mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2025-02-21 11:43:37 +01:00
Fix Simple Beam
- No longer freezes the game - Now fails if the target already has simple - Explicitly checks and changes the target's ability instead of gActiveBattler's ability
This commit is contained in:
parent
2119c33989
commit
a6198e5d46
@ -7910,15 +7910,15 @@ static void Cmd_various(void)
|
|||||||
gBattlescriptCurrInstr += 7;
|
gBattlescriptCurrInstr += 7;
|
||||||
return;
|
return;
|
||||||
case VARIOUS_SET_SIMPLE_BEAM:
|
case VARIOUS_SET_SIMPLE_BEAM:
|
||||||
if (IsEntrainmentTargetOrSimpleBeamBannedAbility(gBattleMons[gActiveBattler].ability))
|
if (IsEntrainmentTargetOrSimpleBeamBannedAbility(gBattleMons[gBattlerTarget].ability)
|
||||||
|
|| gBattleMons[gBattlerTarget].ability == ABILITY_SIMPLE)
|
||||||
{
|
{
|
||||||
gBattlescriptCurrInstr = T1_READ_PTR(gBattlescriptCurrInstr + 3);
|
gBattlescriptCurrInstr = T1_READ_PTR(gBattlescriptCurrInstr + 3);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
gBattleMons[gActiveBattler].ability = ABILITY_SIMPLE;
|
gBattleMons[gBattlerTarget].ability = ABILITY_SIMPLE;
|
||||||
gBattlescriptCurrInstr += 7;
|
gBattlescriptCurrInstr += 7;
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
case VARIOUS_TRY_ENTRAINMENT:
|
case VARIOUS_TRY_ENTRAINMENT:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user