コード例 #1
0
        void CustomInitialize()
        {
            InitializeLevel("Level1");

            foreach (var item in Level1Info)
            {
                if (item.EmbeddedAnimation != null && item.EmbeddedAnimation.Count != 0)
                {
                    AnimationChain animationChain = new AnimationChain();
                    foreach (var frame in item.EmbeddedAnimation)
                    {
                    }
                }
            }

            if (CreatedByTiledList.Count == 0)
            {
                throw new Exception("Entities created from tiled are not appearing in the screen's list");
            }

            if (CreatedByTiledList.Count(item => item.Z == 2) == 0)
            {
                throw new Exception("Entities created from tiled object layers are not appearing in the screen's list with the right Z.");
            }
        }
コード例 #2
0
        void CustomInitialize()
        {
            ReducedTileMapInfo.FastCreateFromTmx = true;

            InitializeLevel("Level1");


            foreach (var item in Level1Info)
            {
                if (item.EmbeddedAnimation != null && item.EmbeddedAnimation.Count != 0)
                {
                    AnimationChain animationChain = new AnimationChain();
                    foreach (var frame in item.EmbeddedAnimation)
                    {
                    }
                }
            }

            if (CreatedByTiledList.Count == 0)
            {
                throw new Exception("Entities created from tiled are not appearing in the screen's list");
            }

            if (CreatedByTiledList.Count(item => item.Z == 2) == 0)
            {
                throw new Exception("Entities created from tiled object layers are not appearing in the screen's list with the right Z.");
            }
            CurrentTileMap.ShapeCollections.Count.ShouldNotBe(0, "Because this TMX file contains shapes");

            TestEntitiesCreatedFromShapes();

            TestTypeEntityCreation();

            TestSettingStatesFromVariables();
        }