mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2025-03-19 20:18:34 +01:00
Using IsBattlerTerrainAffected
This commit is contained in:
parent
ae8de0f07a
commit
62b6accbcc
@ -5194,8 +5194,7 @@ void SetTypeBeforeUsingMove(u16 move, u8 battlerAtk)
|
|||||||
}
|
}
|
||||||
else if (gBattleMoves[move].effect == EFFECT_TERRAIN_PULSE)
|
else if (gBattleMoves[move].effect == EFFECT_TERRAIN_PULSE)
|
||||||
{
|
{
|
||||||
if ((gFieldStatuses & STATUS_FIELD_TERRAIN_ANY)
|
if (IsBattlerTerrainAffected(battlerAtk, STATUS_FIELD_TERRAIN_ANY))
|
||||||
&& IsBattlerGrounded(battlerAtk))
|
|
||||||
{
|
{
|
||||||
if (gFieldStatuses & STATUS_FIELD_ELECTRIC_TERRAIN)
|
if (gFieldStatuses & STATUS_FIELD_ELECTRIC_TERRAIN)
|
||||||
gBattleStruct->dynamicMoveType = TYPE_ELECTRIC | 0x80;
|
gBattleStruct->dynamicMoveType = TYPE_ELECTRIC | 0x80;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user