how do you change the speed of an attribute constrain?
Hello, I would like to create an actor who follows another actor, but at a slower speed than the first.
I put the string in the second actor: constrain attribute (self.position.X) to (game.AIActor1) but by doing so the second player moves as fast as the first.
How can I do?
I put the string in the second actor: constrain attribute (self.position.X) to (game.AIActor1) but by doing so the second player moves as fast as the first.
How can I do?
Comments
change the 40 to whatever works for you
actor 1 motion linear x-40 instead of its position
you might have to throw a rule in to check if the actors motion your following is graeter then 0 so you dont end up going backwards
In the actor you want to follow constrain attribute actorVelocity to self motion linear velocity x
in the actor you want to do the following have a rule when actorVelocity>0
contstrain self motion linear velocity to actorVelocity-40
or as rob said constrain self motion linear velocity to actorVelocity/2
you could create me a very basic tutorial?