コード例 #1
0
        private static void Compute()
        {
            int x;
            int y;
            int state;

            if (playerInput.Length == 3)
            {
                state = playerInput[0];
                x     = playerInput[1];
                y     = playerInput[2];
            }
            else
            {
                state = 0;
                x     = playerInput[0];
                y     = playerInput[1];
            }

            if (!grid.SetTileState(x, y, ToState(state)))
            {
                ErrorMessage();
                MainLoop();
            }

            if (grid.Tiles[y, x].hasBomb)
            {
                EndGame();
            }
        }