How to detect when all bodies have stopped moving
Posted: Wed Jan 13, 2010 6:12 pm
Hi all,
Forgive me if this sounds like a n00b question. I"m one.
I'm working on a billiards-like game. Player take turns in moving.
I need to know when the balls have stopped colliding and moving. Is there a callback function for this?
One workaround I'm thinking is to just assume that things have stopped one second after the last collision. The game world is small enough that this assumption is practically valid all the time. But I'm hoping there's a cleaner, built-in way.
Thanks in advance.
Forgive me if this sounds like a n00b question. I"m one.
I'm working on a billiards-like game. Player take turns in moving.
I need to know when the balls have stopped colliding and moving. Is there a callback function for this?
One workaround I'm thinking is to just assume that things have stopped one second after the last collision. The game world is small enough that this assumption is practically valid all the time. But I'm hoping there's a cleaner, built-in way.
Thanks in advance.