diff options
author | Deokishisu <6993375+Deokishisu@users.noreply.github.com> | 2021-02-15 14:54:35 -0500 |
---|---|---|
committer | Deokishisu <6993375+Deokishisu@users.noreply.github.com> | 2021-02-15 14:54:35 -0500 |
commit | 7b2bf8c7e2249f66a04eabdbaeb2a8018855955f (patch) | |
tree | fd9c56262c4ef44569f313e5e067523a6a3546bf /src/battle_util.c | |
parent | b89c3e901e1de2f3513d74fa548373d82d3f26d0 (diff) |
Rename obedient/fatefulEncounter to eventLegal
Per discussion on pret, `obedient`/`fatefulEncounter` has been renamed to `eventLegal`, and all related functions and constants have been modified with this in mind.
Additionally, fixed some whitespace alignment issues in `script_cmd_table.h`, `pokemon.h`, and `tv.c` from the last commit.
Diffstat (limited to 'src/battle_util.c')
-rw-r--r-- | src/battle_util.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/battle_util.c b/src/battle_util.c index 7914356dc..2bf06f331 100644 --- a/src/battle_util.c +++ b/src/battle_util.c @@ -3949,14 +3949,14 @@ u8 GetMoveTarget(u16 move, u8 setTarget) return targetBattler; } -static bool32 IsNotEventMewOrDeoxys(u8 battlerId) +static bool32 IsNotEventLegalMewOrDeoxys(u8 battlerId) { if (GetBattlerSide(battlerId) == B_SIDE_OPPONENT) return TRUE; if (GetMonData(&gPlayerParty[gBattlerPartyIndexes[battlerId]], MON_DATA_SPECIES, NULL) != SPECIES_DEOXYS && GetMonData(&gPlayerParty[gBattlerPartyIndexes[battlerId]], MON_DATA_SPECIES, NULL) != SPECIES_MEW) return TRUE; - return GetMonData(&gPlayerParty[gBattlerPartyIndexes[battlerId]], MON_DATA_FATEFUL_ENCOUNTER, NULL); + return GetMonData(&gPlayerParty[gBattlerPartyIndexes[battlerId]], MON_DATA_EVENT_LEGAL, NULL); } u8 IsMonDisobedient(void) @@ -3970,7 +3970,7 @@ u8 IsMonDisobedient(void) if (GetBattlerSide(gBattlerAttacker) == B_SIDE_OPPONENT) return 0; - if (IsNotEventMewOrDeoxys(gBattlerAttacker)) // only if species is Mew or Deoxys + if (IsNotEventLegalMewOrDeoxys(gBattlerAttacker)) // only if species is Mew or Deoxys { if (gBattleTypeFlags & BATTLE_TYPE_INGAME_PARTNER && GetBattlerPosition(gBattlerAttacker) == 2) return 0; |