I have a main game thread but when the target score is achieved I have an activity that is launched called StageCleared which basically displays the stats to the user of their performance and then they can press a continue button to carry on with the game. This should switch focus back to the running thread that should continue execution, and thus display the game activity (with parameters i update after StageCleared has exectued).
It was suggested I use a package visible object that calls wait() on itself in the main game thread, and then notify() on itself from StageCleared in order to continue execution. My first problem is I can't seem to declare a package visible object that can be seen by all the classes in my package? Secondly, is this the best way to achieve what I'm intending to do or is there a better way?
Many thanks