Skip to content

Commit

Permalink
Contrary stat drop anim with Spectral Thief (#4824)
Browse files Browse the repository at this point in the history
* Contrary stat drop anim with Spectral Thief

* Are you happy now agbcc? I hope I w
  • Loading branch information
DizzyEggg authored Jun 19, 2024
1 parent 74f53a7 commit c3b1701
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/battle_script_commands.c
Original file line number Diff line number Diff line change
Expand Up @@ -3584,6 +3584,7 @@ void SetMoveEffect(bool32 primary, bool32 certain)
case MOVE_EFFECT_SPECTRAL_THIEF:
if (!NoAliveMonsForEitherParty())
{
bool32 contrary = (GetBattlerAbility(gBattlerAttacker) == ABILITY_CONTRARY);
gBattleStruct->stolenStats[0] = 0; // Stats to steal.
gBattleScripting.animArg1 = 0;
for (i = STAT_ATK; i < NUM_BATTLE_STATS; i++)
Expand All @@ -3605,16 +3606,16 @@ void SetMoveEffect(bool32 primary, bool32 certain)
if (gBattleScripting.animArg1 == 0)
{
if (byTwo)
gBattleScripting.animArg1 = STAT_ANIM_PLUS2 + i;
gBattleScripting.animArg1 = (contrary ? STAT_ANIM_MINUS2 : STAT_ANIM_PLUS2) + i;
else
gBattleScripting.animArg1 = STAT_ANIM_PLUS1 + i;
gBattleScripting.animArg1 = (contrary ? STAT_ANIM_MINUS1 : STAT_ANIM_PLUS1) + i;
}
else
{
if (byTwo)
gBattleScripting.animArg1 = STAT_ANIM_MULTIPLE_PLUS2;
gBattleScripting.animArg1 = (contrary ? STAT_ANIM_MULTIPLE_MINUS2 : STAT_ANIM_MULTIPLE_PLUS2);
else
gBattleScripting.animArg1 = STAT_ANIM_MULTIPLE_PLUS1;
gBattleScripting.animArg1 = (contrary ? STAT_ANIM_MULTIPLE_MINUS1 : STAT_ANIM_MULTIPLE_PLUS1);
}
}
}
Expand Down

0 comments on commit c3b1701

Please sign in to comment.