mirror of
https://github.com/rh-hideout/pokeemerald-expansion.git
synced 2026-04-26 02:14:22 -05:00
Poltergeist Fix: Usable against Klutz targets and while Magic Room is in effect (#9256)
Co-authored-by: LinathanZel <linathan@DESKTOP-RVGNQ5E.localdomain>
This commit is contained in:
parent
150241913a
commit
13118676eb
|
|
@ -1090,10 +1090,6 @@ static enum CancelerResult CancelerMoveFailure(struct BattleContext *ctx)
|
|||
battleScript = BattleScript_ButItFailed;
|
||||
else // set fling item
|
||||
gBattleStruct->flingItem = gLastUsedItem = gBattleMons[ctx->battlerAtk].item;
|
||||
break;
|
||||
case EFFECT_POLTERGEIST:
|
||||
if (gFieldStatuses & STATUS_FIELD_MAGIC_ROOM)
|
||||
battleScript = BattleScript_ButItFailed;
|
||||
break;
|
||||
case EFFECT_FAIL_IF_NOT_ARG_TYPE:
|
||||
if (!IS_BATTLER_OF_TYPE(ctx->battlerAtk, GetMoveArgType(ctx->move)))
|
||||
|
|
@ -1274,8 +1270,7 @@ static enum CancelerResult CancelerMoveEffectFailureTarget(struct BattleContext
|
|||
}
|
||||
break;
|
||||
case EFFECT_POLTERGEIST:
|
||||
if (gBattleMons[battlerDef].item == ITEM_NONE
|
||||
|| GetBattlerAbility(battlerDef) == ABILITY_KLUTZ)
|
||||
if (gBattleMons[battlerDef].item == ITEM_NONE)
|
||||
{
|
||||
battleScript = BattleScript_ButItFailed;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user