Don't complain about transitioning back to PRE_GAME.

git-svn-id: svn+ssh://src.earth.threerings.net/vilya/trunk@428 c613c5cb-e716-0410-b11b-feb51c14d237
This commit is contained in:
Michael Bayne
2007-09-11 19:45:38 +00:00
parent 2b81903c73
commit 9450dc5f2c
2 changed files with 7 additions and 3 deletions
@@ -198,13 +198,15 @@ public /*abstract*/ class GameController extends PlaceController
} }
/** /**
* Derived classes can override this method if they add additional game * Derived classes can override this method if they add additional game states and should
* states and should handle transitions to those states, returning true to * handle transitions to those states, returning true to indicate they were handled and calling
* indicate they were handled and calling super for the normal game states. * super for the normal game states.
*/ */
protected function stateDidChange (state :int) :Boolean protected function stateDidChange (state :int) :Boolean
{ {
switch (state) { switch (state) {
case GameObject.PRE_GAME:
return true;
case GameObject.IN_PLAY: case GameObject.IN_PLAY:
gameDidStart(); gameDidStart();
return true; return true;
@@ -207,6 +207,8 @@ public abstract class GameController extends PlaceController
protected boolean stateDidChange (int state) protected boolean stateDidChange (int state)
{ {
switch (state) { switch (state) {
case GameObject.PRE_GAME:
return true;
case GameObject.IN_PLAY: case GameObject.IN_PLAY:
gameDidStart(); gameDidStart();
return true; return true;