示例#1
0
        public void Resize(int width, int height)                       // editor magic.
        {
            var oldMapTiles     = MapTiles.Value;
            var oldMapResources = MapResources.Value;

            MapTiles     = Lazy.New(() => Exts.ResizeArray(oldMapTiles, oldMapTiles[0, 0], width, height));
            MapResources = Lazy.New(() => Exts.ResizeArray(oldMapResources, oldMapResources[0, 0], width, height));
            MapSize      = new int2(width, height);
        }