How to stop revolving on collision?

gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
edited November -1 in Working with GS (Mac)
Hi, i've started on my iPhone project in earnest now; I have utilized some of Tshirtbooth's excellent Joystick Control demo:

http://gamesalad.com/game/play/22929

In particular, Game1Control scene.

When touch is released from the green stick, it returns to the centre, but the player also returns to 0 rotation. I solved this by adding to the Otherwise section of a Change Attribute: game.Angle to game.finished Angle.

That seemed to work fine; when touch is released, the player stays put. But now, if it collides with something, a wall, for instance, it starts revolving.

If anyone could help here, that'd be terrific. I'd upload my work-in-progress if you wanted, to see what's going on.

Comments

  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    Ah sorry, done it again; posted for help before I should. I've made the player's density 0; that's solved the problem.
  • ORBZORBZ Member Posts: 1,304
    Set Physics.Fixed Rotation = true
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    ORBZ said:
    Set Physics.Fixed Rotation = true

    Thanks ORBZ, more refined than my solution! :-)
Sign In or Register to comment.