Grow() public method

public Grow ( IntVector3 p ) : void
p IntVector3
return void
        public void SetTerrains(KeyValuePair <IntVector3, TileData>[] tileDataList)
        {
            this.Version += 1;

            int x, y, z;

            x = y = z = 0;

            foreach (var kvp in tileDataList)
            {
                IntVector3 p = kvp.Key;

                if (x < p.X)
                {
                    x = p.X;
                }
                if (y < p.Y)
                {
                    y = p.Y;
                }
                if (z < p.Z)
                {
                    z = p.Z;
                }
            }

            m_tileGrid.Grow(new IntVector3(x, y, z));

            foreach (var kvp in tileDataList)
            {
                IntVector3 p    = kvp.Key;
                TileData   data = kvp.Value;

                m_tileGrid.SetTileData(p, data);

                if (MapTileTerrainChanged != null)
                {
                    MapTileTerrainChanged(p);
                }
            }
        }