Drought.World.HeightMap.clone C# (CSharp) Method

clone() public method

public clone ( ) : HeightMap
return HeightMap
        public HeightMap clone()
        {
            HeightMap heightMap = new HeightMap(width, height);
            for (int x = 0; x < width; x++)
                for (int y = 0; y < height; y++)
                    heightMap.setHeight(x, y, map[x, y]);

            return heightMap;
        }