示例#1
0
            internal AnimationsManager(GMTileSet tileSet)
            {
                if (tileSet == null)
                {
                    throw new ArgumentNullException(nameof(tileSet));
                }

                animations = new List <GMTileSetAnimation>();

                this.tileSet = tileSet;
            }
示例#2
0
            internal AutoTileSetManager(GMTileSet tileSet)
            {
                if (tileSet == null)
                {
                    throw new ArgumentNullException(nameof(tileSet));
                }

                autoTileSets = new List <GMAutoTileSet>();

                this.tileSet = tileSet;
            }
示例#3
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;
        }
示例#4
0
        internal GMTileSetAnimation(int frameCount, GMTileSet tileSet)
        {
            if (tileSet == null)
            {
                throw new ArgumentNullException(nameof(tileSet));
            }

            // TODO Validate 2, 4, 8, 16, 32, 64, 128, 256?
            if (frameCount < 0)
            {
                throw new ArgumentOutOfRangeException(nameof(frameCount), frameCount, "frameCount cannot be less than 0");
            }

            Frames = new Tile[frameCount];

            this.tileSet = tileSet;
        }