Hey there !
I’m still on my way on making performances better for my game, and I’ve come across this problem : I’m intensely using physics, which causes smartphones to get hot really fast.
I’m using a general “Runtime Collision Listener” (Runtime:addEventListener(“collision”, self)) for several generic stuff (like collision between ground and players, ground and particle), and Local Collision Listener (object:addEventListener(“collision”, onLocalCollision)) for “external items” (like items that aren’t loaded in every level, special bonus, enemies, etc).
The Runtime Collision listener looks pretty heavy, with a lot of “if / then / else / end”.
… So, I was wondering : what would be better ? To have only “local collision listener” or having only “Local Collision Listener”. Or, is mixing both kind of collision listener is just OK ?
BONUS QUESTION : I’m also using collision filters to avoid having useless collision detections (for exemple, parts of a ragdoll that shouldn’t collide on eachother). I’ve read that it would reduce the “bandwith” : is it truely effective ?
Thanks a lot in advance !
But I just wanted to be sure to do it the best way I could. And I guess I won’t be able to do much since I’m using both global and local collision listeners for the different case scenarios.