Fix Plus/Minus to only work with special moves (#2974)

This commit is contained in:
ghoulslash 2023-05-03 13:20:17 -04:00 committed by GitHub
commit ef348e7e65
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -9255,7 +9255,7 @@ static u32 CalcAttackStat(u16 move, u8 battlerAtk, u8 battlerDef, u8 moveType, b
#if B_PLUS_MINUS_INTERACTION >= GEN_5
case ABILITY_PLUS:
case ABILITY_MINUS:
if (IsBattlerAlive(BATTLE_PARTNER(battlerAtk)))
if (IS_MOVE_SPECIAL(move) && IsBattlerAlive(BATTLE_PARTNER(battlerAtk)))
{
u32 partnerAbility = GetBattlerAbility(BATTLE_PARTNER(battlerAtk));
if (partnerAbility == ABILITY_PLUS || partnerAbility == ABILITY_MINUS)
@ -9264,11 +9264,11 @@ static u32 CalcAttackStat(u16 move, u8 battlerAtk, u8 battlerDef, u8 moveType, b
break;
#else
case ABILITY_PLUS:
if (IsBattlerAlive(BATTLE_PARTNER(battlerAtk)) && GetBattlerAbility(BATTLE_PARTNER(battlerAtk)) == ABILITY_MINUS)
if (IS_MOVE_SPECIAL(move) && IsBattlerAlive(BATTLE_PARTNER(battlerAtk)) && GetBattlerAbility(BATTLE_PARTNER(battlerAtk)) == ABILITY_MINUS)
MulModifier(&modifier, UQ_4_12(1.5));
break;
case ABILITY_MINUS:
if (IsBattlerAlive(BATTLE_PARTNER(battlerAtk)) && GetBattlerAbility(BATTLE_PARTNER(battlerAtk)) == ABILITY_PLUS)
if (IS_MOVE_SPECIAL(move) && IsBattlerAlive(BATTLE_PARTNER(battlerAtk)) && GetBattlerAbility(BATTLE_PARTNER(battlerAtk)) == ABILITY_PLUS)
MulModifier(&modifier, UQ_4_12(1.5));
break;
#endif