Merge pull request #1858 from AsparagusEduardo/pret/doc/fateful

Rename eventLegal to modernFatefulEncounter
This commit is contained in:
GriffinR
2023-02-28 11:48:34 -05:00
committed by GitHub
12 changed files with 299 additions and 293 deletions
+9 -9
View File
@@ -2623,12 +2623,12 @@ void ConvertPokemonToBattleTowerPokemon(struct Pokemon *mon, struct BattleTowerP
GetMonData(mon, MON_DATA_NICKNAME, dest->nickname);
}
void CreateEventLegalMon(struct Pokemon *mon, u16 species, u8 level, u8 fixedIV, u8 hasFixedPersonality, u32 fixedPersonality, u8 otIdType, u32 fixedOtId)
static void CreateEventMon(struct Pokemon *mon, u16 species, u8 level, u8 fixedIV, u8 hasFixedPersonality, u32 fixedPersonality, u8 otIdType, u32 fixedOtId)
{
bool32 isEventLegal = TRUE;
bool32 isModernFatefulEncounter = TRUE;
CreateMon(mon, species, level, fixedIV, hasFixedPersonality, fixedPersonality, otIdType, fixedOtId);
SetMonData(mon, MON_DATA_EVENT_LEGAL, &isEventLegal);
SetMonData(mon, MON_DATA_MODERN_FATEFUL_ENCOUNTER, &isModernFatefulEncounter);
}
// If FALSE, should load this game's Deoxys form. If TRUE, should load normal Deoxys form
@@ -2763,14 +2763,14 @@ u16 GetUnionRoomTrainerClass(void)
return gFacilityClassToTrainerClass[gUnionRoomFacilityClasses[arrId]];
}
void CreateEventLegalEnemyMon(void)
void CreateEnemyEventMon(void)
{
s32 species = gSpecialVar_0x8004;
s32 level = gSpecialVar_0x8005;
s32 itemId = gSpecialVar_0x8006;
ZeroEnemyPartyMons();
CreateEventLegalMon(&gEnemyParty[0], species, level, USE_RANDOM_IVS, FALSE, 0, OT_ID_PLAYER_ID, 0);
CreateEventMon(&gEnemyParty[0], species, level, USE_RANDOM_IVS, FALSE, 0, OT_ID_PLAYER_ID, 0);
if (itemId)
{
u8 heldItem[2];
@@ -3957,8 +3957,8 @@ u32 GetBoxMonData(struct BoxPokemon *boxMon, s32 field, u8 *data)
case MON_DATA_UNUSED_RIBBONS:
retVal = substruct3->unusedRibbons;
break;
case MON_DATA_EVENT_LEGAL:
retVal = substruct3->eventLegal;
case MON_DATA_MODERN_FATEFUL_ENCOUNTER:
retVal = substruct3->modernFatefulEncounter;
break;
case MON_DATA_SPECIES_OR_EGG:
retVal = substruct0->species;
@@ -4341,8 +4341,8 @@ void SetBoxMonData(struct BoxPokemon *boxMon, s32 field, const void *dataArg)
case MON_DATA_UNUSED_RIBBONS:
SET8(substruct3->unusedRibbons);
break;
case MON_DATA_EVENT_LEGAL:
SET8(substruct3->eventLegal);
case MON_DATA_MODERN_FATEFUL_ENCOUNTER:
SET8(substruct3->modernFatefulEncounter);
break;
case MON_DATA_IVS:
{