Actor falling over

KyromaticKyromatic Member Posts: 1
edited January 2012 in Working with GS (Mac)
Hello! I have been unable to find an answer to my problem. In my game the actor is constantly moving forward, going over ramps and such. I want the actor to follow the slope of the ramp but not flip over. Many solutions call for me to restrain the movement but this makes my actor's movement unrealistic as they slightly hover when they go up the ramps. Is there some way to allow the actor correct itself? Like as it is in the air it can keep itself up? Sorry if this is confusing. THANKS FOR YOUR HELP AGAIN!

Comments

  • bazookaBenbazookaBen Member Posts: 318
    edited February 2012
    A bit of physics (if I remember correctly from college): actors falling over are result of a rotational "moment" (Force x length of arm) acting on the its center of gravity. To remove this rotational moment in GS, we remove the mass of the actor -> i.e set density of both actors to zero.

    to recap:

    mass = density * volume
    force = mass * acceleration ( in this case, gravitational acceleration)
    moment = force * length of arm

    by setting density to zero, we nullify any rotational moment.
Sign In or Register to comment.