Refactored SetMoveEffect Inner Focus Case (#3885)
* Rollbacked SetMoveEffect Inner Focus logic Co-authored-by: poetahto <walls.dk@gmail.com> * Refactored else if --------- Co-authored-by: poetahto <walls.dk@gmail.com>
This commit is contained in:
parent
9191c22c63
commit
58a93a544f
@ -3128,20 +3128,25 @@ void SetMoveEffect(bool32 primary, u32 certain)
|
||||
}
|
||||
break;
|
||||
case MOVE_EFFECT_FLINCH:
|
||||
if (battlerAbility == ABILITY_INNER_FOCUS
|
||||
&& (primary == TRUE || certain == MOVE_EFFECT_CERTAIN))
|
||||
if (battlerAbility == ABILITY_INNER_FOCUS)
|
||||
{
|
||||
gLastUsedAbility = ABILITY_INNER_FOCUS;
|
||||
gBattlerAbility = gEffectBattler;
|
||||
RecordAbilityBattle(gEffectBattler, ABILITY_INNER_FOCUS);
|
||||
gBattlescriptCurrInstr = BattleScript_FlinchPrevention;
|
||||
if (primary == TRUE || certain == MOVE_EFFECT_CERTAIN)
|
||||
{
|
||||
gLastUsedAbility = ABILITY_INNER_FOCUS;
|
||||
gBattlerAbility = gEffectBattler;
|
||||
RecordAbilityBattle(gEffectBattler, ABILITY_INNER_FOCUS);
|
||||
gBattlescriptCurrInstr = BattleScript_FlinchPrevention;
|
||||
} else
|
||||
{
|
||||
gBattlescriptCurrInstr++;
|
||||
}
|
||||
}
|
||||
else if (GetBattlerTurnOrderNum(gEffectBattler) > gCurrentTurnActionNumber
|
||||
&& !IsDynamaxed(gEffectBattler))
|
||||
&& !IsDynamaxed(gEffectBattler))
|
||||
{
|
||||
gBattleMons[gEffectBattler].status2 |= sStatusFlagsForMoveEffects[gBattleScripting.moveEffect];
|
||||
gBattleMons[gEffectBattler].status2 |= sStatusFlagsForMoveEffects[gBattleScripting.moveEffect];
|
||||
gBattlescriptCurrInstr++;
|
||||
}
|
||||
gBattlescriptCurrInstr++;
|
||||
break;
|
||||
case MOVE_EFFECT_UPROAR:
|
||||
if (!(gBattleMons[gEffectBattler].status2 & STATUS2_UPROAR))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user