From db41c75d26dae7315ca5ca89629eb07b78370e45 Mon Sep 17 00:00:00 2001 From: Eduardo Quezada Date: Sat, 15 Mar 2025 10:16:21 -0300 Subject: [PATCH] Ribbon Documentation + Footstep House scripts (#427) * Footstep house types and script commands * Generated ribbons + messages * Get Friendship + Get/Set Ribbon map scripts * First non egg in party * Standarized "ribbonID" as "monDataParam" and "ribbonNum" as "ribbonID" --- asm/macros/scrcmd.inc | 32 +- generated/game_records.txt | 2 +- generated/meson.build | 1 + generated/ribbons.txt | 81 +++ .../pokemon_summary_screen/main.h | 4 +- include/constants/footstep_house.h | 11 + include/constants/savedata/vars_flags.h | 2 + include/overlay005/footprint_type.h | 7 + include/overlay005/ov5_021F0E84.h | 7 - include/ribbon.h | 95 +--- include/unk_0204CFFC.h | 8 +- include/unk_0205DFC4.h | 2 +- include/unk_0206CCB0.h | 2 +- platinum.us/main.lsf | 2 +- .../scripts_celestic_town_pokecenter_1f.s | 4 +- .../scripts_eterna_city_pokecenter_1f.s | 4 +- res/field/scripts/scripts_footstep_house.s | 498 +++++++++-------- .../scripts_hearthome_city_pokemon_fan_club.s | 4 +- .../scripts_pastoria_city_northeast_house.s | 2 +- .../scripts_resort_area_ribbon_syndicate_1f.s | 15 +- .../scripts_resort_area_ribbon_syndicate_2f.s | 2 +- .../scripts_route_210_grandma_wilma_house.s | 2 +- .../scripts/scripts_route_228_north_house.s | 2 +- .../scripts_solaceon_town_northeast_house.s | 2 +- .../scripts_sunyshore_city_northeast_house.s | 31 +- res/field/scripts/scripts_sunyshore_market.s | 7 +- res/text/footstep_house.gmm | 102 ++-- .../pokemon_summary_screen/main.c | 14 +- .../pokemon_summary_screen/sprites.c | 10 +- .../pokemon_summary_screen/window.c | 4 +- src/game_records.c | 2 +- src/meson.build | 2 +- src/overlay005/footprint_type.c | 524 ++++++++++++++++++ src/overlay005/ov5_021F0E84.c | 523 ----------------- src/overlay006/wild_encounters.c | 10 +- src/ribbon.c | 196 +++---- src/scrcmd.c | 38 +- src/unk_0204B830.c | 20 +- src/unk_0204CFFC.c | 64 +-- src/unk_0205DFC4.c | 15 +- src/unk_0206CCB0.c | 16 +- 41 files changed, 1196 insertions(+), 1173 deletions(-) create mode 100644 generated/ribbons.txt create mode 100644 include/constants/footstep_house.h create mode 100644 include/overlay005/footprint_type.h delete mode 100644 include/overlay005/ov5_021F0E84.h create mode 100644 src/overlay005/footprint_type.c delete mode 100644 src/overlay005/ov5_021F0E84.c diff --git a/asm/macros/scrcmd.inc b/asm/macros/scrcmd.inc index 5d7bf828cc..e19eef10c9 100644 --- a/asm/macros/scrcmd.inc +++ b/asm/macros/scrcmd.inc @@ -2408,10 +2408,10 @@ .short \upperBound .endm - .macro ScrCmd_1B9 arg0, arg1 + .macro GetPartyMonFriendship destVar, partySlot .short 441 - .short \arg0 - .short \arg1 + .short \destVar + .short \partySlot .endm .macro ScrCmd_1BA arg0, arg1 @@ -3071,17 +3071,17 @@ .short \arg0 .endm - .macro ScrCmd_230 arg0, arg1, arg2 + .macro GetPartyMonRibbon destVar, partySlot, ribbonID .short 560 - .short \arg0 - .short \arg1 - .short \arg2 + .short \destVar + .short \partySlot + .short \ribbonID .endm - .macro ScrCmd_231 arg0, arg1 + .macro SetPartyMonRibbon partySlot, ribbonID .short 561 - .short \arg0 - .short \arg1 + .short \partySlot + .short \ribbonID .endm .macro ScrCmd_232 arg0, arg1 @@ -3144,11 +3144,11 @@ .short \arg0 .endm - .macro ScrCmd_23A arg0, arg1, arg2 + .macro GetPartyMonFootprintType hasPrintVar, printTypeVar, partySlot .short 570 - .short \arg0 - .short \arg1 - .short \arg2 + .short \hasPrintVar + .short \printTypeVar + .short \partySlot .endm .macro ScrCmd_23B arg0 @@ -3226,9 +3226,9 @@ .short \arg0 .endm - .macro ScrCmd_247 arg0 + .macro GetFirstNonEggInParty partySlot .short 583 - .short \arg0 + .short \partySlot .endm .macro ScrCmd_248 arg0, arg1, arg2 diff --git a/generated/game_records.txt b/generated/game_records.txt index 5c9a776102..9508856029 100644 --- a/generated/game_records.txt +++ b/generated/game_records.txt @@ -114,7 +114,7 @@ RECORD_UNK_112 RECORD_UNK_113 RECORD_UNK_114 RECORD_UNK_115 -RECORD_UNK_116 +RECORD_CHECKED_FOOTPRINTS RECORD_UNK_117 RECORD_UNK_118 RECORD_UNK_119 diff --git a/generated/meson.build b/generated/meson.build index b629e124f6..6001cc7ec9 100644 --- a/generated/meson.build +++ b/generated/meson.build @@ -73,6 +73,7 @@ metang_generators = { 'pokemon_contest_types': { 'type': 'enum', 'tag': 'PokemonContestType' }, 'pokemon_types': { 'type': 'enum', 'tag': 'PokemonType' }, 'poketch_apps': { 'type': 'enum', 'tag': 'PoketchAppID' }, + 'ribbons': { 'type': 'enum', 'tag': 'RibbonID' }, 'roaming_slots': { 'type': 'enum', 'tag': 'RoamingSlot' }, 'save_types': { 'type': 'enum', 'tag': 'SaveType' }, 'sdat': { 'type': 'enum', 'tag': 'SDATID' }, diff --git a/generated/ribbons.txt b/generated/ribbons.txt new file mode 100644 index 0000000000..40b8e473e6 --- /dev/null +++ b/generated/ribbons.txt @@ -0,0 +1,81 @@ +RIBBON_HOENN_CHAMPION +RIBBON_HOENN_COOL +RIBBON_HOENN_COOL_SUPER +RIBBON_HOENN_COOL_HYPER +RIBBON_HOENN_COOL_MASTER +RIBBON_HOENN_BEAUTY +RIBBON_HOENN_BEAUTY_SUPER +RIBBON_HOENN_BEAUTY_HYPER +RIBBON_HOENN_BEAUTY_MASTER +RIBBON_HOENN_CUTE +RIBBON_HOENN_CUTE_SUPER +RIBBON_HOENN_CUTE_HYPER +RIBBON_HOENN_CUTE_MASTER +RIBBON_HOENN_SMART +RIBBON_HOENN_SMART_SUPER +RIBBON_HOENN_SMART_HYPER +RIBBON_HOENN_SMART_MASTER +RIBBON_HOENN_TOUGH +RIBBON_HOENN_TOUGH_SUPER +RIBBON_HOENN_TOUGH_HYPER +RIBBON_HOENN_TOUGH_MASTER +RIBBON_HOENN_WINNING +RIBBON_HOENN_VICTORY +RIBBON_HOENN_ARTIST +RIBBON_HOENN_EFFORT +RIBBON_HOENN_MARINE +RIBBON_HOENN_LAND +RIBBON_HOENN_SKY +RIBBON_HOENN_COUNTRY +RIBBON_HOENN_NATIONAL +RIBBON_HOENN_EARTH +RIBBON_HOENN_WORLD +RIBBON_SINNOH_CHAMP +RIBBON_COOL +RIBBON_COOL_GREAT +RIBBON_COOL_ULTRA +RIBBON_COOL_MASTER +RIBBON_BEAUTY +RIBBON_BEAUTY_GREAT +RIBBON_BEAUTY_ULTRA +RIBBON_BEAUTY_MASTER +RIBBON_CUTE +RIBBON_CUTE_GREAT +RIBBON_CUTE_ULTRA +RIBBON_CUTE_MASTER +RIBBON_SMART +RIBBON_SMART_GREAT +RIBBON_SMART_ULTRA +RIBBON_SMART_MASTER +RIBBON_TOUGH +RIBBON_TOUGH_GREAT +RIBBON_TOUGH_ULTRA +RIBBON_TOUGH_MASTER +RIBBON_ABILITY +RIBBON_GREAT_ABILITY +RIBBON_DOUBLE_ABILITY +RIBBON_MULTI_ABILITY +RIBBON_PAIR_ABILITY +RIBBON_WORLD_ABILITY +RIBBON_ALERT +RIBBON_SHOCK +RIBBON_DOWNCAST +RIBBON_CARELESS +RIBBON_RELAX +RIBBON_SNOOZE +RIBBON_SMILE +RIBBON_GORGEOUS +RIBBON_ROYAL +RIBBON_GORGEOUS_ROYAL +RIBBON_FOOTPRINT +RIBBON_RECORD +RIBBON_HISTORY +RIBBON_LEGEND +RIBBON_RED +RIBBON_GREEN +RIBBON_BLUE +RIBBON_FESTIVAL +RIBBON_CARNIVAL +RIBBON_CLASSIC +RIBBON_PREMIER +RIBBON_MAX diff --git a/include/applications/pokemon_summary_screen/main.h b/include/applications/pokemon_summary_screen/main.h index 8ea0e95309..9b9e96fe54 100644 --- a/include/applications/pokemon_summary_screen/main.h +++ b/include/applications/pokemon_summary_screen/main.h @@ -465,7 +465,7 @@ typedef struct PokemonSummaryScreen { u8 ribbonCol; u8 ribbonRow; u8 ribbonMax; - u8 ribbonNum; + u8 ribbonID; } PokemonSummaryScreen; BOOL PokemonSummaryScreen_ShowContestData(SaveData *saveData); @@ -473,7 +473,7 @@ void PokemonSummaryScreen_FlagVisiblePages(PokemonSummary *summary, const u8 *pa u8 PokemonSummaryScreen_PageIsVisble(PokemonSummaryScreen *summaryScreen, u32 page); u8 PokemonSummaryScreen_CountVisiblePages(PokemonSummaryScreen *summaryScreen); void *PokemonSummaryScreen_MonData(PokemonSummaryScreen *summaryScreen); -u8 PokemonSummaryScreen_RibbonNumAt(PokemonSummaryScreen *summaryScreen, u8 col); +u8 PokemonSummaryScreen_RibbonIDAt(PokemonSummaryScreen *summaryScreen, u8 col); void PokemonSummaryScreen_SetPlayerProfile(PokemonSummary *summary, const TrainerInfo *trainerInfo); u32 PokemonSummaryScreen_StatusIconChar(void); u32 PokemonSummaryScreen_StatusIconPltt(void); diff --git a/include/constants/footstep_house.h b/include/constants/footstep_house.h new file mode 100644 index 0000000000..4dfe08c9ed --- /dev/null +++ b/include/constants/footstep_house.h @@ -0,0 +1,11 @@ +#ifndef POKEPLATINUM_CONSTANTS_FOOTSTEP_HOUSE_H +#define POKEPLATINUM_CONSTANTS_FOOTSTEP_HOUSE_H + +#define FOOTPRINT_TYPE_NONE 0 +#define FOOTPRINT_TYPE_CUTE 1 +#define FOOTPRINT_TYPE_TOUGH 2 +#define FOOTPRINT_TYPE_SCARY 3 +#define FOOTPRINT_TYPE_SLOW 4 +#define FOOTPRINT_TYPE_SILENT 5 + +#endif // POKEPLATINUM_CONSTANTS_FOOTSTEP_HOUSE_H diff --git a/include/constants/savedata/vars_flags.h b/include/constants/savedata/vars_flags.h index d47c1e4ea6..e7cdac1de1 100644 --- a/include/constants/savedata/vars_flags.h +++ b/include/constants/savedata/vars_flags.h @@ -7,6 +7,8 @@ #define FLAG_TEAM_GALACTIC_LEFT_LAKE_VERITY 0x00BA +#define FLAG_TALKED_TO_DR_FOOTSTEP 0x00F9 + #define FLAG_MESPRIT_CAUGHT 0x0125 #define FLAG_AZELF_CAUGHT 0x0126 #define FLAG_UXIE_CAUGHT 0x0127 diff --git a/include/overlay005/footprint_type.h b/include/overlay005/footprint_type.h new file mode 100644 index 0000000000..9685285e6a --- /dev/null +++ b/include/overlay005/footprint_type.h @@ -0,0 +1,7 @@ +#ifndef POKEPLATINUM_FOOTPRINT_TYPE_H +#define POKEPLATINUM_FOOTPRINT_TYPE_H + +u16 FootprintType_GetTypeFromSpecies(u16 species); +u16 FootprintType_SpeciesHasPrint(u16 species, u16 form); + +#endif // POKEPLATINUM_FOOTPRINT_TYPE_H diff --git a/include/overlay005/ov5_021F0E84.h b/include/overlay005/ov5_021F0E84.h deleted file mode 100644 index f3621e68d4..0000000000 --- a/include/overlay005/ov5_021F0E84.h +++ /dev/null @@ -1,7 +0,0 @@ -#ifndef POKEPLATINUM_OV5_021F0E84_H -#define POKEPLATINUM_OV5_021F0E84_H - -u16 ov5_021F0E84(u16 param0); -u16 ov5_021F0E90(u16 param0, u16 param1); - -#endif // POKEPLATINUM_OV5_021F0E84_H diff --git a/include/ribbon.h b/include/ribbon.h index a711ab9f99..e6aead767d 100644 --- a/include/ribbon.h +++ b/include/ribbon.h @@ -1,102 +1,21 @@ #ifndef POKEPLATINUM_RIBBON_H #define POKEPLATINUM_RIBBON_H -enum RibbonNum { - RIBBON_HOENN_CHAMPION = 0, - RIBBON_HOENN_COOL, - RIBBON_HOENN_COOL_SUPER, - RIBBON_HOENN_COOL_HYPER, - RIBBON_HOENN_COOL_MASTER, - RIBBON_HOENN_BEAUTY, - RIBBON_HOENN_BEAUTY_SUPER, - RIBBON_HOENN_BEAUTY_HYPER, - RIBBON_HOENN_BEAUTY_MASTER, - RIBBON_HOENN_CUTE, - RIBBON_HOENN_CUTE_SUPER, - RIBBON_HOENN_CUTE_HYPER, - RIBBON_HOENN_CUTE_MASTER, - RIBBON_HOENN_SMART, - RIBBON_HOENN_SMART_SUPER, - RIBBON_HOENN_SMART_HYPER, - RIBBON_HOENN_SMART_MASTER, - RIBBON_HOENN_TOUGH, - RIBBON_HOENN_TOUGH_SUPER, - RIBBON_HOENN_TOUGH_HYPER, - RIBBON_HOENN_TOUGH_MASTER, - RIBBON_HOENN_WINNING, - RIBBON_HOENN_VICTORY, - RIBBON_HOENN_ARTIST, - RIBBON_HOENN_EFFORT, - RIBBON_HOENN_MARINE, - RIBBON_HOENN_LAND, - RIBBON_HOENN_SKY, - RIBBON_HOENN_COUNTRY, - RIBBON_HOENN_NATIONAL, - RIBBON_HOENN_EARTH, - RIBBON_HOENN_WORLD, - RIBBON_SINNOH_CHAMP, - RIBBON_COOL, - RIBBON_COOL_GREAT, - RIBBON_COOL_ULTRA, - RIBBON_COOL_MASTER, - RIBBON_BEAUTY, - RIBBON_BEAUTY_GREAT, - RIBBON_BEAUTY_ULTRA, - RIBBON_BEAUTY_MASTER, - RIBBON_CUTE, - RIBBON_CUTE_GREAT, - RIBBON_CUTE_ULTRA, - RIBBON_CUTE_MASTER, - RIBBON_SMART, - RIBBON_SMART_GREAT, - RIBBON_SMART_ULTRA, - RIBBON_SMART_MASTER, - RIBBON_TOUGH, - RIBBON_TOUGH_GREAT, - RIBBON_TOUGH_ULTRA, - RIBBON_TOUGH_MASTER, - RIBBON_ABILITY, - RIBBON_GREAT_ABILITY, - RIBBON_DOUBLE_ABILITY, - RIBBON_MULTI_ABILITY, - RIBBON_PAIR_ABILITY, - RIBBON_WORLD_ABILITY, - RIBBON_ALERT, - RIBBON_SHOCK, - RIBBON_DOWNCAST, - RIBBON_CARELESS, - RIBBON_RELAX, - RIBBON_SNOOZE, - RIBBON_SMILE, - RIBBON_GORGEOUS, - RIBBON_ROYAL, - RIBBON_GORGEOUS_ROYAL, - RIBBON_FOOTPRINT, - RIBBON_RECORD, - RIBBON_HISTORY, - RIBBON_LEGEND, - RIBBON_RED, - RIBBON_GREEN, - RIBBON_BLUE, - RIBBON_FESTIVAL, - RIBBON_CARNIVAL, - RIBBON_CLASSIC, - RIBBON_PREMIER, +#include "generated/ribbons.h" - RIBBON_MAX -}; +#include "pokedex.h" enum RibbonDataField { - RIBBON_DATA_RIBBON_ID = 0, + RIBBON_DATA_MON_DATA_PARAM = 0, RIBBON_DATA_SPRITE_ID, RIBBON_DATA_PALETTE_NUM, RIBBON_DATA_NAME_ID, RIBBON_DATA_DESCRIPTION_ID, }; -u32 Ribbon_GetData(u8 ribbonNum, enum RibbonDataField field); -u32 PokemonSummaryScreen_GetRibbonDescriptionID(u8 *ribbons, u8 ribbonNum); -u8 Ribbon_TryGetSpecialDescriptionID(u8 ribbonNum); -u16 Ribbon_RibbonIDToNameID(u32 ribbonID); +u32 Ribbon_GetData(u8 ribbonID, enum RibbonDataField field); +u32 PokemonSummaryScreen_GetRibbonDescriptionID(u8 *ribbons, u8 ribbonID); +u8 Ribbon_TryGetSpecialDescriptionID(u8 ribbonID); +u16 Ribbon_MonDataParamToNameID(enum PokemonDataParam monDataParam); #endif // POKEPLATINUM_RIBBON_H diff --git a/include/unk_0204CFFC.h b/include/unk_0204CFFC.h index c1247fb2b2..7b3fbf87cc 100644 --- a/include/unk_0204CFFC.h +++ b/include/unk_0204CFFC.h @@ -15,11 +15,11 @@ BOOL ScrCmd_1F6(ScriptContext *param0); BOOL ScrCmd_278(ScriptContext *param0); BOOL ScrCmd_212(ScriptContext *param0); BOOL ScrCmd_213(ScriptContext *param0); -BOOL ScrCmd_1B9(ScriptContext *param0); +BOOL ScrCmd_GetFriendshipByPartySlot(ScriptContext *ctx); BOOL ScrCmd_1BA(ScriptContext *param0); BOOL ScrCmd_1BB(ScriptContext *param0); BOOL ScrCmd_281(ScriptContext *param0); -BOOL ScrCmd_247(ScriptContext *param0); +BOOL ScrCmd_GetFirstNonEggInParty(ScriptContext *ctx); BOOL ScrCmd_248(ScriptContext *param0); BOOL ScrCmd_GetPartyCount(ScriptContext *ctx); BOOL ScrCmd_GetPartyCountHatched(ScriptContext *ctx); @@ -38,8 +38,8 @@ BOOL ScrCmd_2CB(ScriptContext *param0); BOOL ScrCmd_2DD(ScriptContext *param0); BOOL ScrCmd_22E(ScriptContext *param0); BOOL ScrCmd_22F(ScriptContext *param0); -BOOL ScrCmd_230(ScriptContext *param0); -BOOL ScrCmd_231(ScriptContext *param0); +BOOL ScrCmd_GetPartyMonRibbon(ScriptContext *ctx); +BOOL ScrCmd_SetPartyMonRibbon(ScriptContext *ctx); BOOL ScrCmd_2B7(ScriptContext *param0); int ScrCmd_0A0(ScriptContext *param0); BOOL ScrCmd_31C(ScriptContext *param0); diff --git a/include/unk_0205DFC4.h b/include/unk_0205DFC4.h index cd73f1f464..112dfa7c35 100644 --- a/include/unk_0205DFC4.h +++ b/include/unk_0205DFC4.h @@ -10,7 +10,7 @@ u16 sub_0205DFC4(u32 param0); u16 sub_0205E060(u16 param0); u16 sub_0205E078(u16 param0, u16 param1); u16 sub_0205E0E4(u16 param0, u16 param1); -u16 sub_0205E1B4(SaveData *param0); +u16 SaveData_GetFirstNonEggInParty(SaveData *saveData); BOOL HasAllLegendaryTitansInParty(SaveData *param0); void sub_0205E318(FieldTask *param0, MapObject *param1, u16 param2, u16 param3, u16 param4, u16 param5); void sub_0205E3F4(FieldTask *param0, MapObject *param1, u16 param2, u16 param3); diff --git a/include/unk_0206CCB0.h b/include/unk_0206CCB0.h index 55cb6b162b..04c8affff3 100644 --- a/include/unk_0206CCB0.h +++ b/include/unk_0206CCB0.h @@ -52,7 +52,7 @@ void sub_0206DB5C(FieldSystem *fieldSystem, u8 param1); void sub_0206DBB0(SaveData *param0, u32 param1, Pokemon *param2, BOOL param3); void sub_0206DC6C(FieldSystem *fieldSystem, u32 param1, Pokemon *param2); void sub_0206DD38(FieldSystem *fieldSystem, u32 param1, u32 param2, u32 param3); -void sub_0206DDB8(SaveData *param0, Pokemon *param1, u32 param2); +void sub_0206DDB8(SaveData *saveData, Pokemon *mon, u32 monDataParam); void sub_0206DEEC(FieldSystem *fieldSystem, u16 param1, u16 param2); void sub_0206DF60(FieldSystem *fieldSystem, u16 param1); void sub_0206DFE0(SaveData *param0); diff --git a/platinum.us/main.lsf b/platinum.us/main.lsf index 0de804e803..f951fff08e 100644 --- a/platinum.us/main.lsf +++ b/platinum.us/main.lsf @@ -519,7 +519,7 @@ Overlay overlay5 Object main.nef.p/src_overlay005_ov5_021F067C.c.o Object main.nef.p/src_overlay005_ov5_021F0824.c.o Object main.nef.p/src_overlay005_ov5_021F08CC.c.o - Object main.nef.p/src_overlay005_ov5_021F0E84.c.o + Object main.nef.p/src_overlay005_footprint_type.c.o Object main.nef.p/src_overlay005_ov5_021F0EB0.c.o Object main.nef.p/src_overlay005_ov5_021F101C.c.o Object main.nef.p/src_overlay005_ov5_021F10E8.c.o diff --git a/res/field/scripts/scripts_celestic_town_pokecenter_1f.s b/res/field/scripts/scripts_celestic_town_pokecenter_1f.s index eae12645e4..c1cfce1069 100644 --- a/res/field/scripts/scripts_celestic_town_pokecenter_1f.s +++ b/res/field/scripts/scripts_celestic_town_pokecenter_1f.s @@ -40,8 +40,8 @@ _0044: FacePlayer GoToIfSet 0xAA1, _00C0 Message 2 - ScrCmd_247 0x8000 - ScrCmd_1B9 0x800C, 0x8000 + GetFirstNonEggInParty 0x8000 + GetPartyMonFriendship 0x800C, 0x8000 GoToIfGe 0x800C, 150, _0084 GoToIfGe 0x800C, 50, _00CB GoTo _00D6 diff --git a/res/field/scripts/scripts_eterna_city_pokecenter_1f.s b/res/field/scripts/scripts_eterna_city_pokecenter_1f.s index 869cb6aafc..efface4d35 100644 --- a/res/field/scripts/scripts_eterna_city_pokecenter_1f.s +++ b/res/field/scripts/scripts_eterna_city_pokecenter_1f.s @@ -63,10 +63,10 @@ _007D: GoToIfEq 0x4002, 1, _00F4 CheckPoketchAppRegistered POKETCH_APPID_FRIENDSHIPCHECKER, 0x800C GoToIfEq 0x800C, 0, _00D9 - ScrCmd_247 0x8000 + GetFirstNonEggInParty 0x8000 BufferPartyMonSpecies 0, 0x8000 Message 6 - ScrCmd_1B9 0x800C, 0x8000 + GetPartyMonFriendship 0x800C, 0x8000 GoToIfGe 0x800C, 120, _00FF GoToIfGe 0x800C, 70, _010A GoTo _0115 diff --git a/res/field/scripts/scripts_footstep_house.s b/res/field/scripts/scripts_footstep_house.s index cc7e6b55d3..13e10967b4 100644 --- a/res/field/scripts/scripts_footstep_house.s +++ b/res/field/scripts/scripts_footstep_house.s @@ -1,37 +1,43 @@ #include "macros/scrcmd.inc" #include "res/text/bank/footstep_house.h" +#include "constants/footstep_house.h" +#include "generated/ribbons.h" + +#define VAR_HAS_PRINT 0x8000 +#define VAR_FOOTPRINT_TYPE 0x8001 +#define VAR_PARTY_SLOT 0x8002 .data ScriptEntry _000A - ScriptEntry _0010 + ScriptEntry FootstepHouse_DrFootstep ScriptEntryEnd _000A: SetFlag 0x9ED End -_0010: +FootstepHouse_DrFootstep: PlayFanfare SEQ_SE_CONFIRM LockAll FacePlayer - ScrCmd_247 0x8002 - BufferPartyMonSpecies 0, 0x8002 + GetFirstNonEggInParty VAR_PARTY_SLOT + BufferPartyMonSpecies 0, VAR_PARTY_SLOT BufferPlayerName 1 - BufferPartyMonNickname 2, 0x8002 - ScrCmd_23A 0x8000, 0x8001, 0x8002 - GoToIfSet 249, _004B - SetFlag 249 - Message 0 + BufferPartyMonNickname 2, VAR_PARTY_SLOT + GetPartyMonFootprintType VAR_HAS_PRINT, VAR_FOOTPRINT_TYPE, VAR_PARTY_SLOT + GoToIfSet FLAG_TALKED_TO_DR_FOOTSTEP, FootstepHouse_CheckFeelingsAgain + SetFlag FLAG_TALKED_TO_DR_FOOTSTEP + Message footstep_house_pokemon_are_quite_easy_for_me_to_read CloseMessage - GoTo _0056 + GoTo FootstepHouse_FadeScreen -_004B: - Message 1 +FootstepHouse_CheckFeelingsAgain: + Message footstep_house_do_you_want_to_check_the_feelings_of_your_pokemon_again CloseMessage - GoTo _0056 + GoTo FootstepHouse_FadeScreen -_0056: +FootstepHouse_FadeScreen: FadeScreen 6, 1, 0, 0 WaitFadeScreen WaitTime 40, 0x800C @@ -39,8 +45,8 @@ _0056: WaitFadeScreen Call _008A WaitTime 20, 0x800C - IncrementGameRecord RECORD_UNK_116 - GoTo _0150 + IncrementGameRecord RECORD_CHECKED_FOOTPRINTS + GoTo FootstepHouse_CheckType _008A: GetPlayerMapPos 0x8005, 0x8006 @@ -96,347 +102,347 @@ _0144: WaitMovement Return -_0150: - GoToIfEq 0x8001, 1, _018A - GoToIfEq 0x8001, 2, _019D - GoToIfEq 0x8001, 3, _01B0 - GoToIfEq 0x8001, 4, _01C3 - GoTo _0574 +FootstepHouse_CheckType: + GoToIfEq VAR_FOOTPRINT_TYPE, FOOTPRINT_TYPE_CUTE, FootstepHouse_CuteType + GoToIfEq VAR_FOOTPRINT_TYPE, FOOTPRINT_TYPE_TOUGH, FootstepHouse_ToughType + GoToIfEq VAR_FOOTPRINT_TYPE, FOOTPRINT_TYPE_SCARY, FootstepHouse_ScaryType + GoToIfEq VAR_FOOTPRINT_TYPE, FOOTPRINT_TYPE_SLOW, FootstepHouse_SlowType + GoTo FootstepHouse_VoicelessType -_018A: - GoToIfEq 0x8000, 1, _01D6 - GoTo _0216 +FootstepHouse_CuteType: + GoToIfEq VAR_HAS_PRINT, TRUE, FootstepHouse_CuteType_WithPrint + GoTo FootstepHouse_CuteType_WithoutPrint -_019D: - GoToIfEq 0x8000, 1, _0256 - GoTo _0296 +FootstepHouse_ToughType: + GoToIfEq VAR_HAS_PRINT, TRUE, FootstepHouse_ToughType_WithPrint + GoTo FootstepHouse_ToughType_WithoutPrint -_01B0: - GoToIfEq 0x8000, 1, _02D6 - GoTo _0316 +FootstepHouse_ScaryType: + GoToIfEq VAR_HAS_PRINT, TRUE, FootstepHouse_ScaryType_WithPrint + GoTo FootstepHouse_ScaryType_WithoutPrint -_01C3: - GoToIfEq 0x8000, 1, _0356 - GoTo _0396 +FootstepHouse_SlowType: + GoToIfEq VAR_HAS_PRINT, TRUE, FootstepHouse_SlowType_WithPrint + GoTo FootstepHouse_SlowType_WithoutPrint -_01D6: - ScrCmd_1B9 0x800C, 0x8002 - GoToIfGe 0x800C, 0xFF, _03FA - GoToIfGe 0x800C, 200, _03F1 - GoToIfGe 0x800C, 150, _03E8 - GoToIfGe 0x800C, 70, _03DF - GoTo _03D6 +FootstepHouse_CuteType_WithPrint: + GetPartyMonFriendship 0x800C, VAR_PARTY_SLOT + GoToIfGe 0x800C, 0xFF, FootstepHouse_CuteType_WithPrint_Level5 + GoToIfGe 0x800C, 200, FootstepHouse_CuteType_WithPrint_Level4 + GoToIfGe 0x800C, 150, FootstepHouse_CuteType_WithPrint_Level3 + GoToIfGe 0x800C, 70, FootstepHouse_CuteType_WithPrint_Level2 + GoTo FootstepHouse_CuteType_WithPrint_Level1 -_0216: - ScrCmd_1B9 0x800C, 0x8002 - GoToIfGe 0x800C, 0xFF, _0427 - GoToIfGe 0x800C, 200, _041E - GoToIfGe 0x800C, 150, _0415 - GoToIfGe 0x800C, 70, _040C - GoTo _0403 +FootstepHouse_CuteType_WithoutPrint: + GetPartyMonFriendship 0x800C, VAR_PARTY_SLOT + GoToIfGe 0x800C, 0xFF, FootstepHouse_CuteType_WithoutPrint_Level5 + GoToIfGe 0x800C, 200, FootstepHouse_CuteType_WithoutPrint_Level4 + GoToIfGe 0x800C, 150, FootstepHouse_CuteType_WithoutPrint_Level3 + GoToIfGe 0x800C, 70, FootstepHouse_CuteType_WithoutPrint_Level2 + GoTo FootstepHouse_CuteType_WithoutPrint_Level1 -_0256: - ScrCmd_1B9 0x800C, 0x8002 - GoToIfGe 0x800C, 0xFF, _0454 - GoToIfGe 0x800C, 200, _044B - GoToIfGe 0x800C, 150, _0442 - GoToIfGe 0x800C, 70, _0439 - GoTo _0430 +FootstepHouse_ToughType_WithPrint: + GetPartyMonFriendship 0x800C, VAR_PARTY_SLOT + GoToIfGe 0x800C, 0xFF, FootstepHouse_ToughType_WithPrint_Level5 + GoToIfGe 0x800C, 200, FootstepHouse_ToughType_WithPrint_Level4 + GoToIfGe 0x800C, 150, FootstepHouse_ToughType_WithPrint_Level3 + GoToIfGe 0x800C, 70, FootstepHouse_ToughType_WithPrint_Level2 + GoTo FootstepHouse_ToughType_WithPrint_Level1 -_0296: - ScrCmd_1B9 0x800C, 0x8002 - GoToIfGe 0x800C, 0xFF, _0481 - GoToIfGe 0x800C, 200, _0478 - GoToIfGe 0x800C, 150, _046F - GoToIfGe 0x800C, 70, _0466 - GoTo _045D +FootstepHouse_ToughType_WithoutPrint: + GetPartyMonFriendship 0x800C, VAR_PARTY_SLOT + GoToIfGe 0x800C, 0xFF, FootstepHouse_ToughType_WithoutPrint_Level5 + GoToIfGe 0x800C, 200, FootstepHouse_ToughType_WithoutPrint_Level4 + GoToIfGe 0x800C, 150, FootstepHouse_ToughType_WithoutPrint_Level3 + GoToIfGe 0x800C, 70, FootstepHouse_ToughType_WithoutPrint_Level2 + GoTo FootstepHouse_ToughType_WithoutPrint_Level1 -_02D6: - ScrCmd_1B9 0x800C, 0x8002 - GoToIfGe 0x800C, 0xFF, _04AE - GoToIfGe 0x800C, 200, _04A5 - GoToIfGe 0x800C, 150, _049C - GoToIfGe 0x800C, 70, _0493 - GoTo _048A +FootstepHouse_ScaryType_WithPrint: + GetPartyMonFriendship 0x800C, VAR_PARTY_SLOT + GoToIfGe 0x800C, 0xFF, FootstepHouse_ScaryType_WithPrint_Level5 + GoToIfGe 0x800C, 200, FootstepHouse_ScaryType_WithPrint_Level4 + GoToIfGe 0x800C, 150, FootstepHouse_ScaryType_WithPrint_Level3 + GoToIfGe 0x800C, 70, FootstepHouse_ScaryType_WithPrint_Level2 + GoTo FootstepHouse_ScaryType_WithPrint_Level1 -_0316: - ScrCmd_1B9 0x800C, 0x8002 - GoToIfGe 0x800C, 0xFF, _04DB - GoToIfGe 0x800C, 200, _04D2 - GoToIfGe 0x800C, 150, _04C9 - GoToIfGe 0x800C, 70, _04C0 - GoTo _04B7 +FootstepHouse_ScaryType_WithoutPrint: + GetPartyMonFriendship 0x800C, VAR_PARTY_SLOT + GoToIfGe 0x800C, 0xFF, FootstepHouse_ScaryType_WithoutPrint_Level5 + GoToIfGe 0x800C, 200, FootstepHouse_ScaryType_WithoutPrint_Level4 + GoToIfGe 0x800C, 150, FootstepHouse_ScaryType_WithoutPrint_Level3 + GoToIfGe 0x800C, 70, FootstepHouse_ScaryType_WithoutPrint_Level2 + GoTo FootstepHouse_ScaryType_WithoutPrint_Level1 -_0356: - ScrCmd_1B9 0x800C, 0x8002 - GoToIfGe 0x800C, 0xFF, _0508 - GoToIfGe 0x800C, 200, _04FF - GoToIfGe 0x800C, 150, _04F6 - GoToIfGe 0x800C, 70, _04ED - GoTo _04E4 +FootstepHouse_SlowType_WithPrint: + GetPartyMonFriendship 0x800C, VAR_PARTY_SLOT + GoToIfGe 0x800C, 0xFF, FootstepHouse_SlowType_WithPrint_Level5 + GoToIfGe 0x800C, 200, FootstepHouse_SlowType_WithPrint_Level4 + GoToIfGe 0x800C, 150, FootstepHouse_SlowType_WithPrint_Level3 + GoToIfGe 0x800C, 70, FootstepHouse_SlowType_WithPrint_Level2 + GoTo FootstepHouse_SlowType_WithPrint_Level1 -_0396: - ScrCmd_1B9 0x800C, 0x8002 - GoToIfGe 0x800C, 0xFF, _0535 - GoToIfGe 0x800C, 200, _052C - GoToIfGe 0x800C, 150, _0523 - GoToIfGe 0x800C, 70, _051A - GoTo _0511 +FootstepHouse_SlowType_WithoutPrint: + GetPartyMonFriendship 0x800C, VAR_PARTY_SLOT + GoToIfGe 0x800C, 0xFF, FootstepHouse_SlowType_WithoutPrint_Level5 + GoToIfGe 0x800C, 200, FootstepHouse_SlowType_WithoutPrint_Level4 + GoToIfGe 0x800C, 150, FootstepHouse_SlowType_WithoutPrint_Level3 + GoToIfGe 0x800C, 70, FootstepHouse_SlowType_WithoutPrint_Level2 + GoTo FootstepHouse_SlowType_WithoutPrint_Level1 -_03D6: - Message 10 - GoTo _05A5 +FootstepHouse_CuteType_WithPrint_Level1: + Message footstep_house_cute_type_with_print_level_1 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_03DF: - Message 11 - GoTo _05A5 +FootstepHouse_CuteType_WithPrint_Level2: + Message footstep_house_cute_type_with_print_level_2 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_03E8: - Message 12 - GoTo _05A5 +FootstepHouse_CuteType_WithPrint_Level3: + Message footstep_house_cute_type_with_print_level_3 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_03F1: - Message 13 - GoTo _05A5 +FootstepHouse_CuteType_WithPrint_Level4: + Message footstep_house_cute_type_with_print_level_4 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_03FA: - Message 14 - GoTo _053E +FootstepHouse_CuteType_WithPrint_Level5: + Message footstep_house_cute_type_with_print_level_5 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_TryGiveRibbon -_0403: - Message 15 - GoTo _05C4 +FootstepHouse_CuteType_WithoutPrint_Level1: + Message footstep_house_cute_type_without_print_level_1 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_040C: - Message 16 - GoTo _05C4 +FootstepHouse_CuteType_WithoutPrint_Level2: + Message footstep_house_cute_type_without_print_level_2 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_0415: - Message 17 - GoTo _05C4 +FootstepHouse_CuteType_WithoutPrint_Level3: + Message footstep_house_cute_type_without_print_level_3 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_041E: - Message 18 - GoTo _05C4 +FootstepHouse_CuteType_WithoutPrint_Level4: + Message footstep_house_cute_type_without_print_level_4 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_0427: - Message 19 - GoTo _0559 +FootstepHouse_CuteType_WithoutPrint_Level5: + Message footstep_house_cute_type_without_print_level_5 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints_TryGiveRibbon -_0430: - Message 20 - GoTo _05A5 +FootstepHouse_ToughType_WithPrint_Level1: + Message footstep_house_tough_type_with_print_level_1 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_0439: - Message 21 - GoTo _05A5 +FootstepHouse_ToughType_WithPrint_Level2: + Message footstep_house_tough_type_with_print_level_2 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_0442: - Message 22 - GoTo _05A5 +FootstepHouse_ToughType_WithPrint_Level3: + Message footstep_house_tough_type_with_print_level_3 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_044B: - Message 23 - GoTo _05A5 +FootstepHouse_ToughType_WithPrint_Level4: + Message footstep_house_tough_type_with_print_level_4 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_0454: - Message 24 - GoTo _053E +FootstepHouse_ToughType_WithPrint_Level5: + Message footstep_house_tough_type_with_print_level_5 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_TryGiveRibbon -_045D: - Message 25 - GoTo _05C4 +FootstepHouse_ToughType_WithoutPrint_Level1: + Message footstep_house_tough_type_without_print_level_1 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_0466: - Message 26 - GoTo _05C4 +FootstepHouse_ToughType_WithoutPrint_Level2: + Message footstep_house_tough_type_without_print_level_2 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_046F: - Message 27 - GoTo _05C4 +FootstepHouse_ToughType_WithoutPrint_Level3: + Message footstep_house_tough_type_without_print_level_3 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_0478: - Message 28 - GoTo _05C4 +FootstepHouse_ToughType_WithoutPrint_Level4: + Message footstep_house_tough_type_without_print_level_4 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_0481: - Message 29 - GoTo _0559 +FootstepHouse_ToughType_WithoutPrint_Level5: + Message footstep_house_tough_type_without_print_level_5 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints_TryGiveRibbon -_048A: - Message 30 - GoTo _05A5 +FootstepHouse_ScaryType_WithPrint_Level1: + Message footstep_house_scary_type_with_print_level_1 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_0493: - Message 31 - GoTo _05A5 +FootstepHouse_ScaryType_WithPrint_Level2: + Message footstep_house_scary_type_with_print_level_2 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_049C: - Message 32 - GoTo _05A5 +FootstepHouse_ScaryType_WithPrint_Level3: + Message footstep_house_scary_type_with_print_level_3 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_04A5: - Message 33 - GoTo _05A5 +FootstepHouse_ScaryType_WithPrint_Level4: + Message footstep_house_scary_type_with_print_level_4 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_04AE: - Message 34 - GoTo _053E +FootstepHouse_ScaryType_WithPrint_Level5: + Message footstep_house_scary_type_with_print_level_5 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_TryGiveRibbon -_04B7: - Message 35 - GoTo _05C4 +FootstepHouse_ScaryType_WithoutPrint_Level1: + Message footstep_house_scary_type_without_print_level_1 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_04C0: - Message 36 - GoTo _05C4 +FootstepHouse_ScaryType_WithoutPrint_Level2: + Message footstep_house_scary_type_without_print_level_2 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_04C9: - Message 37 - GoTo _05C4 +FootstepHouse_ScaryType_WithoutPrint_Level3: + Message footstep_house_scary_type_without_print_level_3 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_04D2: - Message 38 - GoTo _05C4 +FootstepHouse_ScaryType_WithoutPrint_Level4: + Message footstep_house_scary_type_without_print_level_4 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_04DB: - Message 39 - GoTo _0559 +FootstepHouse_ScaryType_WithoutPrint_Level5: + Message footstep_house_scary_type_without_print_level_5 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints_TryGiveRibbon -_04E4: - Message 40 - GoTo _05A5 +FootstepHouse_SlowType_WithPrint_Level1: + Message footstep_house_slow_type_without_print_level_1 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_04ED: - Message 41 - GoTo _05A5 +FootstepHouse_SlowType_WithPrint_Level2: + Message footstep_house_slow_type_without_print_level_2 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_04F6: - Message 42 - GoTo _05A5 +FootstepHouse_SlowType_WithPrint_Level3: + Message footstep_house_slow_type_without_print_level_3 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_04FF: - Message 43 - GoTo _05A5 +FootstepHouse_SlowType_WithPrint_Level4: + Message footstep_house_slow_type_without_print_level_4 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_0508: - Message 44 - GoTo _053E +FootstepHouse_SlowType_WithPrint_Level5: + Message footstep_house_slow_type_without_print_level_5 + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_TryGiveRibbon -_0511: - Message 45 - GoTo _05C4 +FootstepHouse_SlowType_WithoutPrint_Level1: + Message footstep_house_slow_type_with_print_level_1 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_051A: - Message 46 - GoTo _05C4 +FootstepHouse_SlowType_WithoutPrint_Level2: + Message footstep_house_slow_type_with_print_level_2 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_0523: - Message 47 - GoTo _05C4 +FootstepHouse_SlowType_WithoutPrint_Level3: + Message footstep_house_slow_type_with_print_level_3 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_052C: - Message 48 - GoTo _05C4 +FootstepHouse_SlowType_WithoutPrint_Level4: + Message footstep_house_slow_type_with_print_level_4 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_0535: - Message 49 - GoTo _0559 +FootstepHouse_SlowType_WithoutPrint_Level5: + Message footstep_house_slow_type_with_print_level_5 + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints_TryGiveRibbon -_053E: - ScrCmd_230 0x800C, 0x8002, 69 - GoToIfEq 0x800C, 0, _0602 - GoTo _05A5 +FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_TryGiveRibbon: + GetPartyMonRibbon 0x800C, VAR_PARTY_SLOT, RIBBON_FOOTPRINT + GoToIfEq 0x800C, FALSE, FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_GiveRibbon + GoTo FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon -_0559: - ScrCmd_230 0x800C, 0x8002, 69 - GoToIfEq 0x800C, 0, _0633 - GoTo _05C4 +FootstepHouse_PokemonDoesntLeaveAnyFootprints_TryGiveRibbon: + GetPartyMonRibbon 0x800C, VAR_PARTY_SLOT, RIBBON_FOOTPRINT + GoToIfEq 0x800C, FALSE, FootstepHouse_PokemonDoesntLeaveAnyFootprints_GiveRibbon + GoTo FootstepHouse_PokemonDoesntLeaveAnyFootprints -_0574: - Message 50 - ScrCmd_1B9 0x800C, 0x8002 - GoToIfLt 0x800C, 0xFF, _05E3 - ScrCmd_230 0x800C, 0x8002, 69 - GoToIfEq 0x800C, 0, _0664 - GoTo _05E3 +FootstepHouse_VoicelessType: + Message footstep_house_silent_type + GetPartyMonFriendship 0x800C, VAR_PARTY_SLOT + GoToIfLt 0x800C, 0xFF, FootstepHouse_PokemonSilentType_NoRibbon + GetPartyMonRibbon 0x800C, VAR_PARTY_SLOT, RIBBON_FOOTPRINT + GoToIfEq 0x800C, FALSE, FootstepHouse_PokemonSilentType_GiveRibbon + GoTo FootstepHouse_PokemonSilentType_NoRibbon -_05A5: +FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_NoRibbon: CloseMessage WaitTime 20, 0x800C Call _00ED WaitTime 10, 0x800C - Message 2 + Message footstep_house_and_thats_what_you_pokemon_thinks_of_you WaitABXPadPress CloseMessage ReleaseAll End -_05C4: +FootstepHouse_PokemonDoesntLeaveAnyFootprints: CloseMessage WaitTime 20, 0x800C Call _00ED WaitTime 10, 0x800C - Message 3 + Message footstep_house_pokemon_doesnt_leave_any_footprints WaitABXPadPress CloseMessage ReleaseAll End -_05E3: +FootstepHouse_PokemonSilentType_NoRibbon: CloseMessage WaitTime 20, 0x800C Call _00ED WaitTime 10, 0x800C - Message 4 + Message footstep_house_pokemon_silent_type WaitABXPadPress CloseMessage ReleaseAll End -_0602: +FootstepHouse_AndThatsWhatYourPokemonThinksOfYou_GiveRibbon: CloseMessage WaitTime 20, 0x800C Call _00ED WaitTime 10, 0x800C - Message 5 + Message footstep_house_and_thats_what_you_pokemon_thinks_of_you_close_bond PlaySound SEQ_FANFA1 - Message 8 + Message footstep_house_received_footprint_ribbon WaitSound - ScrCmd_231 0x8002, 69 - Message 9 + SetPartyMonRibbon VAR_PARTY_SLOT, RIBBON_FOOTPRINT + Message footstep_house_put_the_footprint_ribbon_on_pokemon WaitABXPadPress CloseMessage ReleaseAll End -_0633: +FootstepHouse_PokemonDoesntLeaveAnyFootprints_GiveRibbon: CloseMessage WaitTime 20, 0x800C Call _00ED WaitTime 10, 0x800C - Message 6 + Message footstep_house_pokemon_doesnt_leave_any_footprints_close_bond PlaySound SEQ_FANFA1 - Message 8 + Message footstep_house_received_footprint_ribbon WaitSound - ScrCmd_231 0x8002, 69 - Message 9 + SetPartyMonRibbon VAR_PARTY_SLOT, RIBBON_FOOTPRINT + Message footstep_house_put_the_footprint_ribbon_on_pokemon WaitABXPadPress CloseMessage ReleaseAll End -_0664: +FootstepHouse_PokemonSilentType_GiveRibbon: CloseMessage WaitTime 20, 0x800C Call _00ED WaitTime 10, 0x800C - Message 7 + Message footstep_house_pokemon_silent_type_close_bond PlaySound SEQ_FANFA1 - Message 8 + Message footstep_house_received_footprint_ribbon WaitSound - ScrCmd_231 0x8002, 69 - Message 9 + SetPartyMonRibbon VAR_PARTY_SLOT, RIBBON_FOOTPRINT + Message footstep_house_put_the_footprint_ribbon_on_pokemon WaitABXPadPress CloseMessage ReleaseAll diff --git a/res/field/scripts/scripts_hearthome_city_pokemon_fan_club.s b/res/field/scripts/scripts_hearthome_city_pokemon_fan_club.s index 93b089b0cd..e0a2fdf70a 100644 --- a/res/field/scripts/scripts_hearthome_city_pokemon_fan_club.s +++ b/res/field/scripts/scripts_hearthome_city_pokemon_fan_club.s @@ -56,10 +56,10 @@ _0098: PlayFanfare SEQ_SE_CONFIRM LockAll FacePlayer - ScrCmd_247 0x8000 + GetFirstNonEggInParty 0x8000 BufferPartyMonNickname 0, 0x8000 Message 3 - ScrCmd_1B9 0x800C, 0x8000 + GetPartyMonFriendship 0x800C, 0x8000 GoToIfGe 0x800C, 0xFF, _0108 GoToIfGe 0x800C, 200, _0113 GoToIfGe 0x800C, 150, _011E diff --git a/res/field/scripts/scripts_pastoria_city_northeast_house.s b/res/field/scripts/scripts_pastoria_city_northeast_house.s index e996d52467..3a65dd7775 100644 --- a/res/field/scripts/scripts_pastoria_city_northeast_house.s +++ b/res/field/scripts/scripts_pastoria_city_northeast_house.s @@ -12,7 +12,7 @@ _000E: PlayFanfare SEQ_SE_CONFIRM LockAll FacePlayer - ScrCmd_247 0x8000 + GetFirstNonEggInParty 0x8000 GoToIfUnset 0x140, _005C GoToIfUnset 0x141, _005C GoToIfUnset 0x142, _005C diff --git a/res/field/scripts/scripts_resort_area_ribbon_syndicate_1f.s b/res/field/scripts/scripts_resort_area_ribbon_syndicate_1f.s index 0cc260f3a1..218e6ce827 100644 --- a/res/field/scripts/scripts_resort_area_ribbon_syndicate_1f.s +++ b/res/field/scripts/scripts_resort_area_ribbon_syndicate_1f.s @@ -1,5 +1,6 @@ #include "macros/scrcmd.inc" #include "res/text/bank/resort_area_ribbon_syndicate_1f.h" +#include "generated/ribbons.h" .data @@ -72,14 +73,14 @@ _00D6: PlayFanfare SEQ_SE_CONFIRM LockAll FacePlayer - ScrCmd_247 0x8000 + GetFirstNonEggInParty 0x8000 BufferPlayerName 0 BufferPartyMonSpecies 2, 0x8000 - ScrCmd_230 0x800C, 0x8000, 68 + GetPartyMonRibbon 0x800C, 0x8000, RIBBON_GORGEOUS_ROYAL GoToIfEq 0x800C, 1, _0244 - ScrCmd_230 0x800C, 0x8000, 67 + GetPartyMonRibbon 0x800C, 0x8000, RIBBON_ROYAL GoToIfEq 0x800C, 1, _01E7 - ScrCmd_230 0x800C, 0x8000, 66 + GetPartyMonRibbon 0x800C, 0x8000, RIBBON_GORGEOUS GoToIfEq 0x800C, 1, _018A GoTo _012F @@ -98,7 +99,7 @@ _012F: Message 7 Message 8 WaitABXPadPress - ScrCmd_231 0x8000, 66 + SetPartyMonRibbon 0x8000, RIBBON_GORGEOUS CloseMessage ScrCmd_073 ReleaseAll @@ -119,7 +120,7 @@ _018A: Message 9 Message 10 WaitABXPadPress - ScrCmd_231 0x8000, 67 + SetPartyMonRibbon 0x8000, RIBBON_ROYAL CloseMessage ScrCmd_073 ReleaseAll @@ -140,7 +141,7 @@ _01E7: Message 11 Message 12 WaitABXPadPress - ScrCmd_231 0x8000, 68 + SetPartyMonRibbon 0x8000, RIBBON_GORGEOUS_ROYAL CloseMessage ScrCmd_073 ReleaseAll diff --git a/res/field/scripts/scripts_resort_area_ribbon_syndicate_2f.s b/res/field/scripts/scripts_resort_area_ribbon_syndicate_2f.s index 0afd16addd..56dcca820b 100644 --- a/res/field/scripts/scripts_resort_area_ribbon_syndicate_2f.s +++ b/res/field/scripts/scripts_resort_area_ribbon_syndicate_2f.s @@ -15,7 +15,7 @@ _0012: FacePlayer GoToIfSet 0xAA5, _00E2 GoToIfEq 0x400A, 1, _00E2 - ScrCmd_247 0x4000 + GetFirstNonEggInParty 0x4000 BufferPlayerName 0 BufferPartyMonNickname 1, 0x4000 Message 0 diff --git a/res/field/scripts/scripts_route_210_grandma_wilma_house.s b/res/field/scripts/scripts_route_210_grandma_wilma_house.s index 97e2db76e3..9121565139 100644 --- a/res/field/scripts/scripts_route_210_grandma_wilma_house.s +++ b/res/field/scripts/scripts_route_210_grandma_wilma_house.s @@ -106,7 +106,7 @@ _010F: GoToIfEq 0x800C, 0, _0071 ScrCmd_099 0x800C, 0x1B2, 0x8000 GoToIfEq 0x800C, 1, _0087 - ScrCmd_1B9 0x800C, 0x8000 + GetPartyMonFriendship 0x800C, 0x8000 GoToIfLt 0x800C, 0xFF, _0097 SetVar 0x8003, 0x1B2 GoTo _019B diff --git a/res/field/scripts/scripts_route_228_north_house.s b/res/field/scripts/scripts_route_228_north_house.s index 172eca8e6b..7acd0ad205 100644 --- a/res/field/scripts/scripts_route_228_north_house.s +++ b/res/field/scripts/scripts_route_228_north_house.s @@ -42,7 +42,7 @@ _0055: SetVar 0x8002, 0x800C Call _0251 GoToIfEq 0x800C, 1, _02BB - ScrCmd_1B9 0x800C, 0x8000 + GetPartyMonFriendship 0x800C, 0x8000 GoToIfLt 0x800C, 0xFF, _02B0 BufferPartyMonSpecies 0, 0x8000 GoToIfEq 0x8002, 1, _00FE diff --git a/res/field/scripts/scripts_solaceon_town_northeast_house.s b/res/field/scripts/scripts_solaceon_town_northeast_house.s index 6c32e02fa1..e0506a0947 100644 --- a/res/field/scripts/scripts_solaceon_town_northeast_house.s +++ b/res/field/scripts/scripts_solaceon_town_northeast_house.s @@ -11,7 +11,7 @@ _000A: PlayFanfare SEQ_SE_CONFIRM LockAll FacePlayer - ScrCmd_247 0x800C + GetFirstNonEggInParty 0x800C ScrCmd_212 0x8004, 0x800C ScrCmd_17C 0, 0x8004 Message 0 diff --git a/res/field/scripts/scripts_sunyshore_city_northeast_house.s b/res/field/scripts/scripts_sunyshore_city_northeast_house.s index daa199eecb..92189f819e 100644 --- a/res/field/scripts/scripts_sunyshore_city_northeast_house.s +++ b/res/field/scripts/scripts_sunyshore_city_northeast_house.s @@ -1,5 +1,6 @@ #include "macros/scrcmd.inc" #include "res/text/bank/sunyshore_city_northeast_house.h" +#include "generated/ribbons.h" .data @@ -13,7 +14,7 @@ _0006: GoToIfSet 0xAA4, _006A GoToIfSet 0xAA7, _005F GoToIfUnset 247, _004C - ScrCmd_247 0x8002 + GetFirstNonEggInParty 0x8002 Call _0070 GoToIfEq 0x800C, 1, _0136 GoTo _0146 @@ -48,31 +49,31 @@ _0070: GoTo _0104 _00C8: - ScrCmd_230 0x800C, 0x8002, 65 + GetPartyMonRibbon 0x800C, 0x8002, RIBBON_SMILE Return _00D2: - ScrCmd_230 0x800C, 0x8002, 59 + GetPartyMonRibbon 0x800C, 0x8002, RIBBON_ALERT Return _00DC: - ScrCmd_230 0x800C, 0x8002, 60 + GetPartyMonRibbon 0x800C, 0x8002, RIBBON_SHOCK Return _00E6: - ScrCmd_230 0x800C, 0x8002, 61 + GetPartyMonRibbon 0x800C, 0x8002, RIBBON_DOWNCAST Return _00F0: - ScrCmd_230 0x800C, 0x8002, 62 + GetPartyMonRibbon 0x800C, 0x8002, RIBBON_CARELESS Return _00FA: - ScrCmd_230 0x800C, 0x8002, 63 + GetPartyMonRibbon 0x800C, 0x8002, RIBBON_RELAX Return _0104: - ScrCmd_230 0x800C, 0x8002, 64 + GetPartyMonRibbon 0x800C, 0x8002, RIBBON_SNOOZE Return _010E: @@ -124,7 +125,7 @@ _019E: ScrCmd_245 0, 0x8000 Message 21 SetFlag 0xAA4 - ScrCmd_231 0x8002, 65 + SetPartyMonRibbon 0x8002, RIBBON_SMILE ScrCmd_232 3, 65 GoTo _010E @@ -142,7 +143,7 @@ _01F2: ScrCmd_245 0, 0x8000 Message 3 SetFlag 0xAA4 - ScrCmd_231 0x8002, 59 + SetPartyMonRibbon 0x8002, RIBBON_ALERT ScrCmd_232 3, 59 GoTo _010E @@ -160,7 +161,7 @@ _0246: ScrCmd_245 0, 0x8000 Message 11 SetFlag 0xAA4 - ScrCmd_231 0x8002, 60 + SetPartyMonRibbon 0x8002, RIBBON_SHOCK ScrCmd_232 3, 60 GoTo _010E @@ -178,7 +179,7 @@ _029A: ScrCmd_245 0, 0x8000 Message 13 SetFlag 0xAA4 - ScrCmd_231 0x8002, 61 + SetPartyMonRibbon 0x8002, RIBBON_DOWNCAST ScrCmd_232 3, 61 GoTo _010E @@ -196,7 +197,7 @@ _02EE: ScrCmd_245 0, 0x8000 Message 15 SetFlag 0xAA4 - ScrCmd_231 0x8002, 62 + SetPartyMonRibbon 0x8002, RIBBON_CARELESS ScrCmd_232 3, 62 GoTo _010E @@ -214,7 +215,7 @@ _0342: ScrCmd_245 0, 0x8000 Message 17 SetFlag 0xAA4 - ScrCmd_231 0x8002, 63 + SetPartyMonRibbon 0x8002, RIBBON_RELAX ScrCmd_232 3, 63 GoTo _010E @@ -232,7 +233,7 @@ _0396: ScrCmd_245 0, 0x8000 Message 19 SetFlag 0xAA4 - ScrCmd_231 0x8002, 64 + SetPartyMonRibbon 0x8002, RIBBON_SNOOZE ScrCmd_232 3, 64 GoTo _010E diff --git a/res/field/scripts/scripts_sunyshore_market.s b/res/field/scripts/scripts_sunyshore_market.s index 1c5605f5bb..b2993c725c 100644 --- a/res/field/scripts/scripts_sunyshore_market.s +++ b/res/field/scripts/scripts_sunyshore_market.s @@ -1,5 +1,6 @@ #include "macros/scrcmd.inc" #include "res/text/bank/sunyshore_market.h" +#include "generated/ribbons.h" .data @@ -17,15 +18,15 @@ _001A: PlayFanfare SEQ_SE_CONFIRM LockAll FacePlayer - ScrCmd_247 0x8000 - ScrCmd_230 0x800C, 0x8000, 24 + GetFirstNonEggInParty 0x8000 + GetPartyMonRibbon 0x800C, 0x8000, RIBBON_HOENN_EFFORT GoToIfEq 0x800C, 1, _0086 BufferPartyMonSpecies 0, 0x8000 Message 0 ScrCmd_233 0x800C, 0x8000 GoToIfLt 0x800C, 0x1FE, _007B Message 1 - ScrCmd_231 0x8000, 24 + SetPartyMonRibbon 0x8000, RIBBON_HOENN_EFFORT PlaySound SEQ_FANFA1 BufferPlayerName 1 Message 2 diff --git a/res/text/footstep_house.gmm b/res/text/footstep_house.gmm index 8187901beb..37ff8a1629 100644 --- a/res/text/footstep_house.gmm +++ b/res/text/footstep_house.gmm @@ -1,207 +1,207 @@ - + used Dr. Footstep: Pokémon are quite easy\nfor me to read.\rI need only to see their footprints,\nand their innermost thoughts are\frevealed to me!\rOh?\nYou are skeptical of my claim?\rThen, let your {STRVAR_1 0, 0, 0} walk\nin front of me, right here.\rFrom its footprints, I will determine\nhow it feels about you.\r - + used Dr. Footstep: Do you want to check\nthe feelings of your Pokémon again?\rThen, let your {STRVAR_1 0, 0, 0} walk\nin front of me, right here.\rFrom its footprints, I will determine\nhow it feels about you.\r - + used Dr. Footstep: ...And that is what\nyour {STRVAR_1 0, 0, 0} thinks of you. - + used Dr. Footstep: ...Hmmm... {STRVAR_1 0, 0, 0}\ndoesn’t leave any footprints.\rIt’s somewhat difficult for me to\ndetermine what its thoughts are. - + used Dr. Footstep: ...Hmm... {STRVAR_1 0, 0, 0}\nhappens to be quite the silent type! - + used Dr. Footstep: ...And that is what\nyour {STRVAR_1 0, 0, 0} thinks of you.\rI must say, your {STRVAR_1 0, 0, 0} and\nyou share a very close bond.\fThis is for you.\r - + used Dr. Footstep: ...Hmmm... {STRVAR_1 0, 0, 0}\ndoesn’t leave any footprints.\rIt’s somewhat difficult for me to\ndetermine what its thoughts are.\rHowever, your {STRVAR_1 0, 0, 0} and\nyou obviously share a close bond.\fThis is for you.\r - + used Dr. Footstep: ...Hmm... {STRVAR_1 0, 0, 0}\nhappens to be quite the silent type!\rHowever, your {STRVAR_1 0, 0, 0} and\nyou obviously share a close bond.\fThis is for you.\r - + used {STRVAR_1 3, 1, 0} received\nthe Footprint Ribbon.\r - + used {STRVAR_1 3, 1, 0} put the Footprint Ribbon\non {STRVAR_1 0, 0, 0}. - + used Aww... {STRVAR_1 3, 1, 0} only plays with\nother Pokémon...\r{STRVAR_1 1, 2, 0} feels neglected...\rMaybe {STRVAR_1 3, 1, 0} doesn’t like\n{STRVAR_1 1, 2, 0} very much?\r{STRVAR_1 1, 2, 0} will try harder for\n{STRVAR_1 3, 1, 0}.\rPlease be nicer to me!\r - + used Others say there are people who\naren’t very nice to Pokémon.\rI wonder about {STRVAR_1 3, 1, 0}...\rWill {STRVAR_1 3, 1, 0} look after\n{STRVAR_1 1, 2, 0} nicely?\rWill I get to go all over with this\nTrainer?\rCan we be... Friends?\r - + used This adventure with {STRVAR_1 3, 1, 0}\nis lots of fun.\r{STRVAR_1 1, 2, 0} gets to go places where\nI can’t go by myself.\rI get to battle Pokémon I’ve never\never seen before.\rI’m gonna get stronger and stronger\nfor {STRVAR_1 3, 1, 0}!\r - + used {STRVAR_1 1, 2, 0} and {STRVAR_1 3, 1, 0} make\na perfectly matched combo!\rI’ve seen all sorts of people\nso far...\rBut {STRVAR_1 3, 1, 0} understands\n{STRVAR_1 1, 2, 0}’s feelings most!\rI’m a little hungry...\nYou can tell, right?\r - + used If I said there can be friendship\nbetween Pokémon and people, will\f{STRVAR_1 0, 0, 0}’s friends understand?\rBut if you see {STRVAR_1 3, 1, 0} and\n{STRVAR_1 1, 2, 0}, you will understand.\rBecause {STRVAR_1 3, 1, 0} and\n{STRVAR_1 1, 2, 0} are friends!\r - + used {STRVAR_1 1, 2, 0} is bored...\nPlay with me more, more...\r{STRVAR_1 1, 2, 0} and {STRVAR_1 3, 1, 0},\nlet’s play nicer...\r - + used Gonna go with {STRVAR_1 3, 1, 0} all over\nthe place...\rBe nice to {STRVAR_1 1, 2, 0}...\nWarm and cuddly...\r - + used {STRVAR_1 1, 2, 0} get strong, make\n{STRVAR_1 3, 1, 0} happy.\rRound ones, square ones,\ntriangle ones, wobbly ones...\r{STRVAR_1 1, 2, 0} wants to see different\nkinds of Pokémon...\r - + used {STRVAR_1 1, 2, 0} and {STRVAR_1 3, 1, 0}\nmake a friendly combo.\r{STRVAR_1 3, 1, 0}’s feelings, {STRVAR_1 1, 2, 0}\ncan understand.\r{STRVAR_1 1, 2, 0}’s feelings, {STRVAR_1 3, 1, 0}\nunderstands!\r - + used {STRVAR_1 3, 1, 0} makes {STRVAR_1 1, 2, 0}\nvery proud!\r{STRVAR_1 0, 0, 0} boasts to friends\nabout {STRVAR_1 3, 1, 0}!\r{STRVAR_1 3, 1, 0} and {STRVAR_1 1, 2, 0} are\nbest of friends!\r - + used Why does {STRVAR_1 3, 1, 0} use only\nother Pokémon?\rAm I not needed much?\rWould I have been better off if\nI remained in the wild?\rNo, I should give this Trainer\na little more of a chance...\r - + used Humans can’t understand the cries\nof Pokémon, nor our feelings.\rHowever, there are some among us\nthat understand human speech...\rHehehe, {STRVAR_1 3, 1, 0}, you’re not bad\nfor a human.\r - + used If a Pokémon were to travel alone,\nit would be limited as to where\fit could go.\rBut traveling with a human, a Pokémon\nwould be able to travel farther afield\fto more distant cities and lands.\rTraveling with {STRVAR_1 3, 1, 0} has been\nrewarding and reassuring.\rAnd very entertaining...\r - + used Some wild Pokémon frown upon others\nfor traveling with humans.\rThey jeer that the caught Pokémon\nhave “forgotten the wild.”\rBut that view is mistaken.\rThey have just never met a Trainer\nwho could be a great partner.\rA great partner like {STRVAR_1 3, 1, 0},\nin other words...\r - + used {STRVAR_1 3, 1, 0} is...\nA remarkable human and Trainer.\rThat I can always perform the best\nany {STRVAR_1 0, 0, 0} possibly can...\rI attribute that entirely to my\npartner {STRVAR_1 3, 1, 0}.\rWhen we travel, I can see wild\nPokémon eyeing us enviously...\r - + used Does {STRVAR_1 3, 1, 0} intend to ignore\nme forever?\rGive me more opportunities for me\nto shine...\r - + used If a Pokémon is treated as a friend,\nit will return the sentiments.\rWe grow fonder of humans that treat\nus with kindness...\rDoes {STRVAR_1 3, 1, 0} even like\n{STRVAR_1 1, 2, 0}?\r - + used Did {STRVAR_1 1, 2, 0} get stronger?\nWho is responsible for making me so?\rIs it {STRVAR_1 3, 1, 0}’s doing?\nIs the Trainer owed my thanks?\r - + used {STRVAR_1 3, 1, 0} and {STRVAR_1 1, 2, 0} are\nalike in some ways.\rIn humanspeak, we match up well.\nDoes {STRVAR_1 3, 1, 0} think so, too?\r - + used {STRVAR_1 3, 1, 0} is very impressive,\nespecially for a human.\rThe Trainer lets {STRVAR_1 1, 2, 0} use\nevery bit of power properly.\rIt is a shame that {STRVAR_1 3, 1, 0} is\nonly a human...\r - + used That {STRVAR_1 3, 1, 0}...\nWhat is that Trainer thinking?\rWhy make me join the team, then call\nupon me for nothing?\rAm I considered useless?\nIs the Trainer regretting having me?\rDoes the Trainer dare disrespect\nthis {STRVAR_1 0, 0, 0} so easily?\r - + used I have little understanding of\n{STRVAR_1 3, 1, 0} as a human...\r{STRVAR_1 3, 1, 0} may not be too bad,\nconsidering that I, an oft-shunned\f{STRVAR_1 0, 0, 0}, am one of the team...\rThat said, I don’t intend to be all\ncheerful around {STRVAR_1 3, 1, 0}...\r - + used Our kind prefers to lurk in dark\nand dank places...\rBut being with {STRVAR_1 3, 1, 0}, even\nbright and festive places seem less\fthreatening...\r{STRVAR_1 3, 1, 0} has a strange\ncharisma...\r - + used Not for a moment did I think I would\nbe traveling with a human...\rIf my {STRVAR_1 0, 0, 0} friends were to\nsee me now, they would be shocked.\rOr would they be envious of me...?\r - + used That {STRVAR_1 3, 1, 0} is the most\nimpressive of humans.\rIt takes a lot to make me,\n{STRVAR_1 1, 2, 0}, sunny and cheerful!\rAs a show of affection, I should\nchomp down on the Trainer’s neck...\rHahaha... Have no fear...\nI was merely joking...\r - + used Wooooooh...\n{STRVAR_1 1, 2, 0} has nothing to do...\rKeep me too bored, and I’m liable\nto sneak up and bite...\r - + used Is there any human that would grow\nto like us {STRVAR_1 0, 0, 0}?\rWell? Does {STRVAR_1 3, 1, 0} like\n{STRVAR_1 1, 2, 0}?\r{STRVAR_1 1, 2, 0} doesn’t like...\nWell, no, maybe not...\r - + used {STRVAR_1 3, 1, 0} treats me, {STRVAR_1 1, 2, 0},\nnicely without being scared.\rBut {STRVAR_1 1, 2, 0} will be even scarier\nfrom now on.\rThat’s what we {STRVAR_1 0, 0, 0} do...\r - + used {STRVAR_1 1, 2, 0} is starting to forget\na little about being in the wild...\rBut {STRVAR_1 1, 2, 0} isn’t feeling sad.\nIt’s never boring with {STRVAR_1 3, 1, 0}...\r - + used There are no Pokémon that dislike\nhumans...\rOnly humans that dislike Pokémon...\rWe {STRVAR_1 0, 0, 0} are especially\nshunned...\rBut {STRVAR_1 3, 1, 0} always treats me\nas a friend and partner...\r - + used Hnurrrr... Hunh?\nThis is... Where?\r{STRVAR_1 3, 1, 0}’s house, is this?\nIt’s not? Hnurrr...\rIf you don’t need me for anything,\ncan I go back to my Ball?\rHnurrr...\r - + used Hnurrr... Me? Uhm...\nI like to sleep most the time.\fOh, I like to eat, too. That’s next.\rBut what I really like is to think.\nI’m a very deep thinker.\rWhen I think about the future of the\n{STRVAR_1 0, 0, 0} species...\r...Hnurrr...hunh?\nOh, I forget where the time goes.\rHnurrrr...\r - + used Hnurrr... Me? Uhm...\nThere are lots of kinds of moves.\rI like those Dark-type moves,\noh, and Dragon-type moves, too...\rHow would they be for this\n{STRVAR_1 0, 0, 0}?\rWill they be for me?\nOr a no, no, no sort of thing?\rHnurrr...\r - + used Hnurrr... I don’t know how to begin\nsaying this...\rI liked living quietly before I met\n{STRVAR_1 3, 1, 0}. Sssh.\rBut I’m getting to like traveling\nwith {STRVAR_1 3, 1, 0}.\rI think I’m getting sort of funky.\nDo you think I’m sort of funky?\rNo? No funk for me?\nHnurrr...\r - + used Hnurrr... Me? Uhm...\nOther Pokémon, they say to me...\r“You’re not thinking, are you?”\nHow insulting they should say so.\rIt isn’t true what they say.\nThink, think, think, I do that.\rAll the time, I think hard how to help\n{STRVAR_1 3, 1, 0}. I concentrate!\rHnurrr...\r - + used Hnurrr... I did not know that?\nI really don’t? What is this?\fI don’t know what to say?\fHnurrr...\r - + used Hnurrr... Well, I...\nI think I’m motivated.\fAs motivated as the average.\fBut it’s not so simple as that.\fHnurrr...\r - + used Hnurrr... How should I say this?\nWe both look out for each other.\fThat’s what we try to do, I think.\fThat is for the best.\fHnurrrr...\r - + used Hnurrr... How do I say?\nHow should I describe us?\rWe are the sound of both hands\nclapping.\r{STRVAR_1 3, 1, 0} and I are together\nin synchronicity like twins.\rHnurrr...\r - + used Hnurrr...\nWhat is left to say, I say?\rWe have come so far now, where can\nwe go but to see this through?\rHall of Fame...\nWords so sweet fall from my mouth.\rHnurrr...\r - + used Sssshhnnn...\n...\f...Ssshhhnnn...\f...\fSsshhhnnn...\f...\r diff --git a/src/applications/pokemon_summary_screen/main.c b/src/applications/pokemon_summary_screen/main.c index ad3c6b5597..28a4ea2eeb 100644 --- a/src/applications/pokemon_summary_screen/main.c +++ b/src/applications/pokemon_summary_screen/main.c @@ -1169,7 +1169,7 @@ static void SetMonDataFromMon(PokemonSummaryScreen *summaryScreen, Pokemon *mon, summaryScreen->ribbonMax = 0; for (i = 0; i < RIBBON_MAX; i++) { - if (Pokemon_GetValue(mon, Ribbon_GetData(i, RIBBON_DATA_RIBBON_ID), NULL) != 0) { + if (Pokemon_GetValue(mon, Ribbon_GetData(i, RIBBON_DATA_MON_DATA_PARAM), NULL) != 0) { monData->ribbons[i / 32] |= (1 << (i & 0x1F)); summaryScreen->ribbonMax++; } @@ -2126,7 +2126,7 @@ static void ChangeSelectedRibbon(PokemonSummaryScreen *summaryScreen, s8 delta) Sound_PlayEffect(SEQ_SE_CONFIRM); } - summaryScreen->ribbonNum = PokemonSummaryScreen_RibbonNumAt(summaryScreen, summaryScreen->ribbonCol); + summaryScreen->ribbonID = PokemonSummaryScreen_RibbonIDAt(summaryScreen, summaryScreen->ribbonCol); PokemonSummaryScreen_UpdateRibbonCursorPos(summaryScreen); @@ -2150,16 +2150,16 @@ static void ChangeSelectedRibbon(PokemonSummaryScreen *summaryScreen, s8 delta) } } -u8 PokemonSummaryScreen_RibbonNumAt(PokemonSummaryScreen *summaryScreen, u8 col) +u8 PokemonSummaryScreen_RibbonIDAt(PokemonSummaryScreen *summaryScreen, u8 col) { - u16 ribbonNum; + u16 ribbonID; u8 ribbonIndex = col + summaryScreen->ribbonRow * RIBBONS_PER_ROW; u8 monRibbonIndex = 0; - for (ribbonNum = 0; ribbonNum < RIBBON_MAX; ribbonNum++) { - if ((summaryScreen->monData.ribbons[ribbonNum / 32] & (1 << (ribbonNum & 0x1F))) != 0) { + for (ribbonID = 0; ribbonID < RIBBON_MAX; ribbonID++) { + if ((summaryScreen->monData.ribbons[ribbonID / 32] & (1 << (ribbonID & 0x1F))) != 0) { if (ribbonIndex == monRibbonIndex) { - return ribbonNum; + return ribbonID; } monRibbonIndex++; diff --git a/src/applications/pokemon_summary_screen/sprites.c b/src/applications/pokemon_summary_screen/sprites.c index 3fdbcc0da3..23a3d53270 100644 --- a/src/applications/pokemon_summary_screen/sprites.c +++ b/src/applications/pokemon_summary_screen/sprites.c @@ -1487,10 +1487,10 @@ void PokemonSummaryScreen_HideContestStatDots(PokemonSummaryScreen *summaryScree Sprite_SetDrawFlag(summaryScreen->sprites[SUMMARY_SPRITE_CONTEST_STAT_DOT_TOUGH], FALSE); } -static void SetRibbonSpriteGfx(PokemonSummaryScreen *summaryScreen, u8 ribbonNum, u8 ribbonIndex) +static void SetRibbonSpriteGfx(PokemonSummaryScreen *summaryScreen, u8 ribbonID, u8 ribbonIndex) { - SpriteSystem_ReplaceCharResObj(summaryScreen->spriteSys, summaryScreen->spriteMan, NARC_INDEX_GRAPHIC__PL_PST_GRA, Ribbon_GetData(ribbonNum, RIBBON_DATA_SPRITE_ID), 0, 26 + ribbonIndex); - Sprite_SetExplicitPalette2(summaryScreen->sprites[SUMMARY_SPRITE_RIBBON_1 + ribbonIndex], Ribbon_GetData(ribbonNum, RIBBON_DATA_PALETTE_NUM) + 7); + SpriteSystem_ReplaceCharResObj(summaryScreen->spriteSys, summaryScreen->spriteMan, NARC_INDEX_GRAPHIC__PL_PST_GRA, Ribbon_GetData(ribbonID, RIBBON_DATA_SPRITE_ID), 0, 26 + ribbonIndex); + Sprite_SetExplicitPalette2(summaryScreen->sprites[SUMMARY_SPRITE_RIBBON_1 + ribbonIndex], Ribbon_GetData(ribbonID, RIBBON_DATA_PALETTE_NUM) + 7); } void PokemonSummaryScreen_UpdateRibbonSprites(PokemonSummaryScreen *summaryScreen) @@ -1509,7 +1509,7 @@ void PokemonSummaryScreen_UpdateRibbonSprites(PokemonSummaryScreen *summaryScree for (i = 0; i < RIBBONS_PER_PAGE; i++) { if (i < summaryScreen->ribbonMax) { Sprite_SetDrawFlag(summaryScreen->sprites[SUMMARY_RIBBON_SPRITES_START + i], TRUE); - SetRibbonSpriteGfx(summaryScreen, PokemonSummaryScreen_RibbonNumAt(summaryScreen, i), i); + SetRibbonSpriteGfx(summaryScreen, PokemonSummaryScreen_RibbonIDAt(summaryScreen, i), i); } } @@ -1521,7 +1521,7 @@ void PokemonSummaryScreen_UpdateShownRibbonRows(PokemonSummaryScreen *summaryScr for (u16 i = 0; i < RIBBONS_PER_ROW * 2; i++) { if ((summaryScreen->ribbonRow * RIBBONS_PER_ROW + i) < summaryScreen->ribbonMax) { Sprite_SetDrawFlag(summaryScreen->sprites[SUMMARY_RIBBON_SPRITES_START + i], TRUE); - SetRibbonSpriteGfx(summaryScreen, PokemonSummaryScreen_RibbonNumAt(summaryScreen, i), i); + SetRibbonSpriteGfx(summaryScreen, PokemonSummaryScreen_RibbonIDAt(summaryScreen, i), i); } else { Sprite_SetDrawFlag(summaryScreen->sprites[SUMMARY_RIBBON_SPRITES_START + i], FALSE); } diff --git a/src/applications/pokemon_summary_screen/window.c b/src/applications/pokemon_summary_screen/window.c index 95d38a559d..5176e95e74 100644 --- a/src/applications/pokemon_summary_screen/window.c +++ b/src/applications/pokemon_summary_screen/window.c @@ -1357,10 +1357,10 @@ void PokemonSummaryScreen_PrintRibbonNameAndDesc(PokemonSummaryScreen *summarySc Window_FillTilemap(&summaryScreen->extraWindows[SUMMARY_WINDOW_RIBBON_NAME], 0); Window_FillTilemap(&summaryScreen->extraWindows[SUMMARY_WINDOW_RIBBON_DESCRIPTION], 0); - MessageLoader_GetStrbuf(summaryScreen->ribbonLoader, Ribbon_GetData(summaryScreen->ribbonNum, RIBBON_DATA_NAME_ID), summaryScreen->strbuf); + MessageLoader_GetStrbuf(summaryScreen->ribbonLoader, Ribbon_GetData(summaryScreen->ribbonID, RIBBON_DATA_NAME_ID), summaryScreen->strbuf); PrintStrbufToWindow(summaryScreen, &summaryScreen->extraWindows[SUMMARY_WINDOW_RIBBON_NAME], SUMMARY_TEXT_WHITE, ALIGN_LEFT); - MessageLoader_GetStrbuf(summaryScreen->ribbonLoader, PokemonSummaryScreen_GetRibbonDescriptionID(summaryScreen->data->specialRibbons, summaryScreen->ribbonNum), summaryScreen->strbuf); + MessageLoader_GetStrbuf(summaryScreen->ribbonLoader, PokemonSummaryScreen_GetRibbonDescriptionID(summaryScreen->data->specialRibbons, summaryScreen->ribbonID), summaryScreen->strbuf); PrintStrbufToWindow(summaryScreen, &summaryScreen->extraWindows[SUMMARY_WINDOW_RIBBON_DESCRIPTION], SUMMARY_TEXT_BLACK, ALIGN_LEFT); Window_ScheduleCopyToVRAM(&summaryScreen->extraWindows[SUMMARY_WINDOW_RIBBON_NAME]); diff --git a/src/game_records.c b/src/game_records.c index dd69cbe387..da37029308 100644 --- a/src/game_records.c +++ b/src/game_records.c @@ -203,7 +203,7 @@ static u8 sUsesHighLimit[MAX_RECORDS] = { [RECORD_UNK_113] = FALSE, [RECORD_UNK_114] = FALSE, [RECORD_UNK_115] = FALSE, - [RECORD_UNK_116] = FALSE, + [RECORD_CHECKED_FOOTPRINTS] = FALSE, [RECORD_UNK_117] = FALSE, [RECORD_UNK_118] = FALSE, [RECORD_UNK_119] = FALSE, diff --git a/src/meson.build b/src/meson.build index 59eb9011c1..99e69628f5 100644 --- a/src/meson.build +++ b/src/meson.build @@ -411,7 +411,7 @@ pokeplatinum_c = files( 'overlay005/ov5_021F067C.c', 'overlay005/ov5_021F0824.c', 'overlay005/ov5_021F08CC.c', - 'overlay005/ov5_021F0E84.c', + 'overlay005/footprint_type.c', 'overlay005/ov5_021F0EB0.c', 'overlay005/ov5_021F101C.c', 'overlay005/ov5_021F10E8.c', diff --git a/src/overlay005/footprint_type.c b/src/overlay005/footprint_type.c new file mode 100644 index 0000000000..640f20c186 --- /dev/null +++ b/src/overlay005/footprint_type.c @@ -0,0 +1,524 @@ +#include "overlay005/footprint_type.h" + +#include +#include +#include + +#include "constants/footstep_house.h" +#include "constants/species.h" + +typedef struct { + u16 type; + u16 hasPrint; +} FootprintType; + +static const FootprintType sFootprintTypes[NATIONAL_DEX_COUNT + 1] = { + [SPECIES_NONE] = { FOOTPRINT_TYPE_NONE, FALSE }, + [SPECIES_BULBASAUR] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_IVYSAUR] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_VENUSAUR] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CHARMANDER] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_CHARMELEON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CHARIZARD] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SQUIRTLE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_WARTORTLE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_BLASTOISE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CATERPIE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_METAPOD] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_BUTTERFREE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_WEEDLE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_KAKUNA] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_BEEDRILL] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_PIDGEY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_PIDGEOTTO] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_PIDGEOT] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_RATTATA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_RATICATE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SPEAROW] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_FEAROW] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_EKANS] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_ARBOK] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_PIKACHU] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_RAICHU] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SANDSHREW] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SANDSLASH] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_NIDORAN_F] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_NIDORINA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_NIDOQUEEN] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_NIDORAN_M] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_NIDORINO] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_NIDOKING] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CLEFAIRY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_CLEFABLE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_VULPIX] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_NINETALES] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_JIGGLYPUFF] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_WIGGLYTUFF] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_ZUBAT] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_GOLBAT] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_ODDISH] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_GLOOM] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_VILEPLUME] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_PARAS] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_PARASECT] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_VENONAT] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_VENOMOTH] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_DIGLETT] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_DUGTRIO] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_MEOWTH] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_PERSIAN] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_PSYDUCK] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_GOLDUCK] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MANKEY] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_PRIMEAPE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_GROWLITHE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_ARCANINE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_POLIWAG] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_POLIWHIRL] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_POLIWRATH] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_ABRA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_KADABRA] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_ALAKAZAM] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MACHOP] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MACHOKE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MACHAMP] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_BELLSPROUT] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_WEEPINBELL] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_VICTREEBEL] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_TENTACOOL] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_TENTACRUEL] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_GEODUDE] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_GRAVELER] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_GOLEM] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_PONYTA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_RAPIDASH] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SLOWPOKE] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_SLOWBRO] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_MAGNEMITE] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_MAGNETON] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_FARFETCHD] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_DODUO] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_DODRIO] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SEEL] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_DEWGONG] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_GRIMER] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_MUK] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_SHELLDER] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_CLOYSTER] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_GASTLY] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_HAUNTER] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_GENGAR] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_ONIX] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_DROWZEE] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_HYPNO] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_KRABBY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_KINGLER] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_VOLTORB] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_ELECTRODE] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_EXEGGCUTE] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_EXEGGUTOR] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_CUBONE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MAROWAK] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_HITMONLEE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_HITMONCHAN] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_LICKITUNG] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_KOFFING] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_WEEZING] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_RHYHORN] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_RHYDON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CHANSEY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_TANGELA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_KANGASKHAN] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_HORSEA] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_SEADRA] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_GOLDEEN] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_SEAKING] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_STARYU] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_STARMIE] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_MR_MIME] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SCYTHER] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_JYNX] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_ELECTABUZZ] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MAGMAR] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_PINSIR] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_TAUROS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MAGIKARP] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_GYARADOS] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_LAPRAS] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_DITTO] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_EEVEE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_VAPOREON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_JOLTEON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_FLAREON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_PORYGON] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_OMANYTE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_OMASTAR] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_KABUTO] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_KABUTOPS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_AERODACTYL] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SNORLAX] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_ARTICUNO] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_ZAPDOS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MOLTRES] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_DRATINI] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_DRAGONAIR] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_DRAGONITE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MEWTWO] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MEW] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_CHIKORITA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_BAYLEEF] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MEGANIUM] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CYNDAQUIL] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_QUILAVA] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_TYPHLOSION] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_TOTODILE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_CROCONAW] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_FERALIGATR] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SENTRET] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_FURRET] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_HOOTHOOT] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_NOCTOWL] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_LEDYBA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_LEDIAN] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SPINARAK] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_ARIADOS] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_CROBAT] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_CHINCHOU] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_LANTURN] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_PICHU] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_CLEFFA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_IGGLYBUFF] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_TOGEPI] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_TOGETIC] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_NATU] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_XATU] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_MAREEP] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_FLAAFFY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_AMPHAROS] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_BELLOSSOM] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_MARILL] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_AZUMARILL] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SUDOWOODO] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_POLITOED] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_HOPPIP] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SKIPLOOM] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_JUMPLUFF] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_AIPOM] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SUNKERN] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_SUNFLORA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_YANMA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_WOOPER] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_QUAGSIRE] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_ESPEON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_UMBREON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MURKROW] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_SLOWKING] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_MISDREAVUS] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_UNOWN] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_WOBBUFFET] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_GIRAFARIG] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_PINECO] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_FORRETRESS] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_DUNSPARCE] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_GLIGAR] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_STEELIX] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_SNUBBULL] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_GRANBULL] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_QWILFISH] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_SCIZOR] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SHUCKLE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_HERACROSS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SNEASEL] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_TEDDIURSA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_URSARING] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SLUGMA] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_MAGCARGO] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_SWINUB] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_PILOSWINE] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_CORSOLA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_REMORAID] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_OCTILLERY] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_DELIBIRD] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MANTINE] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_SKARMORY] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_HOUNDOUR] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_HOUNDOOM] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_KINGDRA] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_PHANPY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_DONPHAN] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_PORYGON2] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_STANTLER] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SMEARGLE] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_TYROGUE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_HITMONTOP] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SMOOCHUM] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_ELEKID] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MAGBY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MILTANK] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_BLISSEY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_RAIKOU] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_ENTEI] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SUICUNE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_LARVITAR] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_PUPITAR] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_TYRANITAR] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_LUGIA] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_HO_OH] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CELEBI] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_TREECKO] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_GROVYLE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SCEPTILE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_TORCHIC] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_COMBUSKEN] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_BLAZIKEN] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MUDKIP] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MARSHTOMP] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SWAMPERT] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_POOCHYENA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MIGHTYENA] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_ZIGZAGOON] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_LINOONE] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_WURMPLE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SILCOON] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_BEAUTIFLY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_CASCOON] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_DUSTOX] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_LOTAD] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_LOMBRE] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_LUDICOLO] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_SEEDOT] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_NUZLEAF] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SHIFTRY] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_TAILLOW] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SWELLOW] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_WINGULL] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_PELIPPER] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_RALTS] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_KIRLIA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_GARDEVOIR] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SURSKIT] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MASQUERAIN] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_SHROOMISH] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_BRELOOM] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SLAKOTH] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_VIGOROTH] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SLAKING] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_NINCADA] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_NINJASK] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SHEDINJA] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_WHISMUR] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_LOUDRED] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_EXPLOUD] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MAKUHITA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_HARIYAMA] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_AZURILL] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_NOSEPASS] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_SKITTY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_DELCATTY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SABLEYE] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_MAWILE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_ARON] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_LAIRON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_AGGRON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MEDITITE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MEDICHAM] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_ELECTRIKE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MANECTRIC] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_PLUSLE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MINUN] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_VOLBEAT] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_ILLUMISE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_ROSELIA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_GULPIN] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_SWALOT] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_CARVANHA] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_SHARPEDO] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_WAILMER] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_WAILORD] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_NUMEL] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_CAMERUPT] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_TORKOAL] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_SPOINK] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_GRUMPIG] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SPINDA] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_TRAPINCH] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_VIBRAVA] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_FLYGON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CACNEA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_CACTURNE] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_SWABLU] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_ALTARIA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_ZANGOOSE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SEVIPER] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_LUNATONE] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_SOLROCK] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_BARBOACH] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_WHISCASH] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_CORPHISH] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CRAWDAUNT] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_BALTOY] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_CLAYDOL] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_LILEEP] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_CRADILY] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_ANORITH] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_ARMALDO] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_FEEBAS] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_MILOTIC] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_CASTFORM] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_KECLEON] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SHUPPET] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_BANETTE] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_DUSKULL] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_DUSCLOPS] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_TROPIUS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CHIMECHO] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_ABSOL] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_WYNAUT] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_SNORUNT] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_GLALIE] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_SPHEAL] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_SEALEO] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_WALREIN] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_CLAMPERL] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_HUNTAIL] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_GOREBYSS] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_RELICANTH] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_LUVDISC] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_BAGON] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SHELGON] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_SALAMENCE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_BELDUM] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_METANG] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_METAGROSS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_REGIROCK] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_REGICE] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_REGISTEEL] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_LATIAS] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_LATIOS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_KYOGRE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_GROUDON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_RAYQUAZA] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_JIRACHI] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_DEOXYS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_TURTWIG] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_GROTLE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_TORTERRA] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CHIMCHAR] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MONFERNO] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_INFERNAPE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_PIPLUP] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_PRINPLUP] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_EMPOLEON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_STARLY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_STARAVIA] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_STARAPTOR] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_BIDOOF] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_BIBAREL] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_KRICKETOT] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_KRICKETUNE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SHINX] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_LUXIO] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_LUXRAY] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_BUDEW] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_ROSERADE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CRANIDOS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_RAMPARDOS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SHIELDON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_BASTIODON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_BURMY] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_WORMADAM] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_MOTHIM] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_COMBEE] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_VESPIQUEN] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_PACHIRISU] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_BUIZEL] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_FLOATZEL] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CHERUBI] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_CHERRIM] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_SHELLOS] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_GASTRODON] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_AMBIPOM] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_DRIFLOON] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_DRIFBLIM] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_BUNEARY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_LOPUNNY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MISMAGIUS] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_HONCHKROW] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_GLAMEOW] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_PURUGLY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_CHINGLING] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_STUNKY] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_SKUNTANK] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_BRONZOR] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_BRONZONG] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_BONSLY] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_MIME_JR] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_HAPPINY] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_CHATOT] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_SPIRITOMB] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_GIBLE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_GABITE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_GARCHOMP] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MUNCHLAX] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_RIOLU] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_LUCARIO] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_HIPPOPOTAS] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_HIPPOWDON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_SKORUPI] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_DRAPION] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_CROAGUNK] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_TOXICROAK] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_CARNIVINE] = { FOOTPRINT_TYPE_SLOW, FALSE }, + [SPECIES_FINNEON] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_LUMINEON] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_MANTYKE] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_SNOVER] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_ABOMASNOW] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_WEAVILE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MAGNEZONE] = { FOOTPRINT_TYPE_SILENT, FALSE }, + [SPECIES_LICKILICKY] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_RHYPERIOR] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_TANGROWTH] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_ELECTIVIRE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MAGMORTAR] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_TOGEKISS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_YANMEGA] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_LEAFEON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_GLACEON] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_GLISCOR] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_MAMOSWINE] = { FOOTPRINT_TYPE_SLOW, TRUE }, + [SPECIES_PORYGON_Z] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_GALLADE] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_PROBOPASS] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_DUSKNOIR] = { FOOTPRINT_TYPE_SCARY, FALSE }, + [SPECIES_FROSLASS] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_ROTOM] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_UXIE] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_MESPRIT] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_AZELF] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_DIALGA] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_PALKIA] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_HEATRAN] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_REGIGIGAS] = { FOOTPRINT_TYPE_SILENT, TRUE }, + [SPECIES_GIRATINA] = { FOOTPRINT_TYPE_TOUGH, TRUE }, + [SPECIES_CRESSELIA] = { FOOTPRINT_TYPE_TOUGH, FALSE }, + [SPECIES_PHIONE] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_MANAPHY] = { FOOTPRINT_TYPE_CUTE, FALSE }, + [SPECIES_DARKRAI] = { FOOTPRINT_TYPE_SCARY, TRUE }, + [SPECIES_SHAYMIN] = { FOOTPRINT_TYPE_CUTE, TRUE }, + [SPECIES_ARCEUS] = { FOOTPRINT_TYPE_TOUGH, TRUE }, +}; + +u16 FootprintType_GetTypeFromSpecies(u16 species) +{ + return sFootprintTypes[species].type; +} + +u16 FootprintType_SpeciesHasPrint(u16 species, u16 form) +{ + if (species == SPECIES_GIRATINA && form == 1) { + return FALSE; + } + + return sFootprintTypes[species].hasPrint; +} diff --git a/src/overlay005/ov5_021F0E84.c b/src/overlay005/ov5_021F0E84.c deleted file mode 100644 index ad1cbfadf1..0000000000 --- a/src/overlay005/ov5_021F0E84.c +++ /dev/null @@ -1,523 +0,0 @@ -#include "overlay005/ov5_021F0E84.h" - -#include -#include -#include - -#include "constants/species.h" - -typedef struct { - u16 unk_00; - u16 unk_02; -} UnkStruct_ov5_021FFA54; - -static const UnkStruct_ov5_021FFA54 Unk_ov5_021FFA54[NATIONAL_DEX_COUNT + 1] = { - { 0x0, 0x0 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x5, 0x0 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x5, 0x0 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x3, 0x0 }, - { 0x3, 0x0 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x3, 0x0 }, - { 0x3, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x5, 0x1 }, - { 0x5, 0x1 }, - { 0x1, 0x1 }, - { 0x5, 0x1 }, - { 0x1, 0x0 }, - { 0x1, 0x0 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x4, 0x0 }, - { 0x4, 0x0 }, - { 0x2, 0x0 }, - { 0x2, 0x0 }, - { 0x1, 0x0 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x4, 0x1 }, - { 0x5, 0x1 }, - { 0x5, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x0 }, - { 0x4, 0x0 }, - { 0x3, 0x0 }, - { 0x3, 0x0 }, - { 0x4, 0x0 }, - { 0x2, 0x0 }, - { 0x3, 0x0 }, - { 0x3, 0x0 }, - { 0x3, 0x1 }, - { 0x2, 0x0 }, - { 0x3, 0x1 }, - { 0x3, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x0 }, - { 0x2, 0x0 }, - { 0x1, 0x0 }, - { 0x4, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x3, 0x0 }, - { 0x3, 0x0 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x0 }, - { 0x2, 0x0 }, - { 0x1, 0x0 }, - { 0x2, 0x0 }, - { 0x5, 0x1 }, - { 0x5, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x0 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x0 }, - { 0x3, 0x0 }, - { 0x1, 0x0 }, - { 0x4, 0x0 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x5, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x5, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x0 }, - { 0x2, 0x0 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x3, 0x1 }, - { 0x3, 0x1 }, - { 0x3, 0x0 }, - { 0x4, 0x0 }, - { 0x2, 0x0 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x5, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x0 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x4, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x0 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x4, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x3, 0x1 }, - { 0x4, 0x1 }, - { 0x3, 0x0 }, - { 0x5, 0x0 }, - { 0x4, 0x1 }, - { 0x1, 0x1 }, - { 0x5, 0x0 }, - { 0x5, 0x0 }, - { 0x4, 0x0 }, - { 0x4, 0x1 }, - { 0x2, 0x0 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x0 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x0 }, - { 0x4, 0x0 }, - { 0x1, 0x1 }, - { 0x4, 0x1 }, - { 0x1, 0x1 }, - { 0x5, 0x0 }, - { 0x4, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x0 }, - { 0x2, 0x1 }, - { 0x3, 0x1 }, - { 0x3, 0x1 }, - { 0x2, 0x0 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x5, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x5, 0x0 }, - { 0x3, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x4, 0x1 }, - { 0x1, 0x1 }, - { 0x5, 0x0 }, - { 0x1, 0x1 }, - { 0x5, 0x0 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x4, 0x1 }, - { 0x4, 0x1 }, - { 0x5, 0x1 }, - { 0x2, 0x1 }, - { 0x3, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x0 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x5, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x4, 0x1 }, - { 0x4, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x5, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x3, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x4, 0x0 }, - { 0x4, 0x0 }, - { 0x3, 0x0 }, - { 0x3, 0x0 }, - { 0x1, 0x0 }, - { 0x2, 0x0 }, - { 0x4, 0x1 }, - { 0x4, 0x1 }, - { 0x4, 0x1 }, - { 0x1, 0x0 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x4, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x3, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x3, 0x0 }, - { 0x5, 0x0 }, - { 0x5, 0x0 }, - { 0x1, 0x0 }, - { 0x4, 0x0 }, - { 0x2, 0x1 }, - { 0x3, 0x1 }, - { 0x5, 0x1 }, - { 0x5, 0x1 }, - { 0x5, 0x1 }, - { 0x5, 0x1 }, - { 0x5, 0x0 }, - { 0x2, 0x1 }, - { 0x4, 0x0 }, - { 0x2, 0x0 }, - { 0x1, 0x0 }, - { 0x1, 0x1 }, - { 0x3, 0x0 }, - { 0x3, 0x1 }, - { 0x3, 0x0 }, - { 0x3, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x0 }, - { 0x3, 0x1 }, - { 0x4, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x0 }, - { 0x1, 0x0 }, - { 0x2, 0x0 }, - { 0x2, 0x0 }, - { 0x1, 0x0 }, - { 0x2, 0x0 }, - { 0x1, 0x0 }, - { 0x4, 0x0 }, - { 0x1, 0x0 }, - { 0x1, 0x1 }, - { 0x5, 0x1 }, - { 0x2, 0x1 }, - { 0x5, 0x1 }, - { 0x5, 0x1 }, - { 0x2, 0x1 }, - { 0x5, 0x1 }, - { 0x5, 0x1 }, - { 0x5, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x0 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x4, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x0 }, - { 0x1, 0x0 }, - { 0x2, 0x1 }, - { 0x1, 0x0 }, - { 0x1, 0x0 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x3, 0x1 }, - { 0x1, 0x1 }, - { 0x3, 0x0 }, - { 0x3, 0x0 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x3, 0x0 }, - { 0x3, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x3, 0x1 }, - { 0x3, 0x1 }, - { 0x5, 0x0 }, - { 0x5, 0x0 }, - { 0x4, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x4, 0x1 }, - { 0x3, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x2, 0x1 }, - { 0x3, 0x1 }, - { 0x3, 0x1 }, - { 0x3, 0x1 }, - { 0x3, 0x1 }, - { 0x4, 0x0 }, - { 0x1, 0x0 }, - { 0x2, 0x0 }, - { 0x1, 0x0 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x5, 0x0 }, - { 0x4, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x4, 0x1 }, - { 0x5, 0x1 }, - { 0x2, 0x1 }, - { 0x5, 0x1 }, - { 0x3, 0x0 }, - { 0x1, 0x0 }, - { 0x2, 0x0 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x1 }, - { 0x5, 0x1 }, - { 0x2, 0x1 }, - { 0x2, 0x0 }, - { 0x1, 0x0 }, - { 0x1, 0x0 }, - { 0x3, 0x1 }, - { 0x1, 0x1 }, - { 0x2, 0x1 } -}; - -u16 ov5_021F0E84(u16 param0) -{ - return Unk_ov5_021FFA54[param0].unk_00; -} - -u16 ov5_021F0E90(u16 param0, u16 param1) -{ - if ((param0 == SPECIES_GIRATINA) && (param1 == 1)) { - return 0; - } - - return Unk_ov5_021FFA54[param0].unk_02; -} diff --git a/src/overlay006/wild_encounters.c b/src/overlay006/wild_encounters.c index 8a808ae0e2..f0193e13fa 100644 --- a/src/overlay006/wild_encounters.c +++ b/src/overlay006/wild_encounters.c @@ -107,7 +107,7 @@ static void WildEncounters_ReplaceGreatMarshDailyEncounters(FieldSystem *fieldSy static BOOL RepelPreventsEncounter(const u8 param0, const WildEncounters_FieldParams *param1); static void AddRoamerToEnemyParty(const u32 param0, Roamer *param1, FieldBattleDTO *param2); static BOOL TryEncounterRoamer(FieldSystem *fieldSystem, Roamer **param1); -static BOOL AddWildMonToParty(const int partyId, const WildEncounters_FieldParams *fieldParams, Pokemon *mon, FieldBattleDTO *battleParams); +static BOOL AddWildMonToParty(const int partySlot, const WildEncounters_FieldParams *fieldParams, Pokemon *mon, FieldBattleDTO *battleParams); static u8 TryFindHigherLevelSlot(const EncounterSlot *encounterTable, const WildEncounters_FieldParams *fieldParams, const u8 encounterSlot); static void InitEncounterFieldParams(FieldSystem *fieldSystem, Pokemon *firstPartyMon, WildEncounters *encounterData, WildEncounters_FieldParams *param3); static void ModifyEncounterRateWithHeldItem(Pokemon *param0, u8 *param1); @@ -980,7 +980,7 @@ static u8 GetWildMonLevel(const EncounterSlot *slot, const WildEncounters_FieldP // Creates a mon with a personality that will make it shiny, and complies with Cute Charm/Synchronize. // It only has to check one or the other, not both, because only one ability can be in effect at a time. -static void CreateWildMonShinyWithGenderOrNature(const u16 species, const u8 level, const int partyId, const u32 param3, const WildEncounters_FieldParams *encounterFieldParams, Pokemon *firstPartyMon, FieldBattleDTO *battleParams) +static void CreateWildMonShinyWithGenderOrNature(const u16 species, const u8 level, const int partySlot, const u32 param3, const WildEncounters_FieldParams *encounterFieldParams, Pokemon *firstPartyMon, FieldBattleDTO *battleParams) { u8 firstMonGender; u8 firstMonNature; @@ -1040,7 +1040,7 @@ static void CreateWildMonShinyWithGenderOrNature(const u16 species, const u8 lev Pokemon_InitWith(newEncounter, species, level, INIT_IVS_RANDOM, TRUE, newEncounterPersonality, OTID_SET, encounterFieldParams->trainerID); - GF_ASSERT(AddWildMonToParty(partyId, encounterFieldParams, newEncounter, battleParams)); + GF_ASSERT(AddWildMonToParty(partySlot, encounterFieldParams, newEncounter, battleParams)); Heap_FreeToHeap(newEncounter); } @@ -1451,7 +1451,7 @@ static BOOL TryEncounterRoamer(FieldSystem *fieldSystem, Roamer **encounteredRoa return TRUE; } -static BOOL AddWildMonToParty(const int partyId, const WildEncounters_FieldParams *encounterFieldParams, Pokemon *mon, FieldBattleDTO *battleParams) +static BOOL AddWildMonToParty(const int partySlot, const WildEncounters_FieldParams *encounterFieldParams, Pokemon *mon, FieldBattleDTO *battleParams) { int hasCompoundEyes = 0; @@ -1493,7 +1493,7 @@ static BOOL AddWildMonToParty(const int partyId, const WildEncounters_FieldParam Pokemon_SetValue(mon, MON_DATA_FORM, &form); } - return Party_AddPokemon(battleParams->parties[partyId], mon); + return Party_AddPokemon(battleParams->parties[partySlot], mon); } static u8 TryFindHigherLevelSlot(const EncounterSlot *encounterTable, const WildEncounters_FieldParams *encounterFieldParams, const u8 encounterSlot) diff --git a/src/ribbon.c b/src/ribbon.c index cc7309beac..4ca1c86ea7 100644 --- a/src/ribbon.c +++ b/src/ribbon.c @@ -3,11 +3,13 @@ #include #include +#include "constants/pokemon.h" + #include "res/graphics/pokemon_summary_screen/pl_pst_gra.naix" #include "res/text/bank/ribbon_names.h" typedef struct { - u32 ribbonID; + enum PokemonDataParam monDataParam; u16 spriteID; u16 paletteNum; u16 nameID; @@ -21,560 +23,560 @@ typedef struct { static const RibbonData sRibbonDataTable[] = { [RIBBON_HOENN_CHAMPION] = { - .ribbonID = 98, + .monDataParam = MON_DATA_HOENN_CHAMPION_RIBBON, .spriteID = hoenn_champion_NCGR, .paletteNum = 0, .nameID = ribbon_name_hoenn_champion, .descriptionID = ribbon_desc_hoenn_champion, }, [RIBBON_HOENN_COOL] = { - .ribbonID = 78, + .monDataParam = MON_DATA_HOENN_COOL_RIBBON, .spriteID = hoenn_contest_NCGR, .paletteNum = 0, .nameID = ribbon_name_hoenn_cool, .descriptionID = ribbon_desc_hoenn_cool, }, [RIBBON_HOENN_COOL_SUPER] = { - .ribbonID = 79, + .monDataParam = MON_DATA_HOENN_COOL_RIBBON_SUPER, .spriteID = hoenn_contest_super_NCGR, .paletteNum = 0, .nameID = ribbon_name_hoenn_cool_super, .descriptionID = ribbon_desc_hoenn_cool_super, }, [RIBBON_HOENN_COOL_HYPER] = { - .ribbonID = 80, + .monDataParam = MON_DATA_HOENN_COOL_RIBBON_HYPER, .spriteID = hoenn_contest_hyper_NCGR, .paletteNum = 0, .nameID = ribbon_name_hoenn_cool_hyper, .descriptionID = ribbon_desc_hoenn_cool_hyper, }, [RIBBON_HOENN_COOL_MASTER] = { - .ribbonID = 81, + .monDataParam = MON_DATA_HOENN_COOL_RIBBON_MASTER, .spriteID = hoenn_contest_master_NCGR, .paletteNum = 0, .nameID = ribbon_name_hoenn_cool_master, .descriptionID = ribbon_desc_hoenn_cool_master, }, [RIBBON_HOENN_BEAUTY] = { - .ribbonID = 82, + .monDataParam = MON_DATA_HOENN_BEAUTY_RIBBON, .spriteID = hoenn_contest_NCGR, .paletteNum = 1, .nameID = ribbon_name_hoenn_beauty, .descriptionID = ribbon_desc_hoenn_beauty, }, [RIBBON_HOENN_BEAUTY_SUPER] = { - .ribbonID = 83, + .monDataParam = MON_DATA_HOENN_BEAUTY_RIBBON_SUPER, .spriteID = hoenn_contest_super_NCGR, .paletteNum = 1, .nameID = ribbon_name_hoenn_beauty_super, .descriptionID = ribbon_desc_hoenn_beauty_super, }, [RIBBON_HOENN_BEAUTY_HYPER] = { - .ribbonID = 84, + .monDataParam = MON_DATA_HOENN_BEAUTY_RIBBON_HYPER, .spriteID = hoenn_contest_hyper_NCGR, .paletteNum = 1, .nameID = ribbon_name_hoenn_beauty_hyper, .descriptionID = ribbon_desc_hoenn_beauty_hyper, }, [RIBBON_HOENN_BEAUTY_MASTER] = { - .ribbonID = 85, + .monDataParam = MON_DATA_HOENN_BEAUTY_RIBBON_MASTER, .spriteID = hoenn_contest_master_NCGR, .paletteNum = 1, .nameID = ribbon_name_hoenn_beauty_master, .descriptionID = ribbon_desc_hoenn_beauty_master, }, [RIBBON_HOENN_CUTE] = { - .ribbonID = 86, + .monDataParam = MON_DATA_HOENN_CUTE_RIBBON, .spriteID = hoenn_contest_NCGR, .paletteNum = 2, .nameID = ribbon_name_hoenn_cute, .descriptionID = ribbon_desc_hoenn_cute, }, [RIBBON_HOENN_CUTE_SUPER] = { - .ribbonID = 87, + .monDataParam = MON_DATA_HOENN_CUTE_RIBBON_SUPER, .spriteID = hoenn_contest_super_NCGR, .paletteNum = 2, .nameID = ribbon_name_hoenn_cute_super, .descriptionID = ribbon_desc_hoenn_cute_super, }, [RIBBON_HOENN_CUTE_HYPER] = { - .ribbonID = 88, + .monDataParam = MON_DATA_HOENN_CUTE_RIBBON_HYPER, .spriteID = hoenn_contest_hyper_NCGR, .paletteNum = 2, .nameID = ribbon_name_hoenn_cute_hyper, .descriptionID = ribbon_desc_hoenn_cute_hyper, }, [RIBBON_HOENN_CUTE_MASTER] = { - .ribbonID = 89, + .monDataParam = MON_DATA_HOENN_CUTE_RIBBON_MASTER, .spriteID = hoenn_contest_master_NCGR, .paletteNum = 2, .nameID = ribbon_name_hoenn_cute_master, .descriptionID = ribbon_desc_hoenn_cute_master, }, [RIBBON_HOENN_SMART] = { - .ribbonID = 90, + .monDataParam = MON_DATA_HOENN_SMART_RIBBON, .spriteID = hoenn_contest_NCGR, .paletteNum = 3, .nameID = ribbon_name_hoenn_smart, .descriptionID = ribbon_desc_hoenn_smart, }, [RIBBON_HOENN_SMART_SUPER] = { - .ribbonID = 91, + .monDataParam = MON_DATA_HOENN_SMART_RIBBON_SUPER, .spriteID = hoenn_contest_super_NCGR, .paletteNum = 3, .nameID = ribbon_name_hoenn_smart_super, .descriptionID = ribbon_desc_hoenn_smart_super, }, [RIBBON_HOENN_SMART_HYPER] = { - .ribbonID = 92, + .monDataParam = MON_DATA_HOENN_SMART_RIBBON_HYPER, .spriteID = hoenn_contest_hyper_NCGR, .paletteNum = 3, .nameID = ribbon_name_hoenn_smart_hyper, .descriptionID = ribbon_desc_hoenn_smart_hyper, }, [RIBBON_HOENN_SMART_MASTER] = { - .ribbonID = 93, + .monDataParam = MON_DATA_HOENN_SMART_RIBBON_MASTER, .spriteID = hoenn_contest_master_NCGR, .paletteNum = 3, .nameID = ribbon_name_hoenn_smart_master, .descriptionID = ribbon_desc_hoenn_smart_master, }, [RIBBON_HOENN_TOUGH] = { - .ribbonID = 94, + .monDataParam = MON_DATA_HOENN_TOUGH_RIBBON, .spriteID = hoenn_contest_NCGR, .paletteNum = 4, .nameID = ribbon_name_hoenn_tough, .descriptionID = ribbon_desc_hoenn_tough, }, [RIBBON_HOENN_TOUGH_SUPER] = { - .ribbonID = 95, + .monDataParam = MON_DATA_HOENN_TOUGH_RIBBON_SUPER, .spriteID = hoenn_contest_super_NCGR, .paletteNum = 4, .nameID = ribbon_name_hoenn_tough_super, .descriptionID = ribbon_desc_hoenn_tough_super, }, [RIBBON_HOENN_TOUGH_HYPER] = { - .ribbonID = 96, + .monDataParam = MON_DATA_HOENN_TOUGH_RIBBON_HYPER, .spriteID = hoenn_contest_hyper_NCGR, .paletteNum = 4, .nameID = ribbon_name_hoenn_tough_hyper, .descriptionID = ribbon_desc_hoenn_tough_hyper, }, [RIBBON_HOENN_TOUGH_MASTER] = { - .ribbonID = 97, + .monDataParam = MON_DATA_HOENN_TOUGH_RIBBON_MASTER, .spriteID = hoenn_contest_master_NCGR, .paletteNum = 4, .nameID = ribbon_name_hoenn_tough_master, .descriptionID = ribbon_desc_hoenn_tough_master, }, [RIBBON_HOENN_WINNING] = { - .ribbonID = 99, + .monDataParam = MON_DATA_HOENN_WINNING_RIBBON, .spriteID = hoenn_winning_NCGR, .paletteNum = 0, .nameID = ribbon_name_hoenn_winning, .descriptionID = ribbon_desc_hoenn_winning, }, [RIBBON_HOENN_VICTORY] = { - .ribbonID = 100, + .monDataParam = MON_DATA_HOENN_VICTORY_RIBBON, .spriteID = hoenn_victory_NCGR, .paletteNum = 0, .nameID = ribbon_name_hoenn_victory, .descriptionID = ribbon_desc_hoenn_victory, }, [RIBBON_HOENN_ARTIST] = { - .ribbonID = 101, + .monDataParam = MON_DATA_HOENN_ARTIST_RIBBON, .spriteID = hoenn_artist_NCGR, .paletteNum = 1, .nameID = ribbon_name_hoenn_artist, .descriptionID = ribbon_desc_hoenn_artist, }, [RIBBON_HOENN_EFFORT] = { - .ribbonID = 102, + .monDataParam = MON_DATA_HOENN_EFFORT_RIBBON, .spriteID = hoenn_effort_NCGR, .paletteNum = 2, .nameID = ribbon_name_hoenn_effort, .descriptionID = ribbon_desc_hoenn_effort, }, [RIBBON_HOENN_MARINE] = { - .ribbonID = 103, + .monDataParam = MON_DATA_HOENN_MARINE_RIBBON, .spriteID = hoenn_marine_land_sky_NCGR, .paletteNum = 1, .nameID = ribbon_name_hoenn_marine, .descriptionID = SPECIAL_DESCRIPTION_MASK | 0, }, [RIBBON_HOENN_LAND] = { - .ribbonID = 104, + .monDataParam = MON_DATA_HOENN_LAND_RIBBON, .spriteID = hoenn_marine_land_sky_NCGR, .paletteNum = 3, .nameID = ribbon_name_hoenn_land, .descriptionID = SPECIAL_DESCRIPTION_MASK | 1, }, [RIBBON_HOENN_SKY] = { - .ribbonID = 105, + .monDataParam = MON_DATA_HOENN_SKY_RIBBON, .spriteID = hoenn_marine_land_sky_NCGR, .paletteNum = 4, .nameID = ribbon_name_hoenn_sky, .descriptionID = SPECIAL_DESCRIPTION_MASK | 2, }, [RIBBON_HOENN_COUNTRY] = { - .ribbonID = 106, + .monDataParam = MON_DATA_HOENN_COUNTRY_RIBBON, .spriteID = hoenn_country_national_NCGR, .paletteNum = 3, .nameID = ribbon_name_hoenn_country, .descriptionID = ribbon_desc_hoenn_country_world, }, [RIBBON_HOENN_NATIONAL] = { - .ribbonID = 107, + .monDataParam = MON_DATA_HOENN_NATIONAL_RIBBON, .spriteID = hoenn_country_national_NCGR, .paletteNum = 4, .nameID = ribbon_name_hoenn_national, .descriptionID = ribbon_desc_hoenn_national, }, [RIBBON_HOENN_EARTH] = { - .ribbonID = 108, + .monDataParam = MON_DATA_HOENN_EARTH_RIBBON, .spriteID = hoenn_earth_world_NCGR, .paletteNum = 0, .nameID = ribbon_name_hoenn_earth, .descriptionID = ribbon_desc_hoenn_earth, }, [RIBBON_HOENN_WORLD] = { - .ribbonID = 109, + .monDataParam = MON_DATA_HOENN_WORLD_RIBBON, .spriteID = hoenn_earth_world_NCGR, .paletteNum = 1, .nameID = ribbon_name_hoenn_world, .descriptionID = ribbon_desc_hoenn_country_world, }, [RIBBON_SINNOH_CHAMP] = { - .ribbonID = 25, + .monDataParam = MON_DATA_SINNOH_CHAMP_RIBBON, .spriteID = sinnoh_champion_NCGR, .paletteNum = 0, .nameID = ribbon_name_sinnoh_champ, .descriptionID = ribbon_desc_sinnoh_champ, }, [RIBBON_COOL] = { - .ribbonID = 123, + .monDataParam = MON_DATA_SINNOH_SUPER_COOL_RIBBON, .spriteID = sinnoh_contest_NCGR, .paletteNum = 0, .nameID = ribbon_name_cool, .descriptionID = ribbon_desc_cool, }, [RIBBON_COOL_GREAT] = { - .ribbonID = 124, + .monDataParam = MON_DATA_SINNOH_SUPER_COOL_RIBBON_GREAT, .spriteID = sinnoh_contest_great_NCGR, .paletteNum = 0, .nameID = ribbon_name_cool_great, .descriptionID = ribbon_desc_cool_great, }, [RIBBON_COOL_ULTRA] = { - .ribbonID = 125, + .monDataParam = MON_DATA_SINNOH_SUPER_COOL_RIBBON_ULTRA, .spriteID = sinnoh_contest_ultra_NCGR, .paletteNum = 0, .nameID = ribbon_name_cool_ultra, .descriptionID = ribbon_desc_cool_ultra, }, [RIBBON_COOL_MASTER] = { - .ribbonID = 126, + .monDataParam = MON_DATA_SINNOH_SUPER_COOL_RIBBON_MASTER, .spriteID = sinnoh_contest_master_NCGR, .paletteNum = 0, .nameID = ribbon_name_cool_master, .descriptionID = ribbon_desc_cool_master, }, [RIBBON_BEAUTY] = { - .ribbonID = 127, + .monDataParam = MON_DATA_SINNOH_SUPER_BEAUTY_RIBBON, .spriteID = sinnoh_contest_NCGR, .paletteNum = 1, .nameID = ribbon_name_beauty, .descriptionID = ribbon_desc_beauty, }, [RIBBON_BEAUTY_GREAT] = { - .ribbonID = 128, + .monDataParam = MON_DATA_SINNOH_SUPER_BEAUTY_RIBBON_GREAT, .spriteID = sinnoh_contest_great_NCGR, .paletteNum = 1, .nameID = ribbon_name_beauty_great, .descriptionID = ribbon_desc_beauty_great, }, [RIBBON_BEAUTY_ULTRA] = { - .ribbonID = 129, + .monDataParam = MON_DATA_SINNOH_SUPER_BEAUTY_RIBBON_ULTRA, .spriteID = sinnoh_contest_ultra_NCGR, .paletteNum = 1, .nameID = ribbon_name_beauty_ultra, .descriptionID = ribbon_desc_beauty_ultra, }, [RIBBON_BEAUTY_MASTER] = { - .ribbonID = 130, + .monDataParam = MON_DATA_SINNOH_SUPER_BEAUTY_RIBBON_MASTER, .spriteID = sinnoh_contest_master_NCGR, .paletteNum = 1, .nameID = ribbon_name_beauty_master, .descriptionID = ribbon_desc_beauty_master, }, [RIBBON_CUTE] = { - .ribbonID = 131, + .monDataParam = MON_DATA_SINNOH_SUPER_CUTE_RIBBON, .spriteID = sinnoh_contest_NCGR, .paletteNum = 2, .nameID = ribbon_name_cute, .descriptionID = ribbon_desc_cute, }, [RIBBON_CUTE_GREAT] = { - .ribbonID = 132, + .monDataParam = MON_DATA_SINNOH_SUPER_CUTE_RIBBON_GREAT, .spriteID = sinnoh_contest_great_NCGR, .paletteNum = 2, .nameID = ribbon_name_cute_great, .descriptionID = ribbon_desc_cute_great, }, [RIBBON_CUTE_ULTRA] = { - .ribbonID = 133, + .monDataParam = MON_DATA_SINNOH_SUPER_CUTE_RIBBON_ULTRA, .spriteID = sinnoh_contest_ultra_NCGR, .paletteNum = 2, .nameID = ribbon_name_cute_ultra, .descriptionID = ribbon_desc_cute_ultra, }, [RIBBON_CUTE_MASTER] = { - .ribbonID = 134, + .monDataParam = MON_DATA_SINNOH_SUPER_CUTE_RIBBON_MASTER, .spriteID = sinnoh_contest_master_NCGR, .paletteNum = 2, .nameID = ribbon_name_cute_master, .descriptionID = ribbon_desc_cute_master, }, [RIBBON_SMART] = { - .ribbonID = 135, + .monDataParam = MON_DATA_SINNOH_SUPER_SMART_RIBBON, .spriteID = sinnoh_contest_NCGR, .paletteNum = 3, .nameID = ribbon_name_smart, .descriptionID = ribbon_desc_smart, }, [RIBBON_SMART_GREAT] = { - .ribbonID = 136, + .monDataParam = MON_DATA_SINNOH_SUPER_SMART_RIBBON_GREAT, .spriteID = sinnoh_contest_great_NCGR, .paletteNum = 3, .nameID = ribbon_name_smart_great, .descriptionID = ribbon_desc_smart_great, }, [RIBBON_SMART_ULTRA] = { - .ribbonID = 137, + .monDataParam = MON_DATA_SINNOH_SUPER_SMART_RIBBON_ULTRA, .spriteID = sinnoh_contest_ultra_NCGR, .paletteNum = 3, .nameID = ribbon_name_smart_ultra, .descriptionID = ribbon_desc_smart_ultra, }, [RIBBON_SMART_MASTER] = { - .ribbonID = 138, + .monDataParam = MON_DATA_SINNOH_SUPER_SMART_RIBBON_MASTER, .spriteID = sinnoh_contest_master_NCGR, .paletteNum = 3, .nameID = ribbon_name_smart_master, .descriptionID = ribbon_desc_smart_master, }, [RIBBON_TOUGH] = { - .ribbonID = 139, + .monDataParam = MON_DATA_SINNOH_SUPER_TOUGH_RIBBON, .spriteID = sinnoh_contest_NCGR, .paletteNum = 4, .nameID = ribbon_name_tough, .descriptionID = ribbon_desc_tough, }, [RIBBON_TOUGH_GREAT] = { - .ribbonID = 140, + .monDataParam = MON_DATA_SINNOH_SUPER_TOUGH_RIBBON_GREAT, .spriteID = sinnoh_contest_great_NCGR, .paletteNum = 4, .nameID = ribbon_name_tough_great, .descriptionID = ribbon_desc_tough_great, }, [RIBBON_TOUGH_ULTRA] = { - .ribbonID = 141, + .monDataParam = MON_DATA_SINNOH_SUPER_TOUGH_RIBBON_ULTRA, .spriteID = sinnoh_contest_ultra_NCGR, .paletteNum = 4, .nameID = ribbon_name_tough_ultra, .descriptionID = ribbon_desc_tough_ultra, }, [RIBBON_TOUGH_MASTER] = { - .ribbonID = 142, + .monDataParam = MON_DATA_SINNOH_SUPER_TOUGH_RIBBON_MASTER, .spriteID = sinnoh_contest_master_NCGR, .paletteNum = 4, .nameID = ribbon_name_tough_master, .descriptionID = ribbon_desc_tough_master, }, [RIBBON_ABILITY] = { - .ribbonID = 26, + .monDataParam = MON_DATA_SINNOH_ABILITY_RIBBON, .spriteID = ability_NCGR, .paletteNum = 0, .nameID = ribbon_name_ability, .descriptionID = ribbon_desc_ability, }, [RIBBON_GREAT_ABILITY] = { - .ribbonID = 27, + .monDataParam = MON_DATA_SINNOH_GREAT_ABILITY_RIBBON, .spriteID = great_ability_NCGR, .paletteNum = 0, .nameID = ribbon_name_great_ability, .descriptionID = ribbon_desc_great_ability, }, [RIBBON_DOUBLE_ABILITY] = { - .ribbonID = 28, + .monDataParam = MON_DATA_SINNOH_DOUBLE_ABILITY_RIBBON, .spriteID = double_ability_NCGR, .paletteNum = 0, .nameID = ribbon_name_double_ability, .descriptionID = ribbon_desc_double_ability, }, [RIBBON_MULTI_ABILITY] = { - .ribbonID = 29, + .monDataParam = MON_DATA_SINNOH_MULTI_ABILITY_RIBBON, .spriteID = multi_ability_NCGR, .paletteNum = 0, .nameID = ribbon_name_multi_ability, .descriptionID = ribbon_desc_multi_ability, }, [RIBBON_PAIR_ABILITY] = { - .ribbonID = 30, + .monDataParam = MON_DATA_SINNOH_PAIR_ABILITY_RIBBON, .spriteID = pair_ability_NCGR, .paletteNum = 0, .nameID = ribbon_name_pair_ability, .descriptionID = ribbon_desc_pair_ability, }, [RIBBON_WORLD_ABILITY] = { - .ribbonID = 31, + .monDataParam = MON_DATA_SINNOH_WORLD_ABILITY_RIBBON, .spriteID = world_ability_NCGR, .paletteNum = 0, .nameID = ribbon_name_world_ability, .descriptionID = ribbon_desc_world_ability, }, [RIBBON_ALERT] = { - .ribbonID = 32, + .monDataParam = MON_DATA_SINNOH_ALERT_RIBBON, .spriteID = alert_NCGR, .paletteNum = 2, .nameID = ribbon_name_alert, .descriptionID = ribbon_desc_alert, }, [RIBBON_SHOCK] = { - .ribbonID = 33, + .monDataParam = MON_DATA_SINNOH_SHOCK_RIBBON, .spriteID = shock_NCGR, .paletteNum = 0, .nameID = ribbon_name_shock, .descriptionID = ribbon_desc_shock, }, [RIBBON_DOWNCAST] = { - .ribbonID = 34, + .monDataParam = MON_DATA_SINNOH_DOWNCAST_RIBBON, .spriteID = downcast_NCGR, .paletteNum = 1, .nameID = ribbon_name_downcast, .descriptionID = ribbon_desc_downcast, }, [RIBBON_CARELESS] = { - .ribbonID = 35, + .monDataParam = MON_DATA_SINNOH_CARELESS_RIBBON, .spriteID = careless_NCGR, .paletteNum = 2, .nameID = ribbon_name_careless, .descriptionID = ribbon_desc_careless, }, [RIBBON_RELAX] = { - .ribbonID = 36, + .monDataParam = MON_DATA_SINNOH_RELAX_RIBBON, .spriteID = relax_NCGR, .paletteNum = 3, .nameID = ribbon_name_relax, .descriptionID = ribbon_desc_relax, }, [RIBBON_SNOOZE] = { - .ribbonID = 37, + .monDataParam = MON_DATA_SINNOH_SNOOZE_RIBBON, .spriteID = snooze_NCGR, .paletteNum = 0, .nameID = ribbon_name_snooze, .descriptionID = ribbon_desc_snooze, }, [RIBBON_SMILE] = { - .ribbonID = 38, + .monDataParam = MON_DATA_SINNOH_SMILE_RIBBON, .spriteID = smile_NCGR, .paletteNum = 2, .nameID = ribbon_name_smile, .descriptionID = ribbon_desc_smile, }, [RIBBON_GORGEOUS] = { - .ribbonID = 39, + .monDataParam = MON_DATA_SINNOH_GORGEOUS_RIBBON, .spriteID = gorgeous_NCGR, .paletteNum = 1, .nameID = ribbon_name_gorgeous, .descriptionID = ribbon_desc_gorgeous, }, [RIBBON_ROYAL] = { - .ribbonID = 40, + .monDataParam = MON_DATA_SINNOH_ROYAL_RIBBON, .spriteID = royal_NCGR, .paletteNum = 3, .nameID = ribbon_name_royal, .descriptionID = ribbon_desc_royal, }, [RIBBON_GORGEOUS_ROYAL] = { - .ribbonID = 41, + .monDataParam = MON_DATA_SINNOH_GORGEOUS_ROYAL_RIBBON, .spriteID = gorgeous_royal_NCGR, .paletteNum = 0, .nameID = ribbon_name_gorgeous_royal, .descriptionID = ribbon_desc_gorgeous_royal, }, [RIBBON_FOOTPRINT] = { - .ribbonID = 42, + .monDataParam = MON_DATA_SINNOH_FOOTPRINT_RIBBON, .spriteID = footprint_NCGR, .paletteNum = 0, .nameID = ribbon_name_footprint, .descriptionID = ribbon_desc_footprint, }, [RIBBON_RECORD] = { - .ribbonID = 43, + .monDataParam = MON_DATA_SINNOH_RECORD_RIBBON, .spriteID = record_NCGR, .paletteNum = 1, .nameID = ribbon_name_record, .descriptionID = ribbon_desc_record, }, [RIBBON_HISTORY] = { - .ribbonID = 44, + .monDataParam = MON_DATA_SINNOH_HISTORY_RIBBON, .spriteID = history_NCGR, .paletteNum = 3, .nameID = ribbon_name_history, .descriptionID = ribbon_desc_history, }, [RIBBON_LEGEND] = { - .ribbonID = 45, + .monDataParam = MON_DATA_SINNOH_LEGEND_RIBBON, .spriteID = legend_NCGR, .paletteNum = 0, .nameID = ribbon_name_legend, .descriptionID = ribbon_desc_legend, }, [RIBBON_RED] = { - .ribbonID = 46, + .monDataParam = MON_DATA_SINNOH_RED_RIBBON, .spriteID = red_NCGR, .paletteNum = 0, .nameID = ribbon_name_red, .descriptionID = SPECIAL_DESCRIPTION_MASK | 7, }, [RIBBON_GREEN] = { - .ribbonID = 47, + .monDataParam = MON_DATA_SINNOH_GREEN_RIBBON, .spriteID = green_NCGR, .paletteNum = 3, .nameID = ribbon_name_green, .descriptionID = SPECIAL_DESCRIPTION_MASK | 8, }, [RIBBON_BLUE] = { - .ribbonID = 48, + .monDataParam = MON_DATA_SINNOH_BLUE_RIBBON, .spriteID = blue_NCGR, .paletteNum = 1, .nameID = ribbon_name_blue, .descriptionID = SPECIAL_DESCRIPTION_MASK | 9, }, [RIBBON_FESTIVAL] = { - .ribbonID = 49, + .monDataParam = MON_DATA_SINNOH_FESTIVAL_RIBBON, .spriteID = festival_NCGR, .paletteNum = 1, .nameID = ribbon_name_festival, .descriptionID = SPECIAL_DESCRIPTION_MASK | 10, }, [RIBBON_CARNIVAL] = { - .ribbonID = 50, + .monDataParam = MON_DATA_SINNOH_CARNIVAL_RIBBON, .spriteID = carnival_NCGR, .paletteNum = 0, .nameID = ribbon_name_carnival, .descriptionID = SPECIAL_DESCRIPTION_MASK | 11, }, [RIBBON_CLASSIC] = { - .ribbonID = 51, + .monDataParam = MON_DATA_SINNOH_CLASSIC_RIBBON, .spriteID = classic_NCGR, .paletteNum = 1, .nameID = ribbon_name_classic, .descriptionID = SPECIAL_DESCRIPTION_MASK | 12, }, [RIBBON_PREMIER] = { - .ribbonID = 52, + .monDataParam = MON_DATA_SINNOH_PREMIER_RIBBON, .spriteID = premier_NCGR, .paletteNum = 0, .nameID = ribbon_name_premier, @@ -582,46 +584,46 @@ static const RibbonData sRibbonDataTable[] = { }, }; -u32 Ribbon_GetData(u8 ribbonNum, enum RibbonDataField field) +u32 Ribbon_GetData(u8 ribbonID, enum RibbonDataField field) { switch (field) { - case RIBBON_DATA_RIBBON_ID: - return sRibbonDataTable[ribbonNum].ribbonID; + case RIBBON_DATA_MON_DATA_PARAM: + return sRibbonDataTable[ribbonID].monDataParam; case RIBBON_DATA_SPRITE_ID: - return sRibbonDataTable[ribbonNum].spriteID; + return sRibbonDataTable[ribbonID].spriteID; case RIBBON_DATA_PALETTE_NUM: - return sRibbonDataTable[ribbonNum].paletteNum; + return sRibbonDataTable[ribbonID].paletteNum; case RIBBON_DATA_NAME_ID: - return sRibbonDataTable[ribbonNum].nameID; + return sRibbonDataTable[ribbonID].nameID; case RIBBON_DATA_DESCRIPTION_ID: - return sRibbonDataTable[ribbonNum].descriptionID; + return sRibbonDataTable[ribbonID].descriptionID; } return 0; } -u32 PokemonSummaryScreen_GetRibbonDescriptionID(u8 *specialRibbons, u8 ribbonNum) +u32 PokemonSummaryScreen_GetRibbonDescriptionID(u8 *specialRibbons, u8 ribbonID) { - if (sRibbonDataTable[ribbonNum].descriptionID & SPECIAL_DESCRIPTION_MASK) { - return SPECIAL_DESCRIPTIONS_START + specialRibbons[sRibbonDataTable[ribbonNum].descriptionID & 0xFF]; + if (sRibbonDataTable[ribbonID].descriptionID & SPECIAL_DESCRIPTION_MASK) { + return SPECIAL_DESCRIPTIONS_START + specialRibbons[sRibbonDataTable[ribbonID].descriptionID & 0xFF]; } - return sRibbonDataTable[ribbonNum].descriptionID; + return sRibbonDataTable[ribbonID].descriptionID; } -u8 Ribbon_TryGetSpecialDescriptionID(u8 ribbonNum) +u8 Ribbon_TryGetSpecialDescriptionID(u8 ribbonID) { - if (sRibbonDataTable[ribbonNum].descriptionID & SPECIAL_DESCRIPTION_MASK) { - return sRibbonDataTable[ribbonNum].descriptionID & 0xFF; + if (sRibbonDataTable[ribbonID].descriptionID & SPECIAL_DESCRIPTION_MASK) { + return sRibbonDataTable[ribbonID].descriptionID & 0xFF; } return 0xFF; } -u16 Ribbon_RibbonIDToNameID(u32 ribbonID) +u16 Ribbon_MonDataParamToNameID(enum PokemonDataParam monDataParam) { for (int i = 0; i < NELEMS(sRibbonDataTable); i++) { - if (sRibbonDataTable[i].ribbonID == ribbonID) { + if (sRibbonDataTable[i].monDataParam == monDataParam) { return sRibbonDataTable[i].nameID; } } diff --git a/src/scrcmd.c b/src/scrcmd.c index 24b7ffa3f4..75a9c9402d 100644 --- a/src/scrcmd.c +++ b/src/scrcmd.c @@ -47,6 +47,7 @@ #include "field/field_system.h" #include "field/field_system_sub2_t.h" #include "overlay005/field_menu.h" +#include "overlay005/footprint_type.h" #include "overlay005/honey_tree.h" #include "overlay005/land_data.h" #include "overlay005/map_object_anim_cmd.h" @@ -58,7 +59,6 @@ #include "overlay005/ov5_021EA874.h" #include "overlay005/ov5_021ECC20.h" #include "overlay005/ov5_021EE7D4.h" -#include "overlay005/ov5_021F0E84.h" #include "overlay005/ov5_021F6454.h" #include "overlay005/save_info_window.h" #include "overlay005/scrcmd_move_tutor.h" @@ -614,7 +614,7 @@ static BOOL ScrCmd_22D(ScriptContext *ctx); static BOOL ScrCmd_233(ScriptContext *ctx); static BOOL ScrCmd_GetDayOfWeek(ScriptContext *ctx); static BOOL ScrCmd_239(ScriptContext *ctx); -static BOOL ScrCmd_23A(ScriptContext *ctx); +static BOOL ScrCmd_GetSpeciesFootprintType(ScriptContext *ctx); static BOOL ScrCmd_23B(ScriptContext *ctx); static BOOL ScrCmd_23C(ScriptContext *ctx); static BOOL ScrCmd_23D(ScriptContext *ctx); @@ -1206,7 +1206,7 @@ const ScrCmdFunc Unk_020EAC58[] = { ScrCmd_GetTimeOfDay, ScrCmd_GetRandom, ScrCmd_GetRandom2, - ScrCmd_1B9, + ScrCmd_GetFriendshipByPartySlot, ScrCmd_1BA, ScrCmd_1BB, ScrCmd_1BC, @@ -1325,8 +1325,8 @@ const ScrCmdFunc Unk_020EAC58[] = { ScrCmd_22D, ScrCmd_22E, ScrCmd_22F, - ScrCmd_230, - ScrCmd_231, + ScrCmd_GetPartyMonRibbon, + ScrCmd_SetPartyMonRibbon, ScrCmd_232, ScrCmd_233, ScrCmd_GetDayOfWeek, @@ -1335,7 +1335,7 @@ const ScrCmdFunc Unk_020EAC58[] = { ScrCmd_237, ScrCmd_238, ScrCmd_239, - ScrCmd_23A, + ScrCmd_GetSpeciesFootprintType, ScrCmd_23B, ScrCmd_23C, ScrCmd_23D, @@ -1348,7 +1348,7 @@ const ScrCmdFunc Unk_020EAC58[] = { ScrCmd_244, ScrCmd_245, ScrCmd_246, - ScrCmd_247, + ScrCmd_GetFirstNonEggInParty, ScrCmd_248, ScrCmd_249, ScrCmd_24A, @@ -6573,21 +6573,21 @@ static BOOL ScrCmd_239(ScriptContext *ctx) return 1; } -static BOOL ScrCmd_23A(ScriptContext *ctx) +static BOOL ScrCmd_GetSpeciesFootprintType(ScriptContext *ctx) { - Pokemon *v0; - u16 *v1 = ScriptContext_GetVarPointer(ctx); - u16 *v2 = ScriptContext_GetVarPointer(ctx); - u16 v3 = ScriptContext_GetVar(ctx); - u16 v4, v5; + Pokemon *mon; + u16 *hasPrintVar = ScriptContext_GetVarPointer(ctx); + u16 *typeVar = ScriptContext_GetVarPointer(ctx); + u16 slot = ScriptContext_GetVar(ctx); + u16 species, form; - v0 = Party_GetPokemonBySlotIndex(Party_GetFromSavedata(ctx->fieldSystem->saveData), v3); - v4 = Pokemon_GetValue(v0, MON_DATA_SPECIES, NULL); - v5 = Pokemon_GetValue(v0, MON_DATA_FORM, NULL); - *v1 = ov5_021F0E90(v4, v5); - *v2 = ov5_021F0E84(v4); + mon = Party_GetPokemonBySlotIndex(Party_GetFromSavedata(ctx->fieldSystem->saveData), slot); + species = Pokemon_GetValue(mon, MON_DATA_SPECIES, NULL); + form = Pokemon_GetValue(mon, MON_DATA_FORM, NULL); + *hasPrintVar = FootprintType_SpeciesHasPrint(species, form); + *typeVar = FootprintType_GetTypeFromSpecies(species); - return 0; + return FALSE; } static BOOL ScrCmd_23B(ScriptContext *ctx) diff --git a/src/unk_0204B830.c b/src/unk_0204B830.c index fc2f77af31..f37c9370b3 100644 --- a/src/unk_0204B830.c +++ b/src/unk_0204B830.c @@ -231,43 +231,43 @@ static void sub_0204BAAC(FieldSystem *fieldSystem, void *param1) v13 = sub_0202D79C(fieldSystem->saveData); if (Pokemon_GetValue(v4, MON_DATA_SINNOH_RED_RIBBON, 0)) { - v13[Ribbon_TryGetSpecialDescriptionID(73)] = v14[0]; + v13[Ribbon_TryGetSpecialDescriptionID(RIBBON_RED)] = v14[0]; } if (Pokemon_GetValue(v4, MON_DATA_SINNOH_GREEN_RIBBON, 0)) { - v13[Ribbon_TryGetSpecialDescriptionID(74)] = v14[1]; + v13[Ribbon_TryGetSpecialDescriptionID(RIBBON_GREEN)] = v14[1]; } if (Pokemon_GetValue(v4, MON_DATA_SINNOH_BLUE_RIBBON, 0)) { - v13[Ribbon_TryGetSpecialDescriptionID(75)] = v14[2]; + v13[Ribbon_TryGetSpecialDescriptionID(RIBBON_BLUE)] = v14[2]; } if (Pokemon_GetValue(v4, MON_DATA_SINNOH_FESTIVAL_RIBBON, 0)) { - v13[Ribbon_TryGetSpecialDescriptionID(76)] = v14[3]; + v13[Ribbon_TryGetSpecialDescriptionID(RIBBON_FESTIVAL)] = v14[3]; } if (Pokemon_GetValue(v4, MON_DATA_SINNOH_CARNIVAL_RIBBON, 0)) { - v13[Ribbon_TryGetSpecialDescriptionID(77)] = v14[4]; + v13[Ribbon_TryGetSpecialDescriptionID(RIBBON_CARNIVAL)] = v14[4]; } if (Pokemon_GetValue(v4, MON_DATA_SINNOH_CLASSIC_RIBBON, 0)) { - v13[Ribbon_TryGetSpecialDescriptionID(78)] = v14[5]; + v13[Ribbon_TryGetSpecialDescriptionID(RIBBON_CLASSIC)] = v14[5]; } if (Pokemon_GetValue(v4, MON_DATA_SINNOH_PREMIER_RIBBON, 0)) { - v13[Ribbon_TryGetSpecialDescriptionID(79)] = v14[6]; + v13[Ribbon_TryGetSpecialDescriptionID(RIBBON_PREMIER)] = v14[6]; } if (Pokemon_GetValue(v4, MON_DATA_HOENN_MARINE_RIBBON, 0)) { - v13[Ribbon_TryGetSpecialDescriptionID(25)] = v14[7]; + v13[Ribbon_TryGetSpecialDescriptionID(RIBBON_HOENN_MARINE)] = v14[7]; } if (Pokemon_GetValue(v4, MON_DATA_HOENN_LAND_RIBBON, 0)) { - v13[Ribbon_TryGetSpecialDescriptionID(26)] = v14[8]; + v13[Ribbon_TryGetSpecialDescriptionID(RIBBON_HOENN_LAND)] = v14[8]; } if (Pokemon_GetValue(v4, MON_DATA_HOENN_SKY_RIBBON, 0)) { - v13[Ribbon_TryGetSpecialDescriptionID(27)] = v14[9]; + v13[Ribbon_TryGetSpecialDescriptionID(RIBBON_HOENN_SKY)] = v14[9]; } if (v0->val1.unk_00 == 0) { diff --git a/src/unk_0204CFFC.c b/src/unk_0204CFFC.c index 947233e7f7..b5ec907226 100644 --- a/src/unk_0204CFFC.c +++ b/src/unk_0204CFFC.c @@ -277,17 +277,17 @@ BOOL ScrCmd_213(ScriptContext *param0) return 0; } -BOOL ScrCmd_1B9(ScriptContext *param0) +BOOL ScrCmd_GetFriendshipByPartySlot(ScriptContext *ctx) { - FieldSystem *fieldSystem = param0->fieldSystem; - Pokemon *v1; - u16 *v2 = ScriptContext_GetVarPointer(param0); - u16 v3 = ScriptContext_GetVar(param0); + FieldSystem *fieldSystem = ctx->fieldSystem; + Pokemon *mon; + u16 *destVar = ScriptContext_GetVarPointer(ctx); + u16 slot = ScriptContext_GetVar(ctx); - v1 = Party_GetPokemonBySlotIndex(Party_GetFromSavedata(fieldSystem->saveData), v3); - *v2 = Pokemon_GetValue(v1, MON_DATA_FRIENDSHIP, NULL); + mon = Party_GetPokemonBySlotIndex(Party_GetFromSavedata(fieldSystem->saveData), slot); + *destVar = Pokemon_GetValue(mon, MON_DATA_FRIENDSHIP, NULL); - return 0; + return FALSE; } BOOL ScrCmd_1BA(ScriptContext *param0) @@ -360,12 +360,12 @@ BOOL ScrCmd_281(ScriptContext *param0) return 0; } -BOOL ScrCmd_247(ScriptContext *param0) +BOOL ScrCmd_GetFirstNonEggInParty(ScriptContext *ctx) { - u16 *v0 = ScriptContext_GetVarPointer(param0); + u16 *destVar = ScriptContext_GetVarPointer(ctx); - *v0 = sub_0205E1B4(param0->fieldSystem->saveData); - return 0; + *destVar = SaveData_GetFirstNonEggInParty(ctx->fieldSystem->saveData); + return FALSE; } BOOL ScrCmd_248(ScriptContext *param0) @@ -725,7 +725,7 @@ BOOL ScrCmd_22E(ScriptContext *param0) v0 = Party_GetPokemonBySlotIndex(Party_GetFromSavedata(param0->fieldSystem->saveData), v2); for (v3 = 0, v4 = 0; v3 < 80; v3++) { - if (Pokemon_GetValue(v0, Ribbon_GetData(v3, RIBBON_DATA_RIBBON_ID), NULL) != 0) { + if (Pokemon_GetValue(v0, Ribbon_GetData(v3, RIBBON_DATA_MON_DATA_PARAM), NULL) != 0) { v4++; } } @@ -750,7 +750,7 @@ BOOL ScrCmd_22F(ScriptContext *param0) v0 = Party_GetPokemonBySlotIndex(v1, v4); if (Pokemon_GetValue(v0, MON_DATA_IS_EGG, NULL) == 0) { - if (Pokemon_GetValue(v0, Ribbon_GetData(v3, RIBBON_DATA_RIBBON_ID), NULL) != 0) { + if (Pokemon_GetValue(v0, Ribbon_GetData(v3, RIBBON_DATA_MON_DATA_PARAM), NULL) != 0) { v5++; break; } @@ -763,33 +763,33 @@ BOOL ScrCmd_22F(ScriptContext *param0) return 0; } -BOOL ScrCmd_230(ScriptContext *param0) +BOOL ScrCmd_GetPartyMonRibbon(ScriptContext *ctx) { - Pokemon *v0; - u16 *v1 = ScriptContext_GetVarPointer(param0); - u16 v2 = ScriptContext_GetVar(param0); - u16 v3 = ScriptContext_GetVar(param0); - u8 v4 = 1; + Pokemon *mon; + u16 *hasRibbonVar = ScriptContext_GetVarPointer(ctx); + u16 slot = ScriptContext_GetVar(ctx); + u16 ribbonID = ScriptContext_GetVar(ctx); + u8 unused = 1; - v0 = Party_GetPokemonBySlotIndex(Party_GetFromSavedata(param0->fieldSystem->saveData), v2); - *v1 = Pokemon_GetValue(v0, Ribbon_GetData(v3, RIBBON_DATA_RIBBON_ID), NULL); + mon = Party_GetPokemonBySlotIndex(Party_GetFromSavedata(ctx->fieldSystem->saveData), slot); + *hasRibbonVar = Pokemon_GetValue(mon, Ribbon_GetData(ribbonID, RIBBON_DATA_MON_DATA_PARAM), NULL); - return 0; + return FALSE; } -BOOL ScrCmd_231(ScriptContext *param0) +BOOL ScrCmd_SetPartyMonRibbon(ScriptContext *ctx) { - Pokemon *v0; - u16 v1 = ScriptContext_GetVar(param0); - u16 v2 = ScriptContext_GetVar(param0); - u8 v3 = 1; + Pokemon *mon; + u16 slot = ScriptContext_GetVar(ctx); + u16 ribbonID = ScriptContext_GetVar(ctx); + u8 value = TRUE; - v0 = Party_GetPokemonBySlotIndex(Party_GetFromSavedata(param0->fieldSystem->saveData), v1); + mon = Party_GetPokemonBySlotIndex(Party_GetFromSavedata(ctx->fieldSystem->saveData), slot); - Pokemon_SetValue(v0, Ribbon_GetData(v2, RIBBON_DATA_RIBBON_ID), &v3); - sub_0206DDB8(param0->fieldSystem->saveData, v0, Ribbon_GetData(v2, RIBBON_DATA_RIBBON_ID)); + Pokemon_SetValue(mon, Ribbon_GetData(ribbonID, RIBBON_DATA_MON_DATA_PARAM), &value); + sub_0206DDB8(ctx->fieldSystem->saveData, mon, Ribbon_GetData(ribbonID, RIBBON_DATA_MON_DATA_PARAM)); - return 0; + return FALSE; } BOOL ScrCmd_2B7(ScriptContext *param0) diff --git a/src/unk_0205DFC4.c b/src/unk_0205DFC4.c index 7f4626a2a0..ba38b95e01 100644 --- a/src/unk_0205DFC4.c +++ b/src/unk_0205DFC4.c @@ -238,18 +238,15 @@ u16 sub_0205E0E4(u16 param0, u16 param1) } } -u16 sub_0205E1B4(SaveData *param0) +u16 SaveData_GetFirstNonEggInParty(SaveData *saveData) { - Pokemon *v0; - u16 v1, v2; + u16 i, partyCount = Party_GetCurrentCount(Party_GetFromSavedata(saveData)); - v2 = Party_GetCurrentCount(Party_GetFromSavedata(param0)); + for (i = 0; i < partyCount; i++) { + Pokemon *mon = Party_GetPokemonBySlotIndex(Party_GetFromSavedata(saveData), i); - for (v1 = 0; v1 < v2; v1++) { - v0 = Party_GetPokemonBySlotIndex(Party_GetFromSavedata(param0), v1); - - if (Pokemon_GetValue(v0, MON_DATA_IS_EGG, NULL) == 0) { - return v1; + if (Pokemon_GetValue(mon, MON_DATA_IS_EGG, NULL) == FALSE) { + return i; } } diff --git a/src/unk_0206CCB0.c b/src/unk_0206CCB0.c index 8ae31328c5..b97e9e667c 100644 --- a/src/unk_0206CCB0.c +++ b/src/unk_0206CCB0.c @@ -1366,13 +1366,13 @@ static int sub_0206DD5C(FieldSystem *fieldSystem, StringTemplate *param1, UnkStr return 3; } -void sub_0206DDB8(SaveData *param0, Pokemon *param1, u32 param2) +void sub_0206DDB8(SaveData *saveData, Pokemon *mon, u32 monDataParam) { u8 v0, v1; UnkUnion_0206D1B8 v2; UnkStruct_0206DE80 *v3 = &v2.val21; - v1 = sub_0206DE4C(param1); + v1 = sub_0206DE4C(mon); switch (v1) { case 15: @@ -1381,18 +1381,18 @@ void sub_0206DDB8(SaveData *param0, Pokemon *param1, u32 param2) case 30: case 35: case 40: - if (Ribbon_RibbonIDToNameID(param2) > 0xff) { + if (Ribbon_MonDataParamToNameID(monDataParam) > 0xff) { GF_ASSERT(0); return; } - sub_0206CE38(param1, &v3->unk_1C, &v3->unk_19, &v3->unk_1A, &v3->unk_1B); - sub_0206CED0(32, param1, &v3->unk_18, v3->unk_00); + sub_0206CE38(mon, &v3->unk_1C, &v3->unk_19, &v3->unk_1A, &v3->unk_1B); + sub_0206CED0(32, mon, &v3->unk_18, v3->unk_00); - v3->unk_16 = Ribbon_RibbonIDToNameID(param2); + v3->unk_16 = Ribbon_MonDataParamToNameID(monDataParam); v3->unk_17 = v1; - sub_0206CD7C(param0, 3, 5, v3); + sub_0206CD7C(saveData, 3, 5, v3); break; } } @@ -2828,7 +2828,7 @@ static int sub_0206F160(FieldSystem *fieldSystem, StringTemplate *param1, UnkStr Pokedex *pokedex = SaveData_GetPokedex(fieldSystem->saveData); party = Party_GetFromSavedata(fieldSystem->saveData); - pokemon = Party_GetPokemonBySlotIndex(party, sub_0205E1B4(fieldSystem->saveData)); + pokemon = Party_GetPokemonBySlotIndex(party, SaveData_GetFirstNonEggInParty(fieldSystem->saveData)); sub_0206CE74(param1, 0, Pokemon_GetValue(pokemon, MON_DATA_SPECIES, NULL), Pokemon_GetValue(pokemon, MON_DATA_GENDER, NULL), TrainerInfo_RegionCode(trainerInfo), TrainerInfo_GameCode(trainerInfo)); StringTemplate_SetContestAccessoryName(param1, 1, (LCRNG_Next() % 100));