Moving consistently - how to move to a X,Y position but not stop
![cibram](http://forums.gamesalad.com/applications/dashboard/design/images/defaulticon.png)
Hey everyone,
Imagine a top down game, an actor is spawning and taking Move To action which tells it to go to another actors X,Y position. So far i have done this with telling him to go local attribute.
But the actor stops when it goes to the X,Y - what i want is, it should move consistently and goes out of the scene.
Any suggestions?
Imagine a top down game, an actor is spawning and taking Move To action which tells it to go to another actors X,Y position. So far i have done this with telling him to go local attribute.
But the actor stops when it goes to the X,Y - what i want is, it should move consistently and goes out of the scene.
Any suggestions?
Best Answer
-
JohnPapiomitis Posts: 6,256
vectorToAngle(actorX-secondX,actorY-secondY)
Theres alot of info on the forums about vectorToAngle, do a search if your still having trouble
Answers
how can i find the angle to use in the direction? can you explain a little more?