Esempio n. 1
0
        public void GetValidMotionSetIndex(
            int animId,
            bool isBattle,
            bool hasWeapon,
            int expectedMsetId)
        {
            var fakeBar = GenerateFakeBar(new bool[]
            {
                // A000
                ANIM,
                DUMMY,
                ANIM,
                DUMMY,
                // A001
                ANIM,
                DUMMY,
                ANIM,
                ANIM,
                // A002
                ANIM,
                DUMMY,
                ANIM,
                ANIM,
                // A003
                DUMMY,
                DUMMY,
                ANIM,
                DUMMY,
                // A004
                DUMMY,
                DUMMY,
                ANIM,
                DUMMY,
                // A005
                DUMMY,
                DUMMY,
                DUMMY,
                DUMMY,
            });

            var actualMsetId = MotionSet.GetMotionSetIndex(
                fakeBar, (MotionSet.MotionName)animId, isBattle, hasWeapon);

            Assert.Equal(expectedMsetId, actualMsetId);
        }
Esempio n. 2
0
        public void GetAbsoluteMotionSetIndex(
            bool isBattle,
            bool hasWeapon,
            int expectedMsetId)
        {
            var fakeBar = GenerateFakeBar(new bool[]
            {
                ANIM,
                ANIM,
                ANIM,
                ANIM,
            });

            var actualMsetId = MotionSet.GetMotionSetIndex(
                fakeBar, MotionSet.MotionName.IDLE, isBattle, hasWeapon);

            Assert.Equal(expectedMsetId, actualMsetId);
        }