Beispiel #1
0
        private void CheckForCollision()
        {
            Coordinate movedPosition = snake.GetHeadPosition();
            Cell       collidedCell  = grid.GetGridCell(movedPosition);

            if (collidedCell.CellType != CellType.Empty)
            {
                HandleCollision(collidedCell);
            }
        }