changed CanBeConfused to actually check its argument (#2855)

This commit is contained in:
AgustinGDLV 2023-03-23 01:50:44 -07:00 committed by GitHub
parent 9ec31c61bf
commit 03f6fe635f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -6546,8 +6546,8 @@ bool32 CanBeFrozen(u8 battlerId)
bool32 CanBeConfused(u8 battlerId)
{
if (GetBattlerAbility(gEffectBattler) == ABILITY_OWN_TEMPO
|| gBattleMons[gEffectBattler].status2 & STATUS2_CONFUSION
if (GetBattlerAbility(battlerId) == ABILITY_OWN_TEMPO
|| gBattleMons[battlerId].status2 & STATUS2_CONFUSION
|| IsBattlerTerrainAffected(battlerId, STATUS_FIELD_MISTY_TERRAIN))
return FALSE;
return TRUE;