Stop a ball from rotating

jon2sjon2s Member Posts: 40
edited November -1 in Working with GS (Mac)
I've been messing with all sorts of things to keep a ball from rolling forever.

My setup: Gravity is in use. If a ball falls down to the "ground" and does not come into contact with anything else, it stops perfectly. If a ball falls down and comes into contact with something else, it nearly always continues to roll. Even if it falls between 2 boxes, it will roll between those 2 boxes forever. Barely even moving. I've tried applying drag, increasing the friction, density, changing velocity to 0 for both x and y, setting rotation to 0, moving the ball somewhere else. Nothing seems to work. Any suggestions?

Thanks,

Jon

Comments

  • EastboundEastbound Member, BASIC Posts: 1,074
    You could try:

    If angular velocity < 1 (or some other arbitrary amount. Test to find what you like)
    set angular velocity = 0
  • rebumprebump Member Posts: 1,058
    I think you may need to play with the normal velocities as well. If the ball is rolling and spinning while rolling (like balls do), you need to stop the spin (angular) and stop the motion (non-angular).

    Edit: Oop. Initially, I just scanned your initial post. After more thorough reading, sounds like you are still getting rotation while even standing in place...so yeah, angular velocity being zeroed out similar to what Eastbound suggested should work.
  • HunnenkoenigHunnenkoenig Member Posts: 1,173
    That was my exact same problem in the other thread made yesterday.

    I will try this too.

    Thanks guys!
  • ValanValan Member, BASIC Posts: 410
    I had a similar problem.

    After a few hours of banging my head I made the actor spawn an identical unmovable actor. A bit of a side step but it worked and gave me more FPS.

    Although destroying and spawning takes FPS from the game, unmovable actors are much more efficient than movable ones.
Sign In or Register to comment.