- Home /
Enemy Rotation AI
Hello There!
Im trying to make an enemy AI to be in the orbit of a planet (always 30f distant from the planet) and make him move to the same angle that the player is.
Im using vector3 rotate towards and calculating the the angle between the planet.position - enemy.position and the player.position - planet.position. So I rotate towards that angle and I line up with the player position.
The problem is, I don't want the enemy to always be on the middle ... and when I have like 30 enemies on the screen they all try to be in the same splot(in the players angle). what I want them to do is to try to go in that position but if there is somebody there already, they don't push each other. Kind of a swarming effect.
Please help me if u can!
Thanks
Your answer
Follow this Question
Related Questions
Rotate towards 270 degrees,Rotate Towards 270 1 Answer
Turret AI script off rotation 1 Answer
Rotate player back to walkable position after being hit. 0 Answers
NavMeshAgent resume original position and facing direction C# 0 Answers
Boids for 2D 0 Answers