示例#1
0
        public GameStatesTypes NextMove(InputType input)
        {
            GameStatesTypes nextMove = _currentState.NextAction(input);

            _currentState = _currentState.NextState(input);
            return(nextMove);
        }
        public DirectionType NextMove(InputType input)
        {
            // Find next move from current state and input
            DirectionType nextMove = _currentState.NextAction(input);

            // Find next state from current state and input
            _currentState = _currentState.NextState(input);

            return(nextMove);
        }
        public SnakeStatesTypes NextMove(InputType input)
        {
            // Find next move from current state and input
            SnakeStatesTypes nextMove = _currentState.NextAction(input);

            // Find next state from current state and input
            _currentState = _currentState.NextState(input);

            return(nextMove);
        }
示例#4
0
        public StatesTypes NextMove()
        {
            // Find next move from current state and input
            StatesTypes nextMove = _currentState.NextAction();

            // Find next state from current state and input
            _currentState = _currentState.NextState();

            return(nextMove);
        }