Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes Rapid Spin / Toxic Debris interaction #6023

Merged
merged 3 commits into from
Jan 21, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions docs/tutorials/how_to_new_move.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,6 @@ Each move can have up to 15 additional effects, allowing you to construct monstr
.moveEffect = MOVE_EFFECT_ALL_STATS_UP,
.chance = 40,
.self = TRUE,
},{
.moveEffect = MOVE_EFFECT_RAPID_SPIN,
},{
.moveEffect = MOVE_EFFECT_DEF_MINUS_2,
.chance = 50,
Expand Down
109 changes: 54 additions & 55 deletions include/constants/battle.h
Original file line number Diff line number Diff line change
Expand Up @@ -364,61 +364,60 @@
#define MOVE_EFFECT_PREVENT_ESCAPE 33
#define MOVE_EFFECT_NIGHTMARE 34
#define MOVE_EFFECT_ALL_STATS_UP 35
#define MOVE_EFFECT_RAPID_SPIN 36
#define MOVE_EFFECT_REMOVE_STATUS 37
#define MOVE_EFFECT_ATK_DEF_DOWN 38
#define MOVE_EFFECT_ATK_PLUS_2 39
#define MOVE_EFFECT_DEF_PLUS_2 40
#define MOVE_EFFECT_SPD_PLUS_2 41
#define MOVE_EFFECT_SP_ATK_PLUS_2 42
#define MOVE_EFFECT_SP_DEF_PLUS_2 43
#define MOVE_EFFECT_ACC_PLUS_2 44
#define MOVE_EFFECT_EVS_PLUS_2 45
#define MOVE_EFFECT_ATK_MINUS_2 46
#define MOVE_EFFECT_DEF_MINUS_2 47
#define MOVE_EFFECT_SPD_MINUS_2 48
#define MOVE_EFFECT_SP_ATK_MINUS_2 49
#define MOVE_EFFECT_SP_DEF_MINUS_2 50
#define MOVE_EFFECT_ACC_MINUS_2 51
#define MOVE_EFFECT_EVS_MINUS_2 52
#define MOVE_EFFECT_SCALE_SHOT 53
#define MOVE_EFFECT_THRASH 54
#define MOVE_EFFECT_KNOCK_OFF 55
#define MOVE_EFFECT_DEF_SPDEF_DOWN 56
#define MOVE_EFFECT_CLEAR_SMOG 57
#define MOVE_EFFECT_SMACK_DOWN 58
#define MOVE_EFFECT_FLAME_BURST 59
#define MOVE_EFFECT_FEINT 60
#define MOVE_EFFECT_SPECTRAL_THIEF 61
#define MOVE_EFFECT_V_CREATE 62
#define MOVE_EFFECT_HAPPY_HOUR 63
#define MOVE_EFFECT_CORE_ENFORCER 64
#define MOVE_EFFECT_THROAT_CHOP 65
#define MOVE_EFFECT_INCINERATE 66
#define MOVE_EFFECT_BUG_BITE 67
#define MOVE_EFFECT_RECOIL_HP_25 68
#define MOVE_EFFECT_TRAP_BOTH 69
#define MOVE_EFFECT_ROUND 70
#define MOVE_EFFECT_STOCKPILE_WORE_OFF 71
#define MOVE_EFFECT_DIRE_CLAW 72
#define MOVE_EFFECT_STEALTH_ROCK 73
#define MOVE_EFFECT_SPIKES 74
#define MOVE_EFFECT_SYRUP_BOMB 75
#define MOVE_EFFECT_FLORAL_HEALING 76
#define MOVE_EFFECT_SECRET_POWER 77
#define MOVE_EFFECT_PSYCHIC_NOISE 78
#define MOVE_EFFECT_TERA_BLAST 79
#define MOVE_EFFECT_ORDER_UP 80
#define MOVE_EFFECT_ION_DELUGE 81
#define MOVE_EFFECT_AROMATHERAPY 82 // No functionality yet
#define MOVE_EFFECT_HAZE 83
#define MOVE_EFFECT_LEECH_SEED 84
#define MOVE_EFFECT_REFLECT 85
#define MOVE_EFFECT_LIGHT_SCREEN 86
#define MOVE_EFFECT_SALT_CURE 87
#define MOVE_EFFECT_EERIE_SPELL 88

#define NUM_MOVE_EFFECTS 89
#define MOVE_EFFECT_REMOVE_STATUS 36
#define MOVE_EFFECT_ATK_DEF_DOWN 37
#define MOVE_EFFECT_ATK_PLUS_2 38
#define MOVE_EFFECT_DEF_PLUS_2 39
#define MOVE_EFFECT_SPD_PLUS_2 40
#define MOVE_EFFECT_SP_ATK_PLUS_2 41
#define MOVE_EFFECT_SP_DEF_PLUS_2 42
#define MOVE_EFFECT_ACC_PLUS_2 43
#define MOVE_EFFECT_EVS_PLUS_2 44
#define MOVE_EFFECT_ATK_MINUS_2 45
#define MOVE_EFFECT_DEF_MINUS_2 46
#define MOVE_EFFECT_SPD_MINUS_2 47
#define MOVE_EFFECT_SP_ATK_MINUS_2 48
#define MOVE_EFFECT_SP_DEF_MINUS_2 49
#define MOVE_EFFECT_ACC_MINUS_2 50
#define MOVE_EFFECT_EVS_MINUS_2 51
#define MOVE_EFFECT_SCALE_SHOT 52
#define MOVE_EFFECT_THRASH 53
#define MOVE_EFFECT_KNOCK_OFF 54
#define MOVE_EFFECT_DEF_SPDEF_DOWN 55
#define MOVE_EFFECT_CLEAR_SMOG 56
#define MOVE_EFFECT_SMACK_DOWN 57
#define MOVE_EFFECT_FLAME_BURST 58
#define MOVE_EFFECT_FEINT 59
#define MOVE_EFFECT_SPECTRAL_THIEF 60
#define MOVE_EFFECT_V_CREATE 61
#define MOVE_EFFECT_HAPPY_HOUR 62
#define MOVE_EFFECT_CORE_ENFORCER 63
#define MOVE_EFFECT_THROAT_CHOP 64
#define MOVE_EFFECT_INCINERATE 65
#define MOVE_EFFECT_BUG_BITE 66
#define MOVE_EFFECT_RECOIL_HP_25 67
#define MOVE_EFFECT_TRAP_BOTH 68
#define MOVE_EFFECT_ROUND 69
#define MOVE_EFFECT_STOCKPILE_WORE_OFF 70
#define MOVE_EFFECT_DIRE_CLAW 71
#define MOVE_EFFECT_STEALTH_ROCK 72
#define MOVE_EFFECT_SPIKES 73
#define MOVE_EFFECT_SYRUP_BOMB 74
#define MOVE_EFFECT_FLORAL_HEALING 75
#define MOVE_EFFECT_SECRET_POWER 76
#define MOVE_EFFECT_PSYCHIC_NOISE 77
#define MOVE_EFFECT_TERA_BLAST 78
#define MOVE_EFFECT_ORDER_UP 79
#define MOVE_EFFECT_ION_DELUGE 80
#define MOVE_EFFECT_AROMATHERAPY 81 // No functionality yet
#define MOVE_EFFECT_HAZE 82
#define MOVE_EFFECT_LEECH_SEED 83
#define MOVE_EFFECT_REFLECT 84
#define MOVE_EFFECT_LIGHT_SCREEN 85
#define MOVE_EFFECT_SALT_CURE 86
#define MOVE_EFFECT_EERIE_SPELL 87

#define NUM_MOVE_EFFECTS 88

#define MOVE_EFFECT_AFFECTS_USER 0x2000
#define MOVE_EFFECT_CERTAIN 0x4000
Expand Down
1 change: 1 addition & 0 deletions include/constants/battle_move_effects.h
Original file line number Diff line number Diff line change
Expand Up @@ -348,6 +348,7 @@ enum {
EFFECT_GUARDIAN_OF_ALOLA,
EFFECT_SHELL_SIDE_ARM,
EFFECT_ORDER_UP,
EFFECT_RAPID_SPIN,
NUM_BATTLE_MOVE_EFFECTS,
};

Expand Down
1 change: 1 addition & 0 deletions include/constants/battle_script_commands.h
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,7 @@ enum MoveEndEffects
MOVEEND_MULTIHIT_MOVE,
MOVEEND_DEFROST,
MOVEEND_RECOIL,
MOVEEND_RAPID_SPIN,
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
Expand Down
15 changes: 8 additions & 7 deletions src/battle_ai_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -3502,7 +3502,7 @@ static u32 AI_CalcMoveEffectScore(u32 battlerAtk, u32 battlerDef, u32 move)
case EFFECT_LEECH_SEED:
if (IS_BATTLER_OF_TYPE(battlerDef, TYPE_GRASS)
|| gStatuses3[battlerDef] & STATUS3_LEECHSEED
|| HasMoveWithAdditionalEffect(battlerDef, MOVE_EFFECT_RAPID_SPIN)
|| HasMoveEffect(battlerDef, EFFECT_RAPID_SPIN)
|| aiData->abilities[battlerDef] == ABILITY_LIQUID_OOZE
|| aiData->abilities[battlerDef] == ABILITY_MAGIC_GUARD)
break;
Expand Down Expand Up @@ -4414,6 +4414,12 @@ static u32 AI_CalcMoveEffectScore(u32 battlerAtk, u32 battlerDef, u32 move)
|| gBattleMons[BATTLE_PARTNER(battlerAtk)].status1 & STATUS1_ANY)
ADJUST_SCORE(GOOD_EFFECT);
break;
case EFFECT_RAPID_SPIN:
if ((gSideStatuses[GetBattlerSide(battlerAtk)] & SIDE_STATUS_HAZARDS_ANY && CountUsablePartyMons(battlerAtk) != 0)
|| (gStatuses3[battlerAtk] & STATUS3_LEECHSEED || gBattleMons[battlerAtk].status2 & STATUS2_WRAPPED))
ADJUST_SCORE(GOOD_EFFECT);
break;

} // move effect checks

