示例#1
0
            public GMAutoTileSet Create(GMAutoTileSetType type)
            {
                var autoTileSet = new GMAutoTileSet(type, tileSet)
                {
                    Id   = Guid.NewGuid(),
                    Name = $"autotile_{autoTileSets.Count + 1}"
                };

                autoTileSets.Add(autoTileSet);

                return(autoTileSet);
            }
示例#2
0
        internal GMAutoTileSet(GMAutoTileSetType type, GMTileSet tileSet)
        {
            if (tileSet == null)
            {
                throw new ArgumentNullException(nameof(tileSet));
            }

            int length = type == GMAutoTileSetType.Full ? 47 : 16;

            Tiles = new Tile[length];

            this.tileSet = tileSet;
        }