Merge pull request #2469 from LOuroboros/patch-1

Updated TryChangeBattleTerrain
This commit is contained in:
Eduardo Quezada D'Ottone 2022-12-05 23:40:52 -03:00 committed by GitHub
commit 3718f58a0a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4237,7 +4237,7 @@ static bool32 TryChangeBattleTerrain(u32 battler, u32 statusFlag, u8 *timer)
{
if (!(gFieldStatuses & statusFlag))
{
gFieldStatuses &= ~(STATUS_FIELD_MISTY_TERRAIN | STATUS_FIELD_GRASSY_TERRAIN | EFFECT_ELECTRIC_TERRAIN | EFFECT_PSYCHIC_TERRAIN);
gFieldStatuses &= ~(STATUS_FIELD_MISTY_TERRAIN | STATUS_FIELD_GRASSY_TERRAIN | STATUS_FIELD_ELECTRIC_TERRAIN | STATUS_FIELD_PSYCHIC_TERRAIN);
gFieldStatuses |= statusFlag;
if (GetBattlerHoldEffect(battler, TRUE) == HOLD_EFFECT_TERRAIN_EXTENDER)