public void SetTiles(Tile[,] newTiles) { tiles = newTiles; }
private void ResizeLayer(int layerWidth, int layerHeight) { var newTiles = new Tile[layerHeight, layerWidth]; for (int x = 0; x < layerWidth; x++) for (int y = 0; y < layerHeight; y++) newTiles[y, x] = (x >= width) || (y >= height) ? new EmptyTile() : tiles[y, x]; tiles = newTiles; }
public void SetTile(int tileX, int tileY, Tile newCell) { tiles[tileY, tileX] = newCell; }