I am working on a motorbike jumping game, with a bike constructed of several marts pinned together, and a ragdoll driver who come off the bike when it crashes. I'm trying to optimize the performance a bit, and originally assumed that the graphics drawing was the biggest bottleneck. But after stripping out all of the graphics (and most of the scene's box2d Objects) I notice that the framerate drops from 60fps down to 20fps when the bike is in the air (ie mid-jump) and then goes up again when it lands.
Does anyone have any suggestions as to why this might be happening? Is it just that it is a more complex physics problem for the engine to solve? Are there any known slowdowns caused by certain configurations, such as a ring of pinned objects. (Here, the rider holds on with hand and feet, creating a ring.) I can't quite see why being off the 'ground' should make such a big difference, when the whole bike in in motion and obviously never reaching a resting state or anything.
I thought it might be something to do with jumping out of the defined bounds of the world, but I think I've made it big enough now, with no noticeable change in performance.
Any tips are greatly appreciated.
Does anyone have any suggestions as to why this might be happening? Is it just that it is a more complex physics problem for the engine to solve? Are there any known slowdowns caused by certain configurations, such as a ring of pinned objects. (Here, the rider holds on with hand and feet, creating a ring.) I can't quite see why being off the 'ground' should make such a big difference, when the whole bike in in motion and obviously never reaching a resting state or anything.
I thought it might be something to do with jumping out of the defined bounds of the world, but I think I've made it big enough now, with no noticeable change in performance.
Any tips are greatly appreciated.