diff --git a/src/battle_util.c b/src/battle_util.c index 3807270276..640b4753af 100644 --- a/src/battle_util.c +++ b/src/battle_util.c @@ -4313,6 +4313,7 @@ bool32 CanAbilityBlockMove(u32 battlerAtk, u32 battlerDef, u32 move, u32 ability if (option == ABILITY_RUN_SCRIPT) { + gMultiHitCounter = 0; // Prevent multi-hit moves from hitting more than once after move has been absorbed. gBattleScripting.battler = gBattlerAbility = battlerAbility; gBattlescriptCurrInstr = battleScriptBlocksMove; } diff --git a/test/battle/ability/dazzling.c b/test/battle/ability/dazzling.c index e248c9ce0b..7541b8a566 100644 --- a/test/battle/ability/dazzling.c +++ b/test/battle/ability/dazzling.c @@ -72,3 +72,27 @@ DOUBLE_BATTLE_TEST("Dazzling, Queenly Majesty and Armor Tail don't protect the u } } +SINGLE_BATTLE_TEST("Dazzling, Queenly Majesty and Armor Tail protect from all multi hit hits with one activation") +{ + u32 species, ability; + + PARAMETRIZE { species = SPECIES_BRUXISH; ability = ABILITY_DAZZLING; } + PARAMETRIZE { species = SPECIES_FARIGIRAF; ability = ABILITY_ARMOR_TAIL; } + PARAMETRIZE { species = SPECIES_TSAREENA; ability = ABILITY_QUEENLY_MAJESTY; } + + GIVEN { + PLAYER(SPECIES_WOBBUFFET); + OPPONENT(species) { Ability(ability); } + } WHEN { + TURN { MOVE(player, MOVE_WATER_SHURIKEN); } + } SCENE { + NOT ANIMATION(ANIM_TYPE_MOVE, MOVE_WATER_SHURIKEN, opponent); + ABILITY_POPUP(opponent, ability); + NONE_OF { + ABILITY_POPUP(opponent, ability); + ABILITY_POPUP(opponent, ability); + ABILITY_POPUP(opponent, ability); + ABILITY_POPUP(opponent, ability); + } + } +}