Impactus
17-04-2008 01:02:49
I am having trouble restarting the scene! (specific bodies)
My goal is to put the bodies in the same place where they were in the beginning, but this is not working.
What I am doing is: HALT everything -> setGlobalPosition(...) of the bodies I want to reset the position -> RESUME everything.
I tried to use setTimeModifier(0), then setGlobalPosition(...) the body in the right place, and then switch back the setTimeModifier(1) - doesn't work!
I also tried to use body->putToSleep on the bodies before resetting the position and wakeUp() after, but the same thing happens.
Any ideas on how to do this?
My goal is to put the bodies in the same place where they were in the beginning, but this is not working.
What I am doing is: HALT everything -> setGlobalPosition(...) of the bodies I want to reset the position -> RESUME everything.
I tried to use setTimeModifier(0), then setGlobalPosition(...) the body in the right place, and then switch back the setTimeModifier(1) - doesn't work!
I also tried to use body->putToSleep on the bodies before resetting the position and wakeUp() after, but the same thing happens.
Any ideas on how to do this?