constrained Actor
polimerjones
Member Posts: 50
When actor1 is constrained to actor2 when they move only actor2 can tell that its moving. does anyone know a work around for this?
Comments
This is because constraining to a position is not actually moving, but instead changing the position coordinates at a very fast rate.
Do this instead:
constrain actor1.motionLinearVelocityX to (actor2.posX - actor1.posX)*20
constrain actor1.motionLinearVelocityY to (actor2.posY - actor1.posY)*20
Note: make 20 higher for more responsive, or less for less responsive