Fixes Red Card / Eject Pack interaction (#5724)
This commit is contained in:
parent
b123126939
commit
6b170d70f1
3 changed files with 39 additions and 1 deletions
|
@ -300,9 +300,9 @@ enum MoveEndEffects
|
|||
MOVEEND_RECOIL,
|
||||
MOVEEND_ITEM_EFFECTS_ATTACKER,
|
||||
MOVEEND_MAGICIAN, // Occurs after final multi-hit strike, and after other items/abilities would activate
|
||||
MOVEEND_RED_CARD, // Red Card triggers before Eject Pack
|
||||
MOVEEND_EJECT_ITEMS,
|
||||
MOVEEND_WHITE_HERB,
|
||||
MOVEEND_RED_CARD,
|
||||
MOVEEND_LIFEORB_SHELLBELL, // Includes shell bell, throat spray, etc
|
||||
MOVEEND_CHANGED_ITEMS,
|
||||
MOVEEND_PICKPOCKET,
|
||||
|
|
|
@ -332,3 +332,19 @@ DOUBLE_BATTLE_TEST("Primal reversion and other switch-in effects trigger for all
|
|||
EXPECT_EQ(opponentRight->statStages[STAT_SPEED], DEFAULT_STAT_STAGE - 1);
|
||||
}
|
||||
}
|
||||
|
||||
SINGLE_BATTLE_TEST("111")
|
||||
{
|
||||
GIVEN {
|
||||
ASSUME(gMovesInfo[MOVE_TACKLE].power != 0);
|
||||
PLAYER(SPECIES_GROUDON) { HP(1); Item(ITEM_RED_ORB); }
|
||||
PLAYER(SPECIES_WOBBUFFET)
|
||||
OPPONENT(SPECIES_WOBBUFFET);
|
||||
} WHEN {
|
||||
TURN { MOVE(opponent, MOVE_TACKLE); SEND_OUT(player, 1); }
|
||||
} SCENE {
|
||||
ANIMATION(ANIM_TYPE_GENERAL, B_ANIM_PRIMAL_REVERSION, player);
|
||||
MESSAGE("Groudon's Primal Reversion! It reverted to its primal form!");
|
||||
MESSAGE("Groudon fainted!");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -467,4 +467,26 @@ SINGLE_BATTLE_TEST("Red Card prevents Emergency Exit activation when triggered")
|
|||
}
|
||||
}
|
||||
|
||||
SINGLE_BATTLE_TEST("Red Card activates before Eject Pack")
|
||||
{
|
||||
GIVEN {
|
||||
ASSUME(MoveHasAdditionalEffectSelf(MOVE_OVERHEAT, MOVE_EFFECT_SP_ATK_MINUS_2) == TRUE);
|
||||
PLAYER(SPECIES_WOBBUFFET) { Item(ITEM_EJECT_PACK); }
|
||||
PLAYER(SPECIES_WYNAUT);
|
||||
OPPONENT(SPECIES_WOBBUFFET) { Item(ITEM_RED_CARD); }
|
||||
OPPONENT(SPECIES_WYNAUT);
|
||||
} WHEN {
|
||||
TURN { MOVE(player, MOVE_OVERHEAT); MOVE(opponent, MOVE_TACKLE); }
|
||||
} SCENE {
|
||||
ANIMATION(ANIM_TYPE_MOVE, MOVE_OVERHEAT, player);
|
||||
NONE_OF {
|
||||
ANIMATION(ANIM_TYPE_GENERAL, B_ANIM_HELD_ITEM_EFFECT, player);
|
||||
MESSAGE("Wobbuffet is switched out with the Eject Button!");
|
||||
}
|
||||
ANIMATION(ANIM_TYPE_GENERAL, B_ANIM_HELD_ITEM_EFFECT, opponent);
|
||||
MESSAGE("Foe Wobbuffet held up its Red Card against Wobbuffet!");
|
||||
ANIMATION(ANIM_TYPE_MOVE, MOVE_TACKLE, opponent);
|
||||
}
|
||||
}
|
||||
|
||||
// SINGLE_BATTLE_TEST("Red Card activates but fails if the attacker has Dynamaxed")
|
||||
|
|
Loading…
Reference in a new issue