mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2025-01-29 14:53:55 +01:00
Add missing ability checks to orbs
Flame Orb shouldn't burn mons with Water Bubble and neither orb should affect mons with Comatose.
This commit is contained in:
parent
e8598076a8
commit
542201dd4f
@ -6272,6 +6272,7 @@ u8 ItemBattleEffects(u8 caseID, u8 battlerId, bool8 moveTurn)
|
||||
if (!gBattleMons[battlerId].status1
|
||||
&& CanPoisonType(battlerId, battlerId)
|
||||
&& GetBattlerAbility(battlerId) != ABILITY_IMMUNITY
|
||||
&& GetBattlerAbility(battlerId) != ABILITY_COMATOSE
|
||||
&& IsBattlerAlive)
|
||||
{
|
||||
effect = ITEM_STATUS_CHANGE;
|
||||
@ -6284,6 +6285,8 @@ u8 ItemBattleEffects(u8 caseID, u8 battlerId, bool8 moveTurn)
|
||||
if (!gBattleMons[battlerId].status1
|
||||
&& !IS_BATTLER_OF_TYPE(battlerId, TYPE_FIRE)
|
||||
&& GetBattlerAbility(battlerId) != ABILITY_WATER_VEIL
|
||||
&& GetBattlerAbility(battlerId) != ABILITY_WATER_BUBBLE
|
||||
&& GetBattlerAbility(battlerId) != ABILITY_COMATOSE
|
||||
&& IsBattlerAlive)
|
||||
{
|
||||
effect = ITEM_STATUS_CHANGE;
|
||||
|
Loading…
x
Reference in New Issue
Block a user