How do I change attribute upon motion stopping
JamesZeppelin
Member Posts: 1,927
I have a game where an actor comes to a halt do to drag. If he didnt hit the goal i need the level to fail (basically change an attribute).
How would i go about the actor changing the attribute under those circumstances
Im sure it can be done but i just cant figure it out.
How would i go about the actor changing the attribute under those circumstances
Im sure it can be done but i just cant figure it out.
Comments
when self.velocity.X (or Y) is < 1
and game.actorsCollided = false
then
game.actorFellShortOfTarget = true
The main problem was i just somehow missed the fact that we had x and y velocity self attributes to work with..... Once i realized that it made it alot easier. I always seem to miss something obvious
I also used something i found on a post you had started to bring the actor to a stop at a certain speed. FMG had suggested the < 1, > -1 thing and it helped move thngs along without having to play with drag for two hours or more like i usually do.
thanks!
BTW, if you ever post a question and find the solution yourself...post it...
Usually it will help everyone else too!!!