// check move additional effects that are likely to happen
Expand Down Expand Up @@ -4456,11 +4462,6 @@ static u32 AI_CalcMoveEffectScore(u32 battlerAtk, u32 battlerDef, u32 move)
case MOVE_EFFECT_EVS_PLUS_2:
ADJUST_SCORE(IncreaseStatUpScore(battlerAtk, battlerDef, STAT_CHANGE_EVASION));
break;
case MOVE_EFFECT_RAPID_SPIN:
if ((gSideStatuses[GetBattlerSide(battlerAtk)] & SIDE_STATUS_HAZARDS_ANY && CountUsablePartyMons(battlerAtk) != 0)
|| (gStatuses3[battlerAtk] & STATUS3_LEECHSEED || gBattleMons[battlerAtk].status2 & STATUS2_WRAPPED))
ADJUST_SCORE(GOOD_EFFECT);
break;
}
}
else
Expand Down Expand Up @@ -4655,7 +4656,7 @@ static u32 AI_CalcMoveEffectScore(u32 battlerAtk, u32 battlerDef, u32 move)
}
break;
case MOVE_EFFECT_WRAP:
if (!HasMoveWithAdditionalEffect(battlerDef, MOVE_EFFECT_RAPID_SPIN) && ShouldTrap(battlerAtk, battlerDef, move))
if (!HasMoveEffect(battlerDef, EFFECT_RAPID_SPIN) && ShouldTrap(battlerAtk, battlerDef, move))
ADJUST_SCORE(BEST_EFFECT);
break;
case MOVE_EFFECT_SALT_CURE:
Expand Down
2 changes: 1 addition & 1 deletion src/battle_ai_switch_items.c
Original file line number Diff line number Diff line change
Expand Up @@ -807,7 +807,7 @@ static bool32 CanMonSurviveHazardSwitchin(u32 battler)
for (j = 0; j < MAX_MON_MOVES; j++)
{
aiMove = GetMonData(&party[i], MON_DATA_MOVE1 + j, NULL);
if (MoveHasAdditionalEffectSelf(aiMove, MOVE_EFFECT_RAPID_SPIN)
if (gMovesInfo[aiMove].effect == EFFECT_RAPID_SPIN
|| (B_DEFOG_EFFECT_CLEARING >= GEN_6 && gMovesInfo[aiMove].effect == EFFECT_DEFOG)
|| gMovesInfo[aiMove].effect == EFFECT_TIDY_UP)
{
Expand Down
2 changes: 1 addition & 1 deletion src/battle_ai_util.c
Original file line number Diff line number Diff line change
Expand Up @@ -4013,7 +4013,7 @@ bool32 AI_ShouldSetUpHazards(u32 battlerAtk, u32 battlerDef, struct AiLogicData
{
if (aiData->abilities[battlerDef] == ABILITY_MAGIC_BOUNCE
|| CountUsablePartyMons(battlerDef) == 0
|| HasMoveWithAdditionalEffect(battlerDef, MOVE_EFFECT_RAPID_SPIN)
|| HasMoveEffect(battlerDef, EFFECT_RAPID_SPIN)
|| HasMoveEffect(battlerDef, EFFECT_DEFOG))
return FALSE;

Expand Down
15 changes: 11 additions & 4 deletions src/battle_script_commands.c
Original file line number Diff line number Diff line change
Expand Up @@ -3578,10 +3578,6 @@ void SetMoveEffect(bool32 primary, bool32 certain)
gBattlescriptCurrInstr = BattleScript_AllStatsUp;
}
break;
case MOVE_EFFECT_RAPID_SPIN:
BattleScriptPush(gBattlescriptCurrInstr + 1);
gBattlescriptCurrInstr = BattleScript_RapidSpinAway;
break;
case MOVE_EFFECT_ATK_DEF_DOWN: // SuperPower
if (!NoAliveMonsForEitherParty())
{
Expand Down Expand Up @@ -5909,6 +5905,17 @@ static void Cmd_moveend(void)
}
gBattleScripting.moveendState++;
break;
case MOVEEND_RAPID_SPIN:
if (gMovesInfo[gCurrentMove].effect == EFFECT_RAPID_SPIN
&& !(gHitMarker & HITMARKER_UNABLE_TO_USE_MOVE)
&& TARGET_TURN_DAMAGED)
{
BattleScriptPushCursor();
gBattlescriptCurrInstr = BattleScript_RapidSpinAway;
effect = TRUE;
}
gBattleScripting.moveendState++;
break;
case MOVEEND_ITEM_EFFECTS_ATTACKER:
if (ItemBattleEffects(ITEMEFFECT_MOVE_END, gBattlerAttacker, FALSE))
effect = TRUE;
Expand Down
2 changes: 1 addition & 1 deletion src/battle_tv.c
Original file line number Diff line number Diff line change
Expand Up @@ -933,7 +933,7 @@ static void AddMovePoints(u8 caseId, u16 arg1, u8 arg2, u8 arg3)
// Various cases to add/remove points
if (gMovesInfo[arg2].recoil > 0)
baseFromEffect++; // Recoil moves
if (MoveHasAdditionalEffect(arg2, MOVE_EFFECT_RAPID_SPIN))
if (gMovesInfo[arg2].effect == EFFECT_RAPID_SPIN)
baseFromEffect++;
if (MoveHasAdditionalEffect(arg2, MOVE_EFFECT_SP_ATK_MINUS_2) || MoveHasAdditionalEffect(arg2, MOVE_EFFECT_ATK_DEF_DOWN))
baseFromEffect += 2; // Overheat, Superpower, etc.
Expand Down
6 changes: 6 additions & 0 deletions src/data/battle_move_effects.h
Original file line number Diff line number Diff line change
Expand Up @@ -2219,4 +2219,10 @@ const struct BattleMoveEffect gBattleMoveEffects[NUM_BATTLE_MOVE_EFFECTS] =
.battleScript = BattleScript_EffectHit,
.battleTvScore = 0, // TODO: Assign points
},

[EFFECT_RAPID_SPIN] =
{
.battleScript = BattleScript_EffectHit,
.battleTvScore = 0, // TODO: Assign points
},
};
16 changes: 5 additions & 11 deletions src/data/moves_info.h
Original file line number Diff line number Diff line change
Expand Up @@ -5811,7 +5811,7 @@ const struct MoveInfo gMovesInfo[MOVES_COUNT_DYNAMAX] =
.description = COMPOUND_STRING(
"Spins the body at high\n"
"speed to strike the foe."),
.effect = EFFECT_HIT,
.effect = EFFECT_RAPID_SPIN,
.power = B_UPDATED_MOVE_DATA >= GEN_8 ? 50 : 20,
.type = TYPE_NORMAL,
.accuracy = 100,
Expand All @@ -5820,12 +5820,9 @@ const struct MoveInfo gMovesInfo[MOVES_COUNT_DYNAMAX] =
.priority = 0,
.category = DAMAGE_CATEGORY_PHYSICAL,
.makesContact = TRUE,
.additionalEffects = ADDITIONAL_EFFECTS({
.moveEffect = MOVE_EFFECT_RAPID_SPIN,
.self = TRUE,
}
.additionalEffects = ADDITIONAL_EFFECTS(
#if B_SPEED_BUFFING_RAPID_SPIN >= GEN_8
,{
{
.moveEffect = MOVE_EFFECT_SPD_PLUS_1,
.self = TRUE,
.chance = 100,
Expand Down Expand Up @@ -19576,7 +19573,7 @@ const struct MoveInfo gMovesInfo[MOVES_COUNT_DYNAMAX] =
.description = COMPOUND_STRING(
"Erases trap moves and Leech\n"
"Seed. Poisons adjacent foes."),
.effect = EFFECT_HIT,
.effect = EFFECT_RAPID_SPIN,
.power = 30,
.type = TYPE_POISON,
.accuracy = 100,
Expand All @@ -19585,10 +19582,7 @@ const struct MoveInfo gMovesInfo[MOVES_COUNT_DYNAMAX] =
.priority = 0,
.category = DAMAGE_CATEGORY_PHYSICAL,
.makesContact = TRUE,
.additionalEffects = ADDITIONAL_EFFECTS({
.moveEffect = MOVE_EFFECT_RAPID_SPIN,
.self = TRUE,
},
.additionalEffects = ADDITIONAL_EFFECTS(
{
.moveEffect = MOVE_EFFECT_POISON,
.chance = 100,
Expand Down
2 changes: 1 addition & 1 deletion test/battle/ability/shield_dust.c
Original file line number Diff line number Diff line change
Expand Up @@ -93,8 +93,8 @@ SINGLE_BATTLE_TEST("Shield Dust does not block self-targeting effects, primary o
PARAMETRIZE { move = MOVE_METEOR_ASSAULT; }

GIVEN {
ASSUME(gMovesInfo[MOVE_RAPID_SPIN].effect == EFFECT_RAPID_SPIN);
ASSUME(MoveHasAdditionalEffectSelf(MOVE_POWER_UP_PUNCH, MOVE_EFFECT_ATK_PLUS_1) == TRUE);
ASSUME(MoveHasAdditionalEffectSelf(MOVE_RAPID_SPIN, MOVE_EFFECT_RAPID_SPIN) == TRUE);
ASSUME(MoveHasAdditionalEffectSelf(MOVE_LEAF_STORM, MOVE_EFFECT_SP_ATK_MINUS_2) == TRUE);
ASSUME(MoveHasAdditionalEffectSelf(MOVE_METEOR_ASSAULT, MOVE_EFFECT_RECHARGE) == TRUE);
PLAYER(SPECIES_WOBBUFFET);
Expand Down
2 changes: 1 addition & 1 deletion test/battle/ai/ai_powerful_status.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ AI_SINGLE_BATTLE_TEST("AI prefers to set up a powerful Status over fainting a ta
AI_SINGLE_BATTLE_TEST("AI will try to do damage on target instead of setting up hazards if target has a way to remove them")
{
GIVEN {
ASSUME(MoveHasAdditionalEffectSelf(MOVE_RAPID_SPIN, MOVE_EFFECT_RAPID_SPIN) == TRUE);
ASSUME(gMovesInfo[MOVE_RAPID_SPIN].effect == EFFECT_RAPID_SPIN);
ASSUME(gMovesInfo[MOVE_STEALTH_ROCK].effect == EFFECT_STEALTH_ROCK);
ASSUME(gMovesInfo[MOVE_TACKLE].power > 0);
AI_FLAGS(AI_FLAG_CHECK_BAD_MOVE | AI_FLAG_TRY_TO_FAINT | AI_FLAG_POWERFUL_STATUS | AI_FLAG_OMNISCIENT);
Expand Down
2 changes: 1 addition & 1 deletion test/battle/hold_effect/covert_cloak.c
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,8 @@ SINGLE_BATTLE_TEST("Covert Cloak does not block self-targeting effects, primary
PARAMETRIZE { move = MOVE_METEOR_ASSAULT; }

GIVEN {
ASSUME(gMovesInfo[MOVE_RAPID_SPIN].effect == EFFECT_RAPID_SPIN);
ASSUME(MoveHasAdditionalEffectSelf(MOVE_POWER_UP_PUNCH, MOVE_EFFECT_ATK_PLUS_1) == TRUE);
ASSUME(MoveHasAdditionalEffectSelf(MOVE_RAPID_SPIN, MOVE_EFFECT_RAPID_SPIN) == TRUE);
ASSUME(MoveHasAdditionalEffectSelf(MOVE_LEAF_STORM, MOVE_EFFECT_SP_ATK_MINUS_2) == TRUE);
ASSUME(MoveHasAdditionalEffectSelf(MOVE_METEOR_ASSAULT, MOVE_EFFECT_RECHARGE) == TRUE);
PLAYER(SPECIES_WOBBUFFET);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,30 @@

ASSUMPTIONS
{
ASSUME(MoveHasAdditionalEffectSelf(MOVE_RAPID_SPIN, MOVE_EFFECT_RAPID_SPIN) == TRUE);
ASSUME(gMovesInfo[MOVE_RAPID_SPIN].effect == EFFECT_RAPID_SPIN);
ASSUME(gMovesInfo[MOVE_MORTAL_SPIN].effect == EFFECT_RAPID_SPIN);
#if B_SPEED_BUFFING_RAPID_SPIN >= GEN_8
ASSUME(MoveHasAdditionalEffectSelf(MOVE_RAPID_SPIN, MOVE_EFFECT_SPD_PLUS_1) == TRUE);
#endif
ASSUME(MoveHasAdditionalEffectSelf(MOVE_MORTAL_SPIN, MOVE_EFFECT_RAPID_SPIN) == TRUE);
ASSUME(MoveHasAdditionalEffect(MOVE_MORTAL_SPIN, MOVE_EFFECT_POISON) == TRUE);
}

SINGLE_BATTLE_TEST("Rapin Spin blows away Wrap, hazards and raises Speed (Gen 8+)")
SINGLE_BATTLE_TEST("Rapid Spin activates after Toxic Debris")
{
GIVEN {
PLAYER(SPECIES_GLIMMORA) { Ability(ABILITY_TOXIC_DEBRIS); }
OPPONENT(SPECIES_WOBBUFFET);
} WHEN {
TURN { MOVE(opponent, MOVE_RAPID_SPIN); }
} SCENE {
ANIMATION(ANIM_TYPE_MOVE, MOVE_RAPID_SPIN, opponent);
ABILITY_POPUP(player, ABILITY_TOXIC_DEBRIS);
MESSAGE("Poison spikes were scattered on the ground all around the opposing team!");
MESSAGE("The opposing Wobbuffet blew away Toxic Spikes!");
}
}

SINGLE_BATTLE_TEST("Rapid Spin blows away Wrap, hazards and raises Speed (Gen 8+)")
{
GIVEN {
PLAYER(SPECIES_WOBBUFFET);
Expand All @@ -22,16 +37,16 @@ SINGLE_BATTLE_TEST("Rapin Spin blows away Wrap, hazards and raises Speed (Gen 8+
} SCENE {
ANIMATION(ANIM_TYPE_MOVE, MOVE_STEALTH_ROCK, opponent);
ANIMATION(ANIM_TYPE_MOVE, MOVE_RAPID_SPIN, player);
MESSAGE("Wobbuffet got free of the opposing Wobbuffet's Wrap!");
MESSAGE("Wobbuffet blew away Stealth Rock!");
#if B_SPEED_BUFFING_RAPID_SPIN >= GEN_8
ANIMATION(ANIM_TYPE_GENERAL, B_ANIM_STATS_CHANGE, player);
MESSAGE("Wobbuffet's Speed rose!");
#endif
MESSAGE("Wobbuffet got free of the opposing Wobbuffet's Wrap!");
MESSAGE("Wobbuffet blew away Stealth Rock!");
}
}

SINGLE_BATTLE_TEST("Mortal Spin blows away Wrap, hazards and poisons foe")
SINGLE_BATTLE_TEST("Rapid Spin: Mortal Spin blows away Wrap, hazards and poisons foe")
{
GIVEN {
PLAYER(SPECIES_WOBBUFFET);
Expand All @@ -42,10 +57,9 @@ SINGLE_BATTLE_TEST("Mortal Spin blows away Wrap, hazards and poisons foe")
} SCENE {
ANIMATION(ANIM_TYPE_MOVE, MOVE_STEALTH_ROCK, opponent);
ANIMATION(ANIM_TYPE_MOVE, MOVE_MORTAL_SPIN, player);
MESSAGE("Wobbuffet got free of the opposing Wobbuffet's Wrap!");
MESSAGE("Wobbuffet blew away Stealth Rock!");
MESSAGE("The opposing Wobbuffet was poisoned!");
STATUS_ICON(opponent, poison: TRUE);
MESSAGE("Wobbuffet got free of the opposing Wobbuffet's Wrap!");
MESSAGE("Wobbuffet blew away Stealth Rock!");
}
}

Loading