public void SetTile(int2 position, Type.Ground groundType)
 {
     tilemaps["Ground"].SetTile(
         new Vector3Int(position.x, position.y, 0),
         tiles[Info.Tile.groundTileNames[groundType]]
         );
 }
Ejemplo n.º 2
0
        public void SetupGround(int2 position, Type.Ground groundType)
        {
            if (Util.Map.OnMap(position))
            {
                Data.Cell cellData = GetCell(position);
                cellData.GroundType = groundType;

                SetCell(position, cellData);
            }
        }
Ejemplo n.º 3
0
 public void SetupGround(RectInt bounds, Type.Ground groundType, bool fill = true)
 {
     for (int x = bounds.xMin; x < bounds.xMax; x++)
     {
         for (int y = bounds.yMin; y < bounds.yMax; y++)
         {
             if (fill || Util.Map.OnRectBoundary(x, y, bounds))
             {
                 SetupGround(x, y, groundType);
             }
         }
     }
 }
Ejemplo n.º 4
0
 public void SetupGround(int x, int y, Type.Ground groundType)
 {
     SetupGround(new int2(x, y), groundType);
 }