Esempio n. 1
0
 private void AddPieceToGrid(Piece piece, int row, int column, int rotation)
 {
     bool[,] bitmask = piece.GetBitmask(rotation);
     for (int i = 0; i < bitmask.GetLength(0); i++)
         for (int j = 0; j < bitmask.GetLength(1); j++)
             if (bitmask[i, j])
                 Grid[row + i, column + j] = (int)piece;
 }