Beispiel #1
0
        public static PlayerMoveState GetMoveState(PlayerManager.MoveState pState)
        {
            PlayerManager pMan = PlayerManager.PrivGetInstance();

            Debug.Assert(pMan != null);

            PlayerMoveState toReturn = null;

            switch (pState)
            {
            case MoveState.PlayerMoveNormal:
                toReturn = pMan.poNormalState;
                break;

            case MoveState.PlayerHitLeftWall:
                toReturn = pMan.poHitLeftState;
                break;

            case MoveState.PlayerHitRightWall:
                toReturn = pMan.poHitRightState;
                break;

            default:
                Debug.Assert(false);
                break;
            }
            Debug.Assert(toReturn != null);
            return(toReturn);
        }
Beispiel #2
0
 public void SetMoveState(PlayerManager.MoveState pState)
 {
     this.pMoveState = PlayerManager.GetMoveState(pState);
 }