Lose life if actor is standing still!

How do you make your actor loose a life if it is like not moving for like 5-7 seconds?

Comments

  • OskarDeveloperOskarDeveloper Member Posts: 533
    If self.motionline.x is = 0
    timer
    after random 5, 7 seconds
    change game.hp to game.hp -1
  • Mathiashelseth99Mathiashelseth99 Member Posts: 37
    Thanks ;)

    is all the attributes already in the creator?
  • -Timo--Timo- Member Posts: 2,313
    except for the lives (game.hp)

    if you're also moving on the y then do
    if self.motion.linear velocity.X = 0 and self.motion.linear velocity.Y = 0
    do
    after random(5,7) seconds
    change game.hp to game.hp-1
  • Mathiashelseth99Mathiashelseth99 Member Posts: 37
    i cant seem to find the self.motionline.x and y!
  • Mathiashelseth99Mathiashelseth99 Member Posts: 37
    ok, Thanks ;)
  • -Timo--Timo- Member Posts: 2,313
    found it?
    it's not self.motionline.x it's self.motion.linear velocity.x (and y)
    good luck :)

    -Timo-
Sign In or Register to comment.