So I’m animating a number of balls around the screen on an enterframe listener, making sure they dont overlap the screen edges and reversing their direction if so.
I’ve attached a collision listener to each ball and want a linearImpulse should two balls collide.
This is all working perfectly - however I’ve noticed that having added the impulse upon collision that balls are now falling outside of the screen edges.
If I take away the impulse then it all works fine again. I suspect it’s something to do with the issue of changing an objects properties while an event is occurring; however my issue is that because the animation is on an enterframe listener then these objects are constantly changing their properties.
Any help to avoid this would be grateful - picture it as a physics enabled version of asteroids I guess. [import]uid: 33275 topic_id: 35317 reply_id: 335317[/import]