We are using Cocos 2D for Android and are unsure if it's a good thing to execute our non-ui tasks on the Cocos thread as a way to get the animations in our game to pause.
What is the recommended practice?
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It only takes a minute to sign up.Sign up to join this community
Thread are something that you have to avoid as long as possible. sure they make all the thing easier in some conditions but they may also create some enexpeted behavior that are really hard to trace. so for your example i prefer some flag to stop update functions to do their animate jobs since you can easily implement it that way.
in general specially for iphone/android that using threads doesn't give any boost in performance (and sometimes might even reduce fps) I prefer to do all the jobs by hand. except some very rare cases such as loading game content while playing animations there is no need to use threads at all, so you have to avoid using them.