예제 #1
0
            public static void TestPartyNPEquipCount()
            {
                BattleMario mario     = new BattleMario(new MarioStats(0, 0, 0, 0, 0, EquipmentGlobals.BootLevels.Normal, EquipmentGlobals.HammerLevels.Normal));
                Goombario   goombario = new Goombario();

                List <BattleEntity> set = new List <BattleEntity>()
                {
                    mario, goombario
                };

                CloseCallBadge  cc  = new CloseCallBadge();
                CloseCallPBadge ccp = new CloseCallPBadge();

                cc.Equip(mario);
                ccp.Equip(goombario);

                Debug.Assert(EntityGlobals.GetCombinedEquippedBadgeCount(set, cc.BadgeType) == 1);
                Debug.Assert(EntityGlobals.GetCombinedEquippedBadgeCount(set, ccp.BadgeType) == 1);

                Debug.Assert(EntityGlobals.GetCombinedEquippedNPBadgeCount(set, cc.BadgeType) == 2);
                Debug.Assert(EntityGlobals.GetCombinedEquippedNPBadgeCount(set, ccp.BadgeType) == 2);
                Debug.Assert(EntityGlobals.GetCombinedEquippedNPBadgeCount(set, cc.BadgeType) == 2);
                Debug.Assert(EntityGlobals.GetCombinedEquippedNPBadgeCount(set, ccp.BadgeType) == 2);

                cc.UnEquip();
                ccp.UnEquip();

                Debug.Log("\n");
            }
예제 #2
0
            public static void TestPAndNoPEquipCount2(BattlePlayer player)
            {
                CloseCallPBadge CCP1 = new CloseCallPBadge();
                CloseCallPBadge CCP2 = new CloseCallPBadge();
                CloseCallPBadge CCP3 = new CloseCallPBadge();
                CloseCallPBadge CCP4 = new CloseCallPBadge();
                CloseCallBadge  CC   = new CloseCallBadge();

                CCP1.Equip(player);
                CCP2.Equip(player);
                CCP3.Equip(player);
                CCP4.Equip(player);
                CC.Equip(player);

                Debug.Assert(player.GetEquippedBadgeCount(BadgeGlobals.BadgeTypes.CloseCall) == 1);
                Debug.Assert(player.GetEquippedBadgeCount(BadgeGlobals.BadgeTypes.CloseCallP) == 4);
                Debug.Assert(player.GetEquippedNPBadgeCount(BadgeGlobals.BadgeTypes.CloseCall) == 5);
                Debug.Assert(player.GetEquippedNPBadgeCount(BadgeGlobals.BadgeTypes.CloseCallP) == 5);

                CCP1.UnEquip();
                CCP2.UnEquip();
                CCP3.UnEquip();
                CCP4.UnEquip();
                CC.UnEquip();

                Debug.Log("\n");
            }