mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-26 03:34:15 +01:00
Fixes Make it Rain in double battles (#3441)
This commit is contained in:
parent
70985ed3d6
commit
0a6c0261fe
@ -496,6 +496,8 @@ BattleScript_CorrosiveGasFail:
|
||||
goto BattleScript_MoveEnd
|
||||
|
||||
BattleScript_EffectMakeItRain:
|
||||
jumpifbattletype BATTLE_TYPE_DOUBLE, BattleScript_MakeItRainDoubles
|
||||
BattleScript_MakeItRainContinuous:
|
||||
setmoveeffect MOVE_EFFECT_PAYDAY
|
||||
call BattleScript_EffectHit_Ret
|
||||
seteffectwithchance
|
||||
@ -503,6 +505,9 @@ BattleScript_EffectMakeItRain:
|
||||
setmoveeffect MOVE_EFFECT_SP_ATK_MINUS_1 | MOVE_EFFECT_AFFECTS_USER | MOVE_EFFECT_CERTAIN
|
||||
seteffectprimary
|
||||
goto BattleScript_MoveEnd
|
||||
BattleScript_MakeItRainDoubles:
|
||||
jumpifword CMP_NO_COMMON_BITS, gHitMarker, HITMARKER_NO_ATTACKSTRING | HITMARKER_NO_PPDEDUCT, BattleScript_NoMoveEffect
|
||||
goto BattleScript_MakeItRainContinuous
|
||||
|
||||
BattleScript_EffectSpinOut::
|
||||
setmoveeffect MOVE_EFFECT_SPD_MINUS_2 | MOVE_EFFECT_AFFECTS_USER | MOVE_EFFECT_CERTAIN
|
||||
|
@ -32,3 +32,27 @@ SINGLE_BATTLE_TEST("Make It Rain lowers special attack by one stage")
|
||||
EXPECT_MUL_EQ(damage[0], Q_4_12(0.66), damage[1]);
|
||||
}
|
||||
}
|
||||
|
||||
DOUBLE_BATTLE_TEST("Make It Rain lowers special attack by one stage if it hits both targets")
|
||||
{
|
||||
GIVEN {
|
||||
PLAYER(SPECIES_WOBBUFFET)
|
||||
PLAYER(SPECIES_WOBBUFFET);
|
||||
OPPONENT(SPECIES_WOBBUFFET);
|
||||
OPPONENT(SPECIES_WOBBUFFET);
|
||||
} WHEN {
|
||||
TURN { MOVE(playerLeft, MOVE_MAKE_IT_RAIN); }
|
||||
} SCENE {
|
||||
ANIMATION(ANIM_TYPE_MOVE, MOVE_MAKE_IT_RAIN, playerLeft);
|
||||
HP_BAR(opponentLeft);
|
||||
NONE_OF {
|
||||
MESSAGE("Coins scattered everywhere!");
|
||||
ANIMATION(ANIM_TYPE_GENERAL, B_ANIM_STATS_CHANGE, playerLeft);
|
||||
MESSAGE("Wobbuffet's Sp. Atk fell!");
|
||||
}
|
||||
HP_BAR(opponentRight);
|
||||
MESSAGE("Coins scattered everywhere!");
|
||||
ANIMATION(ANIM_TYPE_GENERAL, B_ANIM_STATS_CHANGE, playerLeft);
|
||||
MESSAGE("Wobbuffet's Sp. Atk fell!");
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user