Hi
I'm using box2d in the cocos2d iphone engine. So I realise this may not be the easiest question to answer as there are many variables involved. But just wanted to mention it here if anyone has any tips for what I could check.
My box2d world is set with zero gravity to simulate a top down game.
When I add a bullet to the world (as a b2Circle) I give it an initial linear velocity and it moves across the screen at a steady rate.
But if the framerate drops to zero for a second due to a big calculation going on, the bullet slows down and continues at a slower speed when the framerate goes back to normal.
I cant reproduce this in the box2d test bed in the cocos2d test project, so im guessing it's something I'm doing wrong.
Would there be anything obvious that would effect the speed of bodies when the frame rate drops?
I am not altering the linear velocity at any time after the initial speed is set when the body is added.
Thanks for any help.
I'm using box2d in the cocos2d iphone engine. So I realise this may not be the easiest question to answer as there are many variables involved. But just wanted to mention it here if anyone has any tips for what I could check.
My box2d world is set with zero gravity to simulate a top down game.
When I add a bullet to the world (as a b2Circle) I give it an initial linear velocity and it moves across the screen at a steady rate.
But if the framerate drops to zero for a second due to a big calculation going on, the bullet slows down and continues at a slower speed when the framerate goes back to normal.
I cant reproduce this in the box2d test bed in the cocos2d test project, so im guessing it's something I'm doing wrong.
Would there be anything obvious that would effect the speed of bodies when the frame rate drops?
I am not altering the linear velocity at any time after the initial speed is set when the body is added.
Thanks for any help.