The problem exists in a clean project with updated packages as well. I can send a download link to the project. I set up a test scene where the target is animated to reproduce the issue. The target will move once the agent reaches it. At that point the rotation will be messed up, causing the...
Hello, to me it looks like the surround behavior tree task stops updating the agent rotation after reaching the destination. After the destination is changed to another location the agents moves without updating the rotation according to the navmash agent's direction. I was able to trace it back...
I have traced it back to the navmeshtacticalgroup script. it seems to fail at this line:
if (Quaternion.Angle(transform.rotation, targetRotation) < AttackAgent.AttackAngle())
The AttackAgent does not seem to be assigned, causing the null reference error.
I am sorry, it looks like the tree has stopped working because the surround task failed at the following task: if (tacticalAgent.RotateTowardsPosition(tacticalAgent.TargetTransform.position))
The values tacticalAgent.TargetTransform.position and tacticalAgent are not empty.
Hello,
I reverted to using the unity navmesh agent instead of a*pathfinding using the surround task for the behavior tree. However, the rest of the tree is only executing if the surround task is not finished. As soon as the agent moves, the rest of the tree starts executing again. I am using a...
For anyone facing this issue, I have added the following line of code to the "surround" script at "OnUpdate" after the destination gets set and the detour part. this should return the next best nearest point on the navmesh: destination = (Vector3)AstarPath.active.GetNearest(destination...
I visualized the destination from the detour which is in a clear line from the leader across the target. I am not sure if it should not be at the height ot the target.
As far as I can tell the surround task has lines of codes that should prevent this. However, the agents seem to cross way too narrow to the target.
Is there a way to make the agent circle around the size of the circle instead of in between the target and other agents? Sort of traveling at a...
I could trace it back to the "CenterAttackPosition" function of the "tacticalgroup". With breakpoints and logs, I can tell that there are sometimes no target transforms resulting in the position vector being zero. this does not happen every time.
I even tried setting the target with a game...
I have set breakpoints and added debug.log to check if both the leader and the following agent get added to the group. I can see that both are added right after one another. after the following agent is added I get the "Look rotation viewing vector is zero" Log and the agent stops moving. The...