From 15eb293e61498b0f49a2c767d65cae1b1e03fc57 Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Tue, 22 Nov 2022 02:59:27 -0500 Subject: [PATCH 01/25] [Fix] Create MQ saves when only MQ OTR loaded (#2001) Co-authored-by: briaguya --- soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c | 1 + 1 file changed, 1 insertion(+) diff --git a/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c b/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c index ece2ff48b..9d75c5753 100644 --- a/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c +++ b/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c @@ -488,6 +488,7 @@ void FileChoose_UpdateMainMenu(GameState* thisx) { this->configMode = CM_ROTATE_TO_QUEST_MENU; } else { this->configMode = CM_ROTATE_TO_NAME_ENTRY; + gSaveContext.isMasterQuest = MIN_QUEST == MASTER_QUEST; this->questType[this->buttonIndex] = MIN_QUEST; CVar_SetS32("gOnFileSelectNameEntry", 1); this->kbdButton = FS_KBD_BTN_NONE; From c87f0668489c020f8df124e92b76ddfe777da17a Mon Sep 17 00:00:00 2001 From: Adam Bird Date: Tue, 22 Nov 2022 03:17:51 -0500 Subject: [PATCH 02/25] [Fix] Allow turning in Ruto's letter after rescuing her (#1999) --- soh/src/overlays/actors/ovl_En_Kz/z_en_kz.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/soh/src/overlays/actors/ovl_En_Kz/z_en_kz.c b/soh/src/overlays/actors/ovl_En_Kz/z_en_kz.c index 6b2d4970e..337f136e9 100644 --- a/soh/src/overlays/actors/ovl_En_Kz/z_en_kz.c +++ b/soh/src/overlays/actors/ovl_En_Kz/z_en_kz.c @@ -75,6 +75,10 @@ u16 EnKz_GetTextNoMaskChild(PlayState* play, EnKz* this) { if ((gSaveContext.n64ddFlag && Flags_GetRandomizerInf(RAND_INF_DUNGEONS_DONE_JABU_JABUS_BELLY)) || (!gSaveContext.n64ddFlag && CHECK_QUEST_ITEM(QUEST_ZORA_SAPPHIRE))) { + // Allow turning in Ruto's letter even if you have already rescued her + if (gSaveContext.n64ddFlag && !(gSaveContext.eventChkInf[3] & 8)) { + player->exchangeItemId = EXCH_ITEM_LETTER_RUTO; + } return 0x402B; } else if (gSaveContext.eventChkInf[3] & 8) { return 0x401C; From b843937b345b0eedbad2610a67bfa2182dfd93a2 Mon Sep 17 00:00:00 2001 From: DeusVexus <10972000+DeusVexus@users.noreply.github.com> Date: Tue, 22 Nov 2022 00:30:12 -0800 Subject: [PATCH 03/25] [Fix] Rando: Like Likes should not eat tunics (#1978) --- soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c b/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c index f3a7a3c32..530bf5113 100644 --- a/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c +++ b/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c @@ -303,7 +303,7 @@ void EnRr_SetupReleasePlayer(EnRr* this, PlayState* play) { this->retreat = true; } } - if (CUR_EQUIP_VALUE(EQUIP_TUNIC) != 1 /* Kokiri tunic */) { + if (CUR_EQUIP_VALUE(EQUIP_TUNIC) != 1 /* Kokiri tunic */ && !gSaveContext.n64ddFlag /* Randomizer Save File */) { tunic = Inventory_DeleteEquipment(play, EQUIP_TUNIC); if (tunic != 0) { this->eatenTunic = tunic; From 67e325a0b97111d3fc6318737468334e3b2ddf5c Mon Sep 17 00:00:00 2001 From: Sarge-117 <108380086+Sarge-117@users.noreply.github.com> Date: Wed, 23 Nov 2022 17:53:10 -0800 Subject: [PATCH 04/25] Fix C-button counts and ice trap count (#2009) --- soh/src/code/z_play.c | 6 +++--- soh/src/overlays/actors/ovl_player_actor/z_player.c | 2 ++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/soh/src/code/z_play.c b/soh/src/code/z_play.c index 2cd647c79..830a22098 100644 --- a/soh/src/code/z_play.c +++ b/soh/src/code/z_play.c @@ -704,9 +704,9 @@ void Play_Update(PlayState* play) { if (CHECK_BTN_ALL(input[0].press.button, BTN_A)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_A]++;} if (CHECK_BTN_ALL(input[0].press.button, BTN_B)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_B]++;} if (CHECK_BTN_ALL(input[0].press.button, BTN_CUP)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_CUP]++;} - if (CHECK_BTN_ALL(input[0].press.button, BTN_CRIGHT)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_CLEFT]++;} - if (CHECK_BTN_ALL(input[0].press.button, BTN_CLEFT)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_CDOWN]++;} - if (CHECK_BTN_ALL(input[0].press.button, BTN_CDOWN)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_CRIGHT]++;} + if (CHECK_BTN_ALL(input[0].press.button, BTN_CRIGHT)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_CRIGHT]++;} + if (CHECK_BTN_ALL(input[0].press.button, BTN_CLEFT)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_CLEFT]++;} + if (CHECK_BTN_ALL(input[0].press.button, BTN_CDOWN)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_CDOWN]++;} if (CHECK_BTN_ALL(input[0].press.button, BTN_DUP)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_DUP]++;} if (CHECK_BTN_ALL(input[0].press.button, BTN_DRIGHT)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_DRIGHT]++;} if (CHECK_BTN_ALL(input[0].press.button, BTN_DDOWN)) {gSaveContext.sohStats.count[COUNT_BUTTON_PRESSES_DDOWN]++;} diff --git a/soh/src/overlays/actors/ovl_player_actor/z_player.c b/soh/src/overlays/actors/ovl_player_actor/z_player.c index 43057769a..ab26ee623 100644 --- a/soh/src/overlays/actors/ovl_player_actor/z_player.c +++ b/soh/src/overlays/actors/ovl_player_actor/z_player.c @@ -6305,6 +6305,8 @@ s32 func_8083E5A8(Player* this, PlayState* play) { Audio_PlayFanfare(NA_BGM_SMALL_ITEM_GET); this->getItemId = GI_NONE; this->getItemEntry = (GetItemEntry) GET_ITEM_NONE; + // Gameplay stats: Increment Ice Trap count + gSaveContext.sohStats.count[COUNT_ICE_TRAPS]++; return 1; } } From bd54ac5d157de53980173a0851ceafb48ecdc09b Mon Sep 17 00:00:00 2001 From: sonoftunk <59073987+sonoftunk@users.noreply.github.com> Date: Wed, 23 Nov 2022 21:05:48 -0500 Subject: [PATCH 05/25] Removes duplicated rando option enum for merchant (#2008) --- soh/soh/Enhancements/randomizer/randomizerTypes.h | 5 ----- 1 file changed, 5 deletions(-) diff --git a/soh/soh/Enhancements/randomizer/randomizerTypes.h b/soh/soh/Enhancements/randomizer/randomizerTypes.h index 459768321..cfc9ce473 100644 --- a/soh/soh/Enhancements/randomizer/randomizerTypes.h +++ b/soh/soh/Enhancements/randomizer/randomizerTypes.h @@ -1129,11 +1129,6 @@ typedef enum RandoOption { RO_SCRUBS_EXPENSIVE, RO_SCRUBS_RANDOM, - //Shuffle Merchants settings (off, on w/o hints, on w/hints) - RO_MERCHANTS_OFF = 0, - RO_MERCHANTS_ON_NO_HINTS, - RO_MERCHANTS_ON_WITH_HINTS, - //Ammo drop settings (on, "on+bombchu", off) RO_AMMO_DROPS_ON = 0, RO_AMMO_DROPS_ON_PLUS_BOMBCHU, From 80bb4577b0557ad4f541ddde4d869bd1c8cb9165 Mon Sep 17 00:00:00 2001 From: PurpleHato Date: Thu, 24 Nov 2022 19:17:47 +0100 Subject: [PATCH 06/25] Google Translation Strikes back (#2014) --- soh/soh/z_message_OTR.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/soh/soh/z_message_OTR.cpp b/soh/soh/z_message_OTR.cpp index 7bb65efdc..064b3059d 100644 --- a/soh/soh/z_message_OTR.cpp +++ b/soh/soh/z_message_OTR.cpp @@ -132,7 +132,7 @@ extern "C" void OTRMessage_Init() TEXTBOX_TYPE_BLUE, TEXTBOX_POS_BOTTOM, "You got a %rHeart Container%w!&You've collected %r{{heartContainerCount}}%w containers&in total!", "Du erhältst ein %rHerzgefäß%w! Du&hast insgesamt %r{{heartContainerCount}}%w Gefäße&gesammelt!", - "Vous obtenez un %rRécipient de&coeur%w! Vous avez&collecté %r{{heartContainerCount}}%w récipients en tout!" + "Vous obtenez un %rCoeur&d'Energie%w! Vous en avez&collecté %r{{heartContainerCount}}%w en tout!" } ); CustomMessageManager::Instance->CreateGetItemMessage( @@ -141,7 +141,7 @@ extern "C" void OTRMessage_Init() TEXTBOX_TYPE_BLUE, TEXTBOX_POS_BOTTOM, "You got a %rHeart Piece%w!&You've collected %r{{heartPieceCount}}%w pieces&in total!", "Du erhältst ein %rHerzteil%w! Du hast&insgesamt %r{{heartPieceCount}}%w Teile&gesammelt!", - "Vous obtenez un %rMorceau de&coeur%w! Vous avez&collecté %r{{heartPieceCount}}%w morceaux en tout!" + "Vous obtenez un %rQuart de&Coeur%w! Vous en avez collecté&%r{{heartPieceCount}}%w en tout!" } ); } From 1bf5fb64a5d7e927619458fbb8e8ad430fd3ac6b Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Sat, 26 Nov 2022 02:19:33 -0500 Subject: [PATCH 07/25] [Fix] Dodongo boss battle crashing with only mq otr (#2020) Co-authored-by: briaguya --- soh/src/overlays/actors/ovl_Boss_Dodongo/z_boss_dodongo.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/soh/src/overlays/actors/ovl_Boss_Dodongo/z_boss_dodongo.c b/soh/src/overlays/actors/ovl_Boss_Dodongo/z_boss_dodongo.c index 74ae077e3..052fdbb73 100644 --- a/soh/src/overlays/actors/ovl_Boss_Dodongo/z_boss_dodongo.c +++ b/soh/src/overlays/actors/ovl_Boss_Dodongo/z_boss_dodongo.c @@ -118,7 +118,10 @@ void func_808C12C4(u8* arg1, s16 arg2) { } void func_808C1554(void* arg0, void* floorTex, s32 arg2, f32 arg3) { - arg0 = ResourceMgr_LoadTexByName(arg0); + // Entering the King Dodongo boss battle was crashing when using only an mq otr + // because it was trying to load a texture from a non-mq path + // HACK: LoadTexByName doesn't account for mq vs non-mq paths, LoadTexOrDListByName does. + arg0 = ResourceMgr_LoadTexOrDListByName(arg0); floorTex = ResourceMgr_LoadTexByName(floorTex); u16* temp_s3 = SEGMENTED_TO_VIRTUAL(arg0); From 091b6a298725cb72ce1a8a7135bdbde4682773fd Mon Sep 17 00:00:00 2001 From: Garrett Cox Date: Sat, 26 Nov 2022 12:39:45 -0600 Subject: [PATCH 08/25] [Fix] Issue with first two rainbow bridge settings getting swapped (#2023) Fixes #2022 --- soh/soh/Enhancements/randomizer/randomizerTypes.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/soh/soh/Enhancements/randomizer/randomizerTypes.h b/soh/soh/Enhancements/randomizer/randomizerTypes.h index cfc9ce473..9a50db4de 100644 --- a/soh/soh/Enhancements/randomizer/randomizerTypes.h +++ b/soh/soh/Enhancements/randomizer/randomizerTypes.h @@ -1106,8 +1106,8 @@ typedef enum RandoOption { RO_GF_OPEN, //Rainbow Bridge settings (always open, vanilla, stones, medallions, dungeon rewards, dungeons, tokens) - RO_BRIDGE_VANILLA = 0, - RO_BRIDGE_ALWAYS_OPEN, + RO_BRIDGE_ALWAYS_OPEN = 0, + RO_BRIDGE_VANILLA, RO_BRIDGE_STONES, RO_BRIDGE_MEDALLIONS, RO_BRIDGE_DUNGEON_REWARDS, From c10e4a98ca497f475a9431f1bdc5f601d65a30a8 Mon Sep 17 00:00:00 2001 From: David Chavez Date: Sat, 26 Nov 2022 21:07:47 +0100 Subject: [PATCH 09/25] Bump version to Flynn: Bravo --- CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 88278ba7d..b5a6707b7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,8 +7,8 @@ set(CMAKE_CXX_STANDARD 20 CACHE STRING "The C++ standard to use") set(CMAKE_OSX_DEPLOYMENT_TARGET "10.15" CACHE STRING "Minimum OS X deployment version" FORCE) project(Ship LANGUAGES C CXX - VERSION 5.0.0) -set(PROJECT_BUILD_NAME "FLYNN ALFA" CACHE STRING "") + VERSION 5.0.1) +set(PROJECT_BUILD_NAME "FLYNN BRAVO" CACHE STRING "") set(PROJECT_TEAM "github.com/harbourmasters" CACHE STRING "") set_property(DIRECTORY ${CMAKE_SOURCE_DIR} PROPERTY VS_STARTUP_PROJECT soh) From 0424c5aaf3f3f55d390d1045bd001bb1e8fe98b6 Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Mon, 28 Nov 2022 16:41:33 -0500 Subject: [PATCH 10/25] fix: rando door of time enum usage (#2032) --- soh/soh/Enhancements/presets.h | 5 +++-- soh/soh/Enhancements/randomizer/randomizer.cpp | 4 ++-- soh/soh/Enhancements/randomizer/randomizerTypes.h | 6 +++--- soh/src/code/z_sram.c | 2 +- .../overlays/actors/ovl_En_Okarina_Tag/z_en_okarina_tag.c | 5 ++--- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/soh/soh/Enhancements/presets.h b/soh/soh/Enhancements/presets.h index b5c54de06..02768cb86 100644 --- a/soh/soh/Enhancements/presets.h +++ b/soh/soh/Enhancements/presets.h @@ -4,6 +4,7 @@ #include #include #include +#include "soh/Enhancements/randomizer/randomizerTypes.h" enum PresetEntryType { PRESET_ENTRY_TYPE_S32, @@ -551,7 +552,7 @@ const std::vector s6PresetEntries = { PRESET_ENTRY_S32("gMMBunnyHood", 2), PRESET_ENTRY_S32("gRandomizeBigPoeTargetCount", 1), PRESET_ENTRY_S32("gRandomizeCuccosToReturn", 4), - PRESET_ENTRY_S32("gRandomizeDoorOfTime", 2), + PRESET_ENTRY_S32("gRandomizeDoorOfTime", RO_DOOROFTIME_OPEN), PRESET_ENTRY_STRING("gRandomizeExcludedLocations", "48,"), PRESET_ENTRY_S32("gRandomizeForest", 1), PRESET_ENTRY_S32("gRandomizeGanonTrial", 0), @@ -586,7 +587,7 @@ const std::vector hellModePresetEntries = { PRESET_ENTRY_S32("gRandomizeBossKeysanity", 5), PRESET_ENTRY_S32("gRandomizeCompleteMaskQuest", 1), PRESET_ENTRY_S32("gRandomizeCuccosToReturn", 1), - PRESET_ENTRY_S32("gRandomizeDoorOfTime", 2), + PRESET_ENTRY_S32("gRandomizeDoorOfTime", RO_DOOROFTIME_OPEN), PRESET_ENTRY_S32("gRandomizeEnableBombchuDrops", 1), PRESET_ENTRY_S32("gRandomizeEnableGlitchCutscenes", 1), PRESET_ENTRY_S32("gRandomizeForest", 2), diff --git a/soh/soh/Enhancements/randomizer/randomizer.cpp b/soh/soh/Enhancements/randomizer/randomizer.cpp index d554714af..a6ebc50f9 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer.cpp @@ -2562,7 +2562,7 @@ void GenerateRandomizerImgui() { cvarSettings[RSK_LOGIC_RULES] = CVar_GetS32("gRandomizeLogicRules", 0); cvarSettings[RSK_FOREST] = CVar_GetS32("gRandomizeForest", 0); cvarSettings[RSK_KAK_GATE] = CVar_GetS32("gRandomizeKakarikoGate", 0); - cvarSettings[RSK_DOOR_OF_TIME] = CVar_GetS32("gRandomizeDoorOfTime", 0); + cvarSettings[RSK_DOOR_OF_TIME] = CVar_GetS32("gRandomizeDoorOfTime", RO_DOOROFTIME_CLOSED); cvarSettings[RSK_ZORAS_FOUNTAIN] = CVar_GetS32("gRandomizeZorasFountain", 0); cvarSettings[RSK_STARTING_AGE] = CVar_GetS32("gRandomizeStartingAge", 0); cvarSettings[RSK_GERUDO_FORTRESS] = CVar_GetS32("gRandomizeGerudoFortress", 0); @@ -2890,7 +2890,7 @@ void DrawRandoEditor(bool& open) { //RANDOTODO: Replace magic number checks with enums bool disableRandoStartingAge = (CVar_GetS32("gRandomizeLogicRules", 0) == 0) && // glitchless logic ((CVar_GetS32("gRandomizeForest", 0) == 0) || // Closed Forest - ((CVar_GetS32("gRandomizeDoorOfTime", 0) == 0) && // Closed Door of Time + ((CVar_GetS32("gRandomizeDoorOfTime", RO_DOOROFTIME_CLOSED) == RO_DOOROFTIME_CLOSED) && (CVar_GetS32("gRandomizeShuffleOcarinas", 0) == 0))); // ocarinas not shuffled const char* disableRandoStartingAgeText = "This option is disabled due to other options making the game unbeatable."; diff --git a/soh/soh/Enhancements/randomizer/randomizerTypes.h b/soh/soh/Enhancements/randomizer/randomizerTypes.h index 9a50db4de..8af56dc70 100644 --- a/soh/soh/Enhancements/randomizer/randomizerTypes.h +++ b/soh/soh/Enhancements/randomizer/randomizerTypes.h @@ -1085,10 +1085,10 @@ typedef enum RandoOption { RO_FOREST_CLOSED_DEKU, RO_FOREST_OPEN, - //Door of Time settings (open, song only, closed) - RO_DOOROFTIME_OPEN = 0, + //Door of Time settings (closed, song only, open) + RO_DOOROFTIME_CLOSED = 0, RO_DOOROFTIME_SONGONLY, - RO_DOOROFTIME_CLOSED, + RO_DOOROFTIME_OPEN, //Zora's Fountain settings (closed, closed as child, open) RO_ZF_CLOSED = 0, diff --git a/soh/src/code/z_sram.c b/soh/src/code/z_sram.c index 9337e7ce8..797a96177 100644 --- a/soh/src/code/z_sram.c +++ b/soh/src/code/z_sram.c @@ -399,7 +399,7 @@ void Sram_InitSave(FileChooseContext* fileChooseCtx) { int doorOfTime = Randomizer_GetSettingValue(RSK_DOOR_OF_TIME); switch (doorOfTime) { - case 0: // open + case RO_DOOROFTIME_OPEN: gSaveContext.eventChkInf[4] |= 0x800; break; } diff --git a/soh/src/overlays/actors/ovl_En_Okarina_Tag/z_en_okarina_tag.c b/soh/src/overlays/actors/ovl_En_Okarina_Tag/z_en_okarina_tag.c index d61528867..3c4b769cc 100644 --- a/soh/src/overlays/actors/ovl_En_Okarina_Tag/z_en_okarina_tag.c +++ b/soh/src/overlays/actors/ovl_En_Okarina_Tag/z_en_okarina_tag.c @@ -234,7 +234,7 @@ void func_80ABF4C8(EnOkarinaTag* this, PlayState* play) { if (play->msgCtx.ocarinaMode == OCARINA_MODE_04) { this->actionFunc = func_80ABF28C; } else if (play->msgCtx.ocarinaMode == OCARINA_MODE_03) { - if (!gSaveContext.n64ddFlag || (gSaveContext.n64ddFlag && Randomizer_GetSettingValue(RSK_DOOR_OF_TIME) != 2)) { + if (!gSaveContext.n64ddFlag || (gSaveContext.n64ddFlag && Randomizer_GetSettingValue(RSK_DOOR_OF_TIME) != RO_DOOROFTIME_CLOSED)) { func_80078884(NA_SE_SY_CORRECT_CHIME); } if (this->switchFlag >= 0) { @@ -257,8 +257,7 @@ void func_80ABF4C8(EnOkarinaTag* this, PlayState* play) { break; case 4: if (gSaveContext.n64ddFlag) { - int doorOfTime = Randomizer_GetSettingValue(RSK_DOOR_OF_TIME); - if (doorOfTime == 2 && + if (Randomizer_GetSettingValue(RSK_DOOR_OF_TIME) == RO_DOOROFTIME_CLOSED && (INV_CONTENT(ITEM_OCARINA_FAIRY) != ITEM_OCARINA_TIME || !CHECK_QUEST_ITEM(QUEST_KOKIRI_EMERALD) || !CHECK_QUEST_ITEM(QUEST_GORON_RUBY) || !CHECK_QUEST_ITEM(QUEST_ZORA_SAPPHIRE))) { From 9027d8567151d1d190febcf62e6ebb09567e6645 Mon Sep 17 00:00:00 2001 From: Ada <60364512+GreatArgorath@users.noreply.github.com> Date: Mon, 28 Nov 2022 22:45:07 +0000 Subject: [PATCH 11/25] TWEAK: Game controls menu simplification (#2007) --- .../controls/GameControlEditor.cpp | 48 ++++++++++++++++++ soh/soh/GameMenuBar.cpp | 50 +++---------------- 2 files changed, 56 insertions(+), 42 deletions(-) diff --git a/soh/soh/Enhancements/controls/GameControlEditor.cpp b/soh/soh/Enhancements/controls/GameControlEditor.cpp index 7d272909c..5907b77df 100644 --- a/soh/soh/Enhancements/controls/GameControlEditor.cpp +++ b/soh/soh/Enhancements/controls/GameControlEditor.cpp @@ -245,6 +245,52 @@ namespace GameControlEditor { UIWidgets::EnhancementSliderFloat("Camera Sensitivity: %d %%", "##Sensitivity", "gCameraSensitivity", 0.01f, 5.0f, "", 1.0f, true, true); } + void DrawDpadControlPanel() { + if (!ImGui::CollapsingHeader("D-Pad Controls")) { + return; + } + + ImVec2 cursor = ImGui::GetCursorPos(); + ImGui::SetCursorPos(ImVec2(cursor.x + 5, cursor.y + 5)); + SohImGui::BeginGroupPanel("D-Pad Options", ImGui::GetContentRegionAvail()); + UIWidgets::PaddedEnhancementCheckbox("D-pad Support on Pause Screen", "gDpadPause"); + DrawHelpIcon("Navigate Pause with the D-pad\nIf used with D-pad as Equip Items, you must hold C-Up to equip instead of navigate\n" + "To make the cursor only move a single space no matter how long a direction is held, manually set gDpadHoldChange to 0"); + UIWidgets::PaddedEnhancementCheckbox("D-pad Support in Text Boxes", "gDpadText"); + DrawHelpIcon("Navigate choices in text boxes, shop item selection, and the file select / name entry screens with the D-pad\n" + "To make the cursor only move a single space during name entry no matter how long a direction is held, manually set gDpadHoldChange to 0"); + UIWidgets::PaddedEnhancementCheckbox("D-pad as Equip Items", "gDpadEquips"); + DrawHelpIcon("Equip items and equipment on the D-pad\nIf used with D-pad on Pause Screen, you must hold C-Up to equip instead of navigate"); + SohImGui::EndGroupPanel(); + } + + void DrawMiscControlPanel() { + if (!ImGui::CollapsingHeader("Miscellaneous Controls")) { + return; + } + + ImVec2 cursor = ImGui::GetCursorPos(); + ImGui::SetCursorPos(ImVec2(cursor.x + 5, cursor.y + 5)); + SohImGui::BeginGroupPanel("Misc Controls", ImGui::GetContentRegionAvail()); + UIWidgets::PaddedEnhancementCheckbox("Enable walk speed modifiers", "gEnableWalkModify", true, false); + DrawHelpIcon("Hold the assigned button to change the maximum walking speed\nTo change the assigned button, go into the Ports tabs above"); + if (CVar_GetS32("gEnableWalkModify", 0)) { + UIWidgets::Spacer(5); + SohImGui::BeginGroupPanel("Walk Modifier", ImGui::GetContentRegionAvail()); + UIWidgets::PaddedEnhancementCheckbox("Toggle modifier instead of holding", "gWalkSpeedToggle", true, false); + UIWidgets::EnhancementSliderFloat("Modifier 1: %d %%", "##WalkMod1", "gWalkModifierOne", 0.0f, 5.0f, "", 1.0f, true); + UIWidgets::EnhancementSliderFloat("Modifier 2: %d %%", "##WalkMod2", "gWalkModifierTwo", 0.0f, 5.0f, "", 1.0f, true); + SohImGui::EndGroupPanel(); + } + UIWidgets::Spacer(0); + UIWidgets::PaddedEnhancementCheckbox("Allow the cursor to be on any slot", "gPauseAnyCursor"); + DrawHelpIcon("Allows the cursor on the pause menu to be over any slot\nSimilar to Rando and Spaceworld 97"); + UIWidgets::PaddedEnhancementCheckbox("Answer Navi Prompt with L Button", "gNaviOnL"); + DrawHelpIcon("Speak to Navi with L but enter first-person camera with C-Up"); + SohImGui::EndGroupPanel(); + + } + void DrawUI(bool& open) { if (!open) { CVar_SetS32("gGameControlEditorEnabled", false); @@ -271,6 +317,8 @@ namespace GameControlEditor { if (CurrentPort == 0) { DrawOcarinaControlPanel(); DrawCameraControlPanel(); + DrawDpadControlPanel(); + DrawMiscControlPanel(); } else { DrawCustomButtons(); } diff --git a/soh/soh/GameMenuBar.cpp b/soh/soh/GameMenuBar.cpp index 813df89b3..01befbad2 100644 --- a/soh/soh/GameMenuBar.cpp +++ b/soh/soh/GameMenuBar.cpp @@ -307,48 +307,6 @@ namespace GameMenuBar { UIWidgets::Spacer(0); - if (ImGui::BeginMenu("Controls")) { - ImGui::PushStyleVar(ImGuiStyleVar_FramePadding, ImVec2(12.0f, 6.0f)); - ImGui::PushStyleVar(ImGuiStyleVar_ButtonTextAlign, ImVec2(0, 0)); - ImGui::PushStyleVar(ImGuiStyleVar_FrameBorderSize, 1.0f); - ImGui::PushStyleColor(ImGuiCol_Border, ImVec4(0.22f, 0.38f, 0.56f, 1.0f)); - float availableWidth = ImGui::GetContentRegionAvail().x; - if (ImGui::Button( - GetWindowButtonText("Customize Game Controls", CVar_GetS32("gGameControlEditorEnabled", 0)).c_str(), - ImVec2(availableWidth, 0) - )) { - bool currentValue = CVar_GetS32("gGameControlEditorEnabled", 0); - CVar_SetS32("gGameControlEditorEnabled", !currentValue); - SohImGui::RequestCvarSaveOnNextTick(); - SohImGui::EnableWindow("Game Control Editor", CVar_GetS32("gGameControlEditorEnabled", 0)); - } - ImGui::PopStyleVar(3); - ImGui::PopStyleColor(1); - - UIWidgets::PaddedEnhancementCheckbox("D-pad Support on Pause Screen", "gDpadPause", true, false); - UIWidgets::Tooltip("Navigate Pause with the D-pad\nIf used with D-pad as Equip Items, you must hold C-Up to equip instead of navigate\n" - "To make the cursor only move a single space no matter how long a direction is held, manually set gDpadHoldChange to 0"); - UIWidgets::PaddedEnhancementCheckbox("D-pad Support in Text Boxes", "gDpadText", true, false); - UIWidgets::Tooltip("Navigate choices in text boxes, shop item selection, and the file select / name entry screens with the D-pad\n" - "To make the cursor only move a single space during name entry no matter how long a direction is held, manually set gDpadHoldChange to 0"); - UIWidgets::PaddedEnhancementCheckbox("D-pad as Equip Items", "gDpadEquips", true, false); - UIWidgets::Tooltip("Equip items and equipment on the D-pad\nIf used with D-pad on Pause Screen, you must hold C-Up to equip instead of navigate"); - UIWidgets::PaddedEnhancementCheckbox("Allow the cursor to be on any slot", "gPauseAnyCursor", true, false); - UIWidgets::Tooltip("Allows the cursor on the pause menu to be over any slot\nSimilar to Rando and Spaceworld 97"); - UIWidgets::PaddedEnhancementCheckbox("Answer Navi Prompt with L Button", "gNaviOnL", true, false); - UIWidgets::Tooltip("Speak to Navi with L but enter first-person camera with C-Up"); - UIWidgets::PaddedEnhancementCheckbox("Enable walk speed modifiers", "gEnableWalkModify", true, false); - UIWidgets::Tooltip("Hold the assigned button to change the maximum walking speed\nTo change the assigned button, click Customize Game Controls"); - if (CVar_GetS32("gEnableWalkModify", 0)) { - UIWidgets::PaddedEnhancementCheckbox("Toggle modifier instead of holding", "gWalkSpeedToggle", true, false); - UIWidgets::EnhancementSliderFloat("Modifier 1: %d %%", "##WalkMod1", "gWalkModifierOne", 0.0f, 5.0f, "", 1.0f, true); - UIWidgets::EnhancementSliderFloat("Modifier 2: %d %%", "##WalkMod2", "gWalkModifierTwo", 0.0f, 5.0f, "", 1.0f, true); - } - ImGui::EndMenu(); - } - - UIWidgets::Spacer(0); - if (ImGui::BeginMenu("Gameplay")) { if (ImGui::BeginMenu("Time Savers")) @@ -792,6 +750,14 @@ namespace GameMenuBar { ImGui::PushStyleVar(ImGuiStyleVar_ButtonTextAlign, ImVec2(0, 0)); ImGui::PushStyleVar(ImGuiStyleVar_FrameBorderSize, 1.0f); ImGui::PushStyleColor(ImGuiCol_Border, ImVec4(0.22f, 0.38f, 0.56f, 1.0f)); + + if (ImGui::Button(GetWindowButtonText("Customize Game Controls", CVar_GetS32("gGameControlEditorEnabled", 0)).c_str(), ImVec2(-1.0f, 0.0f))) + { + bool currentValue = CVar_GetS32("gGameControlEditorEnabled", 0); + CVar_SetS32("gGameControlEditorEnabled", !currentValue); + SohImGui::RequestCvarSaveOnNextTick(); + SohImGui::EnableWindow("Game Control Editor", CVar_GetS32("gGameControlEditorEnabled", 0)); + } if (ImGui::Button(GetWindowButtonText("Cosmetics Editor", CVar_GetS32("gCosmeticsEditorEnabled", 0)).c_str(), ImVec2(-1.0f, 0.0f))) { bool currentValue = CVar_GetS32("gCosmeticsEditorEnabled", 0); From 5037b99740a07205667471589e72f58302025901 Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Mon, 28 Nov 2022 17:49:21 -0500 Subject: [PATCH 12/25] rename 3drando dot enums to match soh enum naming (#2034) --- soh/soh/Enhancements/randomizer/3drando/hint_list.cpp | 4 ++-- soh/soh/Enhancements/randomizer/3drando/hints.cpp | 8 ++++---- soh/soh/Enhancements/randomizer/3drando/keys.hpp | 2 +- .../3drando/location_access/locacc_castle_town.cpp | 4 ++-- .../randomizer/3drando/setting_descriptions.cpp | 4 ++-- .../randomizer/3drando/setting_descriptions.hpp | 2 +- soh/soh/Enhancements/randomizer/3drando/settings.cpp | 4 ++-- soh/soh/Enhancements/randomizer/3drando/settings.hpp | 2 +- 8 files changed, 15 insertions(+), 15 deletions(-) diff --git a/soh/soh/Enhancements/randomizer/3drando/hint_list.cpp b/soh/soh/Enhancements/randomizer/3drando/hint_list.cpp index 040835979..d6cfa515b 100644 --- a/soh/soh/Enhancements/randomizer/3drando/hint_list.cpp +++ b/soh/soh/Enhancements/randomizer/3drando/hint_list.cpp @@ -2838,7 +2838,7 @@ void HintTable_Init() { /*spanish*/ "Para aquel que se convierta en el héroe...&La puerta al futuro está a su disposición..." }, }); - hintTable[CHILD_ALTAR_TEXT_END_DOTCLOSED] = HintText::Altar({ + hintTable[CHILD_ALTAR_TEXT_END_DOTSONGONLY] = HintText::Altar({ // obscure text Text{ "Ye who may become a Hero...&Stand with the Ocarina and&play the Song of Time.", @@ -2846,7 +2846,7 @@ void HintTable_Init() { /*spanish*/ "Para aquel que se convierta en el héroe...&Tome la ocarina y&entone la Canción del Tiempo." }, }); - hintTable[CHILD_ALTAR_TEXT_END_DOTINTENDED] = HintText::Altar({ + hintTable[CHILD_ALTAR_TEXT_END_DOTCLOSED] = HintText::Altar({ // obscure text Text{ "Ye who may become a Hero...&Offer the spiritual stones and&play the Song of Time.", /*french*/ diff --git a/soh/soh/Enhancements/randomizer/3drando/hints.cpp b/soh/soh/Enhancements/randomizer/3drando/hints.cpp index 9b30bc5a6..2b700d4a8 100644 --- a/soh/soh/Enhancements/randomizer/3drando/hints.cpp +++ b/soh/soh/Enhancements/randomizer/3drando/hints.cpp @@ -555,13 +555,13 @@ static Text BuildDoorOfTimeText() { itemObtained = "$o"; doorOfTimeText = Hint(CHILD_ALTAR_TEXT_END_DOTOPEN).GetText(); - } else if (OpenDoorOfTime.Is(OPENDOOROFTIME_CLOSED)) { + } else if (OpenDoorOfTime.Is(OPENDOOROFTIME_SONGONLY)) { itemObtained = "$c"; - doorOfTimeText = Hint(CHILD_ALTAR_TEXT_END_DOTCLOSED).GetText(); + doorOfTimeText = Hint(CHILD_ALTAR_TEXT_END_DOTSONGONLY).GetText(); - } else if (OpenDoorOfTime.Is(OPENDOOROFTIME_INTENDED)) { + } else if (OpenDoorOfTime.Is(OPENDOOROFTIME_CLOSED)) { itemObtained = "$i"; - doorOfTimeText = Hint(CHILD_ALTAR_TEXT_END_DOTINTENDED).GetText(); + doorOfTimeText = Hint(CHILD_ALTAR_TEXT_END_DOTCLOSED).GetText(); } return Text()+itemObtained+doorOfTimeText; diff --git a/soh/soh/Enhancements/randomizer/3drando/keys.hpp b/soh/soh/Enhancements/randomizer/3drando/keys.hpp index 92bf0a432..07714145b 100644 --- a/soh/soh/Enhancements/randomizer/3drando/keys.hpp +++ b/soh/soh/Enhancements/randomizer/3drando/keys.hpp @@ -1742,8 +1742,8 @@ typedef enum { SPIRITUAL_STONE_TEXT_START, CHILD_ALTAR_TEXT_END_DOTOPEN, + CHILD_ALTAR_TEXT_END_DOTSONGONLY, CHILD_ALTAR_TEXT_END_DOTCLOSED, - CHILD_ALTAR_TEXT_END_DOTINTENDED, ADULT_ALTAR_TEXT_START, ADULT_ALTAR_TEXT_END, diff --git a/soh/soh/Enhancements/randomizer/3drando/location_access/locacc_castle_town.cpp b/soh/soh/Enhancements/randomizer/3drando/location_access/locacc_castle_town.cpp index 7df38c193..172cca45d 100644 --- a/soh/soh/Enhancements/randomizer/3drando/location_access/locacc_castle_town.cpp +++ b/soh/soh/Enhancements/randomizer/3drando/location_access/locacc_castle_town.cpp @@ -56,8 +56,8 @@ void AreaTable_Init_CastleTown() { }, { //Exits Entrance(TOT_ENTRANCE, {[]{return true;}}), - Entrance(TOT_BEYOND_DOOR_OF_TIME, {[]{return OpenDoorOfTime.Is(OPENDOOROFTIME_OPEN) || (CanPlay(SongOfTime) && (OpenDoorOfTime.Is(OPENDOOROFTIME_CLOSED) || (HasAllStones && OcarinaOfTime)));}, - /*Glitched*/[]{return SongOfTime && OpenDoorOfTime.Is(OPENDOOROFTIME_CLOSED) && (CanDoGlitch(GlitchType::IndoorBombOI, GlitchDifficulty::ADVANCED) || + Entrance(TOT_BEYOND_DOOR_OF_TIME, {[]{return OpenDoorOfTime.Is(OPENDOOROFTIME_OPEN) || (CanPlay(SongOfTime) && (OpenDoorOfTime.Is(OPENDOOROFTIME_SONGONLY) || (HasAllStones && OcarinaOfTime)));}, + /*Glitched*/[]{return SongOfTime && OpenDoorOfTime.Is(OPENDOOROFTIME_SONGONLY) && (CanDoGlitch(GlitchType::IndoorBombOI, GlitchDifficulty::ADVANCED) || ((Bugs || Fish) && Bombs && (CanSurviveDamage || (Fairy && NumBottles >= 2)) && CanShield && CanDoGlitch(GlitchType::QPA, GlitchDifficulty::ADVANCED) && CanDoGlitch(GlitchType::RestrictedItems, GlitchDifficulty::NOVICE)));}}), }); diff --git a/soh/soh/Enhancements/randomizer/3drando/setting_descriptions.cpp b/soh/soh/Enhancements/randomizer/3drando/setting_descriptions.cpp index aa0c4637b..e3bafb31f 100644 --- a/soh/soh/Enhancements/randomizer/3drando/setting_descriptions.cpp +++ b/soh/soh/Enhancements/randomizer/3drando/setting_descriptions.cpp @@ -63,9 +63,9 @@ string_view kakGateClosed = "The gate and the Happy Mask Shop both r ------------------------------*/ // string_view doorOfTimeOpen = "The Door of Time starts opened instead of needing\n" "to play the Song of Time."; // -string_view doorOfTimeClosed = "Only an Ocarina and the Song of Time need to be\n"// +string_view doorOfTimeSongOnly = "Only an Ocarina and the Song of Time need to be\n"// "found to open the Door of Time."; // -string_view doorOfTimeIntended = "The Ocarina of Time, the Song of Time, and\n" // +string_view doorOfTimeClosed = "The Ocarina of Time, the Song of Time, and\n" // "all Spiritual Stones need to be found to\n" // "open the Door of Time."; // /*------------------------------ // diff --git a/soh/soh/Enhancements/randomizer/3drando/setting_descriptions.hpp b/soh/soh/Enhancements/randomizer/3drando/setting_descriptions.hpp index 224563d5e..6b9df1712 100644 --- a/soh/soh/Enhancements/randomizer/3drando/setting_descriptions.hpp +++ b/soh/soh/Enhancements/randomizer/3drando/setting_descriptions.hpp @@ -22,8 +22,8 @@ extern string_view kakGateOpen; extern string_view kakGateClosed; extern string_view doorOfTimeOpen; +extern string_view doorOfTimeSongOnly; extern string_view doorOfTimeClosed; -extern string_view doorOfTimeIntended; extern string_view fountainNormal; extern string_view fountainAdult; diff --git a/soh/soh/Enhancements/randomizer/3drando/settings.cpp b/soh/soh/Enhancements/randomizer/3drando/settings.cpp index 41a83dd33..c4abd2266 100644 --- a/soh/soh/Enhancements/randomizer/3drando/settings.cpp +++ b/soh/soh/Enhancements/randomizer/3drando/settings.cpp @@ -55,7 +55,7 @@ namespace Settings { Option RandomizeOpen = Option::Bool("Randomize Settings", {"No","Yes"}, {openRandomize}, OptionCategory::Toggle); Option OpenForest = Option::U8 ("Forest", {"Closed", "Closed Deku", "Open"}, {forestClosed, forestClosedDeku, forestOpen}, OptionCategory::Setting, OPENFOREST_CLOSED); Option OpenKakariko = Option::U8 ("Kakariko Gate", {"Closed", "Open"}, {kakGateClosed, kakGateOpen}); - Option OpenDoorOfTime = Option::U8 ("Door of Time", {"Closed", "Song only", "Open"}, {doorOfTimeIntended, doorOfTimeClosed, doorOfTimeOpen}); + Option OpenDoorOfTime = Option::U8 ("Door of Time", {"Closed", "Song only", "Open"}, {doorOfTimeClosed, doorOfTimeSongOnly, doorOfTimeOpen}); Option ZorasFountain = Option::U8 ("Zora's Fountain", {"Closed", "Closed as child", "Open"}, {fountainNormal, fountainAdult, fountainOpen}); Option GerudoFortress = Option::U8 ("Gerudo Fortress", {"Normal", "Fast", "Open"}, {gerudoNormal, gerudoFast, gerudoOpen}); Option Bridge = Option::U8 ("Rainbow Bridge", {"Vanilla", "Always open", "Stones", "Medallions", "Dungeon rewards", "Dungeons", "Tokens"}, {bridgeVanilla, bridgeOpen, bridgeStones, bridgeMedallions, bridgeRewards, bridgeDungeons, bridgeTokens}, OptionCategory::Setting, RAINBOWBRIDGE_VANILLA); @@ -1864,7 +1864,7 @@ namespace Settings { //Adult is also not compatible with the following combination: //DoT:Intended, ShuffleOcarinas:false, Logic:Glitchless - if (OpenDoorOfTime.Is(OPENDOOROFTIME_INTENDED) && !ShuffleOcarinas && + if (OpenDoorOfTime.Is(OPENDOOROFTIME_CLOSED) && !ShuffleOcarinas && Logic.Is(LOGIC_GLITCHLESS)) { StartingAge.SetSelectedIndex(AGE_CHILD); StartingAge.Lock(); diff --git a/soh/soh/Enhancements/randomizer/3drando/settings.hpp b/soh/soh/Enhancements/randomizer/3drando/settings.hpp index 6e23ca571..bb89f5a35 100644 --- a/soh/soh/Enhancements/randomizer/3drando/settings.hpp +++ b/soh/soh/Enhancements/randomizer/3drando/settings.hpp @@ -44,8 +44,8 @@ typedef enum { } OpenKakarikoSetting; typedef enum { - OPENDOOROFTIME_INTENDED, OPENDOOROFTIME_CLOSED, + OPENDOOROFTIME_SONGONLY, OPENDOOROFTIME_OPEN, } OpenDoorOfTimeSetting; From 453eb7af88d6220125e08b93fadec172318eec1a Mon Sep 17 00:00:00 2001 From: PurpleHato Date: Tue, 29 Nov 2022 00:21:25 +0100 Subject: [PATCH 13/25] Missing space (#2024) --- soh/soh/Enhancements/randomizer/randomizer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/soh/soh/Enhancements/randomizer/randomizer.cpp b/soh/soh/Enhancements/randomizer/randomizer.cpp index a6ebc50f9..a67b65934 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer.cpp @@ -3024,7 +3024,7 @@ void DrawRandoEditor(bool& open) { "\n" "None - All Dungeons will be their Vanilla versions.\n" "\n" - "Set Number - Select a number of dungeons that will be their Master Quest versions" + "Set Number - Select a number of dungeons that will be their Master Quest versions " "using the slider below. Which dungeons are set to be the Master Quest variety will be random.\n" "\n" "Random Number - A Random number and set of dungeons will be their Master Quest varieties." From e3af07aa2757ac377d4fbe2c5921ef6b5c59af39 Mon Sep 17 00:00:00 2001 From: Garrett Cox Date: Mon, 28 Nov 2022 17:48:09 -0600 Subject: [PATCH 14/25] Fix PR artifacts workflow (#2028) --- .github/workflows/pr-artifacts.yml | 32 ++++++++++++++++++++++++++---- 1 file changed, 28 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pr-artifacts.yml b/.github/workflows/pr-artifacts.yml index 599aa1bbb..43b985b5d 100644 --- a/.github/workflows/pr-artifacts.yml +++ b/.github/workflows/pr-artifacts.yml @@ -11,7 +11,31 @@ jobs: runs-on: ubuntu-latest if: ${{ github.event.workflow_run.event == 'pull_request' }} steps: - - id: 'get-info' + - id: 'pr-number' + uses: actions/github-script@v6 + with: + result-encoding: string + script: | + const {owner, repo} = context.repo; + const pullHeadSHA = '${{github.event.workflow_run.head_sha}}'; + const pullUserId = ${{github.event.sender.id}}; + const prNumber = await (async () => { + const pulls = await github.rest.pulls.list({owner, repo}); + for await (const {data} of github.paginate.iterator(pulls)) { + for (const pull of data) { + if (pull.head.sha === pullHeadSHA && pull.user.id === pullUserId) { + return pull.number; + } + } + } + })(); + + if (!prNumber) { + return core.error(`No matching pull request found`); + } + + return prNumber; + - id: 'artifacts-text' uses: actions/github-script@v6 with: result-encoding: string @@ -25,13 +49,13 @@ jobs: return allArtifacts.data.artifacts.reduce((acc, item) => { if (item.name === "assets") return acc; acc += ` - - [${item.name}](${context.payload.repository.html_url}/suites/${context.payload.workflow_run.check_suite_id}/artifacts/${item.id})`; + - [${item.name}.zip](https://nightly.link/${context.repo.owner}/${context.repo.repo}/actions/artifacts/${item.id}.zip)`; return acc; }, '### Build Artifacts'); - id: 'add-to-pr' uses: garrettjoecox/pr-section@3.1.0 with: repo-token: '${{ secrets.GITHUB_TOKEN }}' - pr-number: ${{ github.event.workflow_run.pull_requests[0].number }} + pr-number: ${{ steps.pr-number.outputs.result }} section-name: 'artifacts' - section-value: '${{ steps.get-info.outputs.result }}' + section-value: '${{ steps.artifacts-text.outputs.result }}' From 8064ad9dfee6e4c45b4080ddcca4af8f48707288 Mon Sep 17 00:00:00 2001 From: Oliver Schall Date: Tue, 29 Nov 2022 01:04:24 +0100 Subject: [PATCH 15/25] Add git submodule update to BUILDING.md (#2027) * Added git submodule to building instructions * Fixed git submodule build instruction order * Removed --recursive flag from git submodule building instructions * Removed windows git submodule instruction --- BUILDING.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/BUILDING.md b/BUILDING.md index fd7cfd0a8..6706d960d 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -85,6 +85,8 @@ _Note: If you're using Visual Studio Code, the [cpack plugin](https://marketplac # Clone the repo git clone https://github.com/HarbourMasters/Shipwright.git cd Shipwright +# Clone the submodule libultraship +git submodule update --init # Copy the baserom to the OTRExporter folder cp OTRExporter # Generate Ninja project @@ -123,6 +125,8 @@ _Note: If you're using Visual Studio Code, the [cpack plugin](https://marketplac # Clone the repo git clone https://github.com/HarbourMasters/Shipwright.git cd ShipWright +# Clone the submodule libultraship +git submodule update --init # Copy the baserom to the OTRExporter folder cp OTRExporter # Generate Ninja project From d7c35221421bf712b5ead56a360f81f624aca4bc Mon Sep 17 00:00:00 2001 From: Garrett Cox Date: Tue, 29 Nov 2022 17:28:57 -0600 Subject: [PATCH 16/25] [docs] Upstream updates 1 (#1955) * First round of upstream updates and commenting patternss * Renames from z64player * Renames from z64save * Undo changes to legacy save struct * Add missing reference from entrance rando * Fixes from stat tracker * More tweaks --- soh/include/alignment.h | 16 + soh/include/macros.h | 149 ++-- soh/include/z64.h | 1 + soh/include/z64player.h | 519 ++++++++------ soh/include/z64save.h | 674 ++++++++++++++++-- .../crowd-control/CrowdControl.cpp | 6 +- soh/soh/Enhancements/debugconsole.cpp | 6 +- .../Enhancements/debugger/debugSaveEditor.cpp | 42 +- .../Enhancements/randomizer/randomizer.cpp | 2 +- .../randomizer/randomizer_grotto.c | 2 +- soh/soh/SaveManager.cpp | 100 +-- soh/src/code/game.c | 8 +- soh/src/code/z_actor.c | 6 +- soh/src/code/z_common_data.c | 2 +- soh/src/code/z_demo.c | 36 +- soh/src/code/z_elf_message.c | 2 +- soh/src/code/z_fbdemo_fade.c | 8 +- soh/src/code/z_fbdemo_wipe1.c | 4 +- soh/src/code/z_kaleido_setup.c | 2 +- soh/src/code/z_kankyo.c | 8 +- soh/src/code/z_message_PAL.c | 12 +- soh/src/code/z_parameter.c | 164 ++--- soh/src/code/z_play.c | 34 +- soh/src/code/z_player_lib.c | 82 +-- soh/src/code/z_sram.c | 6 +- soh/src/code/z_vr_box.c | 2 +- .../actors/ovl_Arms_Hook/z_arms_hook.c | 4 +- .../ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c | 30 +- .../ovl_Bg_Hidan_Dalm/z_bg_hidan_dalm.c | 2 +- .../actors/ovl_Bg_Toki_Swd/z_bg_toki_swd.c | 2 +- .../actors/ovl_Bg_Ydan_Sp/z_bg_ydan_sp.c | 10 +- .../actors/ovl_Boss_Ganon/z_boss_ganon.c | 8 +- .../actors/ovl_Boss_Ganon2/z_boss_ganon2.c | 2 +- .../overlays/actors/ovl_Demo_Im/z_demo_im.c | 2 +- .../actors/ovl_Door_Shutter/z_door_shutter.c | 2 +- .../actors/ovl_Door_Warp1/z_door_warp1.c | 4 +- .../overlays/actors/ovl_En_Butte/z_en_butte.c | 14 +- .../actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c | 4 +- soh/src/overlays/actors/ovl_En_Gb/z_en_gb.c | 4 +- .../overlays/actors/ovl_En_GeldB/z_en_geldb.c | 8 +- .../actors/ovl_En_Heishi1/z_en_heishi1.c | 2 +- .../actors/ovl_En_Heishi3/z_en_heishi3.c | 2 +- soh/src/overlays/actors/ovl_En_Hy/z_en_hy.c | 2 +- .../actors/ovl_En_Kakasi/z_en_kakasi.c | 6 +- .../actors/ovl_En_Kanban/z_en_kanban.c | 2 +- .../actors/ovl_En_M_Thunder/z_en_m_thunder.c | 10 +- soh/src/overlays/actors/ovl_En_Mag/z_en_mag.c | 16 +- soh/src/overlays/actors/ovl_En_Owl/z_en_owl.c | 2 +- .../ovl_En_Po_Sisters/z_en_po_sisters.c | 2 +- soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c | 4 +- soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c | 4 +- soh/src/overlays/actors/ovl_En_Sw/z_en_sw.h | 2 +- soh/src/overlays/actors/ovl_En_Ta/z_en_ta.c | 4 +- .../overlays/actors/ovl_En_Test/z_en_test.c | 14 +- .../actors/ovl_En_Torch2/z_en_torch2.c | 68 +- soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c | 8 +- soh/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c | 2 +- .../overlays/actors/ovl_Fishing/z_fishing.c | 2 +- .../actors/ovl_Item_Ocarina/z_item_ocarina.c | 2 +- .../actors/ovl_Obj_Syokudai/z_obj_syokudai.c | 4 +- .../actors/ovl_Oceff_Spot/z_oceff_spot.c | 2 +- .../actors/ovl_Oceff_Storm/z_oceff_storm.c | 2 +- .../actors/ovl_Oceff_Wipe/z_oceff_wipe.c | 2 +- .../actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c | 2 +- .../actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c | 2 +- .../actors/ovl_player_actor/z_player.c | 568 +++++++-------- .../ovl_file_choose/z_file_choose.c | 14 +- .../overlays/gamestates/ovl_select/z_select.c | 8 +- .../ovl_kaleido_scope/z_kaleido_scope_PAL.c | 14 +- 69 files changed, 1721 insertions(+), 1040 deletions(-) create mode 100644 soh/include/alignment.h diff --git a/soh/include/alignment.h b/soh/include/alignment.h new file mode 100644 index 000000000..7a3b94ea2 --- /dev/null +++ b/soh/include/alignment.h @@ -0,0 +1,16 @@ +#ifndef ALIGNMENT_H +#define ALIGNMENT_H + +#define ALIGN8(val) (((val) + 7) & ~7) +#define ALIGN16(val) (((val) + 0xF) & ~0xF) +#define ALIGN32(val) (((val) + 0x1F) & ~0x1F) +#define ALIGN64(val) (((val) + 0x3F) & ~0x3F) +#define ALIGN256(val) (((val) + 0xFF) & ~0xFF) + +#ifdef __GNUC__ +#define ALIGNED8 __attribute__ ((aligned (8))) +#else +#define ALIGNED8 +#endif + +#endif diff --git a/soh/include/macros.h b/soh/include/macros.h index 2829257d1..2d69b83ea 100644 --- a/soh/include/macros.h +++ b/soh/include/macros.h @@ -3,49 +3,51 @@ #include +// Upstream TODO: Document reasoning for change +// #ifndef __GNUC__ +// #define __attribute__(x) +// #endif + +// #ifndef AVOID_UB +// #define BAD_RETURN(type) type +// #else +// #define BAD_RETURN(type) void +// #endif + +// #define UNUSED __attribute__((unused)) +// #define FALLTHROUGH __attribute__((fallthrough)) + #define ARRAY_COUNT(arr) (s32)(sizeof(arr) / sizeof(arr[0])) #define ARRAY_COUNTU(arr) (u32)(sizeof(arr) / sizeof(arr[0])) #define PHYSICAL_TO_VIRTUAL(addr) (void*)((uintptr_t)(addr) + 0x80000000) #define VIRTUAL_TO_PHYSICAL(addr) (uintptr_t)((u8*)(addr) - 0x80000000) +// Upstream TODO: Document reasoning for change //#define SEGMENTED_TO_VIRTUAL(addr) PHYSICAL_TO_VIRTUAL(gSegments[SEGMENT_NUMBER(addr)] + SEGMENT_OFFSET(addr)) - #define SEGMENTED_TO_VIRTUAL(addr) addr -#define ALIGN16(val) (((val) + 0xF) & ~0xF) -#define ALIGN32(val) (((val) + 0x1F) & ~0x1F) -#define ALIGN64(val) (((val) + 0x3F) & ~0x3F) -#define ALIGN256(val) (((val) + 0xFF) & ~0xFF) - -#define OFFSETOF(structure, member) ((size_t)&(((structure*)0)->member)) - #define SQ(x) ((x)*(x)) #define ABS(x) ((x) >= 0 ? (x) : -(x)) #define DECR(x) ((x) == 0 ? 0 : --(x)) #define CLAMP(x, min, max) ((x) < (min) ? (min) : (x) > (max) ? (max) : (x)) #define CLAMP_MAX(x, max) ((x) > (max) ? (max) : (x)) #define CLAMP_MIN(x, min) ((x) < (min) ? (min) : (x)) -#define MEDIAN3(a1, a2, a3) \ - (((a2) >= (a1)) ? (((a3) >= (a2)) ? (a2) : (((a1) >= (a3)) ? (a1) : (a3))) \ - : (((a2) >= (a3)) ? (a2) : (((a3) >= (a1)) ? (a1) : (a3)))) #define RGBA8(r, g, b, a) ((((r) & 0xFF) << 24) | (((g) & 0xFF) << 16) | (((b) & 0xFF) << 8) | (((a) & 0xFF) << 0)) #define GET_PLAYER(play) ((Player*)(play)->actorCtx.actorLists[ACTORCAT_PLAYER].head) -#define GET_ACTIVE_CAM(play) ((play)->cameraPtrs[(play)->activeCamera]) +#define GET_ACTIVE_CAM(play) ((play)->cameraPtrs[(play)->activeCamera]) // Upstream TODO: Camera -#define LINK_IS_ADULT (gSaveContext.linkAge == 0) -#define LINK_IS_CHILD (gSaveContext.linkAge == 1) - -#define CHECK_EQUIPMENT_AGE(i, j) (CVar_GetS32("gTimelessEquipment", 0) || (gEquipAgeReqs[i][j] == 9) || (gEquipAgeReqs[i][j] == ((void)0, gSaveContext.linkAge))) -#define CHECK_SLOT_AGE(slotIndex) (CVar_GetS32("gTimelessEquipment", 0) || (gSlotAgeReqs[slotIndex] == 9) || gSlotAgeReqs[slotIndex] == ((void)0, gSaveContext.linkAge)) -#define CHECK_ITEM_AGE(itemIndex) (CVar_GetS32("gTimelessEquipment", 0) || (gItemAgeReqs[itemIndex] == 9) || (gItemAgeReqs[itemIndex] == gSaveContext.linkAge)) +#define LINK_IS_ADULT (gSaveContext.linkAge == LINK_AGE_ADULT) +#define LINK_IS_CHILD (gSaveContext.linkAge == LINK_AGE_CHILD) #define YEARS_CHILD 5 #define YEARS_ADULT 17 #define LINK_AGE_IN_YEARS (!LINK_IS_ADULT ? YEARS_CHILD : YEARS_ADULT) +#define CLOCK_TIME(hr, min) ((s32)(((hr) * 60 + (min)) * (f32)0x10000 / (24 * 60) + 0.5f)) + #define IS_DAY (gSaveContext.nightFlag == 0) #define IS_NIGHT (gSaveContext.nightFlag == 1) @@ -56,7 +58,15 @@ #define ALL_EQUIP_VALUE(equip) ((s32)(gSaveContext.inventory.equipment & gEquipMasks[equip]) >> gEquipShifts[equip]) #define CUR_EQUIP_VALUE(equip) ((s32)(gSaveContext.equips.equipment & gEquipMasks[equip]) >> gEquipShifts[equip]) -#define CHECK_OWNED_EQUIP(equip, value) ((gBitFlags[value] << gEquipShifts[equip]) & gSaveContext.inventory.equipment) +#define OWNED_EQUIP_FLAG(equip, value) (gBitFlags[value] << gEquipShifts[equip]) +#define OWNED_EQUIP_FLAG_ALT(equip, value) ((1 << (value)) << gEquipShifts[equip]) +#define CHECK_OWNED_EQUIP(equip, value) (OWNED_EQUIP_FLAG(equip, value) & gSaveContext.inventory.equipment) +#define CHECK_OWNED_EQUIP_ALT(equip, value) (gBitFlags[(value) + (equip) * 4] & gSaveContext.inventory.equipment) + +#define SWORD_EQUIP_TO_PLAYER(swordEquip) (swordEquip) +#define SHIELD_EQUIP_TO_PLAYER(shieldEquip) (shieldEquip) +#define TUNIC_EQUIP_TO_PLAYER(tunicEquip) ((tunicEquip) - 1) +#define BOOTS_EQUIP_TO_PLAYER(bootsEquip) ((bootsEquip) - 1) #define CUR_UPG_VALUE(upg) ((s32)(gSaveContext.inventory.upgrades & gUpgradeMasks[upg]) >> gUpgradeShifts[upg]) #define CAPACITY(upg, value) gUpgradeCapacities[upg][value] @@ -72,6 +82,21 @@ #define HIGH_SCORE(score) (gSaveContext.highScores[score]) +#define GET_EVENTCHKINF(flag) (gSaveContext.eventChkInf[(flag) >> 4] & (1 << ((flag) & 0xF))) +#define SET_EVENTCHKINF(flag) (gSaveContext.eventChkInf[(flag) >> 4] |= (1 << ((flag) & 0xF))) +#define CLEAR_EVENTCHKINF(flag) (gSaveContext.eventChkInf[(flag) >> 4] &= ~(1 << ((flag) & 0xF))) + +#define GET_ITEMGETINF(flag) (gSaveContext.itemGetInf[(flag) >> 4] & (1 << ((flag) & 0xF))) +#define SET_ITEMGETINF(flag) (gSaveContext.itemGetInf[(flag) >> 4] |= (1 << ((flag) & 0xF))) + +#define GET_INFTABLE(flag) (gSaveContext.infTable[(flag) >> 4] & (1 << ((flag) & 0xF))) +#define SET_INFTABLE(flag) (gSaveContext.infTable[(flag) >> 4] |= (1 << ((flag) & 0xF))) +#define CLEAR_INFTABLE(flag) (gSaveContext.infTable[(flag) >> 4] &= ~(1 << ((flag) & 0xF))) + +#define GET_EVENTINF(flag) (gSaveContext.eventInf[(flag) >> 4] & (1 << ((flag) & 0xF))) +#define SET_EVENTINF(flag) (gSaveContext.eventInf[(flag) >> 4] |= (1 << ((flag) & 0xF))) +#define CLEAR_EVENTINF(flag) (gSaveContext.eventInf[(flag) >> 4] &= ~(1 << ((flag) & 0xF))) + #define B_BTN_ITEM ((gSaveContext.buttonStatus[0] == ITEM_NONE) \ ? ITEM_NONE \ : (gSaveContext.equips.buttonItems[0] == ITEM_SWORD_KNIFE) \ @@ -82,15 +107,13 @@ ? gSaveContext.equips.buttonItems[(button) + 1] \ : ITEM_NONE) -#define DPAD_ITEM(button) ((gSaveContext.buttonStatus[(button) + 5] != BTN_DISABLED) \ - ? gSaveContext.equips.buttonItems[(button) + 4] \ - : ITEM_NONE) - #define CHECK_BTN_ALL(state, combo) (~((state) | ~(combo)) == 0) #define CHECK_BTN_ANY(state, combo) (((state) & (combo)) != 0) #define CHECK_FLAG_ALL(flags, mask) (((flags) & (mask)) == (mask)) +// #region SOH [General] +// Logging changes #ifndef NDEBUG #define LOG(exp, value, format) \ do { \ @@ -133,30 +156,8 @@ #define LOG_THREAD_ID() ((void)0) #define LOG_HUNGUP_THREAD() ((void)0) #endif +// #endregion -#define MATRIX_TOMTX(dest) Matrix_ToMtx(dest, __FILE__, __LINE__) -#define MATRIX_NEWMTX(gfxCtx) Matrix_NewMtx(gfxCtx, __FILE__, __LINE__) -#define MATRIX_CHECKFLOATS(mf) Matrix_CheckFloats(mf, __FILE__, __LINE__) - -#define ZELDA_ARENA_MALLOC_DEBUG(size) ZeldaArena_MallocDebug(size, __FILE__, __LINE__) -#define ZELDA_ARENA_MALLOC_RDEBUG(size) ZeldaArena_MallocRDebug(size, __FILE__, __LINE__) -#define ZELDA_ARENA_REALLOC_DEBUG(ptr, newSize) ZeldaArena_ReallocDebug(ptr, newSize, __FILE__, __LINE__) -#define ZELDA_ARENA_FREE_DEBUG(ptr) ZeldaArena_FreeDebug(ptr, __FILE__, __LINE__) - -#define SYSTEM_ARENA_MALLOC_DEBUG(size) SystemArena_MallocDebug(size, __FILE__, __LINE__) -#define SYSTEM_ARENA_MALLOC_RDEBUG(size) SystemArena_MallocRDebug(size, __FILE__, __LINE__) -#define SYSTEM_ARENA_REALLOC_DEBUG(ptr, newSize) SystemArena_ReallocDebug(ptr, newSize, __FILE__, __LINE__) -#define SYSTEM_ARENA_FREE_DEBUG(ptr) SystemArena_FreeDebug(ptr, __FILE__, __LINE__) - -#define DEBUG_ARENA_MALLOC_DEBUG(size) DebugArena_MallocDebug(size, __FILE__, __LINE__) -#define DEBUG_ARENA_MALLOC_RDEBUG(size) DebugArena_MallocRDebug(size, __FILE__, __LINE__) -#define DEBUG_ARENA_REALLOC_DEBUG(ptr, newSize) DebugArena_ReallocDebug(ptr, newSize, __FILE__, __LINE__) -#define DEBUG_ARENA_FREE_DEBUG(ptr) DebugArena_FreeDebug(ptr, __FILE__, __LINE__) - -#define GAMESTATE_ALLOC_MC(gameState, size) GameState_Alloc(gameState, size, __FILE__, __LINE__) -#define GAMESTATE_MALLOC_DEBUG(gameState, size) GameAlloc_MallocDebug(gameState, size, __FILE__, __LINE__) - -#define BGCHECK_POS_ERROR_CHECK(vec3f) BgCheck_PosErrorCheck(vec3f, __FILE__, __LINE__) #define SET_NEXT_GAMESTATE(curState, newInit, newStruct) \ do { \ @@ -180,12 +181,17 @@ extern GraphicsContext* __gfxCtx; #define WORK_DISP __gfxCtx->work.p #define POLY_OPA_DISP __gfxCtx->polyOpa.p #define POLY_XLU_DISP __gfxCtx->polyXlu.p +// #region SOH [General] +// Upstream TODO: Document reasoning for these only existing in SoH #define WORLD_OVERLAY_DISP __gfxCtx->worldOverlay.p #define POLY_KAL_DISP __gfxCtx->polyKal.p +// #endregion #define OVERLAY_DISP __gfxCtx->overlay.p // __gfxCtx shouldn't be used directly. // Use the DISP macros defined above when writing to display buffers. +// #region SOH [General] +// Augmented to provide debug information in debug build and support interpolation #ifndef NDEBUG #define OPEN_DISPS(gfxCtx) \ { \ @@ -221,6 +227,7 @@ extern GraphicsContext* __gfxCtx; } \ (void)0 #endif +// #endregion /** * `x` vertex x @@ -237,11 +244,13 @@ extern GraphicsContext* __gfxCtx; #define VTX_T(x,y,z,s,t,cr,cg,cb,a) { { x, y, z }, 0, { s, t }, { cr, cg, cb, a } } +// #region SOH [WiiU] #ifdef __WIIU__ #define ASSERT(expression) (void)((!!(expression)) || (_assert(#expression, __FILE__, (unsigned)(__LINE__)), 0)) #else #define ASSERT(expression) (void)((!!(expression)) || (__assert(#expression, __FILE__, (unsigned)(__LINE__)), 0)) #endif +// #endregion #define gDPSetTileCustom(pkt, fmt, siz, width, height, pal, cms, cmt, masks, maskt, shifts, shiftt) \ do { \ @@ -256,14 +265,51 @@ extern GraphicsContext* __gfxCtx; ((height)-1) << G_TEXTURE_IMAGE_FRAC); \ } while (0) -#ifdef __GNUC__ -#define ALIGNED8 __attribute__ ((aligned (8))) -#else -#define ALIGNED8 -#endif +// #region SOH [General] +#define OFFSETOF(structure, member) ((size_t)&(((structure*)0)->member)) + +#define MEDIAN3(a1, a2, a3) \ + (((a2) >= (a1)) ? (((a3) >= (a2)) ? (a2) : (((a1) >= (a3)) ? (a1) : (a3))) \ + : (((a2) >= (a3)) ? (a2) : (((a3) >= (a1)) ? (a1) : (a3)))) + +#define MATRIX_TOMTX(dest) Matrix_ToMtx(dest, __FILE__, __LINE__) +#define MATRIX_NEWMTX(gfxCtx) Matrix_NewMtx(gfxCtx, __FILE__, __LINE__) +#define MATRIX_CHECKFLOATS(mf) Matrix_CheckFloats(mf, __FILE__, __LINE__) + +#define ZELDA_ARENA_MALLOC_DEBUG(size) ZeldaArena_MallocDebug(size, __FILE__, __LINE__) +#define ZELDA_ARENA_MALLOC_RDEBUG(size) ZeldaArena_MallocRDebug(size, __FILE__, __LINE__) +#define ZELDA_ARENA_REALLOC_DEBUG(ptr, newSize) ZeldaArena_ReallocDebug(ptr, newSize, __FILE__, __LINE__) +#define ZELDA_ARENA_FREE_DEBUG(ptr) ZeldaArena_FreeDebug(ptr, __FILE__, __LINE__) + +#define SYSTEM_ARENA_MALLOC_DEBUG(size) SystemArena_MallocDebug(size, __FILE__, __LINE__) +#define SYSTEM_ARENA_MALLOC_RDEBUG(size) SystemArena_MallocRDebug(size, __FILE__, __LINE__) +#define SYSTEM_ARENA_REALLOC_DEBUG(ptr, newSize) SystemArena_ReallocDebug(ptr, newSize, __FILE__, __LINE__) +#define SYSTEM_ARENA_FREE_DEBUG(ptr) SystemArena_FreeDebug(ptr, __FILE__, __LINE__) + +#define DEBUG_ARENA_MALLOC_DEBUG(size) DebugArena_MallocDebug(size, __FILE__, __LINE__) +#define DEBUG_ARENA_MALLOC_RDEBUG(size) DebugArena_MallocRDebug(size, __FILE__, __LINE__) +#define DEBUG_ARENA_REALLOC_DEBUG(ptr, newSize) DebugArena_ReallocDebug(ptr, newSize, __FILE__, __LINE__) +#define DEBUG_ARENA_FREE_DEBUG(ptr) DebugArena_FreeDebug(ptr, __FILE__, __LINE__) + +#define GAMESTATE_ALLOC_MC(gameState, size) GameState_Alloc(gameState, size, __FILE__, __LINE__) +#define GAMESTATE_MALLOC_DEBUG(gameState, size) GameAlloc_MallocDebug(gameState, size, __FILE__, __LINE__) + +#define BGCHECK_POS_ERROR_CHECK(vec3f) BgCheck_PosErrorCheck(vec3f, __FILE__, __LINE__) #define SEG_ADDR(seg, addr) (addr | (seg << 24) | 1) +// #endregion +// #region SOH [Enhancements] +#define CHECK_EQUIPMENT_AGE(i, j) (CVar_GetS32("gTimelessEquipment", 0) || (gEquipAgeReqs[i][j] == 9) || (gEquipAgeReqs[i][j] == ((void)0, gSaveContext.linkAge))) +#define CHECK_SLOT_AGE(slotIndex) (CVar_GetS32("gTimelessEquipment", 0) || (gSlotAgeReqs[slotIndex] == 9) || gSlotAgeReqs[slotIndex] == ((void)0, gSaveContext.linkAge)) +#define CHECK_ITEM_AGE(itemIndex) (CVar_GetS32("gTimelessEquipment", 0) || (gItemAgeReqs[itemIndex] == 9) || (gItemAgeReqs[itemIndex] == gSaveContext.linkAge)) + +#define DPAD_ITEM(button) ((gSaveContext.buttonStatus[(button) + 5] != BTN_DISABLED) \ + ? gSaveContext.equips.buttonItems[(button) + 4] \ + : ITEM_NONE) +// #endregion + +// #region SOH [Randomizer] #define NUM_TRIALS 6 #define NUM_SHOP_ITEMS 64 #define NUM_SCRUBS 46 @@ -277,5 +323,6 @@ extern GraphicsContext* __gfxCtx; #define GERUDO_FORTRESS_SMALL_KEY_MAX 4 #define GANONS_CASTLE_SMALL_KEY_MAX (ResourceMgr_IsSceneMasterQuest(SCENE_GANONTIKA) ? 3 : 2) #define TREASURE_GAME_SMALL_KEY_MAX 6 +// #endregion #endif diff --git a/soh/include/z64.h b/soh/include/z64.h index c376470e1..b83e650b7 100644 --- a/soh/include/z64.h +++ b/soh/include/z64.h @@ -24,6 +24,7 @@ #include "z64skin.h" #include "z64transition.h" #include "z64interface.h" +#include "alignment.h" #include "sequence.h" #include "sfx.h" #include diff --git a/soh/include/z64player.h b/soh/include/z64player.h index dab2e7752..1d3c3e971 100644 --- a/soh/include/z64player.h +++ b/soh/include/z64player.h @@ -2,6 +2,7 @@ #define Z64PLAYER_H #include "z64actor.h" +#include "alignment.h" #include "soh/Enhancements/item-tables/ItemTableTypes.h" struct Player; @@ -64,84 +65,85 @@ typedef enum { } PlayerMask; typedef enum { - /* 0x00 */ PLAYER_AP_NONE, - /* 0x01 */ PLAYER_AP_LAST_USED, - /* 0x02 */ PLAYER_AP_FISHING_POLE, - /* 0x03 */ PLAYER_AP_SWORD_MASTER, - /* 0x04 */ PLAYER_AP_SWORD_KOKIRI, - /* 0x05 */ PLAYER_AP_SWORD_BGS, - /* 0x06 */ PLAYER_AP_STICK, - /* 0x07 */ PLAYER_AP_HAMMER, - /* 0x08 */ PLAYER_AP_BOW, - /* 0x09 */ PLAYER_AP_BOW_FIRE, - /* 0x0A */ PLAYER_AP_BOW_ICE, - /* 0x0B */ PLAYER_AP_BOW_LIGHT, - /* 0x0C */ PLAYER_AP_BOW_0C, - /* 0x0D */ PLAYER_AP_BOW_0D, - /* 0x0E */ PLAYER_AP_BOW_0E, - /* 0x0F */ PLAYER_AP_SLINGSHOT, - /* 0x10 */ PLAYER_AP_HOOKSHOT, - /* 0x11 */ PLAYER_AP_LONGSHOT, - /* 0x12 */ PLAYER_AP_BOMB, - /* 0x13 */ PLAYER_AP_BOMBCHU, - /* 0x14 */ PLAYER_AP_BOOMERANG, - /* 0x15 */ PLAYER_AP_MAGIC_SPELL_15, - /* 0x16 */ PLAYER_AP_MAGIC_SPELL_16, - /* 0x17 */ PLAYER_AP_MAGIC_SPELL_17, - /* 0x18 */ PLAYER_AP_FARORES_WIND, - /* 0x19 */ PLAYER_AP_NAYRUS_LOVE, - /* 0x1A */ PLAYER_AP_DINS_FIRE, - /* 0x1B */ PLAYER_AP_NUT, - /* 0x1C */ PLAYER_AP_OCARINA_FAIRY, - /* 0x1D */ PLAYER_AP_OCARINA_TIME, - /* 0x1E */ PLAYER_AP_BOTTLE, - /* 0x1F */ PLAYER_AP_BOTTLE_FISH, - /* 0x20 */ PLAYER_AP_BOTTLE_FIRE, - /* 0x21 */ PLAYER_AP_BOTTLE_BUG, - /* 0x22 */ PLAYER_AP_BOTTLE_POE, - /* 0x23 */ PLAYER_AP_BOTTLE_BIG_POE, - /* 0x24 */ PLAYER_AP_BOTTLE_LETTER, - /* 0x25 */ PLAYER_AP_BOTTLE_POTION_RED, - /* 0x26 */ PLAYER_AP_BOTTLE_POTION_BLUE, - /* 0x27 */ PLAYER_AP_BOTTLE_POTION_GREEN, - /* 0x28 */ PLAYER_AP_BOTTLE_MILK, - /* 0x29 */ PLAYER_AP_BOTTLE_MILK_HALF, - /* 0x2A */ PLAYER_AP_BOTTLE_FAIRY, - /* 0x2B */ PLAYER_AP_LETTER_ZELDA, - /* 0x2C */ PLAYER_AP_WEIRD_EGG, - /* 0x2D */ PLAYER_AP_CHICKEN, - /* 0x2E */ PLAYER_AP_BEAN, - /* 0x2F */ PLAYER_AP_POCKET_EGG, - /* 0x30 */ PLAYER_AP_POCKET_CUCCO, - /* 0x31 */ PLAYER_AP_COJIRO, - /* 0x32 */ PLAYER_AP_ODD_MUSHROOM, - /* 0x33 */ PLAYER_AP_ODD_POTION, - /* 0x34 */ PLAYER_AP_SAW, - /* 0x35 */ PLAYER_AP_SWORD_BROKEN, - /* 0x36 */ PLAYER_AP_PRESCRIPTION, - /* 0x37 */ PLAYER_AP_FROG, - /* 0x38 */ PLAYER_AP_EYEDROPS, - /* 0x39 */ PLAYER_AP_CLAIM_CHECK, - /* 0x3A */ PLAYER_AP_MASK_KEATON, - /* 0x3B */ PLAYER_AP_MASK_SKULL, - /* 0x3C */ PLAYER_AP_MASK_SPOOKY, - /* 0x3D */ PLAYER_AP_MASK_BUNNY, - /* 0x3E */ PLAYER_AP_MASK_GORON, - /* 0x3F */ PLAYER_AP_MASK_ZORA, - /* 0x40 */ PLAYER_AP_MASK_GERUDO, - /* 0x41 */ PLAYER_AP_MASK_TRUTH, - /* 0x42 */ PLAYER_AP_LENS, - /* 0x43 */ PLAYER_AP_SHIELD_DEKU, - /* 0x44 */ PLAYER_AP_SHIELD_HYLIAN, - /* 0x45 */ PLAYER_AP_SHIELD_MIRROR, - /* 0x46 */ PLAYER_AP_TUNIC_KOKIRI, - /* 0x47 */ PLAYER_AP_TUNIC_GORON, - /* 0x48 */ PLAYER_AP_TUNIC_ZORA, - /* 0x49 */ PLAYER_AP_BOOTS_KOKIRI, - /* 0x4A */ PLAYER_AP_BOOTS_IRON, - /* 0x4B */ PLAYER_AP_BOOTS_HOVER, - /* 0x4C */ PLAYER_AP_MAX -} PlayerActionParam; + /* 0x00 */ PLAYER_IA_NONE, + /* 0x01 */ PLAYER_IA_LAST_USED, + /* 0x02 */ PLAYER_IA_FISHING_POLE, + /* 0x03 */ PLAYER_IA_SWORD_MASTER, + /* 0x04 */ PLAYER_IA_SWORD_KOKIRI, + /* 0x05 */ PLAYER_IA_SWORD_BGS, + /* 0x06 */ PLAYER_IA_STICK, + /* 0x07 */ PLAYER_IA_HAMMER, + /* 0x08 */ PLAYER_IA_BOW, + /* 0x09 */ PLAYER_IA_BOW_FIRE, + /* 0x0A */ PLAYER_IA_BOW_ICE, + /* 0x0B */ PLAYER_IA_BOW_LIGHT, + /* 0x0C */ PLAYER_IA_BOW_0C, + /* 0x0D */ PLAYER_IA_BOW_0D, + /* 0x0E */ PLAYER_IA_BOW_0E, + /* 0x0F */ PLAYER_IA_SLINGSHOT, + /* 0x10 */ PLAYER_IA_HOOKSHOT, + /* 0x11 */ PLAYER_IA_LONGSHOT, + /* 0x12 */ PLAYER_IA_BOMB, + /* 0x13 */ PLAYER_IA_BOMBCHU, + /* 0x14 */ PLAYER_IA_BOOMERANG, + /* 0x15 */ PLAYER_IA_MAGIC_SPELL_15, + /* 0x16 */ PLAYER_IA_MAGIC_SPELL_16, + /* 0x17 */ PLAYER_IA_MAGIC_SPELL_17, + /* 0x18 */ PLAYER_IA_FARORES_WIND, + /* 0x19 */ PLAYER_IA_NAYRUS_LOVE, + /* 0x1A */ PLAYER_IA_DINS_FIRE, + /* 0x1B */ PLAYER_IA_NUT, + /* 0x1C */ PLAYER_IA_OCARINA_FAIRY, + /* 0x1D */ PLAYER_IA_OCARINA_TIME, + /* 0x1E */ PLAYER_IA_BOTTLE, + /* 0x1F */ PLAYER_IA_BOTTLE_FISH, + /* 0x20 */ PLAYER_IA_BOTTLE_FIRE, + /* 0x21 */ PLAYER_IA_BOTTLE_BUG, + /* 0x22 */ PLAYER_IA_BOTTLE_POE, + /* 0x23 */ PLAYER_IA_BOTTLE_BIG_POE, + /* 0x24 */ PLAYER_IA_BOTTLE_LETTER, + /* 0x25 */ PLAYER_IA_BOTTLE_POTION_RED, + /* 0x26 */ PLAYER_IA_BOTTLE_POTION_BLUE, + /* 0x27 */ PLAYER_IA_BOTTLE_POTION_GREEN, + /* 0x28 */ PLAYER_IA_BOTTLE_MILK, + /* 0x29 */ PLAYER_IA_BOTTLE_MILK_HALF, + /* 0x2A */ PLAYER_IA_BOTTLE_FAIRY, + /* 0x2B */ PLAYER_IA_LETTER_ZELDA, + /* 0x2C */ PLAYER_IA_WEIRD_EGG, + /* 0x2D */ PLAYER_IA_CHICKEN, + /* 0x2E */ PLAYER_IA_BEAN, + /* 0x2F */ PLAYER_IA_POCKET_EGG, + /* 0x30 */ PLAYER_IA_POCKET_CUCCO, + /* 0x31 */ PLAYER_IA_COJIRO, + /* 0x32 */ PLAYER_IA_ODD_MUSHROOM, + /* 0x33 */ PLAYER_IA_ODD_POTION, + /* 0x34 */ PLAYER_IA_SAW, + /* 0x35 */ PLAYER_IA_SWORD_BROKEN, + /* 0x36 */ PLAYER_IA_PRESCRIPTION, + /* 0x37 */ PLAYER_IA_FROG, + /* 0x38 */ PLAYER_IA_EYEDROPS, + /* 0x39 */ PLAYER_IA_CLAIM_CHECK, + /* 0x3A */ PLAYER_IA_MASK_KEATON, + /* 0x3B */ PLAYER_IA_MASK_SKULL, + /* 0x3C */ PLAYER_IA_MASK_SPOOKY, + /* 0x3D */ PLAYER_IA_MASK_BUNNY, + /* 0x3E */ PLAYER_IA_MASK_GORON, + /* 0x3F */ PLAYER_IA_MASK_ZORA, + /* 0x40 */ PLAYER_IA_MASK_GERUDO, + /* 0x41 */ PLAYER_IA_MASK_TRUTH, + /* 0x42 */ PLAYER_IA_LENS, + // Upstream TODO: Document why these entries were added + /* 0x43 */ PLAYER_IA_SHIELD_DEKU, + /* 0x44 */ PLAYER_IA_SHIELD_HYLIAN, + /* 0x45 */ PLAYER_IA_SHIELD_MIRROR, + /* 0x46 */ PLAYER_IA_TUNIC_KOKIRI, + /* 0x47 */ PLAYER_IA_TUNIC_GORON, + /* 0x48 */ PLAYER_IA_TUNIC_ZORA, + /* 0x49 */ PLAYER_IA_BOOTS_KOKIRI, + /* 0x4A */ PLAYER_IA_BOOTS_IRON, + /* 0x4B */ PLAYER_IA_BOOTS_HOVER, + /* 0x4C */ PLAYER_IA_MAX +} PlayerItemAction; typedef enum { /* 0x00 */ PLAYER_LIMB_NONE, @@ -170,27 +172,59 @@ typedef enum { } PlayerLimb; typedef enum { - /* 0 */ PLAYER_BODYPART_WAIST, // PLAYER_LIMB_WAIST - /* 1 */ PLAYER_BODYPART_R_THIGH, // PLAYER_LIMB_R_THIGH - /* 2 */ PLAYER_BODYPART_R_SHIN, // PLAYER_LIMB_R_SHIN - /* 3 */ PLAYER_BODYPART_R_FOOT, // PLAYER_LIMB_R_FOOT - /* 4 */ PLAYER_BODYPART_L_THIGH, // PLAYER_LIMB_L_THIGH - /* 5 */ PLAYER_BODYPART_L_SHIN, // PLAYER_LIMB_L_SHIN - /* 6 */ PLAYER_BODYPART_L_FOOT, // PLAYER_LIMB_L_FOOT - /* 7 */ PLAYER_BODYPART_HEAD, // PLAYER_LIMB_HEAD - /* 8 */ PLAYER_BODYPART_HAT, // PLAYER_LIMB_HAT - /* 9 */ PLAYER_BODYPART_COLLAR, // PLAYER_LIMB_COLLAR - /* 10 */ PLAYER_BODYPART_L_SHOULDER, // PLAYER_LIMB_L_SHOULDER - /* 11 */ PLAYER_BODYPART_L_FOREARM, // PLAYER_LIMB_L_FOREARM - /* 12 */ PLAYER_BODYPART_L_HAND, // PLAYER_LIMB_L_HAND - /* 13 */ PLAYER_BODYPART_R_SHOULDER, // PLAYER_LIMB_R_SHOULDER - /* 14 */ PLAYER_BODYPART_R_FOREARM, // PLAYER_LIMB_R_FOREARM - /* 15 */ PLAYER_BODYPART_R_HAND, // PLAYER_LIMB_R_HAND - /* 16 */ PLAYER_BODYPART_SHEATH, // PLAYER_LIMB_SHEATH - /* 17 */ PLAYER_BODYPART_TORSO, // PLAYER_LIMB_TORSO - /* 18 */ PLAYER_BODYPART_MAX + /* 0x00 */ PLAYER_BODYPART_WAIST, // PLAYER_LIMB_WAIST + /* 0x01 */ PLAYER_BODYPART_R_THIGH, // PLAYER_LIMB_R_THIGH + /* 0x02 */ PLAYER_BODYPART_R_SHIN, // PLAYER_LIMB_R_SHIN + /* 0x03 */ PLAYER_BODYPART_R_FOOT, // PLAYER_LIMB_R_FOOT + /* 0x04 */ PLAYER_BODYPART_L_THIGH, // PLAYER_LIMB_L_THIGH + /* 0x05 */ PLAYER_BODYPART_L_SHIN, // PLAYER_LIMB_L_SHIN + /* 0x06 */ PLAYER_BODYPART_L_FOOT, // PLAYER_LIMB_L_FOOT + /* 0x07 */ PLAYER_BODYPART_HEAD, // PLAYER_LIMB_HEAD + /* 0x08 */ PLAYER_BODYPART_HAT, // PLAYER_LIMB_HAT + /* 0x09 */ PLAYER_BODYPART_COLLAR, // PLAYER_LIMB_COLLAR + /* 0x0A */ PLAYER_BODYPART_L_SHOULDER, // PLAYER_LIMB_L_SHOULDER + /* 0x0B */ PLAYER_BODYPART_L_FOREARM, // PLAYER_LIMB_L_FOREARM + /* 0x0C */ PLAYER_BODYPART_L_HAND, // PLAYER_LIMB_L_HAND + /* 0x0D */ PLAYER_BODYPART_R_SHOULDER, // PLAYER_LIMB_R_SHOULDER + /* 0x0E */ PLAYER_BODYPART_R_FOREARM, // PLAYER_LIMB_R_FOREARM + /* 0x0F */ PLAYER_BODYPART_R_HAND, // PLAYER_LIMB_R_HAND + /* 0x10 */ PLAYER_BODYPART_SHEATH, // PLAYER_LIMB_SHEATH + /* 0x11 */ PLAYER_BODYPART_TORSO, // PLAYER_LIMB_TORSO + /* 0x12 */ PLAYER_BODYPART_MAX } PlayerBodyPart; +typedef enum { + /* 0 */ PLAYER_MWA_FORWARD_SLASH_1H, + /* 1 */ PLAYER_MWA_FORWARD_SLASH_2H, + /* 2 */ PLAYER_MWA_FORWARD_COMBO_1H, + /* 3 */ PLAYER_MWA_FORWARD_COMBO_2H, + /* 4 */ PLAYER_MWA_RIGHT_SLASH_1H, + /* 5 */ PLAYER_MWA_RIGHT_SLASH_2H, + /* 6 */ PLAYER_MWA_RIGHT_COMBO_1H, + /* 7 */ PLAYER_MWA_RIGHT_COMBO_2H, + /* 8 */ PLAYER_MWA_LEFT_SLASH_1H, + /* 9 */ PLAYER_MWA_LEFT_SLASH_2H, + /* 10 */ PLAYER_MWA_LEFT_COMBO_1H, + /* 11 */ PLAYER_MWA_LEFT_COMBO_2H, + /* 12 */ PLAYER_MWA_STAB_1H, + /* 13 */ PLAYER_MWA_STAB_2H, + /* 14 */ PLAYER_MWA_STAB_COMBO_1H, + /* 15 */ PLAYER_MWA_STAB_COMBO_2H, + /* 16 */ PLAYER_MWA_FLIPSLASH_START, + /* 17 */ PLAYER_MWA_JUMPSLASH_START, + /* 18 */ PLAYER_MWA_FLIPSLASH_FINISH, + /* 19 */ PLAYER_MWA_JUMPSLASH_FINISH, + /* 20 */ PLAYER_MWA_BACKSLASH_RIGHT, + /* 21 */ PLAYER_MWA_BACKSLASH_LEFT, + /* 22 */ PLAYER_MWA_HAMMER_FORWARD, + /* 23 */ PLAYER_MWA_HAMMER_SIDE, + /* 24 */ PLAYER_MWA_SPIN_ATTACK_1H, + /* 25 */ PLAYER_MWA_SPIN_ATTACK_2H, + /* 26 */ PLAYER_MWA_BIG_SPIN_1H, + /* 27 */ PLAYER_MWA_BIG_SPIN_2H, + /* 28 */ PLAYER_MWA_MAX +} PlayerMeleeWeaponAnimation; + typedef enum { /* -1 */ PLAYER_DOORTYPE_AJAR = -1, /* 0 */ PLAYER_DOORTYPE_NONE, @@ -200,124 +234,125 @@ typedef enum { } PlayerDoorType; typedef enum { - /* 0 */ PLAYER_MODELGROUP_0, // unused (except with the `Player_OverrideLimbDrawPause` bug) - /* 1 */ PLAYER_MODELGROUP_CHILD_HYLIAN_SHIELD, // kokiri/master sword, shield not in hand - /* 2 */ PLAYER_MODELGROUP_SWORD, // kokiri/master sword and possibly shield - /* 3 */ PLAYER_MODELGROUP_DEFAULT, // non-specific models, for items that don't have particular link models - /* 4 */ PLAYER_MODELGROUP_4, // unused, same as PLAYER_MODELGROUP_DEFAULT - /* 5 */ PLAYER_MODELGROUP_BGS, // biggoron sword - /* 6 */ PLAYER_MODELGROUP_BOW_SLINGSHOT, // bow/slingshot - /* 7 */ PLAYER_MODELGROUP_EXPLOSIVES, // bombs, bombchus, same as PLAYER_MODELGROUP_DEFAULT - /* 8 */ PLAYER_MODELGROUP_BOOMERANG, - /* 9 */ PLAYER_MODELGROUP_HOOKSHOT, - /* 10 */ PLAYER_MODELGROUP_10, // stick/fishing pole (which are drawn separately) - /* 11 */ PLAYER_MODELGROUP_HAMMER, - /* 12 */ PLAYER_MODELGROUP_OCARINA, // ocarina - /* 13 */ PLAYER_MODELGROUP_OOT, // ocarina of time - /* 14 */ PLAYER_MODELGROUP_BOTTLE, // bottles (drawn separately) - /* 15 */ PLAYER_MODELGROUP_15, // "last used" - /* 16 */ PLAYER_MODELGROUP_MAX + /* 0x00 */ PLAYER_MODELGROUP_0, // unused (except with the `Player_OverrideLimbDrawPause` bug) + /* 0x01 */ PLAYER_MODELGROUP_CHILD_HYLIAN_SHIELD, // kokiri/master sword, shield not in hand + /* 0x02 */ PLAYER_MODELGROUP_SWORD, // kokiri/master sword and possibly shield + /* 0x03 */ PLAYER_MODELGROUP_DEFAULT, // non-specific models, for items that don't have particular link models + /* 0x04 */ PLAYER_MODELGROUP_4, // unused, same as PLAYER_MODELGROUP_DEFAULT + /* 0x05 */ PLAYER_MODELGROUP_BGS, // biggoron sword + /* 0x06 */ PLAYER_MODELGROUP_BOW_SLINGSHOT, // bow/slingshot + /* 0x07 */ PLAYER_MODELGROUP_EXPLOSIVES, // bombs, bombchus, same as PLAYER_MODELGROUP_DEFAULT + /* 0x08 */ PLAYER_MODELGROUP_BOOMERANG, + /* 0x09 */ PLAYER_MODELGROUP_HOOKSHOT, + /* 0x0A */ PLAYER_MODELGROUP_10, // stick/fishing pole (which are drawn separately) + /* 0x0B */ PLAYER_MODELGROUP_HAMMER, + /* 0x0C */ PLAYER_MODELGROUP_OCARINA, // ocarina + /* 0x0D */ PLAYER_MODELGROUP_OOT, // ocarina of time + /* 0x0E */ PLAYER_MODELGROUP_BOTTLE, // bottles (drawn separately) + /* 0x0F */ PLAYER_MODELGROUP_15, // "last used" + /* 0x10 */ PLAYER_MODELGROUP_MAX } PlayerModelGroup; typedef enum { - /* 0 */ PLAYER_MODELGROUPENTRY_ANIM, - /* 1 */ PLAYER_MODELGROUPENTRY_LEFT_HAND, - /* 2 */ PLAYER_MODELGROUPENTRY_RIGHT_HAND, - /* 3 */ PLAYER_MODELGROUPENTRY_SHEATH, - /* 4 */ PLAYER_MODELGROUPENTRY_WAIST, - /* 5 */ PLAYER_MODELGROUPENTRY_MAX + /* 0x00 */ PLAYER_MODELGROUPENTRY_ANIM, + /* 0x01 */ PLAYER_MODELGROUPENTRY_LEFT_HAND, + /* 0x02 */ PLAYER_MODELGROUPENTRY_RIGHT_HAND, + /* 0x03 */ PLAYER_MODELGROUPENTRY_SHEATH, + /* 0x04 */ PLAYER_MODELGROUPENTRY_WAIST, + /* 0x05 */ PLAYER_MODELGROUPENTRY_MAX } PlayerModelGroupEntry; typedef enum { // left hand - /* 0 */ PLAYER_MODELTYPE_LH_OPEN, // empty open hand - /* 1 */ PLAYER_MODELTYPE_LH_CLOSED, // empty closed hand - /* 2 */ PLAYER_MODELTYPE_LH_SWORD, // holding kokiri/master sword - /* 3 */ PLAYER_MODELTYPE_3, // unused, same as PLAYER_MODELTYPE_LH_SWORD - /* 4 */ PLAYER_MODELTYPE_LH_BGS, // holding bgs/broken giant knife (child: master sword) - /* 5 */ PLAYER_MODELTYPE_LH_HAMMER, // holding hammer (child: empty hand) - /* 6 */ PLAYER_MODELTYPE_LH_BOOMERANG, // holding boomerang (adult: empty hand) - /* 7 */ PLAYER_MODELTYPE_LH_BOTTLE, // holding bottle (bottle drawn separately) + /* 0x00 */ PLAYER_MODELTYPE_LH_OPEN, // empty open hand + /* 0x01 */ PLAYER_MODELTYPE_LH_CLOSED, // empty closed hand + /* 0x02 */ PLAYER_MODELTYPE_LH_SWORD, // holding kokiri/master sword + /* 0x03 */ PLAYER_MODELTYPE_LH_SWORD_2, // unused, same as PLAYER_MODELTYPE_LH_SWORD + /* 0x04 */ PLAYER_MODELTYPE_LH_BGS, // holding bgs/broken giant knife (child: master sword) + /* 0x05 */ PLAYER_MODELTYPE_LH_HAMMER, // holding hammer (child: empty hand) + /* 0x06 */ PLAYER_MODELTYPE_LH_BOOMERANG, // holding boomerang (adult: empty hand) + /* 0x07 */ PLAYER_MODELTYPE_LH_BOTTLE, // holding bottle (bottle drawn separately) // right hand - /* 8 */ PLAYER_MODELTYPE_RH_OPEN, // empty open hand - /* 9 */ PLAYER_MODELTYPE_RH_CLOSED, // empty closed hand - /* 10 */ PLAYER_MODELTYPE_RH_SHIELD, // holding a shield (including no shield) - /* 11 */ PLAYER_MODELTYPE_RH_BOW_SLINGSHOT, // holding bow/slingshot - /* 12 */ PLAYER_MODELTYPE_12, // unused, same as PLAYER_MODELTYPE_RH_BOW_SLINGSHOT - /* 13 */ PLAYER_MODELTYPE_RH_OCARINA, // holding ocarina (child: fairy ocarina, adult: OoT) - /* 14 */ PLAYER_MODELTYPE_RH_OOT, // holding OoT - /* 15 */ PLAYER_MODELTYPE_RH_HOOKSHOT, // holding hookshot (child: empty hand) + /* 0x08 */ PLAYER_MODELTYPE_RH_OPEN, // empty open hand + /* 0x09 */ PLAYER_MODELTYPE_RH_CLOSED, // empty closed hand + /* 0x0A */ PLAYER_MODELTYPE_RH_SHIELD, // holding a shield (including no shield) + /* 0x0B */ PLAYER_MODELTYPE_RH_BOW_SLINGSHOT, // holding bow/slingshot + /* 0x0C */ PLAYER_MODELTYPE_RH_BOW_SLINGSHOT_2, // unused, same as PLAYER_MODELTYPE_RH_BOW_SLINGSHOT + /* 0x0D */ PLAYER_MODELTYPE_RH_OCARINA, // holding ocarina (child: fairy ocarina, adult: OoT) + /* 0x0E */ PLAYER_MODELTYPE_RH_OOT, // holding OoT + /* 0x0F */ PLAYER_MODELTYPE_RH_HOOKSHOT, // holding hookshot (child: empty hand) // sheath - /* 16 */ PLAYER_MODELTYPE_SHEATH_16, // sheathed kokiri/master sword? - /* 17 */ PLAYER_MODELTYPE_SHEATH_17, // empty sheath? - /* 18 */ PLAYER_MODELTYPE_SHEATH_18, // sword sheathed and shield on back? - /* 19 */ PLAYER_MODELTYPE_SHEATH_19, // empty sheath and shield on back? + /* 0x10 */ PLAYER_MODELTYPE_SHEATH_16, // sheathed kokiri/master sword? + /* 0x11 */ PLAYER_MODELTYPE_SHEATH_17, // empty sheath? + /* 0x12 */ PLAYER_MODELTYPE_SHEATH_18, // sword sheathed and shield on back? + /* 0x13 */ PLAYER_MODELTYPE_SHEATH_19, // empty sheath and shield on back? // waist - /* 20 */ PLAYER_MODELTYPE_WAIST, - /* 21 */ PLAYER_MODELTYPE_MAX, + /* 0x14 */ PLAYER_MODELTYPE_WAIST, + /* 0x15 */ PLAYER_MODELTYPE_MAX, /* 0xFF */ PLAYER_MODELTYPE_RH_FF = 0xFF // disable shield collider, cutscene-specific } PlayerModelType; typedef enum { - /* 0 */ PLAYER_ANIMTYPE_0, - /* 1 */ PLAYER_ANIMTYPE_1, - /* 2 */ PLAYER_ANIMTYPE_2, - /* 3 */ PLAYER_ANIMTYPE_3, - /* 4 */ PLAYER_ANIMTYPE_4, - /* 5 */ PLAYER_ANIMTYPE_5, - /* 6 */ PLAYER_ANIMTYPE_MAX + /* 0x00 */ PLAYER_ANIMTYPE_0, + /* 0x01 */ PLAYER_ANIMTYPE_1, + /* 0x02 */ PLAYER_ANIMTYPE_2, + /* 0x03 */ PLAYER_ANIMTYPE_3, + /* 0x04 */ PLAYER_ANIMTYPE_4, + /* 0x05 */ PLAYER_ANIMTYPE_5, + /* 0x06 */ PLAYER_ANIMTYPE_MAX } PlayerAnimType; typedef enum { - /* 0 */ PLAYER_ANIMGROUP_0, - /* 1 */ PLAYER_ANIMGROUP_1, - /* 2 */ PLAYER_ANIMGROUP_2, - /* 3 */ PLAYER_ANIMGROUP_3, - /* 4 */ PLAYER_ANIMGROUP_4, - /* 5 */ PLAYER_ANIMGROUP_5, - /* 6 */ PLAYER_ANIMGROUP_6, - /* 7 */ PLAYER_ANIMGROUP_7, - /* 8 */ PLAYER_ANIMGROUP_8, - /* 9 */ PLAYER_ANIMGROUP_9, - /* 10 */ PLAYER_ANIMGROUP_10, - /* 11 */ PLAYER_ANIMGROUP_11, - /* 12 */ PLAYER_ANIMGROUP_12, - /* 13 */ PLAYER_ANIMGROUP_13, - /* 14 */ PLAYER_ANIMGROUP_14, - /* 15 */ PLAYER_ANIMGROUP_15, - /* 16 */ PLAYER_ANIMGROUP_16, - /* 17 */ PLAYER_ANIMGROUP_17, - /* 18 */ PLAYER_ANIMGROUP_18, - /* 19 */ PLAYER_ANIMGROUP_19, - /* 20 */ PLAYER_ANIMGROUP_20, - /* 21 */ PLAYER_ANIMGROUP_21, - /* 22 */ PLAYER_ANIMGROUP_22, - /* 23 */ PLAYER_ANIMGROUP_23, - /* 24 */ PLAYER_ANIMGROUP_24, - /* 25 */ PLAYER_ANIMGROUP_25, - /* 26 */ PLAYER_ANIMGROUP_26, - /* 27 */ PLAYER_ANIMGROUP_27, - /* 28 */ PLAYER_ANIMGROUP_28, - /* 29 */ PLAYER_ANIMGROUP_29, - /* 30 */ PLAYER_ANIMGROUP_30, - /* 31 */ PLAYER_ANIMGROUP_31, - /* 32 */ PLAYER_ANIMGROUP_32, - /* 33 */ PLAYER_ANIMGROUP_33, - /* 34 */ PLAYER_ANIMGROUP_34, - /* 35 */ PLAYER_ANIMGROUP_35, - /* 36 */ PLAYER_ANIMGROUP_36, - /* 37 */ PLAYER_ANIMGROUP_37, - /* 38 */ PLAYER_ANIMGROUP_38, - /* 39 */ PLAYER_ANIMGROUP_39, - /* 40 */ PLAYER_ANIMGROUP_40, - /* 41 */ PLAYER_ANIMGROUP_41, - /* 42 */ PLAYER_ANIMGROUP_42, - /* 43 */ PLAYER_ANIMGROUP_43, - /* 44 */ PLAYER_ANIMGROUP_44, - /* 45 */ PLAYER_ANIMGROUP_MAX + /* 0x00 */ PLAYER_ANIMGROUP_0, + /* 0x01 */ PLAYER_ANIMGROUP_1, + /* 0x02 */ PLAYER_ANIMGROUP_2, + /* 0x03 */ PLAYER_ANIMGROUP_3, + /* 0x04 */ PLAYER_ANIMGROUP_4, + /* 0x05 */ PLAYER_ANIMGROUP_5, + /* 0x06 */ PLAYER_ANIMGROUP_6, + /* 0x07 */ PLAYER_ANIMGROUP_7, + /* 0x08 */ PLAYER_ANIMGROUP_8, + /* 0x09 */ PLAYER_ANIMGROUP_9, + /* 0x0A */ PLAYER_ANIMGROUP_10, + /* 0x0B */ PLAYER_ANIMGROUP_11, + /* 0x0C */ PLAYER_ANIMGROUP_12, + /* 0x0D */ PLAYER_ANIMGROUP_13, + /* 0x0E */ PLAYER_ANIMGROUP_14, + /* 0x0F */ PLAYER_ANIMGROUP_15, + /* 0x10 */ PLAYER_ANIMGROUP_16, + /* 0x11 */ PLAYER_ANIMGROUP_17, + /* 0x12 */ PLAYER_ANIMGROUP_18, + /* 0x13 */ PLAYER_ANIMGROUP_19, + /* 0x14 */ PLAYER_ANIMGROUP_20, + /* 0x15 */ PLAYER_ANIMGROUP_21, + /* 0x16 */ PLAYER_ANIMGROUP_22, + /* 0x17 */ PLAYER_ANIMGROUP_23, + /* 0x18 */ PLAYER_ANIMGROUP_24, + /* 0x19 */ PLAYER_ANIMGROUP_25, + /* 0x1A */ PLAYER_ANIMGROUP_26, + /* 0x1B */ PLAYER_ANIMGROUP_27, + /* 0x1C */ PLAYER_ANIMGROUP_28, + /* 0x1D */ PLAYER_ANIMGROUP_29, + /* 0x1E */ PLAYER_ANIMGROUP_30, + /* 0x1F */ PLAYER_ANIMGROUP_31, + /* 0x20 */ PLAYER_ANIMGROUP_32, + /* 0x21 */ PLAYER_ANIMGROUP_33, + /* 0x22 */ PLAYER_ANIMGROUP_34, + /* 0x23 */ PLAYER_ANIMGROUP_35, + /* 0x24 */ PLAYER_ANIMGROUP_36, + /* 0x25 */ PLAYER_ANIMGROUP_37, + /* 0x26 */ PLAYER_ANIMGROUP_38, + /* 0x27 */ PLAYER_ANIMGROUP_39, + /* 0x28 */ PLAYER_ANIMGROUP_40, + /* 0x29 */ PLAYER_ANIMGROUP_41, + /* 0x2A */ PLAYER_ANIMGROUP_42, + /* 0x2B */ PLAYER_ANIMGROUP_43, + /* 0x2C */ PLAYER_ANIMGROUP_44, + /* 0x2D */ PLAYER_ANIMGROUP_MAX } PlayerAnimGroup; -#define PLAYER_LIMB_BUF_COUNT PLAYER_LIMB_MAX + 2 // 2 extra entries in limb buffers? +#define LIMB_BUF_COUNT(limbCount) ((ALIGN16((limbCount) * sizeof(Vec3s)) + sizeof(Vec3s) - 1) / sizeof(Vec3s)) +#define PLAYER_LIMB_BUF_COUNT LIMB_BUF_COUNT(PLAYER_LIMB_MAX) typedef struct { /* 0x00 */ f32 unk_00; @@ -361,6 +396,9 @@ typedef struct { /* 0x10 */ Vec3f base; } WeaponInfo; // size = 0x1C +// #region SOH [General] +// Supporting pendingFlag +// Upstream TODO: Rename these to be more obviously SoH specific typedef enum { FLAG_NONE, FLAG_SCENE_SWITCH, @@ -375,9 +413,10 @@ typedef struct { /* 0x00 */ s32 flagID; // which flag to set when Player_SetPendingFlag is called /* 0x04 */ FlagType flagType; // type of flag to set when Player_SetPendingFlag is called } PendingFlag; // size = 0x06 +// #endregion #define PLAYER_STATE1_0 (1 << 0) -#define PLAYER_STATE1_1 (1 << 1) +#define PLAYER_STATE1_SWINGING_BOTTLE (1 << 1) #define PLAYER_STATE1_2 (1 << 2) #define PLAYER_STATE1_3 (1 << 3) #define PLAYER_STATE1_4 (1 << 4) @@ -425,9 +464,9 @@ typedef struct { #define PLAYER_STATE2_13 (1 << 13) #define PLAYER_STATE2_14 (1 << 14) #define PLAYER_STATE2_15 (1 << 15) -#define PLAYER_STATE2_16 (1 << 16) +#define PLAYER_STATE2_DO_ACTION_ENTER (1 << 16) // Turns on the "Enter On A" DoAction #define PLAYER_STATE2_17 (1 << 17) -#define PLAYER_STATE2_18 (1 << 18) +#define PLAYER_STATE2_CRAWLING (1 << 18) // Crawling through a crawlspace #define PLAYER_STATE2_19 (1 << 19) #define PLAYER_STATE2_20 (1 << 20) #define PLAYER_STATE2_21 (1 << 21) @@ -448,24 +487,24 @@ typedef struct { #define PLAYER_STATE3_3 (1 << 3) #define PLAYER_STATE3_4 (1 << 4) #define PLAYER_STATE3_5 (1 << 5) -#define PLAYER_STATE3_6 (1 << 6) +#define PLAYER_STATE3_RESTORE_NAYRUS_LOVE (1 << 6) // Set by ocarina effects actors when destroyed to signal Nayru's Love may be restored (see `ACTOROVL_ALLOC_ABSOLUTE`) #define PLAYER_STATE3_7 (1 << 7) typedef void (*PlayerFunc674)(struct Player*, struct PlayState*); -typedef s32(*PlayerFunc82C)(struct Player*, struct PlayState*); +typedef s32 (*PlayerFunc82C)(struct Player*, struct PlayState*); typedef void (*PlayerFuncA74)(struct PlayState*, struct Player*); typedef struct Player { /* 0x0000 */ Actor actor; /* 0x014C */ s8 currentTunic; // current tunic from `PlayerTunic` - /* 0x014D */ s8 currentSwordItem; // current sword Item ID + /* 0x014D */ s8 currentSwordItemId; /* 0x014E */ s8 currentShield; // current shield from `PlayerShield` /* 0x014F */ s8 currentBoots; // current boots from `PlayerBoots` /* 0x0150 */ s8 heldItemButton; // Button index for the item currently used - /* 0x0151 */ s8 heldItemActionParam; // Action param for the item currently used + /* 0x0151 */ s8 heldItemAction; // Item action for the item currently used /* 0x0152 */ u8 heldItemId; // Item id for the item currently used /* 0x0153 */ s8 prevBoots; // previous boots from `PlayerBoots` - /* 0x0154 */ s8 itemActionParam; // the difference between this and heldItemActionParam is unclear + /* 0x0154 */ s8 itemAction; // the difference between this and heldItemAction is unclear /* 0x0155 */ char unk_155[0x003]; /* 0x0158 */ u8 modelGroup; /* 0x0159 */ u8 nextModelGroup; @@ -475,71 +514,71 @@ typedef struct Player { /* 0x015D */ u8 rightHandType; /* 0x015E */ u8 sheathType; /* 0x015F */ u8 currentMask; // current mask equipped from `PlayerMask` - /* 0x0160 */ Gfx** rightHandDLists; - /* 0x0164 */ Gfx** leftHandDLists; - /* 0x0168 */ Gfx** sheathDLists; - /* 0x016C */ Gfx** waistDLists; + /* 0x0160 */ Gfx** rightHandDLists; + /* 0x0164 */ Gfx** leftHandDLists; + /* 0x0168 */ Gfx** sheathDLists; + /* 0x016C */ Gfx** waistDLists; /* 0x0170 */ u8 giObjectLoading; /* 0x0174 */ DmaRequest giObjectDmaRequest; /* 0x0194 */ OSMesgQueue giObjectLoadQueue; /* 0x01AC */ OSMesg giObjectLoadMsg; - /* 0x01B0 */ void* giObjectSegment; // also used for title card textures + /* 0x01B0 */ void* giObjectSegment; // also used for title card textures /* 0x01B4 */ SkelAnime skelAnime; /* 0x01F8 */ Vec3s jointTable[PLAYER_LIMB_BUF_COUNT]; /* 0x0288 */ Vec3s morphTable[PLAYER_LIMB_BUF_COUNT]; /* 0x0318 */ Vec3s blendTable[PLAYER_LIMB_BUF_COUNT]; /* 0x03A8 */ s16 unk_3A8[2]; - /* 0x03AC */ Actor* heldActor; + /* 0x03AC */ Actor* heldActor; /* 0x03B0 */ Vec3f leftHandPos; /* 0x03BC */ Vec3s unk_3BC; - /* 0x03C4 */ Actor* unk_3C4; + /* 0x03C4 */ Actor* unk_3C4; /* 0x03C8 */ Vec3f unk_3C8; /* 0x03D4 */ char unk_3D4[0x058]; /* 0x042C */ s8 doorType; /* 0x042D */ s8 doorDirection; /* 0x042E */ s16 doorTimer; - /* 0x0430 */ Actor* doorActor; - /* 0x0434 */ s16 getItemId; + /* 0x0430 */ Actor* doorActor; + /* 0x0434 */ s16 getItemId; // Upstream TODO: Document why this is s16 while it's s8 upstream /* 0x0436 */ u16 getItemDirection; - /* 0x0438 */ Actor* interactRangeActor; + /* 0x0438 */ Actor* interactRangeActor; /* 0x043C */ s8 mountSide; /* 0x043D */ char unk_43D[0x003]; - /* 0x0440 */ Actor* rideActor; + /* 0x0440 */ Actor* rideActor; /* 0x0444 */ u8 csMode; /* 0x0445 */ u8 prevCsMode; /* 0x0446 */ u8 unk_446; /* 0x0447 */ u8 unk_447; - /* 0x0448 */ Actor* unk_448; + /* 0x0448 */ Actor* unk_448; /* 0x044C */ char unk_44C[0x004]; /* 0x0450 */ Vec3f unk_450; /* 0x045C */ Vec3f unk_45C; /* 0x0468 */ char unk_468[0x002]; - /* 0x046A */ s16 unk_46A; - /* 0x046C */ s16 unk_46C; + /* 0x046A */ s16 doorBgCamIndex; + /* 0x046C */ s16 subCamId; /* 0x046E */ char unk_46E[0x02A]; /* 0x0498 */ ColliderCylinder cylinder; - /* 0x04E4 */ ColliderQuad swordQuads[2]; + /* 0x04E4 */ ColliderQuad meleeWeaponQuads[2]; /* 0x05E4 */ ColliderQuad shieldQuad; - /* 0x0664 */ Actor* unk_664; + /* 0x0664 */ Actor* unk_664; /* 0x0668 */ char unk_668[0x004]; /* 0x066C */ s32 unk_66C; - /* 0x0670 */ s32 swordEffectIndex; + /* 0x0670 */ s32 meleeWeaponEffectIndex; /* 0x0674 */ PlayerFunc674 func_674; /* 0x0678 */ PlayerAgeProperties* ageProperties; /* 0x067C */ u32 stateFlags1; /* 0x0680 */ u32 stateFlags2; - /* 0x0684 */ Actor* unk_684; - /* 0x0688 */ Actor* boomerangActor; - /* 0x068C */ Actor* naviActor; + /* 0x0684 */ Actor* unk_684; + /* 0x0688 */ Actor* boomerangActor; + /* 0x068C */ Actor* naviActor; /* 0x0690 */ s16 naviTextId; /* 0x0692 */ u8 stateFlags3; /* 0x0693 */ s8 exchangeItemId; - /* 0x0694 */ Actor* targetActor; + /* 0x0694 */ Actor* targetActor; /* 0x0698 */ f32 targetActorDistance; /* 0x069C */ char unk_69C[0x004]; /* 0x06A0 */ f32 unk_6A0; /* 0x06A4 */ f32 unk_6A4; - /* 0x06A8 */ Actor* unk_6A8; + /* 0x06A8 */ Actor* unk_6A8; /* 0x06AC */ s8 unk_6AC; /* 0x06AD */ u8 unk_6AD; /* 0x06AE */ u16 unk_6AE; @@ -565,8 +604,8 @@ typedef struct Player { /* 0x083C */ s16 currentYaw; /* 0x083E */ s16 targetYaw; /* 0x0840 */ u16 unk_840; - /* 0x0842 */ s8 swordAnimation; - /* 0x0843 */ s8 swordState; + /* 0x0842 */ s8 meleeWeaponAnimation; + /* 0x0843 */ s8 swordState; // Upstream TODO: meleeWeaponState /* 0x0844 */ s8 unk_844; /* 0x0845 */ u8 unk_845; /* 0x0846 */ u8 unk_846; @@ -609,14 +648,14 @@ typedef struct Player { /* 0x08A2 */ s16 unk_8A2; /* 0x08A4 */ f32 unk_8A4; /* 0x08A8 */ f32 unk_8A8; - /* 0x08AC */ f32 windSpeed; - /* 0x08B0 */ s16 windDirection; - /* 0x08B4 */ WeaponInfo swordInfo[3]; - /* 0x0908 */ Vec3f bodyPartsPos[18]; + /* 0x08AC */ f32 windSpeed; // Pushing player, examples include water currents, floor conveyors, climbing sloped surfaces // Upstream TODO: pushedSpeed + /* 0x08B0 */ s16 windDirection; // Yaw direction of player being pushed // Upstream TODO: pushedYaw + /* 0x08B4 */ WeaponInfo meleeWeaponInfo[3]; + /* 0x0908 */ Vec3f bodyPartsPos[PLAYER_BODYPART_MAX]; /* 0x09E0 */ MtxF mf_9E0; /* 0x0A20 */ MtxF shieldMf; /* 0x0A60 */ u8 isBurning; - /* 0x0A61 */ u8 flameTimers[18]; // one flame per body part + /* 0x0A61 */ u8 flameTimers[PLAYER_BODYPART_MAX]; // one flame per body part /* 0x0A73 */ u8 unk_A73; /* 0x0A74 */ PlayerFuncA74 func_A74; /* 0x0A78 */ s8 invincibilityTimer; // prevents damage when nonzero (positive = visible, counts towards zero each frame) @@ -630,9 +669,15 @@ typedef struct Player { /* 0x0A86 */ s8 unk_A86; /* 0x0A87 */ u8 unk_A87; /* 0x0A88 */ Vec3f unk_A88; // previous body part 0 position - /* 0x0A95 */ PendingFlag pendingFlag; - /* 0x0AA1 */ u8 boomerangQuickRecall; // Has the player pressed the boomerang button while it's in the air still? - /* 0x0AA2 */ GetItemEntry getItemEntry; -} Player; // size = 0xAAA + // #region SOH [General] + // Upstream TODO: Rename these to be more obviously SoH specific + /* */ PendingFlag pendingFlag; + /* */ GetItemEntry getItemEntry; + // #endregion + // #region SOH [Enhancements] + // Upstream TODO: Rename this to make it more obvious it is apart of an enhancement + /* */ u8 boomerangQuickRecall; // Has the player pressed the boomerang button while it's in the air still? + // #endregion +} Player; // size = 0xA94 #endif diff --git a/soh/include/z64save.h b/soh/include/z64save.h index fddf9889a..52c7318a6 100644 --- a/soh/include/z64save.h +++ b/soh/include/z64save.h @@ -9,16 +9,42 @@ #include "soh/Enhancements/gameplaystats.h" #include "soh/Enhancements/randomizer/randomizer_entrance.h" +typedef enum { + /* 0x0 */ MAGIC_STATE_IDLE, // Regular gameplay + /* 0x1 */ MAGIC_STATE_CONSUME_SETUP, // Sets the speed at which magic border flashes + /* 0x2 */ MAGIC_STATE_CONSUME, // Consume magic until target is reached or no more magic is available + /* 0x3 */ MAGIC_STATE_METER_FLASH_1, // Flashes border and freezes Dark Link + /* 0x4 */ MAGIC_STATE_METER_FLASH_2, // Flashes border and draws yellow magic to preview target consumption + /* 0x5 */ MAGIC_STATE_RESET, // Reset colors and return to idle + /* 0x6 */ MAGIC_STATE_METER_FLASH_3, // Flashes border with no additional behaviour + /* 0x7 */ MAGIC_STATE_CONSUME_LENS, // Magic slowly consumed by lens. + /* 0x8 */ MAGIC_STATE_STEP_CAPACITY, // Step `magicCapacity` to full capacity + /* 0x9 */ MAGIC_STATE_FILL, // Add magic until magicFillTarget is reached. + /* 0xA */ MAGIC_STATE_ADD // Add requested magic +} MagicState; + +typedef enum { + /* 0 */ MAGIC_CONSUME_NOW, // Consume Magic immediately without preview + /* 1 */ MAGIC_CONSUME_WAIT_NO_PREVIEW, // Sets consume target but waits to consume. No yellow magic preview to target consumption. Unused + /* 2 */ MAGIC_CONSUME_NOW_ALT, // Identical behaviour to MAGIC_CONSUME_NOW. Unused + /* 3 */ MAGIC_CONSUME_LENS, // Lens consumption + /* 4 */ MAGIC_CONSUME_WAIT_PREVIEW, // Sets consume target but waits to consume. Draws yellow magic to target consumption + /* 5 */ MAGIC_ADD // Sets a target to add magic +} MagicChangeType; + +#define MAGIC_NORMAL_METER 0x30 +#define MAGIC_DOUBLE_METER (2 * MAGIC_NORMAL_METER) + typedef struct { - /* 0x00 */ u8 buttonItems[8]; - /* 0x04 */ u8 cButtonSlots[7]; - /* 0x08 */ u16 equipment; + /* 0x00 */ u8 buttonItems[8]; // SOH [Enhancements] Changed from 4 to 8 to support Dpad equips + /* 0x04 */ u8 cButtonSlots[7]; // SOH [Enhancements] Changed from 3 to 7 to support Dpad equips + /* 0x08 */ u16 equipment; // a mask where each nibble corresponds to a type of equipment `EquipmentType`, and each nibble is a piece `EquipValue*` } ItemEquips; // size = 0x0A typedef struct { /* 0x00 */ u8 items[24]; /* 0x18 */ s8 ammo[16]; - /* 0x28 */ u16 equipment; + /* 0x28 */ u16 equipment; // a mask where each nibble corresponds to a type of equipment `EquipmentType`, and each bit to an owned piece `EquipInv*` /* 0x2C */ u32 upgrades; /* 0x30 */ u32 questItems; /* 0x34 */ u8 dungeonItems[20]; @@ -49,11 +75,24 @@ typedef struct { } SavedSceneFlags; // size = 0x1C typedef struct { - /* 0x00 */ s16 scene; + /* 0x00 */ s16 scene; // Upstream TODO: sceneId /* 0x02 */ Vec3s pos; /* 0x08 */ s16 angle; } HorseData; // size = 0x0A +/** + * The respawn mode names refer to the perceived player movement when respawning + * "down": being on ground + * "return": coming from the ground + * "top": coming from the air + */ +typedef enum { + /* 0x00 */ RESPAWN_MODE_DOWN, /* Normal Void Outs */ + /* 0x01 */ RESPAWN_MODE_RETURN, /* Grotto Returnpoints */ + /* 0x02 */ RESPAWN_MODE_TOP, /* Farore's Wind */ + /* 0x03 */ RESPAWN_MODE_MAX +} RespawnMode; + typedef struct { /* 0x00 */ Vec3f pos; /* 0x0C */ s16 yaw; @@ -93,60 +132,71 @@ typedef struct { typedef struct { /* 0x0000 */ s32 entranceIndex; // start of `save` substruct, originally called "memory" - /* 0x0004 */ s32 linkAge; // 0: Adult; 1: Child + /* 0x0004 */ s32 linkAge; // 0: Adult; 1: Child (see enum `LinkAge`) /* 0x0008 */ s32 cutsceneIndex; /* 0x000C */ u16 dayTime; // "zelda_time" /* 0x0010 */ s32 nightFlag; /* 0x0014 */ s32 totalDays; /* 0x0018 */ s32 bgsDayCount; // increments with totalDays, can be cleared with `Environment_ClearBgsDayCount` + /* 0x001C */ char newf[6]; // string "ZELDAZ". start of `info` substruct, originally called "information" /* 0x0022 */ u16 deaths; /* 0x0024 */ char playerName[8]; /* 0x002C */ s16 n64ddFlag; /* 0x002E */ s16 healthCapacity; // "max_life" /* 0x0030 */ s16 health; // "now_life" - /* 0x0032 */ s8 magicLevel; - /* 0x0033 */ s8 magic; + /* 0x0032 */ s8 magicLevel; // 0 for no magic/new load, 1 for magic, 2 for double magic + /* 0x0033 */ s8 magic; // current magic available for use /* 0x0034 */ s16 rupees; /* 0x0036 */ u16 swordHealth; /* 0x0038 */ u16 naviTimer; - /* 0x003A */ u8 magicAcquired; - /* 0x003C */ u8 doubleMagic; - /* 0x003D */ u8 doubleDefense; + /* 0x003A */ u8 isMagicAcquired; + /* 0x003B */ char unk_3B[0x01]; + /* 0x003C */ u8 isDoubleMagicAcquired; + /* 0x003D */ u8 isDoubleDefenseAcquired; /* 0x003E */ u8 bgsFlag; /* 0x003F */ u8 ocarinaGameRoundNum; /* 0x0040 */ ItemEquips childEquips; /* 0x004A */ ItemEquips adultEquips; - /* 0x0054 */ u32 unk_54; // this may be incorrect, currently used for alignement - /* 0x0066 */ s16 savedSceneNum; + /* 0x0054 */ u32 unk_54; // this may be incorrect, currently used for alignment + /* 0x0058 */ char unk_58[0x0E]; + /* 0x0066 */ s16 savedSceneNum; // Upstream TODO: sceneId /* 0x0068 */ ItemEquips equips; /* 0x0074 */ Inventory inventory; /* 0x00D4 */ SavedSceneFlags sceneFlags[124]; /* 0x0E64 */ FaroresWindData fw; + /* 0x0E8C */ char unk_E8C[0x10]; /* 0x0E9C */ s32 gsFlags[6]; + /* 0x0EB4 */ char unk_EB4[0x4]; /* 0x0EB8 */ s32 highScores[7]; /* 0x0ED4 */ u16 eventChkInf[14]; // "event_chk_inf" /* 0x0EF0 */ u16 itemGetInf[4]; // "item_get_inf" /* 0x0EF8 */ u16 infTable[30]; // "inf_table" + /* 0x0F34 */ char unk_F34[0x04]; /* 0x0F38 */ u32 worldMapAreaData; // "area_arrival" - /* 0x0F40 */ u8 scarecrowCustomSongSet; - /* 0x0F41 */ OcarinaNote scarecrowCustomSong[108]; + /* 0x0F3C */ char unk_F3C[0x4]; + /* 0x0F40 */ u8 scarecrowLongSongSet; + /* 0x0F41 */ OcarinaNote scarecrowLongSong[108]; // Upstream TODO: Audio + /* 0x12A1 */ char unk_12A1[0x24]; /* 0x12C5 */ u8 scarecrowSpawnSongSet; - /* 0x12C6 */ OcarinaNote scarecrowSpawnSong[16]; + /* 0x12C6 */ OcarinaNote scarecrowSpawnSong[16]; // Upstream TODO: Audio /* 0x1346 */ char unk_1346[0x02]; /* 0x1348 */ HorseData horseData; + /* 0x1352 */ u16 checksum; // "check_sum" /* 0x1354 */ s32 fileNum; // "file_no" /* 0x1358 */ char unk_1358[0x0004]; /* 0x135C */ s32 gameMode; - /* 0x1360 */ s32 sceneSetupIndex; + /* 0x1360 */ s32 sceneSetupIndex; // "counter" // Upstream TODO: sceneLayer /* 0x1364 */ s32 respawnFlag; // "restart_flag" - /* 0x1368 */ RespawnData respawn[3]; // "restart_data" + /* 0x1368 */ RespawnData respawn[RESPAWN_MODE_MAX]; // "restart_data" /* 0x13BC */ f32 entranceSpeed; /* 0x13C0 */ u16 entranceSound; - /* 0x13C3 */ u8 unk_13C3; + /* 0x13C2 */ char unk_13C2[0x0001]; + /* 0x13C3 */ u8 retainWeatherMode; /* 0x13C4 */ s16 dogParams; /* 0x13C6 */ u8 textTriggerFlags; /* 0x13C7 */ u8 showTitleCard; /* 0x13C8 */ s16 nayrusLoveTimer; + /* 0x13CA */ char unk_13CA[0x0002]; /* 0x13CC */ s16 rupeeAccumulator; /* 0x13CE */ s16 timer1State; /* 0x13D0 */ s16 timer1Value; @@ -154,64 +204,69 @@ typedef struct { /* 0x13D4 */ s16 timer2Value; /* 0x13D6 */ s16 timerX[2]; /* 0x13DA */ s16 timerY[2]; + /* 0x13DE */ char unk_13DE[0x0002]; /* 0x13E0 */ u8 seqId; /* 0x13E1 */ u8 natureAmbienceId; - /* 0x13E2 */ u8 buttonStatus[9]; + /* 0x13E2 */ u8 buttonStatus[9]; // SOH [Enhancements] Changed from 5 to 9 to support Dpad equips /* 0x13E7 */ u8 unk_13E7; // alpha related /* 0x13E8 */ u16 unk_13E8; // alpha type? /* 0x13EA */ u16 unk_13EA; // also alpha type? /* 0x13EC */ u16 unk_13EC; // alpha type counter? /* 0x13EE */ u16 unk_13EE; // previous alpha type? - /* 0x13F0 */ s16 unk_13F0; // magic related - /* 0x13F2 */ s16 unk_13F2; // magic related - /* 0x13F4 */ s16 unk_13F4; // magic related - /* 0x13F6 */ s16 unk_13F6; // magic related - /* 0x13F8 */ s16 unk_13F8; // magic related + /* 0x13F0 */ s16 magicState; // determines magic meter behavior on each frame + /* 0x13F2 */ s16 prevMagicState; // used to resume the previous state after adding or filling magic + /* 0x13F4 */ s16 magicCapacity; // maximum magic available + /* 0x13F6 */ s16 magicFillTarget; // target used to fill magic. Target can either be full capacity (Magic_Fill, magic upgrades), or the saved magic amount (loading a file, game over) + /* 0x13F8 */ s16 magicTarget; // target for magic to step to when adding or consuming magic /* 0x13FA */ u16 eventInf[4]; // "event_inf" /* 0x1402 */ u16 mapIndex; // intended for maps/minimaps but commonly used as the dungeon index /* 0x1404 */ u16 minigameState; /* 0x1406 */ u16 minigameScore; // "yabusame_total" + /* 0x1408 */ char unk_1408[0x0001]; /* 0x1409 */ u8 language; // NTSC 0: Japanese; 1: English | PAL 0: English; 1: German; 2: French /* 0x140A */ u8 audioSetting; + /* 0x140B */ char unk_140B[0x0001]; /* 0x140C */ u8 zTargetSetting; // 0: Switch; 1: Hold /* 0x140E */ u16 forcedSeqId; // immediately start playing the sequence if set - /* 0x1410 */ u8 unk_1410; // transition related + /* 0x1410 */ u8 cutsceneTransitionControl; // context dependent usage: can either trigger a delayed fade or control fill alpha + /* 0x1411 */ char unk_1411[0x0001]; /* 0x1412 */ u16 nextCutsceneIndex; /* 0x1414 */ u8 cutsceneTrigger; /* 0x1415 */ u8 chamberCutsceneNum; /* 0x1416 */ u16 nextDayTime; // "next_zelda_time" - /* 0x1418 */ u8 fadeDuration; - /* 0x1419 */ u8 unk_1419; // transition related + /* 0x1418 */ u8 transFadeDuration; + /* 0x1419 */ u8 transWipeSpeed; /* 0x141A */ u16 skyboxTime; /* 0x141C */ u8 dogIsLost; - /* 0x141D */ u8 nextTransition; + /* 0x141D */ u8 nextTransitionType; + /* 0x141E */ char unk_141E[0x0002]; /* 0x1420 */ s16 worldMapArea; /* 0x1422 */ s16 sunsSongState; // controls the effects of suns song /* 0x1424 */ s16 healthAccumulator; - uint32_t isMasterQuest; - RandoSetting randoSettings[300]; - ItemLocationRando itemLocations[RC_MAX]; - HintLocationRando hintLocations[50]; - EntranceOverride entranceOverrides[ENTRANCE_OVERRIDES_MAX_COUNT]; - char childAltarText[250]; - char adultAltarText[750]; - char ganonHintText[150]; - char ganonText[250]; - u8 seedIcons[5]; - u16 randomizerInf[9]; - u8 temporaryWeapon; - u16 adultTradeItems; - u8 pendingIceTrapCount; - u8 mqDungeonCount; - SohStats sohStats; + // #region SOH [General] + // Upstream TODO: Move these to their own struct or name to more obviously specific to SoH + /* */ uint32_t isMasterQuest; + /* */ u8 mqDungeonCount; + /* */ u8 pendingIceTrapCount; + /* */ SohStats sohStats; + /* */ u8 temporaryWeapon; + // #endregion + // #region SOH [Randomizer] + // Upstream TODO: Move these to their own struct or name to more obviously specific to Randomizer + /* */ RandoSetting randoSettings[300]; + /* */ ItemLocationRando itemLocations[RC_MAX]; + /* */ HintLocationRando hintLocations[50]; + /* */ EntranceOverride entranceOverrides[ENTRANCE_OVERRIDES_MAX_COUNT]; + /* */ char childAltarText[250]; + /* */ char adultAltarText[750]; + /* */ char ganonHintText[150]; + /* */ char ganonText[250]; + /* */ u8 seedIcons[5]; + /* */ u16 randomizerInf[9]; + /* */ u16 adultTradeItems; + // #endregion } SaveContext; // size = 0x1428 -typedef enum { - /* 0x00 */ RESPAWN_MODE_DOWN, /* Normal Void Outs */ - /* 0x01 */ RESPAWN_MODE_RETURN, /* Grotto Returnpoints */ - /* 0x02 */ RESPAWN_MODE_TOP /* Farore's Wind */ -} RespawnMode; - typedef enum { /* 0x00 */ BTN_ENABLED, /* 0xFF */ BTN_DISABLED = 0xFF @@ -243,4 +298,521 @@ typedef enum { /* 3 */ SUNSSONG_SPECIAL // time does not advance, but signals the song was played. used for freezing redeads } SunsSongState; +typedef enum { + /* 0 */ GAMEMODE_NORMAL, + /* 1 */ GAMEMODE_TITLE_SCREEN, + /* 2 */ GAMEMODE_FILE_SELECT, // Note: only instance type transitions swap to file select + /* 3 */ GAMEMODE_END_CREDITS +} GameMode; + +typedef enum { + /* 0 */ SCENE_LAYER_CHILD_DAY, + /* 1 */ SCENE_LAYER_CHILD_NIGHT, + /* 2 */ SCENE_LAYER_ADULT_DAY, + /* 3 */ SCENE_LAYER_ADULT_NIGHT, + /* 4 */ SCENE_LAYER_CUTSCENE_FIRST +} SceneLayer; + +#define IS_CUTSCENE_LAYER (gSaveContext.sceneLayer >= SCENE_LAYER_CUTSCENE_FIRST) + +typedef enum { + /* 0 */ LINK_AGE_ADULT, + /* 1 */ LINK_AGE_CHILD +} LinkAge; + + + +/* + * + * SaveContext flags + * + */ + + +/* + * SaveContext.eventChkInf + */ + +#define EVENTCHKINF_02 0x02 +#define EVENTCHKINF_03 0x03 +#define EVENTCHKINF_04 0x04 +#define EVENTCHKINF_05 0x05 +#define EVENTCHKINF_07 0x07 +#define EVENTCHKINF_09 0x09 +#define EVENTCHKINF_0A 0x0A +#define EVENTCHKINF_0B 0x0B +#define EVENTCHKINF_0C 0x0C +#define EVENTCHKINF_0F 0x0F +#define EVENTCHKINF_10 0x10 +#define EVENTCHKINF_11 0x11 +#define EVENTCHKINF_12 0x12 +#define EVENTCHKINF_TALON_WOKEN_IN_CASTLE 0x13 +#define EVENTCHKINF_TALON_RETURNED_FROM_CASTLE 0x14 +#define EVENTCHKINF_15 0x15 +#define EVENTCHKINF_16 0x16 +#define EVENTCHKINF_EPONA_OBTAINED 0x18 +#define EVENTCHKINF_1B 0x1B +#define EVENTCHKINF_1C 0x1C +#define EVENTCHKINF_1D 0x1D +#define EVENTCHKINF_1E 0x1E +#define EVENTCHKINF_20 0x20 +#define EVENTCHKINF_21 0x21 +#define EVENTCHKINF_22 0x22 +#define EVENTCHKINF_23 0x23 +#define EVENTCHKINF_25 0x25 +#define EVENTCHKINF_2A 0x2A +#define EVENTCHKINF_2B 0x2B +#define EVENTCHKINF_2C 0x2C +#define EVENTCHKINF_2D 0x2D +#define EVENTCHKINF_2F 0x2F +#define EVENTCHKINF_30 0x30 +#define EVENTCHKINF_31 0x31 +#define EVENTCHKINF_32 0x32 +#define EVENTCHKINF_33 0x33 +#define EVENTCHKINF_37 0x37 +#define EVENTCHKINF_38 0x38 +#define EVENTCHKINF_39 0x39 +#define EVENTCHKINF_3A 0x3A +#define EVENTCHKINF_3B 0x3B +#define EVENTCHKINF_3C 0x3C + +// 0x40 +#define EVENTCHKINF_40_INDEX 4 +#define EVENTCHKINF_40_SHIFT 0 +#define EVENTCHKINF_40_MASK (1 << EVENTCHKINF_40_SHIFT) +#define EVENTCHKINF_40 ((EVENTCHKINF_40_INDEX << 4) | EVENTCHKINF_40_SHIFT) + +#define EVENTCHKINF_41 0x41 +#define EVENTCHKINF_42 0x42 +#define EVENTCHKINF_43 0x43 +#define EVENTCHKINF_45 0x45 +#define EVENTCHKINF_48 0x48 +#define EVENTCHKINF_49 0x49 +#define EVENTCHKINF_4A 0x4A +#define EVENTCHKINF_4B 0x4B +#define EVENTCHKINF_4C 0x4C +#define EVENTCHKINF_4D 0x4D +#define EVENTCHKINF_4E 0x4E +#define EVENTCHKINF_4F 0x4F +#define EVENTCHKINF_50 0x50 +#define EVENTCHKINF_51 0x51 +#define EVENTCHKINF_52 0x52 +#define EVENTCHKINF_54 0x54 +#define EVENTCHKINF_55 0x55 +#define EVENTCHKINF_59 0x59 +#define EVENTCHKINF_5A 0x5A +#define EVENTCHKINF_5B 0x5B +#define EVENTCHKINF_5C 0x5C +#define EVENTCHKINF_65 0x65 +#define EVENTCHKINF_67 0x67 +#define EVENTCHKINF_68 0x68 +#define EVENTCHKINF_69 0x69 +#define EVENTCHKINF_TALON_WOKEN_IN_KAKARIKO 0x6A + +// 0x6B +#define EVENTCHKINF_TALON_RETURNED_FROM_KAKARIKO_INDEX 6 +#define EVENTCHKINF_TALON_RETURNED_FROM_KAKARIKO_SHIFT 11 +#define EVENTCHKINF_TALON_RETURNED_FROM_KAKARIKO_MASK (1 << EVENTCHKINF_TALON_RETURNED_FROM_KAKARIKO_SHIFT) +#define EVENTCHKINF_TALON_RETURNED_FROM_KAKARIKO ((EVENTCHKINF_TALON_RETURNED_FROM_KAKARIKO_INDEX << 4) | EVENTCHKINF_TALON_RETURNED_FROM_KAKARIKO_SHIFT) + +#define EVENTCHKINF_6E 0x6E +#define EVENTCHKINF_6F 0x6F +#define EVENTCHKINF_70 0x70 +#define EVENTCHKINF_71 0x71 +#define EVENTCHKINF_72 0x72 +#define EVENTCHKINF_73 0x73 +#define EVENTCHKINF_74 0x74 +#define EVENTCHKINF_75 0x75 +#define EVENTCHKINF_76 0x76 +#define EVENTCHKINF_77 0x77 +#define EVENTCHKINF_78 0x78 +#define EVENTCHKINF_80 0x80 +#define EVENTCHKINF_82 0x82 +#define EVENTCHKINF_8C 0x8C +#define EVENTCHKINF_8D 0x8D +#define EVENTCHKINF_8E 0x8E +#define EVENTCHKINF_8F 0x8F + +// 0x90-0x93 +// carpenters freed from the gerudo +#define EVENTCHKINF_CARPENTERS_FREE_INDEX 9 +#define EVENTCHKINF_CARPENTERS_FREE_SHIFT(n) (0 + (n)) +#define EVENTCHKINF_CARPENTERS_FREE_MASK(n) (1 << EVENTCHKINF_CARPENTERS_FREE_SHIFT(n)) +#define EVENTCHKINF_CARPENTERS_FREE(n) ((EVENTCHKINF_CARPENTERS_FREE_INDEX << 4) | EVENTCHKINF_CARPENTERS_FREE_SHIFT(n)) +#define EVENTCHKINF_CARPENTERS_FREE_MASK_ALL (\ + EVENTCHKINF_CARPENTERS_FREE_MASK(0) \ + | EVENTCHKINF_CARPENTERS_FREE_MASK(1) \ + | EVENTCHKINF_CARPENTERS_FREE_MASK(2) \ + | EVENTCHKINF_CARPENTERS_FREE_MASK(3) ) +#define GET_EVENTCHKINF_CARPENTERS_FREE_ALL() \ + CHECK_FLAG_ALL(gSaveContext.eventChkInf[EVENTCHKINF_CARPENTERS_FREE_INDEX], EVENTCHKINF_CARPENTERS_FREE_MASK_ALL) + +#define EVENTCHKINF_94 0x94 +#define EVENTCHKINF_95 0x95 +#define EVENTCHKINF_96 0x96 +#define EVENTCHKINF_9C 0x9C +#define EVENTCHKINF_A0 0xA0 +#define EVENTCHKINF_A1 0xA1 +#define EVENTCHKINF_A3 0xA3 +#define EVENTCHKINF_A4 0xA4 +#define EVENTCHKINF_A5 0xA5 +#define EVENTCHKINF_A6 0xA6 +#define EVENTCHKINF_A7 0xA7 +#define EVENTCHKINF_A8 0xA8 +#define EVENTCHKINF_A9 0xA9 +#define EVENTCHKINF_AA 0xAA +#define EVENTCHKINF_AC 0xAC +#define EVENTCHKINF_AD 0xAD +#define EVENTCHKINF_B0 0xB0 +#define EVENTCHKINF_B1 0xB1 +#define EVENTCHKINF_B2 0xB2 +#define EVENTCHKINF_B3 0xB3 +#define EVENTCHKINF_B4 0xB4 +#define EVENTCHKINF_B5 0xB5 +#define EVENTCHKINF_B6 0xB6 +#define EVENTCHKINF_B7 0xB7 +#define EVENTCHKINF_B8 0xB8 +#define EVENTCHKINF_B9 0xB9 +#define EVENTCHKINF_BA 0xBA +#define EVENTCHKINF_BB 0xBB +#define EVENTCHKINF_BC 0xBC +#define EVENTCHKINF_BD 0xBD +#define EVENTCHKINF_BE 0xBE +#define EVENTCHKINF_BF 0xBF +#define EVENTCHKINF_C0 0xC0 +#define EVENTCHKINF_C1 0xC1 +#define EVENTCHKINF_C3 0xC3 +#define EVENTCHKINF_C4 0xC4 +#define EVENTCHKINF_C5 0xC5 +#define EVENTCHKINF_C6 0xC6 +#define EVENTCHKINF_C7 0xC7 +#define EVENTCHKINF_C8 0xC8 +#define EVENTCHKINF_C9 0xC9 + +// 0xD0-0xD6 +#define EVENTCHKINF_SONGS_FOR_FROGS_INDEX 13 +#define EVENTCHKINF_SONGS_FOR_FROGS_CHOIR_SHIFT 0 +#define EVENTCHKINF_SONGS_FOR_FROGS_ZL_SHIFT 1 +#define EVENTCHKINF_SONGS_FOR_FROGS_EPONA_SHIFT 2 +#define EVENTCHKINF_SONGS_FOR_FROGS_SUNS_SHIFT 3 +#define EVENTCHKINF_SONGS_FOR_FROGS_SARIA_SHIFT 4 +#define EVENTCHKINF_SONGS_FOR_FROGS_SOT_SHIFT 5 +#define EVENTCHKINF_SONGS_FOR_FROGS_STORMS_SHIFT 6 +#define EVENTCHKINF_SONGS_FOR_FROGS_CHOIR_MASK (1 << EVENTCHKINF_SONGS_FOR_FROGS_CHOIR_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_ZL_MASK (1 << EVENTCHKINF_SONGS_FOR_FROGS_ZL_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_EPONA_MASK (1 << EVENTCHKINF_SONGS_FOR_FROGS_EPONA_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_SUNS_MASK (1 << EVENTCHKINF_SONGS_FOR_FROGS_SUNS_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_SARIA_MASK (1 << EVENTCHKINF_SONGS_FOR_FROGS_SARIA_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_SOT_MASK (1 << EVENTCHKINF_SONGS_FOR_FROGS_SOT_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_STORMS_MASK (1 << EVENTCHKINF_SONGS_FOR_FROGS_STORMS_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_CHOIR ((EVENTCHKINF_SONGS_FOR_FROGS_INDEX << 4) | EVENTCHKINF_SONGS_FOR_FROGS_CHOIR_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_ZL ((EVENTCHKINF_SONGS_FOR_FROGS_INDEX << 4) | EVENTCHKINF_SONGS_FOR_FROGS_ZL_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_EPONA ((EVENTCHKINF_SONGS_FOR_FROGS_INDEX << 4) | EVENTCHKINF_SONGS_FOR_FROGS_EPONA_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_SUNS ((EVENTCHKINF_SONGS_FOR_FROGS_INDEX << 4) | EVENTCHKINF_SONGS_FOR_FROGS_SUNS_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_SARIA ((EVENTCHKINF_SONGS_FOR_FROGS_INDEX << 4) | EVENTCHKINF_SONGS_FOR_FROGS_SARIA_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_SOT ((EVENTCHKINF_SONGS_FOR_FROGS_INDEX << 4) | EVENTCHKINF_SONGS_FOR_FROGS_SOT_SHIFT) +#define EVENTCHKINF_SONGS_FOR_FROGS_STORMS ((EVENTCHKINF_SONGS_FOR_FROGS_INDEX << 4) | EVENTCHKINF_SONGS_FOR_FROGS_STORMS_SHIFT) + +// 0xDA-0xDE +#define EVENTCHKINF_DA_DB_DC_DD_DE_INDEX 13 +#define EVENTCHKINF_DA_MASK (1 << 10) +#define EVENTCHKINF_DB_MASK (1 << 11) +#define EVENTCHKINF_DC_MASK (1 << 12) +#define EVENTCHKINF_DD_MASK (1 << 13) +#define EVENTCHKINF_DE_MASK (1 << 14) + + +/* + * SaveContext.itemGetInf + */ + +#define ITEMGETINF_TALON_BOTTLE 0x02 +#define ITEMGETINF_03 0x03 +#define ITEMGETINF_04 0x04 +#define ITEMGETINF_05 0x05 +#define ITEMGETINF_06 0x06 +#define ITEMGETINF_07 0x07 +#define ITEMGETINF_08 0x08 +#define ITEMGETINF_09 0x09 +#define ITEMGETINF_0A 0x0A +#define ITEMGETINF_0B 0x0B +#define ITEMGETINF_0C 0x0C +#define ITEMGETINF_0D 0x0D +#define ITEMGETINF_0E 0x0E +#define ITEMGETINF_0F 0x0F +#define ITEMGETINF_10 0x10 +#define ITEMGETINF_11 0x11 +#define ITEMGETINF_12 0x12 +#define ITEMGETINF_13 0x13 +#define ITEMGETINF_15 0x15 +#define ITEMGETINF_16 0x16 +#define ITEMGETINF_17 0x17 + +// 0x18-0x1A +#define ITEMGETINF_18_19_1A_INDEX 1 +#define ITEMGETINF_18_SHIFT 8 +#define ITEMGETINF_19_SHIFT 9 +#define ITEMGETINF_1A_SHIFT 10 +#define ITEMGETINF_18_MASK (1 << ITEMGETINF_18_SHIFT) +#define ITEMGETINF_19_MASK (1 << ITEMGETINF_19_SHIFT) +#define ITEMGETINF_1A_MASK (1 << ITEMGETINF_1A_SHIFT) +#define ITEMGETINF_18 ((ITEMGETINF_18_19_1A_INDEX << 4) | ITEMGETINF_18_SHIFT) +#define ITEMGETINF_19 ((ITEMGETINF_18_19_1A_INDEX << 4) | ITEMGETINF_19_SHIFT) +#define ITEMGETINF_1A ((ITEMGETINF_18_19_1A_INDEX << 4) | ITEMGETINF_1A_SHIFT) + +#define ITEMGETINF_1B 0x1B +#define ITEMGETINF_1C 0x1C +#define ITEMGETINF_1D 0x1D +#define ITEMGETINF_1E 0x1E +#define ITEMGETINF_1F 0x1F +#define ITEMGETINF_23 0x23 +#define ITEMGETINF_24 0x24 +#define ITEMGETINF_25 0x25 +#define ITEMGETINF_26 0x26 +#define ITEMGETINF_2A 0x2A +#define ITEMGETINF_2C 0x2C +#define ITEMGETINF_2E 0x2E +#define ITEMGETINF_30 0x30 +#define ITEMGETINF_31 0x31 +#define ITEMGETINF_38 0x38 +#define ITEMGETINF_39 0x39 +#define ITEMGETINF_3A 0x3A +#define ITEMGETINF_3B 0x3B +#define ITEMGETINF_3F 0x3F + + +/* + * SaveContext.infTable + */ + +#define INFTABLE_00 0x00 +#define INFTABLE_01 0x01 +#define INFTABLE_03 0x03 +#define INFTABLE_05 0x05 +#define INFTABLE_0C 0x0C +#define INFTABLE_0E 0x0E +#define INFTABLE_10 0x10 +#define INFTABLE_15 0x15 +#define INFTABLE_17 0x17 +#define INFTABLE_19 0x19 +#define INFTABLE_1E 0x1E +#define INFTABLE_22 0x22 +#define INFTABLE_24 0x24 +#define INFTABLE_26 0x26 +#define INFTABLE_28 0x28 +#define INFTABLE_2A 0x2A +#define INFTABLE_2B 0x2B +#define INFTABLE_2E 0x2E +#define INFTABLE_2F 0x2F +#define INFTABLE_30 0x30 +#define INFTABLE_41 0x41 +#define INFTABLE_47 0x47 +#define INFTABLE_51 0x51 +#define INFTABLE_59 0x59 +#define INFTABLE_61 0x61 +#define INFTABLE_66 0x66 +#define INFTABLE_6A 0x6A +#define INFTABLE_6C 0x6C +#define INFTABLE_71 0x71 +#define INFTABLE_76 0x76 +#define INFTABLE_77 0x77 +#define INFTABLE_TALKED_TO_TALON_IN_RANCH_HOUSE 0x7E +#define INFTABLE_84 0x84 +#define INFTABLE_85 0x85 +#define INFTABLE_8B 0x8B +#define INFTABLE_8C 0x8C +#define INFTABLE_8D 0x8D +#define INFTABLE_8E 0x8E +#define INFTABLE_94 0x94 +#define INFTABLE_97 0x97 +#define INFTABLE_9A 0x9A +#define INFTABLE_A2 0xA2 +#define INFTABLE_AB 0xAB +#define INFTABLE_B0 0xB0 +#define INFTABLE_B1 0xB1 +#define INFTABLE_B4 0xB4 +#define INFTABLE_B6 0xB6 +#define INFTABLE_B7 0xB7 +#define INFTABLE_B8 0xB8 +#define INFTABLE_B9 0xB9 +#define INFTABLE_BC 0xBC +#define INFTABLE_C0 0xC0 +#define INFTABLE_C1 0xC1 +#define INFTABLE_C2 0xC2 +#define INFTABLE_C3 0xC3 +#define INFTABLE_C4 0xC4 +#define INFTABLE_C5 0xC5 +#define INFTABLE_C6 0xC6 +#define INFTABLE_C7 0xC7 +#define INFTABLE_C8 0xC8 +#define INFTABLE_C9 0xC9 +#define INFTABLE_CA 0xCA +#define INFTABLE_CB 0xCB +#define INFTABLE_CC 0xCC +#define INFTABLE_CD 0xCD +#define INFTABLE_CE 0xCE +#define INFTABLE_D0 0xD0 +#define INFTABLE_D2 0xD2 +#define INFTABLE_D4 0xD4 +#define INFTABLE_D6 0xD6 +#define INFTABLE_D8 0xD8 +#define INFTABLE_D9 0xD9 +#define INFTABLE_E0 0xE0 +#define INFTABLE_E3 0xE3 +#define INFTABLE_E6 0xE6 +#define INFTABLE_EB 0xEB +#define INFTABLE_F0 0xF0 +#define INFTABLE_F4 0xF4 +#define INFTABLE_F8 0xF8 +#define INFTABLE_FC 0xFC +#define INFTABLE_109 0x109 +#define INFTABLE_10A 0x10A +#define INFTABLE_10B 0x10B +#define INFTABLE_10C 0x10C +#define INFTABLE_10D 0x10D +#define INFTABLE_10E 0x10E +#define INFTABLE_10F 0x10F +#define INFTABLE_113 0x113 +#define INFTABLE_11A 0x11A +#define INFTABLE_11E 0x11E +#define INFTABLE_124 0x124 +#define INFTABLE_129 0x129 +#define INFTABLE_12A 0x12A +#define INFTABLE_138 0x138 +#define INFTABLE_139 0x139 +#define INFTABLE_140 0x140 +#define INFTABLE_141 0x141 +#define INFTABLE_142 0x142 +#define INFTABLE_143 0x143 +#define INFTABLE_144 0x144 +#define INFTABLE_145 0x145 +#define INFTABLE_146 0x146 +#define INFTABLE_147 0x147 +#define INFTABLE_160 0x160 +#define INFTABLE_161 0x161 +#define INFTABLE_162 0x162 +#define INFTABLE_163 0x163 +#define INFTABLE_164 0x164 +#define INFTABLE_166 0x166 +#define INFTABLE_16A 0x16A +#define INFTABLE_16C 0x16C +#define INFTABLE_170 0x170 +#define INFTABLE_171 0x171 +#define INFTABLE_172 0x172 +#define INFTABLE_176 0x176 +#define INFTABLE_178 0x178 +#define INFTABLE_17C 0x17C +#define INFTABLE_17F 0x17F +#define INFTABLE_190 0x190 +#define INFTABLE_191 0x191 +#define INFTABLE_192 0x192 +#define INFTABLE_193 0x193 +#define INFTABLE_195 0x195 +#define INFTABLE_196 0x196 +#define INFTABLE_197 0x197 +#define INFTABLE_198 0x198 + +// 0x199-0x19F +#define INFTABLE_199_19A_19B_19C_19D_19E_19F_INDEX 25 +#define INFTABLE_199_MASK (1 << 9) +#define INFTABLE_19A_MASK (1 << 10) +#define INFTABLE_19B_MASK (1 << 11) +#define INFTABLE_19C_MASK (1 << 12) +#define INFTABLE_19D_MASK (1 << 13) +#define INFTABLE_19E_MASK (1 << 14) +#define INFTABLE_19F_MASK (1 << 15) + +// 0x1A0-0x1AF +#define INFTABLE_1AX_INDEX 26 +#define INFTABLE_1A0_SHIFT 0 +#define INFTABLE_1A1_SHIFT 1 +#define INFTABLE_1A2_SHIFT 2 +#define INFTABLE_1A3_SHIFT 3 +#define INFTABLE_1A4_SHIFT 4 +#define INFTABLE_1A5_SHIFT 5 +#define INFTABLE_1A6_SHIFT 6 +#define INFTABLE_1A7_SHIFT 7 +#define INFTABLE_1A8_SHIFT 8 +#define INFTABLE_1A9_SHIFT 9 +#define INFTABLE_1AB_SHIFT 11 +#define INFTABLE_1AD_SHIFT 13 + +// 0x1D0-0x1DF +#define INFTABLE_1DX_INDEX 29 + + +/* + * SaveContext.eventInf + */ + +// 0x00-0x0F +// horses related +#define EVENTINF_HORSES_INDEX 0 +#define EVENTINF_HORSES_STATE_SHIFT 0 +#define EVENTINF_HORSES_HORSETYPE_SHIFT 4 +#define EVENTINF_HORSES_05_SHIFT 5 +#define EVENTINF_HORSES_06_SHIFT 6 +#define EVENTINF_HORSES_08_SHIFT 8 +#define EVENTINF_HORSES_0A_SHIFT 10 +#define EVENTINF_HORSES_0F_SHIFT 15 // unused? +#define EVENTINF_HORSES_STATE_MASK (0xF << EVENTINF_HORSES_STATE_SHIFT) +#define EVENTINF_HORSES_HORSETYPE_MASK (1 << EVENTINF_HORSES_HORSETYPE_SHIFT) +#define EVENTINF_HORSES_05_MASK (1 << EVENTINF_HORSES_05_SHIFT) +#define EVENTINF_HORSES_06_MASK (1 << EVENTINF_HORSES_06_SHIFT) +#define EVENTINF_HORSES_0F_MASK (1 << EVENTINF_HORSES_0F_SHIFT) +#define EVENTINF_HORSES_05 ((EVENTINF_HORSES_INDEX << 4) | EVENTINF_HORSES_05_SHIFT) +#define EVENTINF_HORSES_06 ((EVENTINF_HORSES_INDEX << 4) | EVENTINF_HORSES_06_SHIFT) +// Used in z_en_ta (Talon) to store Cucco game winning status +// and in z_en_ge1 (Gerudo) to store archery in-progress status +#define EVENTINF_HORSES_08 ((EVENTINF_HORSES_INDEX << 4) | EVENTINF_HORSES_08_SHIFT) +#define EVENTINF_CUCCO_GAME_WON EVENTINF_HORSES_08 +// Used in z_en_ta (Talon) and z_en_ma3 (Malon) to store minigame finishing status +#define EVENTINF_HORSES_0A ((EVENTINF_HORSES_INDEX << 4) | EVENTINF_HORSES_0A_SHIFT) +#define EVENTINF_CUCCO_GAME_FINISHED EVENTINF_HORSES_0A + +typedef enum { + /* 0 */ EVENTINF_HORSES_STATE_0, + /* 1 */ EVENTINF_HORSES_STATE_1, + /* 2 */ EVENTINF_HORSES_STATE_2, + /* 3 */ EVENTINF_HORSES_STATE_3, + /* 4 */ EVENTINF_HORSES_STATE_4, + /* 5 */ EVENTINF_HORSES_STATE_5, + /* 6 */ EVENTINF_HORSES_STATE_6, + /* 7 */ EVENTINF_HORSES_STATE_7 +} EventInfHorsesState; + +// "InRaceSeq" +#define GET_EVENTINF_HORSES_STATE() \ + ((gSaveContext.eventInf[EVENTINF_HORSES_INDEX] & EVENTINF_HORSES_STATE_MASK) >> EVENTINF_HORSES_STATE_SHIFT) +#define SET_EVENTINF_HORSES_STATE(v) \ + gSaveContext.eventInf[EVENTINF_HORSES_INDEX] = \ + (gSaveContext.eventInf[EVENTINF_HORSES_INDEX] & ~EVENTINF_HORSES_STATE_MASK) | \ + ((v) << EVENTINF_HORSES_STATE_SHIFT) + +#define GET_EVENTINF_HORSES_HORSETYPE() \ + ((gSaveContext.eventInf[EVENTINF_HORSES_INDEX] & EVENTINF_HORSES_HORSETYPE_MASK) >> EVENTINF_HORSES_HORSETYPE_SHIFT) +#define SET_EVENTINF_HORSES_HORSETYPE(v) \ + gSaveContext.eventInf[EVENTINF_HORSES_INDEX] = \ + (gSaveContext.eventInf[EVENTINF_HORSES_INDEX] & ~EVENTINF_HORSES_HORSETYPE_MASK) | \ + ((v) << EVENTINF_HORSES_HORSETYPE_SHIFT) + +#define SET_EVENTINF_HORSES_0F(v) \ + gSaveContext.eventInf[EVENTINF_HORSES_INDEX] = \ + (gSaveContext.eventInf[EVENTINF_HORSES_INDEX] & ~EVENTINF_HORSES_0F_MASK) | ((v) << EVENTINF_HORSES_0F_SHIFT) + + +#define EVENTINF_10 0x10 + +// 0x20-0x24 +#define EVENTINF_20_21_22_23_24_INDEX 2 +#define EVENTINF_20_MASK (1 << 0) +#define EVENTINF_21_MASK (1 << 1) +#define EVENTINF_22_MASK (1 << 2) +#define EVENTINF_23_MASK (1 << 3) +#define EVENTINF_24_MASK (1 << 4) + +#define EVENTINF_30 0x30 + + + #endif diff --git a/soh/soh/Enhancements/crowd-control/CrowdControl.cpp b/soh/soh/Enhancements/crowd-control/CrowdControl.cpp index f00b25b1d..7356390d9 100644 --- a/soh/soh/Enhancements/crowd-control/CrowdControl.cpp +++ b/soh/soh/Enhancements/crowd-control/CrowdControl.cpp @@ -347,18 +347,18 @@ CrowdControl::EffectResult CrowdControl::ExecuteEffect(std::string effectId, uin if (dryRun == 0) CMD_EXECUTE(EFFECT_REMOVE_HEART_CONTAINER); return EffectResult::Success; } else if (effectId == EFFECT_FILL_MAGIC) { - if (!gSaveContext.magicAcquired) { + if (!gSaveContext.isMagicAcquired) { return EffectResult::Failure; } - if (gSaveContext.magic >= (gSaveContext.doubleMagic + 1) + 0x30) { + if (gSaveContext.magic >= (gSaveContext.isDoubleMagicAcquired + 1) + 0x30) { return EffectResult::Failure; } if (dryRun == 0) CMD_EXECUTE(EFFECT_FILL_MAGIC); return EffectResult::Success; } else if (effectId == EFFECT_EMPTY_MAGIC) { - if (!gSaveContext.magicAcquired || gSaveContext.magic <= 0) { + if (!gSaveContext.isMagicAcquired || gSaveContext.magic <= 0) { return EffectResult::Failure; } diff --git a/soh/soh/Enhancements/debugconsole.cpp b/soh/soh/Enhancements/debugconsole.cpp index c31e88d4c..cb642f916 100644 --- a/soh/soh/Enhancements/debugconsole.cpp +++ b/soh/soh/Enhancements/debugconsole.cpp @@ -355,7 +355,7 @@ static bool EntranceHandler(std::shared_ptr Console, const std::v gPlayState->nextEntranceIndex = entrance; gPlayState->sceneLoadFlag = 0x14; gPlayState->fadeTransition = 11; - gSaveContext.nextTransition = 11; + gSaveContext.nextTransitionType = 11; } static bool VoidHandler(std::shared_ptr Console, const std::vector& args) { @@ -366,7 +366,7 @@ static bool VoidHandler(std::shared_ptr Console, const std::vecto gPlayState->sceneLoadFlag = 0x14; gPlayState->nextEntranceIndex = gSaveContext.respawn[RESPAWN_MODE_DOWN].entranceIndex; gPlayState->fadeTransition = 2; - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; } else { SohImGui::GetConsole()->SendErrorMessage("gPlayState == nullptr"); return CMD_FAILED; @@ -379,7 +379,7 @@ static bool ReloadHandler(std::shared_ptr Console, const std::vec gPlayState->nextEntranceIndex = gSaveContext.entranceIndex; gPlayState->sceneLoadFlag = 0x14; gPlayState->fadeTransition = 11; - gSaveContext.nextTransition = 11; + gSaveContext.nextTransitionType = 11; } else { SohImGui::GetConsole()->SendErrorMessage("gPlayState == nullptr"); return CMD_FAILED; diff --git a/soh/soh/Enhancements/debugger/debugSaveEditor.cpp b/soh/soh/Enhancements/debugger/debugSaveEditor.cpp index dbdcd6059..94b696321 100644 --- a/soh/soh/Enhancements/debugger/debugSaveEditor.cpp +++ b/soh/soh/Enhancements/debugger/debugSaveEditor.cpp @@ -341,11 +341,11 @@ void DrawInfoTab() { ImGui::SliderScalar("Health", ImGuiDataType_S16, &gSaveContext.health, &healthMin, &healthMax); UIWidgets::InsertHelpHoverText("Current health. 16 units per full heart"); - bool doubleDefense = gSaveContext.doubleDefense != 0; - if (ImGui::Checkbox("Double Defense", &doubleDefense)) { - gSaveContext.doubleDefense = doubleDefense; + bool isDoubleDefenseAcquired = gSaveContext.isDoubleDefenseAcquired != 0; + if (ImGui::Checkbox("Double Defense", &isDoubleDefenseAcquired)) { + gSaveContext.isDoubleDefenseAcquired = isDoubleDefenseAcquired; gSaveContext.inventory.defenseHearts = - gSaveContext.doubleDefense ? 20 : 0; // Set to get the border drawn in the UI + gSaveContext.isDoubleDefenseAcquired ? 20 : 0; // Set to get the border drawn in the UI } UIWidgets::InsertHelpHoverText("Is double defense unlocked?"); @@ -361,30 +361,30 @@ void DrawInfoTab() { if (ImGui::BeginCombo("Magic Level", magicName.c_str())) { if (ImGui::Selectable("Double")) { gSaveContext.magicLevel = 2; - gSaveContext.magicAcquired = true; - gSaveContext.doubleMagic = true; + gSaveContext.isMagicAcquired = true; + gSaveContext.isDoubleMagicAcquired = true; } if (ImGui::Selectable("Single")) { gSaveContext.magicLevel = 1; - gSaveContext.magicAcquired = true; - gSaveContext.doubleMagic = false; + gSaveContext.isMagicAcquired = true; + gSaveContext.isDoubleMagicAcquired = false; } if (ImGui::Selectable("None")) { gSaveContext.magicLevel = 0; - gSaveContext.magicAcquired = false; - gSaveContext.doubleMagic = false; + gSaveContext.isMagicAcquired = false; + gSaveContext.isDoubleMagicAcquired = false; } ImGui::EndCombo(); } UIWidgets::InsertHelpHoverText("Current magic level"); - gSaveContext.unk_13F4 = gSaveContext.magicLevel * 0x30; // Set to get the bar drawn in the UI - if (gSaveContext.magic > gSaveContext.unk_13F4) { - gSaveContext.magic = gSaveContext.unk_13F4; // Clamp magic to new max + gSaveContext.magicCapacity = gSaveContext.magicLevel * 0x30; // Set to get the bar drawn in the UI + if (gSaveContext.magic > gSaveContext.magicCapacity) { + gSaveContext.magic = gSaveContext.magicCapacity; // Clamp magic to new max } const uint8_t magicMin = 0; - const uint8_t magicMax = gSaveContext.unk_13F4; + const uint8_t magicMax = gSaveContext.magicCapacity; ImGui::SetNextItemWidth(ImGui::GetFontSize() * 15); ImGui::SliderScalar("Magic", ImGuiDataType_S8, &gSaveContext.magic, &magicMin, &magicMax); UIWidgets::InsertHelpHoverText("Current magic. 48 units per magic level"); @@ -1392,7 +1392,7 @@ void DrawPlayerTab() { const char* curTunic; const char* curBoots; - switch (player->currentSwordItem) { + switch (player->currentSwordItemId) { case ITEM_SWORD_KOKIRI: curSword = "Kokiri Sword"; break; @@ -1521,17 +1521,17 @@ void DrawPlayerTab() { ImGui::PushItemWidth(ImGui::GetFontSize() * 15); if (ImGui::BeginCombo("Sword", curSword)) { if (ImGui::Selectable("None")) { - player->currentSwordItem = ITEM_NONE; + player->currentSwordItemId = ITEM_NONE; gSaveContext.equips.buttonItems[0] = ITEM_NONE; Inventory_ChangeEquipment(EQUIP_SWORD, PLAYER_SWORD_NONE); } if (ImGui::Selectable("Kokiri Sword")) { - player->currentSwordItem = ITEM_SWORD_KOKIRI; + player->currentSwordItemId = ITEM_SWORD_KOKIRI; gSaveContext.equips.buttonItems[0] = ITEM_SWORD_KOKIRI; Inventory_ChangeEquipment(EQUIP_SWORD, PLAYER_SWORD_KOKIRI); } if (ImGui::Selectable("Master Sword")) { - player->currentSwordItem = ITEM_SWORD_MASTER; + player->currentSwordItemId = ITEM_SWORD_MASTER; gSaveContext.equips.buttonItems[0] = ITEM_SWORD_MASTER; Inventory_ChangeEquipment(EQUIP_SWORD, PLAYER_SWORD_MASTER); } @@ -1540,20 +1540,20 @@ void DrawPlayerTab() { if (gSaveContext.swordHealth < 8) { gSaveContext.swordHealth = 8; } - player->currentSwordItem = ITEM_SWORD_BGS; + player->currentSwordItemId = ITEM_SWORD_BGS; gSaveContext.equips.buttonItems[0] = ITEM_SWORD_BGS; } else { if (gSaveContext.swordHealth < 8) { gSaveContext.swordHealth = 8; } - player->currentSwordItem = ITEM_SWORD_BGS; + player->currentSwordItemId = ITEM_SWORD_BGS; gSaveContext.equips.buttonItems[0] = ITEM_SWORD_KNIFE; } Inventory_ChangeEquipment(EQUIP_SWORD, PLAYER_SWORD_BGS); } if (ImGui::Selectable("Fishing Pole")) { - player->currentSwordItem = ITEM_FISHING_POLE; + player->currentSwordItemId = ITEM_FISHING_POLE; gSaveContext.equips.buttonItems[0] = ITEM_FISHING_POLE; Inventory_ChangeEquipment(EQUIP_SWORD, PLAYER_SWORD_MASTER); } diff --git a/soh/soh/Enhancements/randomizer/randomizer.cpp b/soh/soh/Enhancements/randomizer/randomizer.cpp index a67b65934..72055d921 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer.cpp @@ -1465,7 +1465,7 @@ ItemObtainability Randomizer::GetItemObtainabilityFromRandomizerGet(RandomizerGe case RG_GERUDO_MEMBERSHIP_CARD: return !CHECK_QUEST_ITEM(QUEST_GERUDO_CARD) ? CAN_OBTAIN : CANT_OBTAIN_ALREADY_HAVE; case RG_DOUBLE_DEFENSE: - return !gSaveContext.doubleDefense ? CAN_OBTAIN : CANT_OBTAIN_ALREADY_HAVE; + return !gSaveContext.isDoubleDefenseAcquired ? CAN_OBTAIN : CANT_OBTAIN_ALREADY_HAVE; case RG_GOLD_SKULLTULA_TOKEN: return gSaveContext.inventory.gsTokens < 100 ? CAN_OBTAIN : CANT_OBTAIN_ALREADY_HAVE; case RG_PROGRESSIVE_STRENGTH: diff --git a/soh/soh/Enhancements/randomizer/randomizer_grotto.c b/soh/soh/Enhancements/randomizer/randomizer_grotto.c index f45384211..4326f646b 100644 --- a/soh/soh/Enhancements/randomizer/randomizer_grotto.c +++ b/soh/soh/Enhancements/randomizer/randomizer_grotto.c @@ -163,7 +163,7 @@ s16 Grotto_OverrideSpecialEntrance(s16 nextEntranceIndex) { gSaveContext.respawnFlag = 2; nextEntranceIndex = grotto.entranceIndex; gPlayState->fadeTransition = 3; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; // Otherwise return 0x7FFF and let the game handle it } else { nextEntranceIndex = 0x7FFF; diff --git a/soh/soh/SaveManager.cpp b/soh/soh/SaveManager.cpp index 70a14824d..9d04d3b09 100644 --- a/soh/soh/SaveManager.cpp +++ b/soh/soh/SaveManager.cpp @@ -385,9 +385,9 @@ void SaveManager::InitFileNormal() { gSaveContext.rupees = 0; gSaveContext.swordHealth = 0; gSaveContext.naviTimer = 0; - gSaveContext.magicAcquired = 0; - gSaveContext.doubleMagic = 0; - gSaveContext.doubleDefense = 0; + gSaveContext.isMagicAcquired = 0; + gSaveContext.isDoubleMagicAcquired = 0; + gSaveContext.isDoubleDefenseAcquired = 0; gSaveContext.bgsFlag = 0; gSaveContext.ocarinaGameRoundNum = 0; for (int button = 0; button < ARRAY_COUNT(gSaveContext.childEquips.buttonItems); button++) { @@ -483,15 +483,15 @@ void SaveManager::InitFileNormal() { gSaveContext.infTable[flag] = 0; } gSaveContext.worldMapAreaData = 0; - gSaveContext.scarecrowCustomSongSet = 0; - for (int i = 0; i < ARRAY_COUNT(gSaveContext.scarecrowCustomSong); i++) { - gSaveContext.scarecrowCustomSong[i].noteIdx = 0; - gSaveContext.scarecrowCustomSong[i].unk_01 = 0; - gSaveContext.scarecrowCustomSong[i].unk_02 = 0; - gSaveContext.scarecrowCustomSong[i].volume = 0; - gSaveContext.scarecrowCustomSong[i].vibrato = 0; - gSaveContext.scarecrowCustomSong[i].tone = 0; - gSaveContext.scarecrowCustomSong[i].semitone = 0; + gSaveContext.scarecrowLongSongSet = 0; + for (int i = 0; i < ARRAY_COUNT(gSaveContext.scarecrowLongSong); i++) { + gSaveContext.scarecrowLongSong[i].noteIdx = 0; + gSaveContext.scarecrowLongSong[i].unk_01 = 0; + gSaveContext.scarecrowLongSong[i].unk_02 = 0; + gSaveContext.scarecrowLongSong[i].volume = 0; + gSaveContext.scarecrowLongSong[i].vibrato = 0; + gSaveContext.scarecrowLongSong[i].tone = 0; + gSaveContext.scarecrowLongSong[i].semitone = 0; } gSaveContext.scarecrowSpawnSongSet = 0; for (int i = 0; i < ARRAY_COUNT(gSaveContext.scarecrowSpawnSong); i++) { @@ -534,9 +534,9 @@ void SaveManager::InitFileDebug() { gSaveContext.rupees = 150; gSaveContext.swordHealth = 8; gSaveContext.naviTimer = 0; - gSaveContext.magicAcquired = 1; - gSaveContext.doubleMagic = 0; - gSaveContext.doubleDefense = 0; + gSaveContext.isMagicAcquired = 1; + gSaveContext.isDoubleMagicAcquired = 0; + gSaveContext.isDoubleDefenseAcquired = 0; gSaveContext.bgsFlag = 0; gSaveContext.ocarinaGameRoundNum = 0; for (int button = 0; button < ARRAY_COUNT(gSaveContext.childEquips.buttonItems); button++) { @@ -794,9 +794,9 @@ void SaveManager::LoadBaseVersion1() { SaveManager::Instance->LoadData("rupees", gSaveContext.rupees); SaveManager::Instance->LoadData("swordHealth", gSaveContext.swordHealth); SaveManager::Instance->LoadData("naviTimer", gSaveContext.naviTimer); - SaveManager::Instance->LoadData("magicAcquired", gSaveContext.magicAcquired); - SaveManager::Instance->LoadData("doubleMagic", gSaveContext.doubleMagic); - SaveManager::Instance->LoadData("doubleDefense", gSaveContext.doubleDefense); + SaveManager::Instance->LoadData("isMagicAcquired", gSaveContext.isMagicAcquired); + SaveManager::Instance->LoadData("isDoubleMagicAcquired", gSaveContext.isDoubleMagicAcquired); + SaveManager::Instance->LoadData("isDoubleDefenseAcquired", gSaveContext.isDoubleDefenseAcquired); SaveManager::Instance->LoadData("bgsFlag", gSaveContext.bgsFlag); SaveManager::Instance->LoadData("ocarinaGameRoundNum", gSaveContext.ocarinaGameRoundNum); SaveManager::Instance->LoadStruct("childEquips", []() { @@ -892,9 +892,9 @@ void SaveManager::LoadBaseVersion1() { SaveManager::Instance->LoadData("", gSaveContext.infTable[i]); }); SaveManager::Instance->LoadData("worldMapAreaData", gSaveContext.worldMapAreaData); - SaveManager::Instance->LoadData("scarecrowCustomSongSet", gSaveContext.scarecrowCustomSongSet); - SaveManager::Instance->LoadArray("scarecrowCustomSong", sizeof(gSaveContext.scarecrowCustomSong), [](size_t i) { - SaveManager::Instance->LoadData("", ((u8*)&gSaveContext.scarecrowCustomSong)[i]); + SaveManager::Instance->LoadData("scarecrowLongSongSet", gSaveContext.scarecrowLongSongSet); + SaveManager::Instance->LoadArray("scarecrowLongSong", sizeof(gSaveContext.scarecrowLongSong), [](size_t i) { + SaveManager::Instance->LoadData("", ((u8*)&gSaveContext.scarecrowLongSong)[i]); }); SaveManager::Instance->LoadData("scarecrowSpawnSongSet", gSaveContext.scarecrowSpawnSongSet); SaveManager::Instance->LoadArray("scarecrowSpawnSong", sizeof(gSaveContext.scarecrowSpawnSong), [](size_t i) { @@ -935,9 +935,9 @@ void SaveManager::LoadBaseVersion2() { SaveManager::Instance->LoadData("rupees", gSaveContext.rupees); SaveManager::Instance->LoadData("swordHealth", gSaveContext.swordHealth); SaveManager::Instance->LoadData("naviTimer", gSaveContext.naviTimer); - SaveManager::Instance->LoadData("magicAcquired", gSaveContext.magicAcquired); - SaveManager::Instance->LoadData("doubleMagic", gSaveContext.doubleMagic); - SaveManager::Instance->LoadData("doubleDefense", gSaveContext.doubleDefense); + SaveManager::Instance->LoadData("isMagicAcquired", gSaveContext.isMagicAcquired); + SaveManager::Instance->LoadData("isDoubleMagicAcquired", gSaveContext.isDoubleMagicAcquired); + SaveManager::Instance->LoadData("isDoubleDefenseAcquired", gSaveContext.isDoubleDefenseAcquired); SaveManager::Instance->LoadData("bgsFlag", gSaveContext.bgsFlag); SaveManager::Instance->LoadData("ocarinaGameRoundNum", gSaveContext.ocarinaGameRoundNum); SaveManager::Instance->LoadStruct("childEquips", []() { @@ -1048,16 +1048,16 @@ void SaveManager::LoadBaseVersion2() { SaveManager::Instance->LoadData("", gSaveContext.infTable[i]); }); SaveManager::Instance->LoadData("worldMapAreaData", gSaveContext.worldMapAreaData); - SaveManager::Instance->LoadData("scarecrowCustomSongSet", gSaveContext.scarecrowCustomSongSet); - SaveManager::Instance->LoadArray("scarecrowCustomSong", ARRAY_COUNT(gSaveContext.scarecrowCustomSong), [](size_t i) { + SaveManager::Instance->LoadData("scarecrowLongSongSet", gSaveContext.scarecrowLongSongSet); + SaveManager::Instance->LoadArray("scarecrowLongSong", ARRAY_COUNT(gSaveContext.scarecrowLongSong), [](size_t i) { SaveManager::Instance->LoadStruct("", [&i]() { - SaveManager::Instance->LoadData("noteIdx", gSaveContext.scarecrowCustomSong[i].noteIdx); - SaveManager::Instance->LoadData("unk_01", gSaveContext.scarecrowCustomSong[i].unk_01); - SaveManager::Instance->LoadData("unk_02", gSaveContext.scarecrowCustomSong[i].unk_02); - SaveManager::Instance->LoadData("volume", gSaveContext.scarecrowCustomSong[i].volume); - SaveManager::Instance->LoadData("vibrato", gSaveContext.scarecrowCustomSong[i].vibrato); - SaveManager::Instance->LoadData("tone", gSaveContext.scarecrowCustomSong[i].tone); - SaveManager::Instance->LoadData("semitone", gSaveContext.scarecrowCustomSong[i].semitone); + SaveManager::Instance->LoadData("noteIdx", gSaveContext.scarecrowLongSong[i].noteIdx); + SaveManager::Instance->LoadData("unk_01", gSaveContext.scarecrowLongSong[i].unk_01); + SaveManager::Instance->LoadData("unk_02", gSaveContext.scarecrowLongSong[i].unk_02); + SaveManager::Instance->LoadData("volume", gSaveContext.scarecrowLongSong[i].volume); + SaveManager::Instance->LoadData("vibrato", gSaveContext.scarecrowLongSong[i].vibrato); + SaveManager::Instance->LoadData("tone", gSaveContext.scarecrowLongSong[i].tone); + SaveManager::Instance->LoadData("semitone", gSaveContext.scarecrowLongSong[i].semitone); }); }); SaveManager::Instance->LoadData("scarecrowSpawnSongSet", gSaveContext.scarecrowSpawnSongSet); @@ -1108,9 +1108,9 @@ void SaveManager::SaveBase() { SaveManager::Instance->SaveData("rupees", gSaveContext.rupees); SaveManager::Instance->SaveData("swordHealth", gSaveContext.swordHealth); SaveManager::Instance->SaveData("naviTimer", gSaveContext.naviTimer); - SaveManager::Instance->SaveData("magicAcquired", gSaveContext.magicAcquired); - SaveManager::Instance->SaveData("doubleMagic", gSaveContext.doubleMagic); - SaveManager::Instance->SaveData("doubleDefense", gSaveContext.doubleDefense); + SaveManager::Instance->SaveData("isMagicAcquired", gSaveContext.isMagicAcquired); + SaveManager::Instance->SaveData("isDoubleMagicAcquired", gSaveContext.isDoubleMagicAcquired); + SaveManager::Instance->SaveData("isDoubleDefenseAcquired", gSaveContext.isDoubleDefenseAcquired); SaveManager::Instance->SaveData("bgsFlag", gSaveContext.bgsFlag); SaveManager::Instance->SaveData("ocarinaGameRoundNum", gSaveContext.ocarinaGameRoundNum); SaveManager::Instance->SaveStruct("childEquips", []() { @@ -1217,16 +1217,16 @@ void SaveManager::SaveBase() { SaveManager::Instance->SaveData("", gSaveContext.infTable[i]); }); SaveManager::Instance->SaveData("worldMapAreaData", gSaveContext.worldMapAreaData); - SaveManager::Instance->SaveData("scarecrowCustomSongSet", gSaveContext.scarecrowCustomSongSet); - SaveManager::Instance->SaveArray("scarecrowCustomSong", ARRAY_COUNT(gSaveContext.scarecrowCustomSong), [](size_t i) { + SaveManager::Instance->SaveData("scarecrowLongSongSet", gSaveContext.scarecrowLongSongSet); + SaveManager::Instance->SaveArray("scarecrowLongSong", ARRAY_COUNT(gSaveContext.scarecrowLongSong), [](size_t i) { SaveManager::Instance->SaveStruct("", [&i]() { - SaveManager::Instance->SaveData("noteIdx", gSaveContext.scarecrowCustomSong[i].noteIdx); - SaveManager::Instance->SaveData("unk_01", gSaveContext.scarecrowCustomSong[i].unk_01); - SaveManager::Instance->SaveData("unk_02", gSaveContext.scarecrowCustomSong[i].unk_02); - SaveManager::Instance->SaveData("volume", gSaveContext.scarecrowCustomSong[i].volume); - SaveManager::Instance->SaveData("vibrato", gSaveContext.scarecrowCustomSong[i].vibrato); - SaveManager::Instance->SaveData("tone", gSaveContext.scarecrowCustomSong[i].tone); - SaveManager::Instance->SaveData("semitone", gSaveContext.scarecrowCustomSong[i].semitone); + SaveManager::Instance->SaveData("noteIdx", gSaveContext.scarecrowLongSong[i].noteIdx); + SaveManager::Instance->SaveData("unk_01", gSaveContext.scarecrowLongSong[i].unk_01); + SaveManager::Instance->SaveData("unk_02", gSaveContext.scarecrowLongSong[i].unk_02); + SaveManager::Instance->SaveData("volume", gSaveContext.scarecrowLongSong[i].volume); + SaveManager::Instance->SaveData("vibrato", gSaveContext.scarecrowLongSong[i].vibrato); + SaveManager::Instance->SaveData("tone", gSaveContext.scarecrowLongSong[i].tone); + SaveManager::Instance->SaveData("semitone", gSaveContext.scarecrowLongSong[i].semitone); }); }); SaveManager::Instance->SaveData("scarecrowSpawnSongSet", gSaveContext.scarecrowSpawnSongSet); @@ -1600,9 +1600,9 @@ void CopyV0Save(SaveContext_v0& src, SaveContext& dst) { dst.rupees = src.rupees; dst.swordHealth = src.swordHealth; dst.naviTimer = src.naviTimer; - dst.magicAcquired = src.magicAcquired; - dst.doubleMagic = src.doubleMagic; - dst.doubleDefense = src.doubleDefense; + dst.isMagicAcquired = src.magicAcquired; + dst.isDoubleMagicAcquired = src.doubleMagic; + dst.isDoubleDefenseAcquired = src.doubleDefense; dst.bgsFlag = src.bgsFlag; dst.ocarinaGameRoundNum = src.ocarinaGameRoundNum; for (size_t i = 0; i < ARRAY_COUNT(src.childEquips.buttonItems); i++) { @@ -1680,8 +1680,8 @@ void CopyV0Save(SaveContext_v0& src, SaveContext& dst) { dst.infTable[i] = src.infTable[i]; } dst.worldMapAreaData = src.worldMapAreaData; - dst.scarecrowCustomSongSet = src.scarecrowCustomSongSet; - memcpy(&dst.scarecrowCustomSong[0], &src.scarecrowCustomSong[0], sizeof(src.scarecrowCustomSong)); + dst.scarecrowLongSongSet = src.scarecrowCustomSongSet; + memcpy(&dst.scarecrowLongSong[0], &src.scarecrowCustomSong[0], sizeof(src.scarecrowCustomSong)); dst.scarecrowSpawnSongSet = src.scarecrowSpawnSongSet; memcpy(&dst.scarecrowSpawnSong[0], &src.scarecrowSpawnSong[0], sizeof(src.scarecrowSpawnSong)); dst.horseData.scene = src.horseData.scene; diff --git a/soh/src/code/game.c b/soh/src/code/game.c index 699f1b22d..2b824c1ab 100644 --- a/soh/src/code/game.c +++ b/soh/src/code/game.c @@ -381,8 +381,8 @@ void GameState_Update(GameState* gameState) { // Inf Magic if (CVar_GetS32("gInfiniteMagic", 0) != 0) { - if (gSaveContext.magicAcquired && gSaveContext.magic != (gSaveContext.doubleMagic + 1) * 0x30) { - gSaveContext.magic = (gSaveContext.doubleMagic + 1) * 0x30; + if (gSaveContext.isMagicAcquired && gSaveContext.magic != (gSaveContext.isDoubleMagicAcquired + 1) * 0x30) { + gSaveContext.magic = (gSaveContext.isDoubleMagicAcquired + 1) * 0x30; } } @@ -440,7 +440,7 @@ void GameState_Update(GameState* gameState) { gPlayState->nextEntranceIndex = gSaveContext.entranceIndex; gPlayState->sceneLoadFlag = 0x14; gPlayState->fadeTransition = 11; - gSaveContext.nextTransition = 11; + gSaveContext.nextTransitionType = 11; warped = true; if (gPlayState->linkAgeOnLoad == 1) { gPlayState->linkAgeOnLoad = 0; @@ -451,7 +451,7 @@ void GameState_Update(GameState* gameState) { } if (gPlayState) { - if (warped && gPlayState->sceneLoadFlag != 0x0014 && gSaveContext.nextTransition == 255) { + if (warped && gPlayState->sceneLoadFlag != 0x0014 && gSaveContext.nextTransitionType == 255) { GET_PLAYER(gPlayState)->actor.shape.rot.y = playerYaw; GET_PLAYER(gPlayState)->actor.world.pos = playerPos; warped = false; diff --git a/soh/src/code/z_actor.c b/soh/src/code/z_actor.c index 3d8ef6753..cc475f1c5 100644 --- a/soh/src/code/z_actor.c +++ b/soh/src/code/z_actor.c @@ -1423,7 +1423,7 @@ s32 func_8002DF38(PlayState* play, Actor* actor, u8 csMode) { player->csMode = csMode; player->unk_448 = actor; - player->unk_46A = 0; + player->doorBgCamIndex = 0; return true; } @@ -1432,7 +1432,7 @@ s32 func_8002DF54(PlayState* play, Actor* actor, u8 csMode) { Player* player = GET_PLAYER(play); func_8002DF38(play, actor, csMode); - player->unk_46A = 1; + player->doorBgCamIndex = 1; return true; } @@ -4529,7 +4529,7 @@ void func_800355B8(PlayState* play, Vec3f* pos) { u8 func_800355E4(PlayState* play, Collider* collider) { Player* player = GET_PLAYER(play); - if ((collider->acFlags & AC_TYPE_PLAYER) && (player->swordState != 0) && (player->swordAnimation == 0x16)) { + if ((collider->acFlags & AC_TYPE_PLAYER) && (player->swordState != 0) && (player->meleeWeaponAnimation == 0x16)) { return true; } else { return false; diff --git a/soh/src/code/z_common_data.c b/soh/src/code/z_common_data.c index 53334fb84..aa0e3cca3 100644 --- a/soh/src/code/z_common_data.c +++ b/soh/src/code/z_common_data.c @@ -14,6 +14,6 @@ void SaveContext_Init(void) { gSaveContext.nextDayTime = 0xFFFF; gSaveContext.skyboxTime = 0; gSaveContext.dogIsLost = true; - gSaveContext.nextTransition = 0xFF; + gSaveContext.nextTransitionType = 0xFF; gSaveContext.unk_13EE = 50; } diff --git a/soh/src/code/z_demo.c b/soh/src/code/z_demo.c index 9eeb3bfa8..8aff4abd7 100644 --- a/soh/src/code/z_demo.c +++ b/soh/src/code/z_demo.c @@ -562,7 +562,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB csCtx->state = CS_STATE_UNSKIPPABLE_EXEC; Audio_SetCutsceneFlag(0); - gSaveContext.unk_1410 = 1; + gSaveContext.cutsceneTransitionControl = 1; osSyncPrintf("\n分岐先指定!!=[%d]番", cmd->base); // "Future fork designation=No. [%d]" @@ -635,7 +635,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB play->nextEntranceIndex = 0x02CA; play->sceneLoadFlag = 0x14; play->fadeTransition = 3; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; } break; case 9: @@ -665,7 +665,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB play->nextEntranceIndex = 0x010E; play->sceneLoadFlag = 0x14; play->fadeTransition = 2; - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; break; case 14: play->nextEntranceIndex = 0x0457; @@ -695,7 +695,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB play->nextEntranceIndex = 0x0324; play->sceneLoadFlag = 0x14; play->fadeTransition = 2; - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; break; case 19: play->nextEntranceIndex = 0x013D; @@ -853,7 +853,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB play->nextEntranceIndex = 0x01ED; play->sceneLoadFlag = 0x14; play->fadeTransition = 15; - gSaveContext.nextTransition = 15; + gSaveContext.nextTransitionType = 15; break; case 49: play->nextEntranceIndex = 0x058C; @@ -985,7 +985,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB play->sceneLoadFlag = 0x14; gSaveContext.cutsceneIndex = 0xFFF4; play->fadeTransition = 2; - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; break; case 71: gSaveContext.equips.equipment |= 0x0100; @@ -1003,7 +1003,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB play->sceneLoadFlag = 0x14; gSaveContext.cutsceneIndex = 0xFFF0; play->fadeTransition = 2; - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; break; case 73: play->linkAgeOnLoad = 1; @@ -1017,7 +1017,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB play->sceneLoadFlag = 0x14; gSaveContext.cutsceneIndex = 0xFFF3; play->fadeTransition = 3; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; break; case 75: play->linkAgeOnLoad = 1; @@ -1109,7 +1109,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB play->nextEntranceIndex = 0x0610; play->sceneLoadFlag = 0x14; play->fadeTransition = 3; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; } break; case 97: @@ -1122,27 +1122,27 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB play->nextEntranceIndex = 0x0580; play->sceneLoadFlag = 0x14; play->fadeTransition = 3; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; } break; case 98: play->nextEntranceIndex = 0x0564; play->sceneLoadFlag = 0x14; play->fadeTransition = 3; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; break; case 99: play->nextEntranceIndex = 0x0608; play->sceneLoadFlag = 0x14; play->fadeTransition = 2; - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; break; case 100: play->nextEntranceIndex = 0x00EE; gSaveContext.cutsceneIndex = 0xFFF8; play->sceneLoadFlag = 0x14; play->fadeTransition = 3; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; break; case 101: play->nextEntranceIndex = 0x01F5; @@ -1248,7 +1248,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB play->nextEntranceIndex = 0x0594; play->sceneLoadFlag = 0x14; play->fadeTransition = 2; - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; break; case 116: if (gSaveContext.eventChkInf[12] & 0x100) { @@ -1260,7 +1260,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB play->sceneLoadFlag = 0x14; play->fadeTransition = 3; } - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; break; case 117: gSaveContext.gameMode = 3; @@ -1275,7 +1275,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB gSaveContext.respawn[RESPAWN_MODE_DOWN].entranceIndex = 0x0517; Play_TriggerVoidOut(play); gSaveContext.respawnFlag = -2; - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; break; case 119: gSaveContext.dayTime = 0x8000; @@ -1357,7 +1357,7 @@ void Cutscene_Command_TransitionFX(PlayState* play, CutsceneContext* csCtx, CsCm } break; case 9: - gSaveContext.unk_1410 = 1; + gSaveContext.cutsceneTransitionControl = 1; break; case 10: case 11: @@ -1371,7 +1371,7 @@ void Cutscene_Command_TransitionFX(PlayState* play, CutsceneContext* csCtx, CsCm } break; case 12: - gSaveContext.unk_1410 = 255.0f - (155.0f * temp); + gSaveContext.cutsceneTransitionControl = 255.0f - (155.0f * temp); break; case 13: play->envCtx.screenFillColor[0] = 0; diff --git a/soh/src/code/z_elf_message.c b/soh/src/code/z_elf_message.c index 5bf7e9723..ea1f504a8 100644 --- a/soh/src/code/z_elf_message.c +++ b/soh/src/code/z_elf_message.c @@ -54,7 +54,7 @@ u32 ElfMessage_CheckCondition(ElfMessage* msg) { return ((msg->byte0 & 1) == 1) == (CHECK_QUEST_ITEM(msg->byte3 - ITEM_MEDALLION_FOREST + QUEST_MEDALLION_FOREST) != 0); case (ELF_MSG_CONDITION_MAGIC << 4): - return ((msg->byte0 & 1) == 1) == (((void)0, gSaveContext.magicAcquired) != 0); + return ((msg->byte0 & 1) == 1) == (((void)0, gSaveContext.isMagicAcquired) != 0); } } diff --git a/soh/src/code/z_fbdemo_fade.c b/soh/src/code/z_fbdemo_fade.c index 5cec2c4d9..5ad05316d 100644 --- a/soh/src/code/z_fbdemo_fade.c +++ b/soh/src/code/z_fbdemo_fade.c @@ -51,16 +51,16 @@ void TransitionFade_Update(void* thisx, s32 updateRate) { break; case 1: this->fadeTimer += updateRate; - if (this->fadeTimer >= gSaveContext.fadeDuration) { - this->fadeTimer = gSaveContext.fadeDuration; + if (this->fadeTimer >= gSaveContext.transFadeDuration) { + this->fadeTimer = gSaveContext.transFadeDuration; this->isDone = 1; } - if (!gSaveContext.fadeDuration) { + if (!gSaveContext.transFadeDuration) { // "Divide by 0! Zero is included in ZCommonGet fade_speed" osSyncPrintf(VT_COL(RED, WHITE) "0除算! ZCommonGet fade_speed に0がはいってる" VT_RST); } - alpha = (255.0f * this->fadeTimer) / ((void)0, gSaveContext.fadeDuration); + alpha = (255.0f * this->fadeTimer) / ((void)0, gSaveContext.transFadeDuration); this->fadeColor.a = (this->fadeDirection != 0) ? 255 - alpha : alpha; break; case 2: diff --git a/soh/src/code/z_fbdemo_wipe1.c b/soh/src/code/z_fbdemo_wipe1.c index d4502f8e7..da473d8af 100644 --- a/soh/src/code/z_fbdemo_wipe1.c +++ b/soh/src/code/z_fbdemo_wipe1.c @@ -67,14 +67,14 @@ void TransitionWipe_Update(void* thisx, s32 updateRate) { u8 unk1419; if (this->direction != 0) { - unk1419 = gSaveContext.unk_1419; + unk1419 = gSaveContext.transWipeSpeed; this->texY += (unk1419 * 3) / updateRate; if (this->texY >= 0x264) { this->texY = 0x264; this->isDone = 1; } } else { - unk1419 = gSaveContext.unk_1419; + unk1419 = gSaveContext.transWipeSpeed; this->texY -= (unk1419 * 3) / updateRate; if (this->texY < 0x14E) { this->texY = 0x14D; diff --git a/soh/src/code/z_kaleido_setup.c b/soh/src/code/z_kaleido_setup.c index 83622820c..704640863 100644 --- a/soh/src/code/z_kaleido_setup.c +++ b/soh/src/code/z_kaleido_setup.c @@ -15,7 +15,7 @@ void KaleidoSetup_Update(PlayState* play) { if (pauseCtx->state == 0 && pauseCtx->debugState == 0 && play->gameOverCtx.state == GAMEOVER_INACTIVE && play->sceneLoadFlag == 0 && play->transitionMode == 0 && gSaveContext.cutsceneIndex < 0xFFF0 && gSaveContext.nextCutsceneIndex < 0xFFF0 && !Play_InCsMode(play) && - play->shootingGalleryStatus <= 1 && gSaveContext.unk_13F0 != 8 && gSaveContext.unk_13F0 != 9 && + play->shootingGalleryStatus <= 1 && gSaveContext.magicState != 8 && gSaveContext.magicState != 9 && (play->sceneNum != SCENE_BOWLING || !Flags_GetSwitch(play, 0x38))) { if (CVar_GetS32("gCheatEasyPauseBufferFrameAdvance", 0) == 2 && !CHECK_BTN_ALL(input->press.button, BTN_START)) { diff --git a/soh/src/code/z_kankyo.c b/soh/src/code/z_kankyo.c index 1718a487d..37e7e2c67 100644 --- a/soh/src/code/z_kankyo.c +++ b/soh/src/code/z_kankyo.c @@ -295,7 +295,7 @@ void Environment_Init(PlayState* play2, EnvironmentContext* envCtx, s32 unused) sLightningFlashAlpha = 0; - gSaveContext.unk_1410 = 0; + gSaveContext.cutsceneTransitionControl = 0; envCtx->adjAmbientColor[0] = envCtx->adjAmbientColor[1] = envCtx->adjAmbientColor[2] = envCtx->adjLight1Color[0] = envCtx->adjLight1Color[1] = envCtx->adjLight1Color[2] = envCtx->adjFogColor[0] = envCtx->adjFogColor[1] = @@ -326,7 +326,7 @@ void Environment_Init(PlayState* play2, EnvironmentContext* envCtx, s32 unused) play->envCtx.unk_F2[0] = 0; - if (gSaveContext.unk_13C3 != 0) { + if (gSaveContext.retainWeatherMode != 0) { if (((void)0, gSaveContext.sceneSetupIndex) < 4) { switch (gWeatherMode) { case 1: @@ -378,7 +378,7 @@ void Environment_Init(PlayState* play2, EnvironmentContext* envCtx, s32 unused) D_8011FB38 = 0; D_8011FB34 = 0; gSkyboxBlendingEnabled = false; - gSaveContext.unk_13C3 = 0; + gSaveContext.retainWeatherMode = 0; R_ENV_LIGHT1_DIR(0) = 80; R_ENV_LIGHT1_DIR(1) = 80; R_ENV_LIGHT1_DIR(2) = 80; @@ -2531,7 +2531,7 @@ void Environment_WarpSongLeave(PlayState* play) { play->nextEntranceIndex = gSaveContext.respawn[RESPAWN_MODE_RETURN].entranceIndex; play->sceneLoadFlag = 0x14; play->fadeTransition = 3; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; switch (play->nextEntranceIndex) { case 0x147: diff --git a/soh/src/code/z_message_PAL.c b/soh/src/code/z_message_PAL.c index 54854c387..14acf64a1 100644 --- a/soh/src/code/z_message_PAL.c +++ b/soh/src/code/z_message_PAL.c @@ -2917,7 +2917,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) { // "Recording complete!!!!!!!!!" osSyncPrintf("録音終了!!!!!!!!! message->info->status=%d \n", msgCtx->ocarinaStaff->state); - gSaveContext.scarecrowCustomSongSet = true; + gSaveContext.scarecrowLongSongSet = true; } Audio_PlaySoundGeneral(NA_SE_SY_OCARINA_ERROR, &D_801333D4, 4, &D_801333E0, &D_801333E0, &D_801333E8); @@ -2930,10 +2930,10 @@ void Message_DrawMain(PlayState* play, Gfx** p) { osSyncPrintf("録音終了!!!!!!!!!録音終了\n"); osSyncPrintf(VT_FGCOL(YELLOW)); osSyncPrintf("\n====================================================================\n"); - memcpy(gSaveContext.scarecrowCustomSong, gScarecrowCustomSongPtr, - sizeof(gSaveContext.scarecrowCustomSong)); - for (i = 0; i < ARRAY_COUNT(gSaveContext.scarecrowCustomSong); i++) { - osSyncPrintf("%d, ", gSaveContext.scarecrowCustomSong[i]); + memcpy(gSaveContext.scarecrowLongSong, gScarecrowCustomSongPtr, + sizeof(gSaveContext.scarecrowLongSong)); + for (i = 0; i < ARRAY_COUNT(gSaveContext.scarecrowLongSong); i++) { + osSyncPrintf("%d, ", gSaveContext.scarecrowLongSong[i]); } osSyncPrintf(VT_RST); osSyncPrintf("\n====================================================================\n"); @@ -3310,7 +3310,7 @@ void Message_Draw(PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - watchVar = gSaveContext.scarecrowCustomSongSet; + watchVar = gSaveContext.scarecrowLongSongSet; Message_DrawDebugVariableChanged(&watchVar, play->state.gfxCtx); if (BREG(0) != 0 && play->msgCtx.textId != 0) { plusOne = Graph_GfxPlusOne(polyOpaP = POLY_OPA_DISP); diff --git a/soh/src/code/z_parameter.c b/soh/src/code/z_parameter.c index f7af5b728..c23e2565f 100644 --- a/soh/src/code/z_parameter.c +++ b/soh/src/code/z_parameter.c @@ -987,7 +987,7 @@ void func_80083108(PlayState* play) { } Interface_ChangeAlpha(50); - } else if ((player->stateFlags1 & 0x00200000) || (player->stateFlags2 & 0x00040000)) { + } else if ((player->stateFlags1 & 0x00200000) || (player->stateFlags2 & PLAYER_STATE2_CRAWLING)) { if (gSaveContext.buttonStatus[0] != BTN_DISABLED) { gSaveContext.buttonStatus[0] = BTN_DISABLED; gSaveContext.buttonStatus[1] = BTN_DISABLED; @@ -2222,7 +2222,7 @@ u8 Item_Give(PlayState* play, u8 item) { PerformAutosave(play, item); return item; } else if (item == ITEM_MAGIC_SMALL) { - if (gSaveContext.unk_13F0 != 10) { + if (gSaveContext.magicState != 10) { if (play != NULL) { Magic_Fill(play); } @@ -2241,7 +2241,7 @@ u8 Item_Give(PlayState* play, u8 item) { PerformAutosave(play, item); return item; } else if (item == ITEM_MAGIC_LARGE) { - if (gSaveContext.unk_13F0 != 10) { + if (gSaveContext.magicState != 10) { if (play != NULL) { Magic_Fill(play); } @@ -2365,16 +2365,16 @@ u16 Randomizer_Item_Give(PlayState* play, GetItemEntry giEntry) { slot = SLOT(item); if (item == RG_MAGIC_SINGLE) { - gSaveContext.magicAcquired = true; - gSaveContext.unk_13F6 = 0x30; + gSaveContext.isMagicAcquired = true; + gSaveContext.magicFillTarget = 0x30; Magic_Fill(play); return RG_NONE; } else if (item == RG_MAGIC_DOUBLE) { - if (!gSaveContext.magicAcquired) { - gSaveContext.magicAcquired = true; + if (!gSaveContext.isMagicAcquired) { + gSaveContext.isMagicAcquired = true; } - gSaveContext.doubleMagic = true; - gSaveContext.unk_13F6 = 0x60; + gSaveContext.isDoubleMagicAcquired = true; + gSaveContext.magicFillTarget = 0x60; gSaveContext.magicLevel = 0; Magic_Fill(play); return RG_NONE; @@ -2389,7 +2389,7 @@ u16 Randomizer_Item_Give(PlayState* play, GetItemEntry giEntry) { } if (item == RG_DOUBLE_DEFENSE) { - gSaveContext.doubleDefense = true; + gSaveContext.isDoubleDefenseAcquired = true; gSaveContext.inventory.defenseHearts = 20; gSaveContext.healthAccumulator = 0x140; return RG_NONE; @@ -3063,7 +3063,7 @@ s32 Health_ChangeBy(PlayState* play, s16 healthChange) { // clang-format off if (healthChange > 0) { Audio_PlaySoundGeneral(NA_SE_SY_HP_RECOVER, &D_801333D4, 4, &D_801333E0, &D_801333E0, &D_801333E8); - } else if ((gSaveContext.doubleDefense != 0) && (healthChange < 0)) { + } else if ((gSaveContext.isDoubleDefenseAcquired != 0) && (healthChange < 0)) { healthChange >>= 1; osSyncPrintf("ハート減少半分!!=%d\n", healthChange); // "Heart decrease halved!!=%d" } @@ -3220,29 +3220,29 @@ void Inventory_ChangeAmmo(s16 item, s16 ammoChange) { } void Magic_Fill(PlayState* play) { - if (gSaveContext.magicAcquired) { - gSaveContext.unk_13F2 = gSaveContext.unk_13F0; - gSaveContext.unk_13F6 = (gSaveContext.doubleMagic + 1) * 0x30; - gSaveContext.unk_13F0 = 9; + if (gSaveContext.isMagicAcquired) { + gSaveContext.prevMagicState = gSaveContext.magicState; + gSaveContext.magicFillTarget = (gSaveContext.isDoubleMagicAcquired + 1) * 0x30; + gSaveContext.magicState = 9; } } void func_800876C8(PlayState* play) { - if ((gSaveContext.unk_13F0 != 8) && (gSaveContext.unk_13F0 != 9)) { - if (gSaveContext.unk_13F0 == 10) { - gSaveContext.unk_13F2 = gSaveContext.unk_13F0; + if ((gSaveContext.magicState != 8) && (gSaveContext.magicState != 9)) { + if (gSaveContext.magicState == 10) { + gSaveContext.prevMagicState = gSaveContext.magicState; } - gSaveContext.unk_13F0 = 5; + gSaveContext.magicState = 5; } } s32 func_80087708(PlayState* play, s16 arg1, s16 arg2) { - if (!gSaveContext.magicAcquired) { + if (!gSaveContext.isMagicAcquired) { return 0; } if ((arg2 != 5) && (gSaveContext.magic - arg1) < 0) { - if (gSaveContext.unk_13F4 != 0) { + if (gSaveContext.magicCapacity != 0) { Audio_PlaySoundGeneral(NA_SE_SY_ERROR, &D_801333D4, 4, &D_801333E0, &D_801333E0, &D_801333E8); } return 0; @@ -3251,66 +3251,66 @@ s32 func_80087708(PlayState* play, s16 arg1, s16 arg2) { switch (arg2) { case 0: case 2: - if ((gSaveContext.unk_13F0 == 0) || (gSaveContext.unk_13F0 == 7)) { - if (gSaveContext.unk_13F0 == 7) { + if ((gSaveContext.magicState == 0) || (gSaveContext.magicState == 7)) { + if (gSaveContext.magicState == 7) { play->actorCtx.lensActive = false; } - gSaveContext.unk_13F8 = gSaveContext.magic - arg1; - gSaveContext.unk_13F0 = 1; + gSaveContext.magicTarget = gSaveContext.magic - arg1; + gSaveContext.magicState = 1; return 1; } else { Audio_PlaySoundGeneral(NA_SE_SY_ERROR, &D_801333D4, 4, &D_801333E0, &D_801333E0, &D_801333E8); return 0; } case 1: - if ((gSaveContext.unk_13F0 == 0) || (gSaveContext.unk_13F0 == 7)) { - if (gSaveContext.unk_13F0 == 7) { + if ((gSaveContext.magicState == 0) || (gSaveContext.magicState == 7)) { + if (gSaveContext.magicState == 7) { play->actorCtx.lensActive = false; } - gSaveContext.unk_13F8 = gSaveContext.magic - arg1; - gSaveContext.unk_13F0 = 6; + gSaveContext.magicTarget = gSaveContext.magic - arg1; + gSaveContext.magicState = 6; return 1; } else { Audio_PlaySoundGeneral(NA_SE_SY_ERROR, &D_801333D4, 4, &D_801333E0, &D_801333E0, &D_801333E8); return 0; } case 3: - if (gSaveContext.unk_13F0 == 0) { + if (gSaveContext.magicState == 0) { if (gSaveContext.magic != 0) { play->interfaceCtx.unk_230 = 80; - gSaveContext.unk_13F0 = 7; + gSaveContext.magicState = 7; return 1; } else { return 0; } } else { - if (gSaveContext.unk_13F0 == 7) { + if (gSaveContext.magicState == 7) { return 1; } else { return 0; } } case 4: - if ((gSaveContext.unk_13F0 == 0) || (gSaveContext.unk_13F0 == 7)) { - if (gSaveContext.unk_13F0 == 7) { + if ((gSaveContext.magicState == 0) || (gSaveContext.magicState == 7)) { + if (gSaveContext.magicState == 7) { play->actorCtx.lensActive = false; } - gSaveContext.unk_13F8 = gSaveContext.magic - arg1; - gSaveContext.unk_13F0 = 4; + gSaveContext.magicTarget = gSaveContext.magic - arg1; + gSaveContext.magicState = 4; return 1; } else { Audio_PlaySoundGeneral(NA_SE_SY_ERROR, &D_801333D4, 4, &D_801333E0, &D_801333E0, &D_801333E8); return 0; } case 5: - if (gSaveContext.unk_13F4 >= gSaveContext.magic) { - gSaveContext.unk_13F8 = gSaveContext.magic + arg1; + if (gSaveContext.magicCapacity >= gSaveContext.magic) { + gSaveContext.magicTarget = gSaveContext.magic + arg1; - if (gSaveContext.unk_13F8 >= gSaveContext.unk_13F4) { - gSaveContext.unk_13F8 = gSaveContext.unk_13F4; + if (gSaveContext.magicTarget >= gSaveContext.magicCapacity) { + gSaveContext.magicTarget = gSaveContext.magicCapacity; } - gSaveContext.unk_13F0 = 10; + gSaveContext.magicState = 10; return 1; } break; @@ -3359,23 +3359,23 @@ void Interface_UpdateMagicBar(PlayState* play) { s16 borderChangeB; s16 temp; - switch (gSaveContext.unk_13F0) { + switch (gSaveContext.magicState) { case 8: temp = gSaveContext.magicLevel * 0x30; - if (gSaveContext.unk_13F4 != temp) { - if (gSaveContext.unk_13F4 < temp) { - gSaveContext.unk_13F4 += 8; - if (gSaveContext.unk_13F4 > temp) { - gSaveContext.unk_13F4 = temp; + if (gSaveContext.magicCapacity != temp) { + if (gSaveContext.magicCapacity < temp) { + gSaveContext.magicCapacity += 8; + if (gSaveContext.magicCapacity > temp) { + gSaveContext.magicCapacity = temp; } } else { - gSaveContext.unk_13F4 -= 8; - if (gSaveContext.unk_13F4 <= temp) { - gSaveContext.unk_13F4 = temp; + gSaveContext.magicCapacity -= 8; + if (gSaveContext.magicCapacity <= temp) { + gSaveContext.magicCapacity = temp; } } } else { - gSaveContext.unk_13F0 = 9; + gSaveContext.magicState = 9; } break; @@ -3388,31 +3388,31 @@ void Interface_UpdateMagicBar(PlayState* play) { } // "Storage MAGIC_NOW=%d (%d)" - osSyncPrintf("蓄電 MAGIC_NOW=%d (%d)\n", gSaveContext.magic, gSaveContext.unk_13F6); - if (gSaveContext.magic >= gSaveContext.unk_13F6) { - gSaveContext.magic = gSaveContext.unk_13F6; - gSaveContext.unk_13F0 = gSaveContext.unk_13F2; - gSaveContext.unk_13F2 = 0; + osSyncPrintf("蓄電 MAGIC_NOW=%d (%d)\n", gSaveContext.magic, gSaveContext.magicFillTarget); + if (gSaveContext.magic >= gSaveContext.magicFillTarget) { + gSaveContext.magic = gSaveContext.magicFillTarget; + gSaveContext.magicState = gSaveContext.prevMagicState; + gSaveContext.prevMagicState = 0; } break; case 1: sMagicBorderRatio = 2; - gSaveContext.unk_13F0 = 2; + gSaveContext.magicState = 2; break; case 2: gSaveContext.magic -= 2; if (gSaveContext.magic <= 0) { gSaveContext.magic = 0; - gSaveContext.unk_13F0 = 3; + gSaveContext.magicState = 3; if (CVar_GetS32("gHudColors", 1) == 2) { sMagicBorder = CVar_GetRGB("gCCMagicBorderNormPrim", sMagicBorder_ori); } else { sMagicBorder = sMagicBorder_ori; } - } else if (gSaveContext.magic == gSaveContext.unk_13F8) { - gSaveContext.unk_13F0 = 3; + } else if (gSaveContext.magic == gSaveContext.magicTarget) { + gSaveContext.magicState = 3; if (CVar_GetS32("gHudColors", 1) == 2) { sMagicBorder = CVar_GetRGB("gCCMagicBorderNormPrim", sMagicBorder_ori); } else { @@ -3464,7 +3464,7 @@ void Interface_UpdateMagicBar(PlayState* play) { } else { sMagicBorder = sMagicBorder_ori; } - gSaveContext.unk_13F0 = 0; + gSaveContext.magicState = 0; break; case 7: @@ -3484,7 +3484,7 @@ void Interface_UpdateMagicBar(PlayState* play) { play->actorCtx.lensActive = false; Audio_PlaySoundGeneral(NA_SE_SY_GLASSMODE_OFF, &D_801333D4, 4, &D_801333E0, &D_801333E0, &D_801333E8); - gSaveContext.unk_13F0 = 0; + gSaveContext.magicState = 0; if (CVar_GetS32("gHudColors", 1) == 2) { sMagicBorder = CVar_GetRGB("gCCMagicBorderNormPrim", sMagicBorder_ori); } else { @@ -3539,15 +3539,15 @@ void Interface_UpdateMagicBar(PlayState* play) { case 10: gSaveContext.magic += 4; Audio_PlaySoundGeneral(NA_SE_SY_GAUGE_UP - SFX_FLAG, &D_801333D4, 4, &D_801333E0, &D_801333E0, &D_801333E8); - if (gSaveContext.magic >= gSaveContext.unk_13F8) { - gSaveContext.magic = gSaveContext.unk_13F8; - gSaveContext.unk_13F0 = gSaveContext.unk_13F2; - gSaveContext.unk_13F2 = 0; + if (gSaveContext.magic >= gSaveContext.magicTarget) { + gSaveContext.magic = gSaveContext.magicTarget; + gSaveContext.magicState = gSaveContext.prevMagicState; + gSaveContext.prevMagicState = 0; } break; default: - gSaveContext.unk_13F0 = 0; + gSaveContext.magicState = 0; break; } } @@ -3663,13 +3663,13 @@ void Interface_DrawMagicBar(PlayState* play) { OVERLAY_DISP = Gfx_TextureIA8(OVERLAY_DISP, gMagicMeterEndTex, 8, 16, PosX_Start, magicBarY, 8, 16, 1 << 10, 1 << 10); - OVERLAY_DISP = Gfx_TextureIA8(OVERLAY_DISP, gMagicMeterMidTex, 24, 16, PosX_MidEnd, magicBarY, gSaveContext.unk_13F4, 16, 1 << 10, 1 << 10); + OVERLAY_DISP = Gfx_TextureIA8(OVERLAY_DISP, gMagicMeterMidTex, 24, 16, PosX_MidEnd, magicBarY, gSaveContext.magicCapacity, 16, 1 << 10, 1 << 10); gDPLoadTextureBlock(OVERLAY_DISP++, gMagicMeterEndTex, G_IM_FMT_IA, G_IM_SIZ_8b, 8, 16, 0, G_TX_MIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP, 3, G_TX_NOMASK, G_TX_NOLOD, G_TX_NOLOD); - gSPWideTextureRectangle(OVERLAY_DISP++, ((rMagicBarX + gSaveContext.unk_13F4) + 8) << 2, magicBarY << 2, - ((rMagicBarX + gSaveContext.unk_13F4) + 16) << 2, (magicBarY + 16) << 2, G_TX_RENDERTILE, + gSPWideTextureRectangle(OVERLAY_DISP++, ((rMagicBarX + gSaveContext.magicCapacity) + 8) << 2, magicBarY << 2, + ((rMagicBarX + gSaveContext.magicCapacity) + 16) << 2, (magicBarY + 16) << 2, G_TX_RENDERTILE, 256, 0, 1 << 10, 1 << 10); gDPPipeSync(OVERLAY_DISP++); @@ -3677,7 +3677,7 @@ void Interface_DrawMagicBar(PlayState* play) { ENVIRONMENT, TEXEL0, ENVIRONMENT, 0, 0, 0, PRIMITIVE); gDPSetEnvColor(OVERLAY_DISP++, 0, 0, 0, 255); - if (gSaveContext.unk_13F0 == 4) { + if (gSaveContext.magicState == 4) { // Yellow part of the bar indicating the amount of magic to be subtracted if (CVar_GetS32("gHudColors", 1) == 2) { gDPSetPrimColor(OVERLAY_DISP++, 0, 0, CVar_GetRGB("gCCMagicUsePrim", magicbar_yellow).r, CVar_GetRGB("gCCMagicUsePrim", magicbar_yellow).g, CVar_GetRGB("gCCMagicUsePrim", magicbar_yellow).b, interfaceCtx->magicAlpha); @@ -3702,7 +3702,7 @@ void Interface_DrawMagicBar(PlayState* play) { } gSPWideTextureRectangle(OVERLAY_DISP++, rMagicFillX << 2, (magicBarY + 3) << 2, - (rMagicFillX + gSaveContext.unk_13F8) << 2, (magicBarY + 10) << 2, G_TX_RENDERTILE, + (rMagicFillX + gSaveContext.magicTarget) << 2, (magicBarY + 10) << 2, G_TX_RENDERTILE, 0, 0, 1 << 10, 1 << 10); } else { // Fill the whole bar with the normal magic color @@ -4164,7 +4164,7 @@ void Interface_DrawItemButtons(PlayState* play) { if ((gSaveContext.unk_13EA == 1) || (gSaveContext.unk_13EA == 2) || (gSaveContext.unk_13EA == 5)) { temp = 0; } else if ((player->stateFlags1 & 0x00200000) || (func_8008F2F8(play) == 4) || - (player->stateFlags2 & 0x00040000)) { + (player->stateFlags2 & PLAYER_STATE2_CRAWLING)) { temp = 70; } else { temp = interfaceCtx->healthAlpha; @@ -5194,7 +5194,7 @@ void Interface_Draw(PlayState* play) { Interface_DrawLineupTick(play); } - if (fullUi || gSaveContext.unk_13F0 > 0) { + if (fullUi || gSaveContext.magicState > 0) { Interface_DrawMagicBar(play); } @@ -6367,15 +6367,15 @@ void Interface_Update(PlayState* play) { (msgCtx->msgMode == MSGMODE_NONE) && (play->sceneLoadFlag == 0) && (play->gameOverCtx.state == GAMEOVER_INACTIVE) && (play->transitionMode == 0) && ((play->csCtx.state == CS_STATE_IDLE) || !Player_InCsMode(play))) { - if ((gSaveContext.magicAcquired != 0) && (gSaveContext.magicLevel == 0)) { - gSaveContext.magicLevel = gSaveContext.doubleMagic + 1; - gSaveContext.unk_13F0 = 8; + if ((gSaveContext.isMagicAcquired != 0) && (gSaveContext.magicLevel == 0)) { + gSaveContext.magicLevel = gSaveContext.isDoubleMagicAcquired + 1; + gSaveContext.magicState = 8; osSyncPrintf(VT_FGCOL(YELLOW)); osSyncPrintf("魔法スター─────ト!!!!!!!!!\n"); // "Magic Start!!!!!!!!!" osSyncPrintf("MAGIC_MAX=%d\n", gSaveContext.magicLevel); osSyncPrintf("MAGIC_NOW=%d\n", gSaveContext.magic); - osSyncPrintf("Z_MAGIC_NOW_NOW=%d\n", gSaveContext.unk_13F6); - osSyncPrintf("Z_MAGIC_NOW_MAX=%d\n", gSaveContext.unk_13F4); + osSyncPrintf("Z_MAGIC_NOW_NOW=%d\n", gSaveContext.magicFillTarget); + osSyncPrintf("Z_MAGIC_NOW_MAX=%d\n", gSaveContext.magicCapacity); osSyncPrintf(VT_RST); } @@ -6463,18 +6463,18 @@ void Interface_Update(PlayState* play) { if ((gSaveContext.dayTime >= 0x4555) && (gSaveContext.dayTime < 0xC001)) { gSaveContext.nextDayTime = 0; play->fadeTransition = 4; - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; play->unk_11DE9 = 1; } else { gSaveContext.nextDayTime = 0x8001; play->fadeTransition = 5; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; play->unk_11DE9 = 1; } if (play->sceneNum == SCENE_SPOT13) { play->fadeTransition = 14; - gSaveContext.nextTransition = 14; + gSaveContext.nextTransitionType = 14; } gSaveContext.respawnFlag = -2; diff --git a/soh/src/code/z_play.c b/soh/src/code/z_play.c index 830a22098..9d35a528c 100644 --- a/soh/src/code/z_play.c +++ b/soh/src/code/z_play.c @@ -214,7 +214,7 @@ void GivePlayerRandoRewardSongOfTime(PlayState* play, RandomizerCheck check) { Player* player = GET_PLAYER(play); if (gSaveContext.entranceIndex == 0x050F && player != NULL && !Player_InBlockingCsMode(play, player) && - !Flags_GetTreasure(play, 0x1F) && gSaveContext.nextTransition == 0xFF && !gSaveContext.pendingIceTrapCount) { + !Flags_GetTreasure(play, 0x1F) && gSaveContext.nextTransitionType == 0xFF && !gSaveContext.pendingIceTrapCount) { GetItemEntry getItemEntry = Randomizer_GetItemFromKnownCheck(check, RG_SONG_OF_TIME); GiveItemEntryWithoutActor(play, getItemEntry); player->pendingFlag.flagID = 0x1F; @@ -556,7 +556,7 @@ void Play_Init(GameState* thisx) { if (CVar_GetS32("gSceneTransitions", 255)!= 255){ play->transitionMode = CVar_GetS32("gSceneTransitions", 0); - gSaveContext.nextTransition = CVar_GetS32("gSceneTransitions", 0); + gSaveContext.nextTransitionType = CVar_GetS32("gSceneTransitions", 0); play->fadeTransition = CVar_GetS32("gSceneTransitions", 0); } @@ -571,12 +571,12 @@ void Play_Init(GameState* thisx) { play->unk_11DE9 = 0; if (gSaveContext.gameMode != 1) { - if (gSaveContext.nextTransition == 0xFF) { + if (gSaveContext.nextTransitionType == 0xFF) { play->fadeTransition = (gEntranceTable[((void)0, gSaveContext.entranceIndex) + tempSetupIndex].field >> 7) & 0x7F; // Fade In } else { - play->fadeTransition = gSaveContext.nextTransition; - gSaveContext.nextTransition = 0xFF; + play->fadeTransition = gSaveContext.nextTransitionType; + gSaveContext.nextTransitionType = 0xFF; } } else { play->fadeTransition = 6; @@ -777,21 +777,21 @@ void Play_Update(PlayState* play) { play->transitionCtx.transitionType | 0x80); } - gSaveContext.unk_1419 = 14; + gSaveContext.transWipeSpeed = 14; if ((play->transitionCtx.transitionType == 8) || (play->transitionCtx.transitionType == 9)) { - gSaveContext.unk_1419 = 28; + gSaveContext.transWipeSpeed = 28; } - gSaveContext.fadeDuration = 60; + gSaveContext.transFadeDuration = 60; if ((play->transitionCtx.transitionType == 4) || (play->transitionCtx.transitionType == 5)) { - gSaveContext.fadeDuration = 20; + gSaveContext.transFadeDuration = 20; } else if ((play->transitionCtx.transitionType == 6) || (play->transitionCtx.transitionType == 7)) { - gSaveContext.fadeDuration = 150; + gSaveContext.transFadeDuration = 150; } else if (play->transitionCtx.transitionType == 17) { - gSaveContext.fadeDuration = 2; + gSaveContext.transFadeDuration = 2; } if ((play->transitionCtx.transitionType == 3) || @@ -954,7 +954,7 @@ void Play_Update(PlayState* play) { break; case 11: - if (gSaveContext.unk_1410 != 0) { + if (gSaveContext.cutsceneTransitionControl != 0) { play->transitionMode = 3; } break; @@ -1029,9 +1029,9 @@ void Play_Update(PlayState* play) { break; case 17: - if (gSaveContext.unk_1410 != 0) { - play->envCtx.screenFillColor[3] = gSaveContext.unk_1410; - if (gSaveContext.unk_1410 < 0x65) { + if (gSaveContext.cutsceneTransitionControl != 0) { + play->envCtx.screenFillColor[3] = gSaveContext.cutsceneTransitionControl; + if (gSaveContext.cutsceneTransitionControl < 0x65) { gTrnsnUnkState = 0; R_UPDATE_RATE = 3; play->sceneLoadFlag = 0; @@ -2177,11 +2177,11 @@ void Play_PerformSave(PlayState* play) { gSaveContext.savedSceneNum = play->sceneNum; if (gSaveContext.temporaryWeapon) { gSaveContext.equips.buttonItems[0] = ITEM_NONE; - GET_PLAYER(play)->currentSwordItem = ITEM_NONE; + GET_PLAYER(play)->currentSwordItemId = ITEM_NONE; Inventory_ChangeEquipment(EQUIP_SWORD, PLAYER_SWORD_NONE); Save_SaveFile(); gSaveContext.equips.buttonItems[0] = ITEM_SWORD_KOKIRI; - GET_PLAYER(play)->currentSwordItem = ITEM_SWORD_KOKIRI; + GET_PLAYER(play)->currentSwordItemId = ITEM_SWORD_KOKIRI; Inventory_ChangeEquipment(EQUIP_SWORD, PLAYER_SWORD_KOKIRI); } else { Save_SaveFile(); diff --git a/soh/src/code/z_player_lib.c b/soh/src/code/z_player_lib.c index 29cdb05ca..6e9e9df80 100644 --- a/soh/src/code/z_player_lib.c +++ b/soh/src/code/z_player_lib.c @@ -332,7 +332,7 @@ void Player_SetBootData(PlayState* play, Player* this) { s32 Player_InBlockingCsMode(PlayState* play, Player* this) { return (this->stateFlags1 & 0x20000080) || (this->csMode != 0) || (play->sceneLoadFlag == 0x14) || (this->stateFlags1 & 1) || (this->stateFlags3 & 0x80) || - ((gSaveContext.unk_13F0 != 0) && (Player_ActionToMagicSpell(this, this->itemActionParam) >= 0)); + ((gSaveContext.magicState != 0) && (Player_ActionToMagicSpell(this, this->itemAction) >= 0)); } s32 Player_InCsMode(PlayState* play) { @@ -361,8 +361,8 @@ s32 Player_ActionToModelGroup(Player* this, s32 actionParam) { void Player_SetModelsForHoldingShield(Player* this) { if ((this->stateFlags1 & 0x400000) && - ((this->itemActionParam < 0) || (this->itemActionParam == this->heldItemActionParam))) { - if ((CVar_GetS32("gShieldTwoHanded", 0) && (this->heldItemActionParam != PLAYER_AP_STICK) || + ((this->itemAction < 0) || (this->itemAction == this->heldItemAction))) { + if ((CVar_GetS32("gShieldTwoHanded", 0) && (this->heldItemAction != PLAYER_IA_STICK) || !Player_HoldsTwoHandedWeapon(this)) && !Player_IsChildWithHylianShield(this)) { this->rightHandType = 10; this->rightHandDLists = &sPlayerDListGroups[10][gSaveContext.linkAge]; @@ -373,7 +373,7 @@ void Player_SetModelsForHoldingShield(Player* this) { } this->sheathDLists = &sPlayerDListGroups[this->sheathType][gSaveContext.linkAge]; this->modelAnimType = 2; - this->itemActionParam = -1; + this->itemAction = -1; } } } @@ -408,8 +408,8 @@ void Player_SetModelGroup(Player* this, s32 modelGroup) { } void func_8008EC70(Player* this) { - this->itemActionParam = this->heldItemActionParam; - Player_SetModelGroup(this, Player_ActionToModelGroup(this, this->heldItemActionParam)); + this->itemAction = this->heldItemAction; + Player_SetModelGroup(this, Player_ActionToModelGroup(this, this->heldItemAction)); this->unk_6AD = 0; } @@ -418,8 +418,8 @@ void Player_SetEquipmentData(PlayState* play, Player* this) { this->currentShield = CUR_EQUIP_VALUE(EQUIP_SHIELD); this->currentTunic = CUR_EQUIP_VALUE(EQUIP_TUNIC) - 1; this->currentBoots = CUR_EQUIP_VALUE(EQUIP_BOOTS) - 1; - this->currentSwordItem = B_BTN_ITEM; - Player_SetModelGroup(this, Player_ActionToModelGroup(this, this->heldItemActionParam)); + this->currentSwordItemId = B_BTN_ITEM; + Player_SetModelGroup(this, Player_ActionToModelGroup(this, this->heldItemAction)); Player_SetBootData(play, this); } } @@ -429,10 +429,10 @@ void Player_UpdateBottleHeld(PlayState* play, Player* this, s32 item, s32 action if (item != ITEM_BOTTLE) { this->heldItemId = item; - this->heldItemActionParam = actionParam; + this->heldItemAction = actionParam; } - this->itemActionParam = actionParam; + this->itemAction = actionParam; } void func_8008EDF0(Player* this) { @@ -478,8 +478,8 @@ s32 Player_IsBurningStickInRange(PlayState* play, Vec3f* pos, f32 xzRange, f32 y Vec3f diff; s32 pad; - if ((this->heldItemActionParam == PLAYER_AP_STICK) && (this->unk_860 != 0)) { - Math_Vec3f_Diff(&this->swordInfo[0].tip, pos, &diff); + if ((this->heldItemAction == PLAYER_IA_STICK) && (this->unk_860 != 0)) { + Math_Vec3f_Diff(&this->meleeWeaponInfo[0].tip, pos, &diff); return ((SQ(diff.x) + SQ(diff.z)) <= SQ(xzRange)) && (0.0f <= diff.y) && (diff.y <= yRange); } else { return false; @@ -525,7 +525,7 @@ s32 Player_HasMirrorShieldSetToDraw(PlayState* play) { } s32 Player_ActionToMagicSpell(Player* this, s32 actionParam) { - s32 magicSpell = actionParam - PLAYER_AP_MAGIC_SPELL_15; + s32 magicSpell = actionParam - PLAYER_IA_MAGIC_SPELL_15; if ((magicSpell >= 0) && (magicSpell < 6)) { return magicSpell; @@ -535,7 +535,7 @@ s32 Player_ActionToMagicSpell(Player* this, s32 actionParam) { } s32 Player_HoldsHookshot(Player* this) { - return (this->heldItemActionParam == PLAYER_AP_HOOKSHOT) || (this->heldItemActionParam == PLAYER_AP_LONGSHOT); + return (this->heldItemAction == PLAYER_IA_HOOKSHOT) || (this->heldItemAction == PLAYER_IA_LONGSHOT); } s32 func_8008F128(Player* this) { @@ -543,7 +543,7 @@ s32 func_8008F128(Player* this) { } s32 Player_ActionToSword(s32 actionParam) { - s32 sword = actionParam - PLAYER_AP_FISHING_POLE; + s32 sword = actionParam - PLAYER_IA_FISHING_POLE; if ((sword > 0) && (sword < 6)) { return sword; @@ -553,11 +553,11 @@ s32 Player_ActionToSword(s32 actionParam) { } s32 Player_GetSwordHeld(Player* this) { - return Player_ActionToSword(this->heldItemActionParam); + return Player_ActionToSword(this->heldItemAction); } s32 Player_HoldsTwoHandedWeapon(Player* this) { - if ((this->heldItemActionParam >= PLAYER_AP_SWORD_BGS) && (this->heldItemActionParam <= PLAYER_AP_HAMMER)) { + if ((this->heldItemAction >= PLAYER_IA_SWORD_BGS) && (this->heldItemAction <= PLAYER_IA_HAMMER)) { return 1; } else { return 0; @@ -565,11 +565,11 @@ s32 Player_HoldsTwoHandedWeapon(Player* this) { } s32 Player_HoldsBrokenKnife(Player* this) { - return (this->heldItemActionParam == PLAYER_AP_SWORD_BGS) && (gSaveContext.swordHealth <= 0.0f); + return (this->heldItemAction == PLAYER_IA_SWORD_BGS) && (gSaveContext.swordHealth <= 0.0f); } s32 Player_ActionToBottle(Player* this, s32 actionParam) { - s32 bottle = actionParam - PLAYER_AP_BOTTLE; + s32 bottle = actionParam - PLAYER_IA_BOTTLE; if ((bottle >= 0) && (bottle < 13)) { return bottle; @@ -579,11 +579,11 @@ s32 Player_ActionToBottle(Player* this, s32 actionParam) { } s32 Player_GetBottleHeld(Player* this) { - return Player_ActionToBottle(this, this->heldItemActionParam); + return Player_ActionToBottle(this, this->heldItemAction); } s32 Player_ActionToExplosive(Player* this, s32 actionParam) { - s32 explosive = actionParam - PLAYER_AP_BOMB; + s32 explosive = actionParam - PLAYER_IA_BOMB; if ((explosive >= 0) && (explosive < 2)) { return explosive; @@ -593,14 +593,14 @@ s32 Player_ActionToExplosive(Player* this, s32 actionParam) { } s32 Player_GetExplosiveHeld(Player* this) { - return Player_ActionToExplosive(this, this->heldItemActionParam); + return Player_ActionToExplosive(this, this->heldItemAction); } s32 func_8008F2BC(Player* this, s32 actionParam) { s32 sword = 0; - if (actionParam != PLAYER_AP_LAST_USED) { - sword = actionParam - PLAYER_AP_SWORD_MASTER; + if (actionParam != PLAYER_IA_LAST_USED) { + sword = actionParam - PLAYER_IA_SWORD_MASTER; if ((sword < 0) || (sword >= 3)) { goto return_neg; } @@ -857,7 +857,7 @@ void func_8008F87C(PlayState* play, Player* this, SkelAnime* skelAnime, Vec3f* p s32 temp3; if ((this->actor.scale.y >= 0.0f) && !(this->stateFlags1 & 0x80) && - (Player_ActionToMagicSpell(this, this->itemActionParam) < 0)) { + (Player_ActionToMagicSpell(this, this->itemAction) < 0)) { s32 pad; sp7C = D_80126058[gSaveContext.linkAge]; @@ -931,7 +931,7 @@ s32 func_8008FCC8(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s if (limbIndex == PLAYER_LIMB_ROOT) { D_80160014 = this->leftHandType; D_80160018 = this->rightHandType; - D_80160000 = &this->swordInfo[2].base; + D_80160000 = &this->meleeWeaponInfo[2].base; if (!LINK_IS_ADULT) { if (!(this->skelAnime.moveFlags & 4) || (this->skelAnime.moveFlags & 1)) { @@ -1157,15 +1157,15 @@ void func_800906D4(PlayState* play, Player* this, Vec3f* newTipPos) { Matrix_MultVec3f(&D_801260A4[1], &newBasePos[1]); Matrix_MultVec3f(&D_801260A4[2], &newBasePos[2]); - if (func_80090480(play, NULL, &this->swordInfo[0], &newTipPos[0], &newBasePos[0]) && + if (func_80090480(play, NULL, &this->meleeWeaponInfo[0], &newTipPos[0], &newBasePos[0]) && !(this->stateFlags1 & 0x400000)) { - EffectBlure_AddVertex(Effect_GetByIndex(this->swordEffectIndex), &this->swordInfo[0].tip, - &this->swordInfo[0].base); + EffectBlure_AddVertex(Effect_GetByIndex(this->meleeWeaponEffectIndex), &this->meleeWeaponInfo[0].tip, + &this->meleeWeaponInfo[0].base); } - if ((this->swordState > 0) && ((this->swordAnimation < 0x18) || (this->stateFlags2 & 0x20000))) { - func_80090480(play, &this->swordQuads[0], &this->swordInfo[1], &newTipPos[1], &newBasePos[1]); - func_80090480(play, &this->swordQuads[1], &this->swordInfo[2], &newTipPos[2], &newBasePos[2]); + if ((this->swordState > 0) && ((this->meleeWeaponAnimation < 0x18) || (this->stateFlags2 & 0x20000))) { + func_80090480(play, &this->meleeWeaponQuads[0], &this->meleeWeaponInfo[1], &newTipPos[1], &newBasePos[1]); + func_80090480(play, &this->meleeWeaponQuads[1], &this->meleeWeaponInfo[2], &newTipPos[2], &newBasePos[2]); } } @@ -1321,7 +1321,7 @@ void func_80090D20(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void Math_Vec3f_Copy(&this->leftHandPos, D_80160000); - if (this->itemActionParam == PLAYER_AP_STICK) { + if (this->itemAction == PLAYER_IA_STICK) { Vec3f sp124[3]; OPEN_DISPS(play->state.gfxCtx); @@ -1330,10 +1330,10 @@ void func_80090D20(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void D_80126080.x = this->unk_85C * 5000.0f; func_80090A28(this, sp124); if (this->swordState != 0) { - EffectBlure_ChangeType(Effect_GetByIndex(this->swordEffectIndex), 7); // default sword type + EffectBlure_ChangeType(Effect_GetByIndex(this->meleeWeaponEffectIndex), 7); // default sword type func_800906D4(play, this, sp124); } else { - Math_Vec3f_Copy(&this->swordInfo[0].tip, &sp124[0]); + Math_Vec3f_Copy(&this->meleeWeaponInfo[0].tip, &sp124[0]); } } @@ -1354,15 +1354,15 @@ void func_80090D20(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void } else { D_80126080.x = sSwordLengths[Player_GetSwordHeld(this)]; if (CVar_GetS32("gSeperateSwords", 0) != 0) - EffectBlure_ChangeType(Effect_GetByIndex(this->swordEffectIndex), sSwordTypes[Player_GetSwordHeld(this)]); + EffectBlure_ChangeType(Effect_GetByIndex(this->meleeWeaponEffectIndex), sSwordTypes[Player_GetSwordHeld(this)]); else - EffectBlure_ChangeType(Effect_GetByIndex(this->swordEffectIndex),1); //default sword type + EffectBlure_ChangeType(Effect_GetByIndex(this->meleeWeaponEffectIndex),1); //default sword type } func_80090A28(this, spE4); func_800906D4(play, this, spE4); } else if ((*dList != NULL) && (this->leftHandType == 7)) { - Color_RGB8* bottleColor = &sBottleColors[Player_ActionToBottle(this, this->itemActionParam)]; + Color_RGB8* bottleColor = &sBottleColors[Player_ActionToBottle(this, this->itemAction)]; OPEN_DISPS(play->state.gfxCtx); @@ -1451,8 +1451,8 @@ void func_80090D20(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void } if (this->actor.scale.y >= 0.0f) { - if ((this->heldItemActionParam == PLAYER_AP_HOOKSHOT) || - (this->heldItemActionParam == PLAYER_AP_LONGSHOT)) { + if ((this->heldItemAction == PLAYER_IA_HOOKSHOT) || + (this->heldItemAction == PLAYER_IA_LONGSHOT)) { Matrix_MultVec3f(&D_80126184, &this->unk_3C8); if (heldActor != NULL) { @@ -1468,7 +1468,7 @@ void func_80090D20(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void if (func_8002DD78(this) != 0) { Matrix_Translate(500.0f, 300.0f, 0.0f, MTXMODE_APPLY); Player_DrawHookshotReticle( - play, this, (this->heldItemActionParam == PLAYER_AP_HOOKSHOT) ? 38600.0f : 77600.0f); + play, this, (this->heldItemAction == PLAYER_IA_HOOKSHOT) ? 38600.0f : 77600.0f); } } } diff --git a/soh/src/code/z_sram.c b/soh/src/code/z_sram.c index 797a96177..9cdc54b01 100644 --- a/soh/src/code/z_sram.c +++ b/soh/src/code/z_sram.c @@ -217,14 +217,14 @@ void Sram_OpenSave() { gSaveContext.health = 0x30; } - if (gSaveContext.scarecrowCustomSongSet) { + if (gSaveContext.scarecrowLongSongSet) { osSyncPrintf(VT_FGCOL(BLUE)); osSyncPrintf("\n====================================================================\n"); - memcpy(gScarecrowCustomSongPtr, gSaveContext.scarecrowCustomSong, sizeof(gSaveContext.scarecrowCustomSong)); + memcpy(gScarecrowCustomSongPtr, gSaveContext.scarecrowLongSong, sizeof(gSaveContext.scarecrowLongSong)); ptr = (u8*)gScarecrowCustomSongPtr; - for (i = 0; i < ARRAY_COUNT(gSaveContext.scarecrowCustomSong); i++, ptr++) { + for (i = 0; i < ARRAY_COUNT(gSaveContext.scarecrowLongSong); i++, ptr++) { osSyncPrintf("%d, ", *ptr); } diff --git a/soh/src/code/z_vr_box.c b/soh/src/code/z_vr_box.c index 70e6fe31d..457cad3db 100644 --- a/soh/src/code/z_vr_box.c +++ b/soh/src/code/z_vr_box.c @@ -604,7 +604,7 @@ void Skybox_Setup(PlayState* play, SkyboxContext* skyboxCtx, s16 skyboxId) { { case SKYBOX_NORMAL_SKY: phi_v1 = 0; - if (gSaveContext.unk_13C3 != 0 && gSaveContext.sceneSetupIndex < 4 && gWeatherMode > 0 && + if (gSaveContext.retainWeatherMode != 0 && gSaveContext.sceneSetupIndex < 4 && gWeatherMode > 0 && gWeatherMode < 6) { phi_v1 = 1; } diff --git a/soh/src/overlays/actors/ovl_Arms_Hook/z_arms_hook.c b/soh/src/overlays/actors/ovl_Arms_Hook/z_arms_hook.c index 3b5cc77ec..9e913a846 100644 --- a/soh/src/overlays/actors/ovl_Arms_Hook/z_arms_hook.c +++ b/soh/src/overlays/actors/ovl_Arms_Hook/z_arms_hook.c @@ -85,7 +85,7 @@ void ArmsHook_Wait(ArmsHook* this, PlayState* play) { if (this->actor.parent == NULL) { Player* player = GET_PLAYER(play); // get correct timer length for hookshot or longshot - s32 length = (player->heldItemActionParam == PLAYER_AP_HOOKSHOT) ? 13 : 26; + s32 length = (player->heldItemAction == PLAYER_IA_HOOKSHOT) ? 13 : 26; ArmsHook_SetupAction(this, ArmsHook_Shoot); func_8002D9A4(&this->actor, 20.0f); @@ -121,7 +121,7 @@ s32 ArmsHook_CheckForCancel(ArmsHook* this) { Player* player = (Player*)this->actor.parent; if (Player_HoldsHookshot(player)) { - if ((player->itemActionParam != player->heldItemActionParam) || (player->actor.flags & ACTOR_FLAG_8) || + if ((player->itemAction != player->heldItemAction) || (player->actor.flags & ACTOR_FLAG_8) || ((player->stateFlags1 & 0x4000080))) { this->timer = 0; ArmsHook_DetachHookFromActor(this); diff --git a/soh/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c b/soh/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c index 635afbd5d..5a3d9a7d3 100644 --- a/soh/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c +++ b/soh/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c @@ -209,12 +209,12 @@ void BgDyYoseizo_CheckMagicAcquired(BgDyYoseizo* this, PlayState* play) { } if (play->sceneNum == SCENE_DAIYOUSEI_IZUMI) { - if (!gSaveContext.magicAcquired && (this->fountainType != FAIRY_UPGRADE_MAGIC)) { + if (!gSaveContext.isMagicAcquired && (this->fountainType != FAIRY_UPGRADE_MAGIC)) { Actor_Kill(&this->actor); return; } } else { - if (!gSaveContext.magicAcquired) { + if (!gSaveContext.isMagicAcquired) { Actor_Kill(&this->actor); return; } @@ -253,7 +253,7 @@ void BgDyYoseizo_ChooseType(BgDyYoseizo* this, PlayState* play) { } else { switch (this->fountainType) { case FAIRY_UPGRADE_MAGIC: - if (!gSaveContext.magicAcquired || BREG(2)) { + if (!gSaveContext.isMagicAcquired || BREG(2)) { // "Spin Attack speed UP" osSyncPrintf(VT_FGCOL(GREEN) " ☆☆☆☆☆ 回転切り速度UP ☆☆☆☆☆ \n" VT_RST); this->givingSpell = true; @@ -261,7 +261,7 @@ void BgDyYoseizo_ChooseType(BgDyYoseizo* this, PlayState* play) { } break; case FAIRY_UPGRADE_DOUBLE_MAGIC: - if (!gSaveContext.doubleMagic) { + if (!gSaveContext.isDoubleMagicAcquired) { // "Magic Meter doubled" osSyncPrintf(VT_FGCOL(YELLOW) " ☆☆☆☆☆ 魔法ゲージメーター倍増 ☆☆☆☆☆ \n" VT_RST); this->givingSpell = true; @@ -269,7 +269,7 @@ void BgDyYoseizo_ChooseType(BgDyYoseizo* this, PlayState* play) { } break; case FAIRY_UPGRADE_HALF_DAMAGE: - if (!gSaveContext.doubleDefense) { + if (!gSaveContext.isDoubleDefenseAcquired) { // "Damage halved" osSyncPrintf(VT_FGCOL(PURPLE) " ☆☆☆☆☆ ダメージ半減 ☆☆☆☆☆ \n" VT_RST); this->givingSpell = true; @@ -495,7 +495,7 @@ void BgDyYoseizo_HealPlayer_NoReward(BgDyYoseizo* this, PlayState* play) { this->refillTimer = 200; } - if (((gSaveContext.healthCapacity == gSaveContext.health) && (gSaveContext.magic == gSaveContext.unk_13F4)) || + if (((gSaveContext.healthCapacity == gSaveContext.health) && (gSaveContext.magic == gSaveContext.magicCapacity)) || (this->refillTimer == 1)) { this->healingTimer--; if (this->healingTimer == 90) { @@ -738,21 +738,21 @@ void BgDyYoseizo_Give_Reward(BgDyYoseizo* this, PlayState* play) { switch (actionIndex) { case FAIRY_UPGRADE_MAGIC: - gSaveContext.magicAcquired = true; - gSaveContext.unk_13F6 = 0x30; + gSaveContext.isMagicAcquired = true; + gSaveContext.magicFillTarget = 0x30; Interface_ChangeAlpha(9); break; case FAIRY_UPGRADE_DOUBLE_MAGIC: - if (!gSaveContext.magicAcquired) { - gSaveContext.magicAcquired = true; + if (!gSaveContext.isMagicAcquired) { + gSaveContext.isMagicAcquired = true; } - gSaveContext.doubleMagic = true; - gSaveContext.unk_13F6 = 0x60; + gSaveContext.isDoubleMagicAcquired = true; + gSaveContext.magicFillTarget = 0x60; gSaveContext.magicLevel = 0; Interface_ChangeAlpha(9); break; case FAIRY_UPGRADE_HALF_DAMAGE: - gSaveContext.doubleDefense = true; + gSaveContext.isDoubleDefenseAcquired = true; Interface_ChangeAlpha(9); break; } @@ -780,8 +780,8 @@ void BgDyYoseizo_Give_Reward(BgDyYoseizo* this, PlayState* play) { itemPos.x, itemPos.y, itemPos.z, 0, 0, 0, sExItemTypes[actionIndex]); if (this->item != NULL) { - if (gSaveContext.magicAcquired == 0) { - gSaveContext.magicAcquired = 1; + if (gSaveContext.isMagicAcquired == 0) { + gSaveContext.isMagicAcquired = 1; } else { Magic_Fill(play); } diff --git a/soh/src/overlays/actors/ovl_Bg_Hidan_Dalm/z_bg_hidan_dalm.c b/soh/src/overlays/actors/ovl_Bg_Hidan_Dalm/z_bg_hidan_dalm.c index 1161127cc..17dc96371 100644 --- a/soh/src/overlays/actors/ovl_Bg_Hidan_Dalm/z_bg_hidan_dalm.c +++ b/soh/src/overlays/actors/ovl_Bg_Hidan_Dalm/z_bg_hidan_dalm.c @@ -127,7 +127,7 @@ void BgHidanDalm_Wait(BgHidanDalm* this, PlayState* play) { Player* player = GET_PLAYER(play); if ((this->collider.base.acFlags & AC_HIT) && !Player_InCsMode(play) && - (player->swordAnimation == 22 || player->swordAnimation == 23)) { + (player->meleeWeaponAnimation == 22 || player->meleeWeaponAnimation == 23)) { this->collider.base.acFlags &= ~AC_HIT; if ((this->collider.elements[0].info.bumperFlags & BUMP_HIT) || (this->collider.elements[1].info.bumperFlags & BUMP_HIT)) { diff --git a/soh/src/overlays/actors/ovl_Bg_Toki_Swd/z_bg_toki_swd.c b/soh/src/overlays/actors/ovl_Bg_Toki_Swd/z_bg_toki_swd.c index 242e667ea..30c160b51 100644 --- a/soh/src/overlays/actors/ovl_Bg_Toki_Swd/z_bg_toki_swd.c +++ b/soh/src/overlays/actors/ovl_Bg_Toki_Swd/z_bg_toki_swd.c @@ -89,7 +89,7 @@ void BgTokiSwd_Init(Actor* thisx, PlayState* play) { uint32_t kokiriSwordBitMask = 1 << 0; if (!(gSaveContext.inventory.equipment & kokiriSwordBitMask)) { Player* player = GET_PLAYER(gPlayState); - player->currentSwordItem = ITEM_NONE; + player->currentSwordItemId = ITEM_NONE; gSaveContext.equips.buttonItems[0] = ITEM_NONE; Inventory_ChangeEquipment(EQUIP_SWORD, PLAYER_SWORD_NONE); } diff --git a/soh/src/overlays/actors/ovl_Bg_Ydan_Sp/z_bg_ydan_sp.c b/soh/src/overlays/actors/ovl_Bg_Ydan_Sp/z_bg_ydan_sp.c index a261b39b5..d9fa609fc 100644 --- a/soh/src/overlays/actors/ovl_Bg_Ydan_Sp/z_bg_ydan_sp.c +++ b/soh/src/overlays/actors/ovl_Bg_Ydan_Sp/z_bg_ydan_sp.c @@ -282,8 +282,8 @@ void BgYdanSp_FloorWebIdle(BgYdanSp* this, PlayState* play) { webPos.y = this->dyna.actor.world.pos.y - 50.0f; webPos.z = this->dyna.actor.world.pos.z; if (Player_IsBurningStickInRange(play, &webPos, 70.0f, 50.0f) != 0) { - this->dyna.actor.home.pos.x = player->swordInfo[0].tip.x; - this->dyna.actor.home.pos.z = player->swordInfo[0].tip.z; + this->dyna.actor.home.pos.x = player->meleeWeaponInfo[0].tip.x; + this->dyna.actor.home.pos.z = player->meleeWeaponInfo[0].tip.z; BgYdanSp_BurnWeb(this, play); return; } @@ -402,11 +402,11 @@ void BgYdanSp_WallWebIdle(BgYdanSp* this, PlayState* play) { if (Flags_GetSwitch(play, this->burnSwitchFlag) || (this->trisCollider.base.acFlags & 2)) { this->dyna.actor.home.pos.y = this->dyna.actor.world.pos.y + 80.0f; BgYdanSp_BurnWeb(this, play); - } else if (player->heldItemActionParam == PLAYER_AP_STICK && player->unk_860 != 0) { - func_8002DBD0(&this->dyna.actor, &sp30, &player->swordInfo[0].tip); + } else if (player->heldItemAction == PLAYER_IA_STICK && player->unk_860 != 0) { + func_8002DBD0(&this->dyna.actor, &sp30, &player->meleeWeaponInfo[0].tip); if (fabsf(sp30.x) < 100.0f && sp30.z < 1.0f && sp30.y < 200.0f) { OnePointCutscene_Init(play, 3020, 40, &this->dyna.actor, MAIN_CAM); - Math_Vec3f_Copy(&this->dyna.actor.home.pos, &player->swordInfo[0].tip); + Math_Vec3f_Copy(&this->dyna.actor.home.pos, &player->meleeWeaponInfo[0].tip); BgYdanSp_BurnWeb(this, play); } } diff --git a/soh/src/overlays/actors/ovl_Boss_Ganon/z_boss_ganon.c b/soh/src/overlays/actors/ovl_Boss_Ganon/z_boss_ganon.c index 1f00f27a7..817bafa15 100644 --- a/soh/src/overlays/actors/ovl_Boss_Ganon/z_boss_ganon.c +++ b/soh/src/overlays/actors/ovl_Boss_Ganon/z_boss_ganon.c @@ -1188,7 +1188,7 @@ void BossGanon_SetupTowerCutscene(BossGanon* this, PlayState* play) { this->csTimer = 0; this->csState = 100; this->unk_198 = 1; - gSaveContext.magic = gSaveContext.unk_13F4; + gSaveContext.magic = gSaveContext.magicCapacity; gSaveContext.health = gSaveContext.healthCapacity; } else { this->actionFunc = BossGanon_SetupTowerCutscene; @@ -3962,7 +3962,7 @@ void BossGanon_LightBall_Update(Actor* thisx, PlayState* play2) { switch (this->unk_1C2) { case 0: - if ((player->stateFlags1 & 2) && + if ((player->stateFlags1 & PLAYER_STATE1_SWINGING_BOTTLE) && (ABS((s16)(player->actor.shape.rot.y - (s16)(ganondorf->actor.yawTowardsPlayer + 0x8000))) < 0x2000) && (sqrtf(SQ(xDistFromLink) + SQ(yDistFromLink) + SQ(zDistFromLink)) <= 25.0f)) { @@ -4003,7 +4003,7 @@ void BossGanon_LightBall_Update(Actor* thisx, PlayState* play2) { } // if a spin attack is used - if (player->swordAnimation >= 0x18) { + if (player->meleeWeaponAnimation >= 0x18) { this->actor.speedXZ = 20.0f; } break; @@ -4447,7 +4447,7 @@ void func_808E2544(Actor* thisx, PlayState* play) { this->actor.world.rot.x = (Math_CosS(this->unk_1A2 * 0x3400) * sp84 * 0.1f) + this->actor.shape.rot.x; this->actor.world.rot.y = (Math_SinS(this->unk_1A2 * 0x1A00) * sp84) + this->actor.shape.rot.y; - if ((player->swordState != 0) && (player->swordAnimation >= 0x18) && (this->actor.xzDistToPlayer < 80.0f)) { + if ((player->swordState != 0) && (player->meleeWeaponAnimation >= 0x18) && (this->actor.xzDistToPlayer < 80.0f)) { this->unk_1C2 = 0xC; this->actor.speedXZ = -30.0f; func_8002D908(&this->actor); diff --git a/soh/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c b/soh/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c index 421826f95..0efb308f5 100644 --- a/soh/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c +++ b/soh/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c @@ -1668,7 +1668,7 @@ void func_8090120C(BossGanon2* this, PlayState* play) { temp_f12 = this->unk_1B8.z - player->actor.world.pos.z; temp_a0_2 = Math_Atan2S(temp_f12, temp_f14) - player->actor.shape.rot.y; if ((ABS(temp_a0_2) < 0x2000) && (sqrtf(SQ(temp_f14) + SQ(temp_f12)) < 70.0f) && - (player->swordState != 0) && (player->heldItemActionParam == PLAYER_AP_SWORD_MASTER)) { + (player->swordState != 0) && (player->heldItemAction == PLAYER_IA_SWORD_MASTER)) { func_80064520(play, &play->csCtx); gSaveContext.sohStats.gameComplete = true; gSaveContext.sohStats.timestamp[TIMESTAMP_DEFEAT_GANON] = GAMEPLAYSTAT_TOTAL_TIME; diff --git a/soh/src/overlays/actors/ovl_Demo_Im/z_demo_im.c b/soh/src/overlays/actors/ovl_Demo_Im/z_demo_im.c index d1753aee1..dff65b42f 100644 --- a/soh/src/overlays/actors/ovl_Demo_Im/z_demo_im.c +++ b/soh/src/overlays/actors/ovl_Demo_Im/z_demo_im.c @@ -915,7 +915,7 @@ void GivePlayerRandoRewardImpa(Actor* impa, PlayState* play, RandomizerCheck che gSaveContext.eventChkInf[5] |= 0x200; play->sceneLoadFlag = 0x14; play->fadeTransition = 3; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; // In entrance rando have impa bring link back to the front of castle grounds if (Randomizer_GetSettingValue(RSK_SHUFFLE_OVERWORLD_ENTRANCES)) { play->nextEntranceIndex = 0x0138; diff --git a/soh/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c b/soh/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c index 91625301f..289f700c1 100644 --- a/soh/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c +++ b/soh/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c @@ -417,7 +417,7 @@ void func_80996C60(DoorShutter* this, PlayState* play) { DoorShutter_SetupAction(this, func_80997004); this->unk_16C = sp38; this->unk_170 = 0.0f; - Camera_ChangeDoorCam(play->cameraPtrs[MAIN_CAM], &this->dyna.actor, player->unk_46A, 0.0f, 12, sp34, 10); + Camera_ChangeDoorCam(play->cameraPtrs[MAIN_CAM], &this->dyna.actor, player->doorBgCamIndex, 0.0f, 12, sp34, 10); } } diff --git a/soh/src/overlays/actors/ovl_Door_Warp1/z_door_warp1.c b/soh/src/overlays/actors/ovl_Door_Warp1/z_door_warp1.c index bc54d7bd6..acc093e3f 100644 --- a/soh/src/overlays/actors/ovl_Door_Warp1/z_door_warp1.c +++ b/soh/src/overlays/actors/ovl_Door_Warp1/z_door_warp1.c @@ -589,7 +589,7 @@ void DoorWarp1_ChildWarpOut(DoorWarp1* this, PlayState* play) { osSyncPrintf("\n\n\nおわりおわり"); play->sceneLoadFlag = 0x14; play->fadeTransition = 7; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; } Math_StepToF(&this->unk_194, 2.0f, 0.01f); @@ -907,7 +907,7 @@ void DoorWarp1_AdultWarpOut(DoorWarp1* this, PlayState* play) { play->sceneLoadFlag = 0x14; play->fadeTransition = 3; - gSaveContext.nextTransition = 7; + gSaveContext.nextTransitionType = 7; } if (this->warpTimer >= 141) { f32 screenFillAlpha; diff --git a/soh/src/overlays/actors/ovl_En_Butte/z_en_butte.c b/soh/src/overlays/actors/ovl_En_Butte/z_en_butte.c index 6368ef19c..b3039f848 100644 --- a/soh/src/overlays/actors/ovl_En_Butte/z_en_butte.c +++ b/soh/src/overlays/actors/ovl_En_Butte/z_en_butte.c @@ -270,7 +270,7 @@ void EnButte_FlyAround(EnButte* this, PlayState* play) { EnButte_SelectFlightParams(this, &sFlyAroundParams[this->flightParamsIdx]); } - if (((this->actor.params & 1) == 1) && (player->heldItemActionParam == PLAYER_AP_STICK) && + if (((this->actor.params & 1) == 1) && (player->heldItemAction == PLAYER_IA_STICK) && (this->swordDownTimer <= 0) && ((Math3D_Dist2DSq(player->actor.world.pos.x, player->actor.world.pos.z, this->actor.home.pos.x, this->actor.home.pos.z) < SQ(120.0f)) || @@ -306,9 +306,9 @@ void EnButte_FollowLink(EnButte* this, PlayState* play) { minAnimSpeed = 0.0f; if ((this->flightParamsIdx != 0) && (this->timer < 12)) { - swordTip.x = player->swordInfo[0].tip.x + Math_SinS(player->actor.shape.rot.y) * 10.0f; - swordTip.y = player->swordInfo[0].tip.y; - swordTip.z = player->swordInfo[0].tip.z + Math_CosS(player->actor.shape.rot.y) * 10.0f; + swordTip.x = player->meleeWeaponInfo[0].tip.x + Math_SinS(player->actor.shape.rot.y) * 10.0f; + swordTip.y = player->meleeWeaponInfo[0].tip.y; + swordTip.z = player->meleeWeaponInfo[0].tip.z + Math_CosS(player->actor.shape.rot.y) * 10.0f; yaw = Math_Vec3f_Yaw(&this->actor.world.pos, &swordTip) + (s16)(Rand_ZeroOne() * D_809CE410); if (Math_ScaledStepToS(&this->actor.world.rot.y, yaw, 2000) != 0) { @@ -320,7 +320,7 @@ void EnButte_FollowLink(EnButte* this, PlayState* play) { } } - this->posYTarget = MAX(player->actor.world.pos.y + 30.0f, player->swordInfo[0].tip.y); + this->posYTarget = MAX(player->actor.world.pos.y + 30.0f, player->meleeWeaponInfo[0].tip.y); EnButte_Turn(this); @@ -336,11 +336,11 @@ void EnButte_FollowLink(EnButte* this, PlayState* play) { distSqFromHome = Math3D_Dist2DSq(this->actor.world.pos.x, this->actor.world.pos.z, this->actor.home.pos.x, this->actor.home.pos.z); - if (!((player->heldItemActionParam == PLAYER_AP_STICK) && (fabsf(player->actor.speedXZ) < 1.8f) && + if (!((player->heldItemAction == PLAYER_IA_STICK) && (fabsf(player->actor.speedXZ) < 1.8f) && (this->swordDownTimer <= 0) && (distSqFromHome < SQ(320.0f)))) { EnButte_SetupFlyAround(this); } else if (distSqFromHome > SQ(240.0f)) { - distSqFromSword = Math3D_Dist2DSq(player->swordInfo[0].tip.x, player->swordInfo[0].tip.z, + distSqFromSword = Math3D_Dist2DSq(player->meleeWeaponInfo[0].tip.x, player->meleeWeaponInfo[0].tip.z, this->actor.world.pos.x, this->actor.world.pos.z); if (distSqFromSword < SQ(60.0f)) { EnButte_SetupTransformIntoFairy(this); diff --git a/soh/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c b/soh/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c index 3e85b72a8..bfb7507cc 100644 --- a/soh/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c +++ b/soh/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c @@ -470,7 +470,7 @@ void EnFhgFire_EnergyBall(EnFhgFire* this, PlayState* play) { switch (this->work[FHGFIRE_FIRE_MODE]) { case FHGFIRE_LIGHT_GREEN: canBottleReflect1 = - ((player->stateFlags1 & 2) && + ((player->stateFlags1 & PLAYER_STATE1_SWINGING_BOTTLE) && (ABS((s16)(player->actor.shape.rot.y - (s16)(bossGnd->actor.yawTowardsPlayer + 0x8000))) < 0x2000) && (sqrtf(SQ(dxL) + SQ(dyL) + SQ(dzL)) <= 25.0f)) @@ -510,7 +510,7 @@ void EnFhgFire_EnergyBall(EnFhgFire* this, PlayState* play) { this->work[FHGFIRE_RETURN_COUNT] = 100; } - if (!canBottleReflect2 && (player->swordAnimation >= 24)) { + if (!canBottleReflect2 && (player->meleeWeaponAnimation >= 24)) { this->actor.speedXZ = 20.0f; this->work[FHGFIRE_RETURN_COUNT] = 4; } else { diff --git a/soh/src/overlays/actors/ovl_En_Gb/z_en_gb.c b/soh/src/overlays/actors/ovl_En_Gb/z_en_gb.c index dff83254f..0bd71ea3b 100644 --- a/soh/src/overlays/actors/ovl_En_Gb/z_en_gb.c +++ b/soh/src/overlays/actors/ovl_En_Gb/z_en_gb.c @@ -320,7 +320,7 @@ void func_80A2F9C0(EnGb* this, PlayState* play) { gSaveContext.infTable[0xB] |= 0x40; } func_80A2F180(this); - Player_UpdateBottleHeld(play, GET_PLAYER(play), ITEM_BOTTLE, PLAYER_AP_BOTTLE); + Player_UpdateBottleHeld(play, GET_PLAYER(play), ITEM_BOTTLE, PLAYER_IA_BOTTLE); Rupees_ChangeBy(10); this->actionFunc = func_80A2F83C; } @@ -332,7 +332,7 @@ void func_80A2FA50(EnGb* this, PlayState* play) { gSaveContext.infTable[0xB] |= 0x40; } func_80A2F180(this); - Player_UpdateBottleHeld(play, GET_PLAYER(play), ITEM_BOTTLE, PLAYER_AP_BOTTLE); + Player_UpdateBottleHeld(play, GET_PLAYER(play), ITEM_BOTTLE, PLAYER_IA_BOTTLE); Rupees_ChangeBy(50); HIGH_SCORE(HS_POE_POINTS) += 100; if (HIGH_SCORE(HS_POE_POINTS) != 1000) { diff --git a/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c b/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c index 426fd4ccd..ccb9cb7bc 100644 --- a/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c +++ b/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c @@ -283,7 +283,7 @@ s32 EnGeldB_ReactToPlayer(PlayState* play, EnGeldB* this, s16 arg2) { angleToLink = ABS(angleToLink); if (func_800354B4(play, thisx, 100.0f, 0x2710, 0x3E80, thisx->shape.rot.y)) { - if (player->swordAnimation == 0x11) { + if (player->meleeWeaponAnimation == 0x11) { EnGeldB_SetupSpinDodge(this, play); return true; } else if (play->gameplayFrames & 1) { @@ -296,7 +296,7 @@ s32 EnGeldB_ReactToPlayer(PlayState* play, EnGeldB* this, s16 arg2) { if ((thisx->bgCheckFlags & 8) && (ABS(angleToWall) < 0x2EE0) && (thisx->xzDistToPlayer < 90.0f)) { EnGeldB_SetupJump(this); return true; - } else if (player->swordAnimation == 0x11) { + } else if (player->meleeWeaponAnimation == 0x11) { EnGeldB_SetupSpinDodge(this, play); return true; } else if ((thisx->xzDistToPlayer < 90.0f) && (play->gameplayFrames & 1)) { @@ -1138,7 +1138,7 @@ void EnGeldB_Block(EnGeldB* this, PlayState* play) { if ((ABS(angleToLink) <= 0x4000) && (this->actor.xzDistToPlayer < 40.0f) && (ABS(this->actor.yDistToPlayer) < 50.0f)) { if (func_800354B4(play, &this->actor, 100.0f, 0x2710, 0x4000, this->actor.shape.rot.y)) { - if (player->swordAnimation == 0x11) { + if (player->meleeWeaponAnimation == 0x11) { EnGeldB_SetupSpinDodge(this, play); } else if (play->gameplayFrames & 1) { EnGeldB_SetupBlock(this); @@ -1159,7 +1159,7 @@ void EnGeldB_Block(EnGeldB* this, PlayState* play) { } } else if ((this->timer == 0) && func_800354B4(play, &this->actor, 100.0f, 0x2710, 0x4000, this->actor.shape.rot.y)) { - if (player->swordAnimation == 0x11) { + if (player->meleeWeaponAnimation == 0x11) { EnGeldB_SetupSpinDodge(this, play); } else if (!EnGeldB_DodgeRanged(play, this)) { if ((play->gameplayFrames & 1)) { diff --git a/soh/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c b/soh/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c index 5e872cff8..26d1cb3ba 100644 --- a/soh/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c +++ b/soh/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c @@ -368,7 +368,7 @@ void EnHeishi1_Kick(EnHeishi1* this, PlayState* play) { this->loadStarted = true; sHeishi1PlayerIsCaught = false; play->fadeTransition = 0x2E; - gSaveContext.nextTransition = 0x2E; + gSaveContext.nextTransitionType = 0x2E; } } } diff --git a/soh/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c b/soh/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c index 768e7ca71..f93292542 100644 --- a/soh/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c +++ b/soh/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c @@ -208,7 +208,7 @@ void func_80A55D00(EnHeishi3* this, PlayState* play) { play->sceneLoadFlag = 0x14; this->respawnFlag = 1; play->fadeTransition = 0x2E; - gSaveContext.nextTransition = 0x2E; + gSaveContext.nextTransitionType = 0x2E; } } diff --git a/soh/src/overlays/actors/ovl_En_Hy/z_en_hy.c b/soh/src/overlays/actors/ovl_En_Hy/z_en_hy.c index a7b81c8f1..cf9c3fe19 100644 --- a/soh/src/overlays/actors/ovl_En_Hy/z_en_hy.c +++ b/soh/src/overlays/actors/ovl_En_Hy/z_en_hy.c @@ -596,7 +596,7 @@ s16 func_80A70058(PlayState* play, Actor* thisx) { case 0x70F3: Rupees_ChangeBy(beggarRewards[this->actor.textId - 0x70F0]); Animation_ChangeByInfo(&this->skelAnime, sAnimationInfo, ENHY_ANIM_17); - Player_UpdateBottleHeld(play, GET_PLAYER(play), ITEM_BOTTLE, PLAYER_AP_BOTTLE); + Player_UpdateBottleHeld(play, GET_PLAYER(play), ITEM_BOTTLE, PLAYER_IA_BOTTLE); break; case 0x7016: gSaveContext.infTable[12] |= 1; diff --git a/soh/src/overlays/actors/ovl_En_Kakasi/z_en_kakasi.c b/soh/src/overlays/actors/ovl_En_Kakasi/z_en_kakasi.c index 463829dd9..95e493eee 100644 --- a/soh/src/overlays/actors/ovl_En_Kakasi/z_en_kakasi.c +++ b/soh/src/overlays/actors/ovl_En_Kakasi/z_en_kakasi.c @@ -180,13 +180,13 @@ void func_80A8F660(EnKakasi* this, PlayState* play) { this->unk_196 = TEXT_STATE_DONE; if (!LINK_IS_ADULT) { this->unk_194 = false; - if (gSaveContext.scarecrowCustomSongSet) { + if (gSaveContext.scarecrowLongSongSet) { this->actor.textId = 0x407A; this->unk_196 = TEXT_STATE_EVENT; } } else { this->unk_194 = true; - if (gSaveContext.scarecrowCustomSongSet) { + if (gSaveContext.scarecrowLongSongSet) { this->actor.textId = 0x4079; this->unk_196 = TEXT_STATE_EVENT; } @@ -342,7 +342,7 @@ void EnKakasi_Draw(Actor* thisx, PlayState* play) { if (BREG(3) != 0) { osSyncPrintf("\n\n"); // "flag!" - osSyncPrintf(VT_FGCOL(YELLOW) "☆☆☆☆☆ フラグ! ☆☆☆☆☆ %d\n" VT_RST, gSaveContext.scarecrowCustomSongSet); + osSyncPrintf(VT_FGCOL(YELLOW) "☆☆☆☆☆ フラグ! ☆☆☆☆☆ %d\n" VT_RST, gSaveContext.scarecrowLongSongSet); } func_80093D18(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelanime.skeleton, this->skelanime.jointTable, this->skelanime.dListCount, diff --git a/soh/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c b/soh/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c index 77cb939b4..af2c416f1 100644 --- a/soh/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c +++ b/soh/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c @@ -287,7 +287,7 @@ void EnKanban_Update(Actor* thisx, PlayState* play2) { u8 i; if (hitItem->toucher.dmgFlags & 0x700) { - this->cutType = sCutTypes[player->swordAnimation]; + this->cutType = sCutTypes[player->meleeWeaponAnimation]; } else { this->cutType = CUT_POST; } diff --git a/soh/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c b/soh/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c index 6ca779d41..d7fdc8c4b 100644 --- a/soh/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c +++ b/soh/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c @@ -85,7 +85,7 @@ void EnMThunder_Init(Actor* thisx, PlayState* play2) { this->unk_1CA = 0; if (player->stateFlags2 & 0x20000) { - if (!gSaveContext.magicAcquired || gSaveContext.unk_13F0 || + if (!gSaveContext.isMagicAcquired || gSaveContext.magicState || (((this->actor.params & 0xFF00) >> 8) && !(func_80087708(play, (this->actor.params & 0xFF00) >> 8, 0)))) { Audio_PlaySoundGeneral(NA_SE_IT_ROLLING_CUT, &player->actor.projectedPos, 4, &D_801333E0, &D_801333E0, @@ -132,7 +132,7 @@ void func_80A9F350(EnMThunder* this, PlayState* play) { Player* player = GET_PLAYER(play); if (player->stateFlags2 & 0x20000) { - if (player->swordAnimation >= 0x18) { + if (player->meleeWeaponAnimation >= 0x18) { Audio_PlaySoundGeneral(NA_SE_IT_ROLLING_CUT, &player->actor.projectedPos, 4, &D_801333E0, &D_801333E0, &D_801333E8); Audio_PlaySoundGeneral(NA_SE_IT_SWORD_SWING_HARD, &player->actor.projectedPos, 4, &D_801333E0, &D_801333E0, @@ -158,7 +158,7 @@ void func_80A9F408(EnMThunder* this, PlayState* play) { if (this->unk_1CA == 0) { if (player->unk_858 >= 0.1f) { - if ((gSaveContext.unk_13F0) || (((this->actor.params & 0xFF00) >> 8) && + if ((gSaveContext.magicState) || (((this->actor.params & 0xFF00) >> 8) && !(func_80087708(play, (this->actor.params & 0xFF00) >> 8, 4)))) { func_80A9F350(this, play); func_80A9EFE0(this, func_80A9F350); @@ -182,7 +182,7 @@ void func_80A9F408(EnMThunder* this, PlayState* play) { } if (player->unk_858 <= 0.15f) { - if ((player->unk_858 >= 0.1f) && (player->swordAnimation >= 0x18)) { + if ((player->unk_858 >= 0.1f) && (player->meleeWeaponAnimation >= 0x18)) { Audio_PlaySoundGeneral(NA_SE_IT_ROLLING_CUT, &player->actor.projectedPos, 4, &D_801333E0, &D_801333E0, &D_801333E8); Audio_PlaySoundGeneral(NA_SE_IT_SWORD_SWING_HARD, &player->actor.projectedPos, 4, &D_801333E0, @@ -193,7 +193,7 @@ void func_80A9F408(EnMThunder* this, PlayState* play) { } else { player->stateFlags2 &= ~0x20000; if ((this->actor.params & 0xFF00) >> 8) { - gSaveContext.unk_13F0 = 1; + gSaveContext.magicState = 1; } if (player->unk_858 < 0.85f) { this->collider.info.toucher.dmgFlags = D_80AA044C[this->unk_1C7]; diff --git a/soh/src/overlays/actors/ovl_En_Mag/z_en_mag.c b/soh/src/overlays/actors/ovl_En_Mag/z_en_mag.c index c73c33e99..5e10d0b9a 100644 --- a/soh/src/overlays/actors/ovl_En_Mag/z_en_mag.c +++ b/soh/src/overlays/actors/ovl_En_Mag/z_en_mag.c @@ -109,8 +109,8 @@ void EnMag_InitMq(Actor* thisx, PlayState* play) { gSaveContext.unk_13E7 = 0; this->globalState = MAG_STATE_DISPLAY; sDelayTimer = 20; - gSaveContext.fadeDuration = 1; - gSaveContext.unk_1419 = 255; + gSaveContext.transFadeDuration = 1; + gSaveContext.transWipeSpeed = 255; } Font_LoadOrderedFont(&this->font); @@ -199,8 +199,8 @@ void EnMag_InitVanilla(Actor* thisx, PlayState* play) { gSaveContext.unk_13E7 = 0; this->globalState = MAG_STATE_DISPLAY; sDelayTimer = 20; - gSaveContext.fadeDuration = 1; - gSaveContext.unk_1419 = 255; + gSaveContext.transFadeDuration = 1; + gSaveContext.transWipeSpeed = 255; } Font_LoadOrderedFont(&this->font); @@ -242,8 +242,8 @@ void EnMag_UpdateMq(Actor* thisx, PlayState* play) { this->globalState = MAG_STATE_DISPLAY; sDelayTimer = 20; - gSaveContext.fadeDuration = 1; - gSaveContext.unk_1419 = 255; + gSaveContext.transFadeDuration = 1; + gSaveContext.transWipeSpeed = 255; } } else if (this->globalState >= MAG_STATE_DISPLAY) { if (sDelayTimer == 0) { @@ -413,8 +413,8 @@ void EnMag_UpdateVanilla(Actor* thisx, PlayState* play) { this->globalState = MAG_STATE_DISPLAY; sDelayTimer = 20; - gSaveContext.fadeDuration = 1; - gSaveContext.unk_1419 = 255; + gSaveContext.transFadeDuration = 1; + gSaveContext.transWipeSpeed = 255; } } else if (this->globalState >= MAG_STATE_DISPLAY) { if (sDelayTimer == 0) { diff --git a/soh/src/overlays/actors/ovl_En_Owl/z_en_owl.c b/soh/src/overlays/actors/ovl_En_Owl/z_en_owl.c index bbecb2505..c971f8844 100644 --- a/soh/src/overlays/actors/ovl_En_Owl/z_en_owl.c +++ b/soh/src/overlays/actors/ovl_En_Owl/z_en_owl.c @@ -630,7 +630,7 @@ void func_80ACB274(EnOwl* this, PlayState* play) { void EnOwl_WaitDeathMountainShortcut(EnOwl* this, PlayState* play) { EnOwl_LookAtLink(this, play); - if (!gSaveContext.magicAcquired && !gSaveContext.n64ddFlag) { + if (!gSaveContext.isMagicAcquired && !gSaveContext.n64ddFlag) { if (func_80ACA558(this, play, 0x3062)) { Audio_PlayFanfare(NA_BGM_OWL); this->actionFunc = func_80ACB274; diff --git a/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c b/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c index 2bb126290..973e2ff71 100644 --- a/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c +++ b/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c @@ -349,7 +349,7 @@ void func_80AD97C8(EnPoSisters* this, PlayState* play) { f32 sp20; if (this->unk_195 == 0 || this->actionFunc != func_80ADAAA4) { - if ((player->swordState == 0 || player->swordAnimation >= 24) && + if ((player->swordState == 0 || player->meleeWeaponAnimation >= 24) && player->actor.world.pos.y - player->actor.floorHeight < 1.0f) { Math_StepToF(&this->unk_294, 110.0f, 3.0f); } else { diff --git a/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c b/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c index c1d9a3a7a..975714fa0 100644 --- a/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c +++ b/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c @@ -479,8 +479,8 @@ void func_80AFD968(EnSkb* this, PlayState* play) { if (this->unk_283 == 0) { if ((this->actor.colChkInfo.damageEffect == 0xD) || ((this->actor.colChkInfo.damageEffect == 0xE) && - ((player->swordAnimation >= 4 && player->swordAnimation <= 11) || - (player->swordAnimation == 20 || player->swordAnimation == 21)))) { + ((player->meleeWeaponAnimation >= 4 && player->meleeWeaponAnimation <= 11) || + (player->meleeWeaponAnimation == 20 || player->meleeWeaponAnimation == 21)))) { BodyBreak_Alloc(&this->bodyBreak, 2, play); this->unk_283 = 1; } diff --git a/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c b/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c index 151d4e84e..b50398b45 100644 --- a/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c +++ b/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c @@ -732,7 +732,7 @@ s32 func_80B0DFFC(EnSw* this, PlayState* play) { false, false, true, &sp5C)) { sp4C = false; } else if (((play->state.frames % 4) == 2) && - !BgCheck_EntityLineTest1(&play->colCtx, &this->actor.world.pos, &this->unk_46C, &sp50, &sp60, true, + !BgCheck_EntityLineTest1(&play->colCtx, &this->actor.world.pos, &this->subCamId, &sp50, &sp60, true, false, false, true, &sp5C)) { sp4C = false; } else if (((play->state.frames % 4) == 3) && @@ -949,7 +949,7 @@ s32 EnSw_OverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* po if (limbIndex == 1) { Matrix_MultVec3f(&sp7C, &this->unk_454); Matrix_MultVec3f(&sp70, &this->unk_460); - Matrix_MultVec3f(&sp64, &this->unk_46C); + Matrix_MultVec3f(&sp64, &this->subCamId); Matrix_MultVec3f(&sp58, &this->unk_478); Matrix_MultVec3f(&sp4C, &this->unk_484); } diff --git a/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.h b/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.h index c766e9f9e..0d0ae96a1 100644 --- a/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.h +++ b/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.h @@ -43,7 +43,7 @@ typedef struct EnSw { /* 0x0448 */ Vec3f unk_448; /* 0x0454 */ Vec3f unk_454; /* 0x0460 */ Vec3f unk_460; - /* 0x046C */ Vec3f unk_46C; + /* 0x046C */ Vec3f subCamId; /* 0x0478 */ Vec3f unk_478; /* 0x0484 */ Vec3f unk_484; /* 0x0490 */ char unk_490[0x48]; diff --git a/soh/src/overlays/actors/ovl_En_Ta/z_en_ta.c b/soh/src/overlays/actors/ovl_En_Ta/z_en_ta.c index 7e43d16d2..93fb532eb 100644 --- a/soh/src/overlays/actors/ovl_En_Ta/z_en_ta.c +++ b/soh/src/overlays/actors/ovl_En_Ta/z_en_ta.c @@ -671,10 +671,10 @@ void func_80B15424(EnTa* this, PlayState* play) { if (gSaveContext.eventInf[0] & 0x100) { play->fadeTransition = 46; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; } else { play->fadeTransition = 38; - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; } play->sceneLoadFlag = 0x14; diff --git a/soh/src/overlays/actors/ovl_En_Test/z_en_test.c b/soh/src/overlays/actors/ovl_En_Test/z_en_test.c index 025626b81..002c5540b 100644 --- a/soh/src/overlays/actors/ovl_En_Test/z_en_test.c +++ b/soh/src/overlays/actors/ovl_En_Test/z_en_test.c @@ -496,7 +496,7 @@ void EnTest_Idle(EnTest* this, PlayState* play) { if ((player->swordState != 0) && (ABS(yawDiff) >= 0x1F40)) { this->actor.shape.rot.y = this->actor.world.rot.y = this->actor.yawTowardsPlayer; - if (Rand_ZeroOne() > 0.7f && player->swordAnimation != 0x11) { + if (Rand_ZeroOne() > 0.7f && player->meleeWeaponAnimation != 0x11) { EnTest_SetupJumpBack(this); } else { func_808627C4(this, play); @@ -627,7 +627,7 @@ void EnTest_WalkAndBlock(EnTest* this, PlayState* play) { if (ABS(yawDiff) >= 0x1F40) { this->actor.shape.rot.y = this->actor.world.rot.y = this->actor.yawTowardsPlayer; - if ((Rand_ZeroOne() > 0.7f) && (player->swordAnimation != 0x11)) { + if ((Rand_ZeroOne() > 0.7f) && (player->meleeWeaponAnimation != 0x11)) { EnTest_SetupJumpBack(this); } else { EnTest_SetupStopAndBlock(this); @@ -663,7 +663,7 @@ void EnTest_WalkAndBlock(EnTest* this, PlayState* play) { EnTest_SetupJumpslash(this); return; } - } else if (player->heldItemActionParam != PLAYER_AP_NONE) { + } else if (player->heldItemAction != PLAYER_IA_NONE) { if (this->actor.isTargeted) { if ((play->gameplayFrames % 2) != 0) { func_808627C4(this, play); @@ -1238,7 +1238,7 @@ void func_808621D4(EnTest* this, PlayState* play) { (this->actor.xzDistToPlayer < 80.0f))) { EnTest_SetupJumpUp(this); } else if ((Rand_ZeroOne() > 0.7f) && (this->actor.params != STALFOS_TYPE_CEILING) && - (player->swordAnimation != 0x11)) { + (player->meleeWeaponAnimation != 0x11)) { EnTest_SetupJumpBack(this); } else { EnTest_SetupStopAndBlock(this); @@ -1277,7 +1277,7 @@ void func_80862418(EnTest* this, PlayState* play) { (this->actor.xzDistToPlayer < 80.0f))) { EnTest_SetupJumpUp(this); } else if ((Rand_ZeroOne() > 0.7f) && (this->actor.params != STALFOS_TYPE_CEILING) && - (player->swordAnimation != 0x11)) { + (player->meleeWeaponAnimation != 0x11)) { EnTest_SetupJumpBack(this); } else { EnTest_SetupStopAndBlock(this); @@ -1323,7 +1323,7 @@ void EnTest_Stunned(EnTest* this, PlayState* play) { ((ABS((s16)(this->actor.wallYaw - this->actor.shape.rot.y)) < 0x38A4) && (this->actor.xzDistToPlayer < 80.0f))) { EnTest_SetupJumpUp(this); - } else if ((Rand_ZeroOne() > 0.7f) && (player->swordAnimation != 0x11)) { + } else if ((Rand_ZeroOne() > 0.7f) && (player->meleeWeaponAnimation != 0x11)) { EnTest_SetupJumpBack(this); } else { EnTest_SetupStopAndBlock(this); @@ -1459,7 +1459,7 @@ void func_808628C8(EnTest* this, PlayState* play) { if (!EnTest_ReactToProjectile(play, this)) { EnTest_ChooseAction(this, play); } - } else if (player->heldItemActionParam != PLAYER_AP_NONE) { + } else if (player->heldItemAction != PLAYER_IA_NONE) { if ((play->gameplayFrames % 2) != 0) { EnTest_SetupIdle(this); } else { diff --git a/soh/src/overlays/actors/ovl_En_Torch2/z_en_torch2.c b/soh/src/overlays/actors/ovl_En_Torch2/z_en_torch2.c index 7f24cc4e6..d5a8209df 100644 --- a/soh/src/overlays/actors/ovl_En_Torch2/z_en_torch2.c +++ b/soh/src/overlays/actors/ovl_En_Torch2/z_en_torch2.c @@ -128,16 +128,16 @@ void EnTorch2_Init(Actor* thisx, PlayState* play2) { sInput.cur.button = sInput.press.button = sInput.rel.button = 0; sInput.cur.stick_x = sInput.cur.stick_y = 0; this->currentShield = PLAYER_SHIELD_HYLIAN; - this->heldItemActionParam = this->heldItemId = PLAYER_AP_SWORD_MASTER; + this->heldItemAction = this->heldItemId = PLAYER_IA_SWORD_MASTER; Player_SetModelGroup(this, 2); play->playerInit(this, play, &gDarkLinkSkel); this->actor.naviEnemyId = 0x26; this->cylinder.base.acFlags = AC_ON | AC_TYPE_PLAYER; - this->swordQuads[0].base.atFlags = this->swordQuads[1].base.atFlags = AT_ON | AT_TYPE_ENEMY; - this->swordQuads[0].base.acFlags = this->swordQuads[1].base.acFlags = AC_ON | AC_HARD | AC_TYPE_PLAYER; - this->swordQuads[0].base.colType = this->swordQuads[1].base.colType = COLTYPE_METAL; - this->swordQuads[0].info.toucher.damage = this->swordQuads[1].info.toucher.damage = 8; - this->swordQuads[0].info.bumperFlags = this->swordQuads[1].info.bumperFlags = BUMP_ON; + this->meleeWeaponQuads[0].base.atFlags = this->meleeWeaponQuads[1].base.atFlags = AT_ON | AT_TYPE_ENEMY; + this->meleeWeaponQuads[0].base.acFlags = this->meleeWeaponQuads[1].base.acFlags = AC_ON | AC_HARD | AC_TYPE_PLAYER; + this->meleeWeaponQuads[0].base.colType = this->meleeWeaponQuads[1].base.colType = COLTYPE_METAL; + this->meleeWeaponQuads[0].info.toucher.damage = this->meleeWeaponQuads[1].info.toucher.damage = 8; + this->meleeWeaponQuads[0].info.bumperFlags = this->meleeWeaponQuads[1].info.bumperFlags = BUMP_ON; this->shieldQuad.base.atFlags = AT_ON | AT_TYPE_ENEMY; this->shieldQuad.base.acFlags = AC_ON | AC_HARD | AC_TYPE_PLAYER; this->actor.colChkInfo.damageTable = &sDamageTable; @@ -162,11 +162,11 @@ void EnTorch2_Destroy(Actor* thisx, PlayState* play) { s32 pad; Player* this = (Player*)thisx; - Effect_Delete(play, this->swordEffectIndex); + Effect_Delete(play, this->meleeWeaponEffectIndex); func_800F5B58(); Collider_DestroyCylinder(play, &this->cylinder); - Collider_DestroyQuad(play, &this->swordQuads[0]); - Collider_DestroyQuad(play, &this->swordQuads[1]); + Collider_DestroyQuad(play, &this->meleeWeaponQuads[0]); + Collider_DestroyQuad(play, &this->meleeWeaponQuads[1]); Collider_DestroyQuad(play, &this->shieldQuad); } @@ -280,16 +280,16 @@ void EnTorch2_Update(Actor* thisx, PlayState* play2) { // Handles Dark Link's sword clanking on Link's sword - if ((this->swordQuads[0].base.acFlags & AC_BOUNCED) || (this->swordQuads[1].base.acFlags & AC_BOUNCED)) { - this->swordQuads[0].base.acFlags &= ~AC_BOUNCED; - this->swordQuads[1].base.acFlags &= ~AC_BOUNCED; - this->swordQuads[0].base.atFlags |= AT_BOUNCED; - this->swordQuads[1].base.atFlags |= AT_BOUNCED; + if ((this->meleeWeaponQuads[0].base.acFlags & AC_BOUNCED) || (this->meleeWeaponQuads[1].base.acFlags & AC_BOUNCED)) { + this->meleeWeaponQuads[0].base.acFlags &= ~AC_BOUNCED; + this->meleeWeaponQuads[1].base.acFlags &= ~AC_BOUNCED; + this->meleeWeaponQuads[0].base.atFlags |= AT_BOUNCED; + this->meleeWeaponQuads[1].base.atFlags |= AT_BOUNCED; this->cylinder.base.acFlags &= ~AC_HIT; - if (sLastSwordAnim != this->swordAnimation) { + if (sLastSwordAnim != this->meleeWeaponAnimation) { sStaggerCount++; - sLastSwordAnim = this->swordAnimation; + sLastSwordAnim = this->meleeWeaponAnimation; } /*! @bug * This code is needed to reset sCounterState, and should run regardless @@ -304,8 +304,8 @@ void EnTorch2_Update(Actor* thisx, PlayState* play2) { } } if ((sCounterState != 0) && (this->swordState != 0)) { - CollisionCheck_SetAC(play, &play->colChkCtx, &this->swordQuads[0].base); - CollisionCheck_SetAC(play, &play->colChkCtx, &this->swordQuads[1].base); + CollisionCheck_SetAC(play, &play->colChkCtx, &this->meleeWeaponQuads[0].base); + CollisionCheck_SetAC(play, &play->colChkCtx, &this->meleeWeaponQuads[1].base); } // Ignores hits when jumping on Link's sword @@ -328,7 +328,7 @@ void EnTorch2_Update(Actor* thisx, PlayState* play2) { // Handles Dark Link's initial reaction to jumpslashes if (((player->swordState != 0) || (player->actor.velocity.y > -3.0f)) && - (player->swordAnimation == JUMPSLASH_START)) { + (player->meleeWeaponAnimation == JUMPSLASH_START)) { this->actor.world.rot.y = this->actor.shape.rot.y = this->actor.yawTowardsPlayer; if (play->gameplayFrames % 2) { @@ -382,13 +382,13 @@ void EnTorch2_Update(Actor* thisx, PlayState* play2) { // Handles Dark Link's reaction to sword attack other than jumpslashes if (func_800354B4(play, &this->actor, 120.0f, 0x7FFF, 0x7FFF, this->actor.world.rot.y)) { - if ((player->swordAnimation == STAB_1H) && (this->actor.xzDistToPlayer < 90.0f)) { + if ((player->meleeWeaponAnimation == STAB_1H) && (this->actor.xzDistToPlayer < 90.0f)) { // Handles the reaction to a one-handed stab. If the conditions are satisfied, // Dark Link jumps on Link's sword. Otherwise he backflips away. if ((this->swordState == 0) && (sCounterState == 0) && (player->invincibilityTimer == 0) && - (player->swordAnimation == STAB_1H) && (this->actor.xzDistToPlayer <= 85.0f) && + (player->meleeWeaponAnimation == STAB_1H) && (this->actor.xzDistToPlayer <= 85.0f) && Actor_IsTargeted(play, &this->actor)) { sStickTilt = 0.0f; @@ -414,17 +414,17 @@ void EnTorch2_Update(Actor* thisx, PlayState* play2) { sStickAngle = thisx->yawTowardsPlayer; input->cur.button = BTN_B; - if (player->swordAnimation <= FORWARD_COMBO_2H) { + if (player->meleeWeaponAnimation <= FORWARD_COMBO_2H) { sStickTilt = 0.0f; - } else if (player->swordAnimation <= RIGHT_COMBO_2H) { + } else if (player->meleeWeaponAnimation <= RIGHT_COMBO_2H) { sStickTilt = 127.0f; sStickAngle += 0x4000; - } else if (player->swordAnimation <= LEFT_COMBO_2H) { + } else if (player->meleeWeaponAnimation <= LEFT_COMBO_2H) { sStickTilt = 127.0f; sStickAngle -= 0x4000; - } else if (player->swordAnimation <= HAMMER_SIDE) { + } else if (player->meleeWeaponAnimation <= HAMMER_SIDE) { input->cur.button = BTN_R; - } else if (player->swordAnimation <= BIG_SPIN_2H) { + } else if (player->meleeWeaponAnimation <= BIG_SPIN_2H) { EnTorch2_Backflip(this, input, &this->actor); } else { EnTorch2_Backflip(this, input, &this->actor); @@ -457,8 +457,8 @@ void EnTorch2_Update(Actor* thisx, PlayState* play2) { Math_SmoothStepToS(&sStickAngle, player->actor.shape.rot.y + 0x7FFF, 1, 0x2328, 0); } } else if (this->actor.xzDistToPlayer > 100.0f + sp50) { - if ((player->swordState == 0) || (player->swordAnimation < SPIN_ATTACK_1H) || - (player->swordAnimation > BIG_SPIN_2H) || (this->actor.xzDistToPlayer >= 280.0f)) { + if ((player->swordState == 0) || (player->meleeWeaponAnimation < SPIN_ATTACK_1H) || + (player->meleeWeaponAnimation > BIG_SPIN_2H) || (this->actor.xzDistToPlayer >= 280.0f)) { sStickTilt = 127.0f; sStickAngle = this->actor.yawTowardsPlayer; if (!this->actor.isTargeted) { @@ -557,8 +557,8 @@ void EnTorch2_Update(Actor* thisx, PlayState* play2) { // Causes Dark Link to shield in place when Link is using magic attacks other than the spin attack - if ((gSaveContext.unk_13F0 == 3) && (player->swordState == 0 || (player->swordAnimation < SPIN_ATTACK_1H) || - (player->swordAnimation > BIG_SPIN_2H))) { + if ((gSaveContext.magicState == 3) && (player->swordState == 0 || (player->meleeWeaponAnimation < SPIN_ATTACK_1H) || + (player->meleeWeaponAnimation > BIG_SPIN_2H))) { sStickTilt = 0.0f; input->cur.stick_x = 0; input->cur.stick_y = 0; @@ -589,12 +589,12 @@ void EnTorch2_Update(Actor* thisx, PlayState* play2) { if ((this->actor.colChkInfo.health == 0) && sDeathFlag) { this->csMode = 0x18; this->unk_448 = &player->actor; - this->unk_46A = 1; + this->doorBgCamIndex = 1; sDeathFlag = false; } if ((this->invincibilityTimer == 0) && (this->actor.colChkInfo.health != 0) && (this->cylinder.base.acFlags & AC_HIT) && !(this->stateFlags1 & 0x04000000) && - !(this->swordQuads[0].base.atFlags & AT_HIT) && !(this->swordQuads[1].base.atFlags & AT_HIT)) { + !(this->meleeWeaponQuads[0].base.atFlags & AT_HIT) && !(this->meleeWeaponQuads[1].base.atFlags & AT_HIT)) { if (!Actor_ApplyDamage(&this->actor)) { func_800F5B58(); @@ -704,8 +704,8 @@ void EnTorch2_Update(Actor* thisx, PlayState* play2) { this->skelAnime.curFrame = player->skelAnime.curFrame - player->skelAnime.playSpeed; this->skelAnime.playSpeed = player->skelAnime.playSpeed; LinkAnimation_Update(play, &this->skelAnime); - Collider_ResetQuadAT(play, &this->swordQuads[0].base); - Collider_ResetQuadAT(play, &this->swordQuads[1].base); + Collider_ResetQuadAT(play, &this->meleeWeaponQuads[0].base); + Collider_ResetQuadAT(play, &this->meleeWeaponQuads[1].base); } } if (sStaggerTimer != 0) { diff --git a/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c b/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c index fa3701dd6..478cd036d 100644 --- a/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c +++ b/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c @@ -294,7 +294,7 @@ s32 EnWf_ChangeAction(PlayState* play, EnWf* this, s16 mustChoose) { playerYawDiff = ABS(playerYawDiff); if (func_800354B4(play, &this->actor, 100.0f, 0x2710, 0x2EE0, this->actor.shape.rot.y)) { - if (player->swordAnimation == 0x11) { + if (player->meleeWeaponAnimation == 0x11) { EnWf_SetupBlocking(this); return true; } @@ -311,7 +311,7 @@ s32 EnWf_ChangeAction(PlayState* play, EnWf* this, s16 mustChoose) { if ((this->actor.bgCheckFlags & 8) && (ABS(wallYawDiff) < 0x2EE0) && (this->actor.xzDistToPlayer < 120.0f)) { EnWf_SetupSomersaultAndAttack(this); return true; - } else if (player->swordAnimation == 0x11) { + } else if (player->meleeWeaponAnimation == 0x11) { EnWf_SetupBlocking(this); return true; } else if ((this->actor.xzDistToPlayer < 80.0f) && (play->gameplayFrames % 2) != 0) { @@ -1021,7 +1021,7 @@ void EnWf_Blocking(EnWf* this, PlayState* play) { if ((ABS(yawDiff) <= 0x4000) && (this->actor.xzDistToPlayer < 60.0f) && (ABS(this->actor.yDistToPlayer) < 50.0f)) { if (func_800354B4(play, &this->actor, 100.0f, 10000, 0x4000, this->actor.shape.rot.y)) { - if (player->swordAnimation == 0x11) { + if (player->meleeWeaponAnimation == 0x11) { EnWf_SetupBlocking(this); } else if ((play->gameplayFrames % 2) != 0) { EnWf_SetupBlocking(this); @@ -1044,7 +1044,7 @@ void EnWf_Blocking(EnWf* this, PlayState* play) { } } else if (this->actionTimer == 0) { if (func_800354B4(play, &this->actor, 100.0f, 10000, 0x4000, this->actor.shape.rot.y)) { - if (player->swordAnimation == 0x11) { + if (player->meleeWeaponAnimation == 0x11) { EnWf_SetupBlocking(this); } else if ((play->gameplayFrames % 2) != 0) { EnWf_SetupBlocking(this); diff --git a/soh/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c b/soh/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c index fc77c5695..c881f2705 100644 --- a/soh/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c +++ b/soh/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c @@ -1808,7 +1808,7 @@ void func_80B5772C(EnZl3* this, PlayState* play) { } void func_80B57754(EnZl3* this, PlayState* play) { - if (gSaveContext.unk_13F0 == 0) { + if (gSaveContext.magicState == 0) { Actor_Spawn(&play->actorCtx, play, ACTOR_OCEFF_WIPE4, this->actor.world.pos.x, this->actor.world.pos.y, this->actor.world.pos.z, 0, 0, 0, 1); func_80B56DA4(this); diff --git a/soh/src/overlays/actors/ovl_Fishing/z_fishing.c b/soh/src/overlays/actors/ovl_Fishing/z_fishing.c index 8e07c56d4..b13333bca 100644 --- a/soh/src/overlays/actors/ovl_Fishing/z_fishing.c +++ b/soh/src/overlays/actors/ovl_Fishing/z_fishing.c @@ -5122,7 +5122,7 @@ void Fishing_HandleOwnerDialog(Fishing* this, PlayState* play) { Player* player = GET_PLAYER(play); if (gSaveContext.temporaryWeapon) { - player->currentSwordItem = ITEM_NONE; + player->currentSwordItemId = ITEM_NONE; gSaveContext.equips.buttonItems[0] = ITEM_NONE; Inventory_ChangeEquipment(EQUIP_SWORD, PLAYER_SWORD_NONE); gSaveContext.temporaryWeapon = false; diff --git a/soh/src/overlays/actors/ovl_Item_Ocarina/z_item_ocarina.c b/soh/src/overlays/actors/ovl_Item_Ocarina/z_item_ocarina.c index 73b31a90f..87231ec94 100644 --- a/soh/src/overlays/actors/ovl_Item_Ocarina/z_item_ocarina.c +++ b/soh/src/overlays/actors/ovl_Item_Ocarina/z_item_ocarina.c @@ -175,7 +175,7 @@ void ItemOcarina_StartSoTCutscene(ItemOcarina* this, PlayState* play) { } else { play->sceneLoadFlag = 0x14; play->fadeTransition = 3; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; play->nextEntranceIndex = 0x050F; gSaveContext.nextCutsceneIndex = 0; } diff --git a/soh/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c b/soh/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c index f887d18c6..b8b6f5258 100644 --- a/soh/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c +++ b/soh/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c @@ -176,8 +176,8 @@ void ObjSyokudai_Update(Actor* thisx, PlayState* play2) { if (dmgFlags & 0x20820) { interactionType = 1; } - } else if (player->heldItemActionParam == PLAYER_AP_STICK) { - Math_Vec3f_Diff(&player->swordInfo[0].tip, &this->actor.world.pos, &tipToFlame); + } else if (player->heldItemAction == PLAYER_IA_STICK) { + Math_Vec3f_Diff(&player->meleeWeaponInfo[0].tip, &this->actor.world.pos, &tipToFlame); tipToFlame.y -= 67.0f; if ((SQ(tipToFlame.x) + SQ(tipToFlame.y) + SQ(tipToFlame.z)) < SQ(20.0f)) { interactionType = -1; diff --git a/soh/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c b/soh/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c index f2a0a2221..47ab5bb47 100644 --- a/soh/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c +++ b/soh/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c @@ -72,7 +72,7 @@ void OceffSpot_Destroy(Actor* thisx, PlayState* play) { LightContext_RemoveLight(play, &play->lightCtx, this->lightNode2); func_800876C8(play); if ((gSaveContext.nayrusLoveTimer != 0) && (play->actorCtx.actorLists[ACTORCAT_PLAYER].length != 0)) { - player->stateFlags3 |= 0x40; + player->stateFlags3 |= PLAYER_STATE3_RESTORE_NAYRUS_LOVE; } } diff --git a/soh/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c b/soh/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c index 852d85dc7..d7a26ec7b 100644 --- a/soh/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c +++ b/soh/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c @@ -62,7 +62,7 @@ void OceffStorm_Destroy(Actor* thisx, PlayState* play) { func_800876C8(play); if (gSaveContext.nayrusLoveTimer != 0) { - player->stateFlags3 |= 0x40; + player->stateFlags3 |= PLAYER_STATE3_RESTORE_NAYRUS_LOVE; } } diff --git a/soh/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c b/soh/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c index 4234f3cb2..20418881a 100644 --- a/soh/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c +++ b/soh/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c @@ -42,7 +42,7 @@ void OceffWipe_Destroy(Actor* thisx, PlayState* play) { func_800876C8(play); if (gSaveContext.nayrusLoveTimer != 0) { - player->stateFlags3 |= 0x40; + player->stateFlags3 |= PLAYER_STATE3_RESTORE_NAYRUS_LOVE; } } diff --git a/soh/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c b/soh/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c index 634f58a38..bec266db4 100644 --- a/soh/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c +++ b/soh/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c @@ -42,7 +42,7 @@ void OceffWipe2_Destroy(Actor* thisx, PlayState* play) { func_800876C8(play); if (gSaveContext.nayrusLoveTimer != 0) { - player->stateFlags3 |= 0x40; + player->stateFlags3 |= PLAYER_STATE3_RESTORE_NAYRUS_LOVE; } } diff --git a/soh/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c b/soh/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c index 09a5a5aaf..3638b31b2 100644 --- a/soh/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c +++ b/soh/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c @@ -45,7 +45,7 @@ void OceffWipe3_Destroy(Actor* thisx, PlayState* play) { func_800876C8(play); if (gSaveContext.nayrusLoveTimer != 0) { - player->stateFlags3 |= 0x40; + player->stateFlags3 |= PLAYER_STATE3_RESTORE_NAYRUS_LOVE; } } diff --git a/soh/src/overlays/actors/ovl_player_actor/z_player.c b/soh/src/overlays/actors/ovl_player_actor/z_player.c index ab26ee623..3190e5eeb 100644 --- a/soh/src/overlays/actors/ovl_player_actor/z_player.c +++ b/soh/src/overlays/actors/ovl_player_actor/z_player.c @@ -980,77 +980,77 @@ static u8 D_80853E7C[] = { // Used to map item IDs to action params static s8 sItemActionParams[] = { - PLAYER_AP_STICK, - PLAYER_AP_NUT, - PLAYER_AP_BOMB, - PLAYER_AP_BOW, - PLAYER_AP_BOW_FIRE, - PLAYER_AP_DINS_FIRE, - PLAYER_AP_SLINGSHOT, - PLAYER_AP_OCARINA_FAIRY, - PLAYER_AP_OCARINA_TIME, - PLAYER_AP_BOMBCHU, - PLAYER_AP_HOOKSHOT, - PLAYER_AP_LONGSHOT, - PLAYER_AP_BOW_ICE, - PLAYER_AP_FARORES_WIND, - PLAYER_AP_BOOMERANG, - PLAYER_AP_LENS, - PLAYER_AP_BEAN, - PLAYER_AP_HAMMER, - PLAYER_AP_BOW_LIGHT, - PLAYER_AP_NAYRUS_LOVE, - PLAYER_AP_BOTTLE, - PLAYER_AP_BOTTLE_POTION_RED, - PLAYER_AP_BOTTLE_POTION_GREEN, - PLAYER_AP_BOTTLE_POTION_BLUE, - PLAYER_AP_BOTTLE_FAIRY, - PLAYER_AP_BOTTLE_FISH, - PLAYER_AP_BOTTLE_MILK, - PLAYER_AP_BOTTLE_LETTER, - PLAYER_AP_BOTTLE_FIRE, - PLAYER_AP_BOTTLE_BUG, - PLAYER_AP_BOTTLE_BIG_POE, - PLAYER_AP_BOTTLE_MILK_HALF, - PLAYER_AP_BOTTLE_POE, - PLAYER_AP_WEIRD_EGG, - PLAYER_AP_CHICKEN, - PLAYER_AP_LETTER_ZELDA, - PLAYER_AP_MASK_KEATON, - PLAYER_AP_MASK_SKULL, - PLAYER_AP_MASK_SPOOKY, - PLAYER_AP_MASK_BUNNY, - PLAYER_AP_MASK_GORON, - PLAYER_AP_MASK_ZORA, - PLAYER_AP_MASK_GERUDO, - PLAYER_AP_MASK_TRUTH, - PLAYER_AP_SWORD_MASTER, - PLAYER_AP_POCKET_EGG, - PLAYER_AP_POCKET_CUCCO, - PLAYER_AP_COJIRO, - PLAYER_AP_ODD_MUSHROOM, - PLAYER_AP_ODD_POTION, - PLAYER_AP_SAW, - PLAYER_AP_SWORD_BROKEN, - PLAYER_AP_PRESCRIPTION, - PLAYER_AP_FROG, - PLAYER_AP_EYEDROPS, - PLAYER_AP_CLAIM_CHECK, - PLAYER_AP_BOW_FIRE, - PLAYER_AP_BOW_ICE, - PLAYER_AP_BOW_LIGHT, - PLAYER_AP_SWORD_KOKIRI, - PLAYER_AP_SWORD_MASTER, - PLAYER_AP_SWORD_BGS, - PLAYER_AP_SHIELD_DEKU, - PLAYER_AP_SHIELD_HYLIAN, - PLAYER_AP_SHIELD_MIRROR, - PLAYER_AP_TUNIC_KOKIRI, - PLAYER_AP_TUNIC_GORON, - PLAYER_AP_TUNIC_ZORA, - PLAYER_AP_BOOTS_KOKIRI, - PLAYER_AP_BOOTS_IRON, - PLAYER_AP_BOOTS_HOVER, + PLAYER_IA_STICK, + PLAYER_IA_NUT, + PLAYER_IA_BOMB, + PLAYER_IA_BOW, + PLAYER_IA_BOW_FIRE, + PLAYER_IA_DINS_FIRE, + PLAYER_IA_SLINGSHOT, + PLAYER_IA_OCARINA_FAIRY, + PLAYER_IA_OCARINA_TIME, + PLAYER_IA_BOMBCHU, + PLAYER_IA_HOOKSHOT, + PLAYER_IA_LONGSHOT, + PLAYER_IA_BOW_ICE, + PLAYER_IA_FARORES_WIND, + PLAYER_IA_BOOMERANG, + PLAYER_IA_LENS, + PLAYER_IA_BEAN, + PLAYER_IA_HAMMER, + PLAYER_IA_BOW_LIGHT, + PLAYER_IA_NAYRUS_LOVE, + PLAYER_IA_BOTTLE, + PLAYER_IA_BOTTLE_POTION_RED, + PLAYER_IA_BOTTLE_POTION_GREEN, + PLAYER_IA_BOTTLE_POTION_BLUE, + PLAYER_IA_BOTTLE_FAIRY, + PLAYER_IA_BOTTLE_FISH, + PLAYER_IA_BOTTLE_MILK, + PLAYER_IA_BOTTLE_LETTER, + PLAYER_IA_BOTTLE_FIRE, + PLAYER_IA_BOTTLE_BUG, + PLAYER_IA_BOTTLE_BIG_POE, + PLAYER_IA_BOTTLE_MILK_HALF, + PLAYER_IA_BOTTLE_POE, + PLAYER_IA_WEIRD_EGG, + PLAYER_IA_CHICKEN, + PLAYER_IA_LETTER_ZELDA, + PLAYER_IA_MASK_KEATON, + PLAYER_IA_MASK_SKULL, + PLAYER_IA_MASK_SPOOKY, + PLAYER_IA_MASK_BUNNY, + PLAYER_IA_MASK_GORON, + PLAYER_IA_MASK_ZORA, + PLAYER_IA_MASK_GERUDO, + PLAYER_IA_MASK_TRUTH, + PLAYER_IA_SWORD_MASTER, + PLAYER_IA_POCKET_EGG, + PLAYER_IA_POCKET_CUCCO, + PLAYER_IA_COJIRO, + PLAYER_IA_ODD_MUSHROOM, + PLAYER_IA_ODD_POTION, + PLAYER_IA_SAW, + PLAYER_IA_SWORD_BROKEN, + PLAYER_IA_PRESCRIPTION, + PLAYER_IA_FROG, + PLAYER_IA_EYEDROPS, + PLAYER_IA_CLAIM_CHECK, + PLAYER_IA_BOW_FIRE, + PLAYER_IA_BOW_ICE, + PLAYER_IA_BOW_LIGHT, + PLAYER_IA_SWORD_KOKIRI, + PLAYER_IA_SWORD_MASTER, + PLAYER_IA_SWORD_BGS, + PLAYER_IA_SHIELD_DEKU, + PLAYER_IA_SHIELD_HYLIAN, + PLAYER_IA_SHIELD_MIRROR, + PLAYER_IA_TUNIC_KOKIRI, + PLAYER_IA_TUNIC_GORON, + PLAYER_IA_TUNIC_ZORA, + PLAYER_IA_BOOTS_KOKIRI, + PLAYER_IA_BOOTS_IRON, + PLAYER_IA_BOOTS_HOVER, }; static u8 sMaskMemory; @@ -1317,17 +1317,17 @@ void func_808322FC(Player* this) { void func_80832318(Player* this) { this->stateFlags2 &= ~PLAYER_STATE2_17; this->swordState = 0; - this->swordInfo[0].active = this->swordInfo[1].active = this->swordInfo[2].active = 0; + this->meleeWeaponInfo[0].active = this->meleeWeaponInfo[1].active = this->meleeWeaponInfo[2].active = 0; } void func_80832340(PlayState* play, Player* this) { Camera* camera; - if (this->unk_46C != SUBCAM_NONE) { - camera = play->cameraPtrs[this->unk_46C]; + if (this->subCamId != SUBCAM_NONE) { + camera = play->cameraPtrs[this->subCamId]; if ((camera != NULL) && (camera->csId == 1100)) { - OnePointCutscene_EndCutscene(play, this->unk_46C); - this->unk_46C = SUBCAM_NONE; + OnePointCutscene_EndCutscene(play, this->subCamId); + this->subCamId = SUBCAM_NONE; } } @@ -1346,7 +1346,7 @@ void func_808323B4(PlayState* play, Player* this) { } if (Player_GetExplosiveHeld(this) >= 0) { - func_8083399C(play, this, PLAYER_AP_NONE); + func_8083399C(play, this, PLAYER_IA_NONE); this->heldItemId = ITEM_NONE_FE; } } @@ -1370,7 +1370,7 @@ void func_80832440(PlayState* play, Player* this) { func_8005B1A4(Play_GetCamera(play, 0)); this->stateFlags1 &= ~(PLAYER_STATE1_13 | PLAYER_STATE1_14 | PLAYER_STATE1_20 | PLAYER_STATE1_21); - this->stateFlags2 &= ~(PLAYER_STATE2_4 | PLAYER_STATE2_7 | PLAYER_STATE2_18); + this->stateFlags2 &= ~(PLAYER_STATE2_4 | PLAYER_STATE2_7 | PLAYER_STATE2_CRAWLING); this->actor.shape.rot.x = 0; this->actor.shape.yOffset = 0.0f; @@ -1379,7 +1379,7 @@ void func_80832440(PlayState* play, Player* this) { } s32 func_80832528(PlayState* play, Player* this) { - if (this->heldItemActionParam >= PLAYER_AP_FISHING_POLE) { + if (this->heldItemAction >= PLAYER_IA_FISHING_POLE) { func_80835F44(play, this, ITEM_NONE); return 1; } else { @@ -1463,7 +1463,7 @@ void func_808327F8(Player* this, f32 arg1) { // Gameplay stats: Count footsteps // Only count while game isn't complete and don't count Link's idle animations or crawling in crawlspaces if (!gSaveContext.sohStats.gameComplete && !(this->stateFlags2 & PLAYER_STATE2_28) && - !(this->stateFlags2 & PLAYER_STATE2_18)) { + !(this->stateFlags2 & PLAYER_STATE2_CRAWLING)) { gSaveContext.sohStats.count[COUNT_STEPS]++; } } @@ -1832,11 +1832,11 @@ void func_80833664(PlayState* play, Player* this, s8 actionParam) { s8 Player_ItemToActionParam(s32 item) { if (item >= ITEM_NONE_FE) { - return PLAYER_AP_NONE; + return PLAYER_IA_NONE; } else if (item == ITEM_LAST_USED) { - return PLAYER_AP_LAST_USED; + return PLAYER_IA_LAST_USED; } else if (item == ITEM_FISHING_POLE) { - return PLAYER_AP_FISHING_POLE; + return PLAYER_IA_FISHING_POLE; } else { return sItemActionParams[item]; } @@ -1855,7 +1855,7 @@ void func_80833790(PlayState* play, Player* this) { void func_8083379C(PlayState* play, Player* this) { this->stateFlags1 |= PLAYER_STATE1_3; - if (this->heldItemActionParam != PLAYER_AP_SLINGSHOT) { + if (this->heldItemAction != PLAYER_IA_SLINGSHOT) { this->unk_860 = -1; } else { this->unk_860 = -2; @@ -1917,7 +1917,7 @@ void func_8083399C(PlayState* play, Player* this, s8 actionParam) { this->unk_85C = 0.0f; this->unk_858 = 0.0f; - this->heldItemActionParam = this->itemActionParam = actionParam; + this->heldItemAction = this->itemAction = actionParam; this->modelGroup = this->nextModelGroup; this->stateFlags1 &= ~(PLAYER_STATE1_3 | PLAYER_STATE1_24); @@ -1932,16 +1932,16 @@ void func_80833A20(Player* this, s32 newSwordState) { u16 voiceSfx; if (this->swordState == 0) { - if ((this->heldItemActionParam == PLAYER_AP_SWORD_BGS) && (gSaveContext.swordHealth > 0.0f)) { + if ((this->heldItemAction == PLAYER_IA_SWORD_BGS) && (gSaveContext.swordHealth > 0.0f)) { itemSfx = NA_SE_IT_HAMMER_SWING; } else { itemSfx = NA_SE_IT_SWORD_SWING; } voiceSfx = NA_SE_VO_LI_SWORD_N; - if (this->heldItemActionParam == PLAYER_AP_HAMMER) { + if (this->heldItemAction == PLAYER_IA_HAMMER) { itemSfx = NA_SE_IT_HAMMER_SWING; - } else if (this->swordAnimation >= 0x18) { + } else if (this->meleeWeaponAnimation >= 0x18) { itemSfx = 0; voiceSfx = NA_SE_VO_LI_SWORD_L; } else if (this->unk_845 >= 3) { @@ -1953,11 +1953,11 @@ void func_80833A20(Player* this, s32 newSwordState) { func_808328EC(this, itemSfx); } - if ((this->swordAnimation < 0x10) || (this->swordAnimation >= 0x14)) { + if ((this->meleeWeaponAnimation < 0x10) || (this->meleeWeaponAnimation >= 0x14)) { func_80832698(this, voiceSfx); } - if (this->heldItemActionParam >= PLAYER_AP_SWORD_MASTER && this->heldItemActionParam <= PLAYER_AP_SWORD_BGS) { + if (this->heldItemAction >= PLAYER_IA_SWORD_MASTER && this->heldItemAction <= PLAYER_IA_SWORD_BGS) { gSaveContext.sohStats.count[COUNT_SWORD_SWINGS]++; } } @@ -2002,7 +2002,7 @@ void func_80833C3C(Player* this) { } s32 func_80833C50(Player* this, s32 item) { - if ((item < ITEM_NONE_FE) && (Player_ItemToActionParam(item) == this->itemActionParam)) { + if ((item < ITEM_NONE_FE) && (Player_ItemToActionParam(item) == this->itemAction)) { return 1; } else { return 0; @@ -2063,7 +2063,7 @@ void func_80833DF8(Player* this, PlayState* play) { func_808328EC(this, NA_SE_PL_CHANGE_ARMS); } } else { - maskActionParam = this->currentMask - 1 + PLAYER_AP_MASK_KEATON; + maskActionParam = this->currentMask - 1 + PLAYER_IA_MASK_KEATON; bool hasOnDpad = false; if (CVar_GetS32("gDpadEquips", 0) != 0) { for (int buttonIndex = 0; buttonIndex < 4; buttonIndex++) { @@ -2078,7 +2078,7 @@ void func_80833DF8(Player* this, PlayState* play) { } if (!(this->stateFlags1 & (PLAYER_STATE1_11 | PLAYER_STATE1_29)) && !func_8008F128(this)) { - if (this->itemActionParam >= PLAYER_AP_FISHING_POLE) { + if (this->itemAction >= PLAYER_IA_FISHING_POLE) { bool hasOnDpad = false; if (CVar_GetS32("gDpadEquips", 0) != 0) { for (int buttonIndex = 0; buttonIndex < 4; buttonIndex++) { @@ -2107,7 +2107,7 @@ void func_80833DF8(Player* this, PlayState* play) { } item = func_80833CDC(play, i); - if ((item < ITEM_NONE_FE) && (Player_ItemToActionParam(item) == this->heldItemActionParam)) { + if ((item < ITEM_NONE_FE) && (Player_ItemToActionParam(item) == this->heldItemAction)) { D_80853618 = true; } } else { @@ -2132,10 +2132,10 @@ void func_808340DC(Player* this, PlayState* play) { nextAnimType = gPlayerModelTypes[this->nextModelGroup][PLAYER_MODELGROUPENTRY_ANIM]; sp38 = D_80854164[gPlayerModelTypes[this->modelGroup][PLAYER_MODELGROUPENTRY_ANIM]][nextAnimType]; - if ((sp37 == PLAYER_AP_BOTTLE) || (sp37 == PLAYER_AP_BOOMERANG) || - ((sp37 == PLAYER_AP_NONE) && - ((this->heldItemActionParam == PLAYER_AP_BOTTLE) || (this->heldItemActionParam == PLAYER_AP_BOOMERANG)))) { - sp38 = (sp37 == PLAYER_AP_NONE) ? -PLAYER_D_808540F4_13 : PLAYER_D_808540F4_13; + if ((sp37 == PLAYER_IA_BOTTLE) || (sp37 == PLAYER_IA_BOOMERANG) || + ((sp37 == PLAYER_IA_NONE) && + ((this->heldItemAction == PLAYER_IA_BOTTLE) || (this->heldItemAction == PLAYER_IA_BOOMERANG)))) { + sp38 = (sp37 == PLAYER_IA_NONE) ? -PLAYER_D_808540F4_13 : PLAYER_D_808540F4_13; } this->unk_15A = ABS(sp38); @@ -2157,7 +2157,7 @@ void func_808340DC(Player* this, PlayState* play) { startFrame = frameCount; } - if (sp37 != PLAYER_AP_NONE) { + if (sp37 != PLAYER_IA_NONE) { playSpeed *= 2.0f; } @@ -2168,7 +2168,7 @@ void func_808340DC(Player* this, PlayState* play) { void func_80834298(Player* this, PlayState* play) { if ((this->actor.category == ACTORCAT_PLAYER) && !(this->stateFlags1 & PLAYER_STATE1_8) && - ((this->heldItemActionParam == this->itemActionParam) || (this->stateFlags1 & PLAYER_STATE1_22)) && + ((this->heldItemAction == this->itemAction) || (this->stateFlags1 & PLAYER_STATE1_22)) && (gSaveContext.health != 0) && (play->csCtx.state == CS_STATE_IDLE) && (this->csMode == 0) && (play->shootingGalleryStatus == 0) && (play->activeCamera == MAIN_CAM) && (play->sceneLoadFlag != 0x14) && (gSaveContext.timer1State != 10)) { @@ -2187,7 +2187,7 @@ s32 func_80834380(PlayState* play, Player* this, s32* itemPtr, s32* typePtr) { if (this->stateFlags1 & PLAYER_STATE1_23) { *typePtr = ARROW_NORMAL_HORSE; } else { - *typePtr = this->heldItemActionParam - 6; + *typePtr = this->heldItemAction - 6; } } else { *itemPtr = ITEM_SLINGSHOT; @@ -2209,8 +2209,8 @@ s32 func_8083442C(Player* this, PlayState* play) { s32 arrowType; s32 magicArrowType; - if ((this->heldItemActionParam >= PLAYER_AP_BOW_FIRE) && (this->heldItemActionParam <= PLAYER_AP_BOW_0E) && - (gSaveContext.unk_13F0 != 0)) { + if ((this->heldItemAction >= PLAYER_IA_BOW_FIRE) && (this->heldItemAction <= PLAYER_IA_BOW_0E) && + (gSaveContext.magicState != 0)) { func_80078884(NA_SE_SY_ERROR); } else { func_80833638(this, func_808351D4); @@ -2244,8 +2244,8 @@ s32 func_8083442C(Player* this, PlayState* play) { } void func_80834594(PlayState* play, Player* this) { - if (this->heldItemActionParam != PLAYER_AP_NONE) { - if (func_8008F2BC(this, this->heldItemActionParam) >= 0) { + if (this->heldItemAction != PLAYER_IA_NONE) { + if (func_8008F2BC(this, this->heldItemAction) >= 0) { func_808328EC(this, NA_SE_IT_SWORD_PUTAWAY); } else { func_808328EC(this, NA_SE_PL_CHANGE_ARMS); @@ -2254,9 +2254,9 @@ void func_80834594(PlayState* play, Player* this) { func_80835F44(play, this, this->heldItemId); - if (func_8008F2BC(this, this->heldItemActionParam) >= 0) { + if (func_8008F2BC(this, this->heldItemAction) >= 0) { func_808328EC(this, NA_SE_IT_SWORD_PICKOUT); - } else if (this->heldItemActionParam != PLAYER_AP_NONE) { + } else if (this->heldItemAction != PLAYER_IA_NONE) { func_808328EC(this, NA_SE_PL_CHANGE_ARMS); } } @@ -2266,7 +2266,7 @@ void func_80834644(PlayState* play, Player* this) { func_80834594(play, this); } - func_80833638(this, D_80853EDC[this->heldItemActionParam]); + func_80833638(this, D_80853EDC[this->heldItemAction]); this->unk_834 = 0; this->unk_6AC = 0; func_808323B4(play, this); @@ -2279,10 +2279,10 @@ LinkAnimationHeader* func_808346C4(PlayState* play, Player* this) { if (this->unk_870 < 0.5f) { return D_808543A4[Player_HoldsTwoHandedWeapon(this) && - !(CVar_GetS32("gShieldTwoHanded", 0) && (this->heldItemActionParam != PLAYER_AP_STICK))]; + !(CVar_GetS32("gShieldTwoHanded", 0) && (this->heldItemAction != PLAYER_IA_STICK))]; } else { return D_808543AC[Player_HoldsTwoHandedWeapon(this) && - !(CVar_GetS32("gShieldTwoHanded", 0) && (this->heldItemActionParam != PLAYER_AP_STICK))]; + !(CVar_GetS32("gShieldTwoHanded", 0) && (this->heldItemAction != PLAYER_IA_STICK))]; } } @@ -2291,7 +2291,7 @@ s32 func_80834758(PlayState* play, Player* this) { f32 frame; if (!(this->stateFlags1 & (PLAYER_STATE1_22 | PLAYER_STATE1_23 | PLAYER_STATE1_29)) && - (play->shootingGalleryStatus == 0) && (this->heldItemActionParam == this->itemActionParam) && + (play->shootingGalleryStatus == 0) && (this->heldItemAction == this->itemAction) && (this->currentShield != PLAYER_SHIELD_NONE) && !Player_IsChildWithHylianShield(this) && func_80833BCC(this) && CHECK_BTN_ALL(sControlInput->cur.button, BTN_R)) { @@ -2317,7 +2317,7 @@ s32 func_8083485C(Player* this, PlayState* play) { void func_80834894(Player* this) { func_80833638(this, func_80834C74); - if (this->itemActionParam < 0) { + if (this->itemAction < 0) { func_8008EC70(this); } @@ -2359,10 +2359,10 @@ s32 func_808349DC(Player* this, PlayState* play) { s32 func_80834A2C(Player* this, PlayState* play) { if (LinkAnimation_Update(play, &this->skelAnime2) || - ((Player_ItemToActionParam(this->heldItemId) == this->heldItemActionParam) && + ((Player_ItemToActionParam(this->heldItemId) == this->heldItemAction) && (D_80853614 = (D_80853614 || ((this->modelAnimType != PLAYER_ANIMTYPE_3) && (play->shootingGalleryStatus == 0)))))) { - func_80833638(this, D_80853EDC[this->heldItemActionParam]); + func_80833638(this, D_80853EDC[this->heldItemAction]); this->unk_834 = 0; this->unk_6AC = 0; D_80853618 = D_80853614; @@ -2413,7 +2413,7 @@ s32 func_80834C74(Player* this, PlayState* play) { D_80853614 = D_80853618; if (D_80853614 || LinkAnimation_Update(play, &this->skelAnime2)) { - func_80833638(this, D_80853EDC[this->heldItemActionParam]); + func_80833638(this, D_80853EDC[this->heldItemAction]); LinkAnimation_PlayLoop(play, &this->skelAnime2, D_80853914[PLAYER_ANIMGROUP_0][this->modelAnimType]); this->unk_6AC = 0; this->func_82C(this, play); @@ -2426,7 +2426,7 @@ s32 func_80834C74(Player* this, PlayState* play) { s32 func_80834D2C(Player* this, PlayState* play) { LinkAnimationHeader* anim; - if (this->heldItemActionParam != PLAYER_AP_BOOMERANG) { + if (this->heldItemAction != PLAYER_IA_BOOMERANG) { if (!func_8083442C(this, play)) { return 0; } @@ -2838,7 +2838,7 @@ s32 func_80835C58(PlayState* play, Player* this, PlayerFunc674 func, s32 flags) this->func_674 = func; - if ((this->itemActionParam != this->heldItemActionParam) && + if ((this->itemAction != this->heldItemAction) && (!(flags & 1) || !(this->stateFlags1 & PLAYER_STATE1_22))) { func_8008EC70(this); } @@ -2873,12 +2873,12 @@ void func_80835DAC(PlayState* play, Player* this, PlayerFunc674 func, s32 flags) void func_80835DE4(PlayState* play, Player* this, PlayerFunc674 func, s32 flags) { s32 temp; - if (this->itemActionParam >= 0) { - temp = this->itemActionParam; - this->itemActionParam = this->heldItemActionParam; + if (this->itemAction >= 0) { + temp = this->itemAction; + this->itemAction = this->heldItemAction; func_80835C58(play, this, func, flags); - this->itemActionParam = temp; - Player_SetModels(this, Player_ActionToModelGroup(this, this->itemActionParam)); + this->itemAction = temp; + Player_SetModels(this, Player_ActionToModelGroup(this, this->itemAction)); } } @@ -2916,20 +2916,20 @@ void func_80835F44(PlayState* play, Player* this, s32 item) { actionParam = Player_ItemToActionParam(item); - if (((this->heldItemActionParam == this->itemActionParam) && + if (((this->heldItemAction == this->itemAction) && (!(this->stateFlags1 & PLAYER_STATE1_22) || (Player_ActionToSword(actionParam) != 0) || - (actionParam == PLAYER_AP_NONE))) || - ((this->itemActionParam < 0) && - ((Player_ActionToSword(actionParam) != 0) || (actionParam == PLAYER_AP_NONE)))) { + (actionParam == PLAYER_IA_NONE))) || + ((this->itemAction < 0) && + ((Player_ActionToSword(actionParam) != 0) || (actionParam == PLAYER_IA_NONE)))) { - if ((actionParam == PLAYER_AP_NONE) || !(this->stateFlags1 & PLAYER_STATE1_27) || + if ((actionParam == PLAYER_IA_NONE) || !(this->stateFlags1 & PLAYER_STATE1_27) || ((this->actor.bgCheckFlags & 1) && - ((actionParam == PLAYER_AP_HOOKSHOT) || (actionParam == PLAYER_AP_LONGSHOT))) || - ((actionParam >= PLAYER_AP_SHIELD_DEKU) && (actionParam <= PLAYER_AP_BOOTS_HOVER))) { + ((actionParam == PLAYER_IA_HOOKSHOT) || (actionParam == PLAYER_IA_LONGSHOT))) || + ((actionParam >= PLAYER_IA_SHIELD_DEKU) && (actionParam <= PLAYER_IA_BOOTS_HOVER))) { if ((play->bombchuBowlingStatus == 0) && - (((actionParam == PLAYER_AP_STICK) && (AMMO(ITEM_STICK) == 0)) || - ((actionParam == PLAYER_AP_BEAN) && (AMMO(ITEM_BEAN) == 0)) || + (((actionParam == PLAYER_IA_STICK) && (AMMO(ITEM_STICK) == 0)) || + ((actionParam == PLAYER_IA_BEAN) && (AMMO(ITEM_BEAN) == 0)) || (temp = Player_ActionToExplosive(this, actionParam), ((temp >= 0) && ((AMMO(sExplosiveInfos[temp].itemId) == 0) || (play->actorCtx.actorLists[ACTORCAT_EXPLOSIVE].length >= 3)))))) { @@ -2937,8 +2937,8 @@ void func_80835F44(PlayState* play, Player* this, s32 item) { return; } - if (actionParam >= PLAYER_AP_BOOTS_KOKIRI) { - u16 bootsValue = actionParam - PLAYER_AP_BOOTS_KOKIRI + 1; + if (actionParam >= PLAYER_IA_BOOTS_KOKIRI) { + u16 bootsValue = actionParam - PLAYER_IA_BOOTS_KOKIRI + 1; if (CUR_EQUIP_VALUE(EQUIP_BOOTS) == bootsValue) { Inventory_ChangeEquipment(EQUIP_BOOTS, PLAYER_BOOTS_KOKIRI + 1); } else { @@ -2950,8 +2950,8 @@ void func_80835F44(PlayState* play, Player* this, s32 item) { return; } - if (actionParam >= PLAYER_AP_TUNIC_KOKIRI) { - u16 tunicValue = actionParam - PLAYER_AP_TUNIC_KOKIRI + 1; + if (actionParam >= PLAYER_IA_TUNIC_KOKIRI) { + u16 tunicValue = actionParam - PLAYER_IA_TUNIC_KOKIRI + 1; if (CUR_EQUIP_VALUE(EQUIP_TUNIC) == tunicValue) { Inventory_ChangeEquipment(EQUIP_TUNIC, PLAYER_TUNIC_KOKIRI + 1); } else { @@ -2962,12 +2962,12 @@ void func_80835F44(PlayState* play, Player* this, s32 item) { return; } - if (actionParam >= PLAYER_AP_SHIELD_DEKU) { + if (actionParam >= PLAYER_IA_SHIELD_DEKU) { // Changing shields through action commands is unimplemented return; } - if (actionParam == PLAYER_AP_LENS) { + if (actionParam == PLAYER_IA_LENS) { if (func_80087708(play, 0, 3)) { if (play->actorCtx.lensActive) { Actor_DisableLens(play); @@ -2981,7 +2981,7 @@ void func_80835F44(PlayState* play, Player* this, s32 item) { return; } - if (actionParam == PLAYER_AP_NUT) { + if (actionParam == PLAYER_IA_NUT) { if (AMMO(ITEM_NUT) != 0) { func_8083C61C(play, this); } else { @@ -2992,10 +2992,10 @@ void func_80835F44(PlayState* play, Player* this, s32 item) { temp = Player_ActionToMagicSpell(this, actionParam); if (temp >= 0) { - if (((actionParam == PLAYER_AP_FARORES_WIND) && (gSaveContext.respawn[RESPAWN_MODE_TOP].data > 0)) || - ((gSaveContext.unk_13F4 != 0) && (gSaveContext.unk_13F0 == 0) && + if (((actionParam == PLAYER_IA_FARORES_WIND) && (gSaveContext.respawn[RESPAWN_MODE_TOP].data > 0)) || + ((gSaveContext.magicCapacity != 0) && (gSaveContext.magicState == 0) && (gSaveContext.magic >= sMagicSpellCosts[temp]))) { - this->itemActionParam = actionParam; + this->itemAction = actionParam; this->unk_6AD = 4; } else { func_80078884(NA_SE_SY_ERROR); @@ -3003,39 +3003,39 @@ void func_80835F44(PlayState* play, Player* this, s32 item) { return; } - if (actionParam >= PLAYER_AP_MASK_KEATON) { + if (actionParam >= PLAYER_IA_MASK_KEATON) { if (this->currentMask != PLAYER_MASK_NONE) { this->currentMask = PLAYER_MASK_NONE; } else { - this->currentMask = actionParam - PLAYER_AP_MASK_KEATON + 1; + this->currentMask = actionParam - PLAYER_IA_MASK_KEATON + 1; } sMaskMemory = this->currentMask; func_808328EC(this, NA_SE_PL_CHANGE_ARMS); return; } - if (((actionParam >= PLAYER_AP_OCARINA_FAIRY) && (actionParam <= PLAYER_AP_OCARINA_TIME)) || - (actionParam >= PLAYER_AP_BOTTLE_FISH)) { + if (((actionParam >= PLAYER_IA_OCARINA_FAIRY) && (actionParam <= PLAYER_IA_OCARINA_TIME)) || + (actionParam >= PLAYER_IA_BOTTLE_FISH)) { if (!func_8008E9C4(this) || - ((actionParam >= PLAYER_AP_BOTTLE_POTION_RED) && (actionParam <= PLAYER_AP_BOTTLE_FAIRY))) { + ((actionParam >= PLAYER_IA_BOTTLE_POTION_RED) && (actionParam <= PLAYER_IA_BOTTLE_FAIRY))) { func_8002D53C(play, &play->actorCtx.titleCtx); this->unk_6AD = 4; - this->itemActionParam = actionParam; + this->itemAction = actionParam; } return; } - if ((actionParam != this->heldItemActionParam) || + if ((actionParam != this->heldItemAction) || ((this->heldActor == 0) && (Player_ActionToExplosive(this, actionParam) >= 0))) { this->nextModelGroup = Player_ActionToModelGroup(this, actionParam); nextAnimType = gPlayerModelTypes[this->nextModelGroup][PLAYER_MODELGROUPENTRY_ANIM]; - if ((this->heldItemActionParam >= 0) && (Player_ActionToMagicSpell(this, actionParam) < 0) && + if ((this->heldItemAction >= 0) && (Player_ActionToMagicSpell(this, actionParam) < 0) && (item != this->heldItemId) && (D_80854164[gPlayerModelTypes[this->modelGroup][PLAYER_MODELGROUPENTRY_ANIM]][nextAnimType] != PLAYER_D_808540F4_0) && (!CVar_GetS32("gSeparateArrows", 0) || - actionParam < PLAYER_AP_BOW || actionParam > PLAYER_AP_BOW_0E || - this->heldItemActionParam < PLAYER_AP_BOW || this->heldItemActionParam > PLAYER_AP_BOW_0E)) { + actionParam < PLAYER_IA_BOW || actionParam > PLAYER_IA_BOW_0E || + this->heldItemAction < PLAYER_IA_BOW || this->heldItemAction > PLAYER_IA_BOW_0E)) { this->heldItemId = item; this->stateFlags1 |= PLAYER_STATE1_8; } else { @@ -3092,7 +3092,7 @@ s32 func_808365C8(Player* this) { ((this->stateFlags1 & PLAYER_STATE1_8) && ((this->heldItemId == ITEM_LAST_USED) || (this->heldItemId == ITEM_NONE)))) && (!(func_80834A2C == this->func_82C) || - (Player_ItemToActionParam(this->heldItemId) == this->heldItemActionParam)); + (Player_ItemToActionParam(this->heldItemId) == this->heldItemAction)); } s32 func_80836670(Player* this, PlayState* play) { @@ -3245,7 +3245,7 @@ void func_80836BEC(Player* this, PlayState* play) { if (cond || (this->unk_66C != 0) || (this->stateFlags1 & (PLAYER_STATE1_12 | PLAYER_STATE1_25))) { if (!cond) { if (!(this->stateFlags1 & PLAYER_STATE1_25) && - ((this->heldItemActionParam != PLAYER_AP_FISHING_POLE) || (this->unk_860 == 0)) && + ((this->heldItemAction != PLAYER_IA_FISHING_POLE) || (this->unk_860 == 0)) && CHECK_BTN_ALL(sControlInput->press.button, BTN_Z)) { if (this->actor.category == ACTORCAT_PLAYER) { @@ -3476,7 +3476,7 @@ s32 func_808375D8(Player* this) { s8 temp2; s32 i; - if ((this->heldItemActionParam == PLAYER_AP_STICK) || Player_HoldsBrokenKnife(this)) { + if ((this->heldItemAction == PLAYER_IA_STICK) || Player_HoldsBrokenKnife(this)) { return 0; } @@ -3508,7 +3508,7 @@ s32 func_808375D8(Player* this) { void func_80837704(PlayState* play, Player* this) { LinkAnimationHeader* anim; - if ((this->swordAnimation >= 4) && (this->swordAnimation < 8)) { + if ((this->meleeWeaponAnimation >= 4) && (this->meleeWeaponAnimation < 8)) { anim = D_80854358[Player_HoldsTwoHandedWeapon(this)]; } else { anim = D_80854350[Player_HoldsTwoHandedWeapon(this)]; @@ -3532,7 +3532,7 @@ s32 func_80837818(Player* this) { s32 sp1C = this->unk_84B[this->unk_846]; s32 sp18; - if (this->heldItemActionParam == PLAYER_AP_HAMMER) { + if (this->heldItemAction == PLAYER_IA_HAMMER) { if (sp1C < 0) { sp1C = 0; } @@ -3557,7 +3557,7 @@ s32 func_80837818(Player* this) { } } } - if (this->heldItemActionParam == PLAYER_AP_STICK) { + if (this->heldItemAction == PLAYER_IA_STICK) { sp18 = 0; } } @@ -3570,12 +3570,12 @@ s32 func_80837818(Player* this) { } void func_80837918(Player* this, s32 quadIndex, u32 flags) { - this->swordQuads[quadIndex].info.toucher.dmgFlags = flags; + this->meleeWeaponQuads[quadIndex].info.toucher.dmgFlags = flags; if (flags == 2) { - this->swordQuads[quadIndex].info.toucherFlags = TOUCH_ON | TOUCH_NEAREST | TOUCH_SFX_WOOD; + this->meleeWeaponQuads[quadIndex].info.toucherFlags = TOUCH_ON | TOUCH_NEAREST | TOUCH_SFX_WOOD; } else { - this->swordQuads[quadIndex].info.toucherFlags = TOUCH_ON | TOUCH_NEAREST; + this->meleeWeaponQuads[quadIndex].info.toucherFlags = TOUCH_ON | TOUCH_NEAREST; } } @@ -3595,7 +3595,7 @@ void func_80837948(PlayState* play, Player* this, s32 arg2) { func_80832318(this); } - if ((arg2 != this->swordAnimation) || !(this->unk_845 < 3)) { + if ((arg2 != this->meleeWeaponAnimation) || !(this->unk_845 < 3)) { this->unk_845 = 0; } @@ -3604,7 +3604,7 @@ void func_80837948(PlayState* play, Player* this, s32 arg2) { arg2 += 2; } - this->swordAnimation = arg2; + this->meleeWeaponAnimation = arg2; func_808322D0(play, this, D_80854190[arg2].unk_00); if ((arg2 != 16) && (arg2 != 17)) { @@ -3956,18 +3956,18 @@ s32 func_808382DC(Player* this, PlayState* play) { if (this->unk_870 < 0.5f) { anim = D_808543BC[Player_HoldsTwoHandedWeapon(this) && !(CVar_GetS32("gShieldTwoHanded", 0) && - (this->heldItemActionParam != PLAYER_AP_STICK))]; + (this->heldItemAction != PLAYER_IA_STICK))]; } else { anim = D_808543B4[Player_HoldsTwoHandedWeapon(this) && !(CVar_GetS32("gShieldTwoHanded", 0) && - (this->heldItemActionParam != PLAYER_AP_STICK))]; + (this->heldItemAction != PLAYER_IA_STICK))]; } LinkAnimation_PlayOnce(play, &this->skelAnime2, anim); } else { func_80832264(play, this, D_808543C4[Player_HoldsTwoHandedWeapon(this) && !(CVar_GetS32("gShieldTwoHanded", 0) && - (this->heldItemActionParam != PLAYER_AP_STICK))]); + (this->heldItemAction != PLAYER_IA_STICK))]); } } @@ -3985,8 +3985,8 @@ s32 func_808382DC(Player* this, PlayState* play) { } if ((this->unk_A87 != 0) || (this->invincibilityTimer > 0) || (this->stateFlags1 & PLAYER_STATE1_26) || - (this->csMode != 0) || (this->swordQuads[0].base.atFlags & AT_HIT) || - (this->swordQuads[1].base.atFlags & AT_HIT)) { + (this->csMode != 0) || (this->meleeWeaponQuads[0].base.atFlags & AT_HIT) || + (this->meleeWeaponQuads[1].base.atFlags & AT_HIT)) { return 0; } @@ -4248,7 +4248,7 @@ s32 func_80839034(PlayState* play, Player* this, CollisionPoly* poly, u32 bgId) gSaveContext.respawnFlag = 2; play->nextEntranceIndex = gSaveContext.respawn[RESPAWN_MODE_RETURN].entranceIndex; play->fadeTransition = 3; - gSaveContext.nextTransition = 3; + gSaveContext.nextTransitionType = 3; } else if (play->nextEntranceIndex >= 0x7FF9) { // handle dynamic exits if (gSaveContext.n64ddFlag) { @@ -4265,14 +4265,14 @@ s32 func_80839034(PlayState* play, Player* this, CollisionPoly* poly, u32 bgId) Play_TriggerVoidOut(play); gSaveContext.respawnFlag = -2; } - gSaveContext.unk_13C3 = 1; + gSaveContext.retainWeatherMode = 1; func_800994A0(play); } play->sceneLoadFlag = 0x14; } if (!(this->stateFlags1 & (PLAYER_STATE1_23 | PLAYER_STATE1_29)) && - !(this->stateFlags2 & PLAYER_STATE2_18) && !func_808332B8(this) && + !(this->stateFlags2 & PLAYER_STATE2_CRAWLING) && !func_808332B8(this) && (temp = func_80041D4C(&play->colCtx, poly, bgId), (temp != 10)) && ((sp34 < 100) || (this->actor.bgCheckFlags & 1))) { @@ -4459,7 +4459,7 @@ s32 func_80839800(Player* this, PlayState* play) { } if (doorShutter->dyna.actor.category == ACTORCAT_DOOR) { - this->unk_46A = play->transiActorCtx.list[(u16)doorShutter->dyna.actor.params >> 10] + this->doorBgCamIndex = play->transiActorCtx.list[(u16)doorShutter->dyna.actor.params >> 10] .sides[(doorDirection > 0) ? 0 : 1] .effects; @@ -4934,7 +4934,7 @@ s32 func_8083AD4C(PlayState* play, Player* this) { s32 func_8083ADD4(PlayState* play, Player* this) { if (this->unk_6AD == 3) { func_80835C58(play, this, func_80852E14, 0); - if (this->unk_46A != 0) { + if (this->doorBgCamIndex != 0) { this->stateFlags1 |= PLAYER_STATE1_29; } func_80832318(this); @@ -4972,7 +4972,7 @@ void func_8083AF44(PlayState* play, Player* this, s32 magicSpell) { LinkAnimation_PlayOnceSetSpeed(play, &this->skelAnime, &gPlayerAnim_link_magic_tame, 0.83f); if (magicSpell == 5) { - this->unk_46C = OnePointCutscene_Init(play, 1100, -101, NULL, MAIN_CAM); + this->subCamId = OnePointCutscene_Init(play, 1100, -101, NULL, MAIN_CAM); } else { func_80835EA4(play, 10); } @@ -5010,7 +5010,7 @@ s32 func_8083B040(Player* this, PlayState* play) { if (!func_8083ADD4(play, this)) { if (this->unk_6AD == 4) { - sp2C = Player_ActionToMagicSpell(this, this->itemActionParam); + sp2C = Player_ActionToMagicSpell(this, this->itemAction); if (sp2C >= 0) { if ((sp2C != 3) || (gSaveContext.respawn[RESPAWN_MODE_TOP].data <= 0)) { func_8083AF44(play, this, sp2C); @@ -5025,13 +5025,13 @@ s32 func_8083B040(Player* this, PlayState* play) { return 1; } - sp2C = this->itemActionParam - PLAYER_AP_LETTER_ZELDA; + sp2C = this->itemAction - PLAYER_IA_LETTER_ZELDA; if ((sp2C >= 0) || - (sp28 = Player_ActionToBottle(this, this->itemActionParam) - 1, + (sp28 = Player_ActionToBottle(this, this->itemAction) - 1, ((sp28 >= 0) && (sp28 < 6) && - ((this->itemActionParam > PLAYER_AP_BOTTLE_POE) || + ((this->itemAction > PLAYER_IA_BOTTLE_POE) || ((this->targetActor != NULL) && - (((this->itemActionParam == PLAYER_AP_BOTTLE_POE) && (this->exchangeItemId == EXCH_ITEM_POE)) || + (((this->itemAction == PLAYER_IA_BOTTLE_POE) && (this->exchangeItemId == EXCH_ITEM_POE)) || (this->exchangeItemId == EXCH_ITEM_BLUE_FIRE))))))) { if ((play->actorCtx.titleCtx.delayTimer == 0) && (play->actorCtx.titleCtx.alpha == 0)) { @@ -5059,10 +5059,10 @@ s32 func_8083B040(Player* this, PlayState* play) { if ((targetActor != NULL) && ((this->exchangeItemId == sp2C) || (this->exchangeItemId == EXCH_ITEM_BLUE_FIRE) || ((this->exchangeItemId == EXCH_ITEM_POE) && - (this->itemActionParam == PLAYER_AP_BOTTLE_BIG_POE)) || + (this->itemAction == PLAYER_IA_BOTTLE_BIG_POE)) || ((this->exchangeItemId == EXCH_ITEM_BEAN) && - (this->itemActionParam == PLAYER_AP_BOTTLE_BUG))) && - ((this->exchangeItemId != EXCH_ITEM_BEAN) || (this->itemActionParam == PLAYER_AP_BEAN))) { + (this->itemAction == PLAYER_IA_BOTTLE_BUG))) && + ((this->exchangeItemId != EXCH_ITEM_BEAN) || (this->itemAction == PLAYER_IA_BEAN))) { if (this->exchangeItemId == EXCH_ITEM_BEAN) { Inventory_ChangeAmmo(ITEM_BEAN, -1); func_80835DE4(play, this, func_8084279C, 0); @@ -5096,7 +5096,7 @@ s32 func_8083B040(Player* this, PlayState* play) { return 1; } - sp2C = Player_ActionToBottle(this, this->itemActionParam); + sp2C = Player_ActionToBottle(this, this->itemAction); if (sp2C >= 0) { if (sp2C == 0xC) { func_80835DE4(play, this, func_8084EED8, 0); @@ -5420,7 +5420,7 @@ s32 func_8083C1DC(Player* this, PlayState* play) { if (func_8083BC7C(this, play)) { return 1; } - if ((this->unk_837 == 0) && (this->heldItemActionParam >= PLAYER_AP_SWORD_MASTER)) { + if ((this->unk_837 == 0) && (this->heldItemAction >= PLAYER_IA_SWORD_MASTER)) { func_80835F44(play, this, ITEM_NONE); } else { this->stateFlags2 ^= PLAYER_STATE2_20; @@ -5501,8 +5501,8 @@ void func_8083C50C(Player* this) { s32 func_8083C544(Player* this, PlayState* play) { if (CHECK_BTN_ALL(sControlInput->cur.button, BTN_B)) { if (!(this->stateFlags1 & PLAYER_STATE1_22) && (Player_GetSwordHeld(this) != 0) && (this->unk_844 == 1) && - (this->heldItemActionParam != PLAYER_AP_STICK)) { - if ((this->heldItemActionParam != PLAYER_AP_SWORD_BGS) || (gSaveContext.swordHealth > 0.0f)) { + (this->heldItemAction != PLAYER_IA_STICK)) { + if ((this->heldItemAction != PLAYER_IA_SWORD_BGS) || (gSaveContext.swordHealth > 0.0f)) { func_808377DC(play, this); return 1; } @@ -5549,7 +5549,7 @@ s32 func_8083C6B8(PlayState* play, Player* this) { return 1; } - if (this->heldItemActionParam == PLAYER_AP_FISHING_POLE) { + if (this->heldItemAction == PLAYER_IA_FISHING_POLE) { sp24 = this->actor.world.pos; sp24.y += 50.0f; @@ -6400,16 +6400,16 @@ s32 func_8083E5A8(Player* this, PlayState* play) { if ((this->heldActor == NULL) || Player_HoldsHookshot(this)) { if ((interactedActor->id == ACTOR_BG_TOKI_SWD) && LINK_IS_ADULT) { - s32 sp24 = this->itemActionParam; + s32 sp24 = this->itemAction; - this->itemActionParam = PLAYER_AP_NONE; + this->itemAction = PLAYER_IA_NONE; this->modelAnimType = PLAYER_ANIMTYPE_0; - this->heldItemActionParam = this->itemActionParam; + this->heldItemAction = this->itemAction; func_80836898(play, this, func_8083A0F4); - if (sp24 == PLAYER_AP_SWORD_MASTER) { - this->nextModelGroup = Player_ActionToModelGroup(this, PLAYER_AP_LAST_USED); - func_8083399C(play, this, PLAYER_AP_LAST_USED); + if (sp24 == PLAYER_IA_SWORD_MASTER) { + this->nextModelGroup = Player_ActionToModelGroup(this, PLAYER_IA_LAST_USED); + func_8083399C(play, this, PLAYER_IA_LAST_USED); } else { func_80835F44(play, this, ITEM_LAST_USED); } @@ -6621,7 +6621,7 @@ s32 func_8083F0C8(Player* this, PlayState* play, u32 arg2) { ((this->actor.world.pos.z - tempZ) * COLPOLY_GET_NORMAL(wallPoly->normal.x)); if (fabsf(temp) < 8.0f) { - this->stateFlags2 |= PLAYER_STATE2_16; + this->stateFlags2 |= PLAYER_STATE2_DO_ACTION_ENTER; if (CHECK_BTN_ALL(sControlInput->press.button, BTN_A)) { f32 wallPolyNormX = COLPOLY_GET_NORMAL(wallPoly->normal.x); @@ -6629,7 +6629,7 @@ s32 func_8083F0C8(Player* this, PlayState* play, u32 arg2) { f32 wallDistance = this->wallDistance; func_80836898(play, this, func_8083A40C); - this->stateFlags2 |= PLAYER_STATE2_18; + this->stateFlags2 |= PLAYER_STATE2_CRAWLING; this->actor.shape.rot.y = this->currentYaw = this->actor.wallYaw + 0x8000; this->actor.world.pos.x = tempX + (wallDistance * wallPolyNormX); this->actor.world.pos.z = tempZ + (wallDistance * wallPolyNormZ); @@ -7893,7 +7893,7 @@ s32 func_808428D8(Player* this, PlayState* play) { func_80832264(play, this, &gPlayerAnim_link_normal_defense_kiru); this->unk_84F = 1; - this->swordAnimation = 0xC; + this->meleeWeaponAnimation = 0xC; this->currentYaw = this->actor.shape.rot.y + this->unk_6BE; if (!CVar_GetS32("gCrouchStabHammerFix", 0)) { @@ -7943,7 +7943,7 @@ void func_80842A88(PlayState* play, Player* this) { } s32 func_80842AC4(PlayState* play, Player* this) { - if ((this->heldItemActionParam == PLAYER_AP_STICK) && (this->unk_85C > 0.5f)) { + if ((this->heldItemAction == PLAYER_IA_STICK) && (this->unk_85C > 0.5f)) { if (AMMO(ITEM_STICK) != 0) { EffectSsStick_Spawn(play, &this->bodyPartsPos[PLAYER_BODYPART_R_HAND], this->actor.shape.rot.y + 0x8000); @@ -7959,7 +7959,7 @@ s32 func_80842AC4(PlayState* play, Player* this) { } s32 func_80842B7C(PlayState* play, Player* this) { - if (this->heldItemActionParam == PLAYER_AP_SWORD_BGS) { + if (this->heldItemAction == PLAYER_IA_SWORD_BGS) { if (!gSaveContext.bgsFlag && (gSaveContext.swordHealth > 0.0f)) { if ((gSaveContext.swordHealth -= 1.0f) <= 0.0f) { EffectSsStick_Spawn(play, &this->bodyPartsPos[PLAYER_BODYPART_R_HAND], @@ -8020,26 +8020,26 @@ s32 func_80842DF4(PlayState* play, Player* this) { s32 sp48; if (this->swordState > 0) { - if (this->swordAnimation < 0x18) { - if (!(this->swordQuads[0].base.atFlags & AT_BOUNCED) && !(this->swordQuads[1].base.atFlags & AT_BOUNCED)) { + if (this->meleeWeaponAnimation < 0x18) { + if (!(this->meleeWeaponQuads[0].base.atFlags & AT_BOUNCED) && !(this->meleeWeaponQuads[1].base.atFlags & AT_BOUNCED)) { if (this->skelAnime.curFrame >= 2.0f) { - phi_f2 = Math_Vec3f_DistXYZAndStoreDiff(&this->swordInfo[0].tip, &this->swordInfo[0].base, &sp50); + phi_f2 = Math_Vec3f_DistXYZAndStoreDiff(&this->meleeWeaponInfo[0].tip, &this->meleeWeaponInfo[0].base, &sp50); if (phi_f2 != 0.0f) { phi_f2 = (phi_f2 + 10.0f) / phi_f2; } - sp68.x = this->swordInfo[0].tip.x + (sp50.x * phi_f2); - sp68.y = this->swordInfo[0].tip.y + (sp50.y * phi_f2); - sp68.z = this->swordInfo[0].tip.z + (sp50.z * phi_f2); + sp68.x = this->meleeWeaponInfo[0].tip.x + (sp50.x * phi_f2); + sp68.y = this->meleeWeaponInfo[0].tip.y + (sp50.y * phi_f2); + sp68.z = this->meleeWeaponInfo[0].tip.z + (sp50.z * phi_f2); - if (BgCheck_EntityLineTest1(&play->colCtx, &sp68, &this->swordInfo[0].tip, &sp5C, &sp78, true, + if (BgCheck_EntityLineTest1(&play->colCtx, &sp68, &this->meleeWeaponInfo[0].tip, &sp5C, &sp78, true, false, false, true, &sp74) && !SurfaceType_IsIgnoredByEntities(&play->colCtx, sp78, sp74) && (func_80041D4C(&play->colCtx, sp78, sp74) != 6) && (func_8002F9EC(play, &this->actor, sp78, sp74, &sp5C) == 0)) { - if (this->heldItemActionParam == PLAYER_AP_HAMMER) { + if (this->heldItemAction == PLAYER_IA_HAMMER) { func_80832630(play); func_80842A28(play, this); func_80842D20(play, this); @@ -8073,18 +8073,18 @@ s32 func_80842DF4(PlayState* play, Player* this) { } } - temp1 = (this->swordQuads[0].base.atFlags & AT_HIT) || (this->swordQuads[1].base.atFlags & AT_HIT); + temp1 = (this->meleeWeaponQuads[0].base.atFlags & AT_HIT) || (this->meleeWeaponQuads[1].base.atFlags & AT_HIT); if (temp1) { - if (this->swordAnimation < 0x18) { - Actor* at = this->swordQuads[temp1 ? 1 : 0].base.at; + if (this->meleeWeaponAnimation < 0x18) { + Actor* at = this->meleeWeaponQuads[temp1 ? 1 : 0].base.at; if ((at != NULL) && (at->id != ACTOR_EN_KANBAN)) { func_80832630(play); } } - if ((func_80842AC4(play, this) == 0) && (this->heldItemActionParam != PLAYER_AP_HAMMER)) { + if ((func_80842AC4(play, this) == 0) && (this->heldItemAction != PLAYER_IA_HAMMER)) { func_80842B7C(play, this); if (this->actor.colChkInfo.atHitEffect == 1) { @@ -8176,7 +8176,7 @@ void func_80843188(Player* this, PlayState* play) { ANIMMODE_ONCE, 0.0f); func_80832F54(play, this, 4); } else { - if (this->itemActionParam < 0) { + if (this->itemAction < 0) { func_8008EC70(this); } func_8083A098(this, D_80853914[PLAYER_ANIMGROUP_22][this->modelAnimType], play); @@ -8727,8 +8727,8 @@ void func_80844AF4(Player* this, PlayState* play) { } if (func_80843E64(play, this) >= 0) { - this->swordAnimation += 2; - func_80837948(play, this, this->swordAnimation); + this->meleeWeaponAnimation += 2; + func_80837948(play, this, this->meleeWeaponAnimation); this->unk_845 = 3; func_808328A0(this); } @@ -9550,7 +9550,7 @@ void Player_InitCommon(Player* this, PlayState* play, FlexSkeletonHeader* skelHe this->getItemEntry = (GetItemEntry)GET_ITEM_NONE; this->ageProperties = &sAgeProperties[gSaveContext.linkAge]; Actor_ProcessInitChain(&this->actor, sInitChain); - this->swordEffectIndex = TOTAL_EFFECT_COUNT; + this->meleeWeaponEffectIndex = TOTAL_EFFECT_COUNT; this->currentYaw = this->actor.world.rot.y; func_80834644(play, this); @@ -9561,15 +9561,15 @@ void Player_InitCommon(Player* this, PlayState* play, FlexSkeletonHeader* skelHe this->morphTable2, PLAYER_LIMB_MAX); this->skelAnime2.baseTransl = D_80854730; - Effect_Add(play, &this->swordEffectIndex, EFFECT_BLURE2, 0, 0, &blureSword); + Effect_Add(play, &this->meleeWeaponEffectIndex, EFFECT_BLURE2, 0, 0, &blureSword); ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFeet, this->ageProperties->unk_04); - this->unk_46C = SUBCAM_NONE; + this->subCamId = SUBCAM_NONE; Collider_InitCylinder(play, &this->cylinder); Collider_SetCylinder(play, &this->cylinder, &this->actor, &D_80854624); - Collider_InitQuad(play, &this->swordQuads[0]); - Collider_SetQuad(play, &this->swordQuads[0], &this->actor, &D_80854650); - Collider_InitQuad(play, &this->swordQuads[1]); - Collider_SetQuad(play, &this->swordQuads[1], &this->actor, &D_80854650); + Collider_InitQuad(play, &this->meleeWeaponQuads[0]); + Collider_SetQuad(play, &this->meleeWeaponQuads[0], &this->actor, &D_80854650); + Collider_InitQuad(play, &this->meleeWeaponQuads[1]); + Collider_SetQuad(play, &this->meleeWeaponQuads[1], &this->actor, &D_80854650); Collider_InitQuad(play, &this->shieldQuad); Collider_SetQuad(play, &this->shieldQuad, &this->actor, &D_808546A0); } @@ -9605,7 +9605,7 @@ void Player_Init(Actor* thisx, PlayState* play2) { thisx->room = -1; this->ageProperties = &sAgeProperties[gSaveContext.linkAge]; - this->itemActionParam = this->heldItemActionParam = -1; + this->itemAction = this->heldItemAction = -1; this->heldItemId = ITEM_NONE; func_80835F44(play, this, ITEM_NONE); @@ -9699,9 +9699,9 @@ void Player_Init(Actor* thisx, PlayState* play2) { } if (gSaveContext.nayrusLoveTimer != 0) { - gSaveContext.unk_13F0 = 3; + gSaveContext.magicState = 3; func_80846A00(play, this, 1); - this->stateFlags3 &= ~PLAYER_STATE3_6; + this->stateFlags3 &= ~PLAYER_STATE3_RESTORE_NAYRUS_LOVE; } if (gSaveContext.entranceSound != 0) { @@ -9787,11 +9787,11 @@ void func_808473D4(PlayState* play, Player* this) { if (!Player_InBlockingCsMode(play, this)) { if (this->stateFlags1 & PLAYER_STATE1_20) { doAction = DO_ACTION_RETURN; - } else if ((this->heldItemActionParam == PLAYER_AP_FISHING_POLE) && (this->unk_860 != 0)) { + } else if ((this->heldItemAction == PLAYER_IA_FISHING_POLE) && (this->unk_860 != 0)) { if (this->unk_860 == 2) { doAction = DO_ACTION_REEL; } - } else if ((func_8084E3C4 != this->func_674) && !(this->stateFlags2 & PLAYER_STATE2_18)) { + } else if ((func_8084E3C4 != this->func_674) && !(this->stateFlags2 & PLAYER_STATE2_CRAWLING)) { if ((this->doorType != PLAYER_DOORTYPE_NONE) && (!(this->stateFlags1 & PLAYER_STATE1_11) || ((heldActor != NULL) && (heldActor->id == ACTOR_EN_RU1)))) { @@ -9832,7 +9832,7 @@ void func_808473D4(PlayState* play, Player* this) { } else if ((this->stateFlags1 & (PLAYER_STATE1_13 | PLAYER_STATE1_21)) || ((this->stateFlags1 & PLAYER_STATE1_23) && (this->stateFlags2 & PLAYER_STATE2_22))) { doAction = DO_ACTION_DOWN; - } else if (this->stateFlags2 & PLAYER_STATE2_16) { + } else if (this->stateFlags2 & PLAYER_STATE2_DO_ACTION_ENTER) { doAction = DO_ACTION_ENTER; } else if ((this->stateFlags1 & PLAYER_STATE1_11) && (this->getItemId == GI_NONE) && (heldActor != NULL)) { @@ -9863,7 +9863,7 @@ void func_808473D4(PlayState* play, Player* this) { } else if ((play->roomCtx.curRoom.behaviorType1 != ROOM_BEHAVIOR_TYPE1_2) && func_80833BCC(this) && (sp20 > 0)) { doAction = DO_ACTION_JUMP; - } else if ((this->heldItemActionParam >= PLAYER_AP_SWORD_MASTER) || + } else if ((this->heldItemAction >= PLAYER_IA_SWORD_MASTER) || ((this->stateFlags2 & PLAYER_STATE2_20) && (play->actorCtx.targetCtx.arrowPointedActor == NULL))) { doAction = DO_ACTION_PUTAWAY; @@ -9940,7 +9940,7 @@ void func_80847BA0(PlayState* play, Player* this) { D_80853604 = this->unk_A7A; - if (this->stateFlags2 & PLAYER_STATE2_18) { + if (this->stateFlags2 & PLAYER_STATE2_CRAWLING) { spB0 = 10.0f; spAC = 15.0f; spA8 = 30.0f; @@ -10042,7 +10042,7 @@ void func_80847BA0(PlayState* play, Player* this) { D_80854798.y = 18.0f; D_80854798.z = this->ageProperties->unk_38 + 10.0f; - if (!(this->stateFlags2 & PLAYER_STATE2_18) && + if (!(this->stateFlags2 & PLAYER_STATE2_CRAWLING) && func_80839768(play, this, &D_80854798, &spA0, &sp9C, &D_80858AA8)) { this->actor.bgCheckFlags |= 0x200; if (this->actor.wallPoly != spA0) { @@ -10249,7 +10249,7 @@ void Player_UpdateCamAndSeqModes(PlayState* play, Player* this) { } } else if (this->stateFlags1 & PLAYER_STATE1_19) { camMode = CAM_MODE_FREEFALL; - } else if ((this->swordState != 0) && (this->swordAnimation >= 0) && (this->swordAnimation < 0x18)) { + } else if ((this->swordState != 0) && (this->meleeWeaponAnimation >= 0) && (this->meleeWeaponAnimation < 0x18)) { camMode = CAM_MODE_STILL; } else { camMode = CAM_MODE_NORMAL; @@ -10304,7 +10304,7 @@ void func_80848A04(PlayState* play, Player* this) { this->unk_85C = temp; } - func_8002836C(play, &this->swordInfo[0].tip, &D_808547A4, &D_808547B0, &D_808547BC, &D_808547C0, temp * 200.0f, + func_8002836C(play, &this->meleeWeaponInfo[0].tip, &D_808547A4, &D_808547B0, &D_808547BC, &D_808547C0, temp * 200.0f, 0, 8); } @@ -10586,9 +10586,9 @@ void Player_UpdateCommon(Player* this, PlayState* play, Input* input) { func_808473D4(play, this); func_80836BEC(this, play); - if ((this->heldItemActionParam == PLAYER_AP_STICK) && (this->unk_860 != 0)) { + if ((this->heldItemAction == PLAYER_IA_STICK) && (this->unk_860 != 0)) { func_80848A04(play, this); - } else if ((this->heldItemActionParam == PLAYER_AP_FISHING_POLE) && (this->unk_860 < 0)) { + } else if ((this->heldItemAction == PLAYER_IA_FISHING_POLE) && (this->unk_860 < 0)) { this->unk_860++; } @@ -10600,10 +10600,10 @@ void Player_UpdateCommon(Player* this, PlayState* play, Input* input) { func_80848C74(play, this); } - if ((this->stateFlags3 & PLAYER_STATE3_6) && (gSaveContext.nayrusLoveTimer != 0) && (gSaveContext.unk_13F0 == 0)) { - gSaveContext.unk_13F0 = 3; + if ((this->stateFlags3 & PLAYER_STATE3_RESTORE_NAYRUS_LOVE) && (gSaveContext.nayrusLoveTimer != 0) && (gSaveContext.magicState == 0)) { + gSaveContext.magicState = 3; func_80846A00(play, this, 1); - this->stateFlags3 &= ~PLAYER_STATE3_6; + this->stateFlags3 &= ~PLAYER_STATE3_RESTORE_NAYRUS_LOVE; } if (this->stateFlags2 & PLAYER_STATE2_15) { @@ -10766,7 +10766,7 @@ void Player_UpdateCommon(Player* this, PlayState* play, Input* input) { Math_StepToF(&this->windSpeed, 0.0f, (this->stateFlags1 & PLAYER_STATE1_27) ? 0.5f : 1.0f); } - if (!Player_InBlockingCsMode(play, this) && !(this->stateFlags2 & PLAYER_STATE2_18)) { + if (!Player_InBlockingCsMode(play, this) && !(this->stateFlags2 & PLAYER_STATE2_CRAWLING)) { func_8083D53C(play, this); if ((this->actor.category == ACTORCAT_PLAYER) && (gSaveContext.health == 0)) { @@ -10822,10 +10822,10 @@ void Player_UpdateCommon(Player* this, PlayState* play, Input* input) { this->stateFlags2 &= ~(PLAYER_STATE2_1 | PLAYER_STATE2_21); } - this->stateFlags1 &= ~(PLAYER_STATE1_1 | PLAYER_STATE1_9 | PLAYER_STATE1_12 | PLAYER_STATE1_22); + this->stateFlags1 &= ~(PLAYER_STATE1_SWINGING_BOTTLE | PLAYER_STATE1_9 | PLAYER_STATE1_12 | PLAYER_STATE1_22); this->stateFlags2 &= ~(PLAYER_STATE2_0 | PLAYER_STATE2_2 | PLAYER_STATE2_3 | PLAYER_STATE2_5 | PLAYER_STATE2_6 | PLAYER_STATE2_8 | PLAYER_STATE2_9 | PLAYER_STATE2_12 | PLAYER_STATE2_14 | - PLAYER_STATE2_16 | PLAYER_STATE2_22 | PLAYER_STATE2_26); + PLAYER_STATE2_DO_ACTION_ENTER | PLAYER_STATE2_22 | PLAYER_STATE2_26); this->stateFlags3 &= ~PLAYER_STATE3_4; func_80847298(this); @@ -10936,8 +10936,8 @@ void Player_UpdateCommon(Player* this, PlayState* play, Input* input) { Collider_ResetCylinderAC(play, &this->cylinder.base); - Collider_ResetQuadAT(play, &this->swordQuads[0].base); - Collider_ResetQuadAT(play, &this->swordQuads[1].base); + Collider_ResetQuadAT(play, &this->meleeWeaponQuads[0].base); + Collider_ResetQuadAT(play, &this->meleeWeaponQuads[1].base); Collider_ResetQuadAC(play, &this->shieldQuad.base); Collider_ResetQuadAT(play, &this->shieldQuad.base); @@ -11195,7 +11195,7 @@ void Player_Draw(Actor* thisx, PlayState* play2) { if (projectedHeadPos.z < -4.0f) { overrideLimbDraw = func_800902F0; } - } else if (this->stateFlags2 & PLAYER_STATE2_18) { + } else if (this->stateFlags2 & PLAYER_STATE2_CRAWLING) { if (this->actor.projectedPos.z < 0.0f) { overrideLimbDraw = func_80090440; } @@ -11257,11 +11257,11 @@ void Player_Draw(Actor* thisx, PlayState* play2) { void Player_Destroy(Actor* thisx, PlayState* play) { Player* this = (Player*)thisx; - Effect_Delete(play, this->swordEffectIndex); + Effect_Delete(play, this->meleeWeaponEffectIndex); Collider_DestroyCylinder(play, &this->cylinder); - Collider_DestroyQuad(play, &this->swordQuads[0]); - Collider_DestroyQuad(play, &this->swordQuads[1]); + Collider_DestroyQuad(play, &this->meleeWeaponQuads[0]); + Collider_DestroyQuad(play, &this->meleeWeaponQuads[1]); Collider_DestroyQuad(play, &this->shieldQuad); func_800876C8(play); @@ -11504,8 +11504,8 @@ s32 func_8084B3CC(PlayState* play, Player* this) { } void func_8084B498(Player* this) { - this->itemActionParam = - (INV_CONTENT(ITEM_OCARINA_FAIRY) == ITEM_OCARINA_FAIRY) ? PLAYER_AP_OCARINA_FAIRY : PLAYER_AP_OCARINA_TIME; + this->itemAction = + (INV_CONTENT(ITEM_OCARINA_FAIRY) == ITEM_OCARINA_FAIRY) ? PLAYER_IA_OCARINA_FAIRY : PLAYER_IA_OCARINA_TIME; } s32 func_8084B4D4(PlayState* play, Player* this) { @@ -11559,7 +11559,7 @@ void func_8084B530(Player* this, PlayState* play) { if (this->skelAnime.moveFlags != 0) { func_80832DBC(this); if ((this->targetActor->category == ACTORCAT_NPC) && - (this->heldItemActionParam != PLAYER_AP_FISHING_POLE)) { + (this->heldItemAction != PLAYER_IA_FISHING_POLE)) { func_808322D0(play, this, &gPlayerAnim_link_normal_talk_free); } else { func_80832284(play, this, func_80833338(this)); @@ -12014,7 +12014,7 @@ void func_8084C81C(Player* this, PlayState* play) { if (LinkAnimation_Update(play, &this->skelAnime)) { func_8083C0E8(this, play); - this->stateFlags2 &= ~PLAYER_STATE2_18; + this->stateFlags2 &= ~PLAYER_STATE2_CRAWLING; return; } @@ -12980,7 +12980,7 @@ static u8 D_808549FC[] = { void func_8084EAC0(Player* this, PlayState* play) { if (LinkAnimation_Update(play, &this->skelAnime)) { if (this->unk_850 == 0) { - if (this->itemActionParam == PLAYER_AP_BOTTLE_POE) { + if (this->itemAction == PLAYER_IA_BOTTLE_POE) { s32 rand = Rand_S16Offset(-1, 3); if (rand == 0) { @@ -12997,9 +12997,9 @@ void func_8084EAC0(Player* this, PlayState* play) { gSaveContext.healthAccumulator = rand * 0x10; } } else { - s32 sp28 = D_808549FC[this->itemActionParam - PLAYER_AP_BOTTLE_POTION_RED]; + s32 sp28 = D_808549FC[this->itemAction - PLAYER_IA_BOTTLE_POTION_RED]; - if (CVar_GetS32("gRedPotionEffect", 0) && this->itemActionParam == PLAYER_AP_BOTTLE_POTION_RED) { + if (CVar_GetS32("gRedPotionEffect", 0) && this->itemAction == PLAYER_IA_BOTTLE_POTION_RED) { if (CVar_GetS32("gRedPercentRestore", 0)) { gSaveContext.healthAccumulator = (gSaveContext.healthCapacity * CVar_GetS32("gRedPotionHealth", 100) / 100 + 15) / 16 * 16; @@ -13007,7 +13007,7 @@ void func_8084EAC0(Player* this, PlayState* play) { gSaveContext.healthAccumulator = CVar_GetS32("gRedPotionHealth", 20) * 16; } } else if (CVar_GetS32("gBluePotionEffects", 0) && - this->itemActionParam == PLAYER_AP_BOTTLE_POTION_BLUE) { + this->itemAction == PLAYER_IA_BOTTLE_POTION_BLUE) { if (CVar_GetS32("gBlueHealthPercentRestore", 0)) { gSaveContext.healthAccumulator = (gSaveContext.healthCapacity * CVar_GetS32("gBluePotionHealth", 100) / 100 + 15) / 16 * 16; @@ -13016,7 +13016,7 @@ void func_8084EAC0(Player* this, PlayState* play) { } if (CVar_GetS32("gBlueManaPercentRestore", 0)) { - if (gSaveContext.unk_13F0 != 10) { + if (gSaveContext.magicState != 10) { Magic_Fill(play); } @@ -13025,7 +13025,7 @@ void func_8084EAC0(Player* this, PlayState* play) { 16 * 16, 5); } else { - if (gSaveContext.unk_13F0 != 10) { + if (gSaveContext.magicState != 10) { Magic_Fill(play); } @@ -13033,9 +13033,9 @@ void func_8084EAC0(Player* this, PlayState* play) { ; } } else if (CVar_GetS32("gGreenPotionEffect", 0) && - this->itemActionParam == PLAYER_AP_BOTTLE_POTION_GREEN) { + this->itemAction == PLAYER_IA_BOTTLE_POTION_GREEN) { if (CVar_GetS32("gGreenPercentRestore", 0)) { - if (gSaveContext.unk_13F0 != 10) { + if (gSaveContext.magicState != 10) { Magic_Fill(play); } @@ -13044,15 +13044,15 @@ void func_8084EAC0(Player* this, PlayState* play) { 16 * 16, 5); } else { - if (gSaveContext.unk_13F0 != 10) { + if (gSaveContext.magicState != 10) { Magic_Fill(play); } func_80087708(play, CVar_GetS32("gGreenPotionMana", 100), 5); ; } - } else if (CVar_GetS32("gMilkEffect", 0) && (this->itemActionParam == PLAYER_AP_BOTTLE_MILK || - this->itemActionParam == PLAYER_AP_BOTTLE_MILK_HALF)) { + } else if (CVar_GetS32("gMilkEffect", 0) && (this->itemAction == PLAYER_IA_BOTTLE_MILK || + this->itemAction == PLAYER_IA_BOTTLE_MILK_HALF)) { if (CVar_GetS32("gMilkPercentRestore", 0)) { gSaveContext.healthAccumulator = (gSaveContext.healthCapacity * CVar_GetS32("gMilkHealth", 100) / 100 + 15) / 16 * 16; @@ -13060,7 +13060,7 @@ void func_8084EAC0(Player* this, PlayState* play) { gSaveContext.healthAccumulator = CVar_GetS32("gMilkHealth", 5) * 16; } if (CVar_GetS32("gSeparateHalfMilkEffect", 0) && - this->itemActionParam == PLAYER_AP_BOTTLE_MILK_HALF) { + this->itemAction == PLAYER_IA_BOTTLE_MILK_HALF) { if (CVar_GetS32("gHalfMilkPercentRestore", 0)) { gSaveContext.healthAccumulator = (gSaveContext.healthCapacity * CVar_GetS32("gHalfMilkHealth", 100) / 100 + 15) / 16 * @@ -13092,10 +13092,10 @@ void func_8084EAC0(Player* this, PlayState* play) { func_8083C0E8(this, play); func_8005B1A4(Play_GetCamera(play, 0)); } else if (this->unk_850 == 1) { - if ((gSaveContext.healthAccumulator == 0) && (gSaveContext.unk_13F0 != 9)) { + if ((gSaveContext.healthAccumulator == 0) && (gSaveContext.magicState != 9)) { func_80832B78(play, this, &gPlayerAnim_link_bottle_drink_demo_end); this->unk_850 = 2; - Player_UpdateBottleHeld(play, this, ITEM_BOTTLE, PLAYER_AP_BOTTLE); + Player_UpdateBottleHeld(play, this, ITEM_BOTTLE, PLAYER_IA_BOTTLE); } func_80832698(this, NA_SE_VO_LI_DRINK - SFX_FLAG); } else if ((this->unk_850 == 2) && LinkAnimation_OnFrame(&this->skelAnime, 29.0f)) { @@ -13174,7 +13174,7 @@ void func_8084ECA4(Player* this, PlayState* play) { } if (this->skelAnime.curFrame <= 7.0f) { - this->stateFlags1 |= PLAYER_STATE1_1; + this->stateFlags1 |= PLAYER_STATE1_SWINGING_BOTTLE; } } @@ -13189,7 +13189,7 @@ void func_8084EED8(Player* this, PlayState* play) { if (LinkAnimation_OnFrame(&this->skelAnime, 37.0f)) { Player_SpawnFairy(play, this, &this->leftHandPos, &D_80854A1C, FAIRY_REVIVE_BOTTLE); - Player_UpdateBottleHeld(play, this, ITEM_BOTTLE, PLAYER_AP_BOTTLE); + Player_UpdateBottleHeld(play, this, ITEM_BOTTLE, PLAYER_IA_BOTTLE); func_8002F7DC(&this->actor, NA_SE_EV_BOTTLE_CAP_OPEN); func_8002F7DC(&this->actor, NA_SE_EV_FIATY_HEAL - SFX_FLAG); } else if (LinkAnimation_OnFrame(&this->skelAnime, 47.0f)) { @@ -13227,14 +13227,14 @@ void func_8084EFC0(Player* this, PlayState* play) { } if (LinkAnimation_OnFrame(&this->skelAnime, 76.0f)) { - BottleDropInfo* dropInfo = &D_80854A28[this->itemActionParam - PLAYER_AP_BOTTLE_FISH]; + BottleDropInfo* dropInfo = &D_80854A28[this->itemAction - PLAYER_IA_BOTTLE_FISH]; Actor_Spawn(&play->actorCtx, play, dropInfo->actorId, (Math_SinS(this->actor.shape.rot.y) * 5.0f) + this->leftHandPos.x, this->leftHandPos.y, (Math_CosS(this->actor.shape.rot.y) * 5.0f) + this->leftHandPos.z, 0x4000, this->actor.shape.rot.y, 0, dropInfo->actorParams); - Player_UpdateBottleHeld(play, this, ITEM_BOTTLE, PLAYER_AP_BOTTLE); + Player_UpdateBottleHeld(play, this, ITEM_BOTTLE, PLAYER_IA_BOTTLE); return; } @@ -13263,7 +13263,7 @@ void func_8084F104(Player* this, PlayState* play) { } else { GetItemEntry giEntry = ItemTable_Retrieve(D_80854528[this->exchangeItemId - 1]); - if (this->itemActionParam >= PLAYER_AP_LETTER_ZELDA) { + if (this->itemAction >= PLAYER_IA_LETTER_ZELDA) { if (giEntry.gi >= 0) { this->unk_862 = giEntry.gi; } else { @@ -13274,7 +13274,7 @@ void func_8084F104(Player* this, PlayState* play) { if (this->unk_850 == 0) { Message_StartTextbox(play, this->actor.textId, &this->actor); - if ((this->itemActionParam == PLAYER_AP_CHICKEN) || (this->itemActionParam == PLAYER_AP_POCKET_CUCCO)) { + if ((this->itemAction == PLAYER_IA_CHICKEN) || (this->itemAction == PLAYER_IA_POCKET_CUCCO)) { func_8002F7DC(&this->actor, NA_SE_EV_CHICKEN_CRY_M); } @@ -13449,7 +13449,7 @@ void func_8084F88C(Player* this, PlayState* play) { func_80078884(NA_SE_OC_ABYSS); } else { play->fadeTransition = 2; - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; gSaveContext.seqId = (u8)NA_BGM_DISABLED; gSaveContext.natureAmbienceId = 0xFF; } @@ -13679,14 +13679,14 @@ s32 func_80850224(Player* this, PlayState* play) { static Vec3f D_80854A40 = { 0.0f, 40.0f, 45.0f }; void func_808502D0(Player* this, PlayState* play) { - struct_80854190* sp44 = &D_80854190[this->swordAnimation]; + struct_80854190* sp44 = &D_80854190[this->meleeWeaponAnimation]; this->stateFlags2 |= PLAYER_STATE2_5; if (!func_80842DF4(play, this)) { func_8084285C(this, 0.0f, sp44->unk_0C, sp44->unk_0D); - if ((this->stateFlags2 & PLAYER_STATE2_30) && (this->heldItemActionParam != PLAYER_AP_HAMMER) && + if ((this->stateFlags2 & PLAYER_STATE2_30) && (this->heldItemAction != PLAYER_IA_HAMMER) && LinkAnimation_OnFrame(&this->skelAnime, 0.0f)) { this->linearVelocity = 15.0f; this->stateFlags2 &= ~PLAYER_STATE2_30; @@ -13723,8 +13723,8 @@ void func_808502D0(Player* this, PlayState* play) { this->skelAnime.moveFlags = sp43; this->stateFlags3 |= PLAYER_STATE3_3; } - } else if (this->heldItemActionParam == PLAYER_AP_HAMMER) { - if ((this->swordAnimation == 0x16) || (this->swordAnimation == 0x13)) { + } else if (this->heldItemAction == PLAYER_IA_HAMMER) { + if ((this->meleeWeaponAnimation == 0x16) || (this->meleeWeaponAnimation == 0x13)) { static Vec3f zeroVec = { 0.0f, 0.0f, 0.0f }; Vec3f shockwavePos; f32 sp2C; @@ -13735,8 +13735,8 @@ void func_808502D0(Player* this, PlayState* play) { Math_ScaledStepToS(&this->actor.focus.rot.x, Math_Atan2S(45.0f, sp2C), 800); func_80836AB8(this, 1); - if ((((this->swordAnimation == 0x16) && LinkAnimation_OnFrame(&this->skelAnime, 7.0f)) || - ((this->swordAnimation == 0x13) && LinkAnimation_OnFrame(&this->skelAnime, 2.0f))) && + if ((((this->meleeWeaponAnimation == 0x16) && LinkAnimation_OnFrame(&this->skelAnime, 7.0f)) || + ((this->meleeWeaponAnimation == 0x13) && LinkAnimation_OnFrame(&this->skelAnime, 2.0f))) && (sp2C > -40.0f) && (sp2C < 40.0f)) { func_80842A28(play, this); EffectSsBlast_SpawnWhiteShockwave(play, &shockwavePos, &zeroVec, &zeroVec); @@ -13850,7 +13850,7 @@ static struct_80832924 D_80854A8C[][2] = { void func_808507F4(Player* this, PlayState* play) { if (LinkAnimation_Update(play, &this->skelAnime)) { if (this->unk_84F < 0) { - if ((this->itemActionParam == PLAYER_AP_NAYRUS_LOVE) || (gSaveContext.unk_13F0 == 0)) { + if ((this->itemAction == PLAYER_IA_NAYRUS_LOVE) || (gSaveContext.magicState == 0)) { func_80839FFC(this, play); func_8005B1A4(Play_GetCamera(play, 0)); } @@ -13861,7 +13861,7 @@ void func_808507F4(Player* this, PlayState* play) { if (func_80846A00(play, this, this->unk_84F) != NULL) { this->stateFlags1 |= PLAYER_STATE1_28 | PLAYER_STATE1_29; if ((this->unk_84F != 0) || (gSaveContext.respawn[RESPAWN_MODE_TOP].data <= 0)) { - gSaveContext.unk_13F0 = 1; + gSaveContext.magicState = 1; } } else { func_800876C8(play); @@ -14605,7 +14605,7 @@ void func_80851CA4(PlayState* play, Player* this, CsCmdActorAction* arg2) { void func_80851D2C(PlayState* play, Player* this, CsCmdActorAction* arg2) { func_80850F1C(play, this, &gPlayerAnim_link_normal_okarina_start); func_8084B498(this); - Player_SetModels(this, Player_ActionToModelGroup(this, this->itemActionParam)); + Player_SetModels(this, Player_ActionToModelGroup(this, this->itemAction)); } static struct_80832924 D_808551B8[] = { @@ -14859,9 +14859,9 @@ void func_80852648(PlayState* play, Player* this, CsCmdActorAction* arg2) { LinkAnimation_Update(play, &this->skelAnime); if (LinkAnimation_OnFrame(&this->skelAnime, 10.0f)) { - this->heldItemActionParam = this->itemActionParam = PLAYER_AP_NONE; + this->heldItemAction = this->itemAction = PLAYER_IA_NONE; this->heldItemId = ITEM_NONE; - this->modelGroup = this->nextModelGroup = Player_ActionToModelGroup(this, PLAYER_AP_NONE); + this->modelGroup = this->nextModelGroup = Player_ActionToModelGroup(this, PLAYER_IA_NONE); this->leftHandDLists = D_80125E08; Inventory_ChangeEquipment(EQUIP_SWORD, 2); gSaveContext.equips.buttonItems[0] = ITEM_SWORD_MASTER; @@ -14922,7 +14922,7 @@ void func_808528C8(PlayState* play, Player* this, CsCmdActorAction* arg2) { func_8084285C(this, 0.0f, 99.0f, this->skelAnime.endFrame - 8.0f); } - if (this->heldItemActionParam != PLAYER_AP_SWORD_MASTER) { + if (this->heldItemAction != PLAYER_IA_SWORD_MASTER) { func_80846720(play, this, 1); } } @@ -15046,7 +15046,7 @@ void func_80852E14(Player* this, PlayState* play) { s32 Player_IsDroppingFish(PlayState* play) { Player* this = GET_PLAYER(play); - return (func_8084EFC0 == this->func_674) && (this->itemActionParam == PLAYER_AP_BOTTLE_FISH); + return (func_8084EFC0 == this->func_674) && (this->itemAction == PLAYER_IA_BOTTLE_FISH); } s32 Player_StartFishing(PlayState* play) { @@ -15057,7 +15057,7 @@ s32 Player_StartFishing(PlayState* play) { gSaveContext.temporaryWeapon = true; } if (this->heldItemId == ITEM_NONE) { - this->currentSwordItem = ITEM_SWORD_KOKIRI; + this->currentSwordItemId = ITEM_SWORD_KOKIRI; gSaveContext.equips.buttonItems[0] = ITEM_SWORD_KOKIRI; Inventory_ChangeEquipment(EQUIP_SWORD, PLAYER_SWORD_KOKIRI); } @@ -15156,7 +15156,7 @@ void func_80853148(PlayState* play, Actor* actor) { if (func_808332B8(this)) { func_80836898(play, this, func_8083A2F8); func_80832C6C(play, this, &gPlayerAnim_link_swimer_swim_wait); - } else if ((actor->category != ACTORCAT_NPC) || (this->heldItemActionParam == PLAYER_AP_FISHING_POLE)) { + } else if ((actor->category != ACTORCAT_NPC) || (this->heldItemAction == PLAYER_IA_FISHING_POLE)) { func_8083A2F8(play, this); if (!func_8008E9C4(this)) { diff --git a/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c b/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c index 9d75c5753..6c8882814 100644 --- a/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c +++ b/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c @@ -2155,30 +2155,30 @@ void FileChoose_LoadGame(GameState* thisx) { gSaveContext.unk_13EE = 0x32; gSaveContext.nayrusLoveTimer = 0; gSaveContext.healthAccumulator = 0; - gSaveContext.unk_13F0 = 0; - gSaveContext.unk_13F2 = 0; + gSaveContext.magicState = 0; + gSaveContext.prevMagicState = 0; gSaveContext.forcedSeqId = NA_BGM_GENERAL_SFX; gSaveContext.skyboxTime = 0; - gSaveContext.nextTransition = 0xFF; + gSaveContext.nextTransitionType = 0xFF; gSaveContext.nextCutsceneIndex = 0xFFEF; gSaveContext.cutsceneTrigger = 0; gSaveContext.chamberCutsceneNum = 0; gSaveContext.nextDayTime = 0xFFFF; - gSaveContext.unk_13C3 = 0; + gSaveContext.retainWeatherMode = 0; for (int buttonIndex = 0; buttonIndex < ARRAY_COUNT(gSaveContext.buttonStatus); buttonIndex++) { gSaveContext.buttonStatus[buttonIndex] = BTN_ENABLED; } gSaveContext.unk_13E7 = gSaveContext.unk_13E8 = gSaveContext.unk_13EA = gSaveContext.unk_13EC = - gSaveContext.unk_13F4 = 0; + gSaveContext.magicCapacity = 0; - gSaveContext.unk_13F6 = gSaveContext.magic; + gSaveContext.magicFillTarget = gSaveContext.magic; gSaveContext.magic = 0; gSaveContext.magicLevel = gSaveContext.magic; osSyncPrintf(VT_FGCOL(GREEN)); - osSyncPrintf("Z_MAGIC_NOW_NOW=%d MAGIC_NOW=%d\n", ((void)0, gSaveContext.unk_13F6), gSaveContext.magic); + osSyncPrintf("Z_MAGIC_NOW_NOW=%d MAGIC_NOW=%d\n", ((void)0, gSaveContext.magicFillTarget), gSaveContext.magic); osSyncPrintf(VT_RST); gSaveContext.naviTimer = 0; diff --git a/soh/src/overlays/gamestates/ovl_select/z_select.c b/soh/src/overlays/gamestates/ovl_select/z_select.c index 278975528..743bb43c9 100644 --- a/soh/src/overlays/gamestates/ovl_select/z_select.c +++ b/soh/src/overlays/gamestates/ovl_select/z_select.c @@ -22,9 +22,9 @@ void Select_LoadGame(SelectContext* this, s32 entranceIndex) { osSyncPrintf(VT_RST); if (gSaveContext.fileNum == 0xFF) { Sram_InitDebugSave(); - gSaveContext.unk_13F6 = gSaveContext.magic; + gSaveContext.magicFillTarget = gSaveContext.magic; gSaveContext.magic = 0; - gSaveContext.unk_13F4 = 0; + gSaveContext.magicCapacity = 0; gSaveContext.magicLevel = gSaveContext.magic; } for (int buttonIndex = 0; buttonIndex < ARRAY_COUNT(gSaveContext.buttonStatus); buttonIndex++) { @@ -63,9 +63,9 @@ void Select_Grotto_LoadGame(SelectContext* this, s32 grottoIndex) { osSyncPrintf(VT_RST); if (gSaveContext.fileNum == 0xFF) { Sram_InitDebugSave(); - gSaveContext.unk_13F6 = gSaveContext.magic; + gSaveContext.magicFillTarget = gSaveContext.magic; gSaveContext.magic = 0; - gSaveContext.unk_13F4 = 0; + gSaveContext.magicCapacity = 0; gSaveContext.magicLevel = gSaveContext.magic; } for (int buttonIndex = 0; buttonIndex < ARRAY_COUNT(gSaveContext.buttonStatus); buttonIndex++) { diff --git a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c index c13ec7908..22821a5ac 100644 --- a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c +++ b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c @@ -4218,20 +4218,20 @@ void KaleidoScope_Update(PlayState* play) if (gSaveContext.n64ddFlag && Randomizer_GetSettingValue(RSK_SHUFFLE_ENTRANCES)) { Grotto_ForceGrottoReturn(); } - gSaveContext.nextTransition = 2; + gSaveContext.nextTransitionType = 2; gSaveContext.health = 0x30; Audio_QueueSeqCmd(0xF << 28 | SEQ_PLAYER_BGM_MAIN << 24 | 0xA); gSaveContext.healthAccumulator = 0; - gSaveContext.unk_13F0 = 0; - gSaveContext.unk_13F2 = 0; + gSaveContext.magicState = 0; + gSaveContext.prevMagicState = 0; osSyncPrintf(VT_FGCOL(YELLOW)); osSyncPrintf("MAGIC_NOW=%d ", gSaveContext.magic); - osSyncPrintf("Z_MAGIC_NOW_NOW=%d → ", gSaveContext.unk_13F6); - gSaveContext.unk_13F4 = 0; - gSaveContext.unk_13F6 = gSaveContext.magic; + osSyncPrintf("Z_MAGIC_NOW_NOW=%d → ", gSaveContext.magicFillTarget); + gSaveContext.magicCapacity = 0; + gSaveContext.magicFillTarget = gSaveContext.magic; gSaveContext.magicLevel = gSaveContext.magic = 0; osSyncPrintf("MAGIC_NOW=%d ", gSaveContext.magic); - osSyncPrintf("Z_MAGIC_NOW_NOW=%d\n", gSaveContext.unk_13F6); + osSyncPrintf("Z_MAGIC_NOW_NOW=%d\n", gSaveContext.magicFillTarget); osSyncPrintf(VT_RST); } else { play->state.running = 0; From 3cb9f93ff47fa1483de997d667c0f7b8318cd081 Mon Sep 17 00:00:00 2001 From: Garrett Cox Date: Tue, 29 Nov 2022 17:29:36 -0600 Subject: [PATCH 17/25] [docs] Pull upstream updates: SetupDL (#2048) --- soh/include/functions.h | 70 +-- soh/include/z64.h | 75 +++ soh/soh/Enhancements/randomizer/draw.cpp | 10 +- soh/src/code/z_actor.c | 18 +- soh/src/code/z_cheap_proc.c | 4 +- soh/src/code/z_debug_display.c | 4 +- soh/src/code/z_draw.c | 84 ++-- soh/src/code/z_eff_blure.c | 8 +- soh/src/code/z_eff_shield_particle.c | 2 +- soh/src/code/z_eff_spark.c | 2 +- soh/src/code/z_effect_soft_sprite_old_init.c | 2 +- soh/src/code/z_en_a_keep.c | 2 +- soh/src/code/z_en_item00.c | 10 +- soh/src/code/z_kankyo.c | 24 +- soh/src/code/z_lifemeter.c | 8 +- soh/src/code/z_map_exp.c | 8 +- soh/src/code/z_message_PAL.c | 6 +- soh/src/code/z_parameter.c | 14 +- soh/src/code/z_play.c | 2 +- soh/src/code/z_player_lib.c | 2 +- soh/src/code/z_prenmi.c | 4 +- soh/src/code/z_rcp.c | 459 +++++++++--------- soh/src/code/z_room.c | 12 +- soh/src/code/z_sample.c | 4 +- soh/src/code/z_vr_box_draw.c | 2 +- .../actors/ovl_Arms_Hook/z_arms_hook.c | 2 +- .../actors/ovl_Arrow_Fire/z_arrow_fire.c | 4 +- .../actors/ovl_Arrow_Ice/z_arrow_ice.c | 4 +- .../actors/ovl_Arrow_Light/z_arrow_light.c | 4 +- .../actors/ovl_Bg_Bowl_Wall/z_bg_bowl_wall.c | 2 +- .../actors/ovl_Bg_Breakwall/z_bg_breakwall.c | 2 +- .../actors/ovl_Bg_Dodoago/z_bg_dodoago.c | 2 +- .../ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c | 4 +- .../ovl_Bg_Ganon_Otyuka/z_bg_ganon_otyuka.c | 4 +- .../ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c | 2 +- .../ovl_Bg_Gjyo_Bridge/z_bg_gjyo_bridge.c | 2 +- .../ovl_Bg_Gnd_Firemeiro/z_bg_gnd_firemeiro.c | 2 +- .../ovl_Bg_Gnd_Soulmeiro/z_bg_gnd_soulmeiro.c | 2 +- .../overlays/actors/ovl_Bg_Haka/z_bg_haka.c | 4 +- .../actors/ovl_Bg_Haka_Gate/z_bg_haka_gate.c | 4 +- .../actors/ovl_Bg_Haka_Ship/z_bg_haka_ship.c | 2 +- .../actors/ovl_Bg_Haka_Tubo/z_bg_haka_tubo.c | 2 +- .../ovl_Bg_Haka_Water/z_bg_haka_water.c | 2 +- .../ovl_Bg_Heavy_Block/z_bg_heavy_block.c | 2 +- .../ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c | 2 +- .../z_bg_hidan_firewall.c | 2 +- .../ovl_Bg_Hidan_Fwbig/z_bg_hidan_fwbig.c | 2 +- .../ovl_Bg_Hidan_Hamstep/z_bg_hidan_hamstep.c | 2 +- .../ovl_Bg_Hidan_Kousi/z_bg_hidan_kousi.c | 2 +- .../z_bg_hidan_kowarerukabe.c | 2 +- .../ovl_Bg_Hidan_Rock/z_bg_hidan_rock.c | 2 +- .../z_bg_hidan_rsekizou.c | 4 +- .../ovl_Bg_Hidan_Sekizou/z_bg_hidan_sekizou.c | 4 +- .../ovl_Bg_Hidan_Sima/z_bg_hidan_sima.c | 4 +- .../ovl_Bg_Ice_Shelter/z_bg_ice_shelter.c | 2 +- .../actors/ovl_Bg_Ingate/z_bg_ingate.c | 2 +- .../ovl_Bg_Jya_Bigmirror/z_bg_jya_bigmirror.c | 2 +- .../actors/ovl_Bg_Jya_Block/z_bg_jya_block.c | 2 +- .../z_bg_jya_bombchuiwa.c | 4 +- .../actors/ovl_Bg_Jya_Cobra/z_bg_jya_cobra.c | 6 +- .../ovl_Bg_Jya_Megami/z_bg_jya_megami.c | 4 +- .../ovl_Bg_Menkuri_Eye/z_bg_menkuri_eye.c | 2 +- .../ovl_Bg_Mizu_Bwall/z_bg_mizu_bwall.c | 2 +- .../ovl_Bg_Mizu_Movebg/z_bg_mizu_movebg.c | 2 +- .../ovl_Bg_Mizu_Shutter/z_bg_mizu_shutter.c | 2 +- .../ovl_Bg_Mizu_Water/z_bg_mizu_water.c | 2 +- .../overlays/actors/ovl_Bg_Mjin/z_bg_mjin.c | 2 +- .../ovl_Bg_Mori_Bigst/z_bg_mori_bigst.c | 2 +- .../ovl_Bg_Mori_Elevator/z_bg_mori_elevator.c | 2 +- .../ovl_Bg_Mori_Hashigo/z_bg_mori_hashigo.c | 2 +- .../ovl_Bg_Mori_Hashira4/z_bg_mori_hashira4.c | 2 +- .../ovl_Bg_Mori_Hineri/z_bg_mori_hineri.c | 4 +- .../ovl_Bg_Mori_Idomizu/z_bg_mori_idomizu.c | 2 +- .../z_bg_mori_kaitenkabe.c | 2 +- .../z_bg_mori_rakkatenjo.c | 2 +- .../actors/ovl_Bg_Po_Event/z_bg_po_event.c | 2 +- .../ovl_Bg_Po_Syokudai/z_bg_po_syokudai.c | 4 +- .../actors/ovl_Bg_Pushbox/z_bg_pushbox.c | 2 +- .../z_bg_spot00_hanebasi.c | 4 +- .../ovl_Bg_Spot01_Fusya/z_bg_spot01_fusya.c | 2 +- .../z_bg_spot01_idohashira.c | 2 +- .../z_bg_spot01_idomizu.c | 2 +- .../z_bg_spot01_idosoko.c | 2 +- .../z_bg_spot02_objects.c | 4 +- .../ovl_Bg_Spot03_Taki/z_bg_spot03_taki.c | 2 +- .../z_bg_spot06_objects.c | 2 +- .../ovl_Bg_Spot07_Taki/z_bg_spot07_taki.c | 4 +- .../ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c | 2 +- .../ovl_Bg_Spot11_Oasis/z_bg_spot11_oasis.c | 2 +- .../ovl_Bg_Spot15_Saku/z_bg_spot15_saku.c | 2 +- .../z_bg_spot16_bombstone.c | 2 +- .../z_bg_spot16_doughnut.c | 4 +- .../z_bg_spot17_bakudankabe.c | 4 +- .../ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c | 2 +- .../actors/ovl_Bg_Sst_Floor/z_bg_sst_floor.c | 2 +- .../ovl_Bg_Toki_Hikari/z_bg_toki_hikari.c | 6 +- .../actors/ovl_Bg_Toki_Swd/z_bg_toki_swd.c | 2 +- .../actors/ovl_Bg_Treemouth/z_bg_treemouth.c | 2 +- .../actors/ovl_Bg_Vb_Sima/z_bg_vb_sima.c | 2 +- .../actors/ovl_Bg_Ydan_Hasi/z_bg_ydan_hasi.c | 2 +- .../actors/ovl_Bg_Ydan_Sp/z_bg_ydan_sp.c | 2 +- soh/src/overlays/actors/ovl_Bg_Zg/z_bg_zg.c | 2 +- .../actors/ovl_Boss_Dodongo/z_boss_dodongo.c | 4 +- .../overlays/actors/ovl_Boss_Fd/z_boss_fd.c | 14 +- .../overlays/actors/ovl_Boss_Fd2/z_boss_fd2.c | 4 +- .../actors/ovl_Boss_Ganon/z_boss_ganon.c | 20 +- .../actors/ovl_Boss_Ganon2/z_boss_ganon2.c | 16 +- .../ovl_Boss_Ganondrof/z_boss_ganondrof.c | 2 +- .../actors/ovl_Boss_Goma/z_boss_goma.c | 2 +- .../overlays/actors/ovl_Boss_Mo/z_boss_mo.c | 22 +- .../overlays/actors/ovl_Boss_Sst/z_boss_sst.c | 12 +- .../overlays/actors/ovl_Boss_Tw/z_boss_tw.c | 22 +- .../overlays/actors/ovl_Boss_Va/z_boss_va.c | 20 +- .../overlays/actors/ovl_Demo_6K/z_demo_6k.c | 16 +- .../overlays/actors/ovl_Demo_Du/z_demo_du.c | 4 +- .../overlays/actors/ovl_Demo_Ec/z_demo_ec.c | 4 +- .../actors/ovl_Demo_Effect/z_demo_effect.c | 30 +- .../overlays/actors/ovl_Demo_Ext/z_demo_ext.c | 2 +- .../actors/ovl_Demo_Geff/z_demo_geff.c | 2 +- .../overlays/actors/ovl_Demo_Gj/z_demo_gj.c | 4 +- .../overlays/actors/ovl_Demo_Go/z_demo_go.c | 2 +- .../overlays/actors/ovl_Demo_Gt/z_demo_gt.c | 18 +- .../overlays/actors/ovl_Demo_Ik/z_demo_ik.c | 8 +- .../overlays/actors/ovl_Demo_Im/z_demo_im.c | 4 +- .../actors/ovl_Demo_Kankyo/z_demo_kankyo.c | 14 +- .../actors/ovl_Demo_Kekkai/z_demo_kekkai.c | 4 +- .../overlays/actors/ovl_Demo_Sa/z_demo_sa.c | 4 +- .../overlays/actors/ovl_Demo_Shd/z_demo_shd.c | 2 +- .../actors/ovl_Demo_Tre_Lgt/z_demo_tre_lgt.c | 2 +- .../overlays/actors/ovl_Door_Ana/z_door_ana.c | 2 +- .../actors/ovl_Door_Gerudo/z_door_gerudo.c | 2 +- .../actors/ovl_Door_Killer/z_door_killer.c | 2 +- .../actors/ovl_Door_Shutter/z_door_shutter.c | 4 +- .../actors/ovl_Door_Warp1/z_door_warp1.c | 6 +- .../actors/ovl_Efc_Erupc/z_efc_erupc.c | 4 +- .../overlays/actors/ovl_Eff_Dust/z_eff_dust.c | 4 +- .../overlays/actors/ovl_Elf_Msg/z_elf_msg.c | 2 +- .../overlays/actors/ovl_Elf_Msg2/z_elf_msg2.c | 2 +- soh/src/overlays/actors/ovl_En_Am/z_en_am.c | 2 +- soh/src/overlays/actors/ovl_En_Ani/z_en_ani.c | 2 +- .../actors/ovl_En_Anubice/z_en_anubice.c | 2 +- .../ovl_En_Anubice_Fire/z_en_anubice_fire.c | 2 +- .../overlays/actors/ovl_En_Arrow/z_en_arrow.c | 4 +- .../ovl_En_Attack_Niw/z_en_attack_niw.c | 2 +- soh/src/overlays/actors/ovl_En_Ba/z_en_ba.c | 2 +- soh/src/overlays/actors/ovl_En_Bb/z_en_bb.c | 4 +- .../actors/ovl_En_Bdfire/z_en_bdfire.c | 4 +- .../actors/ovl_En_Bigokuta/z_en_bigokuta.c | 4 +- .../overlays/actors/ovl_En_Bili/z_en_bili.c | 2 +- .../actors/ovl_En_Blkobj/z_en_blkobj.c | 2 +- soh/src/overlays/actors/ovl_En_Bom/z_en_bom.c | 2 +- .../ovl_En_Bom_Bowl_Man/z_en_bom_bowl_man.c | 2 +- .../actors/ovl_En_Bom_Chu/z_en_bom_chu.c | 2 +- .../overlays/actors/ovl_En_Bombf/z_en_bombf.c | 2 +- .../overlays/actors/ovl_En_Boom/z_en_boom.c | 2 +- soh/src/overlays/actors/ovl_En_Box/z_en_box.c | 4 +- .../overlays/actors/ovl_En_Brob/z_en_brob.c | 2 +- .../actors/ovl_En_Bubble/z_en_bubble.c | 2 +- .../overlays/actors/ovl_En_Butte/z_en_butte.c | 4 +- soh/src/overlays/actors/ovl_En_Bw/z_en_bw.c | 6 +- soh/src/overlays/actors/ovl_En_Bx/z_en_bx.c | 2 +- .../actors/ovl_En_Clear_Tag/z_en_clear_tag.c | 8 +- soh/src/overlays/actors/ovl_En_Cow/z_en_cow.c | 4 +- .../overlays/actors/ovl_En_Crow/z_en_crow.c | 2 +- soh/src/overlays/actors/ovl_En_Cs/z_en_cs.c | 2 +- .../overlays/actors/ovl_En_Daiku/z_en_daiku.c | 2 +- .../z_en_daiku_kakariko.c | 2 +- .../actors/ovl_En_Dekubaba/z_en_dekubaba.c | 4 +- soh/src/overlays/actors/ovl_En_Dh/z_en_dh.c | 6 +- soh/src/overlays/actors/ovl_En_Dha/z_en_dha.c | 2 +- .../ovl_En_Diving_Game/z_en_diving_game.c | 2 +- soh/src/overlays/actors/ovl_En_Dns/z_en_dns.c | 2 +- .../actors/ovl_En_Dnt_Jiji/z_en_dnt_jiji.c | 2 +- .../actors/ovl_En_Dnt_Nomal/z_en_dnt_nomal.c | 4 +- .../actors/ovl_En_Dodojr/z_en_dodojr.c | 2 +- .../actors/ovl_En_Dodongo/z_en_dodongo.c | 2 +- soh/src/overlays/actors/ovl_En_Dog/z_en_dog.c | 2 +- .../overlays/actors/ovl_En_Door/z_en_door.c | 2 +- soh/src/overlays/actors/ovl_En_Ds/z_en_ds.c | 2 +- .../actors/ovl_En_Dy_Extra/z_en_dy_extra.c | 2 +- .../overlays/actors/ovl_En_Eiyer/z_en_eiyer.c | 4 +- soh/src/overlays/actors/ovl_En_Elf/z_en_elf.c | 2 +- .../actors/ovl_En_Ex_Item/z_en_ex_item.c | 2 +- .../actors/ovl_En_Ex_Ruppy/z_en_ex_ruppy.c | 2 +- soh/src/overlays/actors/ovl_En_Fd/z_en_fd.c | 10 +- .../actors/ovl_En_Fd_Fire/z_en_fd_fire.c | 2 +- .../actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c | 8 +- .../actors/ovl_En_Fire_Rock/z_en_fire_rock.c | 2 +- .../actors/ovl_En_Firefly/z_en_firefly.c | 4 +- .../overlays/actors/ovl_En_Fish/z_en_fish.c | 2 +- .../actors/ovl_En_Floormas/z_en_floormas.c | 4 +- soh/src/overlays/actors/ovl_En_Fr/z_en_fr.c | 2 +- soh/src/overlays/actors/ovl_En_Fu/z_en_fu.c | 2 +- soh/src/overlays/actors/ovl_En_Fw/z_en_fw.c | 6 +- soh/src/overlays/actors/ovl_En_Fz/z_en_fz.c | 4 +- .../actors/ovl_En_G_Switch/z_en_g_switch.c | 10 +- .../ovl_En_Ganon_Organ/z_en_ganon_organ.c | 2 +- soh/src/overlays/actors/ovl_En_Gb/z_en_gb.c | 4 +- soh/src/overlays/actors/ovl_En_Ge1/z_en_ge1.c | 2 +- soh/src/overlays/actors/ovl_En_Ge2/z_en_ge2.c | 2 +- soh/src/overlays/actors/ovl_En_Ge3/z_en_ge3.c | 2 +- .../overlays/actors/ovl_En_GeldB/z_en_geldb.c | 2 +- soh/src/overlays/actors/ovl_En_Gm/z_en_gm.c | 2 +- soh/src/overlays/actors/ovl_En_Go/z_en_go.c | 10 +- soh/src/overlays/actors/ovl_En_Go2/z_en_go2.c | 10 +- .../overlays/actors/ovl_En_Goma/z_en_goma.c | 2 +- soh/src/overlays/actors/ovl_En_Gs/z_en_gs.c | 4 +- .../overlays/actors/ovl_En_Guest/z_en_guest.c | 2 +- .../overlays/actors/ovl_En_Hata/z_en_hata.c | 2 +- .../actors/ovl_En_Heishi1/z_en_heishi1.c | 2 +- .../actors/ovl_En_Heishi2/z_en_heishi2.c | 2 +- .../actors/ovl_En_Heishi3/z_en_heishi3.c | 2 +- .../actors/ovl_En_Heishi4/z_en_heishi4.c | 2 +- .../overlays/actors/ovl_En_Holl/z_en_holl.c | 2 +- .../actors/ovl_En_Honotrap/z_en_honotrap.c | 4 +- .../overlays/actors/ovl_En_Horse/z_en_horse.c | 2 +- .../ovl_En_Horse_Ganon/z_en_horse_ganon.c | 2 +- .../z_en_horse_link_child.c | 2 +- .../ovl_En_Horse_Normal/z_en_horse_normal.c | 4 +- .../ovl_En_Horse_Zelda/z_en_horse_zelda.c | 2 +- soh/src/overlays/actors/ovl_En_Hs/z_en_hs.c | 2 +- soh/src/overlays/actors/ovl_En_Hs2/z_en_hs2.c | 2 +- soh/src/overlays/actors/ovl_En_Hy/z_en_hy.c | 2 +- .../actors/ovl_En_Ice_Hono/z_en_ice_hono.c | 2 +- soh/src/overlays/actors/ovl_En_Ik/z_en_ik.c | 12 +- soh/src/overlays/actors/ovl_En_In/z_en_in.c | 2 +- .../actors/ovl_En_Insect/z_en_insect.c | 2 +- .../overlays/actors/ovl_En_Ishi/z_en_ishi.c | 2 +- soh/src/overlays/actors/ovl_En_Jj/z_en_jj.c | 2 +- soh/src/overlays/actors/ovl_En_Js/z_en_js.c | 2 +- .../actors/ovl_En_Jsjutan/z_en_jsjutan.c | 4 +- .../actors/ovl_En_Kakasi/z_en_kakasi.c | 2 +- .../actors/ovl_En_Kakasi2/z_en_kakasi2.c | 2 +- .../actors/ovl_En_Kakasi3/z_en_kakasi3.c | 2 +- .../actors/ovl_En_Kanban/z_en_kanban.c | 4 +- .../actors/ovl_En_Karebaba/z_en_karebaba.c | 4 +- soh/src/overlays/actors/ovl_En_Kz/z_en_kz.c | 2 +- .../overlays/actors/ovl_En_Light/z_en_light.c | 2 +- .../actors/ovl_En_M_Thunder/z_en_m_thunder.c | 2 +- soh/src/overlays/actors/ovl_En_Ma1/z_en_ma1.c | 2 +- soh/src/overlays/actors/ovl_En_Ma2/z_en_ma2.c | 2 +- soh/src/overlays/actors/ovl_En_Ma3/z_en_ma3.c | 2 +- soh/src/overlays/actors/ovl_En_Mag/z_en_mag.c | 14 +- soh/src/overlays/actors/ovl_En_Mb/z_en_mb.c | 2 +- soh/src/overlays/actors/ovl_En_Mk/z_en_mk.c | 2 +- soh/src/overlays/actors/ovl_En_Mm/z_en_mm.c | 2 +- soh/src/overlays/actors/ovl_En_Mm2/z_en_mm2.c | 2 +- soh/src/overlays/actors/ovl_En_Ms/z_en_ms.c | 2 +- soh/src/overlays/actors/ovl_En_Nb/z_en_nb.c | 8 +- soh/src/overlays/actors/ovl_En_Niw/z_en_niw.c | 4 +- .../actors/ovl_En_Niw_Girl/z_en_niw_girl.c | 2 +- .../actors/ovl_En_Niw_Lady/z_en_niw_lady.c | 2 +- .../actors/ovl_En_Nutsball/z_en_nutsball.c | 4 +- soh/src/overlays/actors/ovl_En_Nwc/z_en_nwc.c | 2 +- soh/src/overlays/actors/ovl_En_Ny/z_en_ny.c | 6 +- .../overlays/actors/ovl_En_Okuta/z_en_okuta.c | 4 +- .../overlays/actors/ovl_En_Ossan/z_en_ossan.c | 18 +- soh/src/overlays/actors/ovl_En_Owl/z_en_owl.c | 2 +- .../overlays/actors/ovl_En_Part/z_en_part.c | 2 +- .../actors/ovl_En_Peehat/z_en_peehat.c | 2 +- .../actors/ovl_En_Po_Desert/z_en_po_desert.c | 2 +- .../actors/ovl_En_Po_Field/z_en_po_field.c | 10 +- .../actors/ovl_En_Po_Relay/z_en_po_relay.c | 2 +- .../ovl_En_Po_Sisters/z_en_po_sisters.c | 4 +- soh/src/overlays/actors/ovl_En_Poh/z_en_poh.c | 14 +- soh/src/overlays/actors/ovl_En_Rd/z_en_rd.c | 4 +- .../overlays/actors/ovl_En_Reeba/z_en_reeba.c | 2 +- soh/src/overlays/actors/ovl_En_Rl/z_en_rl.c | 4 +- soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c | 2 +- soh/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c | 4 +- soh/src/overlays/actors/ovl_En_Ru2/z_en_ru2.c | 4 +- .../ovl_En_Scene_Change/z_en_scene_change.c | 2 +- soh/src/overlays/actors/ovl_En_Sda/z_en_sda.c | 2 +- .../actors/ovl_En_Siofuki/z_en_siofuki.c | 2 +- soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c | 2 +- soh/src/overlays/actors/ovl_En_Skj/z_en_skj.c | 4 +- .../actors/ovl_En_Skjneedle/z_en_skjneedle.c | 2 +- soh/src/overlays/actors/ovl_En_St/z_en_st.c | 2 +- soh/src/overlays/actors/ovl_En_Sth/z_en_sth.c | 2 +- .../actors/ovl_En_Stream/z_en_stream.c | 2 +- soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c | 2 +- .../ovl_En_Syateki_Man/z_en_syateki_man.c | 2 +- .../ovl_En_Syateki_Niw/z_en_syateki_niw.c | 4 +- soh/src/overlays/actors/ovl_En_Ta/z_en_ta.c | 2 +- .../ovl_En_Takara_Man/z_en_takara_man.c | 2 +- .../overlays/actors/ovl_En_Tana/z_en_tana.c | 4 +- .../overlays/actors/ovl_En_Test/z_en_test.c | 2 +- .../overlays/actors/ovl_En_Tite/z_en_tite.c | 2 +- soh/src/overlays/actors/ovl_En_Tk/z_en_tk.c | 6 +- .../actors/ovl_En_Torch2/z_en_torch2.c | 2 +- .../overlays/actors/ovl_En_Toryo/z_en_toryo.c | 2 +- soh/src/overlays/actors/ovl_En_Tp/z_en_tp.c | 4 +- soh/src/overlays/actors/ovl_En_Tr/z_en_tr.c | 2 +- .../overlays/actors/ovl_En_Vali/z_en_vali.c | 2 +- .../actors/ovl_En_Vb_Ball/z_en_vb_ball.c | 4 +- .../actors/ovl_En_Viewer/z_en_viewer.c | 8 +- soh/src/overlays/actors/ovl_En_Vm/z_en_vm.c | 6 +- .../actors/ovl_En_Wallmas/z_en_wallmas.c | 4 +- .../actors/ovl_En_Weiyer/z_en_weiyer.c | 4 +- soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c | 2 +- .../actors/ovl_En_Wood02/z_en_wood02.c | 6 +- soh/src/overlays/actors/ovl_En_Xc/z_en_xc.c | 12 +- .../actors/ovl_En_Yukabyun/z_en_yukabyun.c | 2 +- soh/src/overlays/actors/ovl_En_Zf/z_en_zf.c | 4 +- soh/src/overlays/actors/ovl_En_Zl1/z_en_zl1.c | 2 +- soh/src/overlays/actors/ovl_En_Zl2/z_en_zl2.c | 4 +- soh/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c | 4 +- soh/src/overlays/actors/ovl_En_Zl4/z_en_zl4.c | 2 +- soh/src/overlays/actors/ovl_En_Zo/z_en_zo.c | 6 +- soh/src/overlays/actors/ovl_En_fHG/z_en_fhg.c | 2 +- .../actors/ovl_End_Title/z_end_title.c | 6 +- .../overlays/actors/ovl_Fishing/z_fishing.c | 24 +- .../actors/ovl_Item_B_Heart/z_item_b_heart.c | 4 +- .../actors/ovl_Item_Shield/z_item_shield.c | 2 +- .../actors/ovl_Magic_Dark/z_magic_dark.c | 4 +- .../actors/ovl_Magic_Fire/z_magic_fire.c | 4 +- .../actors/ovl_Magic_Wind/z_magic_wind.c | 2 +- .../overlays/actors/ovl_Mir_Ray/z_mir_ray.c | 2 +- .../overlays/actors/ovl_Obj_Comb/z_obj_comb.c | 2 +- .../actors/ovl_Obj_Dekujr/z_obj_dekujr.c | 4 +- .../actors/ovl_Obj_Hamishi/z_obj_hamishi.c | 2 +- .../actors/ovl_Obj_Hsblock/z_obj_hsblock.c | 2 +- .../actors/ovl_Obj_Ice_Poly/z_obj_ice_poly.c | 2 +- .../ovl_Obj_Lightswitch/z_obj_lightswitch.c | 4 +- .../actors/ovl_Obj_Oshihiki/z_obj_oshihiki.c | 2 +- .../actors/ovl_Obj_Switch/z_obj_switch.c | 6 +- .../actors/ovl_Obj_Syokudai/z_obj_syokudai.c | 4 +- .../ovl_Obj_Timeblock/z_obj_timeblock.c | 2 +- .../ovl_Obj_Warp2block/z_obj_warp2block.c | 2 +- .../ovl_Object_Kankyo/z_object_kankyo.c | 10 +- .../actors/ovl_Oceff_Spot/z_oceff_spot.c | 2 +- .../actors/ovl_Oceff_Storm/z_oceff_storm.c | 4 +- .../actors/ovl_Oceff_Wipe/z_oceff_wipe.c | 2 +- .../actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c | 2 +- .../actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c | 2 +- .../actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c | 2 +- .../actors/ovl_player_actor/z_player.c | 2 +- .../ovl_Effect_Ss_Blast/z_eff_ss_blast.c | 2 +- .../ovl_Effect_Ss_Bomb/z_eff_ss_bomb.c | 2 +- .../ovl_Effect_Ss_Bomb2/z_eff_ss_bomb2.c | 4 +- .../ovl_Effect_Ss_Bubble/z_eff_ss_bubble.c | 2 +- .../ovl_Effect_Ss_D_Fire/z_eff_ss_d_fire.c | 2 +- .../ovl_Effect_Ss_Dead_Db/z_eff_ss_dead_db.c | 2 +- .../ovl_Effect_Ss_Dead_Dd/z_eff_ss_dead_dd.c | 2 +- .../ovl_Effect_Ss_Dead_Ds/z_eff_ss_dead_ds.c | 2 +- .../z_eff_ss_dt_bubble.c | 2 +- .../ovl_Effect_Ss_Dust/z_eff_ss_dust.c | 2 +- .../ovl_Effect_Ss_En_Fire/z_eff_ss_en_fire.c | 2 +- .../ovl_Effect_Ss_En_Ice/z_eff_ss_en_ice.c | 2 +- .../ovl_Effect_Ss_Extra/z_eff_ss_extra.c | 2 +- .../ovl_Effect_Ss_Fcircle/z_eff_ss_fcircle.c | 2 +- .../z_eff_ss_fhg_flash.c | 6 +- .../z_eff_ss_fire_tail.c | 2 +- .../z_eff_ss_g_magma2.c | 4 +- .../z_eff_ss_g_ripple.c | 2 +- .../ovl_Effect_Ss_G_Spk/z_eff_ss_g_spk.c | 2 +- .../ovl_Effect_Ss_Hahen/z_eff_ss_hahen.c | 4 +- .../ovl_Effect_Ss_HitMark/z_eff_ss_hitmark.c | 2 +- .../z_eff_ss_ice_piece.c | 2 +- .../z_eff_ss_ice_smoke.c | 2 +- .../ovl_Effect_Ss_K_Fire/z_eff_ss_k_fire.c | 2 +- .../ovl_Effect_Ss_Kakera/z_eff_ss_kakera.c | 4 +- .../z_eff_ss_kirakira.c | 2 +- .../z_eff_ss_lightning.c | 2 +- .../ovl_Effect_Ss_Sibuki/z_eff_ss_sibuki.c | 2 +- .../ovl_Effect_Ss_Sibuki2/z_eff_ss_sibuki2.c | 2 +- .../ovl_Effect_Ss_Stick/z_eff_ss_stick.c | 2 +- .../ovl_Effect_Ss_Stone1/z_eff_ss_stone1.c | 2 +- .../ovl_file_choose/z_file_choose.c | 10 +- .../ovl_file_choose/z_file_nameset_PAL.c | 4 +- .../gamestates/ovl_opening/z_opening.c | 2 +- .../overlays/gamestates/ovl_select/z_select.c | 10 +- .../overlays/gamestates/ovl_title/z_title.c | 8 +- .../misc/ovl_kaleido_scope/z_kaleido_debug.c | 2 +- .../ovl_kaleido_scope/z_kaleido_equipment.c | 4 +- .../misc/ovl_kaleido_scope/z_kaleido_item.c | 2 +- .../ovl_kaleido_scope/z_kaleido_map_PAL.c | 4 +- .../ovl_kaleido_scope/z_kaleido_scope_PAL.c | 12 +- 378 files changed, 1114 insertions(+), 1022 deletions(-) diff --git a/soh/include/functions.h b/soh/include/functions.h index b4bdc9463..02026ed5d 100644 --- a/soh/include/functions.h +++ b/soh/include/functions.h @@ -1173,42 +1173,42 @@ s16 Quake_Calc(Camera* camera, QuakeCamCalc* camData); Gfx* Gfx_SetFog(Gfx* gfx, s32 r, s32 g, s32 b, s32 a, s32 near, s32 far); Gfx* Gfx_SetFogWithSync(Gfx* gfx, s32 r, s32 g, s32 b, s32 a, s32 near, s32 far); Gfx* Gfx_SetFog2(Gfx* gfx, s32 r, s32 g, s32 b, s32 a, s32 near, s32 far); -Gfx* Gfx_CallSetupDL(Gfx* gfx, u32 i); -Gfx* func_800937C0(Gfx* gfx); -Gfx* func_80093808(Gfx* gfx); -void func_800938B4(GraphicsContext* gfxCtx); -void func_8009398C(GraphicsContext* gfxCtx); -void func_80093AD0(GraphicsContext* gfxCtx); -void func_80093BA8(GraphicsContext* gfxCtx); -void func_80093C14(GraphicsContext* gfxCtx); +Gfx* Gfx_SetupDL(Gfx* gfx, u32 i); +Gfx* Gfx_SetupDL_57(Gfx* gfx); +Gfx* Gfx_SetupDL_52NoCD(Gfx* gfx); +void Gfx_SetupDL_57Opa(GraphicsContext* gfxCtx); +void Gfx_SetupDL_51Opa(GraphicsContext* gfxCtx); +void Gfx_SetupDL_54Opa(GraphicsContext* gfxCtx); +void Gfx_SetupDL_26Opa(GraphicsContext* gfxCtx); +void Gfx_SetupDL_25Xlu2(GraphicsContext* gfxCtx); void func_80093C80(PlayState* play); -void func_80093D18(GraphicsContext* gfxCtx); -void func_80093D84(GraphicsContext* gfxCtx); -Gfx* func_80093F34(Gfx* gfx); -Gfx* func_80093F58(Gfx* gfx); -void func_80094044(GraphicsContext* gfxCtx); -void func_800940B0(GraphicsContext* gfxCtx); -void func_80094140(GraphicsContext* gfxCtx); -Gfx* func_8009411C(Gfx* gfx); -void func_800942F0(GraphicsContext* gfxCtx); -void func_8009435C(GraphicsContext* gfxCtx); -void func_800943C8(GraphicsContext* gfxCtx); -Gfx* func_800944A0(Gfx* gfx); -void func_800944C4(GraphicsContext* gfxCtx); -void func_80094520(GraphicsContext* gfxCtx); -void func_8009457C(Gfx** gfxp); -void func_800945A0(GraphicsContext* gfxCtx); -void func_8009460C(GraphicsContext* gfxCtx); -void func_80094678(GraphicsContext* gfxCtx); -Gfx* func_80094968(Gfx* gfx); -Gfx* func_800946E4(Gfx* gfx); +void Gfx_SetupDL_25Opa(GraphicsContext* gfxCtx); +void Gfx_SetupDL_25Xlu(GraphicsContext* gfxCtx); +Gfx* Gfx_SetupDL_64(Gfx* gfx); +Gfx* Gfx_SetupDL_34(Gfx* gfx); +void Gfx_SetupDL_44Xlu(GraphicsContext* gfxCtx); +void Gfx_SetupDL_36Opa(GraphicsContext* gfxCtx); +void Gfx_SetupDL_28Opa(GraphicsContext* gfxCtx); +Gfx* Gfx_SetupDL_28(Gfx* gfx); +void Gfx_SetupDL_38Xlu(GraphicsContext* gfxCtx); +void Gfx_SetupDL_4Xlu(GraphicsContext* gfxCtx); +void Gfx_SetupDL_37Opa(GraphicsContext* gfxCtx); +Gfx* Gfx_SetupDL_39(Gfx* gfx); +void Gfx_SetupDL_39Opa(GraphicsContext* gfxCtx); +void Gfx_SetupDL_39Overlay(GraphicsContext* gfxCtx); +void Gfx_SetupDL_39Ptr(Gfx** gfxp); +void Gfx_SetupDL_40Opa(GraphicsContext* gfxCtx); +void Gfx_SetupDL_41Opa(GraphicsContext* gfxCtx); +void Gfx_SetupDL_47Xlu(GraphicsContext* gfxCtx); +Gfx* Gfx_SetupDL_20NoCD(Gfx* gfx); +Gfx* Gfx_SetupDL_66(Gfx* gfx); Gfx* func_800947AC(Gfx* gfx); -void func_800949A8(GraphicsContext* gfxCtx); -void func_80094A14(GraphicsContext* gfxCtx); -void func_80094B58(GraphicsContext* gfxCtx); -void func_80094BC4(GraphicsContext* gfxCtx); -void func_80094C50(GraphicsContext* gfxCtx); -void func_80094D28(Gfx** gfxp); +void Gfx_SetupDL_42Opa(GraphicsContext* gfxCtx); +void Gfx_SetupDL_42Overlay(GraphicsContext* gfxCtx); +void Gfx_SetupDL_27Xlu(GraphicsContext* gfxCtx); +void Gfx_SetupDL_60NoCDXlu(GraphicsContext* gfxCtx); +void Gfx_SetupDL_61Xlu(GraphicsContext* gfxCtx); +void Gfx_SetupDL_56Ptr(Gfx** gfxp); Gfx* Gfx_BranchTexScroll(Gfx** gfxp, u32 x, u32 y, s32 width, s32 height); Gfx* func_80094E78(GraphicsContext* gfxCtx, u32 x, u32 y); Gfx* Gfx_TexScroll(GraphicsContext* gfxCtx, u32 x, u32 y, s32 width, s32 height); @@ -1217,7 +1217,7 @@ Gfx* Gfx_TwoTexScroll(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 wi Gfx* Gfx_TwoTexScrollEnvColor(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 width1, s32 height1, s32 tile2, u32 x2, u32 y2, s32 width2, s32 height2, s32 r, s32 g, s32 b, s32 a); Gfx* Gfx_EnvColor(GraphicsContext* gfxCtx, s32 r, s32 g, s32 b, s32 a); -void func_80095248(GraphicsContext* gfxCtx, u8 r, u8 g, u8 b); +void Gfx_SetupFrame(GraphicsContext* gfxCtx, u8 r, u8 g, u8 b); void func_80095974(GraphicsContext* gfxCtx); void func_80095AA0(PlayState* play, Room* room, Input* arg2, UNK_TYPE arg3); void func_8009638C(Gfx** displayList, void* source, void* tlut, u16 width, u16 height, u8 fmt, u8 siz, u16 mode0, diff --git a/soh/include/z64.h b/soh/include/z64.h index b83e650b7..a2efaf16a 100644 --- a/soh/include/z64.h +++ b/soh/include/z64.h @@ -213,6 +213,81 @@ typedef struct { /* 0x0124 */ s32 unk_124; } View; // size = 0x128 +typedef enum { + /* 0 */ SETUPDL_0, + /* 1 */ SETUPDL_1, + /* 2 */ SETUPDL_2, + /* 3 */ SETUPDL_3, + /* 4 */ SETUPDL_4, + /* 5 */ SETUPDL_5, + /* 6 */ SETUPDL_6, + /* 7 */ SETUPDL_7, + /* 8 */ SETUPDL_8, + /* 9 */ SETUPDL_9, + /* 10 */ SETUPDL_10, + /* 11 */ SETUPDL_11, + /* 12 */ SETUPDL_12, + /* 13 */ SETUPDL_13, + /* 14 */ SETUPDL_14, + /* 15 */ SETUPDL_15, + /* 16 */ SETUPDL_16, + /* 17 */ SETUPDL_17, + /* 18 */ SETUPDL_18, + /* 19 */ SETUPDL_19, + /* 20 */ SETUPDL_20, + /* 21 */ SETUPDL_21, + /* 22 */ SETUPDL_22, + /* 23 */ SETUPDL_23, + /* 24 */ SETUPDL_24, + /* 25 */ SETUPDL_25, + /* 26 */ SETUPDL_26, + /* 27 */ SETUPDL_27, + /* 28 */ SETUPDL_28, + /* 29 */ SETUPDL_29, + /* 30 */ SETUPDL_30, + /* 31 */ SETUPDL_31, + /* 32 */ SETUPDL_32, + /* 33 */ SETUPDL_33, + /* 34 */ SETUPDL_34, + /* 35 */ SETUPDL_35, + /* 36 */ SETUPDL_36, + /* 37 */ SETUPDL_37, + /* 38 */ SETUPDL_38, + /* 39 */ SETUPDL_39, + /* 40 */ SETUPDL_40, + /* 41 */ SETUPDL_41, + /* 42 */ SETUPDL_42, + /* 43 */ SETUPDL_43, + /* 44 */ SETUPDL_44, + /* 45 */ SETUPDL_45, + /* 46 */ SETUPDL_46, + /* 47 */ SETUPDL_47, + /* 48 */ SETUPDL_48, + /* 49 */ SETUPDL_49, + /* 50 */ SETUPDL_50, + /* 51 */ SETUPDL_51, + /* 52 */ SETUPDL_52, + /* 53 */ SETUPDL_53, + /* 54 */ SETUPDL_54, + /* 55 */ SETUPDL_55, + /* 56 */ SETUPDL_56, + /* 57 */ SETUPDL_57, + /* 58 */ SETUPDL_58, + /* 59 */ SETUPDL_59, + /* 60 */ SETUPDL_60, + /* 61 */ SETUPDL_61, + /* 62 */ SETUPDL_62, + /* 63 */ SETUPDL_63, + /* 64 */ SETUPDL_64, + /* 65 */ SETUPDL_65, + /* 66 */ SETUPDL_66, + /* 67 */ SETUPDL_67, + /* 68 */ SETUPDL_68, + /* 69 */ SETUPDL_69, + /* 70 */ SETUPDL_70, + /* 71 */ SETUPDL_MAX +} SetupDL; + typedef struct { /* 0x00 */ u8 seqId; /* 0x01 */ u8 natureAmbienceId; diff --git a/soh/soh/Enhancements/randomizer/draw.cpp b/soh/soh/Enhancements/randomizer/draw.cpp index 33e14b5ef..63293c48c 100644 --- a/soh/soh/Enhancements/randomizer/draw.cpp +++ b/soh/soh/Enhancements/randomizer/draw.cpp @@ -26,7 +26,7 @@ extern "C" void Randomizer_DrawSmallKey(PlayState* play, GetItemEntry* getItemEn OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(play->state.gfxCtx, (char*)__FILE__, __LINE__), G_MTX_MODELVIEW | G_MTX_LOAD); @@ -56,7 +56,7 @@ extern "C" void Randomizer_DrawBossKey(PlayState* play, GetItemEntry* getItemEnt OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(play->state.gfxCtx, (char*)__FILE__, __LINE__), G_MTX_MODELVIEW | G_MTX_LOAD); @@ -72,7 +72,7 @@ extern "C" void Randomizer_DrawBossKey(PlayState* play, GetItemEntry* getItemEnt gSPGrayscale(POLY_OPA_DISP++, false); } - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(play->state.gfxCtx, (char*)__FILE__, __LINE__), G_MTX_MODELVIEW | G_MTX_LOAD); @@ -106,7 +106,7 @@ extern "C" void Randomizer_DrawKeyRing(PlayState* play, GetItemEntry* getItemEnt OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetGrayscaleColor(POLY_OPA_DISP++, colors[color_slot][0], colors[color_slot][1], colors[color_slot][2], 255); gSPGrayscale(POLY_OPA_DISP++, true); @@ -140,7 +140,7 @@ extern "C" void Randomizer_DrawDoubleDefense(PlayState* play, GetItemEntry getIt s32 pad; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(play->state.gfxCtx, (char*)__FILE__, __LINE__), G_MTX_MODELVIEW | G_MTX_LOAD); diff --git a/soh/src/code/z_actor.c b/soh/src/code/z_actor.c index cc475f1c5..2e17eeacc 100644 --- a/soh/src/code/z_actor.c +++ b/soh/src/code/z_actor.c @@ -95,7 +95,7 @@ void ActorShadow_Draw(Actor* actor, Lights* lights, PlayState* play, Gfx* dlist, if (temp1 >= -50.0f && temp1 < 500.0f) { OPEN_DISPS(play->state.gfxCtx); - POLY_OPA_DISP = Gfx_CallSetupDL(POLY_OPA_DISP, 0x2C); + POLY_OPA_DISP = Gfx_SetupDL(POLY_OPA_DISP, 0x2C); gDPSetCombineLERP(POLY_OPA_DISP++, 0, 0, 0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0, 0, 0, 0, COMBINED, 0, 0, 0, COMBINED); @@ -202,7 +202,7 @@ void ActorShadow_DrawFeet(Actor* actor, Lights* lights, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - POLY_OPA_DISP = Gfx_CallSetupDL(POLY_OPA_DISP, 0x2C); + POLY_OPA_DISP = Gfx_SetupDL(POLY_OPA_DISP, 0x2C); actor->shape.feetFloorFlags = 0; @@ -465,7 +465,7 @@ void func_8002C124(TargetContext* targetCtx, PlayState* play) { func_8002BE64(targetCtx, targetCtx->unk_4C, spBC.x, spBC.y, spBC.z); if ((!(player->stateFlags1 & 0x40)) || (actor != player->unk_664)) { - OVERLAY_DISP = Gfx_CallSetupDL(OVERLAY_DISP, 0x39); + OVERLAY_DISP = Gfx_SetupDL(OVERLAY_DISP, 0x39); for (spB0 = 0, spAC = targetCtx->unk_4C; spB0 < spB8; spB0++, spAC = (spAC + 1) % 3) { entry = &targetCtx->arr_50[spAC]; @@ -509,7 +509,7 @@ void func_8002C124(TargetContext* targetCtx, PlayState* play) { FrameInterpolation_RecordOpenChild(actor, 1); NaviColor* naviColor = &sNaviColorList[actor->category]; - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x7); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x7); Matrix_Translate(actor->focus.pos.x, actor->focus.pos.y + (actor->targetArrowOffset * actor->scale.y) + 17.0f, actor->focus.pos.z, MTXMODE_NEW); @@ -1105,7 +1105,7 @@ void TitleCard_Draw(PlayState* play, TitleCardContext* titleCtx) { } // WORLD_OVERLAY_DISP Goes over POLY_XLU_DISP but under POLY_KAL_DISP - WORLD_OVERLAY_DISP = func_80093808(WORLD_OVERLAY_DISP); + WORLD_OVERLAY_DISP = Gfx_SetupDL_52NoCD(WORLD_OVERLAY_DISP); gDPSetPrimColor(WORLD_OVERLAY_DISP++, 0, 0, (u8)titleCtx->intensityR, (u8)titleCtx->intensityG, (u8)titleCtx->intensityB, (u8)titleCtx->alpha); @@ -2384,7 +2384,7 @@ void Actor_DrawFaroresWindPointer(PlayState* play) { (((void)0, gSaveContext.respawn[RESPAWN_MODE_TOP].roomIndex) == play->roomCtx.curRoom.num)) { f32 scale = 0.025f * ratio; - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x19); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x19); Matrix_Translate(((void)0, gSaveContext.respawn[RESPAWN_MODE_TOP].pos.x), ((void)0, gSaveContext.respawn[RESPAWN_MODE_TOP].pos.y) + yOffset, @@ -3969,7 +3969,7 @@ void func_80033C30(Vec3f* arg0, Vec3f* arg1, u8 alpha, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - POLY_OPA_DISP = Gfx_CallSetupDL(POLY_OPA_DISP, 0x2C); + POLY_OPA_DISP = Gfx_SetupDL(POLY_OPA_DISP, 0x2C); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 0, 0, 0, alpha); @@ -4344,7 +4344,7 @@ void func_80034BA0(PlayState* play, SkelAnime* skelAnime, OverrideLimbDraw overr PostLimbDraw postLimbDraw, Actor* actor, s16 alpha) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPPipeSync(POLY_OPA_DISP++); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, alpha); @@ -4361,7 +4361,7 @@ void func_80034CC4(PlayState* play, SkelAnime* skelAnime, OverrideLimbDraw overr PostLimbDraw postLimbDraw, Actor* actor, s16 alpha) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPPipeSync(POLY_XLU_DISP++); gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, alpha); diff --git a/soh/src/code/z_cheap_proc.c b/soh/src/code/z_cheap_proc.c index 73afef668..a5d0a8bc9 100644 --- a/soh/src/code/z_cheap_proc.c +++ b/soh/src/code/z_cheap_proc.c @@ -3,7 +3,7 @@ void Gfx_DrawDListOpa(PlayState* play, Gfx* dlist) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, dlist); @@ -14,7 +14,7 @@ void Gfx_DrawDListOpa(PlayState* play, Gfx* dlist) { void Gfx_DrawDListXlu(PlayState* play, Gfx* dlist) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, dlist); diff --git a/soh/src/code/z_debug_display.c b/soh/src/code/z_debug_display.c index 48cca9149..e6f3764c8 100644 --- a/soh/src/code/z_debug_display.c +++ b/soh/src/code/z_debug_display.c @@ -69,7 +69,7 @@ void DebugDisplay_DrawObjects(PlayState* play) { void DebugDisplay_DrawSpriteI8(DebugDispObject* dispObj, void* texture, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80094678(play->state.gfxCtx); + Gfx_SetupDL_47Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, dispObj->color.r, dispObj->color.g, dispObj->color.b, dispObj->color.a); @@ -91,7 +91,7 @@ void DebugDisplay_DrawSpriteI8(DebugDispObject* dispObj, void* texture, PlayStat void DebugDisplay_DrawPolygon(DebugDispObject* dispObj, void* dlist, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_8009435C(play->state.gfxCtx); + Gfx_SetupDL_4Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, dispObj->color.r, dispObj->color.g, dispObj->color.b, dispObj->color.a); diff --git a/soh/src/code/z_draw.c b/soh/src/code/z_draw.c index bae750100..9a2de4b46 100644 --- a/soh/src/code/z_draw.c +++ b/soh/src/code/z_draw.c @@ -484,13 +484,13 @@ void GetItem_DrawJewel(PlayState* play, s16 drawId) { gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(play->state.gfxCtx, "../z_demo_effect.c", 2599), G_MTX_NOPUSH | G_MTX_LOAD); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); // func_8002ED80(&this->actor, play, 0); gDPSetPrimColor(POLY_XLU_DISP++, 0, 128, primXluColor[0], primXluColor[1], primXluColor[2], 255); gDPSetEnvColor(POLY_XLU_DISP++, envXluColor[0], envXluColor[1], envXluColor[2], 255); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); // func_8002EBCC(&this->actor, play, 0); gDPSetPrimColor(POLY_OPA_DISP++, 0, 128, primOpaColor[0], primOpaColor[1], primOpaColor[2], 255); gDPSetEnvColor(POLY_OPA_DISP++, envOpaColor[0], envOpaColor[1], envOpaColor[2], 255); @@ -506,7 +506,7 @@ void GetItem_DrawMaskOrBombchu(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093BA8(play->state.gfxCtx); + Gfx_SetupDL_26Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); @@ -519,7 +519,7 @@ void GetItem_DrawSoldOut(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 5); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 5); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[0]); @@ -532,12 +532,12 @@ void GetItem_DrawBlueFire(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 0 * (play->state.frames * 0), 16, 32, 1, 1 * (play->state.frames * 1), @@ -558,12 +558,12 @@ void GetItem_DrawPoes(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[1]); @@ -587,12 +587,12 @@ void GetItem_DrawFairy(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[1]); @@ -615,7 +615,7 @@ void GetItem_DrawMirrorShield(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 0) % 256, 1 * (play->state.frames * 2) % 256, 64, 64, 1, @@ -625,7 +625,7 @@ void GetItem_DrawMirrorShield(PlayState* play, s16 drawId) { G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[1]); @@ -638,12 +638,12 @@ void GetItem_DrawSkullToken(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 1 * -(play->state.frames * 5), 32, 32, 1, 0 * (play->state.frames * 0), @@ -660,7 +660,7 @@ void GetItem_DrawEggOrMedallion(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093BA8(play->state.gfxCtx); + Gfx_SetupDL_26Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); @@ -674,12 +674,12 @@ void GetItem_DrawCompass(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 5); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 5); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[1]); @@ -692,7 +692,7 @@ void GetItem_DrawPotion(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, -1 * (play->state.frames * 1), 1 * (play->state.frames * 1), 32, 32, 1, -1 * (play->state.frames * 1), @@ -704,7 +704,7 @@ void GetItem_DrawPotion(PlayState* play, s16 drawId) { gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[2]); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[3]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[4]); @@ -718,7 +718,7 @@ void GetItem_DrawGoronSword(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 1), 0 * (play->state.frames * 1), 32, 32, 1, 0 * (play->state.frames * 1), @@ -735,7 +735,7 @@ void GetItem_DrawDekuNuts(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 6), 1 * (play->state.frames * 6), 32, 32, 1, 1 * (play->state.frames * 6), @@ -752,7 +752,7 @@ void GetItem_DrawRecoveryHeart(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 1), 1 * -(play->state.frames * 3), 32, 32, 1, 0 * (play->state.frames * 1), @@ -769,7 +769,7 @@ void GetItem_DrawFish(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 1 * (play->state.frames * 1), 32, 32, 1, 0 * (play->state.frames * 0), @@ -786,7 +786,7 @@ void GetItem_DrawOpa0(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); @@ -799,12 +799,12 @@ void GetItem_DrawOpa0Xlu1(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[1]); @@ -830,7 +830,7 @@ void GetItem_DrawGenericMusicNote(PlayState* play, s16 drawId) { gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(play->state.gfxCtx, __FILE__, __LINE__), G_MTX_MODELVIEW | G_MTX_LOAD); gDPSetGrayscaleColor(POLY_XLU_DISP++, colors[color_slot][0], colors[color_slot][1], colors[color_slot][2], 255); gSPGrayscale(POLY_XLU_DISP++, true); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[0]); gSPGrayscale(POLY_XLU_DISP++, false); @@ -842,7 +842,7 @@ void GetItem_DrawXlu01(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[0]); @@ -856,13 +856,13 @@ void GetItem_DrawOpa10Xlu2(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[1]); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[2]); @@ -875,12 +875,12 @@ void GetItem_DrawMagicArrow(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[1]); @@ -894,7 +894,7 @@ void GetItem_DrawMagicSpell(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 2), 1 * -(play->state.frames * 6), 32, 32, 1, 1 * (play->state.frames * 1), @@ -913,7 +913,7 @@ void GetItem_DrawOpa1023(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[1]); @@ -929,13 +929,13 @@ void GetItem_DrawOpa10Xlu32(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[1]); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[3]); @@ -951,13 +951,13 @@ void GetItem_DrawSmallRupee(PlayState* play, s16 drawId) { Matrix_Scale(0.7f, 0.7f, 0.7f, MTXMODE_APPLY); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[1]); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[3]); @@ -971,7 +971,7 @@ void GetItem_DrawScale(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 2), -1 * (play->state.frames * 2), 64, 64, 1, 1 * (play->state.frames * 4), @@ -991,13 +991,13 @@ void GetItem_DrawBulletBag(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[1]); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[2]); @@ -1012,7 +1012,7 @@ void GetItem_DrawWallet(PlayState* play, s16 drawId) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[1]); diff --git a/soh/src/code/z_eff_blure.c b/soh/src/code/z_eff_blure.c index 440b0bbd0..8bccb04c9 100644 --- a/soh/src/code/z_eff_blure.c +++ b/soh/src/code/z_eff_blure.c @@ -589,7 +589,7 @@ void EffectBlure_GetComputedValues(EffectBlure* this, s32 index, f32 ratio, Vec3 void EffectBlure_SetupSmooth(EffectBlure* this, GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x26); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x26); CLOSE_DISPS(gfxCtx); } @@ -923,7 +923,7 @@ void EffectBlure_DrawSmooth(EffectBlure* this2, GraphicsContext* gfxCtx) { void EffectBlure_SetupSimple(GraphicsContext* gfxCtx, EffectBlure* this, Vtx* vtx) { OPEN_DISPS(gfxCtx); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x26); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x26); CLOSE_DISPS(gfxCtx); } @@ -932,7 +932,7 @@ void EffectBlure_SetupSimpleAlt(GraphicsContext* gfxCtx, EffectBlure* this, Vtx* OPEN_DISPS(gfxCtx); gDPPipeSync(POLY_XLU_DISP++); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x26); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x26); gDPSetCycleType(POLY_XLU_DISP++, G_CYC_2CYCLE); gDPSetTextureLUT(POLY_XLU_DISP++, G_TT_NONE); @@ -1162,7 +1162,7 @@ void EffectBlure_Draw(void* thisx, GraphicsContext* gfxCtx) { if (this->numElements != 0) { if (this->flags == 0) { - func_800942F0(gfxCtx); + Gfx_SetupDL_38Xlu(gfxCtx); gDPPipeSync(POLY_XLU_DISP++); vtx = Graph_Alloc(gfxCtx, sizeof(Vtx[32])); diff --git a/soh/src/code/z_eff_shield_particle.c b/soh/src/code/z_eff_shield_particle.c index 43934f4e0..ecc3099f5 100644 --- a/soh/src/code/z_eff_shield_particle.c +++ b/soh/src/code/z_eff_shield_particle.c @@ -160,7 +160,7 @@ void EffectShieldParticle_Draw(void* thisx, GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); if (this != NULL) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x26); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x26); gDPSetCycleType(POLY_XLU_DISP++, G_CYC_2CYCLE); gDPPipeSync(POLY_XLU_DISP++); diff --git a/soh/src/code/z_eff_spark.c b/soh/src/code/z_eff_spark.c index c96bffa55..67c9575c9 100644 --- a/soh/src/code/z_eff_spark.c +++ b/soh/src/code/z_eff_spark.c @@ -161,7 +161,7 @@ void EffectSpark_Draw(void* thisx, GraphicsContext* gfxCtx) { if (this != NULL) { gSPMatrix(POLY_XLU_DISP++, &gMtxClear, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x26); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x26); gDPSetCycleType(POLY_XLU_DISP++, G_CYC_2CYCLE); gDPPipeSync(POLY_XLU_DISP++); diff --git a/soh/src/code/z_effect_soft_sprite_old_init.c b/soh/src/code/z_effect_soft_sprite_old_init.c index 965e3a1f9..7b740bbcd 100644 --- a/soh/src/code/z_effect_soft_sprite_old_init.c +++ b/soh/src/code/z_effect_soft_sprite_old_init.c @@ -66,7 +66,7 @@ void EffectSs_DrawGEffect(PlayState* play, EffectSs* this, void* texture) { if (mtx != NULL) { gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(texture)); - func_80094C50(gfxCtx); + Gfx_SetupDL_61Xlu(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rgPrimColorR, this->rgPrimColorG, this->rgPrimColorB, this->rgPrimColorA); gDPSetEnvColor(POLY_XLU_DISP++, this->rgEnvColorR, this->rgEnvColorG, this->rgEnvColorB, this->rgEnvColorA); diff --git a/soh/src/code/z_en_a_keep.c b/soh/src/code/z_en_a_keep.c index d340422ca..abdc07ecc 100644 --- a/soh/src/code/z_en_a_keep.c +++ b/soh/src/code/z_en_a_keep.c @@ -349,7 +349,7 @@ void EnAObj_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (type >= A_OBJ_MAX) { type = A_OBJ_BOULDER_FRAGMENT; diff --git a/soh/src/code/z_en_item00.c b/soh/src/code/z_en_item00.c index 8bdf4e3a6..cbc8f7607 100644 --- a/soh/src/code/z_en_item00.c +++ b/soh/src/code/z_en_item00.c @@ -1363,7 +1363,7 @@ void EnItem00_DrawRupee(EnItem00* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_8002EBCC(&this->actor, play, 0); if (this->actor.params <= ITEM00_RUPEE_RED) { @@ -1407,7 +1407,7 @@ void EnItem00_DrawCollectible(EnItem00* this, PlayState* play) { texIndex -= 3; } - POLY_OPA_DISP = func_800946E4(POLY_OPA_DISP); + POLY_OPA_DISP = Gfx_SetupDL_66(POLY_OPA_DISP); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sItemDropTex[texIndex])); @@ -1427,13 +1427,13 @@ void EnItem00_DrawHeartContainer(EnItem00* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_8002EBCC(&this->actor, play, 0); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, gHeartPieceExteriorDL); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); func_8002ED80(&this->actor, play, 0); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); @@ -1456,7 +1456,7 @@ void EnItem00_DrawHeartPiece(EnItem00* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); func_8002ED80(&this->actor, play, 0); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD); diff --git a/soh/src/code/z_kankyo.c b/soh/src/code/z_kankyo.c index 37e7e2c67..48bc922e3 100644 --- a/soh/src/code/z_kankyo.c +++ b/soh/src/code/z_kankyo.c @@ -1350,7 +1350,7 @@ void Environment_DrawSunAndMoon(PlayState* play) { scale = (color * 2.0f) + 10.0f; Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_LOAD); - func_80093AD0(play->state.gfxCtx); + Gfx_SetupDL_54Opa(play->state.gfxCtx); static Vtx vertices[] = { VTX(-31, -31, 0, 0, 0, 255, 255, 255, 255), @@ -1388,7 +1388,7 @@ void Environment_DrawSunAndMoon(PlayState* play) { if (alpha > 0.0f) { gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_LOAD); - func_8009398C(play->state.gfxCtx); + Gfx_SetupDL_51Opa(play->state.gfxCtx); gDPPipeSync(POLY_OPA_DISP++); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 240, 255, 180, alpha); gDPSetEnvColor(POLY_OPA_DISP++, 80, 70, 20, alpha); @@ -1581,7 +1581,7 @@ void Environment_DrawLensFlare(PlayState* play, EnvironmentContext* envCtx, View if (screenFillAlpha != 0) { if (alphaScale > 0.0f) { - POLY_XLU_DISP = func_800937C0(POLY_XLU_DISP); + POLY_XLU_DISP = Gfx_SetupDL_57(POLY_XLU_DISP); alpha = colorIntensity / 10.0f; alpha = CLAMP_MAX(alpha, 1.0f); @@ -1664,7 +1664,7 @@ void Environment_DrawRain(PlayState* play, View* view, GraphicsContext* gfxCtx) if (play->envCtx.unk_EE[1]) { gDPPipeSync(POLY_XLU_DISP++); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 150, 255, 255, 30); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 20); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 20); } // draw rain drops @@ -1708,7 +1708,7 @@ void Environment_DrawRain(PlayState* play, View* view, GraphicsContext* gfxCtx) FrameInterpolation_RecordOpenChild("Droplet Ring", i); if (!firstDone) { - func_80093D84(gfxCtx); + Gfx_SetupDL_25Xlu(gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 155, 155, 155, 0); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, 120); firstDone++; @@ -1768,7 +1768,7 @@ void Environment_DrawSkyboxFilters(PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_800938B4(play->state.gfxCtx); + Gfx_SetupDL_57Opa(play->state.gfxCtx); alpha = (1000 - play->lightCtx.fogNear) * 0.02f; @@ -1790,7 +1790,7 @@ void Environment_DrawSkyboxFilters(PlayState* play) { if (play->envCtx.customSkyboxFilter) { OPEN_DISPS(play->state.gfxCtx); - func_800938B4(play->state.gfxCtx); + Gfx_SetupDL_57Opa(play->state.gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, play->envCtx.skyboxFilterColor[0], play->envCtx.skyboxFilterColor[1], play->envCtx.skyboxFilterColor[2], play->envCtx.skyboxFilterColor[3]); @@ -1803,7 +1803,7 @@ void Environment_DrawSkyboxFilters(PlayState* play) { void Environment_DrawLightningFlash(PlayState* play, u8 red, u8 green, u8 blue, u8 alpha) { OPEN_DISPS(play->state.gfxCtx); - func_800938B4(play->state.gfxCtx); + Gfx_SetupDL_57Opa(play->state.gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, red, green, blue, alpha); gDPFillRectangle(POLY_OPA_DISP++, 0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1); @@ -1977,7 +1977,7 @@ void Environment_DrawLightning(PlayState* play, s32 unused) { gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(lightningTextures[sLightningBolts[i].textureIndex])); - func_80094C50(play->state.gfxCtx); + Gfx_SetupDL_61Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, SEG_ADDR(1, 0), G_MTX_NOPUSH | G_MTX_MUL | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, gEffLightningDL); } @@ -2252,7 +2252,7 @@ void Environment_FillScreen(GraphicsContext* gfxCtx, u8 red, u8 green, u8 blue, OPEN_DISPS(gfxCtx); if (drawFlags & FILL_SCREEN_OPA) { - POLY_OPA_DISP = func_800937C0(POLY_OPA_DISP); + POLY_OPA_DISP = Gfx_SetupDL_57(POLY_OPA_DISP); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, red, green, blue, alpha); gDPSetAlphaDither(POLY_OPA_DISP++, G_AD_DISABLE); gDPSetColorDither(POLY_OPA_DISP++, G_CD_DISABLE); @@ -2260,7 +2260,7 @@ void Environment_FillScreen(GraphicsContext* gfxCtx, u8 red, u8 green, u8 blue, } if (drawFlags & FILL_SCREEN_XLU) { - POLY_XLU_DISP = func_800937C0(POLY_XLU_DISP); + POLY_XLU_DISP = Gfx_SetupDL_57(POLY_XLU_DISP); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, red, green, blue, alpha); if ((u32)alpha == 255) { @@ -2420,7 +2420,7 @@ void Environment_DrawSandstorm(PlayState* play, u8 sandstormState) { OPEN_DISPS(play->state.gfxCtx); - POLY_XLU_DISP = func_80093F34(POLY_XLU_DISP); + POLY_XLU_DISP = Gfx_SetupDL_64(POLY_XLU_DISP); gDPSetAlphaDither(POLY_XLU_DISP++, G_AD_NOISE); gDPSetColorDither(POLY_XLU_DISP++, G_CD_NOISE); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, primColor.r, primColor.g, primColor.b, play->envCtx.sandstormPrimA); diff --git a/soh/src/code/z_lifemeter.c b/soh/src/code/z_lifemeter.c index be093af73..26bb03d52 100644 --- a/soh/src/code/z_lifemeter.c +++ b/soh/src/code/z_lifemeter.c @@ -594,14 +594,14 @@ void HealthMeter_Draw(PlayState* play) { if ((ddHeartCountMinusOne < 0) || (i > ddHeartCountMinusOne)) { if (curCombineModeSet != 1) { curCombineModeSet = 1; - func_80094520(gfxCtx); + Gfx_SetupDL_39Overlay(gfxCtx); gDPSetCombineLERP(OVERLAY_DISP++, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0); } } else { if (curCombineModeSet != 3) { curCombineModeSet = 3; - func_80094520(gfxCtx); + Gfx_SetupDL_39Overlay(gfxCtx); gDPSetCombineLERP(OVERLAY_DISP++, ENVIRONMENT, PRIMITIVE, TEXEL0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0, ENVIRONMENT, PRIMITIVE, TEXEL0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0); } @@ -632,14 +632,14 @@ void HealthMeter_Draw(PlayState* play) { if ((ddHeartCountMinusOne < 0) || (i > ddHeartCountMinusOne)) { if (curCombineModeSet != 2) { curCombineModeSet = 2; - func_80094A14(gfxCtx); + Gfx_SetupDL_42Overlay(gfxCtx); gDPSetCombineLERP(OVERLAY_DISP++, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0); } } else { if (curCombineModeSet != 4) { curCombineModeSet = 4; - func_80094A14(gfxCtx); + Gfx_SetupDL_42Overlay(gfxCtx); gDPSetCombineLERP(OVERLAY_DISP++, ENVIRONMENT, PRIMITIVE, TEXEL0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0, ENVIRONMENT, PRIMITIVE, TEXEL0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0); } diff --git a/soh/src/code/z_map_exp.c b/soh/src/code/z_map_exp.c index 33075e3fd..a2d7b8e2a 100644 --- a/soh/src/code/z_map_exp.c +++ b/soh/src/code/z_map_exp.c @@ -616,7 +616,7 @@ void Minimap_DrawCompassIcons(PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (play->interfaceCtx.minimapAlpha >= 0xAA) { - func_80094A14(play->state.gfxCtx); + Gfx_SetupDL_42Overlay(play->state.gfxCtx); //Player current position (yellow arrow) gSPMatrix(OVERLAY_DISP++, &gMtxClear, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -749,7 +749,7 @@ void Minimap_Draw(PlayState* play) { case SCENE_HAKADANCH: case SCENE_ICE_DOUKUTO: if (!R_MINIMAP_DISABLED) { - func_80094520(play->state.gfxCtx); + Gfx_SetupDL_39Overlay(play->state.gfxCtx); gDPSetCombineLERP(OVERLAY_DISP++, 1, 0, PRIMITIVE, 0, TEXEL0, 0, PRIMITIVE, 0, 1, 0, PRIMITIVE, 0, TEXEL0, 0, PRIMITIVE, 0); @@ -788,7 +788,7 @@ void Minimap_Draw(PlayState* play) { if (CHECK_DUNGEON_ITEM(DUNGEON_COMPASS, mapIndex)) { Minimap_DrawCompassIcons(play); // Draw icons for the player spawn and current position - func_80094520(play->state.gfxCtx); + Gfx_SetupDL_39Overlay(play->state.gfxCtx); MapMark_Draw(play); } } @@ -826,7 +826,7 @@ void Minimap_Draw(PlayState* play) { case SCENE_SPOT20: case SCENE_GANON_TOU: if (!R_MINIMAP_DISABLED) { - func_80094520(play->state.gfxCtx); + Gfx_SetupDL_39Overlay(play->state.gfxCtx); gDPSetCombineMode(OVERLAY_DISP++, G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM); if (CVar_GetS32("gHudColors", 1) == 2) {//Overworld minimap diff --git a/soh/src/code/z_message_PAL.c b/soh/src/code/z_message_PAL.c index 14acf64a1..1495a9102 100644 --- a/soh/src/code/z_message_PAL.c +++ b/soh/src/code/z_message_PAL.c @@ -2210,11 +2210,11 @@ void Message_DrawMain(PlayState* play, Gfx** p) { msgCtx->msgMode >= MSGMODE_TEXT_BOX_GROWING && msgCtx->msgMode < MSGMODE_TEXT_CLOSING && msgCtx->textBoxType < TEXTBOX_TYPE_NONE_BOTTOM) { Message_SetView(&msgCtx->view); - func_8009457C(&gfx); + Gfx_SetupDL_39Ptr(&gfx); Message_DrawTextBox(play, &gfx); } - func_8009457C(&gfx); + Gfx_SetupDL_39Ptr(&gfx); gDPSetAlphaCompare(gfx++, G_AC_NONE); gDPSetCombineLERP(gfx++, 0, 0, 0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0, 0, 0, 0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, @@ -3176,7 +3176,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) { if (msgCtx->msgMode >= MSGMODE_OCARINA_PLAYING && msgCtx->msgMode < MSGMODE_TEXT_AWAIT_NEXT && msgCtx->ocarinaAction != OCARINA_ACTION_FREE_PLAY && msgCtx->ocarinaAction != OCARINA_ACTION_CHECK_NOWARP) { - func_8009457C(&gfx); + Gfx_SetupDL_39Ptr(&gfx); gDPSetCombineLERP(gfx++, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0); diff --git a/soh/src/code/z_parameter.c b/soh/src/code/z_parameter.c index c23e2565f..1bd7c239c 100644 --- a/soh/src/code/z_parameter.c +++ b/soh/src/code/z_parameter.c @@ -3557,7 +3557,7 @@ void Interface_DrawLineupTick(PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80094520(play->state.gfxCtx); + Gfx_SetupDL_39Overlay(play->state.gfxCtx); gDPSetEnvColor(OVERLAY_DISP++, 255, 255, 255, 255); gDPSetPrimColor(OVERLAY_DISP++, 0, 0, 255, 255, 255, 255); @@ -3652,7 +3652,7 @@ void Interface_DrawMagicBar(PlayState* play) { rMagicFillX = rMagicFillX_original; } - func_80094520(play->state.gfxCtx); + Gfx_SetupDL_39Overlay(play->state.gfxCtx); if (CVar_GetS32("gHudColors", 1) == 2) {//Original game add color there so to prevent miss match we make it all white :) gDPSetEnvColor(OVERLAY_DISP++, 255, 255, 255, 255); @@ -4995,7 +4995,7 @@ void Interface_Draw(PlayState* play) { HealthMeter_Draw(play); } - func_80094520(play->state.gfxCtx); + Gfx_SetupDL_39Overlay(play->state.gfxCtx); if (fullUi) { // Rupee Icon @@ -5204,7 +5204,7 @@ void Interface_Draw(PlayState* play) { func_8002C124(&play->actorCtx.targetCtx, play); // Draw Z-Target } - func_80094520(play->state.gfxCtx); + Gfx_SetupDL_39Overlay(play->state.gfxCtx); if (fullUi) { Interface_DrawItemButtons(play); @@ -5431,7 +5431,7 @@ void Interface_Draw(PlayState* play) { } // A Button - func_80094A14(play->state.gfxCtx); + Gfx_SetupDL_42Overlay(play->state.gfxCtx); const Color_RGB8 A_Button_Colors = {R_A_BTN_COLOR(0), R_A_BTN_COLOR(1), R_A_BTN_COLOR(2)}; s16 X_Margins_BtnA; s16 Y_Margins_BtnA; @@ -5513,7 +5513,7 @@ void Interface_Draw(PlayState* play) { if ((pauseCtx->state == 6) && (pauseCtx->unk_1E4 == 3)) { // Inventory Equip Effects gSPSegment(OVERLAY_DISP++, 0x08, pauseCtx->iconItemSegment); - func_80094A14(play->state.gfxCtx); + Gfx_SetupDL_42Overlay(play->state.gfxCtx); gDPSetCombineMode(OVERLAY_DISP++, G_CC_MODULATERGBA_PRIM, G_CC_MODULATERGBA_PRIM); gSPMatrix(OVERLAY_DISP++, &gMtxClear, G_MTX_MODELVIEW | G_MTX_LOAD); @@ -5559,7 +5559,7 @@ void Interface_Draw(PlayState* play) { gSP1Quadrangle(OVERLAY_DISP++, 0, 2, 3, 1, 0); } - func_80094520(play->state.gfxCtx); + Gfx_SetupDL_39Overlay(play->state.gfxCtx); if ((play->pauseCtx.state == 0) && (play->pauseCtx.debugState == 0)) { if (gSaveContext.minigameState != 1) { diff --git a/soh/src/code/z_play.c b/soh/src/code/z_play.c index 9d35a528c..8282fef01 100644 --- a/soh/src/code/z_play.c +++ b/soh/src/code/z_play.c @@ -1369,7 +1369,7 @@ void Play_Draw(PlayState* play) { gSPSegment(POLY_XLU_DISP++, 0x02, play->sceneSegment); gSPSegment(OVERLAY_DISP++, 0x02, play->sceneSegment); - func_80095248(gfxCtx, 0, 0, 0); + Gfx_SetupFrame(gfxCtx, 0, 0, 0); if ((HREG(80) != 10) || (HREG(82) != 0)) { POLY_OPA_DISP = Play_SetFog(play, POLY_OPA_DISP); diff --git a/soh/src/code/z_player_lib.c b/soh/src/code/z_player_lib.c index 6e9e9df80..181bdd676 100644 --- a/soh/src/code/z_player_lib.c +++ b/soh/src/code/z_player_lib.c @@ -1240,7 +1240,7 @@ void Player_DrawHookshotReticle(PlayState* play, Player* this, f32 arg2) { if (BgCheck_AnyLineTest3(&play->colCtx, &sp8C, &sp80, &sp74, &sp9C, 1, 1, 1, 1, &bgId)) { OPEN_DISPS(play->state.gfxCtx); - WORLD_OVERLAY_DISP = Gfx_CallSetupDL(WORLD_OVERLAY_DISP, 0x07); + WORLD_OVERLAY_DISP = Gfx_SetupDL(WORLD_OVERLAY_DISP, 0x07); SkinMatrix_Vec3fMtxFMultXYZW(&play->viewProjectionMtxF, &sp74, &sp68, &sp64); diff --git a/soh/src/code/z_prenmi.c b/soh/src/code/z_prenmi.c index f76255b23..4a6f777ae 100644 --- a/soh/src/code/z_prenmi.c +++ b/soh/src/code/z_prenmi.c @@ -33,8 +33,8 @@ void PreNMI_Draw(PreNMIContext* this) { OPEN_DISPS(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x00, NULL); - func_80095248(gfxCtx, 0, 0, 0); - func_800940B0(gfxCtx); + Gfx_SetupFrame(gfxCtx, 0, 0, 0); + Gfx_SetupDL_36Opa(gfxCtx); gDPSetFillColor(POLY_OPA_DISP++, (GPACK_RGBA5551(255, 255, 255, 1) << 16) | GPACK_RGBA5551(255, 255, 255, 1)); gDPFillRectangle(POLY_OPA_DISP++, 0, this->timer + 100, SCREEN_WIDTH - 1, this->timer + 100); diff --git a/soh/src/code/z_rcp.c b/soh/src/code/z_rcp.c index fa7fd71ad..d74bd8975 100644 --- a/soh/src/code/z_rcp.c +++ b/soh/src/code/z_rcp.c @@ -1,8 +1,8 @@ #include "global.h" -Gfx sSetupDL[][6] = { +Gfx sSetupDL[SETUPDL_MAX][6] = { { - /* 0x00 */ + /* SETUPDL_0 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, PRIMITIVE, 0, TEXEL0, 0, 0, 0, 0, COMBINED, 0, @@ -14,7 +14,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x01 */ + /* SETUPDL_1 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineMode(G_CC_SHADE, G_CC_PASS2), @@ -25,7 +25,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x02 */ + /* SETUPDL_2 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineMode(G_CC_SHADE, G_CC_SHADE), @@ -36,7 +36,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x03 */ + /* SETUPDL_3 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineMode(G_CC_SHADE, G_CC_PASS2), @@ -47,7 +47,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x04 */ + /* SETUPDL_4 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineLERP(PRIMITIVE, 0, SHADE, 0, 0, 0, 0, PRIMITIVE, PRIMITIVE, 0, SHADE, 0, 0, 0, 0, PRIMITIVE), @@ -58,7 +58,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x05 */ + /* SETUPDL_5 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEI_PRIM, G_CC_MODULATEI_PRIM), @@ -69,7 +69,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x06 */ + /* SETUPDL_6 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_DECALRGBA, G_CC_PASS2), @@ -80,7 +80,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x07 */ + /* SETUPDL_7 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -91,7 +91,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x08 */ + /* SETUPDL_8 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineMode(G_CC_SHADE, G_CC_SHADE), @@ -102,7 +102,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x09 */ + /* SETUPDL_9 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA, G_CC_MODULATEIA2), @@ -113,7 +113,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x0A */ + /* SETUPDL_10 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIDECALA, G_CC_MODULATEIDECALA), @@ -124,7 +124,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x0B */ + /* SETUPDL_11 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIDECALA, G_CC_MODULATEIA_PRIM2), @@ -135,7 +135,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x0C */ + /* SETUPDL_12 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEI_PRIM, G_CC_MODULATEI_PRIM), @@ -146,7 +146,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x0D */ + /* SETUPDL_13 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -157,7 +157,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x0E */ + /* SETUPDL_14 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_DECALRGBA, G_CC_DECALRGBA), @@ -168,7 +168,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x0F */ + /* SETUPDL_15 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_DECALRGBA, G_CC_PASS2), @@ -179,7 +179,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x10 */ + /* SETUPDL_16 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM2), @@ -190,7 +190,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x11 */ + /* SETUPDL_17 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIDECALA, G_CC_MODULATEIDECALA), @@ -201,7 +201,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x12 */ + /* SETUPDL_18 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIDECALA, G_CC_PASS2), @@ -212,7 +212,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x13 */ + /* SETUPDL_19 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -225,7 +225,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x14 */ + /* SETUPDL_20 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -236,7 +236,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x15 */ + /* SETUPDL_21 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA, G_CC_MODULATEIA), @@ -247,7 +247,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x16 */ + /* SETUPDL_22 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA, G_CC_MODULATEIA2), @@ -258,7 +258,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x17 */ + /* SETUPDL_23 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIDECALA, G_CC_MODULATEIDECALA), @@ -269,7 +269,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x18 */ + /* SETUPDL_24 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIDECALA, G_CC_MODULATEIA2), @@ -280,7 +280,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x19 */ + /* SETUPDL_25 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIDECALA, G_CC_MODULATEIA_PRIM2), @@ -291,7 +291,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x1A */ + /* SETUPDL_26 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEI_PRIM, G_CC_MODULATEI_PRIM), @@ -302,7 +302,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x1B */ + /* SETUPDL_27 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEI_PRIM, G_CC_MODULATEI_PRIM), @@ -313,7 +313,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x1C */ + /* SETUPDL_28 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIDECALA_PRIM, G_CC_MODULATEIDECALA_PRIM), @@ -324,7 +324,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x1D */ + /* SETUPDL_29 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(TEXEL0, 0, SHADE, 0, TEXEL0, 0, SHADE, 0, NOISE, 0, COMBINED, 0, 0, 0, 0, COMBINED), @@ -335,7 +335,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x1E */ + /* SETUPDL_30 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineMode(G_CC_PRIMITIVE, G_CC_PRIMITIVE), @@ -346,7 +346,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x1F */ + /* SETUPDL_31 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_HILITERGBA, G_CC_HILITERGBA), @@ -357,7 +357,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x20 */ + /* SETUPDL_32 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_HILITERGBA, G_CC_HILITERGBA), @@ -369,7 +369,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x21 */ + /* SETUPDL_33 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(TEXEL0, 0, PRIMITIVE, SHADE, 1, 0, TEXEL0, SHADE, ENVIRONMENT, COMBINED, TEXEL0, COMBINED, @@ -382,7 +382,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x22 */ + /* SETUPDL_34 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_DECALRGB, G_CC_DECALRGB), @@ -393,7 +393,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x23 */ + /* SETUPDL_35 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_DECALRGBA, G_CC_DECALRGBA), @@ -404,7 +404,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x24 */ + /* SETUPDL_36 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineMode(G_CC_SHADE, G_CC_SHADE), @@ -415,7 +415,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x25 */ + /* SETUPDL_37 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineLERP(PRIMITIVE, 0, SHADE, 0, 0, 0, 0, PRIMITIVE, 0, 0, 0, COMBINED, 0, 0, 0, COMBINED), @@ -426,7 +426,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x26 */ + /* SETUPDL_38 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineMode(G_CC_SHADE, G_CC_SHADE), @@ -437,7 +437,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x27 */ + /* SETUPDL_39 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -448,7 +448,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x28 */ + /* SETUPDL_40 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(TEXEL1, TEXEL0, PRIMITIVE_ALPHA, TEXEL0, TEXEL1, TEXEL0, PRIMITIVE, TEXEL0, 0, 0, 0, @@ -460,7 +460,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x29 */ + /* SETUPDL_41 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA, G_CC_MODULATEIA), @@ -471,7 +471,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x2A */ + /* SETUPDL_42 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIDECALA, G_CC_MODULATEIDECALA), @@ -482,7 +482,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x2B */ + /* SETUPDL_43 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIDECALA_PRIM, G_CC_MODULATEIDECALA_PRIM), @@ -493,7 +493,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x2C */ + /* SETUPDL_44 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_PASS2), @@ -504,7 +504,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x2D */ + /* SETUPDL_45 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(0, 0, 0, PRIMITIVE, 0, 0, 0, TEXEL0, 0, 0, 0, PRIMITIVE, 0, 0, 0, TEXEL0), @@ -515,7 +515,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x2E */ + /* SETUPDL_46 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(0, 0, 0, PRIMITIVE, 0, 0, 0, TEXEL0, 0, 0, 0, PRIMITIVE, 0, 0, 0, TEXEL0), @@ -526,7 +526,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x2F */ + /* SETUPDL_47 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEI_PRIM, G_CC_MODULATEI_PRIM), @@ -537,7 +537,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x30 */ + /* SETUPDL_48 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineMode(G_CC_PRIMITIVE, G_CC_PRIMITIVE), @@ -548,7 +548,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x31 */ + /* SETUPDL_49 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineLERP(PRIMITIVE, 0, SHADE, 0, 0, 0, 0, PRIMITIVE, PRIMITIVE, 0, SHADE, 0, 0, 0, 0, PRIMITIVE), @@ -559,7 +559,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x32 */ + /* SETUPDL_50 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -570,7 +570,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x33 */ + /* SETUPDL_51 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -581,7 +581,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x34 */ + /* SETUPDL_52 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -592,7 +592,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x35 */ + /* SETUPDL_53 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(TEXEL1, TEXEL0, ENV_ALPHA, TEXEL0, TEXEL1, TEXEL0, ENVIRONMENT, TEXEL0, PRIMITIVE, @@ -604,7 +604,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x36 */ + /* SETUPDL_54 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(TEXEL1, TEXEL0, ENV_ALPHA, TEXEL0, TEXEL1, TEXEL0, ENVIRONMENT, TEXEL0, PRIMITIVE, @@ -616,7 +616,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x37 */ + /* SETUPDL_55 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(TEXEL1, TEXEL0, ENV_ALPHA, TEXEL0, TEXEL1, TEXEL0, ENVIRONMENT, TEXEL0, PRIMITIVE, @@ -628,7 +628,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x38 */ + /* SETUPDL_56 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -639,7 +639,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x39 */ + /* SETUPDL_57 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineMode(G_CC_PRIMITIVE, G_CC_PRIMITIVE), @@ -650,7 +650,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x3A */ + /* SETUPDL_58 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineLERP(PRIMITIVE, 0, SHADE, 0, PRIMITIVE, 0, SHADE, 0, PRIMITIVE, 0, SHADE, 0, PRIMITIVE, 0, SHADE, @@ -662,7 +662,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x3B */ + /* SETUPDL_59 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(TEXEL0, 0, PRIMITIVE, SHADE, 1, 0, TEXEL0, SHADE, ENVIRONMENT, COMBINED, TEXEL0, COMBINED, @@ -675,7 +675,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x3C */ + /* SETUPDL_60 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, PRIMITIVE, 0, TEXEL0, 0, PRIMITIVE, ENVIRONMENT, @@ -687,7 +687,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x3D */ + /* SETUPDL_61 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineLERP(PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, PRIMITIVE, 0, TEXEL0, 0, PRIMITIVE, ENVIRONMENT, @@ -699,7 +699,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x3E */ + /* SETUPDL_62 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIDECALA, G_CC_MODULATEIA_PRIM2), @@ -710,7 +710,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x3F */ + /* SETUPDL_63 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -723,7 +723,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x40 */ + /* SETUPDL_64 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), gsDPSetCombineMode(G_CC_DECALRGBA, G_CC_PASS2), @@ -734,7 +734,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x41 */ + /* SETUPDL_65 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -745,7 +745,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x42 */ + /* SETUPDL_66 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_DECALRGBA, G_CC_DECALRGBA), @@ -757,7 +757,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x43 */ + /* SETUPDL_67 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -769,7 +769,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x44 */ + /* SETUPDL_68 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_DECALRGBA, G_CC_DECALRGBA), @@ -782,7 +782,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x45 */ + /* SETUPDL_69 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM), @@ -795,7 +795,7 @@ Gfx sSetupDL[][6] = { gsSPEndDisplayList(), }, { - /* 0x46 */ + /* SETUPDL_70 */ gsDPPipeSync(), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), gsDPSetCombineMode(G_CC_DECALRGBA, G_CC_DECALRGBA), @@ -895,7 +895,7 @@ Gfx* Gfx_SetFog2(Gfx* gfx, s32 r, s32 g, s32 b, s32 a, s32 near, s32 far) { return Gfx_SetFog(gfx, r, g, b, a, near, far); } -Gfx* Gfx_CallSetupDLImpl(Gfx* gfx, u32 i) { +Gfx* Gfx_SetupDLImpl(Gfx* gfx, u32 i) { s32 dListIndex = 6 * i; gSPDisplayList(gfx++, &((Gfx*)sSetupDL)[dListIndex]); @@ -903,106 +903,106 @@ Gfx* Gfx_CallSetupDLImpl(Gfx* gfx, u32 i) { return gfx; } -Gfx* Gfx_CallSetupDL(Gfx* gfx, u32 i) { - return Gfx_CallSetupDLImpl(gfx, i); +Gfx* Gfx_SetupDL(Gfx* gfx, u32 i) { + return Gfx_SetupDLImpl(gfx, i); } -void Gfx_CallSetupDLAtPtr(Gfx** gfxp, u32 i) { - *gfxp = Gfx_CallSetupDL(*gfxp, i); +void Gfx_SetupDLAtPtr(Gfx** gfxp, u32 i) { + *gfxp = Gfx_SetupDL(*gfxp, i); } -Gfx* func_800937C0(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x39]); +Gfx* Gfx_SetupDL_57(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_57]); return gfx; } -Gfx* func_800937E4(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x39]); +Gfx* Gfx_SetupDL_57b(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_57]); return gfx; } -Gfx* func_80093808(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x34]); +Gfx* Gfx_SetupDL_52NoCD(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_52]); gDPSetColorDither(gfx++, G_CD_DISABLE); return gfx; } -void func_80093848(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_58Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x3A]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_58]); CLOSE_DISPS(gfxCtx); } -void func_800938B4(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_57Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x39]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_57]); CLOSE_DISPS(gfxCtx); } -void func_80093920(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_50Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x32]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_50]); CLOSE_DISPS(gfxCtx); } -void func_8009398C(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_51Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x33]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_51]); CLOSE_DISPS(gfxCtx); } -void func_800939F8(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_52Xlu(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x34]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_52]); CLOSE_DISPS(gfxCtx); } -void func_80093A64(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_53Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x35]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_53]); CLOSE_DISPS(gfxCtx); } -void func_80093AD0(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_54Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x36]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_54]); CLOSE_DISPS(gfxCtx); } -void func_80093B3C(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_55Xlu(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x37]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_55]); CLOSE_DISPS(gfxCtx); } -void func_80093BA8(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_26Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x1A]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_26]); CLOSE_DISPS(gfxCtx); } -void func_80093C14(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_25Xlu2(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x19]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_25]); CLOSE_DISPS(gfxCtx); } @@ -1010,7 +1010,7 @@ void func_80093C14(GraphicsContext* gfxCtx) { void func_80093C80(PlayState* play) { GraphicsContext* gfxCtx = play->state.gfxCtx; - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); if (play->roomCtx.curRoom.behaviorType1 == ROOM_BEHAVIOR_TYPE1_3) { OPEN_DISPS(gfxCtx); @@ -1021,240 +1021,241 @@ void func_80093C80(PlayState* play) { } } -void func_80093D18(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_25Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x19]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_25]); CLOSE_DISPS(gfxCtx); } -void func_80093D84(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_25Xlu(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x19]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_25]); CLOSE_DISPS(gfxCtx); } -void func_80093DF0(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_31Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x1F]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_31]); CLOSE_DISPS(gfxCtx); } -void func_80093E5C(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_32Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x20]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_32]); CLOSE_DISPS(gfxCtx); } -void func_80093EC8(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_33Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x21]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_33]); CLOSE_DISPS(gfxCtx); } -Gfx* func_80093F34(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x40]); +Gfx* Gfx_SetupDL_64(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_64]); return gfx; } -Gfx* func_80093F58(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x22]); +Gfx* Gfx_SetupDL_34(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_34]); return gfx; } -void func_80093F7C(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_34Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - POLY_OPA_DISP = func_80093F58(POLY_OPA_DISP); + POLY_OPA_DISP = Gfx_SetupDL_34(POLY_OPA_DISP); CLOSE_DISPS(gfxCtx); } -void func_80093FD8(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_35Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x23]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_35]); CLOSE_DISPS(gfxCtx); } -void func_80094044(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_44Xlu(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x2C]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_44]); CLOSE_DISPS(gfxCtx); } -void func_800940B0(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_36Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x24]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_36]); CLOSE_DISPS(gfxCtx); } -Gfx* func_8009411C(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x1C]); +Gfx* Gfx_SetupDL_28(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_28]); return gfx; } -void func_80094140(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_28Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x1C]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_28]); CLOSE_DISPS(gfxCtx); } -void func_800941AC(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_43Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x2B]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_43]); CLOSE_DISPS(gfxCtx); } -void func_80094218(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_45Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x2D]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_45]); CLOSE_DISPS(gfxCtx); } -void func_80094284(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_46Overlay(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(OVERLAY_DISP++, sSetupDL[0x2E]); + gSPDisplayList(OVERLAY_DISP++, sSetupDL[SETUPDL_46]); CLOSE_DISPS(gfxCtx); } -void func_800942F0(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_38Xlu(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x26]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_38]); CLOSE_DISPS(gfxCtx); } -void func_8009435C(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_4Xlu(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x04]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_4]); CLOSE_DISPS(gfxCtx); } -void func_800943C8(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_37Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x25]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_37]); CLOSE_DISPS(gfxCtx); } -void func_80094434(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_2Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x02]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_2]); CLOSE_DISPS(gfxCtx); } -Gfx* func_800944A0(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x27]); +Gfx* Gfx_SetupDL_39(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_39]); return gfx; } -void func_800944C4(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_39Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - POLY_OPA_DISP = func_800944A0(POLY_OPA_DISP); + POLY_OPA_DISP = Gfx_SetupDL_39(POLY_OPA_DISP); CLOSE_DISPS(gfxCtx); } -void func_800944C4_KAL(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_39Kal(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - POLY_KAL_DISP = func_800944A0(POLY_KAL_DISP); + POLY_KAL_DISP = Gfx_SetupDL_39(POLY_KAL_DISP); CLOSE_DISPS(gfxCtx); } -void func_80094520(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_39Overlay(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - OVERLAY_DISP = func_800944A0(OVERLAY_DISP); + OVERLAY_DISP = Gfx_SetupDL_39(OVERLAY_DISP); CLOSE_DISPS(gfxCtx); } -void func_8009457C(Gfx** gfxp) { +void Gfx_SetupDL_39Ptr(Gfx** gfxp) { Gfx* gfx = *gfxp; - gSPDisplayList(gfx++, sSetupDL[0x27]); + + gSPDisplayList(gfx++, sSetupDL[SETUPDL_39]); *gfxp = gfx; } -void func_800945A0(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_40Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x28]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_40]); CLOSE_DISPS(gfxCtx); } -void func_8009460C(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_41Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x29]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_41]); CLOSE_DISPS(gfxCtx); } -void func_80094678(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_47Xlu(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x2F]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_47]); CLOSE_DISPS(gfxCtx); } -Gfx* func_800946E4(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x42]); +Gfx* Gfx_SetupDL_66(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_66]); return gfx; } -Gfx* func_80094708(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x43]); +Gfx* Gfx_SetupDL_67(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_67]); return gfx; } -Gfx* func_8009472C(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x44]); +Gfx* Gfx_SetupDL_68NoCD(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_68]); gDPSetColorDither(gfx++, G_CD_DISABLE); return gfx; } -Gfx* func_8009476C(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x45]); +Gfx* Gfx_SetupDL_69NoCD(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_69]); gDPSetColorDither(gfx++, G_CD_DISABLE); return gfx; } Gfx* func_800947AC(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x41]); + gSPDisplayList(gfx++, sSetupDL[SETUPDL_65]); gDPSetColorDither(gfx++, G_CD_DISABLE); // clang-format off @@ -1276,102 +1277,102 @@ Gfx* func_800947AC(Gfx* gfx) { return gfx; } -Gfx* func_80094944(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x46]); +Gfx* Gfx_SetupDL_70(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_70]); return gfx; } -Gfx* func_80094968(Gfx* gfx) { - gSPDisplayList(gfx++, sSetupDL[0x14]); +Gfx* Gfx_SetupDL_20NoCD(Gfx* gfx) { + gSPDisplayList(gfx++, sSetupDL[SETUPDL_20]); gDPSetColorDither(gfx++, G_CD_DISABLE); return gfx; } -void func_800949A8(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_42Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x2A]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_42]); CLOSE_DISPS(gfxCtx); } -void func_800949A8_KAL(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_42Kal(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_KAL_DISP++, sSetupDL[0x2A]); + gSPDisplayList(POLY_KAL_DISP++, sSetupDL[SETUPDL_42]); CLOSE_DISPS(gfxCtx); } -void func_80094A14(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_42Overlay(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(OVERLAY_DISP++, sSetupDL[0x2A]); + gSPDisplayList(OVERLAY_DISP++, sSetupDL[SETUPDL_42]); CLOSE_DISPS(gfxCtx); } -void func_80094A80(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_48Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x30]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_48]); CLOSE_DISPS(gfxCtx); } -void func_80094AEC(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_49Xlu(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x31]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_49]); CLOSE_DISPS(gfxCtx); } -void func_80094B58(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_27Xlu(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x1B]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_27]); CLOSE_DISPS(gfxCtx); } -void func_80094BC4(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_60NoCDXlu(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x3C]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_60]); gDPSetColorDither(POLY_XLU_DISP++, G_CD_DISABLE); CLOSE_DISPS(gfxCtx); } -void func_80094C50(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_61Xlu(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_XLU_DISP++, sSetupDL[0x3D]); + gSPDisplayList(POLY_XLU_DISP++, sSetupDL[SETUPDL_61]); CLOSE_DISPS(gfxCtx); } -void func_80094CBC(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_56Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x38]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_56]); CLOSE_DISPS(gfxCtx); } -void func_80094D28(Gfx** gfxp) { +void Gfx_SetupDL_56Ptr(Gfx** gfxp) { Gfx* gfx = *gfxp; - gSPDisplayList(gfx++, sSetupDL[0x38]); + gSPDisplayList(gfx++, sSetupDL[SETUPDL_56]); *gfxp = gfx; } -void func_80094D4C(GraphicsContext* gfxCtx) { +void Gfx_SetupDL_59Opa(GraphicsContext* gfxCtx) { OPEN_DISPS(gfxCtx); - gSPDisplayList(POLY_OPA_DISP++, sSetupDL[0x3B]); + gSPDisplayList(POLY_OPA_DISP++, sSetupDL[SETUPDL_59]); CLOSE_DISPS(gfxCtx); } @@ -1380,7 +1381,7 @@ Gfx* Gfx_BranchTexScroll(Gfx** gfxp, u32 x, u32 y, s32 width, s32 height) { Gfx* displayList = Graph_DlistAlloc(gfxp, 3 * sizeof(Gfx)); gDPTileSync(displayList); - gDPSetTileSize(displayList + 1, 0, x, y, (x + ((width - 1) << 2)), (y + ((height - 1) << 2))); + gDPSetTileSize(displayList + 1, G_TX_RENDERTILE, x, y, x + ((width - 1) << 2), y + ((height - 1) << 2)); gSPEndDisplayList(displayList + 2); return displayList; @@ -1397,11 +1398,11 @@ Gfx* func_80094E78(GraphicsContext* gfxCtx, u32 x, u32 y) { Gfx* Gfx_TexScroll(GraphicsContext* gfxCtx, u32 x, u32 y, s32 width, s32 height) { Gfx* displayList = Graph_Alloc(gfxCtx, 3 * sizeof(Gfx)); - x %= 2048; - y %= 2048; + x %= 512 << 2; + y %= 512 << 2; gDPTileSync(displayList); - gDPSetTileSize(displayList + 1, 0, x, y, (x + ((width - 1) << 2)), (y + ((height - 1) << 2))); + gDPSetTileSize(displayList + 1, G_TX_RENDERTILE, x, y, x + ((width - 1) << 2), y + ((height - 1) << 2)); gSPEndDisplayList(displayList + 2); return displayList; @@ -1411,15 +1412,15 @@ Gfx* Gfx_TwoTexScroll(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 wi u32 y2, s32 width2, s32 height2) { Gfx* displayList = Graph_Alloc(gfxCtx, 5 * sizeof(Gfx)); - x1 %= 2048; - y1 %= 2048; - x2 %= 2048; - y2 %= 2048; + x1 %= 512 << 2; + y1 %= 512 << 2; + x2 %= 512 << 2; + y2 %= 512 << 2; gDPTileSync(displayList); - gDPSetTileSize(displayList + 1, tile1, x1, y1, (x1 + ((width1 - 1) << 2)), (y1 + ((height1 - 1) << 2))); + gDPSetTileSize(displayList + 1, tile1, x1, y1, x1 + ((width1 - 1) << 2), y1 + ((height1 - 1) << 2)); gDPTileSync(displayList + 2); - gDPSetTileSize(displayList + 3, tile2, x2, y2, (x2 + ((width2 - 1) << 2)), (y2 + ((height2 - 1) << 2))); + gDPSetTileSize(displayList + 3, tile2, x2, y2, x2 + ((width2 - 1) << 2), y2 + ((height2 - 1) << 2)); gSPEndDisplayList(displayList + 4); return displayList; @@ -1429,15 +1430,15 @@ Gfx* Gfx_TwoTexScrollEnvColor(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1 u32 x2, u32 y2, s32 width2, s32 height2, s32 r, s32 g, s32 b, s32 a) { Gfx* displayList = Graph_Alloc(gfxCtx, 6 * sizeof(Gfx)); - x1 %= 2048; - y1 %= 2048; - x2 %= 2048; - y2 %= 2048; + x1 %= 512 << 2; + y1 %= 512 << 2; + x2 %= 512 << 2; + y2 %= 512 << 2; gDPTileSync(displayList); - gDPSetTileSize(displayList + 1, tile1, x1, y1, (x1 + ((width1 - 1) << 2)), (y1 + ((height1 - 1) << 2))); + gDPSetTileSize(displayList + 1, tile1, x1, y1, x1 + ((width1 - 1) << 2), y1 + ((height1 - 1) << 2)); gDPTileSync(displayList + 2); - gDPSetTileSize(displayList + 3, tile2, x2, y2, (x2 + ((width2 - 1) << 2)), (y2 + ((height2 - 1) << 2))); + gDPSetTileSize(displayList + 3, tile2, x2, y2, x2 + ((width2 - 1) << 2), y2 + ((height2 - 1) << 2)); gDPSetEnvColor(displayList + 4, r, g, b, a); gSPEndDisplayList(displayList + 5); @@ -1453,32 +1454,43 @@ Gfx* Gfx_EnvColor(GraphicsContext* gfxCtx, s32 r, s32 g, s32 b, s32 a) { return displayList; } -void func_80095248(GraphicsContext* gfxCtx, u8 r, u8 g, u8 b) { +/** + * Sets up the frame for drawing. + * Initializes the scissor region to full screen. + * Set up the framebuffer and z-buffer. + * The whole screen is filled with the color supplied as arguments. + * Letterbox is also applied here, and will share the color of the screen base. + */ +void Gfx_SetupFrame(GraphicsContext* gfxCtx, u8 r, u8 g, u8 b) { OPEN_DISPS(gfxCtx); + // Set up the RDP render state for rectangles in FILL mode gSPDisplayList(POLY_OPA_DISP++, sFillSetupDL); gSPDisplayList(POLY_XLU_DISP++, sFillSetupDL); gSPDisplayList(POLY_KAL_DISP++, sFillSetupDL); gSPDisplayList(OVERLAY_DISP++, sFillSetupDL); + // Set the scissor region to the full screen gDPSetScissor(POLY_OPA_DISP++, G_SC_NON_INTERLACE, 0, 0, gScreenWidth, gScreenHeight); gDPSetScissor(POLY_XLU_DISP++, G_SC_NON_INTERLACE, 0, 0, gScreenWidth, gScreenHeight); gDPSetScissor(POLY_KAL_DISP++, G_SC_NON_INTERLACE, 0, 0, gScreenWidth, gScreenHeight); gDPSetScissor(OVERLAY_DISP++, G_SC_NON_INTERLACE, 0, 0, gScreenWidth, gScreenHeight); + // Set up the framebuffer, primitives will be drawn here gDPSetColorImage(POLY_OPA_DISP++, G_IM_FMT_RGBA, G_IM_SIZ_16b, gScreenWidth, gfxCtx->curFrameBuffer); gDPSetColorImage(POLY_OPA_DISP++, G_IM_FMT_RGBA, G_IM_SIZ_16b, gScreenWidth, gfxCtx->curFrameBuffer); gDPSetColorImage(POLY_XLU_DISP++, G_IM_FMT_RGBA, G_IM_SIZ_16b, gScreenWidth, gfxCtx->curFrameBuffer); gDPSetColorImage(POLY_KAL_DISP++, G_IM_FMT_RGBA, G_IM_SIZ_16b, gScreenWidth, gfxCtx->curFrameBuffer); gDPSetColorImage(OVERLAY_DISP++, G_IM_FMT_RGBA, G_IM_SIZ_16b, gScreenWidth, gfxCtx->curFrameBuffer); + // Set up the z-buffer gDPSetDepthImage(POLY_OPA_DISP++, gZBuffer); gDPSetDepthImage(POLY_XLU_DISP++, gZBuffer); gDPSetDepthImage(POLY_KAL_DISP++, gZBuffer); gDPSetDepthImage(OVERLAY_DISP++, gZBuffer); if ((R_PAUSE_MENU_MODE < 2) && (gTrnsnUnkState < 2)) { - s32 ret = ShrinkWindow_GetCurrentVal(); + s32 letterboxSize = ShrinkWindow_GetCurrentVal(); // Upstream TODO: Letterbox if (HREG(80) == 16) { if (HREG(95) != 16) { @@ -1500,7 +1512,7 @@ void func_80095248(GraphicsContext* gfxCtx, u8 r, u8 g, u8 b) { } if (HREG(81) & 1) { - HREG(83) = ret; + HREG(83) = letterboxSize; } if (HREG(81) & 2) { @@ -1510,7 +1522,7 @@ void func_80095248(GraphicsContext* gfxCtx, u8 r, u8 g, u8 b) { } if (HREG(82) & 1) { - ret = HREG(83); + letterboxSize = HREG(83); } if (HREG(82) & 2) { @@ -1520,27 +1532,32 @@ void func_80095248(GraphicsContext* gfxCtx, u8 r, u8 g, u8 b) { } } + // Set the whole z buffer to maximum depth + // Don't bother with pixels that are being covered by the letterbox gDPSetColorImage(POLY_OPA_DISP++, G_IM_FMT_RGBA, G_IM_SIZ_16b, gScreenWidth, gZBuffer); gDPSetCycleType(POLY_OPA_DISP++, G_CYC_FILL); gDPSetRenderMode(POLY_OPA_DISP++, G_RM_NOOP, G_RM_NOOP2); - gDPSetFillColor(POLY_OPA_DISP++, (GPACK_RGBA5551(255, 255, 240, 0) << 16) | GPACK_RGBA5551(255, 255, 240, 0)); - gDPFillRectangle(POLY_OPA_DISP++, 0, ret, gScreenWidth - 1, gScreenHeight - ret - 1); + gDPSetFillColor(POLY_OPA_DISP++, (GPACK_ZDZ(G_MAXFBZ, 0) << 16) | GPACK_ZDZ(G_MAXFBZ, 0)); + gDPFillRectangle(POLY_OPA_DISP++, 0, letterboxSize, gScreenWidth - 1, gScreenHeight - letterboxSize - 1); gDPPipeSync(POLY_OPA_DISP++); + // Fill the whole screen with the base color + // Don't bother with pixels that are being covered by the letterbox gDPSetColorImage(POLY_OPA_DISP++, G_IM_FMT_RGBA, G_IM_SIZ_16b, gScreenWidth, gfxCtx->curFrameBuffer); gDPSetCycleType(POLY_OPA_DISP++, G_CYC_FILL); gDPSetRenderMode(POLY_OPA_DISP++, G_RM_NOOP, G_RM_NOOP2); gDPSetFillColor(POLY_OPA_DISP++, (GPACK_RGBA5551(r, g, b, 1) << 16) | GPACK_RGBA5551(r, g, b, 1)); - gDPFillRectangle(POLY_OPA_DISP++, 0, ret, gScreenWidth - 1, gScreenHeight - ret - 1); + gDPFillRectangle(POLY_OPA_DISP++, 0, letterboxSize, gScreenWidth - 1, gScreenHeight - letterboxSize - 1); gDPPipeSync(POLY_OPA_DISP++); - if (ret > 0) { + // Draw the letterbox if applicable (uses the same color as the screen base) + if (letterboxSize > 0) { gDPPipeSync(OVERLAY_DISP++); gDPSetCycleType(OVERLAY_DISP++, G_CYC_FILL); gDPSetRenderMode(OVERLAY_DISP++, G_RM_NOOP, G_RM_NOOP2); gDPSetFillColor(OVERLAY_DISP++, (GPACK_RGBA5551(r, g, b, 1) << 16) | GPACK_RGBA5551(r, g, b, 1)); - gDPFillRectangle(OVERLAY_DISP++, 0, 0, gScreenWidth - 1, ret - 1); - gDPFillRectangle(OVERLAY_DISP++, 0, gScreenHeight - ret, gScreenWidth - 1, gScreenHeight - 1); + gDPFillRectangle(OVERLAY_DISP++, 0, 0, gScreenWidth - 1, letterboxSize - 1); + gDPFillRectangle(OVERLAY_DISP++, 0, gScreenHeight - letterboxSize, gScreenWidth - 1, gScreenHeight - 1); gDPPipeSync(OVERLAY_DISP++); } } diff --git a/soh/src/code/z_room.c b/soh/src/code/z_room.c index e1a3ca1aa..17f810c55 100644 --- a/soh/src/code/z_room.c +++ b/soh/src/code/z_room.c @@ -49,7 +49,7 @@ void func_80095AB4(PlayState* play, Room* room, u32 flags) { if (flags & 2) { func_8003435C(&D_801270A0, play); gSPSegment(POLY_XLU_DISP++, 0x03, room->segment); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, &gMtxClear, G_MTX_MODELVIEW | G_MTX_LOAD); } @@ -109,7 +109,7 @@ void func_80095D04(PlayState* play, Room* room, u32 flags) { if (flags & 2) { func_8003435C(&D_801270A0, play); //gSPSegment(POLY_XLU_DISP++, 0x03, room->segment); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, &gMtxClear, G_MTX_MODELVIEW | G_MTX_LOAD); } @@ -356,7 +356,7 @@ void func_80096680(PlayState* play, Room* room, u32 flags) { gSPSegment(POLY_OPA_DISP++, 0x03, room->segment); if (sp94) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, &gMtxClear, G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, polygonDlist->opa); } @@ -383,7 +383,7 @@ void func_80096680(PlayState* play, Room* room, u32 flags) { if (sp90) { gSPSegment(POLY_XLU_DISP++, 0x03, room->segment); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, &gMtxClear, G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, polygonDlist->xlu); } @@ -458,7 +458,7 @@ void func_80096B6C(PlayState* play, Room* room, u32 flags) { gSPSegment(POLY_OPA_DISP++, 0x03, room->segment); if (sp90) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, &gMtxClear, G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, polygonDlist->opa); } @@ -484,7 +484,7 @@ void func_80096B6C(PlayState* play, Room* room, u32 flags) { if (sp8C) { gSPSegment(POLY_XLU_DISP++, 0x03, room->segment); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, &gMtxClear, G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_XLU_DISP++, polygonDlist->xlu); } diff --git a/soh/src/code/z_sample.c b/soh/src/code/z_sample.c index 0387d986b..ecd379443 100644 --- a/soh/src/code/z_sample.c +++ b/soh/src/code/z_sample.c @@ -16,7 +16,7 @@ void Sample_Draw(SampleContext* this) { gSPSegment(POLY_OPA_DISP++, 0x00, NULL); gSPSegment(POLY_OPA_DISP++, 0x01, this->staticSegment); - func_80095248(gfxCtx, 0, 0, 0); + Gfx_SetupFrame(gfxCtx, 0, 0, 0); view->flags = 1 | 2 | 4; func_800AAA50(view, 15); @@ -29,7 +29,7 @@ void Sample_Draw(SampleContext* this) { } POLY_OPA_DISP = Gfx_SetFog2(POLY_OPA_DISP, 255, 255, 255, 0, 0, 0); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gDPSetCycleType(POLY_OPA_DISP++, G_CYC_1CYCLE); gDPSetRenderMode(POLY_OPA_DISP++, G_RM_AA_ZB_OPA_SURF, G_RM_AA_ZB_OPA_SURF2); diff --git a/soh/src/code/z_vr_box_draw.c b/soh/src/code/z_vr_box_draw.c index 6e66df903..8eb97573e 100644 --- a/soh/src/code/z_vr_box_draw.c +++ b/soh/src/code/z_vr_box_draw.c @@ -17,7 +17,7 @@ void SkyboxDraw_Draw(SkyboxContext* skyboxCtx, GraphicsContext* gfxCtx, s16 skyb OPEN_DISPS(gfxCtx); FrameInterpolation_RecordOpenChild(NULL, FrameInterpolation_GetCameraEpoch()); - func_800945A0(gfxCtx); + Gfx_SetupDL_40Opa(gfxCtx); //gsSPShaderTest(POLY_OPA_DISP++); diff --git a/soh/src/overlays/actors/ovl_Arms_Hook/z_arms_hook.c b/soh/src/overlays/actors/ovl_Arms_Hook/z_arms_hook.c index 9e913a846..0bbbe58c5 100644 --- a/soh/src/overlays/actors/ovl_Arms_Hook/z_arms_hook.c +++ b/soh/src/overlays/actors/ovl_Arms_Hook/z_arms_hook.c @@ -320,7 +320,7 @@ void ArmsHook_Draw(Actor* thisx, PlayState* play) { } func_80090480(play, &this->collider, &this->hookInfo, &sp6C, &sp60); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gLinkAdultHookshotTipDL); diff --git a/soh/src/overlays/actors/ovl_Arrow_Fire/z_arrow_fire.c b/soh/src/overlays/actors/ovl_Arrow_Fire/z_arrow_fire.c index 972a2ffad..729faa547 100644 --- a/soh/src/overlays/actors/ovl_Arrow_Fire/z_arrow_fire.c +++ b/soh/src/overlays/actors/ovl_Arrow_Fire/z_arrow_fire.c @@ -215,7 +215,7 @@ void ArrowFire_Draw(Actor* thisx, PlayState* play2) { // Draw red effect over the screen when arrow hits if (this->unk_15C > 0) { - POLY_XLU_DISP = func_800937C0(POLY_XLU_DISP); + POLY_XLU_DISP = Gfx_SetupDL_57(POLY_XLU_DISP); if (CVar_GetS32("gUseArrowsCol", 0)) { gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, (s32)(Arrow_env.r * this->unk_15C) & 0xFF, @@ -232,7 +232,7 @@ void ArrowFire_Draw(Actor* thisx, PlayState* play2) { } // Draw fire on the arrow - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (CVar_GetS32("gUseArrowsCol", 0)) { gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, Arrow_col.r, Arrow_col.g, Arrow_col.b, this->alpha); gDPSetEnvColor(POLY_XLU_DISP++, Arrow_env.r, Arrow_env.g, Arrow_env.b, 128); diff --git a/soh/src/overlays/actors/ovl_Arrow_Ice/z_arrow_ice.c b/soh/src/overlays/actors/ovl_Arrow_Ice/z_arrow_ice.c index cd298abaa..5097d1a9a 100644 --- a/soh/src/overlays/actors/ovl_Arrow_Ice/z_arrow_ice.c +++ b/soh/src/overlays/actors/ovl_Arrow_Ice/z_arrow_ice.c @@ -213,7 +213,7 @@ void ArrowIce_Draw(Actor* thisx, PlayState* play) { // Draw blue effect over the screen when arrow hits if (this->unk_164 > 0) { - POLY_XLU_DISP = func_800937C0(POLY_XLU_DISP); + POLY_XLU_DISP = Gfx_SetupDL_57(POLY_XLU_DISP); if (CVar_GetS32("gUseArrowsCol", 0)) { gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, (s32)(Arrow_env.r * this->unk_164) & 0xFF, @@ -230,7 +230,7 @@ void ArrowIce_Draw(Actor* thisx, PlayState* play) { } // Draw ice on the arrow - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (CVar_GetS32("gUseArrowsCol", 0)) { gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, Arrow_col.r, Arrow_col.g, Arrow_col.b, this->alpha); gDPSetEnvColor(POLY_XLU_DISP++, Arrow_env.r, Arrow_env.g, Arrow_env.b, 128); diff --git a/soh/src/overlays/actors/ovl_Arrow_Light/z_arrow_light.c b/soh/src/overlays/actors/ovl_Arrow_Light/z_arrow_light.c index 1edcd018e..429c19a49 100644 --- a/soh/src/overlays/actors/ovl_Arrow_Light/z_arrow_light.c +++ b/soh/src/overlays/actors/ovl_Arrow_Light/z_arrow_light.c @@ -211,7 +211,7 @@ void ArrowLight_Draw(Actor* thisx, PlayState* play) { // Draw yellow effect over the screen when arrow hits if (this->unk_164 > 0) { - POLY_XLU_DISP = func_800937C0(POLY_XLU_DISP); + POLY_XLU_DISP = Gfx_SetupDL_57(POLY_XLU_DISP); if (CVar_GetS32("gUseArrowsCol", 0)) { gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, (s32)(Arrow_env.r * this->unk_164) & 0xFF, @@ -228,7 +228,7 @@ void ArrowLight_Draw(Actor* thisx, PlayState* play) { } // Draw light on the arrow - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (CVar_GetS32("gUseArrowsCol", 0)) { gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, Arrow_col.r, Arrow_col.g, Arrow_col.b, this->alpha); gDPSetEnvColor(POLY_XLU_DISP++, Arrow_env.r, Arrow_env.g, Arrow_env.b, 128); diff --git a/soh/src/overlays/actors/ovl_Bg_Bowl_Wall/z_bg_bowl_wall.c b/soh/src/overlays/actors/ovl_Bg_Bowl_Wall/z_bg_bowl_wall.c index cc5ebd060..35475e525 100644 --- a/soh/src/overlays/actors/ovl_Bg_Bowl_Wall/z_bg_bowl_wall.c +++ b/soh/src/overlays/actors/ovl_Bg_Bowl_Wall/z_bg_bowl_wall.c @@ -203,7 +203,7 @@ void BgBowlWall_Draw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x8, Gfx_TexScroll(play->state.gfxCtx, 0, -2 * (frames = play->state.frames), 16, 16)); gDPPipeSync(POLY_OPA_DISP++); diff --git a/soh/src/overlays/actors/ovl_Bg_Breakwall/z_bg_breakwall.c b/soh/src/overlays/actors/ovl_Bg_Breakwall/z_bg_breakwall.c index 7f498e764..b3d197d50 100644 --- a/soh/src/overlays/actors/ovl_Bg_Breakwall/z_bg_breakwall.c +++ b/soh/src/overlays/actors/ovl_Bg_Breakwall/z_bg_breakwall.c @@ -343,7 +343,7 @@ void BgBreakwall_Draw(Actor* thisx, PlayState* play) { if (this->bombableWallDList != NULL) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, this->bombableWallDList); diff --git a/soh/src/overlays/actors/ovl_Bg_Dodoago/z_bg_dodoago.c b/soh/src/overlays/actors/ovl_Bg_Dodoago/z_bg_dodoago.c index 42375931b..3722a15de 100644 --- a/soh/src/overlays/actors/ovl_Bg_Dodoago/z_bg_dodoago.c +++ b/soh/src/overlays/actors/ovl_Bg_Dodoago/z_bg_dodoago.c @@ -312,7 +312,7 @@ void BgDodoago_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (Flags_GetEventChkInf(0xB0)) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gDodongoLowerJawDL); diff --git a/soh/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c b/soh/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c index 5a3d9a7d3..1623a888e 100644 --- a/soh/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c +++ b/soh/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c @@ -922,7 +922,7 @@ void BgDyYoseizo_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->actionFunc != BgDyYoseizo_Vanish) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeState])); @@ -1038,7 +1038,7 @@ void BgDyYoseizo_ParticleDraw(BgDyYoseizo* this, PlayState* play) { s16 i; OPEN_DISPS(gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < 200; i++, particle++) { FrameInterpolation_RecordOpenChild(particle, particle->epoch); diff --git a/soh/src/overlays/actors/ovl_Bg_Ganon_Otyuka/z_bg_ganon_otyuka.c b/soh/src/overlays/actors/ovl_Bg_Ganon_Otyuka/z_bg_ganon_otyuka.c index de4c51f6f..458725be1 100644 --- a/soh/src/overlays/actors/ovl_Bg_Ganon_Otyuka/z_bg_ganon_otyuka.c +++ b/soh/src/overlays/actors/ovl_Bg_Ganon_Otyuka/z_bg_ganon_otyuka.c @@ -276,7 +276,7 @@ void BgGanonOtyuka_Draw(Actor* thisx, PlayState* play) { actor = actor->next; } - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPDisplayList(POLY_OPA_DISP++, sPlatformMaterialDL); actor = play->actorCtx.actorLists[ACTORCAT_PROP].head; @@ -330,7 +330,7 @@ void BgGanonOtyuka_Draw(Actor* thisx, PlayState* play) { actor = actor->next; } - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); actor = play->actorCtx.actorLists[ACTORCAT_PROP].head; while (actor != NULL) { if (actor->id == ACTOR_BG_GANON_OTYUKA) { diff --git a/soh/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c b/soh/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c index 3dd44c1b9..ff5ea2472 100644 --- a/soh/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c +++ b/soh/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c @@ -128,7 +128,7 @@ void BgGateShutter_Update(Actor* thisx, PlayState* play) { void BgGateShutter_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Gjyo_Bridge/z_bg_gjyo_bridge.c b/soh/src/overlays/actors/ovl_Bg_Gjyo_Bridge/z_bg_gjyo_bridge.c index 68dd1ee45..70d97c4e3 100644 --- a/soh/src/overlays/actors/ovl_Bg_Gjyo_Bridge/z_bg_gjyo_bridge.c +++ b/soh/src/overlays/actors/ovl_Bg_Gjyo_Bridge/z_bg_gjyo_bridge.c @@ -159,7 +159,7 @@ void BgGjyoBridge_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 8, Gfx_TexScroll(play->state.gfxCtx, play->gameplayFrames & 127, diff --git a/soh/src/overlays/actors/ovl_Bg_Gnd_Firemeiro/z_bg_gnd_firemeiro.c b/soh/src/overlays/actors/ovl_Bg_Gnd_Firemeiro/z_bg_gnd_firemeiro.c index 199a83e7d..b89d945b4 100644 --- a/soh/src/overlays/actors/ovl_Bg_Gnd_Firemeiro/z_bg_gnd_firemeiro.c +++ b/soh/src/overlays/actors/ovl_Bg_Gnd_Firemeiro/z_bg_gnd_firemeiro.c @@ -140,7 +140,7 @@ void BgGndFiremeiro_Update(Actor* thisx, PlayState* play) { void BgGndFiremeiro_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Gnd_Soulmeiro/z_bg_gnd_soulmeiro.c b/soh/src/overlays/actors/ovl_Bg_Gnd_Soulmeiro/z_bg_gnd_soulmeiro.c index 6332843db..85b3ab263 100644 --- a/soh/src/overlays/actors/ovl_Bg_Gnd_Soulmeiro/z_bg_gnd_soulmeiro.c +++ b/soh/src/overlays/actors/ovl_Bg_Gnd_Soulmeiro/z_bg_gnd_soulmeiro.c @@ -200,7 +200,7 @@ void BgGndSoulmeiro_Draw(Actor* thisx, PlayState* play) { switch (params) { case 0: OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, dLists[params]); diff --git a/soh/src/overlays/actors/ovl_Bg_Haka/z_bg_haka.c b/soh/src/overlays/actors/ovl_Bg_Haka/z_bg_haka.c index 5e8729218..a58e2f3a6 100644 --- a/soh/src/overlays/actors/ovl_Bg_Haka/z_bg_haka.c +++ b/soh/src/overlays/actors/ovl_Bg_Haka/z_bg_haka.c @@ -150,8 +150,8 @@ void BgHaka_Update(Actor* thisx, PlayState* play) { void BgHaka_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Haka_Gate/z_bg_haka_gate.c b/soh/src/overlays/actors/ovl_Bg_Haka_Gate/z_bg_haka_gate.c index 2f09c0293..eb19096e8 100644 --- a/soh/src/overlays/actors/ovl_Bg_Haka_Gate/z_bg_haka_gate.c +++ b/soh/src/overlays/actors/ovl_Bg_Haka_Gate/z_bg_haka_gate.c @@ -317,7 +317,7 @@ void BgHakaGate_DrawFlame(BgHakaGate* this, PlayState* play) { if (this->vFlameScale > 0) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, (this->vScrollTimer * -20) & 0x1FF, 0x20, 0x80)); @@ -348,7 +348,7 @@ void BgHakaGate_Draw(Actor* thisx, PlayState* play) { if (CHECK_FLAG_ALL(thisx->flags, ACTOR_FLAG_7)) { Gfx_DrawDListXlu(play, object_haka_objects_DL_00F1B0); } else { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (thisx->params == BGHAKAGATE_FLOOR) { OPEN_DISPS(play->state.gfxCtx); Matrix_Get(¤tMtxF); diff --git a/soh/src/overlays/actors/ovl_Bg_Haka_Ship/z_bg_haka_ship.c b/soh/src/overlays/actors/ovl_Bg_Haka_Ship/z_bg_haka_ship.c index 21d28813a..e1f29276a 100644 --- a/soh/src/overlays/actors/ovl_Bg_Haka_Ship/z_bg_haka_ship.c +++ b/soh/src/overlays/actors/ovl_Bg_Haka_Ship/z_bg_haka_ship.c @@ -199,7 +199,7 @@ void BgHakaShip_Draw(Actor* thisx, PlayState* play) { f32 angleTemp; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->dyna.actor.params == 0) { gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Haka_Tubo/z_bg_haka_tubo.c b/soh/src/overlays/actors/ovl_Bg_Haka_Tubo/z_bg_haka_tubo.c index c1477b760..115cc3972 100644 --- a/soh/src/overlays/actors/ovl_Bg_Haka_Tubo/z_bg_haka_tubo.c +++ b/soh/src/overlays/actors/ovl_Bg_Haka_Tubo/z_bg_haka_tubo.c @@ -231,7 +231,7 @@ void BgHakaTubo_DrawFlameCircle(BgHakaTubo* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Translate(this->dyna.actor.world.pos.x, this->dyna.actor.world.pos.y + 235.0f, this->dyna.actor.world.pos.z, MTXMODE_NEW); Matrix_RotateY(this->dyna.actor.shape.rot.y * (M_PI / 0x8000), MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_Bg_Haka_Water/z_bg_haka_water.c b/soh/src/overlays/actors/ovl_Bg_Haka_Water/z_bg_haka_water.c index 3df08a383..102d2ecaf 100644 --- a/soh/src/overlays/actors/ovl_Bg_Haka_Water/z_bg_haka_water.c +++ b/soh/src/overlays/actors/ovl_Bg_Haka_Water/z_bg_haka_water.c @@ -113,7 +113,7 @@ void BgHakaWater_Draw(Actor* thisx, PlayState* play) { s32 pad2; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->isLowered) { temp = this->actor.world.pos.y - this->actor.home.pos.y; diff --git a/soh/src/overlays/actors/ovl_Bg_Heavy_Block/z_bg_heavy_block.c b/soh/src/overlays/actors/ovl_Bg_Heavy_Block/z_bg_heavy_block.c index 17ec02f45..52ed6a30d 100644 --- a/soh/src/overlays/actors/ovl_Bg_Heavy_Block/z_bg_heavy_block.c +++ b/soh/src/overlays/actors/ovl_Bg_Heavy_Block/z_bg_heavy_block.c @@ -509,7 +509,7 @@ void BgHeavyBlock_Draw(Actor* thisx, PlayState* play) { Matrix_MultVec3f(&D_80884EC8, &thisx->world.pos); Matrix_MultVec3f(&D_80884ED4, &thisx->home.pos); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c b/soh/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c index 445108c11..0108235fe 100644 --- a/soh/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c +++ b/soh/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c @@ -243,7 +243,7 @@ void BgHidanCurtain_Draw(Actor* thisx, PlayState* play) { BgHidanCurtain* this = (BgHidanCurtain*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 220, 0, this->alpha); diff --git a/soh/src/overlays/actors/ovl_Bg_Hidan_Firewall/z_bg_hidan_firewall.c b/soh/src/overlays/actors/ovl_Bg_Hidan_Firewall/z_bg_hidan_firewall.c index 6dcc36dc5..6c1ce1e8f 100644 --- a/soh/src/overlays/actors/ovl_Bg_Hidan_Firewall/z_bg_hidan_firewall.c +++ b/soh/src/overlays/actors/ovl_Bg_Hidan_Firewall/z_bg_hidan_firewall.c @@ -204,7 +204,7 @@ void BgHidanFirewall_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x14); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x14); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sFireballTexs[this->unk_150])); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x01, 255, 255, 0, 150); diff --git a/soh/src/overlays/actors/ovl_Bg_Hidan_Fwbig/z_bg_hidan_fwbig.c b/soh/src/overlays/actors/ovl_Bg_Hidan_Fwbig/z_bg_hidan_fwbig.c index 944ac957d..212ea7b5a 100644 --- a/soh/src/overlays/actors/ovl_Bg_Hidan_Fwbig/z_bg_hidan_fwbig.c +++ b/soh/src/overlays/actors/ovl_Bg_Hidan_Fwbig/z_bg_hidan_fwbig.c @@ -253,7 +253,7 @@ void BgHidanFwbig_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(gEffUnknown4Tex)); diff --git a/soh/src/overlays/actors/ovl_Bg_Hidan_Hamstep/z_bg_hidan_hamstep.c b/soh/src/overlays/actors/ovl_Bg_Hidan_Hamstep/z_bg_hidan_hamstep.c index 32c4bbf70..c0ffd1c8b 100644 --- a/soh/src/overlays/actors/ovl_Bg_Hidan_Hamstep/z_bg_hidan_hamstep.c +++ b/soh/src/overlays/actors/ovl_Bg_Hidan_Hamstep/z_bg_hidan_hamstep.c @@ -397,7 +397,7 @@ void BgHidanHamstep_Update(Actor* thisx, PlayState* play) { void BgHidanHamstep_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Hidan_Kousi/z_bg_hidan_kousi.c b/soh/src/overlays/actors/ovl_Bg_Hidan_Kousi/z_bg_hidan_kousi.c index 418079e1e..990b6949a 100644 --- a/soh/src/overlays/actors/ovl_Bg_Hidan_Kousi/z_bg_hidan_kousi.c +++ b/soh/src/overlays/actors/ovl_Bg_Hidan_Kousi/z_bg_hidan_kousi.c @@ -153,7 +153,7 @@ void BgHidanKousi_Update(Actor* thisx, PlayState* play) { void BgHidanKousi_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Hidan_Kowarerukabe/z_bg_hidan_kowarerukabe.c b/soh/src/overlays/actors/ovl_Bg_Hidan_Kowarerukabe/z_bg_hidan_kowarerukabe.c index 4491eba26..ee303a178 100644 --- a/soh/src/overlays/actors/ovl_Bg_Hidan_Kowarerukabe/z_bg_hidan_kowarerukabe.c +++ b/soh/src/overlays/actors/ovl_Bg_Hidan_Kowarerukabe/z_bg_hidan_kowarerukabe.c @@ -326,7 +326,7 @@ void BgHidanKowarerukabe_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Hidan_Rock/z_bg_hidan_rock.c b/soh/src/overlays/actors/ovl_Bg_Hidan_Rock/z_bg_hidan_rock.c index 9c77f916d..b452d9cfd 100644 --- a/soh/src/overlays/actors/ovl_Bg_Hidan_Rock/z_bg_hidan_rock.c +++ b/soh/src/overlays/actors/ovl_Bg_Hidan_Rock/z_bg_hidan_rock.c @@ -355,7 +355,7 @@ void func_8088BC40(PlayState* play, BgHidanRock* this) { OPEN_DISPS(play->state.gfxCtx); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x14); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x14); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x01, 255, 255, 0, 150); gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 255); diff --git a/soh/src/overlays/actors/ovl_Bg_Hidan_Rsekizou/z_bg_hidan_rsekizou.c b/soh/src/overlays/actors/ovl_Bg_Hidan_Rsekizou/z_bg_hidan_rsekizou.c index 4eecfde32..c70d250ad 100644 --- a/soh/src/overlays/actors/ovl_Bg_Hidan_Rsekizou/z_bg_hidan_rsekizou.c +++ b/soh/src/overlays/actors/ovl_Bg_Hidan_Rsekizou/z_bg_hidan_rsekizou.c @@ -231,14 +231,14 @@ void BgHidanRsekizou_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gFireTempleSpinningFlamethrowerDL); Matrix_MtxFCopy(&mf, &gMtxFClear); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x14); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x14); // Strange original code. Add || 1 for frame interpolation to get correct. if ((s16)((Camera_GetCamDirYaw(GET_ACTIVE_CAM(play)) - this->dyna.actor.shape.rot.y) - 0x2E6C) >= 0 || 1) { diff --git a/soh/src/overlays/actors/ovl_Bg_Hidan_Sekizou/z_bg_hidan_sekizou.c b/soh/src/overlays/actors/ovl_Bg_Hidan_Sekizou/z_bg_hidan_sekizou.c index 967396c34..fc2cfc6a4 100644 --- a/soh/src/overlays/actors/ovl_Bg_Hidan_Sekizou/z_bg_hidan_sekizou.c +++ b/soh/src/overlays/actors/ovl_Bg_Hidan_Sekizou/z_bg_hidan_sekizou.c @@ -396,7 +396,7 @@ void BgHidanSekizou_Draw(Actor* thisx, PlayState* play2) { s32 sp6C[4]; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); if (this->dyna.actor.params == 0) { @@ -404,7 +404,7 @@ void BgHidanSekizou_Draw(Actor* thisx, PlayState* play2) { } else { gSPDisplayList(POLY_OPA_DISP++, gFireTempleStationaryFlamethrowerTallDL); } - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x14); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x14); if (this->dyna.actor.params == 0) { if (this->unk_168[0] > 0) { if ((s16)(Camera_GetCamDirYaw(GET_ACTIVE_CAM(play)) - this->dyna.actor.shape.rot.y) >= 0) { diff --git a/soh/src/overlays/actors/ovl_Bg_Hidan_Sima/z_bg_hidan_sima.c b/soh/src/overlays/actors/ovl_Bg_Hidan_Sima/z_bg_hidan_sima.c index 86848297c..ce1732e07 100644 --- a/soh/src/overlays/actors/ovl_Bg_Hidan_Sima/z_bg_hidan_sima.c +++ b/soh/src/overlays/actors/ovl_Bg_Hidan_Sima/z_bg_hidan_sima.c @@ -280,7 +280,7 @@ void BgHidanSima_Draw(Actor* thisx, PlayState* play) { BgHidanSima* this = (BgHidanSima*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); if (this->dyna.actor.params == 0) { @@ -288,7 +288,7 @@ void BgHidanSima_Draw(Actor* thisx, PlayState* play) { } else { gSPDisplayList(POLY_OPA_DISP++, gFireTempleStonePlatform2DL); if (this->actionFunc == func_8088E7A8) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x14); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x14); gDPSetPrimColor(POLY_XLU_DISP++, 0, 1, 255, 255, 0, 150); gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 255); POLY_XLU_DISP = func_8088EB54(play, this, POLY_XLU_DISP); diff --git a/soh/src/overlays/actors/ovl_Bg_Ice_Shelter/z_bg_ice_shelter.c b/soh/src/overlays/actors/ovl_Bg_Ice_Shelter/z_bg_ice_shelter.c index 5c1e0c111..ba0a90254 100644 --- a/soh/src/overlays/actors/ovl_Bg_Ice_Shelter/z_bg_ice_shelter.c +++ b/soh/src/overlays/actors/ovl_Bg_Ice_Shelter/z_bg_ice_shelter.c @@ -447,7 +447,7 @@ void BgIceShelter_Draw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Ingate/z_bg_ingate.c b/soh/src/overlays/actors/ovl_Bg_Ingate/z_bg_ingate.c index abfcacfd2..7fcd3d7ac 100644 --- a/soh/src/overlays/actors/ovl_Bg_Ingate/z_bg_ingate.c +++ b/soh/src/overlays/actors/ovl_Bg_Ingate/z_bg_ingate.c @@ -106,7 +106,7 @@ void BgInGate_Update(Actor* thisx, PlayState* play) { void BgInGate_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Jya_Bigmirror/z_bg_jya_bigmirror.c b/soh/src/overlays/actors/ovl_Bg_Jya_Bigmirror/z_bg_jya_bigmirror.c index 5e91ef51b..edf3d41c5 100644 --- a/soh/src/overlays/actors/ovl_Bg_Jya_Bigmirror/z_bg_jya_bigmirror.c +++ b/soh/src/overlays/actors/ovl_Bg_Jya_Bigmirror/z_bg_jya_bigmirror.c @@ -213,7 +213,7 @@ void BgJyaBigmirror_DrawLightBeam(Actor* thisx, PlayState* play) { Actor* lift; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); lift = Actor_Find(&play->actorCtx, ACTOR_BG_JYA_LIFT, ACTORCAT_BG); if (lift != NULL) { this->liftHeight = lift->world.pos.y; diff --git a/soh/src/overlays/actors/ovl_Bg_Jya_Block/z_bg_jya_block.c b/soh/src/overlays/actors/ovl_Bg_Jya_Block/z_bg_jya_block.c index 2315c452d..ff695140d 100644 --- a/soh/src/overlays/actors/ovl_Bg_Jya_Block/z_bg_jya_block.c +++ b/soh/src/overlays/actors/ovl_Bg_Jya_Block/z_bg_jya_block.c @@ -66,7 +66,7 @@ void BgJyaBlock_Update(Actor* thisx, PlayState* play) { void BgJyaBlock_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(gPushBlockGrayTex)); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), diff --git a/soh/src/overlays/actors/ovl_Bg_Jya_Bombchuiwa/z_bg_jya_bombchuiwa.c b/soh/src/overlays/actors/ovl_Bg_Jya_Bombchuiwa/z_bg_jya_bombchuiwa.c index e1737a7ef..7d5484fc9 100644 --- a/soh/src/overlays/actors/ovl_Bg_Jya_Bombchuiwa/z_bg_jya_bombchuiwa.c +++ b/soh/src/overlays/actors/ovl_Bg_Jya_Bombchuiwa/z_bg_jya_bombchuiwa.c @@ -198,7 +198,7 @@ void BgJyaBombchuiwa_Update(Actor* thisx, PlayState* play) { void BgJyaBombchuiwa_DrawRock(PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, gBombchuiwa2DL); @@ -209,7 +209,7 @@ void BgJyaBombchuiwa_DrawLight(Actor* thisx, PlayState* play) { BgJyaBombchuiwa* this = (BgJyaBombchuiwa*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, CLAMP_MAX((u32)(this->lightRayIntensity * 153.0f), 153)); diff --git a/soh/src/overlays/actors/ovl_Bg_Jya_Cobra/z_bg_jya_cobra.c b/soh/src/overlays/actors/ovl_Bg_Jya_Cobra/z_bg_jya_cobra.c index 455cfcd05..414036a94 100644 --- a/soh/src/overlays/actors/ovl_Bg_Jya_Cobra/z_bg_jya_cobra.c +++ b/soh/src/overlays/actors/ovl_Bg_Jya_Cobra/z_bg_jya_cobra.c @@ -531,7 +531,7 @@ void BgJyaCobra_Update(Actor* thisx, PlayState* play2) { void func_80896CB4(PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, gCobra2DL); @@ -544,7 +544,7 @@ void func_80896D78(BgJyaCobra* this, PlayState* play) { Vec3s sp44; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); sp44.x = D_80897308[this->dyna.actor.params & 3] + this->dyna.actor.shape.rot.x; sp44.y = this->dyna.actor.shape.rot.y; @@ -568,7 +568,7 @@ void BgJyaCobra_DrawShadow(BgJyaCobra* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80094044(play->state.gfxCtx); + Gfx_SetupDL_44Xlu(play->state.gfxCtx); if (params == 0) { sp64.x = this->dyna.actor.world.pos.x - 50.0f; diff --git a/soh/src/overlays/actors/ovl_Bg_Jya_Megami/z_bg_jya_megami.c b/soh/src/overlays/actors/ovl_Bg_Jya_Megami/z_bg_jya_megami.c index 0aa7c61e7..12eb0a34a 100644 --- a/soh/src/overlays/actors/ovl_Bg_Jya_Megami/z_bg_jya_megami.c +++ b/soh/src/overlays/actors/ovl_Bg_Jya_Megami/z_bg_jya_megami.c @@ -301,7 +301,7 @@ static void* sLeftSideCrumbles[] = { void BgJyaMegami_DrawFace(BgJyaMegami* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sRightSideCrumbles[this->crumbleIndex])); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(sLeftSideCrumbles[this->crumbleIndex])); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), @@ -324,7 +324,7 @@ void BgJyaMegami_DrawExplode(BgJyaMegami* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->pieces); i++) { piece = &this->pieces[i]; diff --git a/soh/src/overlays/actors/ovl_Bg_Menkuri_Eye/z_bg_menkuri_eye.c b/soh/src/overlays/actors/ovl_Bg_Menkuri_Eye/z_bg_menkuri_eye.c index 0187a8104..28825f509 100644 --- a/soh/src/overlays/actors/ovl_Bg_Menkuri_Eye/z_bg_menkuri_eye.c +++ b/soh/src/overlays/actors/ovl_Bg_Menkuri_Eye/z_bg_menkuri_eye.c @@ -124,7 +124,7 @@ void BgMenkuriEye_Draw(Actor* thisx, PlayState* play) { s32 pad; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (Flags_GetSwitch(play, this->actor.params)) { gDPSetEnvColor(POLY_XLU_DISP++, 200, 0, 0, 255); } else if (this->framesUntilDisable == -1) { diff --git a/soh/src/overlays/actors/ovl_Bg_Mizu_Bwall/z_bg_mizu_bwall.c b/soh/src/overlays/actors/ovl_Bg_Mizu_Bwall/z_bg_mizu_bwall.c index 3cce58ebf..909b685cc 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mizu_Bwall/z_bg_mizu_bwall.c +++ b/soh/src/overlays/actors/ovl_Bg_Mizu_Bwall/z_bg_mizu_bwall.c @@ -508,7 +508,7 @@ void BgMizuBwall_Draw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); frames = play->gameplayFrames; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, 1 * frames, 0, 0x20, 0x20, 1, 0, 0, 0x20, 0x20, 0, 0, 0, this->scrollAlpha1)); diff --git a/soh/src/overlays/actors/ovl_Bg_Mizu_Movebg/z_bg_mizu_movebg.c b/soh/src/overlays/actors/ovl_Bg_Mizu_Movebg/z_bg_mizu_movebg.c index 0744d75d3..edac821cf 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mizu_Movebg/z_bg_mizu_movebg.c +++ b/soh/src/overlays/actors/ovl_Bg_Mizu_Movebg/z_bg_mizu_movebg.c @@ -366,7 +366,7 @@ void BgMizuMovebg_Draw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); frames = play->gameplayFrames; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, frames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0, 0, diff --git a/soh/src/overlays/actors/ovl_Bg_Mizu_Shutter/z_bg_mizu_shutter.c b/soh/src/overlays/actors/ovl_Bg_Mizu_Shutter/z_bg_mizu_shutter.c index 33f01d82f..c80664ee9 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mizu_Shutter/z_bg_mizu_shutter.c +++ b/soh/src/overlays/actors/ovl_Bg_Mizu_Shutter/z_bg_mizu_shutter.c @@ -159,7 +159,7 @@ void BgMizuShutter_Draw(BgMizuShutter* thisx, PlayState* play) { BgMizuShutter* this = (BgMizuShutter*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Mizu_Water/z_bg_mizu_water.c b/soh/src/overlays/actors/ovl_Bg_Mizu_Water/z_bg_mizu_water.c index b741ff4d4..f469acc69 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mizu_Water/z_bg_mizu_water.c +++ b/soh/src/overlays/actors/ovl_Bg_Mizu_Water/z_bg_mizu_water.c @@ -329,7 +329,7 @@ void BgMizuWater_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); gameplayFrames = play->gameplayFrames; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x0C, Gfx_TwoTexScroll(play->state.gfxCtx, 0, -gameplayFrames * 1, gameplayFrames * 1, 32, 32, 1, 0, diff --git a/soh/src/overlays/actors/ovl_Bg_Mjin/z_bg_mjin.c b/soh/src/overlays/actors/ovl_Bg_Mjin/z_bg_mjin.c index e3c365a3a..dc56f1289 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mjin/z_bg_mjin.c +++ b/soh/src/overlays/actors/ovl_Bg_Mjin/z_bg_mjin.c @@ -122,7 +122,7 @@ void BgMjin_Draw(Actor* thisx, PlayState* play) { dlist = gOcarinaWarpPadDL; } - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, dlist); diff --git a/soh/src/overlays/actors/ovl_Bg_Mori_Bigst/z_bg_mori_bigst.c b/soh/src/overlays/actors/ovl_Bg_Mori_Bigst/z_bg_mori_bigst.c index e0d87f7ef..b3520a5a8 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mori_Bigst/z_bg_mori_bigst.c +++ b/soh/src/overlays/actors/ovl_Bg_Mori_Bigst/z_bg_mori_bigst.c @@ -245,7 +245,7 @@ void BgMoriBigst_Draw(Actor* thisx, PlayState* play) { BgMoriBigst* this = (BgMoriBigst*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, play->objectCtx.status[this->moriTexObjIndex].segment); diff --git a/soh/src/overlays/actors/ovl_Bg_Mori_Elevator/z_bg_mori_elevator.c b/soh/src/overlays/actors/ovl_Bg_Mori_Elevator/z_bg_mori_elevator.c index 1ee1beac5..e497500f8 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mori_Elevator/z_bg_mori_elevator.c +++ b/soh/src/overlays/actors/ovl_Bg_Mori_Elevator/z_bg_mori_elevator.c @@ -254,7 +254,7 @@ void BgMoriElevator_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, play->objectCtx.status[this->moriTexObjIndex].segment); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Mori_Hashigo/z_bg_mori_hashigo.c b/soh/src/overlays/actors/ovl_Bg_Mori_Hashigo/z_bg_mori_hashigo.c index aa71e6846..9d4bcdd15 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mori_Hashigo/z_bg_mori_hashigo.c +++ b/soh/src/overlays/actors/ovl_Bg_Mori_Hashigo/z_bg_mori_hashigo.c @@ -283,7 +283,7 @@ void BgMoriHashigo_Draw(Actor* thisx, PlayState* play) { BgMoriHashigo* this = (BgMoriHashigo*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, play->objectCtx.status[this->moriTexObjIndex].segment); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), diff --git a/soh/src/overlays/actors/ovl_Bg_Mori_Hashira4/z_bg_mori_hashira4.c b/soh/src/overlays/actors/ovl_Bg_Mori_Hashira4/z_bg_mori_hashira4.c index 813b7900c..291bcb056 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mori_Hashira4/z_bg_mori_hashira4.c +++ b/soh/src/overlays/actors/ovl_Bg_Mori_Hashira4/z_bg_mori_hashira4.c @@ -163,7 +163,7 @@ void BgMoriHashira4_Draw(Actor* thisx, PlayState* play) { BgMoriHashira4* this = (BgMoriHashira4*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, play->objectCtx.status[this->moriTexObjIndex].segment); diff --git a/soh/src/overlays/actors/ovl_Bg_Mori_Hineri/z_bg_mori_hineri.c b/soh/src/overlays/actors/ovl_Bg_Mori_Hineri/z_bg_mori_hineri.c index e4d1cc77c..a70ee45e9 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mori_Hineri/z_bg_mori_hineri.c +++ b/soh/src/overlays/actors/ovl_Bg_Mori_Hineri/z_bg_mori_hineri.c @@ -242,7 +242,7 @@ void BgMoriHineri_DrawHallAndRoom(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, play->objectCtx.status[this->moriTexObjIdx].segment); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -251,7 +251,7 @@ void BgMoriHineri_DrawHallAndRoom(Actor* thisx, PlayState* play) { Matrix_Get(&mtx); } if ((this->actionFunc == func_808A3C8C) && (this->dyna.actor.shape.rot.z != 0)) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->dyna.actor.params == 0) { Matrix_Translate(-1761.0f, 1278.0f, -1821.0f, MTXMODE_NEW); } else { diff --git a/soh/src/overlays/actors/ovl_Bg_Mori_Idomizu/z_bg_mori_idomizu.c b/soh/src/overlays/actors/ovl_Bg_Mori_Idomizu/z_bg_mori_idomizu.c index 860b1a320..d540a52ef 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mori_Idomizu/z_bg_mori_idomizu.c +++ b/soh/src/overlays/actors/ovl_Bg_Mori_Idomizu/z_bg_mori_idomizu.c @@ -165,7 +165,7 @@ void BgMoriIdomizu_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Mori_Kaitenkabe/z_bg_mori_kaitenkabe.c b/soh/src/overlays/actors/ovl_Bg_Mori_Kaitenkabe/z_bg_mori_kaitenkabe.c index 7e765f21f..2a2cfc004 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mori_Kaitenkabe/z_bg_mori_kaitenkabe.c +++ b/soh/src/overlays/actors/ovl_Bg_Mori_Kaitenkabe/z_bg_mori_kaitenkabe.c @@ -162,7 +162,7 @@ void BgMoriKaitenkabe_Draw(Actor* thisx, PlayState* play) { BgMoriKaitenkabe* this = (BgMoriKaitenkabe*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, play->objectCtx.status[this->moriTexObjIndex].segment); diff --git a/soh/src/overlays/actors/ovl_Bg_Mori_Rakkatenjo/z_bg_mori_rakkatenjo.c b/soh/src/overlays/actors/ovl_Bg_Mori_Rakkatenjo/z_bg_mori_rakkatenjo.c index 52e46f678..0fa09e51a 100644 --- a/soh/src/overlays/actors/ovl_Bg_Mori_Rakkatenjo/z_bg_mori_rakkatenjo.c +++ b/soh/src/overlays/actors/ovl_Bg_Mori_Rakkatenjo/z_bg_mori_rakkatenjo.c @@ -223,7 +223,7 @@ void BgMoriRakkatenjo_Draw(Actor* thisx, PlayState* play) { BgMoriRakkatenjo* this = (BgMoriRakkatenjo*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, play->objectCtx.status[this->moriTexObjIndex].segment); diff --git a/soh/src/overlays/actors/ovl_Bg_Po_Event/z_bg_po_event.c b/soh/src/overlays/actors/ovl_Bg_Po_Event/z_bg_po_event.c index 5ca3cb290..f24fdb31f 100644 --- a/soh/src/overlays/actors/ovl_Bg_Po_Event/z_bg_po_event.c +++ b/soh/src/overlays/actors/ovl_Bg_Po_Event/z_bg_po_event.c @@ -605,7 +605,7 @@ void BgPoEvent_Draw(Actor* thisx, PlayState* play) { s32 pad2; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if ((this->type == 3) || (this->type == 2)) { if (this->actionFunc == BgPoEvent_PaintingEmpty) { alpha = 255; diff --git a/soh/src/overlays/actors/ovl_Bg_Po_Syokudai/z_bg_po_syokudai.c b/soh/src/overlays/actors/ovl_Bg_Po_Syokudai/z_bg_po_syokudai.c index 91f13b083..24b091b24 100644 --- a/soh/src/overlays/actors/ovl_Bg_Po_Syokudai/z_bg_po_syokudai.c +++ b/soh/src/overlays/actors/ovl_Bg_Po_Syokudai/z_bg_po_syokudai.c @@ -152,7 +152,7 @@ void BgPoSyokudai_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gGoldenTorchDL); @@ -169,7 +169,7 @@ void BgPoSyokudai_Draw(Actor* thisx, PlayState* play) { Lights_PointSetColorAndRadius(&this->lightInfo, red, green, blue, 200); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (this->flameTextureScroll * -20) & 0x1FF, 32, 128)); diff --git a/soh/src/overlays/actors/ovl_Bg_Pushbox/z_bg_pushbox.c b/soh/src/overlays/actors/ovl_Bg_Pushbox/z_bg_pushbox.c index 9136e8b36..8377d3d3d 100644 --- a/soh/src/overlays/actors/ovl_Bg_Pushbox/z_bg_pushbox.c +++ b/soh/src/overlays/actors/ovl_Bg_Pushbox/z_bg_pushbox.c @@ -80,7 +80,7 @@ void BgPushbox_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, gBlockSmallDL); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot00_Hanebasi/z_bg_spot00_hanebasi.c b/soh/src/overlays/actors/ovl_Bg_Spot00_Hanebasi/z_bg_spot00_hanebasi.c index 87bb4b283..5ad3594d8 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot00_Hanebasi/z_bg_spot00_hanebasi.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot00_Hanebasi/z_bg_spot00_hanebasi.c @@ -264,7 +264,7 @@ void BgSpot00Hanebasi_DrawTorches(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (gSaveContext.sceneSetupIndex >= 4) { sTorchFlameScale = 0.008f; @@ -303,7 +303,7 @@ void BgSpot00Hanebasi_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot01_Fusya/z_bg_spot01_fusya.c b/soh/src/overlays/actors/ovl_Bg_Spot01_Fusya/z_bg_spot01_fusya.c index 0b4f6f972..808e8058e 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot01_Fusya/z_bg_spot01_fusya.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot01_Fusya/z_bg_spot01_fusya.c @@ -78,7 +78,7 @@ void BgSpot01Fusya_Update(Actor* thisx, PlayState* play) { void BgSpot01Fusya_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot01_Idohashira/z_bg_spot01_idohashira.c b/soh/src/overlays/actors/ovl_Bg_Spot01_Idohashira/z_bg_spot01_idohashira.c index 54217f757..cad21a0cc 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot01_Idohashira/z_bg_spot01_idohashira.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot01_Idohashira/z_bg_spot01_idohashira.c @@ -323,7 +323,7 @@ void func_808AB700(BgSpot01Idohashira* this, PlayState* play) { OPEN_DISPS(localGfxCtx); - func_80093D18(localGfxCtx); + Gfx_SetupDL_25Opa(localGfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(localGfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot01_Idomizu/z_bg_spot01_idomizu.c b/soh/src/overlays/actors/ovl_Bg_Spot01_Idomizu/z_bg_spot01_idomizu.c index 62900a648..4205200d8 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot01_Idomizu/z_bg_spot01_idomizu.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot01_Idomizu/z_bg_spot01_idomizu.c @@ -72,7 +72,7 @@ void BgSpot01Idomizu_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot01_Idosoko/z_bg_spot01_idosoko.c b/soh/src/overlays/actors/ovl_Bg_Spot01_Idosoko/z_bg_spot01_idosoko.c index c41e29942..2a752c297 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot01_Idosoko/z_bg_spot01_idosoko.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot01_Idosoko/z_bg_spot01_idosoko.c @@ -75,7 +75,7 @@ void BgSpot01Idosoko_Update(Actor* thisx, PlayState* play) { void BgSpot01Idosoko_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot02_Objects/z_bg_spot02_objects.c b/soh/src/overlays/actors/ovl_Bg_Spot02_Objects/z_bg_spot02_objects.c index ce874b031..b675165d1 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot02_Objects/z_bg_spot02_objects.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot02_Objects/z_bg_spot02_objects.c @@ -275,7 +275,7 @@ void func_808ACCB8(Actor* thisx, PlayState* play) { Matrix_RotateY(play->csCtx.npcActions[0]->urot.y * (M_PI / (f32)0x8000), MTXMODE_APPLY); Matrix_RotateZ(play->csCtx.npcActions[0]->urot.z * (M_PI / (f32)0x8000), MTXMODE_APPLY); Matrix_Scale(1.0f, 1.0f, 1.0f, MTXMODE_APPLY); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPPipeSync(POLY_XLU_DISP++); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, redPrim, greenPrim, bluePrim, 255); @@ -336,7 +336,7 @@ void func_808AD450(Actor* thisx, PlayState* play) { Matrix_RotateX(play->csCtx.npcActions[2]->urot.x * (M_PI / (f32)0x8000), MTXMODE_APPLY); Matrix_RotateY(play->csCtx.npcActions[2]->urot.y * (M_PI / (f32)0x8000), MTXMODE_APPLY); Matrix_Scale(0.9f, 0.9f, (((this->unk_170 - this->unk_172) * lerp) + this->unk_172) * 0.1f, MTXMODE_APPLY); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPPipeSync(POLY_XLU_DISP++); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 170, 128); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot03_Taki/z_bg_spot03_taki.c b/soh/src/overlays/actors/ovl_Bg_Spot03_Taki/z_bg_spot03_taki.c index 0263a8a3f..60f33b7bb 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot03_Taki/z_bg_spot03_taki.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot03_Taki/z_bg_spot03_taki.c @@ -128,7 +128,7 @@ void BgSpot03Taki_Draw(Actor* thisx, PlayState* play) { gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment( POLY_XLU_DISP++, 0x08, diff --git a/soh/src/overlays/actors/ovl_Bg_Spot06_Objects/z_bg_spot06_objects.c b/soh/src/overlays/actors/ovl_Bg_Spot06_Objects/z_bg_spot06_objects.c index 2790c3f36..11b8a0afa 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot06_Objects/z_bg_spot06_objects.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot06_Objects/z_bg_spot06_objects.c @@ -436,7 +436,7 @@ void BgSpot06Objects_DrawLakeHyliaWater(BgSpot06Objects* this, PlayState* play) OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot07_Taki/z_bg_spot07_taki.c b/soh/src/overlays/actors/ovl_Bg_Spot07_Taki/z_bg_spot07_taki.c index 8f60e0dbc..5253da943 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot07_Taki/z_bg_spot07_taki.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot07_Taki/z_bg_spot07_taki.c @@ -73,7 +73,7 @@ void BgSpot07Taki_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); frames = play->gameplayFrames; if (LINK_IS_ADULT) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); if (this->dyna.actor.params == 0) { @@ -82,7 +82,7 @@ void BgSpot07Taki_Draw(Actor* thisx, PlayState* play) { gSPDisplayList(POLY_OPA_DISP++, object_spot07_object_DL_003210); } } - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c b/soh/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c index 4b879da03..943c50d7b 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c @@ -171,7 +171,7 @@ void BgSpot09Obj_Draw(Actor* thisx, PlayState* play) { if (thisx->params == 3) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot11_Oasis/z_bg_spot11_oasis.c b/soh/src/overlays/actors/ovl_Bg_Spot11_Oasis/z_bg_spot11_oasis.c index 92c4b3a72..2b24344e9 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot11_Oasis/z_bg_spot11_oasis.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot11_Oasis/z_bg_spot11_oasis.c @@ -152,7 +152,7 @@ void BgSpot11Oasis_Draw(Actor* thisx, PlayState* play) { u32 gameplayFrames = play->gameplayFrames; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPSegment(POLY_XLU_DISP++, 0x08, diff --git a/soh/src/overlays/actors/ovl_Bg_Spot15_Saku/z_bg_spot15_saku.c b/soh/src/overlays/actors/ovl_Bg_Spot15_Saku/z_bg_spot15_saku.c index d48ffe055..d4d66d3d2 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot15_Saku/z_bg_spot15_saku.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot15_Saku/z_bg_spot15_saku.c @@ -97,7 +97,7 @@ void BgSpot15Saku_Update(Actor* thisx, PlayState* play) { void BgSpot15Saku_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c b/soh/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c index 7e6a7aa8d..102299de8 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c @@ -535,7 +535,7 @@ void BgSpot16Bombstone_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c b/soh/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c index 88008b018..990bdea68 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c @@ -124,7 +124,7 @@ void BgSpot16Doughnut_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -149,7 +149,7 @@ void BgSpot16Doughnut_DrawExpanding(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot17_Bakudankabe/z_bg_spot17_bakudankabe.c b/soh/src/overlays/actors/ovl_Bg_Spot17_Bakudankabe/z_bg_spot17_bakudankabe.c index 5cfc412a9..08f8e36b5 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot17_Bakudankabe/z_bg_spot17_bakudankabe.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot17_Bakudankabe/z_bg_spot17_bakudankabe.c @@ -130,7 +130,7 @@ void BgSpot17Bakudankabe_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -146,7 +146,7 @@ void BgSpot17Bakudankabe_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c b/soh/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c index 82da3d1c8..ee2f79643 100644 --- a/soh/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c +++ b/soh/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c @@ -57,7 +57,7 @@ void func_808B7478(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_RotateY((s16)(Camera_GetCamDirYaw(GET_ACTIVE_CAM(play)) - thisx->shape.rot.y + 0x8000) * 9.58738019108e-05f, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_Bg_Sst_Floor/z_bg_sst_floor.c b/soh/src/overlays/actors/ovl_Bg_Sst_Floor/z_bg_sst_floor.c index 847960a5d..36c0dc17d 100644 --- a/soh/src/overlays/actors/ovl_Bg_Sst_Floor/z_bg_sst_floor.c +++ b/soh/src/overlays/actors/ovl_Bg_Sst_Floor/z_bg_sst_floor.c @@ -124,7 +124,7 @@ void BgSstFloor_Draw(BgSstFloor* thisx, PlayState* play) { BgSstFloor* this = (BgSstFloor*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Scale(1.0f, this->drumHeight * -0.0025f, 1.0f, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), diff --git a/soh/src/overlays/actors/ovl_Bg_Toki_Hikari/z_bg_toki_hikari.c b/soh/src/overlays/actors/ovl_Bg_Toki_Hikari/z_bg_toki_hikari.c index 063496bf5..26b20d9b1 100644 --- a/soh/src/overlays/actors/ovl_Bg_Toki_Hikari/z_bg_toki_hikari.c +++ b/soh/src/overlays/actors/ovl_Bg_Toki_Hikari/z_bg_toki_hikari.c @@ -86,7 +86,7 @@ void func_808BA018(BgTokiHikari* this, PlayState* play) { s32 pad; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -94,7 +94,7 @@ void func_808BA018(BgTokiHikari* this, PlayState* play) { gSPDisplayList(POLY_OPA_DISP++, object_toki_objects_DL_008190); } else { gSPDisplayList(POLY_OPA_DISP++, object_toki_objects_DL_007E20); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 8, Gfx_TexScroll(play->state.gfxCtx, 0, play->gameplayFrames % 128, 64, 32)); @@ -140,7 +140,7 @@ void func_808BA2CC(BgTokiHikari* this, PlayState* play) { Matrix_Translate(0.0f, 276.0f, 1122.0f, MTXMODE_NEW); Matrix_Scale(0.32f, 0.32f, this->unk_14C * 7.0f, MTXMODE_APPLY); Matrix_RotateZ(M_PI, MTXMODE_APPLY); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Push(); gDPPipeSync(POLY_XLU_DISP++); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, this->unk_14C * 255.0f, (u8)(155.0f * this->unk_14C) + 100, diff --git a/soh/src/overlays/actors/ovl_Bg_Toki_Swd/z_bg_toki_swd.c b/soh/src/overlays/actors/ovl_Bg_Toki_Swd/z_bg_toki_swd.c index 30c160b51..c1406382f 100644 --- a/soh/src/overlays/actors/ovl_Bg_Toki_Swd/z_bg_toki_swd.c +++ b/soh/src/overlays/actors/ovl_Bg_Toki_Swd/z_bg_toki_swd.c @@ -187,7 +187,7 @@ void BgTokiSwd_Draw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_8002EBCC(&this->actor, play, 0); diff --git a/soh/src/overlays/actors/ovl_Bg_Treemouth/z_bg_treemouth.c b/soh/src/overlays/actors/ovl_Bg_Treemouth/z_bg_treemouth.c index 831e03a61..4d2400b62 100644 --- a/soh/src/overlays/actors/ovl_Bg_Treemouth/z_bg_treemouth.c +++ b/soh/src/overlays/actors/ovl_Bg_Treemouth/z_bg_treemouth.c @@ -232,7 +232,7 @@ void BgTreemouth_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if ((gSaveContext.sceneSetupIndex < 4) || LINK_IS_ADULT) { if (gSaveContext.eventChkInf[0] & 0x80) { diff --git a/soh/src/overlays/actors/ovl_Bg_Vb_Sima/z_bg_vb_sima.c b/soh/src/overlays/actors/ovl_Bg_Vb_Sima/z_bg_vb_sima.c index 70a58df6e..dcbb6c126 100644 --- a/soh/src/overlays/actors/ovl_Bg_Vb_Sima/z_bg_vb_sima.c +++ b/soh/src/overlays/actors/ovl_Bg_Vb_Sima/z_bg_vb_sima.c @@ -151,7 +151,7 @@ void BgVbSima_Update(Actor* thisx, PlayState* play) { void BgVbSima_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gVolvagiaPlatformDL); diff --git a/soh/src/overlays/actors/ovl_Bg_Ydan_Hasi/z_bg_ydan_hasi.c b/soh/src/overlays/actors/ovl_Bg_Ydan_Hasi/z_bg_ydan_hasi.c index f74bdecc9..a74e166f1 100644 --- a/soh/src/overlays/actors/ovl_Bg_Ydan_Hasi/z_bg_ydan_hasi.c +++ b/soh/src/overlays/actors/ovl_Bg_Ydan_Hasi/z_bg_ydan_hasi.c @@ -179,7 +179,7 @@ void BgYdanHasi_Draw(Actor* thisx, PlayState* play) { } else { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, -play->gameplayFrames % 128, play->gameplayFrames % 128, 0x20, 0x20, 1, play->gameplayFrames % 128, diff --git a/soh/src/overlays/actors/ovl_Bg_Ydan_Sp/z_bg_ydan_sp.c b/soh/src/overlays/actors/ovl_Bg_Ydan_Sp/z_bg_ydan_sp.c index d9fa609fc..e4c80d3f8 100644 --- a/soh/src/overlays/actors/ovl_Bg_Ydan_Sp/z_bg_ydan_sp.c +++ b/soh/src/overlays/actors/ovl_Bg_Ydan_Sp/z_bg_ydan_sp.c @@ -425,7 +425,7 @@ void BgYdanSp_Draw(Actor* thisx, PlayState* play) { MtxF mtxF; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (thisx->params == WEB_WALL) { gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Bg_Zg/z_bg_zg.c b/soh/src/overlays/actors/ovl_Bg_Zg/z_bg_zg.c index 0703debd9..8759d1e31 100644 --- a/soh/src/overlays/actors/ovl_Bg_Zg/z_bg_zg.c +++ b/soh/src/overlays/actors/ovl_Bg_Zg/z_bg_zg.c @@ -125,7 +125,7 @@ void func_808C0EEC(BgZg* this, PlayState* play) { OPEN_DISPS(localGfxCtx); - func_80093D18(localGfxCtx); + Gfx_SetupDL_25Opa(localGfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(localGfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gTowerCollapseBarsDL); diff --git a/soh/src/overlays/actors/ovl_Boss_Dodongo/z_boss_dodongo.c b/soh/src/overlays/actors/ovl_Boss_Dodongo/z_boss_dodongo.c index 5aa33a911..8d58dc6c9 100644 --- a/soh/src/overlays/actors/ovl_Boss_Dodongo/z_boss_dodongo.c +++ b/soh/src/overlays/actors/ovl_Boss_Dodongo/z_boss_dodongo.c @@ -1140,7 +1140,7 @@ void BossDodongo_Draw(Actor* thisx, PlayState* play) { s32 pad; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if ((this->unk_1C0 >= 2) && (this->unk_1C0 & 1)) { POLY_OPA_DISP = Gfx_SetFog(POLY_OPA_DISP, 255, 255, 255, 0, 900, 1099); @@ -1700,7 +1700,7 @@ void BossDodongo_DrawEffects(PlayState* play) { OPEN_DISPS(gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); unkMtx = &play->billboardMtxF; // OTRTODO: This call causes the whole texture cache to be cleaned up, which causes an important slowdown on switch so we need to find a way to avoid it. diff --git a/soh/src/overlays/actors/ovl_Boss_Fd/z_boss_fd.c b/soh/src/overlays/actors/ovl_Boss_Fd/z_boss_fd.c index 22cdd76fa..872dd051b 100644 --- a/soh/src/overlays/actors/ovl_Boss_Fd/z_boss_fd.c +++ b/soh/src/overlays/actors/ovl_Boss_Fd/z_boss_fd.c @@ -1527,7 +1527,7 @@ void BossFd_DrawEffects(BossFdEffect* effect, PlayState* play) { if (effect->type == BFD_FX_EMBER) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, gVolvagiaEmberMaterialDL); flag++; } @@ -1550,7 +1550,7 @@ void BossFd_DrawEffects(BossFdEffect* effect, PlayState* play) { if (effect->type == BFD_FX_DEBRIS) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPDisplayList(POLY_OPA_DISP++, gVolvagiaDebrisMaterialDL); flag++; } @@ -1573,7 +1573,7 @@ void BossFd_DrawEffects(BossFdEffect* effect, PlayState* play) { if (effect->type == BFD_FX_DUST) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0); gSPDisplayList(POLY_XLU_DISP++, gVolvagiaDustMaterialDL); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 90, 30, 0, 255); gDPSetEnvColor(POLY_XLU_DISP++, 90, 30, 0, 0); @@ -1598,7 +1598,7 @@ void BossFd_DrawEffects(BossFdEffect* effect, PlayState* play) { if (effect->type == BFD_FX_FIRE_BREATH) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0); gSPDisplayList(POLY_XLU_DISP++, gVolvagiaDustMaterialDL); gDPSetEnvColor(POLY_XLU_DISP++, 255, 10, 0, 255); flag++; @@ -1623,7 +1623,7 @@ void BossFd_DrawEffects(BossFdEffect* effect, PlayState* play) { if (effect->type == BFD_FX_SKULL_PIECE) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, gVolvagiaSkullPieceMaterialDL); flag++; } @@ -1650,7 +1650,7 @@ void BossFd_Draw(Actor* thisx, PlayState* play) { osSyncPrintf("FD DRAW START\n"); if (this->actionFunc != BossFd_Wait) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->work[BFD_DAMAGE_FLASH_TIMER] & 2) { POLY_OPA_DISP = Gfx_SetFog(POLY_OPA_DISP, 255, 255, 255, 0, 900, 1099); } @@ -1972,7 +1972,7 @@ void BossFd_DrawBody(PlayState* play, BossFd* this) { Vec3f spB0 = { 0.0f, 1700.0f, 7000.0f }; Vec3f spA4 = { -1000.0f, 700.0f, 7000.0f }; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, gVolvagiaManeMaterialDL); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, this->fwork[BFD_MANE_COLOR_CENTER], 0, 255); Matrix_Push(); diff --git a/soh/src/overlays/actors/ovl_Boss_Fd2/z_boss_fd2.c b/soh/src/overlays/actors/ovl_Boss_Fd2/z_boss_fd2.c index a13c13d45..15b3ba17b 100644 --- a/soh/src/overlays/actors/ovl_Boss_Fd2/z_boss_fd2.c +++ b/soh/src/overlays/actors/ovl_Boss_Fd2/z_boss_fd2.c @@ -1178,7 +1178,7 @@ void BossFd2_DrawMane(BossFd2* this, PlayState* play) { this->leftMane.scale[i] = 1.5f + 0.3f * Math_CosS(5696.0f * this->work[FD2_VAR_TIMER] + i * 0x3200); } - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, gHoleVolvagiaManeMaterialDL); @@ -1205,7 +1205,7 @@ void BossFd2_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); osSyncPrintf("FD2 draw start \n"); if (this->actionFunc != BossFd2_Wait) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->work[FD2_DAMAGE_FLASH_TIMER] & 2) { POLY_OPA_DISP = Gfx_SetFog(POLY_OPA_DISP, 255, 255, 255, 0, 900, 1099); } diff --git a/soh/src/overlays/actors/ovl_Boss_Ganon/z_boss_ganon.c b/soh/src/overlays/actors/ovl_Boss_Ganon/z_boss_ganon.c index 817bafa15..b85ec62c1 100644 --- a/soh/src/overlays/actors/ovl_Boss_Ganon/z_boss_ganon.c +++ b/soh/src/overlays/actors/ovl_Boss_Ganon/z_boss_ganon.c @@ -3362,7 +3362,7 @@ void BossGanon_DrawShock(BossGanon* this, PlayState* play) { OPEN_DISPS(gfxCtx); if ((this->unk_2E8 != 0) || (this->unk_2E6 != 0)) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, 255); gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 0, 0); gSPDisplayList(POLY_XLU_DISP++, gGanondorfLightBallMaterialDL); @@ -3426,7 +3426,7 @@ void BossGanon_DrawHandLightBall(BossGanon* this, PlayState* play) { OPEN_DISPS(gfxCtx); if (this->handLightBallScale > 0.0f) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, 255); if ((this->unk_1A2 % 2) != 0) { @@ -3467,7 +3467,7 @@ void BossGanon_DrawBigMagicCharge(BossGanon* this, PlayState* play) { OPEN_DISPS(gfxCtx); if (this->unk_284 > 0.0f) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); // light flecks gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 170, (s8)this->unk_290); @@ -3786,7 +3786,7 @@ void BossGanon_DrawShadowTexture(void* tex, BossGanon* this, PlayState* play) { OPEN_DISPS(gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 0, 0, 0, 50); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 0); @@ -3824,8 +3824,8 @@ void BossGanon_Draw(Actor* thisx, PlayState* play) { gSPInvalidateTexCache(POLY_OPA_DISP++, ganon_boss_sceneTex_007418); } - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if ((this->unk_1A6 & 2) != 0) { POLY_OPA_DISP = Gfx_SetFog(POLY_OPA_DISP, 255, 50, 0, 0, 900, 1099); @@ -4166,7 +4166,7 @@ void BossGanon_LightBall_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); alpha = ((this->unk_1A2 % 2) != 0) ? this->fwork[GDF_FWORK_1] * 0.4f : this->fwork[GDF_FWORK_1] * 0.35f; @@ -4315,7 +4315,7 @@ void func_808E229C(Actor* thisx, PlayState* play2) { s32 temp; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, 255); gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 0, 0); gSPDisplayList(POLY_XLU_DISP++, gGanondorfLightBallMaterialDL); @@ -4597,7 +4597,7 @@ void func_808E324C(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, 255, 255, 255, (s8)this->fwork[GDF_FWORK_1]); gDPSetEnvColor(POLY_XLU_DISP++, 150, 255, 0, 128); gSPSegment(POLY_XLU_DISP++, 0x0D, mtx); @@ -4853,7 +4853,7 @@ void BossGanon_DrawEffects(PlayState* play) { GanondorfEffect* effFirst = eff; OPEN_DISPS(gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < 200; i++, eff++) { if (eff->type == GDF_EFF_WINDOW_SHARD) { diff --git a/soh/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c b/soh/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c index 0efb308f5..7e8548800 100644 --- a/soh/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c +++ b/soh/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c @@ -2649,7 +2649,7 @@ void func_80904D88(BossGanon2* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->unk_30C > 0.0f) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->unk_380 > 0.0f) { gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 170, 255); gDPSetEnvColor(POLY_XLU_DISP++, 255, 200, 0, 0); @@ -2683,7 +2683,7 @@ void func_80904FC8(BossGanon2* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->unk_384 > 0.0f) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, 200); gDPSetEnvColor(POLY_XLU_DISP++, 255, 200, 0, 0); gSPDisplayList(POLY_XLU_DISP++, ovl_Boss_Ganon2_DL_00B308); @@ -2714,7 +2714,7 @@ void func_8090523C(BossGanon2* this, PlayState* play) { s8 i; player = GET_PLAYER(play); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, (s16)this->unk_38C); gDPSetEnvColor(POLY_XLU_DISP++, 0, 255, 255, 0); gSPDisplayList(POLY_XLU_DISP++, ovl_Boss_Ganon2_DL_00B308); @@ -2799,8 +2799,8 @@ void BossGanon2_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); switch (this->unk_337) { case 0: @@ -2942,7 +2942,7 @@ void func_809060E8(PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); for (i = 0; i < 1; i++) { if (effect->type == 1) { @@ -2952,7 +2952,7 @@ void func_809060E8(PlayState* play) { f32 temp_f0; f32 angle; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); spA0.x = play->envCtx.dirLight1.params.dir.x; spA0.y = play->envCtx.dirLight1.params.dir.y; spA0.z = play->envCtx.dirLight1.params.dir.z; @@ -3111,7 +3111,7 @@ void BossGanon2_DrawShadowTexture(void* shadowTexture, BossGanon2* this, PlaySta OPEN_DISPS(gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if ((play->envCtx.unk_BD == 1) || (play->envCtx.unk_BD == 2)) { alpha = (s16)(play->envCtx.unk_D8 * 180.0f) + 30; diff --git a/soh/src/overlays/actors/ovl_Boss_Ganondrof/z_boss_ganondrof.c b/soh/src/overlays/actors/ovl_Boss_Ganondrof/z_boss_ganondrof.c index dc0f2fd5c..72502226c 100644 --- a/soh/src/overlays/actors/ovl_Boss_Ganondrof/z_boss_ganondrof.c +++ b/soh/src/overlays/actors/ovl_Boss_Ganondrof/z_boss_ganondrof.c @@ -1537,7 +1537,7 @@ void BossGanondrof_Draw(Actor* thisx, PlayState* play) { } osSyncPrintf("YP %f\n", this->actor.world.pos.y); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->work[GND_INVINC_TIMER] & 4) { POLY_OPA_DISP = Gfx_SetFog(POLY_OPA_DISP, 255, 50, 0, 0, 900, 1099); } else { diff --git a/soh/src/overlays/actors/ovl_Boss_Goma/z_boss_goma.c b/soh/src/overlays/actors/ovl_Boss_Goma/z_boss_goma.c index 97d354ac0..16db7b6db 100644 --- a/soh/src/overlays/actors/ovl_Boss_Goma/z_boss_goma.c +++ b/soh/src/overlays/actors/ovl_Boss_Goma/z_boss_goma.c @@ -2123,7 +2123,7 @@ void BossGoma_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Translate(0.0f, -4000.0f, 0.0f, MTXMODE_APPLY); // Invalidate Texture Cache since Goma modifies her own texture diff --git a/soh/src/overlays/actors/ovl_Boss_Mo/z_boss_mo.c b/soh/src/overlays/actors/ovl_Boss_Mo/z_boss_mo.c index 1d7256dd2..00f245ca6 100644 --- a/soh/src/overlays/actors/ovl_Boss_Mo/z_boss_mo.c +++ b/soh/src/overlays/actors/ovl_Boss_Mo/z_boss_mo.c @@ -2577,7 +2577,7 @@ void BossMo_DrawWater(BossMo* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); Matrix_Push(); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Translate(0.0f, MO_WATER_LEVEL(play), 0.0f, MTXMODE_NEW); gSPSegment(POLY_XLU_DISP++, 0x0D, @@ -2609,7 +2609,7 @@ void BossMo_DrawCore(Actor* thisx, PlayState* play) { BossMo_DrawWater(this, play); } if (this->drawActor) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, sMorphaTent1->work[MO_TENT_VAR_TIMER] * 3, @@ -2654,7 +2654,7 @@ void BossMo_DrawCore(Actor* thisx, PlayState* play) { shadowAlpha = 160; } - func_80094044(play->state.gfxCtx); + Gfx_SetupDL_44Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 0, 0, 0, shadowAlpha); @@ -2681,7 +2681,7 @@ void BossMo_DrawCore(Actor* thisx, PlayState* play) { Vec3f sp6C; Vec3f sp60; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0xFF, 0xFF, 200, 255, 255, (s8)this->fwork[MO_CORE_INTRO_WATER_ALPHA]); gDPSetEnvColor(POLY_XLU_DISP++, 0, 100, 255, (s8)this->fwork[MO_CORE_INTRO_WATER_ALPHA]); @@ -2734,11 +2734,11 @@ void BossMo_DrawTent(Actor* thisx, PlayState* play) { u16 scroll; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 255, 255, (s8)(this->baseAlpha * 1.5f)); gDPSetEnvColor(POLY_OPA_DISP++, 150, 150, 150, 0); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->work[MO_TENT_BASE_TEX1_X], this->work[MO_TENT_BASE_TEX1_Y], 32, 32, 1, this->work[MO_TENT_BASE_TEX2_X], @@ -2921,7 +2921,7 @@ void BossMo_DrawEffects(BossMoEffect* effect, PlayState* play) { if (effect->type == MO_FX_BIG_RIPPLE) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (flag == 0) { - func_80094BC4(gfxCtx); + Gfx_SetupDL_60NoCDXlu(gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 155, 155, 255, 0); @@ -2946,7 +2946,7 @@ void BossMo_DrawEffects(BossMoEffect* effect, PlayState* play) { if (effect->type == MO_FX_SMALL_RIPPLE) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (flag == 0) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 155, 155, 255, 0); @@ -2972,7 +2972,7 @@ void BossMo_DrawEffects(BossMoEffect* effect, PlayState* play) { (effect->type == MO_FX_SPLASH_TRAIL)) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (flag == 0) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(gDust1Tex)); gSPDisplayList(POLY_XLU_DISP++, gMorphaDropletMaterialDL); @@ -3002,7 +3002,7 @@ void BossMo_DrawEffects(BossMoEffect* effect, PlayState* play) { if (effect->type == MO_FX_WET_SPOT) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (flag == 0) { - func_80094044(gfxCtx); + Gfx_SetupDL_44Xlu(gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(gDust1Tex)); gDPSetEnvColor(POLY_XLU_DISP++, 250, 250, 255, 0); @@ -3030,7 +3030,7 @@ void BossMo_DrawEffects(BossMoEffect* effect, PlayState* play) { if (effect->type == MO_FX_BUBBLE) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (flag == 0) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 150, 150, 150, 0); diff --git a/soh/src/overlays/actors/ovl_Boss_Sst/z_boss_sst.c b/soh/src/overlays/actors/ovl_Boss_Sst/z_boss_sst.c index 83680e0e0..e65c15d32 100644 --- a/soh/src/overlays/actors/ovl_Boss_Sst/z_boss_sst.c +++ b/soh/src/overlays/actors/ovl_Boss_Sst/z_boss_sst.c @@ -2710,7 +2710,7 @@ void BossSst_DrawHand(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0x00, 0x80, sBodyColor.r, sBodyColor.g, sBodyColor.b, 255); @@ -2731,7 +2731,7 @@ void BossSst_DrawHand(Actor* thisx, PlayState* play) { s32 end; s32 pad; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); end = this->trailCount >> 1; idx = (this->trailIndex + 4) % 7; @@ -2867,7 +2867,7 @@ void BossSst_DrawHead(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (!CHECK_FLAG_ALL(this->actor.flags, ACTOR_FLAG_7)) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0x00, 0x80, sBodyColor.r, sBodyColor.g, sBodyColor.b, 255); if (!sBodyStatic) { gSPSegment(POLY_OPA_DISP++, 0x08, &D_80116280[2]); @@ -2876,7 +2876,7 @@ void BossSst_DrawHead(Actor* thisx, PlayState* play) { gSPSegment(POLY_OPA_DISP++, 0x08, sBodyStaticDList); } } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0x00, 0x80, 255, 255, 255, 255); gSPSegment(POLY_XLU_DISP++, 0x08, &D_80116280[2]); } @@ -2908,7 +2908,7 @@ void BossSst_DrawHead(Actor* thisx, PlayState* play) { Vec3f vanishMaskPos; Vec3f vanishMaskOffset; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0x00, 0x00, 0, 0, 18, 255); yOffset = 113 * 8 - this->timer * 8; @@ -3168,7 +3168,7 @@ void BossSst_DrawEffect(Actor* thisx, PlayState* play) { if (this->effectMode != BONGO_NULL) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->effectMode == BONGO_ICE) { gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, play->gameplayFrames % 256, 0x20, 0x10, 1, diff --git a/soh/src/overlays/actors/ovl_Boss_Tw/z_boss_tw.c b/soh/src/overlays/actors/ovl_Boss_Tw/z_boss_tw.c index 2f5843ffb..08cb71cad 100644 --- a/soh/src/overlays/actors/ovl_Boss_Tw/z_boss_tw.c +++ b/soh/src/overlays/actors/ovl_Boss_Tw/z_boss_tw.c @@ -3240,7 +3240,7 @@ void func_80941BC0(BossTw* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); Matrix_Push(); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Translate(this->groundBlastPos2.x, this->groundBlastPos2.y, this->groundBlastPos2.z, MTXMODE_NEW); Matrix_Scale(this->workf[UNK_F12], this->workf[UNK_F12], this->workf[UNK_F12], MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), @@ -3285,7 +3285,7 @@ void func_80942180(BossTw* this, PlayState* play) { Matrix_Push(); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Translate(this->groundBlastPos2.x, this->groundBlastPos2.y, this->groundBlastPos2.z, MTXMODE_NEW); Matrix_Scale(this->workf[KM_GD_CRTR_SCL], this->workf[KM_GD_CRTR_SCL], this->workf[KM_GD_CRTR_SCL], MTXMODE_APPLY); gSPSegment(POLY_XLU_DISP++, 8, @@ -3444,7 +3444,7 @@ void func_80943028(Actor* thisx, PlayState* play) { gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(object_tw_DL_01F608)); - func_80094044(play->state.gfxCtx); + Gfx_SetupDL_44Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 0, 0, 0, 200); Matrix_Translate(this->actor.world.pos.x, 240.0f, this->actor.world.pos.z, MTXMODE_NEW); Matrix_Scale((this->actor.scale.x * 4000.0f) / 100.0f, 1.0f, (this->actor.scale.x * 4000.0f) / 100.0f, @@ -3492,8 +3492,8 @@ void BossTw_Draw(Actor* thisx, PlayState* play2) { (s16)this->workf[INNR_CRWN_TX_Y2] & 0xFF, 0x20, 0x40)); } - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->work[FOG_TIMER] & 2) { POLY_OPA_DISP = Gfx_SetFog(POLY_OPA_DISP, 255, 50, 0, 0, 900, 1099); @@ -3761,7 +3761,7 @@ void BossTw_SpawnPortalDraw(BossTw* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment( POLY_XLU_DISP++, 8, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, -this->work[CS_TIMER_1] * 15, 0x20, 0x40, 1, 0, 0, 0x40, 0x40)); @@ -3851,8 +3851,8 @@ void BossTw_TwinrovaDraw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); if (this->visible) { - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); POLY_OPA_DISP = (this->work[FOG_TIMER] & 2) ? Gfx_SetFog2(POLY_OPA_DISP, 255, 50, 0, 0, 900, 1099) : Gfx_SetFog2(POLY_OPA_DISP, (u32)this->fogR, (u32)this->fogG, @@ -4419,7 +4419,7 @@ void BossTw_BlastDraw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); switch (this->actor.params) { case TW_FIRE_BLAST: @@ -4491,7 +4491,7 @@ void BossTw_DrawDeathBall(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->actor.params == TW_DEATHBALL_KOUME) { gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 200, 20, 0, (s8)this->workf[TAIL_ALPHA]); @@ -4901,7 +4901,7 @@ void BossTw_DrawEffects(PlayState* play) { OPEN_DISPS(gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(sTwEffects); i++) { if (currentEffect->type == 1) { diff --git a/soh/src/overlays/actors/ovl_Boss_Va/z_boss_va.c b/soh/src/overlays/actors/ovl_Boss_Va/z_boss_va.c index e78925d7f..88ee2894f 100644 --- a/soh/src/overlays/actors/ovl_Boss_Va/z_boss_va.c +++ b/soh/src/overlays/actors/ovl_Boss_Va/z_boss_va.c @@ -3193,9 +3193,9 @@ void BossVa_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); paramsPtr = &this->actor.params; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); switch (this->actor.params) { case BOSSVA_BODY: @@ -3526,7 +3526,7 @@ void BossVa_DrawEffects(BossVaEffect* effect, PlayState* play) { if (effect->type == VA_LARGE_SPARK) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 130, 130, 30, 0); gSPDisplayList(POLY_XLU_DISP++, gBarinadeDL_0156A0); flag++; @@ -3549,7 +3549,7 @@ void BossVa_DrawEffects(BossVaEffect* effect, PlayState* play) { if (effect->type == VA_SPARK_BALL) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, gBarinadeDL_011738); flag++; } @@ -3577,7 +3577,7 @@ void BossVa_DrawEffects(BossVaEffect* effect, PlayState* play) { if (effect->type == VA_BLOOD) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, gBarinadeDL_009430); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(gEffBubble1Tex)); flag++; @@ -3611,7 +3611,7 @@ void BossVa_DrawEffects(BossVaEffect* effect, PlayState* play) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, effect->envColor[3]); gSPDisplayList(POLY_OPA_DISP++, gBarinadeDL_0128B8); flag++; @@ -3635,7 +3635,7 @@ void BossVa_DrawEffects(BossVaEffect* effect, PlayState* play) { if (effect->type == VA_GORE) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPDisplayList(POLY_OPA_DISP++, gBarinadeDL_012BA0); flag++; } @@ -3668,7 +3668,7 @@ void BossVa_DrawEffects(BossVaEffect* effect, PlayState* play) { if (effect->type == VA_ZAP_CHARGE) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, gBarinadeDL_0135B0); flag++; } @@ -3693,7 +3693,7 @@ void BossVa_DrawEffects(BossVaEffect* effect, PlayState* play) { if (effect->type == VA_BLAST_SPARK) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - func_80093C14(play->state.gfxCtx); + Gfx_SetupDL_25Xlu2(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 130, 130, 30, 0); gSPDisplayList(POLY_XLU_DISP++, gBarinadeDL_0156A0); flag++; @@ -3717,7 +3717,7 @@ void BossVa_DrawEffects(BossVaEffect* effect, PlayState* play) { if (effect->type == VA_SMALL_SPARK) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (!flag) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 100, 0); gSPDisplayList(POLY_XLU_DISP++, gBarinadeDL_008F08); flag++; diff --git a/soh/src/overlays/actors/ovl_Demo_6K/z_demo_6k.c b/soh/src/overlays/actors/ovl_Demo_6K/z_demo_6k.c index debdad31d..f089bc4b1 100644 --- a/soh/src/overlays/actors/ovl_Demo_6K/z_demo_6k.c +++ b/soh/src/overlays/actors/ovl_Demo_6K/z_demo_6k.c @@ -566,7 +566,7 @@ void func_80967FFC(Actor* thisx, PlayState* play) { u16 timer1 = this->timer1; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_RotateX(-M_PI / 2, MTXMODE_APPLY); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0x7FFF - ((timer1 * 8) & 0x7FFF), 16, 512, 1, 0, @@ -618,12 +618,12 @@ void func_80968298(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); alpha = (s32)(this->unk_170 * 255.0f); - POLY_XLU_DISP = func_800937C0(POLY_XLU_DISP); + POLY_XLU_DISP = Gfx_SetupDL_57(POLY_XLU_DISP); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 0, 0, 0, alpha); gDPSetAlphaDither(POLY_XLU_DISP++, G_AD_DISABLE); gDPSetColorDither(POLY_XLU_DISP++, G_CD_DISABLE); gDPFillRectangle(POLY_XLU_DISP++, 0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); alpha = (s32)(this->unk_16C * 255.0f); for (i2 = 0, i = 0; i < 63; i++) { @@ -646,7 +646,7 @@ void func_80968298(Actor* thisx, PlayState* play) { Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, 255); gDPSetEnvColor(POLY_XLU_DISP++, 50, 50, 50, 255); gSPDisplayList(POLY_XLU_DISP++, object_demo_6k_DL_001040); @@ -668,7 +668,7 @@ void func_8096865C(Actor* thisx, PlayState* play) { displayList = gEffFlash2DL; } - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 255, 255, 255); gDPSetEnvColor(POLY_XLU_DISP++, sEnvColors[this->unk_293].r, sEnvColors[this->unk_293].g, sEnvColors[this->unk_293].b, 255); @@ -698,7 +698,7 @@ void func_809688C4(Actor* thisx, PlayState* play2) { (play->csCtx.npcActions[1]->action != 1)) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 255, 255, 255); Matrix_RotateY((s16)(Camera_GetCamDirYaw(GET_ACTIVE_CAM(play)) + 0x8000) * (M_PI / 0x8000), MTXMODE_APPLY); @@ -737,7 +737,7 @@ void func_80968B70(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Mult(&play->billboardMtxF, MTXMODE_APPLY); Matrix_RotateX(M_PI / 2, MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), @@ -785,7 +785,7 @@ void func_80968FB0(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); scaleFactor = ((s16)D_809693CC[(frames * 4) & 0xF] * 0.01f) + 1.0f; Matrix_Scale(this->actor.scale.x * scaleFactor, this->actor.scale.y * scaleFactor, this->actor.scale.z * scaleFactor, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_Demo_Du/z_demo_du.c b/soh/src/overlays/actors/ovl_Demo_Du/z_demo_du.c index 556a54135..f182d9d5f 100644 --- a/soh/src/overlays/actors/ovl_Demo_Du/z_demo_du.c +++ b/soh/src/overlays/actors/ovl_Demo_Du/z_demo_du.c @@ -807,7 +807,7 @@ void DemoDu_Draw_02(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTexture)); gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(mouthTexture)); @@ -1002,7 +1002,7 @@ void DemoDu_Draw_01(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTexture)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(mouthTexture)); diff --git a/soh/src/overlays/actors/ovl_Demo_Ec/z_demo_ec.c b/soh/src/overlays/actors/ovl_Demo_Ec/z_demo_ec.c index bd21a2467..46ede7985 100644 --- a/soh/src/overlays/actors/ovl_Demo_Ec/z_demo_ec.c +++ b/soh/src/overlays/actors/ovl_Demo_Ec/z_demo_ec.c @@ -256,7 +256,7 @@ void DemoEc_DrawSkeleton(DemoEc* this, PlayState* play, void* eyeTexture, void* OPEN_DISPS(gfxCtx); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); if (eyeTexture != NULL) { gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTexture)); @@ -282,7 +282,7 @@ void DemoEc_DrawSkeletonCustomColor(DemoEc* this, PlayState* play, Gfx* arg2, Gf OPEN_DISPS(gfxCtx); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); if (arg2 != 0) { gSPSegment(POLY_OPA_DISP++, 0x0A, SEGMENTED_TO_VIRTUAL(arg2)); diff --git a/soh/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c b/soh/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c index f1d9b76c2..e41bf1996 100644 --- a/soh/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c +++ b/soh/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c @@ -1759,13 +1759,13 @@ void DemoEffect_DrawJewel(Actor* thisx, PlayState* play2) { G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); func_8002ED80(&this->actor, play, 0); gDPSetPrimColor(POLY_XLU_DISP++, 0, 128, this->primXluColor[0], this->primXluColor[1], this->primXluColor[2], 255); gDPSetEnvColor(POLY_XLU_DISP++, this->envXluColor[0], this->envXluColor[1], this->envXluColor[2], 255); gSPDisplayList(POLY_XLU_DISP++, this->jewelDisplayList); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_8002EBCC(&this->actor, play, 0); gDPSetPrimColor(POLY_OPA_DISP++, 0, 128, this->primOpaColor[0], this->primOpaColor[1], this->primOpaColor[2], 255); @@ -1793,7 +1793,7 @@ void DemoEffect_DrawCrystalLight(Actor* thisx, PlayState* play) { gDPSetPrimColor(POLY_XLU_DISP++, 128, 128, 255, 255, 170, 255); } - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 8, Gfx_TwoTexScroll(play->state.gfxCtx, 0, (frames * 2) % 512, 512 - (frames % 512) - 1, 128, 128, 1, @@ -1835,7 +1835,7 @@ void DemoEffect_DrawFireBall(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 64, 64, 255, 200, 0, 255); gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 255); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPMatrix(POLY_XLU_DISP++, play->billboardMtx, G_MTX_NOPUSH | G_MTX_MUL | G_MTX_MODELVIEW); @@ -1879,12 +1879,12 @@ void DemoEffect_DrawGodLgt(Actor* thisx, PlayState* play) { gDPSetPrimColor(POLY_XLU_DISP++, 128, 128, this->primXluColor[0], this->primXluColor[1], this->primXluColor[2], 255); gDPSetEnvColor(POLY_XLU_DISP++, this->envXluColor[0], this->envXluColor[1], this->envXluColor[2], 255); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Push(); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, gGoldenGoddessAuraDL); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_8002EBCC(&this->actor, play, 0); Matrix_Pop(); @@ -1922,7 +1922,7 @@ void DemoEffect_DrawLightEffect(Actor* thisx, PlayState* play) { } else { disp = (uintptr_t)gEffFlash1DL; alpha = &this->light.alpha; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 128, this->primXluColor[0], this->primXluColor[1], this->primXluColor[2], *alpha); gDPSetEnvColor(POLY_XLU_DISP++, this->envXluColor[0], this->envXluColor[1], this->envXluColor[2], 255); @@ -1956,7 +1956,7 @@ void DemoEffect_DrawBlueOrb(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 128, 128, 188, 255, 255, this->blueOrb.alpha); gDPSetEnvColor(POLY_XLU_DISP++, 0, 100, 255, 255); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Mult(&play->billboardMtxF, MTXMODE_APPLY); Matrix_RotateZ(this->blueOrb.rotation * (M_PI / 0x8000), MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), @@ -1977,7 +1977,7 @@ void DemoEffect_DrawLgtShower(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 64, 64, 255, 255, 160, this->lgtShower.alpha); gDPSetEnvColor(POLY_XLU_DISP++, 50, 200, 0, 255); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPSegment(POLY_XLU_DISP++, 8, @@ -1997,7 +1997,7 @@ void DemoEffect_DrawLightRing(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 128, 128, 170, 255, 255, this->lightRing.alpha); gDPSetEnvColor(POLY_XLU_DISP++, 0, 100, 255, 255); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), @@ -2021,7 +2021,7 @@ void DemoEffect_DrawTriforceSpot(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (gSaveContext.entranceIndex != 0x0400 || play->csCtx.frames < 885) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->triforceSpot.lightColumnOpacity > 0) { Audio_PlayActorSound2(&this->actor, NA_SE_EV_AURORA - SFX_FLAG); @@ -2047,7 +2047,7 @@ void DemoEffect_DrawTriforceSpot(Actor* thisx, PlayState* play) { if (this->triforceSpot.triforceSpotOpacity < 250) { func_8002ED80(&this->actor, play, 0); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetRenderMode(POLY_XLU_DISP++, G_RM_PASS, G_RM_AA_ZB_XLU_SURF2); Matrix_RotateY(this->triforceSpot.rotation * (M_PI / 0x8000), MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), @@ -2059,7 +2059,7 @@ void DemoEffect_DrawTriforceSpot(Actor* thisx, PlayState* play) { gSPDisplayList(POLY_XLU_DISP++, gTriforceDL); } else { func_8002EBCC(&this->actor, play, 0); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetRenderMode(POLY_OPA_DISP++, G_RM_PASS, G_RM_AA_ZB_OPA_SURF2); Matrix_RotateY(this->triforceSpot.rotation * (M_PI / 0x8000), MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), @@ -2109,7 +2109,7 @@ s32 DemoEffect_DrawTimewarpLimbs(PlayState* play, SkelAnimeCurve* skelCuve, s32 u32 frames = play->gameplayFrames; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 128, 170, 255, 255, 255); gDPSetEnvColor(POLY_XLU_DISP++, this->envXluColor[0], this->envXluColor[1], this->envXluColor[2], 255); gSPSegment(POLY_XLU_DISP++, 8, @@ -2138,7 +2138,7 @@ void DemoEffect_DrawTimeWarp(Actor* thisx, PlayState* play) { if (effectType == DEMO_EFFECT_TIMEWARP_TIMEBLOCK_LARGE || effectType == DEMO_EFFECT_TIMEWARP_TIMEBLOCK_SMALL || Flags_GetEnv(play, 1) || gSaveContext.sceneSetupIndex >= 4 || gSaveContext.entranceIndex == 0x0324) { OPEN_DISPS(gfxCtx); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 25); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 25); Matrix_Scale(2.0f, 2.0f, 2.0f, MTXMODE_APPLY); SkelCurve_Draw(thisx, play, &this->skelCurve, DemoEffect_DrawTimewarpLimbs, NULL, 1, this); CLOSE_DISPS(gfxCtx); diff --git a/soh/src/overlays/actors/ovl_Demo_Ext/z_demo_ext.c b/soh/src/overlays/actors/ovl_Demo_Ext/z_demo_ext.c index 479b12c6f..6ed939848 100644 --- a/soh/src/overlays/actors/ovl_Demo_Ext/z_demo_ext.c +++ b/soh/src/overlays/actors/ovl_Demo_Ext/z_demo_ext.c @@ -199,7 +199,7 @@ void DemoExt_DrawVortex(Actor* thisx, PlayState* play) { Matrix_Translate(kREG(22), kREG(23), kREG(24), MTXMODE_APPLY); MATRIX_TOMTX(mtx); Matrix_Pop(); - func_80093D84(gfxCtx); + Gfx_SetupDL_25Xlu(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, kREG(33) + 128, kREG(25) + 140, kREG(26) + 80, kREG(27) + 140, this->primAlpha); gDPSetEnvColor(POLY_XLU_DISP++, kREG(29) + 90, kREG(30) + 50, kREG(31) + 95, this->envAlpha); diff --git a/soh/src/overlays/actors/ovl_Demo_Geff/z_demo_geff.c b/soh/src/overlays/actors/ovl_Demo_Geff/z_demo_geff.c index bedbcded1..b2829b2d9 100644 --- a/soh/src/overlays/actors/ovl_Demo_Geff/z_demo_geff.c +++ b/soh/src/overlays/actors/ovl_Demo_Geff/z_demo_geff.c @@ -75,7 +75,7 @@ void func_80977EA8(PlayState* play, Gfx* dlist) { OPEN_DISPS(gfxCtx); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Demo_Gj/z_demo_gj.c b/soh/src/overlays/actors/ovl_Demo_Gj/z_demo_gj.c index 6159f3b20..7685b6ae4 100644 --- a/soh/src/overlays/actors/ovl_Demo_Gj/z_demo_gj.c +++ b/soh/src/overlays/actors/ovl_Demo_Gj/z_demo_gj.c @@ -271,7 +271,7 @@ void DemoGj_DrawCommon(DemoGj* this, PlayState* play, Gfx* displayList) { OPEN_DISPS(gfxCtx); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -302,7 +302,7 @@ void DemoGj_DrawRotated(DemoGj* this, PlayState* play, Gfx* displayList) { MATRIX_TOMTX(matrix); Matrix_Pop(); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPMatrix(POLY_OPA_DISP++, matrix, G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, displayList); diff --git a/soh/src/overlays/actors/ovl_Demo_Go/z_demo_go.c b/soh/src/overlays/actors/ovl_Demo_Go/z_demo_go.c index 6828764a7..1e45f14db 100644 --- a/soh/src/overlays/actors/ovl_Demo_Go/z_demo_go.c +++ b/soh/src/overlays/actors/ovl_Demo_Go/z_demo_go.c @@ -333,7 +333,7 @@ void func_8097D29C(DemoGo* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTexture)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(mouthTexture)); diff --git a/soh/src/overlays/actors/ovl_Demo_Gt/z_demo_gt.c b/soh/src/overlays/actors/ovl_Demo_Gt/z_demo_gt.c index 41e5de0f4..4d0e78382 100644 --- a/soh/src/overlays/actors/ovl_Demo_Gt/z_demo_gt.c +++ b/soh/src/overlays/actors/ovl_Demo_Gt/z_demo_gt.c @@ -668,7 +668,7 @@ void DemoGt_Draw1(DemoGt* this, PlayState* play) { Matrix_Pop(); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TwoTexScrollEnvColor(gfxCtx, 0, 0, unk198[0], 0x20, 0x40, 1, 0, unk198[1], 0x20, 0x40, unk178[0], @@ -678,7 +678,7 @@ void DemoGt_Draw1(DemoGt* this, PlayState* play) { unk188[1], unk188[2], 0x80)); gSPMatrix(POLY_OPA_DISP++, spB4, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gTowerCollapseCsExteriorStructureDL); - func_80093D84(gfxCtx); + Gfx_SetupDL_25Xlu(gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 128, 128, 128, 128); gSPSegment( POLY_XLU_DISP++, 0x09, @@ -853,7 +853,7 @@ void DemoGt_Draw2(DemoGt* this, PlayState* play) { OPEN_DISPS(gfxCtx); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); unk198 = this->unk_198; unk178 = this->unk_178; gSPSegment(POLY_OPA_DISP++, 0x08, @@ -1168,7 +1168,7 @@ void DemoGt_Draw3(DemoGt* this, PlayState* play) { OPEN_DISPS(gfxCtx); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gTowerCollapseCsCollapsedStructureOuterDL); @@ -1291,7 +1291,7 @@ void DemoGt_Draw4(DemoGt* this, PlayState* play2) { Matrix_Pop(); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPMatrix(POLY_OPA_DISP++, sp60, (G_MTX_PUSH | G_MTX_LOAD) | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gTowerCollapseCsStandalonePillarDL); gSPPopMatrix(POLY_OPA_DISP++, G_MTX_MODELVIEW); @@ -1410,7 +1410,7 @@ void DemoGt_Draw5(DemoGt* this, PlayState* play) { Matrix_Pop(); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPMatrix(POLY_OPA_DISP++, sp60, G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gTowerCollapseCsStandalonePillarDL); gSPPopMatrix(POLY_OPA_DISP++, G_MTX_MODELVIEW); @@ -1502,7 +1502,7 @@ void DemoGt_Draw6(DemoGt* this, PlayState* play) { Matrix_Pop(); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPMatrix(POLY_OPA_DISP++, sp64, G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gTowerCollapseCsStandalonePillarDL); gSPPopMatrix(POLY_OPA_DISP++, G_MTX_MODELVIEW); @@ -1594,7 +1594,7 @@ void DemoGt_Draw7(DemoGt* this, PlayState* play) { Matrix_Pop(); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPMatrix(POLY_OPA_DISP++, sp5C, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gTowerCollapseCsWalkwayDL); @@ -1685,7 +1685,7 @@ void DemoGt_Draw8(DemoGt* this, PlayState* play) { Matrix_Pop(); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPMatrix(POLY_OPA_DISP++, sp5C, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gTowerCollapseCsAlternativeWalkwayDL); diff --git a/soh/src/overlays/actors/ovl_Demo_Ik/z_demo_ik.c b/soh/src/overlays/actors/ovl_Demo_Ik/z_demo_ik.c index 13377c331..db9c80fe6 100644 --- a/soh/src/overlays/actors/ovl_Demo_Ik/z_demo_ik.c +++ b/soh/src/overlays/actors/ovl_Demo_Ik/z_demo_ik.c @@ -284,8 +284,8 @@ void DemoIk_Type1Draw(DemoIk* this, PlayState* play) { OPEN_DISPS(gfxCtx); func_8002EBCC(&this->actor, play, 0); - func_80093D18(gfxCtx); - func_80093D84(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); + Gfx_SetupDL_25Xlu(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, DemoIk_SetColors(gfxCtx, 245, 225, 155, 30, 30, 0)); gSPSegment(POLY_OPA_DISP++, 0x09, DemoIk_SetColors(gfxCtx, 255, 40, 0, 40, 0, 0)); gSPSegment(POLY_OPA_DISP++, 0x0A, DemoIk_SetColors(gfxCtx, 255, 255, 255, 20, 40, 30)); @@ -452,8 +452,8 @@ void DemoIk_Type2Draw(DemoIk* this, PlayState* play) { OPEN_DISPS(gfxCtx); func_8002EBCC(&this->actor, play, 0); - func_80093D18(gfxCtx); - func_80093D84(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); + Gfx_SetupDL_25Xlu(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, DemoIk_SetColors(gfxCtx, 245, 225, 155, 30, 30, 0)); gSPSegment(POLY_OPA_DISP++, 0x09, DemoIk_SetColors(gfxCtx, 255, 40, 0, 40, 0, 0)); gSPSegment(POLY_OPA_DISP++, 0x0A, DemoIk_SetColors(gfxCtx, 255, 255, 255, 20, 40, 30)); diff --git a/soh/src/overlays/actors/ovl_Demo_Im/z_demo_im.c b/soh/src/overlays/actors/ovl_Demo_Im/z_demo_im.c index dff65b42f..aaed8a438 100644 --- a/soh/src/overlays/actors/ovl_Demo_Im/z_demo_im.c +++ b/soh/src/overlays/actors/ovl_Demo_Im/z_demo_im.c @@ -526,7 +526,7 @@ void DemoIm_DrawTranslucent(DemoIm* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTex)); gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTex)); @@ -1221,7 +1221,7 @@ void DemoIm_DrawSolid(DemoIm* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTexture)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTexture)); diff --git a/soh/src/overlays/actors/ovl_Demo_Kankyo/z_demo_kankyo.c b/soh/src/overlays/actors/ovl_Demo_Kankyo/z_demo_kankyo.c index e9b557f1e..9e05d9e41 100644 --- a/soh/src/overlays/actors/ovl_Demo_Kankyo/z_demo_kankyo.c +++ b/soh/src/overlays/actors/ovl_Demo_Kankyo/z_demo_kankyo.c @@ -624,7 +624,7 @@ void DemoKankyo_DrawRain(Actor* thisx, PlayState* play) { Matrix_Translate(translateX, translateY, translateZ, MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x14); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x14); gSPDisplayList(POLY_XLU_DISP++, object_efc_star_field_DL_000080); FrameInterpolation_RecordCloseChild(); @@ -639,7 +639,7 @@ void DemoKankyo_DrawRock(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Translate(this->actor.world.pos.x, this->actor.world.pos.y, this->actor.world.pos.z, MTXMODE_NEW); Matrix_RotateX(DEG_TO_RAD(this->unk_150[0].unk_C.x), MTXMODE_APPLY); Matrix_RotateY(DEG_TO_RAD(this->unk_150[0].unk_C.y), MTXMODE_APPLY); @@ -684,7 +684,7 @@ void DemoKankyo_DrawClouds(Actor* thisx, PlayState* play) { G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(gDust5Tex)); - func_80094C50(play->state.gfxCtx); + Gfx_SetupDL_61Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, SEG_ADDR(1, 0), G_MTX_NOPUSH | G_MTX_MUL | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, gEffDustDL); @@ -701,7 +701,7 @@ void DemoKankyo_DrawDoorOfTime(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Translate(-this->unk_150[0].unk_18, 0.0f, 0.0f, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -721,7 +721,7 @@ void DemoKankyo_DrawLightPlane(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (play->csCtx.state == CS_STATE_IDLE || gSaveContext.sceneSetupIndex >= 4) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 0, play->state.frames & 0x7F, 64, 32)); @@ -894,7 +894,7 @@ void DemoKankyo_DrawWarpSparkles(Actor* thisx, PlayState* play) { gDPSetEnvColor(POLY_XLU_DISP++, sWarpSparkleEnvColors[respawnData].r, sWarpSparkleEnvColors[respawnData].g, sWarpSparkleEnvColors[respawnData].b, 255); } - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Mult(&play->billboardMtxF, MTXMODE_APPLY); Matrix_RotateZ(DEG_TO_RAD(this->unk_150[i].unk_24), MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), @@ -1000,7 +1000,7 @@ void DemoKankyo_DrawSparkles(Actor* thisx, PlayState* play) { gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, 255, 255, 255, 255); gDPSetEnvColor(POLY_XLU_DISP++, sSparkleEnvColors[3].r, sSparkleEnvColors[3].g, sSparkleEnvColors[3].b, 255); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Mult(&play->billboardMtxF, MTXMODE_APPLY); Matrix_RotateZ(DEG_TO_RAD(this->unk_150[i].unk_24), MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), diff --git a/soh/src/overlays/actors/ovl_Demo_Kekkai/z_demo_kekkai.c b/soh/src/overlays/actors/ovl_Demo_Kekkai/z_demo_kekkai.c index 764529bf7..e6ad6e143 100644 --- a/soh/src/overlays/actors/ovl_Demo_Kekkai/z_demo_kekkai.c +++ b/soh/src/overlays/actors/ovl_Demo_Kekkai/z_demo_kekkai.c @@ -356,7 +356,7 @@ void DemoKekkai_DrawTrialBarrier(Actor* thisx, PlayState* play2) { } colorIndex = (this->actor.params - 1) * 6; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Push(); Matrix_Translate(0.0f, 1200.0f, 0.0f, MTXMODE_APPLY); Matrix_Scale(this->orbScale, this->orbScale, this->orbScale, MTXMODE_APPLY); @@ -395,7 +395,7 @@ void DemoKekkai_DrawTowerBarrier(Actor* thisx, PlayState* play) { scroll = (s32)this->barrierScroll & 0xFFFF; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gDPSetPrimColor(POLY_XLU_DISP++, 0x00, 0x80, 255, 170, 255, 255); diff --git a/soh/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c b/soh/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c index ec9c2b812..83c9776c6 100644 --- a/soh/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c +++ b/soh/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c @@ -466,7 +466,7 @@ void DemoSa_DrawXlu(DemoSa* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sp78)); gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(sp78)); @@ -804,7 +804,7 @@ void DemoSa_DrawOpa(DemoSa* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTex)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTex)); diff --git a/soh/src/overlays/actors/ovl_Demo_Shd/z_demo_shd.c b/soh/src/overlays/actors/ovl_Demo_Shd/z_demo_shd.c index ad4d40deb..378fc3e87 100644 --- a/soh/src/overlays/actors/ovl_Demo_Shd/z_demo_shd.c +++ b/soh/src/overlays/actors/ovl_Demo_Shd/z_demo_shd.c @@ -104,7 +104,7 @@ void DemoShd_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Demo_Tre_Lgt/z_demo_tre_lgt.c b/soh/src/overlays/actors/ovl_Demo_Tre_Lgt/z_demo_tre_lgt.c index 12265a6af..555fdbea9 100644 --- a/soh/src/overlays/actors/ovl_Demo_Tre_Lgt/z_demo_tre_lgt.c +++ b/soh/src/overlays/actors/ovl_Demo_Tre_Lgt/z_demo_tre_lgt.c @@ -161,7 +161,7 @@ void DemoTreLgt_Draw(Actor* thisx, PlayState* play) { return; } - func_80093D84(gfxCtx); + Gfx_SetupDL_25Xlu(gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 200, 255, 0, 0); SkelCurve_Draw(&this->actor, play, &this->skelCurve, DemoTreLgt_PostLimbDraw, NULL, 1, thisx); diff --git a/soh/src/overlays/actors/ovl_Door_Ana/z_door_ana.c b/soh/src/overlays/actors/ovl_Door_Ana/z_door_ana.c index 7d3dfa9da..f8c3a9a91 100644 --- a/soh/src/overlays/actors/ovl_Door_Ana/z_door_ana.c +++ b/soh/src/overlays/actors/ovl_Door_Ana/z_door_ana.c @@ -183,7 +183,7 @@ void DoorAna_Update(Actor* thisx, PlayState* play) { void DoorAna_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, gGrottoDL); diff --git a/soh/src/overlays/actors/ovl_Door_Gerudo/z_door_gerudo.c b/soh/src/overlays/actors/ovl_Door_Gerudo/z_door_gerudo.c index c288863e5..c5f05341a 100644 --- a/soh/src/overlays/actors/ovl_Door_Gerudo/z_door_gerudo.c +++ b/soh/src/overlays/actors/ovl_Door_Gerudo/z_door_gerudo.c @@ -146,7 +146,7 @@ void DoorGerudo_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Door_Killer/z_door_killer.c b/soh/src/overlays/actors/ovl_Door_Killer/z_door_killer.c index 93b12f27a..0cd7e97eb 100644 --- a/soh/src/overlays/actors/ovl_Door_Killer/z_door_killer.c +++ b/soh/src/overlays/actors/ovl_Door_Killer/z_door_killer.c @@ -527,7 +527,7 @@ void DoorKiller_SetTexture(Actor* thisx, PlayState* play) { void DoorKiller_DrawDoor(Actor* thisx, PlayState* play) { DoorKiller* this = (DoorKiller*)thisx; - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); DoorKiller_SetTexture(&this->actor, play); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, NULL, NULL); diff --git a/soh/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c b/soh/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c index 289f700c1..aab96055d 100644 --- a/soh/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c +++ b/soh/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c @@ -709,14 +709,14 @@ void DoorShutter_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->unk_16C == 3) { POLY_OPA_DISP = func_80997838(play, this, POLY_OPA_DISP); if (this->unk_170 != 0.0f) { f32 sp58 = (this->unk_166 * 0.01f) * this->unk_170; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255.0f * sp58); Matrix_Translate(0, 0, sp70->translateZ, MTXMODE_APPLY); Matrix_Scale(sp58, sp58, sp58, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_Door_Warp1/z_door_warp1.c b/soh/src/overlays/actors/ovl_Door_Warp1/z_door_warp1.c index acc093e3f..c7ea77f38 100644 --- a/soh/src/overlays/actors/ovl_Door_Warp1/z_door_warp1.c +++ b/soh/src/overlays/actors/ovl_Door_Warp1/z_door_warp1.c @@ -1009,7 +1009,7 @@ void DoorWarp1_DrawBlueCrystal(DoorWarp1* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0xFF, 0xFF, 200, 255, 255, (u8)this->crystalAlpha); gDPSetEnvColor(POLY_XLU_DISP++, 0, 100, 255, (u8)this->crystalAlpha); @@ -1032,7 +1032,7 @@ void DoorWarp1_DrawPurpleCrystal(DoorWarp1* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); func_8002EB44(&this->actor.world.pos, &eye, &eye, play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, (u8)this->crystalAlpha); @@ -1065,7 +1065,7 @@ void DoorWarp1_DrawWarp(DoorWarp1* this, PlayState* play) { if (this->actor.params == WARP_DESTINATION) { this->unk_19C -= (s16)(temp_f0 * 2.0f); } - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); switch (this->actor.params) { case WARP_YELLOW: diff --git a/soh/src/overlays/actors/ovl_Efc_Erupc/z_efc_erupc.c b/soh/src/overlays/actors/ovl_Efc_Erupc/z_efc_erupc.c index ed53284e7..7c0225851 100644 --- a/soh/src/overlays/actors/ovl_Efc_Erupc/z_efc_erupc.c +++ b/soh/src/overlays/actors/ovl_Efc_Erupc/z_efc_erupc.c @@ -118,7 +118,7 @@ void EfcErupc_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->unk_14C * 1, this->unk_14E * -4, 32, 64, 1, @@ -171,7 +171,7 @@ void EfcErupc_DrawParticles(EfcErupcParticles* particles, PlayState* play) { FrameInterpolation_RecordOpenChild(particles, particles->epoch); if (particles->isActive) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, object_efc_erupc_DL_002760); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, particles->color.r, particles->color.g, particles->color.b, particles->alpha); diff --git a/soh/src/overlays/actors/ovl_Eff_Dust/z_eff_dust.c b/soh/src/overlays/actors/ovl_Eff_Dust/z_eff_dust.c index 5f08ee401..7740419e5 100644 --- a/soh/src/overlays/actors/ovl_Eff_Dust/z_eff_dust.c +++ b/soh/src/overlays/actors/ovl_Eff_Dust/z_eff_dust.c @@ -272,7 +272,7 @@ void EffDust_DrawFunc_8099E4F4(Actor* thisx, PlayState* play2) { OPEN_DISPS(gfxCtx); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gDPPipeSync(POLY_XLU_DISP++); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 128, 128, 128, 255); @@ -322,7 +322,7 @@ void EffDust_DrawFunc_8099E784(Actor* thisx, PlayState* play2) { OPEN_DISPS(gfxCtx); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gDPPipeSync(POLY_XLU_DISP++); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, 255); diff --git a/soh/src/overlays/actors/ovl_Elf_Msg/z_elf_msg.c b/soh/src/overlays/actors/ovl_Elf_Msg/z_elf_msg.c index 8ea458d5f..cd1a7822a 100644 --- a/soh/src/overlays/actors/ovl_Elf_Msg/z_elf_msg.c +++ b/soh/src/overlays/actors/ovl_Elf_Msg/z_elf_msg.c @@ -181,7 +181,7 @@ void ElfMsg_Draw(Actor* thisx, PlayState* play) return; } - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (thisx->params & 0x8000) { gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 100, 100, R_NAVI_MSG_REGION_ALPHA); } else { diff --git a/soh/src/overlays/actors/ovl_Elf_Msg2/z_elf_msg2.c b/soh/src/overlays/actors/ovl_Elf_Msg2/z_elf_msg2.c index 64c30e7d2..9988e3822 100644 --- a/soh/src/overlays/actors/ovl_Elf_Msg2/z_elf_msg2.c +++ b/soh/src/overlays/actors/ovl_Elf_Msg2/z_elf_msg2.c @@ -160,7 +160,7 @@ void ElfMsg2_Draw(Actor* thisx, PlayState* play) { return; } - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 100, 100, 255, R_NAVI_MSG_REGION_ALPHA); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_En_Am/z_en_am.c b/soh/src/overlays/actors/ovl_En_Am/z_en_am.c index d5bdab432..c4477e4e5 100644 --- a/soh/src/overlays/actors/ovl_En_Am/z_en_am.c +++ b/soh/src/overlays/actors/ovl_En_Am/z_en_am.c @@ -956,7 +956,7 @@ void EnAm_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, this->textureBlend); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, NULL, EnAm_PostLimbDraw, this); diff --git a/soh/src/overlays/actors/ovl_En_Ani/z_en_ani.c b/soh/src/overlays/actors/ovl_En_Ani/z_en_ani.c index f95c5de80..f9d76b60e 100644 --- a/soh/src/overlays/actors/ovl_En_Ani/z_en_ani.c +++ b/soh/src/overlays/actors/ovl_En_Ani/z_en_ani.c @@ -332,7 +332,7 @@ void EnAni_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeIndex])); diff --git a/soh/src/overlays/actors/ovl_En_Anubice/z_en_anubice.c b/soh/src/overlays/actors/ovl_En_Anubice/z_en_anubice.c index fc07ed0cb..13e451e37 100644 --- a/soh/src/overlays/actors/ovl_En_Anubice/z_en_anubice.c +++ b/soh/src/overlays/actors/ovl_En_Anubice/z_en_anubice.c @@ -493,7 +493,7 @@ void EnAnubice_PostLimbDraw(struct PlayState* play, s32 limbIndex, Gfx** dList, void EnAnubice_Draw(Actor* thisx, PlayState* play) { EnAnubice* this = (EnAnubice*)thisx; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnAnubice_OverrideLimbDraw, EnAnubice_PostLimbDraw, this); } diff --git a/soh/src/overlays/actors/ovl_En_Anubice_Fire/z_en_anubice_fire.c b/soh/src/overlays/actors/ovl_En_Anubice_Fire/z_en_anubice_fire.c index 8659b80a3..e262d1cdb 100644 --- a/soh/src/overlays/actors/ovl_En_Anubice_Fire/z_en_anubice_fire.c +++ b/soh/src/overlays/actors/ovl_En_Anubice_Fire/z_en_anubice_fire.c @@ -223,7 +223,7 @@ void EnAnubiceFire_Draw(Actor* thisx, PlayState* play) { s32 i; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 0, 255); gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 0); diff --git a/soh/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c b/soh/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c index c582d8b95..5e77320f0 100644 --- a/soh/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c +++ b/soh/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c @@ -486,7 +486,7 @@ void EnArrow_Draw(Actor* thisx, PlayState* play) { f32 scale; if (this->actor.params <= ARROW_0E) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawLod(play, this->skelAnime.skeleton, this->skelAnime.jointTable, NULL, NULL, this, (this->actor.projectedPos.z < MREG(95)) ? 0 : 1); } else if (this->actor.speedXZ != 0.0f) { @@ -494,7 +494,7 @@ void EnArrow_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093C14(play->state.gfxCtx); + Gfx_SetupDL_25Xlu2(play->state.gfxCtx); if (this->actor.params == ARROW_SEED) { gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, 255); diff --git a/soh/src/overlays/actors/ovl_En_Attack_Niw/z_en_attack_niw.c b/soh/src/overlays/actors/ovl_En_Attack_Niw/z_en_attack_niw.c index d299eadba..a73c542c6 100644 --- a/soh/src/overlays/actors/ovl_En_Attack_Niw/z_en_attack_niw.c +++ b/soh/src/overlays/actors/ovl_En_Attack_Niw/z_en_attack_niw.c @@ -398,7 +398,7 @@ s32 func_809B5F98(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s void EnAttackNiw_Draw(Actor* thisx, PlayState* play) { EnAttackNiw* this = (EnAttackNiw*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, func_809B5F98, NULL, this); } diff --git a/soh/src/overlays/actors/ovl_En_Ba/z_en_ba.c b/soh/src/overlays/actors/ovl_En_Ba/z_en_ba.c index dc1ec1a4f..f2a6fffa0 100644 --- a/soh/src/overlays/actors/ovl_En_Ba/z_en_ba.c +++ b/soh/src/overlays/actors/ovl_En_Ba/z_en_ba.c @@ -483,7 +483,7 @@ void EnBa_Draw(Actor* thisx, PlayState* play) { Vec3f unused = { 0.0f, 0.0f, 448.0f }; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->actor.params < EN_BA_DEAD_BLOB) { Matrix_Push(); gSPSegment(POLY_OPA_DISP++, 0x0C, mtx); diff --git a/soh/src/overlays/actors/ovl_En_Bb/z_en_bb.c b/soh/src/overlays/actors/ovl_En_Bb/z_en_bb.c index f29b1e9f5..cccf27df4 100644 --- a/soh/src/overlays/actors/ovl_En_Bb/z_en_bb.c +++ b/soh/src/overlays/actors/ovl_En_Bb/z_en_bb.c @@ -1299,7 +1299,7 @@ void EnBb_Draw(Actor* thisx, PlayState* play) { blureBase2.z = this->maxSpeed * 80.0f; if (this->moveMode != BBMOVE_HIDDEN) { if (this->actor.params <= ENBB_BLUE) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, NULL, EnBb_PostLimbDraw, this); @@ -1333,7 +1333,7 @@ void EnBb_Draw(Actor* thisx, PlayState* play) { Matrix_Translate(0.0f, -40.0f, 0.0f, MTXMODE_APPLY); } if (this->actor.params != ENBB_WHITE) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, ((play->gameplayFrames + (this->flameScrollMod * 10)) * diff --git a/soh/src/overlays/actors/ovl_En_Bdfire/z_en_bdfire.c b/soh/src/overlays/actors/ovl_En_Bdfire/z_en_bdfire.c index d902e4fed..b9d4ef0a9 100644 --- a/soh/src/overlays/actors/ovl_En_Bdfire/z_en_bdfire.c +++ b/soh/src/overlays/actors/ovl_En_Bdfire/z_en_bdfire.c @@ -207,8 +207,8 @@ void EnBdfire_DrawFire(EnBdfire* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); temp = this->unk_156 & 7; Matrix_ReplaceRotation(&play->billboardMtxF); - func_80094BC4(play->state.gfxCtx); - POLY_XLU_DISP = func_80094968(POLY_XLU_DISP); + Gfx_SetupDL_60NoCDXlu(play->state.gfxCtx); + POLY_XLU_DISP = Gfx_SetupDL_20NoCD(POLY_XLU_DISP); gDPSetCombineLERP(POLY_XLU_DISP++, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT); diff --git a/soh/src/overlays/actors/ovl_En_Bigokuta/z_en_bigokuta.c b/soh/src/overlays/actors/ovl_En_Bigokuta/z_en_bigokuta.c index dcea1c0b8..24b2ff9f3 100644 --- a/soh/src/overlays/actors/ovl_En_Bigokuta/z_en_bigokuta.c +++ b/soh/src/overlays/actors/ovl_En_Bigokuta/z_en_bigokuta.c @@ -873,7 +873,7 @@ void EnBigokuta_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if ((this->actionFunc != func_809BE26C) || (this->unk_196 != 0) || (this->unk_198 != 0)) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x0C, &D_80116280[2]); gDPSetEnvColor(POLY_OPA_DISP++, 255, 255, 255, 255); if (this->unk_196 & 1) { @@ -892,7 +892,7 @@ void EnBigokuta_Draw(Actor* thisx, PlayState* play) { SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnBigokuta_OverrideLimbDraw, NULL, this); } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x0C, D_80116280); gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, (this->actor.scale.y * (255 / 0.033f))); POLY_XLU_DISP = SkelAnime_DrawFlex(play, this->skelAnime.skeleton, this->skelAnime.jointTable, diff --git a/soh/src/overlays/actors/ovl_En_Bili/z_en_bili.c b/soh/src/overlays/actors/ovl_En_Bili/z_en_bili.c index cb6770c96..d2ce6686e 100644 --- a/soh/src/overlays/actors/ovl_En_Bili/z_en_bili.c +++ b/soh/src/overlays/actors/ovl_En_Bili/z_en_bili.c @@ -753,7 +753,7 @@ void EnBili_Draw(Actor* thisx, PlayState* play) { EnBili* this = (EnBili*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); this->tentaclesTexIndex = CLAMP_MAX(this->tentaclesTexIndex, 7); diff --git a/soh/src/overlays/actors/ovl_En_Blkobj/z_en_blkobj.c b/soh/src/overlays/actors/ovl_En_Blkobj/z_en_blkobj.c index c58e756ae..ca2e09c45 100644 --- a/soh/src/overlays/actors/ovl_En_Blkobj/z_en_blkobj.c +++ b/soh/src/overlays/actors/ovl_En_Blkobj/z_en_blkobj.c @@ -154,7 +154,7 @@ void EnBlkobj_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gameplayFrames = play->gameplayFrames % 128; diff --git a/soh/src/overlays/actors/ovl_En_Bom/z_en_bom.c b/soh/src/overlays/actors/ovl_En_Bom/z_en_bom.c index 49aa1b46b..d71433a35 100644 --- a/soh/src/overlays/actors/ovl_En_Bom/z_en_bom.c +++ b/soh/src/overlays/actors/ovl_En_Bom/z_en_bom.c @@ -366,7 +366,7 @@ void EnBom_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (thisx->params == BOMB_BODY) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_ReplaceRotation(&play->billboardMtxF); func_8002EBCC(thisx, play, 0); diff --git a/soh/src/overlays/actors/ovl_En_Bom_Bowl_Man/z_en_bom_bowl_man.c b/soh/src/overlays/actors/ovl_En_Bom_Bowl_Man/z_en_bom_bowl_man.c index 90d3f704f..4016b2120 100644 --- a/soh/src/overlays/actors/ovl_En_Bom_Bowl_Man/z_en_bom_bowl_man.c +++ b/soh/src/overlays/actors/ovl_En_Bom_Bowl_Man/z_en_bom_bowl_man.c @@ -563,7 +563,7 @@ void EnBomBowlMan_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeTextureIndex])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnBomBowlMan_OverrideLimbDraw, NULL, this); diff --git a/soh/src/overlays/actors/ovl_En_Bom_Chu/z_en_bom_chu.c b/soh/src/overlays/actors/ovl_En_Bom_Chu/z_en_bom_chu.c index bb4a1dbdd..0f98d6079 100644 --- a/soh/src/overlays/actors/ovl_En_Bom_Chu/z_en_bom_chu.c +++ b/soh/src/overlays/actors/ovl_En_Bom_Chu/z_en_bom_chu.c @@ -495,7 +495,7 @@ void EnBomChu_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_8002EBCC(&this->actor, play, 0); if (this->timer >= 40) { diff --git a/soh/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c b/soh/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c index 2f564d8e6..7be69c154 100644 --- a/soh/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c +++ b/soh/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c @@ -484,7 +484,7 @@ void EnBombf_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (thisx->params <= BOMBFLOWER_BODY) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (thisx->params != BOMBFLOWER_BODY) { gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), diff --git a/soh/src/overlays/actors/ovl_En_Boom/z_en_boom.c b/soh/src/overlays/actors/ovl_En_Boom/z_en_boom.c index d1eafd600..7342c01b3 100644 --- a/soh/src/overlays/actors/ovl_En_Boom/z_en_boom.c +++ b/soh/src/overlays/actors/ovl_En_Boom/z_en_boom.c @@ -269,7 +269,7 @@ void EnBoom_Draw(Actor* thisx, PlayState* play) { EffectBlure_AddVertex(Effect_GetByIndex(this->effectIndex), &vec1, &vec2); } - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_RotateY((this->activeTimer * 12000) * (M_PI / 0x8000), MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), diff --git a/soh/src/overlays/actors/ovl_En_Box/z_en_box.c b/soh/src/overlays/actors/ovl_En_Box/z_en_box.c index 73a1dc2a7..e99d4b036 100644 --- a/soh/src/overlays/actors/ovl_En_Box/z_en_box.c +++ b/soh/src/overlays/actors/ovl_En_Box/z_en_box.c @@ -846,12 +846,12 @@ void EnBox_Draw(Actor* thisx, PlayState* play) { gDPPipeSync(POLY_OPA_DISP++); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255); gSPSegment(POLY_OPA_DISP++, 0x08, EnBox_EmptyDList(play->state.gfxCtx)); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); POLY_OPA_DISP = SkelAnime_Draw(play, this->skelanime.skeleton, this->skelanime.jointTable, NULL, EnBox_PostLimbDraw, this, POLY_OPA_DISP); } else if (this->alpha != 0) { gDPPipeSync(POLY_XLU_DISP++); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->alpha); if (this->type == ENBOX_TYPE_4 || this->type == ENBOX_TYPE_6) { gSPSegment(POLY_XLU_DISP++, 0x08, func_809CA518(play->state.gfxCtx)); diff --git a/soh/src/overlays/actors/ovl_En_Brob/z_en_brob.c b/soh/src/overlays/actors/ovl_En_Brob/z_en_brob.c index 1ef081fd8..a7c2d119c 100644 --- a/soh/src/overlays/actors/ovl_En_Brob/z_en_brob.c +++ b/soh/src/overlays/actors/ovl_En_Brob/z_en_brob.c @@ -322,7 +322,7 @@ void EnBrob_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot void EnBrob_Draw(Actor* thisx, PlayState* play) { EnBrob* this = (EnBrob*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Translate(0.0f, this->unk_1AE, 0.0f, MTXMODE_APPLY); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, EnBrob_PostLimbDraw, this); diff --git a/soh/src/overlays/actors/ovl_En_Bubble/z_en_bubble.c b/soh/src/overlays/actors/ovl_En_Bubble/z_en_bubble.c index fc9546a26..be4db9d4d 100644 --- a/soh/src/overlays/actors/ovl_En_Bubble/z_en_bubble.c +++ b/soh/src/overlays/actors/ovl_En_Bubble/z_en_bubble.c @@ -413,7 +413,7 @@ void EnBubble_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->actionFunc != EnBubble_Disappear) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Math_SmoothStepToF(&this->graphicRotSpeed, 16.0f, 0.2f, 1000.0f, 0.0f); Math_SmoothStepToF(&this->graphicEccentricity, 0.08f, 0.2f, 1000.0f, 0.0f); Matrix_ReplaceRotation(&play->billboardMtxF); diff --git a/soh/src/overlays/actors/ovl_En_Butte/z_en_butte.c b/soh/src/overlays/actors/ovl_En_Butte/z_en_butte.c index b3039f848..99a31eb0b 100644 --- a/soh/src/overlays/actors/ovl_En_Butte/z_en_butte.c +++ b/soh/src/overlays/actors/ovl_En_Butte/z_en_butte.c @@ -117,7 +117,7 @@ void EnButte_DrawTransformationEffect(EnButte* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093C14(play->state.gfxCtx); + Gfx_SetupDL_25Xlu2(play->state.gfxCtx); alpha = Math_SinS(sTransformationEffectAlpha) * 250; alpha = CLAMP(alpha, 0, 255); @@ -424,7 +424,7 @@ void EnButte_Draw(Actor* thisx, PlayState* play) { EnButte* this = (EnButte*)thisx; if (this->drawSkelAnime) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, NULL, NULL, NULL); Collider_UpdateSpheres(0, &this->collider); } diff --git a/soh/src/overlays/actors/ovl_En_Bw/z_en_bw.c b/soh/src/overlays/actors/ovl_En_Bw/z_en_bw.c index e8e9d792e..acf4727b4 100644 --- a/soh/src/overlays/actors/ovl_En_Bw/z_en_bw.c +++ b/soh/src/overlays/actors/ovl_En_Bw/z_en_bw.c @@ -850,13 +850,13 @@ void EnBw_Draw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); if (this->color1.a == 0xFF) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, this->color1.r, this->color1.g, this->color1.b, this->color1.a); gSPSegment(POLY_OPA_DISP++, 0x08, &D_80116280[2]); POLY_OPA_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnBw_OverrideLimbDraw, NULL, this, POLY_OPA_DISP); } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPPipeSync(POLY_XLU_DISP++); gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 0, 0, 0, this->color1.a); gDPSetEnvColor(POLY_XLU_DISP++, this->color1.r, this->color1.g, this->color1.b, this->color1.a); @@ -878,7 +878,7 @@ void EnBw_Draw(Actor* thisx, PlayState* play2) { Matrix_Translate(thisx->world.pos.x, thisx->world.pos.y + ((thisx->scale.y - 0.013f) * 1000.0f), thisx->world.pos.z, MTXMODE_NEW); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 0); gSPSegment(POLY_XLU_DISP++, 0x08, diff --git a/soh/src/overlays/actors/ovl_En_Bx/z_en_bx.c b/soh/src/overlays/actors/ovl_En_Bx/z_en_bx.c index b6969d743..e83969c5f 100644 --- a/soh/src/overlays/actors/ovl_En_Bx/z_en_bx.c +++ b/soh/src/overlays/actors/ovl_En_Bx/z_en_bx.c @@ -210,7 +210,7 @@ void EnBx_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x0C, mtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_809D2560[this->actor.params & 0x7F])); diff --git a/soh/src/overlays/actors/ovl_En_Clear_Tag/z_en_clear_tag.c b/soh/src/overlays/actors/ovl_En_Clear_Tag/z_en_clear_tag.c index f3923dbba..50208e299 100644 --- a/soh/src/overlays/actors/ovl_En_Clear_Tag/z_en_clear_tag.c +++ b/soh/src/overlays/actors/ovl_En_Clear_Tag/z_en_clear_tag.c @@ -691,7 +691,7 @@ void EnClearTag_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->drawMode != CLEAR_TAG_DRAW_MODE_EFFECT) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->state >= CLEAR_TAG_STATE_LASER) { // Draw Arwing lasers. @@ -708,7 +708,7 @@ void EnClearTag_Draw(Actor* thisx, PlayState* play) { gSPDisplayList(POLY_XLU_DISP++, gArwingLaserDL); } else { // Draw the Arwing itself. - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 255, 255, 255); if (this->crashingTimer != 0) { f32 xRotation; @@ -900,8 +900,8 @@ void EnClearTag_DrawEffects(PlayState* play) { EnClearTagEffect* firstEffect = effect; OPEN_DISPS(gfxCtx); - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); // Draw all Debris effects. for (i = 0; i < CLEAR_TAG_EFFECT_MAX_COUNT; i++, effect++) { diff --git a/soh/src/overlays/actors/ovl_En_Cow/z_en_cow.c b/soh/src/overlays/actors/ovl_En_Cow/z_en_cow.c index d7ab361bb..d31864502 100644 --- a/soh/src/overlays/actors/ovl_En_Cow/z_en_cow.c +++ b/soh/src/overlays/actors/ovl_En_Cow/z_en_cow.c @@ -439,7 +439,7 @@ void EnCow_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void EnCow_Draw(Actor* thisx, PlayState* play) { EnCow* this = (EnCow*)thisx; - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnCow_OverrideLimbDraw, EnCow_PostLimbDraw, this); } @@ -447,7 +447,7 @@ void EnCow_Draw(Actor* thisx, PlayState* play) { void func_809E0070(Actor* thisx, PlayState* play) { EnCow* this = (EnCow*)thisx; - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, NULL, this); } diff --git a/soh/src/overlays/actors/ovl_En_Crow/z_en_crow.c b/soh/src/overlays/actors/ovl_En_Crow/z_en_crow.c index e7160ca15..d021651b8 100644 --- a/soh/src/overlays/actors/ovl_En_Crow/z_en_crow.c +++ b/soh/src/overlays/actors/ovl_En_Crow/z_en_crow.c @@ -505,7 +505,7 @@ void EnCrow_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot void EnCrow_Draw(Actor* thisx, PlayState* play) { EnCrow* this = (EnCrow*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnCrow_OverrideLimbDraw, EnCrow_PostLimbDraw, this); } diff --git a/soh/src/overlays/actors/ovl_En_Cs/z_en_cs.c b/soh/src/overlays/actors/ovl_En_Cs/z_en_cs.c index 4e00d4f73..fca4d24fe 100644 --- a/soh/src/overlays/actors/ovl_En_Cs/z_en_cs.c +++ b/soh/src/overlays/actors/ovl_En_Cs/z_en_cs.c @@ -464,7 +464,7 @@ void EnCs_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeIndex])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, diff --git a/soh/src/overlays/actors/ovl_En_Daiku/z_en_daiku.c b/soh/src/overlays/actors/ovl_En_Daiku/z_en_daiku.c index 51125b394..638b47580 100644 --- a/soh/src/overlays/actors/ovl_En_Daiku/z_en_daiku.c +++ b/soh/src/overlays/actors/ovl_En_Daiku/z_en_daiku.c @@ -588,7 +588,7 @@ void EnDaiku_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if ((thisx->params & 3) == 0) { gDPSetEnvColor(POLY_OPA_DISP++, 170, 10, 70, 255); diff --git a/soh/src/overlays/actors/ovl_En_Daiku_Kakariko/z_en_daiku_kakariko.c b/soh/src/overlays/actors/ovl_En_Daiku_Kakariko/z_en_daiku_kakariko.c index 8d5c6eee0..ecd64c925 100644 --- a/soh/src/overlays/actors/ovl_En_Daiku_Kakariko/z_en_daiku_kakariko.c +++ b/soh/src/overlays/actors/ovl_En_Daiku_Kakariko/z_en_daiku_kakariko.c @@ -545,7 +545,7 @@ void EnDaikuKakariko_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if ((thisx->params & 3) == CARPENTER_ICHIRO) { gDPSetEnvColor(POLY_OPA_DISP++, 170, 10, 70, 255); diff --git a/soh/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c b/soh/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c index 1ee5e144c..5fa65f49c 100644 --- a/soh/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c +++ b/soh/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c @@ -1263,7 +1263,7 @@ void EnDekubaba_DrawBaseShadow(EnDekubaba* this, PlayState* play) { f32 horizontalScale; OPEN_DISPS(play->state.gfxCtx); - func_80094044(play->state.gfxCtx); + Gfx_SetupDL_44Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 0, 0, 0, 255); @@ -1291,7 +1291,7 @@ void EnDekubaba_Draw(Actor* thisx, PlayState* play) { f32 scale; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->actionFunc != EnDekubaba_DeadStickDrop) { SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, NULL, diff --git a/soh/src/overlays/actors/ovl_En_Dh/z_en_dh.c b/soh/src/overlays/actors/ovl_En_Dh/z_en_dh.c index c27374ee1..b41e9cdff 100644 --- a/soh/src/overlays/actors/ovl_En_Dh/z_en_dh.c +++ b/soh/src/overlays/actors/ovl_En_Dh/z_en_dh.c @@ -550,21 +550,21 @@ void EnDh_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->alpha == 255) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, this->alpha); gSPSegment(POLY_OPA_DISP++, 0x08, &D_80116280[2]); POLY_OPA_DISP = SkelAnime_DrawFlex(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, EnDh_PostLimbDraw, &this->actor, POLY_OPA_DISP); } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->alpha); gSPSegment(POLY_XLU_DISP++, 0x08, &D_80116280[0]); POLY_XLU_DISP = SkelAnime_DrawFlex(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, NULL, &this->actor, POLY_XLU_DISP); } if (this->drawDirtWave) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 85, 55, 0, 130); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, (play->state.frames * -3) % 0x80, 0, 0x20, 0x40, 1, diff --git a/soh/src/overlays/actors/ovl_En_Dha/z_en_dha.c b/soh/src/overlays/actors/ovl_En_Dha/z_en_dha.c index 11ec20512..dda60bfe4 100644 --- a/soh/src/overlays/actors/ovl_En_Dha/z_en_dha.c +++ b/soh/src/overlays/actors/ovl_En_Dha/z_en_dha.c @@ -460,7 +460,7 @@ void EnDha_Draw(Actor* thisx, PlayState* play) { s32 pad; EnDha* this = (EnDha*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnDha_OverrideLimbDraw, EnDha_PostLimbDraw, this); } diff --git a/soh/src/overlays/actors/ovl_En_Diving_Game/z_en_diving_game.c b/soh/src/overlays/actors/ovl_En_Diving_Game/z_en_diving_game.c index 57f110124..904b143b8 100644 --- a/soh/src/overlays/actors/ovl_En_Diving_Game/z_en_diving_game.c +++ b/soh/src/overlays/actors/ovl_En_Diving_Game/z_en_diving_game.c @@ -571,7 +571,7 @@ void EnDivingGame_Draw(Actor* thisx, PlayState* play) { GraphicsContext* gfxCtx = play->state.gfxCtx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255); gSPSegment(POLY_OPA_DISP++, 0x0C, EnDivingGame_EmptyDList(play->state.gfxCtx)); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeTexIndex])); diff --git a/soh/src/overlays/actors/ovl_En_Dns/z_en_dns.c b/soh/src/overlays/actors/ovl_En_Dns/z_en_dns.c index 05485d911..8a877ad9d 100644 --- a/soh/src/overlays/actors/ovl_En_Dns/z_en_dns.c +++ b/soh/src/overlays/actors/ovl_En_Dns/z_en_dns.c @@ -534,7 +534,7 @@ void EnDns_Update(Actor* thisx, PlayState* play) { void EnDns_Draw(Actor* thisx, PlayState* play) { EnDns* this = (EnDns*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, NULL, &this->actor); } diff --git a/soh/src/overlays/actors/ovl_En_Dnt_Jiji/z_en_dnt_jiji.c b/soh/src/overlays/actors/ovl_En_Dnt_Jiji/z_en_dnt_jiji.c index daf812a0b..215331857 100644 --- a/soh/src/overlays/actors/ovl_En_Dnt_Jiji/z_en_dnt_jiji.c +++ b/soh/src/overlays/actors/ovl_En_Dnt_Jiji/z_en_dnt_jiji.c @@ -432,7 +432,7 @@ void EnDntJiji_Draw(Actor* thisx, PlayState* play) { EnDntJiji* this = (EnDntJiji*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Push(); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(blinkTex[this->eyeState])); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, NULL, NULL, this); diff --git a/soh/src/overlays/actors/ovl_En_Dnt_Nomal/z_en_dnt_nomal.c b/soh/src/overlays/actors/ovl_En_Dnt_Nomal/z_en_dnt_nomal.c index 7b1d015d5..d7cd0fb7d 100644 --- a/soh/src/overlays/actors/ovl_En_Dnt_Nomal/z_en_dnt_nomal.c +++ b/soh/src/overlays/actors/ovl_En_Dnt_Nomal/z_en_dnt_nomal.c @@ -858,7 +858,7 @@ void EnDntNomal_DrawStageScrub(Actor* thisx, PlayState* play) { s32 pad; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(blinkTex[this->eyeState])); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnDntNomal_OverrideLimbDraw, EnDntNomal_PostLimbDraw, this); @@ -880,7 +880,7 @@ void EnDntNomal_DrawTargetScrub(Actor* thisx, PlayState* play) { EnDntNomal* this = (EnDntNomal*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, NULL, EnDntNomal_PostLimbDraw, this); Matrix_Translate(this->flowerPos.x, this->flowerPos.y, this->flowerPos.z, MTXMODE_NEW); diff --git a/soh/src/overlays/actors/ovl_En_Dodojr/z_en_dodojr.c b/soh/src/overlays/actors/ovl_En_Dodojr/z_en_dodojr.c index ccf761d2e..bcfbd9e11 100644 --- a/soh/src/overlays/actors/ovl_En_Dodojr/z_en_dodojr.c +++ b/soh/src/overlays/actors/ovl_En_Dodojr/z_en_dodojr.c @@ -644,7 +644,7 @@ void EnDodojr_Draw(Actor* thisx, PlayState* play) { EnDodojr* this = (EnDodojr*)thisx; if ((this->actionFunc != func_809F73AC) && (this->actionFunc != func_809F7BE4)) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, func_809F7D50, func_809F7DFC, &this->actor); } diff --git a/soh/src/overlays/actors/ovl_En_Dodongo/z_en_dodongo.c b/soh/src/overlays/actors/ovl_En_Dodongo/z_en_dodongo.c index 02e639ad1..2c904fd0b 100644 --- a/soh/src/overlays/actors/ovl_En_Dodongo/z_en_dodongo.c +++ b/soh/src/overlays/actors/ovl_En_Dodongo/z_en_dodongo.c @@ -919,7 +919,7 @@ void EnDodongo_Draw(Actor* thisx, PlayState* play2) { EnDodongo* this = (EnDodongo*)thisx; s32 index; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnDodongo_OverrideLimbDraw, EnDodongo_PostLimbDraw, this); diff --git a/soh/src/overlays/actors/ovl_En_Dog/z_en_dog.c b/soh/src/overlays/actors/ovl_En_Dog/z_en_dog.c index 11544025c..f14dc957f 100644 --- a/soh/src/overlays/actors/ovl_En_Dog/z_en_dog.c +++ b/soh/src/overlays/actors/ovl_En_Dog/z_en_dog.c @@ -479,7 +479,7 @@ void EnDog_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPPipeSync(POLY_OPA_DISP++); if (CVar_GetS32("gUseDogsCol",0)) { diff --git a/soh/src/overlays/actors/ovl_En_Door/z_en_door.c b/soh/src/overlays/actors/ovl_En_Door/z_en_door.c index 2f316e719..5827ae306 100644 --- a/soh/src/overlays/actors/ovl_En_Door/z_en_door.c +++ b/soh/src/overlays/actors/ovl_En_Door/z_en_door.c @@ -342,7 +342,7 @@ void EnDoor_Draw(Actor* thisx, PlayState* play) { if (this->actor.objBankIndex == this->requiredObjBankIndex) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnDoor_OverrideLimbDraw, NULL, &this->actor); if (this->actor.world.rot.y != 0) { diff --git a/soh/src/overlays/actors/ovl_En_Ds/z_en_ds.c b/soh/src/overlays/actors/ovl_En_Ds/z_en_ds.c index af4abac1a..74ba1a476 100644 --- a/soh/src/overlays/actors/ovl_En_Ds/z_en_ds.c +++ b/soh/src/overlays/actors/ovl_En_Ds/z_en_ds.c @@ -289,7 +289,7 @@ void EnDs_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void EnDs_Draw(Actor* thisx, PlayState* play) { EnDs* this = (EnDs*)thisx; - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnDs_OverrideLimbDraw, EnDs_PostLimbDraw, this); } diff --git a/soh/src/overlays/actors/ovl_En_Dy_Extra/z_en_dy_extra.c b/soh/src/overlays/actors/ovl_En_Dy_Extra/z_en_dy_extra.c index cc58afb91..fbdbe0a9c 100644 --- a/soh/src/overlays/actors/ovl_En_Dy_Extra/z_en_dy_extra.c +++ b/soh/src/overlays/actors/ovl_En_Dy_Extra/z_en_dy_extra.c @@ -112,7 +112,7 @@ void EnDyExtra_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, play->state.frames * 2, 0, 0x20, 0x40, 1, play->state.frames, play->state.frames * -8, 0x10, 0x10)); diff --git a/soh/src/overlays/actors/ovl_En_Eiyer/z_en_eiyer.c b/soh/src/overlays/actors/ovl_En_Eiyer/z_en_eiyer.c index f3ad3a4f5..b7bfa42f4 100644 --- a/soh/src/overlays/actors/ovl_En_Eiyer/z_en_eiyer.c +++ b/soh/src/overlays/actors/ovl_En_Eiyer/z_en_eiyer.c @@ -700,7 +700,7 @@ void EnEiyer_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->actionFunc != EnEiyer_Dead) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, &D_80116280[2]); gDPSetEnvColor(POLY_OPA_DISP++, 255, 255, 255, 255); @@ -708,7 +708,7 @@ void EnEiyer_Draw(Actor* thisx, PlayState* play) { POLY_OPA_DISP = SkelAnime_Draw(play, this->skelanime.skeleton, this->skelanime.jointTable, EnEiyer_OverrideLimbDraw, NULL, this, POLY_OPA_DISP); } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, D_80116280); gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 255, this->actor.shape.shadowAlpha); diff --git a/soh/src/overlays/actors/ovl_En_Elf/z_en_elf.c b/soh/src/overlays/actors/ovl_En_Elf/z_en_elf.c index 25ce77a30..c96b9fecc 100644 --- a/soh/src/overlays/actors/ovl_En_Elf/z_en_elf.c +++ b/soh/src/overlays/actors/ovl_En_Elf/z_en_elf.c @@ -1515,7 +1515,7 @@ void EnElf_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80094B58(play->state.gfxCtx); + Gfx_SetupDL_27Xlu(play->state.gfxCtx); envAlpha = (this->timer * 50) & 0x1FF; envAlpha = (envAlpha > 255) ? 511 - envAlpha : envAlpha; diff --git a/soh/src/overlays/actors/ovl_En_Ex_Item/z_en_ex_item.c b/soh/src/overlays/actors/ovl_En_Ex_Item/z_en_ex_item.c index 69e915610..81ad6df5e 100644 --- a/soh/src/overlays/actors/ovl_En_Ex_Item/z_en_ex_item.c +++ b/soh/src/overlays/actors/ovl_En_Ex_Item/z_en_ex_item.c @@ -561,7 +561,7 @@ void EnExItem_DrawKey(EnExItem* this, PlayState* play, s32 index) { OPEN_DISPS(play->state.gfxCtx); - func_8009460C(play->state.gfxCtx); + Gfx_SetupDL_41Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(keySegments[index])); diff --git a/soh/src/overlays/actors/ovl_En_Ex_Ruppy/z_en_ex_ruppy.c b/soh/src/overlays/actors/ovl_En_Ex_Ruppy/z_en_ex_ruppy.c index ae7258cbb..9a9e71615 100644 --- a/soh/src/overlays/actors/ovl_En_Ex_Ruppy/z_en_ex_ruppy.c +++ b/soh/src/overlays/actors/ovl_En_Ex_Ruppy/z_en_ex_ruppy.c @@ -433,7 +433,7 @@ void EnExRuppy_Draw(Actor* thisx, PlayState* play) { if (!this->invisible) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_8002EBCC(thisx, play, 0); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); if (CVar_GetS32("gNewDrops", 0) !=0) { diff --git a/soh/src/overlays/actors/ovl_En_Fd/z_en_fd.c b/soh/src/overlays/actors/ovl_En_Fd/z_en_fd.c index acc923a6e..de2aaf391 100644 --- a/soh/src/overlays/actors/ovl_En_Fd/z_en_fd.c +++ b/soh/src/overlays/actors/ovl_En_Fd/z_en_fd.c @@ -775,7 +775,7 @@ void EnFd_Draw(Actor* thisx, PlayState* play) { EnFd_DrawFlames(this, play); Matrix_Pop(); if (this->actionFunc != EnFd_Reappear && !(this->fadeAlpha < 0.9f)) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); clampedHealth = CLAMP(thisx->colChkInfo.health - 1, 0, 23); gDPSetPrimColor(POLY_XLU_DISP++, 0, 128, primColors[clampedHealth / 8].r, primColors[clampedHealth / 8].g, primColors[clampedHealth / 8].b, (u8)this->fadeAlpha); @@ -886,13 +886,13 @@ void EnFd_DrawFlames(EnFd* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); firstDone = false; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->effects); i++, eff++) { if (eff->type == FD_EFFECT_FLAME) { FrameInterpolation_RecordOpenChild(eff, eff->epoch); if (!firstDone) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0); gSPDisplayList(POLY_XLU_DISP++, gFlareDancerDL_7928); gDPSetEnvColor(POLY_XLU_DISP++, 255, 10, 0, (u8)((this->fadeAlpha / 255.0f) * 255)); firstDone = true; @@ -923,14 +923,14 @@ void EnFd_DrawDots(EnFd* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); firstDone = false; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->effects); i++, eff++) { if (eff->type == FD_EFFECT_DOT) { FrameInterpolation_RecordOpenChild(eff, eff->epoch); if (!firstDone) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, gFlareDancerDL_79F8); firstDone = true; } diff --git a/soh/src/overlays/actors/ovl_En_Fd_Fire/z_en_fd_fire.c b/soh/src/overlays/actors/ovl_En_Fd_Fire/z_en_fd_fire.c index 5f4a6524d..8cc76a37a 100644 --- a/soh/src/overlays/actors/ovl_En_Fd_Fire/z_en_fd_fire.c +++ b/soh/src/overlays/actors/ovl_En_Fd_Fire/z_en_fd_fire.c @@ -265,7 +265,7 @@ void EnFdFire_Draw(Actor* thisx, PlayState* play) { Matrix_Scale(1.0f, sp84, 1.0f / sp84, MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x8, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, play->state.frames * this->tile2Y, 0x20, 0x80)); diff --git a/soh/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c b/soh/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c index bfb7507cc..0bbd70ca1 100644 --- a/soh/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c +++ b/soh/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c @@ -703,7 +703,7 @@ void EnFhgFire_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->actor.params == FHGFIRE_LIGHTNING_BURST) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, (s8)this->fwork[FHGFIRE_ALPHA]); gDPSetEnvColor(POLY_XLU_DISP++, 165, 255, 75, 0); gDPPipeSync(POLY_XLU_DISP++); @@ -713,7 +713,7 @@ void EnFhgFire_Draw(Actor* thisx, PlayState* play) { } else if ((this->actor.params == FHGFIRE_SPEAR_LIGHT) || (this->actor.params == FHGFIRE_ENERGY_BALL)) { osSyncPrintf("yari hikari draw 1\n"); Matrix_ReplaceRotation(&play->billboardMtxF); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, (s8)this->fwork[FHGFIRE_ALPHA]); if (this->work[FHGFIRE_FIRE_MODE] > FHGFIRE_LIGHT_GREEN) { @@ -728,7 +728,7 @@ void EnFhgFire_Draw(Actor* thisx, PlayState* play) { gSPDisplayList(POLY_XLU_DISP++, gPhantomEnergyBallDL); } else if ((this->actor.params == FHGFIRE_WARP_EMERGE) || (this->actor.params == FHGFIRE_WARP_RETREAT) || (this->actor.params == FHGFIRE_WARP_DEATH)) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 0, 0, 0, (u8)this->fwork[FHGFIRE_WARP_ALPHA]); gDPSetEnvColor(POLY_XLU_DISP++, 90, 50, 95, (s8)(this->fwork[FHGFIRE_WARP_ALPHA] * 0.5f)); gDPPipeSync(POLY_XLU_DISP++); @@ -743,7 +743,7 @@ void EnFhgFire_Draw(Actor* thisx, PlayState* play) { } else { osSyncPrintf("FF DRAW 1\n"); Matrix_Translate(0.0f, -100.0f, 0.0f, MTXMODE_APPLY); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, (s8)this->fwork[FHGFIRE_ALPHA]); gDPSetEnvColor(POLY_XLU_DISP++, 0, 255, 30, 0); gDPPipeSync(POLY_XLU_DISP++); diff --git a/soh/src/overlays/actors/ovl_En_Fire_Rock/z_en_fire_rock.c b/soh/src/overlays/actors/ovl_En_Fire_Rock/z_en_fire_rock.c index 1f8a42059..022a95538 100644 --- a/soh/src/overlays/actors/ovl_En_Fire_Rock/z_en_fire_rock.c +++ b/soh/src/overlays/actors/ovl_En_Fire_Rock/z_en_fire_rock.c @@ -389,7 +389,7 @@ void EnFireRock_Draw(Actor* thisx, PlayState* play) { Matrix_RotateY(DEG_TO_RAD(this->rockRotation.y), MTXMODE_APPLY); Matrix_RotateZ(DEG_TO_RAD(this->rockRotation.z), MTXMODE_APPLY); Matrix_Scale(thisx->scale.x, thisx->scale.y, thisx->scale.z, MTXMODE_APPLY); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 155, 55, 255); gDPSetEnvColor(POLY_OPA_DISP++, 155, 255, 55, 255); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), diff --git a/soh/src/overlays/actors/ovl_En_Firefly/z_en_firefly.c b/soh/src/overlays/actors/ovl_En_Firefly/z_en_firefly.c index ae5e989a7..eaa18d9c1 100644 --- a/soh/src/overlays/actors/ovl_En_Firefly/z_en_firefly.c +++ b/soh/src/overlays/actors/ovl_En_Firefly/z_en_firefly.c @@ -837,7 +837,7 @@ void EnFirefly_Draw(Actor* thisx, PlayState* play) { EnFirefly* this = (EnFirefly*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->onFire) { gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 0); @@ -854,7 +854,7 @@ void EnFirefly_DrawInvisible(Actor* thisx, PlayState* play) { EnFirefly* this = (EnFirefly*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->onFire) { gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, 0); diff --git a/soh/src/overlays/actors/ovl_En_Fish/z_en_fish.c b/soh/src/overlays/actors/ovl_En_Fish/z_en_fish.c index 9306c4cdc..be42dc521 100644 --- a/soh/src/overlays/actors/ovl_En_Fish/z_en_fish.c +++ b/soh/src/overlays/actors/ovl_En_Fish/z_en_fish.c @@ -761,7 +761,7 @@ void EnFish_Update(Actor* thisx, PlayState* play) { void EnFish_Draw(Actor* thisx, PlayState* play) { EnFish* this = (EnFish*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, NULL, NULL); Collider_UpdateSpheres(0, &this->collider); diff --git a/soh/src/overlays/actors/ovl_En_Floormas/z_en_floormas.c b/soh/src/overlays/actors/ovl_En_Floormas/z_en_floormas.c index 362f43115..798e2f906 100644 --- a/soh/src/overlays/actors/ovl_En_Floormas/z_en_floormas.c +++ b/soh/src/overlays/actors/ovl_En_Floormas/z_en_floormas.c @@ -1112,7 +1112,7 @@ void EnFloormas_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->collider.base.colType == COLTYPE_HARD) { func_80026230(play, &sMergeColor, this->actionTarget % 0x28, 0x28); } @@ -1132,7 +1132,7 @@ void EnFloormas_DrawHighlighted(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->collider.base.colType == COLTYPE_HARD) { func_80026690(play, &sMergeColor, this->actionTarget % 0x28, 0x28); } diff --git a/soh/src/overlays/actors/ovl_En_Fr/z_en_fr.c b/soh/src/overlays/actors/ovl_En_Fr/z_en_fr.c index 33abfa39c..5c7159da0 100644 --- a/soh/src/overlays/actors/ovl_En_Fr/z_en_fr.c +++ b/soh/src/overlays/actors/ovl_En_Fr/z_en_fr.c @@ -1101,7 +1101,7 @@ void EnFr_Draw(Actor* thisx, PlayState* play) { s16 frogIndex = this->actor.params - 1; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); // For the frogs 2 HP, the frog with the next note and the butterfly lights up lightRadius = this->isButterflyDrawn ? 95 : -1; gDPPipeSync(POLY_OPA_DISP++); diff --git a/soh/src/overlays/actors/ovl_En_Fu/z_en_fu.c b/soh/src/overlays/actors/ovl_En_Fu/z_en_fu.c index 57b049270..13d32d757 100644 --- a/soh/src/overlays/actors/ovl_En_Fu/z_en_fu.c +++ b/soh/src/overlays/actors/ovl_En_Fu/z_en_fu.c @@ -327,7 +327,7 @@ void EnFu_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyesSegments[this->facialExpression])); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(sMouthSegments[this->facialExpression])); SkelAnime_DrawFlexOpa(play, this->skelanime.skeleton, this->skelanime.jointTable, this->skelanime.dListCount, diff --git a/soh/src/overlays/actors/ovl_En_Fw/z_en_fw.c b/soh/src/overlays/actors/ovl_En_Fw/z_en_fw.c index 43adc01f8..41732a7c0 100644 --- a/soh/src/overlays/actors/ovl_En_Fw/z_en_fw.c +++ b/soh/src/overlays/actors/ovl_En_Fw/z_en_fw.c @@ -403,7 +403,7 @@ void EnFw_Draw(Actor* thisx, PlayState* play) { Matrix_Push(); EnFw_DrawDust(this, play); Matrix_Pop(); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnFw_OverrideLimbDraw, EnFw_PostLimbDraw, this); } @@ -463,14 +463,14 @@ void EnFw_DrawDust(EnFw* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); firstDone = false; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->effects); i++, eff++) { FrameInterpolation_RecordOpenChild(eff, eff->epoch); if (eff->type != 0) { if (!firstDone) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0U); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0U); gSPDisplayList(POLY_XLU_DISP++, gFlareDancerDL_7928); gDPSetEnvColor(POLY_XLU_DISP++, 100, 60, 20, 0); firstDone = true; diff --git a/soh/src/overlays/actors/ovl_En_Fz/z_en_fz.c b/soh/src/overlays/actors/ovl_En_Fz/z_en_fz.c index 36b4d373b..8736b47ba 100644 --- a/soh/src/overlays/actors/ovl_En_Fz/z_en_fz.c +++ b/soh/src/overlays/actors/ovl_En_Fz/z_en_fz.c @@ -727,7 +727,7 @@ void EnFz_Draw(Actor* thisx, PlayState* play) { if (this->isActive) { func_8002ED80(&this->actor, play, 0); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, play->state.frames & 0x7F, 32, 32, 1, 0, (2 * play->state.frames) & 0x7F, 32, 32)); @@ -865,7 +865,7 @@ void EnFz_DrawIceSmoke(EnFz* this, PlayState* play) { OPEN_DISPS(gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->iceSmoke); i++) { FrameInterpolation_RecordOpenChild(iceSmoke, iceSmoke->epoch); diff --git a/soh/src/overlays/actors/ovl_En_G_Switch/z_en_g_switch.c b/soh/src/overlays/actors/ovl_En_G_Switch/z_en_g_switch.c index a29752393..f9cb56f50 100644 --- a/soh/src/overlays/actors/ovl_En_G_Switch/z_en_g_switch.c +++ b/soh/src/overlays/actors/ovl_En_G_Switch/z_en_g_switch.c @@ -475,7 +475,7 @@ void EnGSwitch_DrawPot(Actor* thisx, PlayState* play) { if (!this->broken) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, object_tsubo_DL_0017C0); @@ -495,7 +495,7 @@ void EnGSwitch_DrawRupee(Actor* thisx, PlayState* play) { if (!this->broken) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_8002EBCC(&this->actor, play, 0); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); if (CVar_GetS32("gNewDrops", 0) !=0) { @@ -505,10 +505,10 @@ void EnGSwitch_DrawRupee(Actor* thisx, PlayState* play) { } else { gDPSetGrayscaleColor(POLY_OPA_DISP++, 255, 255, 255, 255); gSPGrayscale(POLY_OPA_DISP++, true); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPDisplayList(POLY_OPA_DISP++, gGiRupeeInnerDL); gSPDisplayList(POLY_OPA_DISP++, gGiGoldRupeeInnerColorDL); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_OPA_DISP++, gGiRupeeOuterDL); gSPDisplayList(POLY_OPA_DISP++, gGiGoldRupeeOuterColorDL); gSPGrayscale(POLY_OPA_DISP++, false); @@ -589,7 +589,7 @@ void EnGSwitch_DrawEffects(EnGSwitch* this, PlayState* play) { s32 pad; OPEN_DISPS(gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); for (i = 0; i < this->numEffects; i++, effect++) { if (effect->flag) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); diff --git a/soh/src/overlays/actors/ovl_En_Ganon_Organ/z_en_ganon_organ.c b/soh/src/overlays/actors/ovl_En_Ganon_Organ/z_en_ganon_organ.c index c1598f60c..b1bccd113 100644 --- a/soh/src/overlays/actors/ovl_En_Ganon_Organ/z_en_ganon_organ.c +++ b/soh/src/overlays/actors/ovl_En_Ganon_Organ/z_en_ganon_organ.c @@ -92,7 +92,7 @@ void EnGanonOrgan_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); osSyncPrintf("ORGAN DRAW 1\n"); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if ((thisx->params == 1) && (dorf->organAlpha != 255)) { gSPSegment(POLY_OPA_DISP++, 0x08, func_80A280BC(play->state.gfxCtx, dorf)); gSPSegment(POLY_OPA_DISP++, 0x09, func_80A28148(play->state.gfxCtx, dorf)); diff --git a/soh/src/overlays/actors/ovl_En_Gb/z_en_gb.c b/soh/src/overlays/actors/ovl_En_Gb/z_en_gb.c index 0bd71ea3b..0110c3017 100644 --- a/soh/src/overlays/actors/ovl_En_Gb/z_en_gb.c +++ b/soh/src/overlays/actors/ovl_En_Gb/z_en_gb.c @@ -437,7 +437,7 @@ void EnGb_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPPipeSync(POLY_OPA_DISP++); gDPSetEnvColor(POLY_OPA_DISP++, this->lightColor.r, this->lightColor.g, this->lightColor.b, 255); @@ -531,7 +531,7 @@ void EnGb_DrawCagedSouls(EnGb* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < 4; i++) { s32 idx = this->cagedSouls[i].infoIdx; diff --git a/soh/src/overlays/actors/ovl_En_Ge1/z_en_ge1.c b/soh/src/overlays/actors/ovl_En_Ge1/z_en_ge1.c index 0ee47a595..323bfc160 100644 --- a/soh/src/overlays/actors/ovl_En_Ge1/z_en_ge1.c +++ b/soh/src/overlays/actors/ovl_En_Ge1/z_en_ge1.c @@ -876,7 +876,7 @@ void EnGe1_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeIndex])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnGe1_OverrideLimbDraw, EnGe1_PostLimbDraw, this); diff --git a/soh/src/overlays/actors/ovl_En_Ge2/z_en_ge2.c b/soh/src/overlays/actors/ovl_En_Ge2/z_en_ge2.c index 0d49cbab1..ab5a48b7a 100644 --- a/soh/src/overlays/actors/ovl_En_Ge2/z_en_ge2.c +++ b/soh/src/overlays/actors/ovl_En_Ge2/z_en_ge2.c @@ -675,7 +675,7 @@ void EnGe2_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeIndex])); func_8002EBCC(&this->actor, play, 0); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, diff --git a/soh/src/overlays/actors/ovl_En_Ge3/z_en_ge3.c b/soh/src/overlays/actors/ovl_En_Ge3/z_en_ge3.c index 44ae79d9e..3d174fe14 100644 --- a/soh/src/overlays/actors/ovl_En_Ge3/z_en_ge3.c +++ b/soh/src/overlays/actors/ovl_En_Ge3/z_en_ge3.c @@ -298,7 +298,7 @@ void EnGe3_Draw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeIndex])); func_8002EBCC(&this->actor, play, 0); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, diff --git a/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c b/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c index ccb9cb7bc..a5782788b 100644 --- a/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c +++ b/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c @@ -1577,7 +1577,7 @@ void EnGeldB_Draw(Actor* thisx, PlayState* play) { } if ((this->action != GELDB_WAIT) || !this->invisible) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->blinkState])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnGeldB_OverrideLimbDraw, EnGeldB_PostLimbDraw, this); diff --git a/soh/src/overlays/actors/ovl_En_Gm/z_en_gm.c b/soh/src/overlays/actors/ovl_En_Gm/z_en_gm.c index 8a63a70f2..826a684ce 100644 --- a/soh/src/overlays/actors/ovl_En_Gm/z_en_gm.c +++ b/soh/src/overlays/actors/ovl_En_Gm/z_en_gm.c @@ -348,7 +348,7 @@ void EnGm_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeTexIndex])); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(gGoronCsMouthNeutralTex)); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, diff --git a/soh/src/overlays/actors/ovl_En_Go/z_en_go.c b/soh/src/overlays/actors/ovl_En_Go/z_en_go.c index 936d7c0cc..6b4ba5da6 100644 --- a/soh/src/overlays/actors/ovl_En_Go/z_en_go.c +++ b/soh/src/overlays/actors/ovl_En_Go/z_en_go.c @@ -1072,7 +1072,7 @@ void EnGo_DrawCurledUp(EnGo* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); Matrix_Push(); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -1091,7 +1091,7 @@ void EnGo_DrawRolling(EnGo* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); Matrix_Push(); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_RotateZYX((s16)(play->state.frames * ((s16)this->actor.speedXZ * 1400)), 0, this->actor.shape.rot.z, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), @@ -1161,7 +1161,7 @@ void EnGo_Draw(Actor* thisx, PlayState* play) { this->actionFunc == EnGo_StopRolling || this->actionFunc == func_80A3FEB4) { EnGo_DrawRolling(this, play); } else { - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(gGoronCsEyeOpenTex)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(gGoronCsMouthNeutralTex)); @@ -1231,11 +1231,11 @@ void EnGo_DrawDust(EnGo* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); firstDone = false; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->dustEffects); i++, dustEffect++) { if (dustEffect->type) { if (!firstDone) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0); gSPDisplayList(POLY_XLU_DISP++, gGoronDL_00FD40); gDPSetEnvColor(POLY_XLU_DISP++, 100, 60, 20, 0); firstDone = true; diff --git a/soh/src/overlays/actors/ovl_En_Go2/z_en_go2.c b/soh/src/overlays/actors/ovl_En_Go2/z_en_go2.c index c2620fa82..df7233d93 100644 --- a/soh/src/overlays/actors/ovl_En_Go2/z_en_go2.c +++ b/soh/src/overlays/actors/ovl_En_Go2/z_en_go2.c @@ -229,12 +229,12 @@ void EnGo2_DrawDust(EnGo2* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); firstDone = false; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->dustEffects); i++, dustEffect++) { if (dustEffect->type) { if (!firstDone) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0); gSPDisplayList(POLY_XLU_DISP++, gGoronDL_00FD40); gDPSetEnvColor(POLY_XLU_DISP++, 100, 60, 20, 0); firstDone = true; @@ -2066,7 +2066,7 @@ s32 EnGo2_DrawCurledUp(EnGo2* this, PlayState* play) { Vec3f D_80A48554 = { 0.0f, 0.0f, 0.0f }; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gGoronDL_00BD80); @@ -2082,7 +2082,7 @@ s32 EnGo2_DrawRolling(EnGo2* this, PlayState* play) { f32 speedXZ; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); speedXZ = this->actionFunc == EnGo2_ReverseRolling ? 0.0f : this->actor.speedXZ; Matrix_RotateZYX((play->state.frames * ((s16)speedXZ * 1400)), 0, this->actor.shape.rot.z, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), @@ -2150,7 +2150,7 @@ void EnGo2_Draw(Actor* thisx, PlayState* play) { EnGo2_DrawRolling(this, play); } else { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeTexIndex])); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(mouthTextures[this->mouthTexIndex])); diff --git a/soh/src/overlays/actors/ovl_En_Goma/z_en_goma.c b/soh/src/overlays/actors/ovl_En_Goma/z_en_goma.c index 4d99b703a..3ad2e9eee 100644 --- a/soh/src/overlays/actors/ovl_En_Goma/z_en_goma.c +++ b/soh/src/overlays/actors/ovl_En_Goma/z_en_goma.c @@ -786,7 +786,7 @@ void EnGoma_Draw(Actor* thisx, PlayState* play) { s32 pad; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); switch (this->gomaType) { case ENGOMA_NORMAL: diff --git a/soh/src/overlays/actors/ovl_En_Gs/z_en_gs.c b/soh/src/overlays/actors/ovl_En_Gs/z_en_gs.c index aee0edfc5..63688b0a8 100644 --- a/soh/src/overlays/actors/ovl_En_Gs/z_en_gs.c +++ b/soh/src/overlays/actors/ovl_En_Gs/z_en_gs.c @@ -574,7 +574,7 @@ void EnGs_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); frames = play->gameplayFrames; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Push(); if (this->unk_19E & 1) { Matrix_RotateY(this->unk_1A0[0].y * (M_PI / 0x8000), MTXMODE_APPLY); @@ -602,7 +602,7 @@ void EnGs_Draw(Actor* thisx, PlayState* play) { Matrix_Pop(); if (this->unk_19E & 2) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_ReplaceRotation(&play->billboardMtxF); Matrix_Scale(0.05f, -0.05f, 1.0f, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_En_Guest/z_en_guest.c b/soh/src/overlays/actors/ovl_En_Guest/z_en_guest.c index a664d4a66..44be982cd 100644 --- a/soh/src/overlays/actors/ovl_En_Guest/z_en_guest.c +++ b/soh/src/overlays/actors/ovl_En_Guest/z_en_guest.c @@ -222,7 +222,7 @@ void EnGuest_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, func_80A50708(play->state.gfxCtx, 255, 255, 255, 255)); gSPSegment(POLY_OPA_DISP++, 0x09, func_80A50708(play->state.gfxCtx, 160, 60, 220, 255)); diff --git a/soh/src/overlays/actors/ovl_En_Hata/z_en_hata.c b/soh/src/overlays/actors/ovl_En_Hata/z_en_hata.c index 80ecf983b..3499a8120 100644 --- a/soh/src/overlays/actors/ovl_En_Hata/z_en_hata.c +++ b/soh/src/overlays/actors/ovl_En_Hata/z_en_hata.c @@ -139,7 +139,7 @@ void EnHata_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot void EnHata_Draw(Actor* thisx, PlayState* play) { EnHata* this = (EnHata*)thisx; - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); Matrix_Scale(1.0f, 1.1f, 1.0f, MTXMODE_APPLY); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnHata_OverrideLimbDraw, EnHata_PostLimbDraw, this); diff --git a/soh/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c b/soh/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c index 26d1cb3ba..7c06608ff 100644 --- a/soh/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c +++ b/soh/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c @@ -502,7 +502,7 @@ void EnHeishi1_Draw(Actor* thisx, PlayState* play) { EnHeishi1* this = (EnHeishi1*)thisx; Vec3f matrixScale = { 0.3f, 0.3f, 0.3f }; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnHeishi1_OverrideLimbDraw, NULL, this); func_80033C30(&this->actor.world.pos, &matrixScale, 0xFF, play); diff --git a/soh/src/overlays/actors/ovl_En_Heishi2/z_en_heishi2.c b/soh/src/overlays/actors/ovl_En_Heishi2/z_en_heishi2.c index d851deaa2..625699d07 100644 --- a/soh/src/overlays/actors/ovl_En_Heishi2/z_en_heishi2.c +++ b/soh/src/overlays/actors/ovl_En_Heishi2/z_en_heishi2.c @@ -842,7 +842,7 @@ void EnHeishi2_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnHeishi2_OverrideLimbDraw, EnHeishi2_PostLimbDraw, this); diff --git a/soh/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c b/soh/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c index f93292542..06407227f 100644 --- a/soh/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c +++ b/soh/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c @@ -248,7 +248,7 @@ s32 EnHeishi3_OverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3 void EnHeishi3_Draw(Actor* thisx, PlayState* play) { EnHeishi3* this = (EnHeishi3*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnHeishi3_OverrideLimbDraw, NULL, this); } diff --git a/soh/src/overlays/actors/ovl_En_Heishi4/z_en_heishi4.c b/soh/src/overlays/actors/ovl_En_Heishi4/z_en_heishi4.c index 7bd935df9..379281148 100644 --- a/soh/src/overlays/actors/ovl_En_Heishi4/z_en_heishi4.c +++ b/soh/src/overlays/actors/ovl_En_Heishi4/z_en_heishi4.c @@ -381,7 +381,7 @@ s32 EnHeishi_OverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f void EnHeishi4_Draw(Actor* thisx, PlayState* play) { EnHeishi4* this = (EnHeishi4*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnHeishi_OverrideLimbDraw, NULL, this); } diff --git a/soh/src/overlays/actors/ovl_En_Holl/z_en_holl.c b/soh/src/overlays/actors/ovl_En_Holl/z_en_holl.c index 2851efb88..a2e23a599 100644 --- a/soh/src/overlays/actors/ovl_En_Holl/z_en_holl.c +++ b/soh/src/overlays/actors/ovl_En_Holl/z_en_holl.c @@ -338,7 +338,7 @@ void EnHoll_Draw(Actor* thisx, PlayState* play) { gfxP = POLY_XLU_DISP; setupDlIdx = 0; } - gfxP = Gfx_CallSetupDL(gfxP, setupDlIdx); + gfxP = Gfx_SetupDL(gfxP, setupDlIdx); if (this->side == 0) { Matrix_RotateY(M_PI, MTXMODE_APPLY); } diff --git a/soh/src/overlays/actors/ovl_En_Honotrap/z_en_honotrap.c b/soh/src/overlays/actors/ovl_En_Honotrap/z_en_honotrap.c index be30f0f56..b01ea5f6d 100644 --- a/soh/src/overlays/actors/ovl_En_Honotrap/z_en_honotrap.c +++ b/soh/src/overlays/actors/ovl_En_Honotrap/z_en_honotrap.c @@ -497,7 +497,7 @@ void EnHonotrap_DrawEye(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeState])); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -512,7 +512,7 @@ void EnHonotrap_DrawFlame(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); this->flameScroll -= 20; this->flameScroll &= 0x1FF; gSPSegment(POLY_XLU_DISP++, 0x08, diff --git a/soh/src/overlays/actors/ovl_En_Horse/z_en_horse.c b/soh/src/overlays/actors/ovl_En_Horse/z_en_horse.c index 24240b422..05719098f 100644 --- a/soh/src/overlays/actors/ovl_En_Horse/z_en_horse.c +++ b/soh/src/overlays/actors/ovl_En_Horse/z_en_horse.c @@ -3825,7 +3825,7 @@ void EnHorse_Draw(Actor* thisx, PlayState* play) { EnHorse* this = (EnHorse*)thisx; if (!(this->stateFlags & ENHORSE_INACTIVE)) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); this->stateFlags |= ENHORSE_DRAW; if (this->stateFlags & ENHORSE_JUMPING) { func_800A6360(thisx, play, &this->skin, EnHorse_PostDraw, EnHorse_OverrideLimbDraw, false); diff --git a/soh/src/overlays/actors/ovl_En_Horse_Ganon/z_en_horse_ganon.c b/soh/src/overlays/actors/ovl_En_Horse_Ganon/z_en_horse_ganon.c index d256eabfe..f492b3cf4 100644 --- a/soh/src/overlays/actors/ovl_En_Horse_Ganon/z_en_horse_ganon.c +++ b/soh/src/overlays/actors/ovl_En_Horse_Ganon/z_en_horse_ganon.c @@ -326,6 +326,6 @@ void EnHorseGanon_Draw(Actor* thisx, PlayState* play) { EnHorseGanon* this = (EnHorseGanon*)thisx; func_80A68E14(this, play); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_800A6330(&this->actor, play, &this->skin, EnHorseGanon_PostDraw, true); } diff --git a/soh/src/overlays/actors/ovl_En_Horse_Link_Child/z_en_horse_link_child.c b/soh/src/overlays/actors/ovl_En_Horse_Link_Child/z_en_horse_link_child.c index b9a7120b8..529432052 100644 --- a/soh/src/overlays/actors/ovl_En_Horse_Link_Child/z_en_horse_link_child.c +++ b/soh/src/overlays/actors/ovl_En_Horse_Link_Child/z_en_horse_link_child.c @@ -620,7 +620,7 @@ s32 EnHorseLinkChild_OverrideLimbDraw(Actor* thisx, PlayState* play, s32 arg2, S void EnHorseLinkChild_Draw(Actor* thisx, PlayState* play) { EnHorseLinkChild* this = (EnHorseLinkChild*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_800A6360(&this->actor, play, &this->skin, EnHorseLinkChild_PostDraw, EnHorseLinkChild_OverrideLimbDraw, true); } diff --git a/soh/src/overlays/actors/ovl_En_Horse_Normal/z_en_horse_normal.c b/soh/src/overlays/actors/ovl_En_Horse_Normal/z_en_horse_normal.c index 582781cd6..4ca68c4aa 100644 --- a/soh/src/overlays/actors/ovl_En_Horse_Normal/z_en_horse_normal.c +++ b/soh/src/overlays/actors/ovl_En_Horse_Normal/z_en_horse_normal.c @@ -642,7 +642,7 @@ void EnHorseNormal_Draw(Actor* thisx, PlayState* play) { if (play->sceneNum != SCENE_SPOT20 || play->sceneNum != SCENE_MALON_STABLE) { func_80A6C8E0(this, play); } - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_800A6330(&this->actor, play, &this->skin, EnHorseNormal_PostDraw, true); if (this->action == HORSE_WAIT_CLONE) { @@ -699,7 +699,7 @@ void EnHorseNormal_Draw(Actor* thisx, PlayState* play) { this->cloneCollider.dim.pos.y = clonePos.y; this->cloneCollider.dim.pos.z = clonePos.z; CollisionCheck_SetOC(play, &play->colChkCtx, &this->cloneCollider.base); - func_80094044(play->state.gfxCtx); + Gfx_SetupDL_44Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 0, 0, 0, 255); Matrix_Translate(clonePos.x, clonePos.y, clonePos.z, MTXMODE_NEW); temp_f0_4 = (1.0f - (distFromGround * 0.01f)) * this->actor.shape.shadowScale; diff --git a/soh/src/overlays/actors/ovl_En_Horse_Zelda/z_en_horse_zelda.c b/soh/src/overlays/actors/ovl_En_Horse_Zelda/z_en_horse_zelda.c index 925345587..8a2bad211 100644 --- a/soh/src/overlays/actors/ovl_En_Horse_Zelda/z_en_horse_zelda.c +++ b/soh/src/overlays/actors/ovl_En_Horse_Zelda/z_en_horse_zelda.c @@ -270,6 +270,6 @@ void EnHorseZelda_Draw(Actor* thisx, PlayState* play) { EnHorseZelda* this = (EnHorseZelda*)thisx; func_80A6DE38(this, play); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_800A6330(&this->actor, play, &this->skin, EnHorseZelda_PostDraw, true); } diff --git a/soh/src/overlays/actors/ovl_En_Hs/z_en_hs.c b/soh/src/overlays/actors/ovl_En_Hs/z_en_hs.c index d642bce3e..bb1b07b3c 100644 --- a/soh/src/overlays/actors/ovl_En_Hs/z_en_hs.c +++ b/soh/src/overlays/actors/ovl_En_Hs/z_en_hs.c @@ -329,7 +329,7 @@ void EnHs_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void EnHs_Draw(Actor* thisx, PlayState* play) { EnHs* this = (EnHs*)thisx; - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnHs_OverrideLimbDraw, EnHs_PostLimbDraw, this); } diff --git a/soh/src/overlays/actors/ovl_En_Hs2/z_en_hs2.c b/soh/src/overlays/actors/ovl_En_Hs2/z_en_hs2.c index ca3a2f8fa..6e0e58913 100644 --- a/soh/src/overlays/actors/ovl_En_Hs2/z_en_hs2.c +++ b/soh/src/overlays/actors/ovl_En_Hs2/z_en_hs2.c @@ -163,7 +163,7 @@ void EnHs2_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void EnHs2_Draw(Actor* thisx, PlayState* play) { EnHs2* this = (EnHs2*)thisx; - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnHs2_OverrideLimbDraw, EnHs2_PostLimbDraw, this); } diff --git a/soh/src/overlays/actors/ovl_En_Hy/z_en_hy.c b/soh/src/overlays/actors/ovl_En_Hy/z_en_hy.c index cf9c3fe19..66b0af42d 100644 --- a/soh/src/overlays/actors/ovl_En_Hy/z_en_hy.c +++ b/soh/src/overlays/actors/ovl_En_Hy/z_en_hy.c @@ -1205,7 +1205,7 @@ void EnHy_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->actionFunc != EnHy_InitImpl) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Translate(this->modelOffset.x, this->modelOffset.y, this->modelOffset.z, MTXMODE_APPLY); envColorSeg8 = sModelInfo[this->actor.params & 0x7F].envColorSeg8; envColorSeg9 = sModelInfo[this->actor.params & 0x7F].envColorSeg9; diff --git a/soh/src/overlays/actors/ovl_En_Ice_Hono/z_en_ice_hono.c b/soh/src/overlays/actors/ovl_En_Ice_Hono/z_en_ice_hono.c index a2a5d1c34..aed400350 100644 --- a/soh/src/overlays/actors/ovl_En_Ice_Hono/z_en_ice_hono.c +++ b/soh/src/overlays/actors/ovl_En_Ice_Hono/z_en_ice_hono.c @@ -376,7 +376,7 @@ void EnIceHono_Draw(Actor* thisx, PlayState* play) { u32 pad; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (play->state.frames * -20) % 512, diff --git a/soh/src/overlays/actors/ovl_En_Ik/z_en_ik.c b/soh/src/overlays/actors/ovl_En_Ik/z_en_ik.c index 79d65259c..99fd33d31 100644 --- a/soh/src/overlays/actors/ovl_En_Ik/z_en_ik.c +++ b/soh/src/overlays/actors/ovl_En_Ik/z_en_ik.c @@ -930,8 +930,8 @@ void func_80A76798(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->actor.params == 0) { gSPSegment(POLY_OPA_DISP++, 0x08, func_80A761B0(play->state.gfxCtx, 245, 225, 155, 30, 30, 0)); @@ -1215,8 +1215,8 @@ void func_80A77844(EnIk* this, PlayState* play) { OPEN_DISPS(gfxCtx); func_8002EBCC(&this->actor, play, 0); - func_80093D18(gfxCtx); - func_80093D84(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); + Gfx_SetupDL_25Xlu(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, func_80A761B0(gfxCtx, 245, 225, 155, 30, 30, 0)); gSPSegment(POLY_OPA_DISP++, 0x09, func_80A761B0(gfxCtx, 255, 40, 0, 40, 0, 0)); gSPSegment(POLY_OPA_DISP++, 0x0A, func_80A761B0(gfxCtx, 255, 255, 255, 20, 40, 30)); @@ -1369,8 +1369,8 @@ void func_80A77EDC(EnIk* this, PlayState* play) { OPEN_DISPS(gfxCtx); func_8002EBCC(&this->actor, play, 0); - func_80093D18(gfxCtx); - func_80093D84(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); + Gfx_SetupDL_25Xlu(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, func_80A761B0(gfxCtx, 245, 225, 155, 30, 30, 0)); gSPSegment(POLY_OPA_DISP++, 0x09, func_80A761B0(gfxCtx, 255, 40, 0, 40, 0, 0)); gSPSegment(POLY_OPA_DISP++, 0x0A, func_80A761B0(gfxCtx, 255, 255, 255, 20, 40, 30)); diff --git a/soh/src/overlays/actors/ovl_En_In/z_en_in.c b/soh/src/overlays/actors/ovl_En_In/z_en_in.c index 1c4291efc..123f23df5 100644 --- a/soh/src/overlays/actors/ovl_En_In/z_en_in.c +++ b/soh/src/overlays/actors/ovl_En_In/z_en_in.c @@ -995,7 +995,7 @@ void EnIn_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->actionFunc != func_80A79FB0) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeIndex])); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(gIngoHeadGradient2Tex)); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, diff --git a/soh/src/overlays/actors/ovl_En_Insect/z_en_insect.c b/soh/src/overlays/actors/ovl_En_Insect/z_en_insect.c index 43562b00b..08bb0d42a 100644 --- a/soh/src/overlays/actors/ovl_En_Insect/z_en_insect.c +++ b/soh/src/overlays/actors/ovl_En_Insect/z_en_insect.c @@ -789,7 +789,7 @@ void EnInsect_Update(Actor* thisx, PlayState* play) { void EnInsect_Draw(Actor* thisx, PlayState* play) { EnInsect* this = (EnInsect*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, NULL, NULL, NULL); Collider_UpdateSpheres(0, &this->collider); D_80A7DEB4 = 0; diff --git a/soh/src/overlays/actors/ovl_En_Ishi/z_en_ishi.c b/soh/src/overlays/actors/ovl_En_Ishi/z_en_ishi.c index 5741f49f2..57c4bb98a 100644 --- a/soh/src/overlays/actors/ovl_En_Ishi/z_en_ishi.c +++ b/soh/src/overlays/actors/ovl_En_Ishi/z_en_ishi.c @@ -490,7 +490,7 @@ void EnIshi_DrawSmall(EnIshi* this, PlayState* play) { void EnIshi_DrawLarge(EnIshi* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 255, 255, 255); diff --git a/soh/src/overlays/actors/ovl_En_Jj/z_en_jj.c b/soh/src/overlays/actors/ovl_En_Jj/z_en_jj.c index eabc9aaa6..9b729d260 100644 --- a/soh/src/overlays/actors/ovl_En_Jj/z_en_jj.c +++ b/soh/src/overlays/actors/ovl_En_Jj/z_en_jj.c @@ -312,7 +312,7 @@ void EnJj_Draw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); Matrix_Translate(0.0f, (cosf(this->skelAnime.curFrame * (M_PI / 41.0f)) * 10.0f) - 10.0f, 0.0f, MTXMODE_APPLY); Matrix_Scale(10.0f, 10.0f, 10.0f, MTXMODE_APPLY); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeIndex])); diff --git a/soh/src/overlays/actors/ovl_En_Js/z_en_js.c b/soh/src/overlays/actors/ovl_En_Js/z_en_js.c index 66ae484d4..3afa0e8ca 100644 --- a/soh/src/overlays/actors/ovl_En_Js/z_en_js.c +++ b/soh/src/overlays/actors/ovl_En_Js/z_en_js.c @@ -234,7 +234,7 @@ void EnJs_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void EnJs_Draw(Actor* thisx, PlayState* play) { EnJs* this = (EnJs*)thisx; - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnJs_OverrideLimbDraw, EnJs_PostLimbDraw, this); } diff --git a/soh/src/overlays/actors/ovl_En_Jsjutan/z_en_jsjutan.c b/soh/src/overlays/actors/ovl_En_Jsjutan/z_en_jsjutan.c index 6217ae1c4..70131d1b4 100644 --- a/soh/src/overlays/actors/ovl_En_Jsjutan/z_en_jsjutan.c +++ b/soh/src/overlays/actors/ovl_En_Jsjutan/z_en_jsjutan.c @@ -407,7 +407,7 @@ void EnJsjutan_Draw(Actor* thisx, PlayState* play2) { } } } - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 0, 0, 0, (s16)this->shadowAlpha); @@ -430,7 +430,7 @@ void EnJsjutan_Draw(Actor* thisx, PlayState* play2) { } gSPDisplayList(POLY_OPA_DISP++, sModelDL); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Translate(thisx->world.pos.x, this->unk_168 + 3.0f, thisx->world.pos.z, MTXMODE_NEW); Matrix_Scale(thisx->scale.x, thisx->scale.y, thisx->scale.z, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_En_Kakasi/z_en_kakasi.c b/soh/src/overlays/actors/ovl_En_Kakasi/z_en_kakasi.c index 95e493eee..2d2e2c6a6 100644 --- a/soh/src/overlays/actors/ovl_En_Kakasi/z_en_kakasi.c +++ b/soh/src/overlays/actors/ovl_En_Kakasi/z_en_kakasi.c @@ -344,7 +344,7 @@ void EnKakasi_Draw(Actor* thisx, PlayState* play) { // "flag!" osSyncPrintf(VT_FGCOL(YELLOW) "☆☆☆☆☆ フラグ! ☆☆☆☆☆ %d\n" VT_RST, gSaveContext.scarecrowLongSongSet); } - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelanime.skeleton, this->skelanime.jointTable, this->skelanime.dListCount, NULL, NULL, this); } diff --git a/soh/src/overlays/actors/ovl_En_Kakasi2/z_en_kakasi2.c b/soh/src/overlays/actors/ovl_En_Kakasi2/z_en_kakasi2.c index d3add65bb..618b8d897 100644 --- a/soh/src/overlays/actors/ovl_En_Kakasi2/z_en_kakasi2.c +++ b/soh/src/overlays/actors/ovl_En_Kakasi2/z_en_kakasi2.c @@ -245,7 +245,7 @@ void EnKakasi2_Update(Actor* thisx, PlayState* play2) { void func_80A90948(Actor* thisx, PlayState* play) { EnKakasi2* this = (EnKakasi2*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, NULL, this); } diff --git a/soh/src/overlays/actors/ovl_En_Kakasi3/z_en_kakasi3.c b/soh/src/overlays/actors/ovl_En_Kakasi3/z_en_kakasi3.c index 74eada74a..95b0e405f 100644 --- a/soh/src/overlays/actors/ovl_En_Kakasi3/z_en_kakasi3.c +++ b/soh/src/overlays/actors/ovl_En_Kakasi3/z_en_kakasi3.c @@ -436,7 +436,7 @@ void EnKakasi3_Update(Actor* thisx, PlayState* play) { void EnKakasi3_Draw(Actor* thisx, PlayState* play) { EnKakasi3* this = (EnKakasi3*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, NULL, this); } diff --git a/soh/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c b/soh/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c index af2c416f1..ea587972e 100644 --- a/soh/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c +++ b/soh/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c @@ -791,8 +791,8 @@ void EnKanban_Draw(Actor* thisx, PlayState* play) { u8* shadowTex = Graph_Alloc(play->state.gfxCtx, 0x400); OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_OPA_DISP++, object_kanban_DL_000C30); if (this->actionState != ENKANBAN_SIGN) { Matrix_Translate(this->actor.world.pos.x, this->actor.world.pos.y, this->actor.world.pos.z, MTXMODE_NEW); diff --git a/soh/src/overlays/actors/ovl_En_Karebaba/z_en_karebaba.c b/soh/src/overlays/actors/ovl_En_Karebaba/z_en_karebaba.c index b08465246..de209a242 100644 --- a/soh/src/overlays/actors/ovl_En_Karebaba/z_en_karebaba.c +++ b/soh/src/overlays/actors/ovl_En_Karebaba/z_en_karebaba.c @@ -445,7 +445,7 @@ void EnKarebaba_DrawBaseShadow(EnKarebaba* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80094044(play->state.gfxCtx); + Gfx_SetupDL_44Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 0, 0, 0, 255); func_80038A28(this->boundFloor, this->actor.home.pos.x, this->actor.home.pos.y, this->actor.home.pos.z, &mf); @@ -469,7 +469,7 @@ void EnKarebaba_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->actionFunc == EnKarebaba_DeadItemDrop) { if (this->actor.params > 40 || (this->actor.params & 1)) { diff --git a/soh/src/overlays/actors/ovl_En_Kz/z_en_kz.c b/soh/src/overlays/actors/ovl_En_Kz/z_en_kz.c index 337f136e9..4db606f9b 100644 --- a/soh/src/overlays/actors/ovl_En_Kz/z_en_kz.c +++ b/soh/src/overlays/actors/ovl_En_Kz/z_en_kz.c @@ -551,7 +551,7 @@ void EnKz_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeSegments[this->eyeIdx])); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelanime.skeleton, this->skelanime.jointTable, this->skelanime.dListCount, EnKz_OverrideLimbDraw, EnKz_PostLimbDraw, this); diff --git a/soh/src/overlays/actors/ovl_En_Light/z_en_light.c b/soh/src/overlays/actors/ovl_En_Light/z_en_light.c index 3d13d9b23..d7f9772d6 100644 --- a/soh/src/overlays/actors/ovl_En_Light/z_en_light.c +++ b/soh/src/overlays/actors/ovl_En_Light/z_en_light.c @@ -160,7 +160,7 @@ void EnLight_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->actor.params >= 0) { gSPSegment( diff --git a/soh/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c b/soh/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c index d7fdc8c4b..46cefe7f1 100644 --- a/soh/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c +++ b/soh/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c @@ -324,7 +324,7 @@ void EnMThunder_Draw(Actor* thisx, PlayState* play2) { s32 phi_t1; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Scale(0.02f, 0.02f, 0.02f, MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_En_Ma1/z_en_ma1.c b/soh/src/overlays/actors/ovl_En_Ma1/z_en_ma1.c index 30afcb2e7..02a68cd1a 100644 --- a/soh/src/overlays/actors/ovl_En_Ma1/z_en_ma1.c +++ b/soh/src/overlays/actors/ovl_En_Ma1/z_en_ma1.c @@ -568,7 +568,7 @@ void EnMa1_Draw(Actor* thisx, PlayState* play) { camera = GET_ACTIVE_CAM(play); distFromCamera = Math_Vec3f_DistXZ(&this->actor.world.pos, &camera->eye); func_800F6268(distFromCamera, NA_BGM_LONLON); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(sMouthTextures[this->mouthIndex])); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeIndex])); diff --git a/soh/src/overlays/actors/ovl_En_Ma2/z_en_ma2.c b/soh/src/overlays/actors/ovl_En_Ma2/z_en_ma2.c index ef5279aea..92c3bc029 100644 --- a/soh/src/overlays/actors/ovl_En_Ma2/z_en_ma2.c +++ b/soh/src/overlays/actors/ovl_En_Ma2/z_en_ma2.c @@ -382,7 +382,7 @@ void EnMa2_Draw(Actor* thisx, PlayState* play) { camera = GET_ACTIVE_CAM(play); someFloat = Math_Vec3f_DistXZ(&this->actor.world.pos, &camera->eye); func_800F6268(someFloat, NA_BGM_LONLON); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(sMouthTextures[this->mouthIndex])); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeIndex])); diff --git a/soh/src/overlays/actors/ovl_En_Ma3/z_en_ma3.c b/soh/src/overlays/actors/ovl_En_Ma3/z_en_ma3.c index 16a9e04ce..c0a0f2540 100644 --- a/soh/src/overlays/actors/ovl_En_Ma3/z_en_ma3.c +++ b/soh/src/overlays/actors/ovl_En_Ma3/z_en_ma3.c @@ -362,7 +362,7 @@ void EnMa3_Draw(Actor* thisx, PlayState* play) { camera = GET_ACTIVE_CAM(play); someFloat = Math_Vec3f_DistXZ(&this->actor.world.pos, &camera->eye); func_800F6268(someFloat, NA_BGM_LONLON); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(sMouthTextures[this->mouthIndex])); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeIndex])); diff --git a/soh/src/overlays/actors/ovl_En_Mag/z_en_mag.c b/soh/src/overlays/actors/ovl_En_Mag/z_en_mag.c index 5e10d0b9a..40b3ffbc1 100644 --- a/soh/src/overlays/actors/ovl_En_Mag/z_en_mag.c +++ b/soh/src/overlays/actors/ovl_En_Mag/z_en_mag.c @@ -608,7 +608,7 @@ void EnMag_DrawImageRGBA32(Gfx** gfxp, s16 centerX, s16 centerY, const char* sou source = ResourceMgr_LoadTexByName(source); - func_80094D28(&gfx); + Gfx_SetupDL_56Ptr(&gfx); curTexture = source; rectLeft = centerX - (width / 2); @@ -696,7 +696,7 @@ void EnMag_DrawInnerMq(Actor* thisx, PlayState* play, Gfx** gfxp) { gSPSegment(gfx++, 0x06, play->objectCtx.status[this->actor.objBankIndex].segment); - func_8009457C(&gfx); + Gfx_SetupDL_39Ptr(&gfx); this->effectScroll -= 2; @@ -726,7 +726,7 @@ void EnMag_DrawInnerMq(Actor* thisx, PlayState* play, Gfx** gfxp) { EnMag_DrawImageRGBA32(&gfx, 152, 100, (u8*)gTitleZeldaShieldLogoMQTex, 160, 160); } - func_8009457C(&gfx); + Gfx_SetupDL_39Ptr(&gfx); gDPPipeSync(gfx++); gDPSetAlphaCompare(gfx++, G_AC_NONE); @@ -758,7 +758,7 @@ void EnMag_DrawInnerMq(Actor* thisx, PlayState* play, Gfx** gfxp) { EnMag_DrawImageRGBA32(&gfx, 174, 145, "__OTR__objects/object_mag/gTitleMasterQuestSubtitleTex", 128, 32); } - func_8009457C(&gfx); + Gfx_SetupDL_39Ptr(&gfx); gDPSetAlphaCompare(gfx++, G_AC_NONE); gDPSetCombineMode(gfx++, G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM); @@ -886,7 +886,7 @@ void EnMag_DrawInnerVanilla(Actor* thisx, PlayState* play, Gfx** gfxp) { gSPSegment(gfx++, 0x06, play->objectCtx.status[this->actor.objBankIndex].segment); - func_8009457C(&gfx); + Gfx_SetupDL_39Ptr(&gfx); this->effectScroll -= 2; @@ -916,7 +916,7 @@ void EnMag_DrawInnerVanilla(Actor* thisx, PlayState* play, Gfx** gfxp) { EnMag_DrawImageRGBA32(&gfx, 160, 100, (u8*)gTitleZeldaShieldLogoTex, 160, 160); } - func_8009457C(&gfx); + Gfx_SetupDL_39Ptr(&gfx); gDPPipeSync(gfx++); gDPSetAlphaCompare(gfx++, G_AC_NONE); @@ -945,7 +945,7 @@ void EnMag_DrawInnerVanilla(Actor* thisx, PlayState* play, Gfx** gfxp) { } - func_8009457C(&gfx); + Gfx_SetupDL_39Ptr(&gfx); gDPSetAlphaCompare(gfx++, G_AC_NONE); gDPSetCombineMode(gfx++, G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM); diff --git a/soh/src/overlays/actors/ovl_En_Mb/z_en_mb.c b/soh/src/overlays/actors/ovl_En_Mb/z_en_mb.c index d700f8e97..4648e85f4 100644 --- a/soh/src/overlays/actors/ovl_En_Mb/z_en_mb.c +++ b/soh/src/overlays/actors/ovl_En_Mb/z_en_mb.c @@ -1525,7 +1525,7 @@ void EnMb_Draw(Actor* thisx, PlayState* play) { s32 bodyPartIdx; EnMb* this = (EnMb*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, EnMb_PostLimbDraw, thisx); diff --git a/soh/src/overlays/actors/ovl_En_Mk/z_en_mk.c b/soh/src/overlays/actors/ovl_En_Mk/z_en_mk.c index cbd96a305..8fc28530a 100644 --- a/soh/src/overlays/actors/ovl_En_Mk/z_en_mk.c +++ b/soh/src/overlays/actors/ovl_En_Mk/z_en_mk.c @@ -394,7 +394,7 @@ void EnMk_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void EnMk_Draw(Actor* thisx, PlayState* play) { EnMk* this = (EnMk*)thisx; - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnMk_OverrideLimbDraw, EnMk_PostLimbDraw, &this->actor); } diff --git a/soh/src/overlays/actors/ovl_En_Mm/z_en_mm.c b/soh/src/overlays/actors/ovl_En_Mm/z_en_mm.c index c2b7908a9..ce31cf2c7 100644 --- a/soh/src/overlays/actors/ovl_En_Mm/z_en_mm.c +++ b/soh/src/overlays/actors/ovl_En_Mm/z_en_mm.c @@ -517,7 +517,7 @@ void EnMm_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(mouthTextures[this->mouthTexIndex])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnMm_OverrideLimbDraw, EnMm_PostLimbDraw, this); diff --git a/soh/src/overlays/actors/ovl_En_Mm2/z_en_mm2.c b/soh/src/overlays/actors/ovl_En_Mm2/z_en_mm2.c index 3eaa81e22..d48517704 100644 --- a/soh/src/overlays/actors/ovl_En_Mm2/z_en_mm2.c +++ b/soh/src/overlays/actors/ovl_En_Mm2/z_en_mm2.c @@ -311,7 +311,7 @@ void EnMm2_Draw(Actor* thisx, PlayState* play) { EnMm2* this = (EnMm2*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(mouthTextures[this->mouthTexIndex])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnMm2_OverrideLimbDraw, EnMm2_PostLimbDraw, this); diff --git a/soh/src/overlays/actors/ovl_En_Ms/z_en_ms.c b/soh/src/overlays/actors/ovl_En_Ms/z_en_ms.c index 67f418340..074b48097 100644 --- a/soh/src/overlays/actors/ovl_En_Ms/z_en_ms.c +++ b/soh/src/overlays/actors/ovl_En_Ms/z_en_ms.c @@ -196,7 +196,7 @@ void EnMs_Update(Actor* thisx, PlayState* play) { void EnMs_Draw(Actor* thisx, PlayState* play) { EnMs* this = (EnMs*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, NULL, this); } diff --git a/soh/src/overlays/actors/ovl_En_Nb/z_en_nb.c b/soh/src/overlays/actors/ovl_En_Nb/z_en_nb.c index 0ca410779..08f31e18c 100644 --- a/soh/src/overlays/actors/ovl_En_Nb/z_en_nb.c +++ b/soh/src/overlays/actors/ovl_En_Nb/z_en_nb.c @@ -549,7 +549,7 @@ void EnNb_DrawTransparency(EnNb* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTex)); gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTex)); gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->alpha); @@ -957,7 +957,7 @@ void func_80AB2E70(EnNb* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(gNabooruEyeWideTex)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(gNabooruEyeWideTex)); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255); @@ -987,7 +987,7 @@ void func_80AB2FE4(EnNb* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTexture)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTexture)); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255); @@ -1502,7 +1502,7 @@ void EnNb_DrawDefault(EnNb* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTexture)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTexture)); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255); diff --git a/soh/src/overlays/actors/ovl_En_Niw/z_en_niw.c b/soh/src/overlays/actors/ovl_En_Niw/z_en_niw.c index c85de58ed..6659350ff 100644 --- a/soh/src/overlays/actors/ovl_En_Niw/z_en_niw.c +++ b/soh/src/overlays/actors/ovl_En_Niw/z_en_niw.c @@ -1135,7 +1135,7 @@ void EnNiw_Draw(Actor* thisx, PlayState* play) { Vec3f scale = { 0.15f, 0.15f, 0.15f }; GraphicsContext* gfxCtx = play->state.gfxCtx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnNiw_OverrideLimbDraw, NULL, this); @@ -1206,7 +1206,7 @@ void EnNiw_FeatherDraw(EnNiw* this, PlayState* play) { OPEN_DISPS(gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->feathers); i++, feather++) { if (feather->type == 1) { diff --git a/soh/src/overlays/actors/ovl_En_Niw_Girl/z_en_niw_girl.c b/soh/src/overlays/actors/ovl_En_Niw_Girl/z_en_niw_girl.c index 2d0393035..ad948a91b 100644 --- a/soh/src/overlays/actors/ovl_En_Niw_Girl/z_en_niw_girl.c +++ b/soh/src/overlays/actors/ovl_En_Niw_Girl/z_en_niw_girl.c @@ -253,7 +253,7 @@ void EnNiwGirl_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeIndex])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnNiwGirlOverrideLimbDraw, NULL, this); diff --git a/soh/src/overlays/actors/ovl_En_Niw_Lady/z_en_niw_lady.c b/soh/src/overlays/actors/ovl_En_Niw_Lady/z_en_niw_lady.c index 0a17fb10f..0cff223ae 100644 --- a/soh/src/overlays/actors/ovl_En_Niw_Lady/z_en_niw_lady.c +++ b/soh/src/overlays/actors/ovl_En_Niw_Lady/z_en_niw_lady.c @@ -607,7 +607,7 @@ void EnNiwLady_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->unk_27E != 0) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->faceState])); gSPSegment(POLY_OPA_DISP++, 0x0C, func_80ABB0A0(play->state.gfxCtx)); diff --git a/soh/src/overlays/actors/ovl_En_Nutsball/z_en_nutsball.c b/soh/src/overlays/actors/ovl_En_Nutsball/z_en_nutsball.c index f75436f31..9b4696f94 100644 --- a/soh/src/overlays/actors/ovl_En_Nutsball/z_en_nutsball.c +++ b/soh/src/overlays/actors/ovl_En_Nutsball/z_en_nutsball.c @@ -173,7 +173,7 @@ void EnNutsball_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (CVar_GetS32("gNewDrops", 0) != 0) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 6), 1 * (play->state.frames * 6), 32, 32, 1, 1 * (play->state.frames * 6), @@ -184,7 +184,7 @@ void EnNutsball_Draw(Actor* thisx, PlayState* play) { G_MTX_MODELVIEW | G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, sDListsNew[thisx->params]); } else { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Mult(&play->billboardMtxF, MTXMODE_APPLY); Matrix_RotateZ(thisx->home.rot.z * 9.58738e-05f, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_En_Nwc/z_en_nwc.c b/soh/src/overlays/actors/ovl_En_Nwc/z_en_nwc.c index d07d97f21..38aff1f83 100644 --- a/soh/src/overlays/actors/ovl_En_Nwc/z_en_nwc.c +++ b/soh/src/overlays/actors/ovl_En_Nwc/z_en_nwc.c @@ -188,7 +188,7 @@ void EnNwc_DrawChicks(EnNwc* this, PlayState* play) { chick = this->chicks; POLY_XLU_DISP = dList3; - func_80094044(play->state.gfxCtx); + Gfx_SetupDL_44Xlu(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, gCuccoChickSetupShadowDL); for (i = 0; i < this->count; i++, chick++) { diff --git a/soh/src/overlays/actors/ovl_En_Ny/z_en_ny.c b/soh/src/overlays/actors/ovl_En_Ny/z_en_ny.c index 94f21f314..725064e21 100644 --- a/soh/src/overlays/actors/ovl_En_Ny/z_en_ny.c +++ b/soh/src/overlays/actors/ovl_En_Ny/z_en_ny.c @@ -530,7 +530,7 @@ void EnNy_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); Collider_UpdateSpheres(0, &this->collider); func_8002ED80(&this->actor, play, 1); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gDPPipeSync(POLY_XLU_DISP++); @@ -544,7 +544,7 @@ void EnNy_Draw(Actor* thisx, PlayState* play) { if (this->unk_1E0 > 0.25f) { Matrix_Scale(this->unk_1E0, this->unk_1E0, this->unk_1E0, MTXMODE_APPLY); func_8002EBCC(&this->actor, play, 1); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gEnNySpikeDL); @@ -574,7 +574,7 @@ void EnNy_DrawDeathEffect(Actor* thisx, PlayState* play) { s32 i; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 0x00, 0x00, 0x00, 0xFF); gDPSetRenderMode(POLY_OPA_DISP++, G_RM_FOG_SHADE_A, G_RM_AA_ZB_OPA_SURF2); gDPPipeSync(POLY_OPA_DISP++); diff --git a/soh/src/overlays/actors/ovl_En_Okuta/z_en_okuta.c b/soh/src/overlays/actors/ovl_En_Okuta/z_en_okuta.c index 6aa61d905..7464ecb25 100644 --- a/soh/src/overlays/actors/ovl_En_Okuta/z_en_okuta.c +++ b/soh/src/overlays/actors/ovl_En_Okuta/z_en_okuta.c @@ -750,7 +750,7 @@ void EnOkuta_Draw(Actor* thisx, PlayState* play) { EnOkuta* this = (EnOkuta*)thisx; s32 pad; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->actor.params == 0) { SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnOkuta_OverrideLimbDraw, @@ -759,7 +759,7 @@ void EnOkuta_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (CVar_GetS32("gNewDrops", 0) != 0) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 6), 1 * (play->state.frames * 6), 32, 32, 1, 1 * (play->state.frames * 6), diff --git a/soh/src/overlays/actors/ovl_En_Ossan/z_en_ossan.c b/soh/src/overlays/actors/ovl_En_Ossan/z_en_ossan.c index 2d45be35d..14551987f 100644 --- a/soh/src/overlays/actors/ovl_En_Ossan/z_en_ossan.c +++ b/soh/src/overlays/actors/ovl_En_Ossan/z_en_ossan.c @@ -2326,7 +2326,7 @@ void EnOssan_DrawCursor(PlayState* play, EnOssan* this, f32 x, f32 y, f32 z, u8 OPEN_DISPS(play->state.gfxCtx); if (drawCursor != 0) { - func_80094520(play->state.gfxCtx); + Gfx_SetupDL_39Overlay(play->state.gfxCtx); gDPSetPrimColor(OVERLAY_DISP++, 0, 0, this->cursorColorR, this->cursorColorG, this->cursorColorB, this->cursorColorA); gDPLoadTextureBlock_4b(OVERLAY_DISP++, gSelectionCursorTex, G_IM_FMT_IA, 16, 16, 0, G_TX_MIRROR | G_TX_WRAP, @@ -2373,7 +2373,7 @@ void EnOssan_DrawStickDirectionPrompts(PlayState* play, EnOssan* this) { OPEN_DISPS(play->state.gfxCtx); if (drawStickLeftPrompt || drawStickRightPrompt) { - func_80094520(play->state.gfxCtx); + Gfx_SetupDL_39Overlay(play->state.gfxCtx); gDPSetCombineMode(OVERLAY_DISP++, G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM); gDPLoadTextureBlock(OVERLAY_DISP++, gArrowCursorTex, G_IM_FMT_IA, G_IM_SIZ_8b, 16, 24, 0, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP, 4, G_TX_NOMASK, G_TX_NOLOD, @@ -2416,7 +2416,7 @@ void EnOssan_DrawBazaarShopkeeper(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sBazaarShopkeeperEyeTextures[this->eyeTextureIdx])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnOssan_OverrideLimbDrawDefaultShopkeeper, NULL, this); @@ -2471,7 +2471,7 @@ void EnOssan_DrawKokiriShopkeeper(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255); gSPSegment(POLY_OPA_DISP++, 0x08, EnOssan_SetEnvColor(play->state.gfxCtx, 0, 130, 70, 255)); gSPSegment(POLY_OPA_DISP++, 0x09, EnOssan_SetEnvColor(play->state.gfxCtx, 110, 170, 20, 255)); @@ -2492,7 +2492,7 @@ void EnOssan_DrawGoronShopkeeper(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sGoronShopkeeperEyeTextures[this->eyeTextureIdx])); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(gGoronCsMouthNeutralTex)); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, @@ -2520,7 +2520,7 @@ void EnOssan_DrawZoraShopkeeper(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255); gSPSegment(POLY_OPA_DISP++, 0x0C, EnOssan_EndDList(play->state.gfxCtx)); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sZoraShopkeeperEyeTextures[this->eyeTextureIdx])); @@ -2541,7 +2541,7 @@ void EnOssan_DrawPotionShopkeeper(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sPotionShopkeeperEyeTextures[this->eyeTextureIdx])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, NULL, this); @@ -2558,7 +2558,7 @@ void EnOssan_DrawHappyMaskShopkeeper(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sHappyMaskShopkeeperEyeTextures[this->happyMaskShopkeeperEyeIdx])); @@ -2578,7 +2578,7 @@ void EnOssan_DrawBombchuShopkeeper(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sBombchuShopkeeperEyeTextures[this->eyeTextureIdx])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, diff --git a/soh/src/overlays/actors/ovl_En_Owl/z_en_owl.c b/soh/src/overlays/actors/ovl_En_Owl/z_en_owl.c index c971f8844..065ac7088 100644 --- a/soh/src/overlays/actors/ovl_En_Owl/z_en_owl.c +++ b/soh/src/overlays/actors/ovl_En_Owl/z_en_owl.c @@ -1349,7 +1349,7 @@ void EnOwl_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 8, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeTexIndex])); SkelAnime_DrawFlexOpa(play, this->curSkelAnime->skeleton, this->curSkelAnime->jointTable, this->curSkelAnime->dListCount, EnOwl_OverrideLimbDraw, EnOwl_PostLimbUpdate, this); diff --git a/soh/src/overlays/actors/ovl_En_Part/z_en_part.c b/soh/src/overlays/actors/ovl_En_Part/z_en_part.c index 8088b87ea..9a40e7f7f 100644 --- a/soh/src/overlays/actors/ovl_En_Part/z_en_part.c +++ b/soh/src/overlays/actors/ovl_En_Part/z_en_part.c @@ -282,7 +282,7 @@ void EnPart_Draw(Actor* thisx, PlayState* play) { Matrix_RotateZ(this->rotZ, MTXMODE_APPLY); } - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_8002EBCC(thisx, play, 0); if (thisx->params == 5) { diff --git a/soh/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c b/soh/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c index 13857fd9a..bab73e337 100644 --- a/soh/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c +++ b/soh/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c @@ -1073,7 +1073,7 @@ void EnPeehat_Draw(Actor* thisx, PlayState* play) { }; EnPeehat* this = (EnPeehat*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnPeehat_OverrideLimbDraw, EnPeehat_PostLimbDraw, this); if (this->actor.speedXZ != 0.0f || this->actor.velocity.y != 0.0f) { diff --git a/soh/src/overlays/actors/ovl_En_Po_Desert/z_en_po_desert.c b/soh/src/overlays/actors/ovl_En_Po_Desert/z_en_po_desert.c index 869184a37..b5771c87d 100644 --- a/soh/src/overlays/actors/ovl_En_Po_Desert/z_en_po_desert.c +++ b/soh/src/overlays/actors/ovl_En_Po_Desert/z_en_po_desert.c @@ -255,7 +255,7 @@ void EnPoDesert_Draw(Actor* thisx, PlayState* play) { EnPoDesert* this = (EnPoDesert*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x0A, Gfx_EnvColor(play->state.gfxCtx, 255, 85, 0, 255)); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_EnvColor(play->state.gfxCtx, this->lightColor.r, this->lightColor.g, this->lightColor.b, diff --git a/soh/src/overlays/actors/ovl_En_Po_Field/z_en_po_field.c b/soh/src/overlays/actors/ovl_En_Po_Field/z_en_po_field.c index d1722a53d..c7e8bf877 100644 --- a/soh/src/overlays/actors/ovl_En_Po_Field/z_en_po_field.c +++ b/soh/src/overlays/actors/ovl_En_Po_Field/z_en_po_field.c @@ -789,7 +789,7 @@ void EnPoField_DrawFlame(EnPoField* this, PlayState* play) { if (this->flameTimer != 0) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (play->gameplayFrames * -20) % 512, 32, 128)); @@ -935,8 +935,8 @@ void EnPoField_Draw(Actor* thisx, PlayState* play) { if (this->actionFunc != EnPoField_WaitForSpawn) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x0A, Gfx_EnvColor(play->state.gfxCtx, info->envColor.r, info->envColor.g, info->envColor.b, 255)); if (this->lightColor.a == 255 || this->lightColor.a == 0) { @@ -985,7 +985,7 @@ void EnPoField_DrawSoul(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->actionFunc == EnPoField_SoulIdle) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x0A, Gfx_EnvColor(play->state.gfxCtx, info->envColor.r, info->envColor.g, info->envColor.b, 255)); Lights_PointGlowSetInfo(&this->lightInfo, this->actor.world.pos.x, this->actor.world.pos.y, @@ -996,7 +996,7 @@ void EnPoField_DrawSoul(Actor* thisx, PlayState* play) { gSPDisplayList(POLY_OPA_DISP++, gPoeFieldLanternDL); gSPDisplayList(POLY_OPA_DISP++, gPoeFieldLanternTopDL); } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, (play->gameplayFrames * info->unk_9) & 0x1FF, 0x20, 0x80)); diff --git a/soh/src/overlays/actors/ovl_En_Po_Relay/z_en_po_relay.c b/soh/src/overlays/actors/ovl_En_Po_Relay/z_en_po_relay.c index 1efbdf7ea..f6112e646 100644 --- a/soh/src/overlays/actors/ovl_En_Po_Relay/z_en_po_relay.c +++ b/soh/src/overlays/actors/ovl_En_Po_Relay/z_en_po_relay.c @@ -429,7 +429,7 @@ void EnPoRelay_Draw(Actor* thisx, PlayState* play) { EnPoRelay* this = (EnPoRelay*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyesTextures[this->eyeTextureIdx])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, NULL, EnPoRelay_PostLimbDraw, &this->actor); diff --git a/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c b/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c index 973e2ff71..16e231e83 100644 --- a/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c +++ b/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c @@ -1365,8 +1365,8 @@ void EnPoSisters_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); func_80ADC55C(this); - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->unk_22E.a == 255 || this->unk_22E.a == 0) { gDPSetEnvColor(POLY_OPA_DISP++, this->unk_22E.r, this->unk_22E.g, this->unk_22E.b, this->unk_22E.a); gSPSegment(POLY_OPA_DISP++, 0x09, D_80116280 + 2); diff --git a/soh/src/overlays/actors/ovl_En_Poh/z_en_poh.c b/soh/src/overlays/actors/ovl_En_Poh/z_en_poh.c index 59c34d5d8..117752a8e 100644 --- a/soh/src/overlays/actors/ovl_En_Poh/z_en_poh.c +++ b/soh/src/overlays/actors/ovl_En_Poh/z_en_poh.c @@ -1081,8 +1081,8 @@ void EnPoh_DrawRegular(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); func_80AE067C(this); - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->lightColor.a == 255 || this->lightColor.a == 0) { gDPSetEnvColor(POLY_OPA_DISP++, this->lightColor.r, this->lightColor.g, this->lightColor.b, this->lightColor.a); gSPSegment(POLY_OPA_DISP++, 0x08, D_80116280 + 2); @@ -1118,7 +1118,7 @@ void EnPoh_DrawComposer(Actor* thisx, PlayState* play) { phi_t0 = &D_80AE1B58; } if (this->lightColor.a == 255 || this->lightColor.a == 0) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_EnvColor(play->state.gfxCtx, this->lightColor.r, this->lightColor.g, this->lightColor.b, this->lightColor.a)); @@ -1131,8 +1131,8 @@ void EnPoh_DrawComposer(Actor* thisx, PlayState* play) { this->skelAnime.dListCount, EnPoh_OverrideLimbDraw, EnPoh_PostLimbDraw, &this->actor, POLY_OPA_DISP); } else { - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_EnvColor(play->state.gfxCtx, this->lightColor.r, this->lightColor.g, this->lightColor.b, this->lightColor.a)); @@ -1174,7 +1174,7 @@ void EnPoh_DrawSoul(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->actionFunc == EnPoh_Death) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, this->envColor.r, this->envColor.g, this->envColor.b, 255); Lights_PointGlowSetInfo(&this->lightInfo, this->actor.world.pos.x, this->actor.world.pos.y, this->actor.world.pos.z, this->envColor.r, this->envColor.g, this->envColor.b, 200); @@ -1191,7 +1191,7 @@ void EnPoh_DrawSoul(Actor* thisx, PlayState* play) { gSPDisplayList(POLY_OPA_DISP++, gPoeComposerLanternTopDL); } } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, (this->visibilityTimer * this->info->unk_8) % 512U, 0x20, 0x80)); diff --git a/soh/src/overlays/actors/ovl_En_Rd/z_en_rd.c b/soh/src/overlays/actors/ovl_En_Rd/z_en_rd.c index 1b9852c97..332fc59af 100644 --- a/soh/src/overlays/actors/ovl_En_Rd/z_en_rd.c +++ b/soh/src/overlays/actors/ovl_En_Rd/z_en_rd.c @@ -902,7 +902,7 @@ void EnRd_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->unk_314 == 0xFF) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, this->unk_314); gSPSegment(POLY_OPA_DISP++, 8, &D_80116280[2]); POLY_OPA_DISP = SkelAnime_DrawFlex(play, this->skelAnime.skeleton, this->skelAnime.jointTable, @@ -918,7 +918,7 @@ void EnRd_Draw(Actor* thisx, PlayState* play) { } } } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->unk_314); gSPSegment(POLY_XLU_DISP++, 8, &D_80116280[0]); POLY_XLU_DISP = diff --git a/soh/src/overlays/actors/ovl_En_Reeba/z_en_reeba.c b/soh/src/overlays/actors/ovl_En_Reeba/z_en_reeba.c index e691828cf..9015f3407 100644 --- a/soh/src/overlays/actors/ovl_En_Reeba/z_en_reeba.c +++ b/soh/src/overlays/actors/ovl_En_Reeba/z_en_reeba.c @@ -660,7 +660,7 @@ void EnReeba_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->isBig) { gDPSetPrimColor(POLY_OPA_DISP++, 0x0, 0x01, 155, 55, 255, 255); diff --git a/soh/src/overlays/actors/ovl_En_Rl/z_en_rl.c b/soh/src/overlays/actors/ovl_En_Rl/z_en_rl.c index 7e4cef134..00fd5fac4 100644 --- a/soh/src/overlays/actors/ovl_En_Rl/z_en_rl.c +++ b/soh/src/overlays/actors/ovl_En_Rl/z_en_rl.c @@ -303,7 +303,7 @@ void func_80AE7D94(EnRl* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(tex)); gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(tex)); @@ -352,7 +352,7 @@ void func_80AE7FDC(EnRl* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(tex)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(tex)); diff --git a/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c b/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c index 237b87d9d..82eb2c93e 100644 --- a/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c +++ b/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c @@ -847,7 +847,7 @@ void EnRr_Draw(Actor* thisx, PlayState* play) { Mtx* segMtx = Graph_Alloc(play->state.gfxCtx, 4 * sizeof(Mtx)); OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x0C, segMtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, (this->scrollTimer * 0) & 0x7F, diff --git a/soh/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c b/soh/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c index d500345fc..bce28e045 100644 --- a/soh/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c +++ b/soh/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c @@ -2325,7 +2325,7 @@ void EnRu1_DrawOpa(EnRu1* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTex)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTex)); @@ -2350,7 +2350,7 @@ void EnRu1_DrawXlu(EnRu1* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTex)); gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTex)); diff --git a/soh/src/overlays/actors/ovl_En_Ru2/z_en_ru2.c b/soh/src/overlays/actors/ovl_En_Ru2/z_en_ru2.c index c269935b2..697871524 100644 --- a/soh/src/overlays/actors/ovl_En_Ru2/z_en_ru2.c +++ b/soh/src/overlays/actors/ovl_En_Ru2/z_en_ru2.c @@ -474,7 +474,7 @@ void func_80AF321C(EnRu2* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(tex)); gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(tex)); @@ -804,7 +804,7 @@ void func_80AF3F20(EnRu2* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(tex)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(tex)); diff --git a/soh/src/overlays/actors/ovl_En_Scene_Change/z_en_scene_change.c b/soh/src/overlays/actors/ovl_En_Scene_Change/z_en_scene_change.c index eb7ebe5ee..be98c6bf4 100644 --- a/soh/src/overlays/actors/ovl_En_Scene_Change/z_en_scene_change.c +++ b/soh/src/overlays/actors/ovl_En_Scene_Change/z_en_scene_change.c @@ -63,7 +63,7 @@ void EnSceneChange_Draw(Actor* thisx, PlayState* play) { displayListHead = displayList; gSPSegment(POLY_OPA_DISP++, 0x0C, displayListHead); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); CLOSE_DISPS(play->state.gfxCtx); } diff --git a/soh/src/overlays/actors/ovl_En_Sda/z_en_sda.c b/soh/src/overlays/actors/ovl_En_Sda/z_en_sda.c index a24355447..c2bb03643 100644 --- a/soh/src/overlays/actors/ovl_En_Sda/z_en_sda.c +++ b/soh/src/overlays/actors/ovl_En_Sda/z_en_sda.c @@ -342,7 +342,7 @@ void func_80AF9C70(u8* shadowTexture, Player* player, PlayState* play) { OPEN_DISPS(gfxCtx); osSyncPrintf("SDA D 1\n"); - func_80094044(play->state.gfxCtx); + Gfx_SetupDL_44Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0x00, 0x00, 0, 0, 0, (BREG(52) + 50)); gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, 0); Matrix_Translate(player->actor.world.pos.x, player->actor.floorHeight, player->actor.world.pos.z, MTXMODE_NEW); diff --git a/soh/src/overlays/actors/ovl_En_Siofuki/z_en_siofuki.c b/soh/src/overlays/actors/ovl_En_Siofuki/z_en_siofuki.c index 7ec825985..3d8f68886 100644 --- a/soh/src/overlays/actors/ovl_En_Siofuki/z_en_siofuki.c +++ b/soh/src/overlays/actors/ovl_En_Siofuki/z_en_siofuki.c @@ -283,7 +283,7 @@ void EnSiofuki_Draw(Actor* thisx, PlayState* play) { u32 gameplayFrames = play->gameplayFrames; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Translate(0.0f, this->unk_170, 0.0f, MTXMODE_APPLY); Matrix_Scale(1.0f, 1.0f, 1.0f, MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), diff --git a/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c b/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c index 975714fa0..8d58e8175 100644 --- a/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c +++ b/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c @@ -550,7 +550,7 @@ void EnSkb_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void EnSkb_Draw(Actor* thisx, PlayState* play) { EnSkb* this = (EnSkb*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnSkb_OverrideLimbDraw, EnSkb_PostLimbDraw, &this->actor); } diff --git a/soh/src/overlays/actors/ovl_En_Skj/z_en_skj.c b/soh/src/overlays/actors/ovl_En_Skj/z_en_skj.c index 652ad64fe..56f389d73 100644 --- a/soh/src/overlays/actors/ovl_En_Skj/z_en_skj.c +++ b/soh/src/overlays/actors/ovl_En_Skj/z_en_skj.c @@ -1629,7 +1629,7 @@ void EnSkj_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, OPEN_DISPS(play->state.gfxCtx); if ((limbIndex == 11) && (gSaveContext.itemGetInf[3] & 0x200)) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Push(); Matrix_RotateZYX(-0x4000, 0, 0, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), @@ -1672,7 +1672,7 @@ void EnSkj_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->alpha < 255) { gSPSegment(POLY_OPA_DISP++, 0x0C, EnSkj_TranslucentDL(play->state.gfxCtx, this->alpha)); diff --git a/soh/src/overlays/actors/ovl_En_Skjneedle/z_en_skjneedle.c b/soh/src/overlays/actors/ovl_En_Skjneedle/z_en_skjneedle.c index e1bf69b1d..a802fedd0 100644 --- a/soh/src/overlays/actors/ovl_En_Skjneedle/z_en_skjneedle.c +++ b/soh/src/overlays/actors/ovl_En_Skjneedle/z_en_skjneedle.c @@ -103,7 +103,7 @@ void EnSkjneedle_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gSkullKidNeedleDL); diff --git a/soh/src/overlays/actors/ovl_En_St/z_en_st.c b/soh/src/overlays/actors/ovl_En_St/z_en_st.c index 70a7edf80..c9de2bb59 100644 --- a/soh/src/overlays/actors/ovl_En_St/z_en_st.c +++ b/soh/src/overlays/actors/ovl_En_St/z_en_st.c @@ -1088,7 +1088,7 @@ void EnSt_Draw(Actor* thisx, PlayState* play) { EnSt* this = (EnSt*)thisx; EnSt_CheckBodyStickHit(this, play); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnSt_OverrideLimbDraw, EnSt_PostLimbDraw, this); } diff --git a/soh/src/overlays/actors/ovl_En_Sth/z_en_sth.c b/soh/src/overlays/actors/ovl_En_Sth/z_en_sth.c index ed18e0956..cdfd90efc 100644 --- a/soh/src/overlays/actors/ovl_En_Sth/z_en_sth.c +++ b/soh/src/overlays/actors/ovl_En_Sth/z_en_sth.c @@ -423,7 +423,7 @@ void EnSth_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); gSegments[6] = PHYSICAL_TO_VIRTUAL(play->objectCtx.status[this->objectBankIdx].segment); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, EnSth_AllocColorDList(play->state.gfxCtx, sTunicColors[this->actor.params].r, diff --git a/soh/src/overlays/actors/ovl_En_Stream/z_en_stream.c b/soh/src/overlays/actors/ovl_En_Stream/z_en_stream.c index e34b24ca9..661145c33 100644 --- a/soh/src/overlays/actors/ovl_En_Stream/z_en_stream.c +++ b/soh/src/overlays/actors/ovl_En_Stream/z_en_stream.c @@ -133,7 +133,7 @@ void EnStream_Draw(Actor* thisx, PlayState* play) { u32 frames = play->gameplayFrames; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); multipliedFrames = frames * 20; diff --git a/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c b/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c index b50398b45..732cfec51 100644 --- a/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c +++ b/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c @@ -1012,7 +1012,7 @@ void EnSw_Draw(Actor* thisx, PlayState* play) { func_80B0EDB8(play, &sp30, 0x14, 0x1E); } - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnSw_OverrideLimbDraw, EnSw_PostLimbDraw, this); if (this->actionFunc == func_80B0E728) { diff --git a/soh/src/overlays/actors/ovl_En_Syateki_Man/z_en_syateki_man.c b/soh/src/overlays/actors/ovl_En_Syateki_Man/z_en_syateki_man.c index c489f869a..117abcee8 100644 --- a/soh/src/overlays/actors/ovl_En_Syateki_Man/z_en_syateki_man.c +++ b/soh/src/overlays/actors/ovl_En_Syateki_Man/z_en_syateki_man.c @@ -536,7 +536,7 @@ void EnSyatekiMan_Draw(Actor* thisx, PlayState* play) { s32 pad; EnSyatekiMan* this = (EnSyatekiMan*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnSyatekiMan_OverrideLimbDraw, NULL, this); } diff --git a/soh/src/overlays/actors/ovl_En_Syateki_Niw/z_en_syateki_niw.c b/soh/src/overlays/actors/ovl_En_Syateki_Niw/z_en_syateki_niw.c index c270b2a1b..cfbe70085 100644 --- a/soh/src/overlays/actors/ovl_En_Syateki_Niw/z_en_syateki_niw.c +++ b/soh/src/overlays/actors/ovl_En_Syateki_Niw/z_en_syateki_niw.c @@ -696,7 +696,7 @@ void EnSyatekiNiw_Draw(Actor* thisx, PlayState* play) { Color_RGBA8 sp30 = { 0, 0, 0, 255 }; if (this->actionFunc != func_80B128F8) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->unk_260 != 0) { func_80026230(play, &sp30, 0, 0x14); } @@ -766,7 +766,7 @@ void func_80B13464(EnSyatekiNiw* this, PlayState* play) { OPEN_DISPS(gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < 5; i++, ptr++) { if (ptr->unk_00 == 1) { diff --git a/soh/src/overlays/actors/ovl_En_Ta/z_en_ta.c b/soh/src/overlays/actors/ovl_En_Ta/z_en_ta.c index 93fb532eb..17a83eb18 100644 --- a/soh/src/overlays/actors/ovl_En_Ta/z_en_ta.c +++ b/soh/src/overlays/actors/ovl_En_Ta/z_en_ta.c @@ -1226,7 +1226,7 @@ void EnTa_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x8, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeIndex])); gSPSegment(POLY_OPA_DISP++, 0x9, SEGMENTED_TO_VIRTUAL(gTalonHeadSkinTex)); diff --git a/soh/src/overlays/actors/ovl_En_Takara_Man/z_en_takara_man.c b/soh/src/overlays/actors/ovl_En_Takara_Man/z_en_takara_man.c index 36aa5af68..c3967d9b3 100644 --- a/soh/src/overlays/actors/ovl_En_Takara_Man/z_en_takara_man.c +++ b/soh/src/overlays/actors/ovl_En_Takara_Man/z_en_takara_man.c @@ -222,7 +222,7 @@ void EnTakaraMan_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeTextureIdx])); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnTakaraMan_OverrideLimbDraw, NULL, this); diff --git a/soh/src/overlays/actors/ovl_En_Tana/z_en_tana.c b/soh/src/overlays/actors/ovl_En_Tana/z_en_tana.c index 2d492ef0e..ff17deabd 100644 --- a/soh/src/overlays/actors/ovl_En_Tana/z_en_tana.c +++ b/soh/src/overlays/actors/ovl_En_Tana/z_en_tana.c @@ -75,7 +75,7 @@ void EnTana_DrawWoodenShelves(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, sShelfDLists[thisx->params]); @@ -88,7 +88,7 @@ void EnTana_DrawStoneShelves(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sStoneTextures[thisx->params])); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_En_Test/z_en_test.c b/soh/src/overlays/actors/ovl_En_Test/z_en_test.c index 002c5540b..e30f94c48 100644 --- a/soh/src/overlays/actors/ovl_En_Test/z_en_test.c +++ b/soh/src/overlays/actors/ovl_En_Test/z_en_test.c @@ -1950,7 +1950,7 @@ void EnTest_PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot void EnTest_Draw(Actor* thisx, PlayState* play) { EnTest* this = (EnTest*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); func_8002EBCC(&this->actor, play, 1); if ((thisx->params <= STALFOS_TYPE_CEILING) || (thisx->child == NULL)) { diff --git a/soh/src/overlays/actors/ovl_En_Tite/z_en_tite.c b/soh/src/overlays/actors/ovl_En_Tite/z_en_tite.c index 546275d2e..f64d81163 100644 --- a/soh/src/overlays/actors/ovl_En_Tite/z_en_tite.c +++ b/soh/src/overlays/actors/ovl_En_Tite/z_en_tite.c @@ -982,7 +982,7 @@ void EnTite_Draw(Actor* thisx, PlayState* play) { EnTite* this = (EnTite*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Collider_UpdateSpheres(0, &this->collider); if (this->actor.params == TEKTITE_BLUE) { gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(object_tite_Tex_001300)); diff --git a/soh/src/overlays/actors/ovl_En_Tk/z_en_tk.c b/soh/src/overlays/actors/ovl_En_Tk/z_en_tk.c index dafff3010..b7b369a0b 100644 --- a/soh/src/overlays/actors/ovl_En_Tk/z_en_tk.c +++ b/soh/src/overlays/actors/ovl_En_Tk/z_en_tk.c @@ -98,12 +98,12 @@ void EnTkEff_Draw(EnTk* this, PlayState* play) { gfxSetup = 0; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->eff); i++) { if (eff->active != 0) { if (gfxSetup == 0) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0); gSPDisplayList(POLY_XLU_DISP++, gDampeEff1DL); gDPSetEnvColor(POLY_XLU_DISP++, 100, 60, 20, 0); gfxSetup = 1; @@ -776,7 +776,7 @@ void EnTk_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyesSegments[this->eyeTextureIdx])); diff --git a/soh/src/overlays/actors/ovl_En_Torch2/z_en_torch2.c b/soh/src/overlays/actors/ovl_En_Torch2/z_en_torch2.c index d5a8209df..a5f11cf72 100644 --- a/soh/src/overlays/actors/ovl_En_Torch2/z_en_torch2.c +++ b/soh/src/overlays/actors/ovl_En_Torch2/z_en_torch2.c @@ -773,7 +773,7 @@ void EnTorch2_Draw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); func_80093C80(play); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (sAlpha == 255) { gDPSetEnvColor(POLY_OPA_DISP++, 255, 0, 0, sAlpha); gSPSegment(POLY_OPA_DISP++, 0x0C, D_80116280 + 2); diff --git a/soh/src/overlays/actors/ovl_En_Toryo/z_en_toryo.c b/soh/src/overlays/actors/ovl_En_Toryo/z_en_toryo.c index da611dfd7..2fdfd407f 100644 --- a/soh/src/overlays/actors/ovl_En_Toryo/z_en_toryo.c +++ b/soh/src/overlays/actors/ovl_En_Toryo/z_en_toryo.c @@ -388,7 +388,7 @@ void EnToryo_Update(Actor* thisx, PlayState* play) { void EnToryo_Draw(Actor* thisx, PlayState* play) { EnToryo* this = (EnToryo*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnToryo_OverrideLimbDraw, EnToryo_PostLimbDraw, this); } diff --git a/soh/src/overlays/actors/ovl_En_Tp/z_en_tp.c b/soh/src/overlays/actors/ovl_En_Tp/z_en_tp.c index bbe6435e8..7f032a49a 100644 --- a/soh/src/overlays/actors/ovl_En_Tp/z_en_tp.c +++ b/soh/src/overlays/actors/ovl_En_Tp/z_en_tp.c @@ -737,7 +737,7 @@ void EnTp_Draw(Actor* thisx, PlayState* play) { if (this->unk_150 != 2) { if ((thisx->params <= TAILPASARAN_HEAD) || (thisx->params == TAILPASARAN_HEAD_DYING)) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -745,7 +745,7 @@ void EnTp_Draw(Actor* thisx, PlayState* play) { Matrix_Translate(0.0f, 0.0f, 8.0f, MTXMODE_APPLY); } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_ReplaceRotation(&play->billboardMtxF); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->red, 0, 255, this->alpha); diff --git a/soh/src/overlays/actors/ovl_En_Tr/z_en_tr.c b/soh/src/overlays/actors/ovl_En_Tr/z_en_tr.c index 2f1a96436..e9b2f6db4 100644 --- a/soh/src/overlays/actors/ovl_En_Tr/z_en_tr.c +++ b/soh/src/overlays/actors/ovl_En_Tr/z_en_tr.c @@ -436,7 +436,7 @@ void EnTr_Draw(Actor* thisx, PlayState* play) { this->actor.shape.shadowDraw = ActorShadow_DrawCircle; OPEN_DISPS(play->state.gfxCtx); - func_800943C8(play->state.gfxCtx); + Gfx_SetupDL_37Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeIndex])); func_8002EBCC(&this->actor, play, 0); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, diff --git a/soh/src/overlays/actors/ovl_En_Vali/z_en_vali.c b/soh/src/overlays/actors/ovl_En_Vali/z_en_vali.c index 79b6d8a6b..fc73eafe3 100644 --- a/soh/src/overlays/actors/ovl_En_Vali/z_en_vali.c +++ b/soh/src/overlays/actors/ovl_En_Vali/z_en_vali.c @@ -790,7 +790,7 @@ void EnVali_Draw(Actor* thisx, PlayState* play) { EnVali* this = (EnVali*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 0, (127 - (play->gameplayFrames * 12)) % 128, 32, 32)); diff --git a/soh/src/overlays/actors/ovl_En_Vb_Ball/z_en_vb_ball.c b/soh/src/overlays/actors/ovl_En_Vb_Ball/z_en_vb_ball.c index ac77c09d7..0e859c37c 100644 --- a/soh/src/overlays/actors/ovl_En_Vb_Ball/z_en_vb_ball.c +++ b/soh/src/overlays/actors/ovl_En_Vb_Ball/z_en_vb_ball.c @@ -303,7 +303,7 @@ void EnVbBall_Draw(Actor* thisx, PlayState* play) { EnVbBall* this = (EnVbBall*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -311,7 +311,7 @@ void EnVbBall_Draw(Actor* thisx, PlayState* play) { gSPDisplayList(POLY_OPA_DISP++, SEGMENTED_TO_VIRTUAL(gVolvagiaRibsDL)); } else { gSPDisplayList(POLY_OPA_DISP++, SEGMENTED_TO_VIRTUAL(gVolvagiaRockDL)); - func_80094044(play->state.gfxCtx); + Gfx_SetupDL_44Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 0, 0, 0, (s8)this->shadowOpacity); Matrix_Translate(this->actor.world.pos.x, 100.0f, this->actor.world.pos.z, MTXMODE_NEW); diff --git a/soh/src/overlays/actors/ovl_En_Viewer/z_en_viewer.c b/soh/src/overlays/actors/ovl_En_Viewer/z_en_viewer.c index 6b6f5b8ab..bf72529ed 100644 --- a/soh/src/overlays/actors/ovl_En_Viewer/z_en_viewer.c +++ b/soh/src/overlays/actors/ovl_En_Viewer/z_en_viewer.c @@ -506,7 +506,7 @@ s32 EnViewer_Ganondorf3OverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dL void EnViewer_Ganondorf9PostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) { if (limbIndex == 11) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gGanondorfEyesDL)); @@ -702,12 +702,12 @@ void EnViewer_Draw(Actor* thisx, PlayState* play) { type = this->actor.params >> 8; if (type <= ENVIEWER_TYPE_2_ZELDA) { // zelda's horse, impa and zelda if (play->csCtx.state != CS_STATE_IDLE && play->csCtx.npcActions[0] != NULL) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); sDrawFuncs[this->drawFuncIndex](this, play); } } else if ((play->csCtx.state != CS_STATE_IDLE && play->csCtx.npcActions[1] != NULL) || type == ENVIEWER_TYPE_9_GANONDORF) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); sDrawFuncs[this->drawFuncIndex](this, play); } } @@ -847,7 +847,7 @@ void EnViewer_DrawFireEffects(EnViewer* this2, PlayState* play) { } FrameInterpolation_RecordOpenChild(&this->fireEffects[i], this->fireEffects[i].epoch); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Translate(this->fireEffects[i].pos.x, this->fireEffects[i].pos.y, this->fireEffects[i].pos.z, MTXMODE_NEW); Matrix_Scale(this->fireEffects[i].scale, this->fireEffects[i].scale, this->fireEffects[i].scale, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_En_Vm/z_en_vm.c b/soh/src/overlays/actors/ovl_En_Vm/z_en_vm.c index 875baab12..d04ceeb4e 100644 --- a/soh/src/overlays/actors/ovl_En_Vm/z_en_vm.c +++ b/soh/src/overlays/actors/ovl_En_Vm/z_en_vm.c @@ -523,8 +523,8 @@ void EnVm_Draw(Actor* thisx, PlayState* play2) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); SkelAnime_DrawOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnVm_OverrideLimbDraw, EnVm_PostLimbDraw, this); actorPos = this->actor.world.pos; @@ -536,7 +536,7 @@ void EnVm_Draw(Actor* thisx, PlayState* play2) { gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, 168); - func_80094BC4(play->state.gfxCtx); + Gfx_SetupDL_60NoCDXlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 255, 0); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_80B2EB88[play->gameplayFrames % 8])); gSPDisplayList(POLY_XLU_DISP++, gEffEnemyDeathFlameDL); diff --git a/soh/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c b/soh/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c index bb5cbf674..07ee9fe23 100644 --- a/soh/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c +++ b/soh/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c @@ -588,7 +588,7 @@ void EnWallmas_DrawXlu(EnWallmas* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80094044(play->state.gfxCtx); + Gfx_SetupDL_44Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 0, 0, 0, 255); func_80038A28(this->actor.floorPoly, this->actor.world.pos.x, this->actor.floorHeight, this->actor.world.pos.z, @@ -646,7 +646,7 @@ void EnWallmas_Draw(Actor* thisx, PlayState* play) { EnWallmas* this = (EnWallmas*)thisx; if (this->actionFunc != EnWallmas_WaitToDrop) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnWallMas_OverrideLimbDraw, EnWallMas_PostLimbDraw, this); } diff --git a/soh/src/overlays/actors/ovl_En_Weiyer/z_en_weiyer.c b/soh/src/overlays/actors/ovl_En_Weiyer/z_en_weiyer.c index 865fe71af..31ceb7071 100644 --- a/soh/src/overlays/actors/ovl_En_Weiyer/z_en_weiyer.c +++ b/soh/src/overlays/actors/ovl_En_Weiyer/z_en_weiyer.c @@ -634,13 +634,13 @@ void EnWeiyer_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); if (this->actionFunc != func_80B33338) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, &D_80116280[2]); gDPSetEnvColor(POLY_OPA_DISP++, 255, 255, 255, 255); POLY_OPA_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable, EnWeiyer_OverrideLimbDraw, NULL, &this->actor, POLY_OPA_DISP); } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, &D_80116280[0]); gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 255, this->actor.shape.shadowAlpha); POLY_XLU_DISP = SkelAnime_Draw(play, this->skelAnime.skeleton, this->skelAnime.jointTable, diff --git a/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c b/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c index 478cd036d..fbfe531ad 100644 --- a/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c +++ b/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c @@ -1440,7 +1440,7 @@ void EnWf_Draw(Actor* thisx, PlayState* play) { // This conditional will always evaluate to true, since unk_300 is false whenever action is // WOLFOS_ACTION_WAIT_TO_APPEAR. if ((this->action != WOLFOS_ACTION_WAIT_TO_APPEAR) || !this->unk_300) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (this->actor.params == WOLFOS_NORMAL) { gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sWolfosNormalEyeTextures[this->eyeIndex])); diff --git a/soh/src/overlays/actors/ovl_En_Wood02/z_en_wood02.c b/soh/src/overlays/actors/ovl_En_Wood02/z_en_wood02.c index 3ee7c7089..d37093090 100644 --- a/soh/src/overlays/actors/ovl_En_Wood02/z_en_wood02.c +++ b/soh/src/overlays/actors/ovl_En_Wood02/z_en_wood02.c @@ -441,10 +441,10 @@ void EnWood02_Draw(Actor* thisx, PlayState* play) { red = green = blue = 255; } - func_80093D84(gfxCtx); + Gfx_SetupDL_25Xlu(gfxCtx); if ((this->actor.params == WOOD_LEAF_GREEN) || (this->actor.params == WOOD_LEAF_YELLOW)) { - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, red, green, blue, 127); Gfx_DrawDListOpa(play, object_wood02_DL_000700); } else if (D_80B3BF70[this->drawType & 0xF] != NULL) { @@ -454,7 +454,7 @@ void EnWood02_Draw(Actor* thisx, PlayState* play) { G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, D_80B3BF70[this->drawType & 0xF]); } else { - func_80093D84(gfxCtx); + Gfx_SetupDL_25Xlu(gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, D_80B3BF54[this->drawType & 0xF]); diff --git a/soh/src/overlays/actors/ovl_En_Xc/z_en_xc.c b/soh/src/overlays/actors/ovl_En_Xc/z_en_xc.c index 4eae7c311..e0c701b3a 100644 --- a/soh/src/overlays/actors/ovl_En_Xc/z_en_xc.c +++ b/soh/src/overlays/actors/ovl_En_Xc/z_en_xc.c @@ -1128,7 +1128,7 @@ void EnXc_DrawPullingOutHarp(Actor* thisx, PlayState* play) { gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 255, 20, 0); gDPSetEnvColor(POLY_OPA_DISP++, 60, 0, 0, 0); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); func_8002EBCC(&this->actor, play, 0); SkelAnime_DrawFlexOpa(play, skelAnime->skeleton, skelAnime->jointTable, skelAnime->dListCount, EnXc_PullingOutHarpOverrideLimbDraw, NULL, this); @@ -1151,7 +1151,7 @@ void EnXc_DrawHarp(Actor* thisx, PlayState* play) { gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 255, 20, 0); gDPSetEnvColor(POLY_OPA_DISP++, 60, 0, 0, 0); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); func_8002EBCC(&this->actor, play, 0); SkelAnime_DrawFlexOpa(play, skelAnime->skeleton, skelAnime->jointTable, skelAnime->dListCount, EnXc_HarpOverrideLimbDraw, NULL, this); @@ -1770,7 +1770,7 @@ void EnXc_DrawTriforce(Actor* thisx, PlayState* play) { Matrix_Scale(scale[0], scale[1], scale[2], MTXMODE_APPLY); MATRIX_TOMTX(mtx); Matrix_Pop(); - func_80093D84(gfxCtx); + Gfx_SetupDL_25Xlu(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, 255, 255, primColor[2], primColor[3]); gDPSetEnvColor(POLY_XLU_DISP++, 255, envColor[1], 0, 128); gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -1778,7 +1778,7 @@ void EnXc_DrawTriforce(Actor* thisx, PlayState* play) { } func_8002EBCC(thisx, play, 0); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTexture)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTexture)); SkelAnime_DrawFlexOpa(play, skelAnime->skeleton, skelAnime->jointTable, skelAnime->dListCount, @@ -2180,7 +2180,7 @@ void EnXc_DrawSquintingEyes(Actor* thisx, PlayState* play) { GraphicsContext* gfxCtx = play->state.gfxCtx; OPEN_DISPS(gfxCtx); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(gSheikEyeSquintingTex)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(gSheikEyeSquintingTex)); SkelAnime_DrawFlexOpa(play, skelAnime->skeleton, skelAnime->jointTable, skelAnime->dListCount, NULL, NULL, @@ -2450,7 +2450,7 @@ void EnXc_DrawDefault(Actor* thisx, PlayState* play) { OPEN_DISPS(gfxCtx); func_8002EBCC(&this->actor, play, 0); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeSegment)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeSegment)); SkelAnime_DrawFlexOpa(play, skelAnime->skeleton, skelAnime->jointTable, skelAnime->dListCount, diff --git a/soh/src/overlays/actors/ovl_En_Yukabyun/z_en_yukabyun.c b/soh/src/overlays/actors/ovl_En_Yukabyun/z_en_yukabyun.c index 50f334d42..c1f2f08c1 100644 --- a/soh/src/overlays/actors/ovl_En_Yukabyun/z_en_yukabyun.c +++ b/soh/src/overlays/actors/ovl_En_Yukabyun/z_en_yukabyun.c @@ -150,7 +150,7 @@ void EnYukabyun_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_80B43F64[this->unk_152])); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_En_Zf/z_en_zf.c b/soh/src/overlays/actors/ovl_En_Zf/z_en_zf.c index e73360268..eeb88ea39 100644 --- a/soh/src/overlays/actors/ovl_En_Zf/z_en_zf.c +++ b/soh/src/overlays/actors/ovl_En_Zf/z_en_zf.c @@ -2249,7 +2249,7 @@ void EnZf_Draw(Actor* thisx, PlayState* play) { gSPSegment(POLY_OPA_DISP++, 0x08, D_80B4A2F8); if (this->alpha == 255) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, this->alpha); gSPSegment(POLY_OPA_DISP++, 0x09, &D_80116280[2]); @@ -2268,7 +2268,7 @@ void EnZf_Draw(Actor* thisx, PlayState* play) { } } } else { // fades out when dead - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPPipeSync(POLY_XLU_DISP++); gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->alpha); gSPSegment(POLY_XLU_DISP++, 0x09, &D_80116280[0]); diff --git a/soh/src/overlays/actors/ovl_En_Zl1/z_en_zl1.c b/soh/src/overlays/actors/ovl_En_Zl1/z_en_zl1.c index d995ecf09..39e15bbcf 100644 --- a/soh/src/overlays/actors/ovl_En_Zl1/z_en_zl1.c +++ b/soh/src/overlays/actors/ovl_En_Zl1/z_en_zl1.c @@ -622,7 +622,7 @@ void EnZl1_Draw(Actor* thisx, PlayState* play) { gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(this->unk_1F8)); gSPSegment(POLY_OPA_DISP++, 0x0A, SEGMENTED_TO_VIRTUAL(this->unk_1EC)); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnZl1_OverrideLimbDraw, EnZl1_PostLimbDraw, this); diff --git a/soh/src/overlays/actors/ovl_En_Zl2/z_en_zl2.c b/soh/src/overlays/actors/ovl_En_Zl2/z_en_zl2.c index bb60e362b..9b48a2351 100644 --- a/soh/src/overlays/actors/ovl_En_Zl2/z_en_zl2.c +++ b/soh/src/overlays/actors/ovl_En_Zl2/z_en_zl2.c @@ -1643,7 +1643,7 @@ void func_80B523C8(EnZl2* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTex)); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTex2)); @@ -1668,7 +1668,7 @@ void func_80B525D4(EnZl2* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTex)); gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTex)); diff --git a/soh/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c b/soh/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c index c881f2705..93e98ec3c 100644 --- a/soh/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c +++ b/soh/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c @@ -2704,7 +2704,7 @@ void func_80B59FF4(EnZl3* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x8, SEGMENTED_TO_VIRTUAL(eyeTex)); gSPSegment(POLY_OPA_DISP++, 0x9, SEGMENTED_TO_VIRTUAL(eyeTex)); @@ -2729,7 +2729,7 @@ void func_80B5A1D0(EnZl3* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 8, SEGMENTED_TO_VIRTUAL(eyeTex)); gSPSegment(POLY_XLU_DISP++, 9, SEGMENTED_TO_VIRTUAL(eyeTex)); diff --git a/soh/src/overlays/actors/ovl_En_Zl4/z_en_zl4.c b/soh/src/overlays/actors/ovl_En_Zl4/z_en_zl4.c index 22cd49add..3e1d7b462 100644 --- a/soh/src/overlays/actors/ovl_En_Zl4/z_en_zl4.c +++ b/soh/src/overlays/actors/ovl_En_Zl4/z_en_zl4.c @@ -1324,7 +1324,7 @@ void EnZl4_Draw(Actor* thisx, PlayState* play) { gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTex[this->rightEyeState])); gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTex[this->leftEyeState])); gSPSegment(POLY_OPA_DISP++, 0x0A, SEGMENTED_TO_VIRTUAL(mouthTex[this->mouthState])); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); SkelAnime_DrawFlexOpa(play, this->skelAnime.skeleton, this->skelAnime.jointTable, this->skelAnime.dListCount, EnZl4_OverrideLimbDraw, EnZl4_PostLimbDraw, this); CLOSE_DISPS(play->state.gfxCtx); diff --git a/soh/src/overlays/actors/ovl_En_Zo/z_en_zo.c b/soh/src/overlays/actors/ovl_En_Zo/z_en_zo.c index 8157a6e39..78ef6e298 100644 --- a/soh/src/overlays/actors/ovl_En_Zo/z_en_zo.c +++ b/soh/src/overlays/actors/ovl_En_Zo/z_en_zo.c @@ -180,7 +180,7 @@ void EnZo_DrawRipples(EnZo* this, PlayState* play) { effect = this->effects; OPEN_DISPS(play->state.gfxCtx); setup = false; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->effects); i++) { if (effect->type == ENZO_EFFECT_RIPPLE) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); @@ -211,7 +211,7 @@ void EnZo_DrawBubbles(EnZo* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); setup = false; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->effects); i++) { if (effect->type == ENZO_EFFECT_BUBBLE) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); @@ -246,7 +246,7 @@ void EnZo_DrawSplashes(EnZo* this, PlayState* play) { effect = this->effects; OPEN_DISPS(play->state.gfxCtx); setup = false; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); for (i = 0; i < ARRAY_COUNT(this->effects); i++) { if (effect->type == ENZO_EFFECT_SPLASH) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); diff --git a/soh/src/overlays/actors/ovl_En_fHG/z_en_fhg.c b/soh/src/overlays/actors/ovl_En_fHG/z_en_fhg.c index 93a09e68a..ce7c8f342 100644 --- a/soh/src/overlays/actors/ovl_En_fHG/z_en_fhg.c +++ b/soh/src/overlays/actors/ovl_En_fHG/z_en_fhg.c @@ -716,7 +716,7 @@ void EnfHG_Draw(Actor* thisx, PlayState* play) { s32 pad; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); POLY_OPA_DISP = ((bossGnd->work[GND_INVINC_TIMER] & 4) && (bossGnd->flyMode == GND_FLY_PAINTING)) ? Gfx_SetFog(POLY_OPA_DISP, 255, 50, 0, 0, 900, 1099) diff --git a/soh/src/overlays/actors/ovl_End_Title/z_end_title.c b/soh/src/overlays/actors/ovl_End_Title/z_end_title.c index 84ceccd49..7d528b3c7 100644 --- a/soh/src/overlays/actors/ovl_End_Title/z_end_title.c +++ b/soh/src/overlays/actors/ovl_End_Title/z_end_title.c @@ -58,7 +58,7 @@ void EndTitle_DrawFull(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); // Draw the Triforce on Link's left hand - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Mult(mf, MTXMODE_NEW); Matrix_Translate(0.0f, 150.0f, 170.0f, MTXMODE_APPLY); Matrix_Scale(0.13f, 0.13f, 0.13f, MTXMODE_APPLY); @@ -83,7 +83,7 @@ void EndTitle_DrawFull(Actor* thisx, PlayState* play) { this->ootAlpha += 15; } - OVERLAY_DISP = func_80093F34(OVERLAY_DISP); + OVERLAY_DISP = Gfx_SetupDL_64(OVERLAY_DISP); if (D_801614B0.a > 0) gSPGrayscale(OVERLAY_DISP++, false); gDPSetTextureLUT(OVERLAY_DISP++, G_TT_NONE); @@ -128,7 +128,7 @@ void EndTitle_DrawNintendoLogo(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - OVERLAY_DISP = func_80093F34(OVERLAY_DISP); + OVERLAY_DISP = Gfx_SetupDL_64(OVERLAY_DISP); gDPSetPrimColor(OVERLAY_DISP++, 0, 0x80, 0, 0, 0, this->endAlpha); gSPDisplayList(OVERLAY_DISP++, sPresentedByNintendoDL); diff --git a/soh/src/overlays/actors/ovl_Fishing/z_fishing.c b/soh/src/overlays/actors/ovl_Fishing/z_fishing.c index b13333bca..1c532ac37 100644 --- a/soh/src/overlays/actors/ovl_Fishing/z_fishing.c +++ b/soh/src/overlays/actors/ovl_Fishing/z_fishing.c @@ -1305,7 +1305,7 @@ void Fishing_DrawEffects(FishingEffect* effect, PlayState* play) { if (effect->type == FS_EFF_RAIN_DROP) { FrameInterpolation_RecordOpenChild(effect, effect->epoch); if (flag == 0) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x14); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x14); gDPSetCombineMode(POLY_XLU_DISP++, G_CC_PRIMITIVE, G_CC_PRIMITIVE); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 150, 255, 255, 30); flag++; @@ -1326,7 +1326,7 @@ void Fishing_DrawEffects(FishingEffect* effect, PlayState* play) { effect++; } - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); effect = firstEffect + 30; flag = 0; @@ -1772,7 +1772,7 @@ void Fishing_DrawSinkingLure(PlayState* play) { Fishing_UpdateSinkingLure(play); if (sLurePos.y < WATER_SURFACE_Y(play)) { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPDisplayList(POLY_OPA_DISP++, gFishingSinkingLureSegmentMaterialDL); @@ -1791,7 +1791,7 @@ void Fishing_DrawSinkingLure(PlayState* play) { } } } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPDisplayList(POLY_XLU_DISP++, gFishingSinkingLureSegmentMaterialDL); @@ -1825,7 +1825,7 @@ void Fishing_DrawLureAndLine(PlayState* play, Vec3f* linePos, Vec3f* lineRot) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Push(); if (D_80B7A6D4 != 0) { @@ -1867,7 +1867,7 @@ void Fishing_DrawLureAndLine(PlayState* play, Vec3f* linePos, Vec3f* lineRot) { Matrix_RotateZ(M_PI / 2, MTXMODE_APPLY); Matrix_RotateY(M_PI / 2, MTXMODE_APPLY); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -1889,7 +1889,7 @@ void Fishing_DrawLureAndLine(PlayState* play, Vec3f* linePos, Vec3f* lineRot) { Fishing_DrawLureHook(play, &hookPos[1], &sLureHookRefPos[1], 1); } - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x14); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x14); gDPSetCombineMode(POLY_XLU_DISP++, G_CC_PRIMITIVE, G_CC_PRIMITIVE); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, 55); @@ -1963,7 +1963,7 @@ void Fishing_DrawLureAndLine(PlayState* play, Vec3f* linePos, Vec3f* lineRot) { } Matrix_Pop(); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); CLOSE_DISPS(play->state.gfxCtx); } @@ -2058,7 +2058,7 @@ void Fishing_DrawRod(PlayState* play) { } } - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPDisplayList(POLY_OPA_DISP++, gFishingRodMaterialDL); @@ -4316,7 +4316,7 @@ void Fishing_LoachPostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3 void Fishing_DrawFish(Actor* thisx, PlayState* play) { Fishing* this = (Fishing*)thisx; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Translate(this->actor.world.pos.x, this->actor.world.pos.y, this->actor.world.pos.z, MTXMODE_NEW); Matrix_RotateY(((this->unk_162 + this->actor.shape.rot.y) / 32768.0f) * M_PI, MTXMODE_APPLY); @@ -5824,8 +5824,8 @@ void Fishing_DrawOwner(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if ((this->actor.projectedPos.z < 1500.0f) && (fabsf(this->actor.projectedPos.x) < (100.0f + this->actor.projectedPos.z))) { diff --git a/soh/src/overlays/actors/ovl_Item_B_Heart/z_item_b_heart.c b/soh/src/overlays/actors/ovl_Item_B_Heart/z_item_b_heart.c index cebd0f4d7..35f6d5457 100644 --- a/soh/src/overlays/actors/ovl_Item_B_Heart/z_item_b_heart.c +++ b/soh/src/overlays/actors/ovl_Item_B_Heart/z_item_b_heart.c @@ -103,13 +103,13 @@ void ItemBHeart_Draw(Actor* thisx, PlayState* play) { play->sceneNum,this->actor.params, GI_HEART_CONTAINER_2)); } else { if (flag) { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, gGiHeartBorderDL); gSPDisplayList(POLY_XLU_DISP++, gGiHeartContainerDL); } else { - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, gGiHeartBorderDL); diff --git a/soh/src/overlays/actors/ovl_Item_Shield/z_item_shield.c b/soh/src/overlays/actors/ovl_Item_Shield/z_item_shield.c index 9eda477a6..b60de8082 100644 --- a/soh/src/overlays/actors/ovl_Item_Shield/z_item_shield.c +++ b/soh/src/overlays/actors/ovl_Item_Shield/z_item_shield.c @@ -221,7 +221,7 @@ void ItemShield_Draw(Actor* thisx, PlayState* play) { if (!(this->unk_19C & 2)) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_OPA_DISP++, SEGMENTED_TO_VIRTUAL(gLinkChildDekuShieldDL)); diff --git a/soh/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c b/soh/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c index 4079eb473..333ce4bf6 100644 --- a/soh/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c +++ b/soh/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c @@ -205,7 +205,7 @@ void MagicDark_DiamondDraw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); { Player* player = GET_PLAYER(play); @@ -270,7 +270,7 @@ void MagicDark_OrbDraw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, 170, 255, 255, 255); gDPSetEnvColor(POLY_XLU_DISP++, 0, 150, 255, 255); Matrix_Translate(pos.x, pos.y, pos.z, MTXMODE_NEW); diff --git a/soh/src/overlays/actors/ovl_Magic_Fire/z_magic_fire.c b/soh/src/overlays/actors/ovl_Magic_Fire/z_magic_fire.c index 16f1e0bf6..0ad2f0e79 100644 --- a/soh/src/overlays/actors/ovl_Magic_Fire/z_magic_fire.c +++ b/soh/src/overlays/actors/ovl_Magic_Fire/z_magic_fire.c @@ -223,14 +223,14 @@ void MagicFire_Draw(Actor* thisx, PlayState* play) { if (this->action > 0) { OPEN_DISPS(play->state.gfxCtx); - POLY_XLU_DISP = func_800937C0(POLY_XLU_DISP); + POLY_XLU_DISP = Gfx_SetupDL_57(POLY_XLU_DISP); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, (u8)(s32)(60 * this->screenTintIntensity), (u8)(s32)(20 * this->screenTintIntensity), (u8)(s32)(0 * this->screenTintIntensity), (u8)(s32)(120 * this->screenTintIntensity)); gDPSetAlphaDither(POLY_XLU_DISP++, G_AD_DISABLE); gDPSetColorDither(POLY_XLU_DISP++, G_CD_DISABLE); gDPFillRectangle(POLY_XLU_DISP++, 0, 0, 319, 239); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (CVar_GetS32("gUseSpellsCol",0)) { gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, Spell_col.r, Spell_col.g, Spell_col.b, (u8)(this->alphaMultiplier * 255)); gDPSetEnvColor(POLY_XLU_DISP++, Spell_env.r, Spell_env.g, Spell_env.b, (u8)(this->alphaMultiplier * 255)); diff --git a/soh/src/overlays/actors/ovl_Magic_Wind/z_magic_wind.c b/soh/src/overlays/actors/ovl_Magic_Wind/z_magic_wind.c index 68e30e186..def55aae9 100644 --- a/soh/src/overlays/actors/ovl_Magic_Wind/z_magic_wind.c +++ b/soh/src/overlays/actors/ovl_Magic_Wind/z_magic_wind.c @@ -175,7 +175,7 @@ void MagicWind_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(gfxCtx); if (this->actionFunc != MagicWind_WaitForTimer) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 25); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 25); SkelCurve_Draw(thisx, play, &this->skelCurve, MagicWind_OverrideLimbDraw, NULL, 1, NULL); } diff --git a/soh/src/overlays/actors/ovl_Mir_Ray/z_mir_ray.c b/soh/src/overlays/actors/ovl_Mir_Ray/z_mir_ray.c index 34e142a3b..43c1447bf 100644 --- a/soh/src/overlays/actors/ovl_Mir_Ray/z_mir_ray.c +++ b/soh/src/overlays/actors/ovl_Mir_Ray/z_mir_ray.c @@ -490,7 +490,7 @@ void MirRay_Draw(Actor* thisx, PlayState* play) { if (!(this->reflectIntensity <= 0.0f)) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Scale(1.0f, 1.0f, this->reflectIntensity * 5.0f, MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Obj_Comb/z_obj_comb.c b/soh/src/overlays/actors/ovl_Obj_Comb/z_obj_comb.c index cdbec8db2..225eac29f 100644 --- a/soh/src/overlays/actors/ovl_Obj_Comb/z_obj_comb.c +++ b/soh/src/overlays/actors/ovl_Obj_Comb/z_obj_comb.c @@ -207,7 +207,7 @@ void ObjComb_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); Matrix_Translate(this->actor.world.pos.x, this->actor.world.pos.y + (118.0f * this->actor.scale.y), this->actor.world.pos.z, MTXMODE_NEW); diff --git a/soh/src/overlays/actors/ovl_Obj_Dekujr/z_obj_dekujr.c b/soh/src/overlays/actors/ovl_Obj_Dekujr/z_obj_dekujr.c index 2331fbbaf..360a8a390 100644 --- a/soh/src/overlays/actors/ovl_Obj_Dekujr/z_obj_dekujr.c +++ b/soh/src/overlays/actors/ovl_Obj_Dekujr/z_obj_dekujr.c @@ -152,8 +152,8 @@ void ObjDekujr_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Obj_Hamishi/z_obj_hamishi.c b/soh/src/overlays/actors/ovl_Obj_Hamishi/z_obj_hamishi.c index c0c38f4f1..e17cf0d80 100644 --- a/soh/src/overlays/actors/ovl_Obj_Hamishi/z_obj_hamishi.c +++ b/soh/src/overlays/actors/ovl_Obj_Hamishi/z_obj_hamishi.c @@ -197,7 +197,7 @@ void ObjHamishi_Update(Actor* thisx, PlayState* play) { void ObjHamishi_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Obj_Hsblock/z_obj_hsblock.c b/soh/src/overlays/actors/ovl_Obj_Hsblock/z_obj_hsblock.c index 5680ad826..45a75e079 100644 --- a/soh/src/overlays/actors/ovl_Obj_Hsblock/z_obj_hsblock.c +++ b/soh/src/overlays/actors/ovl_Obj_Hsblock/z_obj_hsblock.c @@ -151,7 +151,7 @@ void ObjHsblock_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Obj_Ice_Poly/z_obj_ice_poly.c b/soh/src/overlays/actors/ovl_Obj_Ice_Poly/z_obj_ice_poly.c index fb27cd29b..5922830c0 100644 --- a/soh/src/overlays/actors/ovl_Obj_Ice_Poly/z_obj_ice_poly.c +++ b/soh/src/overlays/actors/ovl_Obj_Ice_Poly/z_obj_ice_poly.c @@ -194,7 +194,7 @@ void ObjIcePoly_Draw(Actor* thisx, PlayState* play) { ObjIcePoly* this = (ObjIcePoly*)thisx; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); func_8002ED80(&this->actor, play, 0); Matrix_RotateZYX(0x500, 0, -0x500, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_Obj_Lightswitch/z_obj_lightswitch.c b/soh/src/overlays/actors/ovl_Obj_Lightswitch/z_obj_lightswitch.c index 1bc5e543d..027e4c6aa 100644 --- a/soh/src/overlays/actors/ovl_Obj_Lightswitch/z_obj_lightswitch.c +++ b/soh/src/overlays/actors/ovl_Obj_Lightswitch/z_obj_lightswitch.c @@ -484,7 +484,7 @@ void ObjLightswitch_DrawOpa(ObjLightswitch* this, PlayState* play) { Vec3s rot; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetEnvColor(POLY_OPA_DISP++, (u8)(this->color[0] >> 6), (u8)(this->color[1] >> 6), (u8)(this->color[2] >> 6), (u8)(this->alpha >> 6)); @@ -534,7 +534,7 @@ void ObjLightswitch_DrawXlu(ObjLightswitch* this, PlayState* play) { Vec3s sp60; OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, (u8)(this->color[0] >> 6), (u8)(this->color[1] >> 6), (u8)(this->color[2] >> 6), (u8)(this->alpha >> 6)); diff --git a/soh/src/overlays/actors/ovl_Obj_Oshihiki/z_obj_oshihiki.c b/soh/src/overlays/actors/ovl_Obj_Oshihiki/z_obj_oshihiki.c index c8ea35321..31849422c 100644 --- a/soh/src/overlays/actors/ovl_Obj_Oshihiki/z_obj_oshihiki.c +++ b/soh/src/overlays/actors/ovl_Obj_Oshihiki/z_obj_oshihiki.c @@ -659,7 +659,7 @@ void ObjOshihiki_Draw(Actor* thisx, PlayState* play) { Matrix_Translate(this->underDistX * 10.0f, 0.0f, this->underDistZ * 10.0f, MTXMODE_APPLY); } this->stateFlags &= ~PUSHBLOCK_MOVE_UNDER; - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(this->texture)); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), diff --git a/soh/src/overlays/actors/ovl_Obj_Switch/z_obj_switch.c b/soh/src/overlays/actors/ovl_Obj_Switch/z_obj_switch.c index 2e245286e..532666adf 100644 --- a/soh/src/overlays/actors/ovl_Obj_Switch/z_obj_switch.c +++ b/soh/src/overlays/actors/ovl_Obj_Switch/z_obj_switch.c @@ -733,7 +733,7 @@ void ObjSwitch_DrawEye(ObjSwitch* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(eyeTextures[subType][this->eyeTexIndex])); @@ -756,7 +756,7 @@ void ObjSwitch_DrawCrystal(ObjSwitch* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPDisplayList(POLY_XLU_DISP++, xluDLists[subType]); @@ -765,7 +765,7 @@ void ObjSwitch_DrawCrystal(ObjSwitch* this, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c b/soh/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c index b8b6f5258..ad5829123 100644 --- a/soh/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c +++ b/soh/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c @@ -266,7 +266,7 @@ void ObjSyokudai_Draw(Actor* thisx, PlayState* play) { timerMax = (((this->actor.params >> 6) & 0xF) * 50) + 100; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); @@ -283,7 +283,7 @@ void ObjSyokudai_Draw(Actor* thisx, PlayState* play) { } flameScale *= 0.0027f; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, diff --git a/soh/src/overlays/actors/ovl_Obj_Timeblock/z_obj_timeblock.c b/soh/src/overlays/actors/ovl_Obj_Timeblock/z_obj_timeblock.c index 9de638280..959baa8b8 100644 --- a/soh/src/overlays/actors/ovl_Obj_Timeblock/z_obj_timeblock.c +++ b/soh/src/overlays/actors/ovl_Obj_Timeblock/z_obj_timeblock.c @@ -337,7 +337,7 @@ void ObjTimeblock_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, primColor->r, primColor->g, primColor->b, 255); diff --git a/soh/src/overlays/actors/ovl_Obj_Warp2block/z_obj_warp2block.c b/soh/src/overlays/actors/ovl_Obj_Warp2block/z_obj_warp2block.c index 02c566751..960db69f9 100644 --- a/soh/src/overlays/actors/ovl_Obj_Warp2block/z_obj_warp2block.c +++ b/soh/src/overlays/actors/ovl_Obj_Warp2block/z_obj_warp2block.c @@ -309,7 +309,7 @@ void ObjWarp2block_Draw(Actor* thisx, PlayState* play) { sp44 = &sColors[thisx->home.rot.z & 7]; OPEN_DISPS(play->state.gfxCtx); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Object_Kankyo/z_object_kankyo.c b/soh/src/overlays/actors/ovl_Object_Kankyo/z_object_kankyo.c index 413f55634..325bd1e02 100644 --- a/soh/src/overlays/actors/ovl_Object_Kankyo/z_object_kankyo.c +++ b/soh/src/overlays/actors/ovl_Object_Kankyo/z_object_kankyo.c @@ -521,7 +521,7 @@ void ObjectKankyo_DrawFairies(ObjectKankyo* this2, PlayState* play2) { if (!(play->cameraPtrs[0]->unk_14C & 0x100)) { OPEN_DISPS(play->state.gfxCtx); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x14); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x14); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(gSunTex)); gSPDisplayList(POLY_XLU_DISP++, gKokiriDustMoteTextureLoadDL); @@ -723,7 +723,7 @@ void ObjectKankyo_DrawSnow(ObjectKankyo* this2, PlayState* play2) { gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(gDust5Tex)); - func_80094C50(play->state.gfxCtx); + Gfx_SetupDL_61Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, SEG_ADDR(1, 0), G_MTX_MODELVIEW | G_MTX_NOPUSH | G_MTX_MUL); gDPPipeSync(POLY_XLU_DISP++); @@ -778,7 +778,7 @@ void ObjectKankyo_DrawLightning(ObjectKankyo* this, PlayState* play) { gDPSetEnvColor(POLY_XLU_DISP++, 0, 255, 255, 128); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_LOAD); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEffLightningTextures[this->effects[0].timer])); - func_80094C50(play->state.gfxCtx); + Gfx_SetupDL_61Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, SEG_ADDR(1, 0), G_MTX_MODELVIEW | G_MTX_NOPUSH | G_MTX_MUL); gDPPipeSync(POLY_XLU_DISP++); gSPDisplayList(POLY_XLU_DISP++, gEffLightningDL); @@ -866,7 +866,7 @@ void ObjectKankyo_DrawSunGraveSpark(ObjectKankyo* this2, PlayState* play2) { Matrix_Translate((end.x - start.x) * weight + start.x, (end.y - start.y) * weight + start.y, (end.z - start.z) * weight + start.z, MTXMODE_NEW); Matrix_Scale(this->effects[0].size, this->effects[0].size, this->effects[0].size, MTXMODE_APPLY); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPPipeSync(POLY_XLU_DISP++); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, (u8)(105 * this->effects[0].amplitude) + 150, 255, (u8)(105 * this->effects[0].amplitude) + 150, this->effects[0].alpha); @@ -950,7 +950,7 @@ void ObjectKankyo_DrawBeams(ObjectKankyo* this2, PlayState* play2) { Matrix_RotateY(DEG_TO_RAD(beamYaw[i]), MTXMODE_APPLY); Matrix_RotateX(DEG_TO_RAD(beamPitch[i]), MTXMODE_APPLY); Matrix_Scale(this->effects[i].size, 0.1f, this->effects[i].size, MTXMODE_APPLY); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPPipeSync(POLY_XLU_DISP++); gDPSetPrimColor(POLY_XLU_DISP++, 0, 128, sBeamPrimColors[i].r, sBeamPrimColors[i].g, sBeamPrimColors[i].b, 128); diff --git a/soh/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c b/soh/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c index 47ab5bb47..337fb86ee 100644 --- a/soh/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c +++ b/soh/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c @@ -152,7 +152,7 @@ void OceffSpot_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c b/soh/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c index d7a26ec7b..09fa0078f 100644 --- a/soh/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c +++ b/soh/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c @@ -131,7 +131,7 @@ void OceffStorm_Draw2(Actor* thisx, PlayState* play) { gDPPipeSync(POLY_XLU_DISP++); - POLY_XLU_DISP = func_80093F34(POLY_XLU_DISP); + POLY_XLU_DISP = Gfx_SetupDL_64(POLY_XLU_DISP); gDPSetAlphaDither(POLY_XLU_DISP++, G_AD_NOISE); gDPSetColorDither(POLY_XLU_DISP++, G_CD_NOISE); gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 200, 200, 150, this->primColorAlpha); @@ -152,7 +152,7 @@ void OceffStorm_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 255, 200, 255); gDPSetEnvColor(POLY_XLU_DISP++, 150, 150, 0, 128); diff --git a/soh/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c b/soh/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c index 20418881a..a8e6637d7 100644 --- a/soh/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c +++ b/soh/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c @@ -102,7 +102,7 @@ void OceffWipe_Draw(Actor* thisx, PlayState* play) { vtxPtr[i * 2 + 1].v.cn[3] = alphaTable[sAlphaIndices[i] & 0xF]; } - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Translate(eye.x + vec.x, eye.y + vec.y, eye.z + vec.z, MTXMODE_NEW); Matrix_Scale(0.1f, 0.1f, 0.1f, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c b/soh/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c index bec266db4..2d143b8a8 100644 --- a/soh/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c +++ b/soh/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c @@ -90,7 +90,7 @@ void OceffWipe2_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Translate(eye.x + vec.x, eye.y + vec.y, eye.z + vec.z, MTXMODE_NEW); Matrix_Scale(0.1f, 0.1f, 0.1f, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c b/soh/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c index 3638b31b2..f1a36a894 100644 --- a/soh/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c +++ b/soh/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c @@ -91,7 +91,7 @@ void OceffWipe3_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Translate(eye.x + vec.x, eye.y + vec.y, eye.z + vec.z, MTXMODE_NEW); Matrix_Scale(0.1f, 0.1f, 0.1f, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c b/soh/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c index 90dfdf2dd..8e46acbba 100644 --- a/soh/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c +++ b/soh/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c @@ -86,7 +86,7 @@ void OceffWipe4_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_Translate(eye.x + vec.x, eye.y + vec.y, eye.z + vec.z, MTXMODE_NEW); Matrix_Scale(0.1f, 0.1f, 0.1f, MTXMODE_APPLY); diff --git a/soh/src/overlays/actors/ovl_player_actor/z_player.c b/soh/src/overlays/actors/ovl_player_actor/z_player.c index 3190e5eeb..d3c5604d4 100644 --- a/soh/src/overlays/actors/ovl_player_actor/z_player.c +++ b/soh/src/overlays/actors/ovl_player_actor/z_player.c @@ -11177,7 +11177,7 @@ void Player_Draw(Actor* thisx, PlayState* play2) { lod = 0; func_80093C80(play); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (this->invincibilityTimer > 0) { this->unk_88F += CLAMP(50 - this->invincibilityTimer, 8, 40); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Blast/z_eff_ss_blast.c b/soh/src/overlays/effects/ovl_Effect_Ss_Blast/z_eff_ss_blast.c index 48192fbe4..1135ca0a2 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Blast/z_eff_ss_blast.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Blast/z_eff_ss_blast.c @@ -65,7 +65,7 @@ void EffectSsBlast_Draw(PlayState* play, u32 index, EffectSs* this) { radius = this->rScale * 0.0025f; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, this->rEnvColorA); func_800BFCB8(play, &mf, &this->pos); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rPrimColorA); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Bomb/z_eff_ss_bomb.c b/soh/src/overlays/effects/ovl_Effect_Ss_Bomb/z_eff_ss_bomb.c index 5651ffdc3..e01b6fb98 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Bomb/z_eff_ss_bomb.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Bomb/z_eff_ss_bomb.c @@ -69,7 +69,7 @@ void EffectSsBomb_Draw(PlayState* play, u32 index, EffectSs* this) { gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(explosionTextures[this->rTexIdx])); gDPPipeSync(POLY_XLU_DISP++); - func_80094C50(gfxCtx); + Gfx_SetupDL_61Xlu(gfxCtx); color = this->life * 12.75f; gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, color, color, color, color); gDPPipeSync(POLY_XLU_DISP++); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Bomb2/z_eff_ss_bomb2.c b/soh/src/overlays/effects/ovl_Effect_Ss_Bomb2/z_eff_ss_bomb2.c index 6e0c17e60..12d5c38cc 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Bomb2/z_eff_ss_bomb2.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Bomb2/z_eff_ss_bomb2.c @@ -87,7 +87,7 @@ void EffectSsBomb2_DrawFade(PlayState* play, u32 index, EffectSs* this) { if (mtx != NULL) { gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80094BC4(gfxCtx); + Gfx_SetupDL_60NoCDXlu(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rPrimColorA); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, 0); @@ -134,7 +134,7 @@ void EffectSsBomb2_DrawLayered(PlayState* play, u32 index, EffectSs* this) { mtx2 = SkinMatrix_MtxFToNewMtx(gfxCtx, &mfResult); if (mtx2 != NULL) { - func_80094BC4(gfxCtx); + Gfx_SetupDL_60NoCDXlu(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rPrimColorA); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, 0); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Bubble/z_eff_ss_bubble.c b/soh/src/overlays/effects/ovl_Effect_Ss_Bubble/z_eff_ss_bubble.c index f96d60cf4..006487496 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Bubble/z_eff_ss_bubble.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Bubble/z_eff_ss_bubble.c @@ -47,7 +47,7 @@ void EffectSsBubble_Draw(PlayState* play, u32 index, EffectSs* this) { Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 255, 255, 255); gDPSetEnvColor(POLY_OPA_DISP++, 150, 150, 150, 0); gSPSegment(POLY_OPA_DISP++, 0x08, this->gfx); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_D_Fire/z_eff_ss_d_fire.c b/soh/src/overlays/effects/ovl_Effect_Ss_D_Fire/z_eff_ss_d_fire.c index ef73f691e..3ded89d2c 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_D_Fire/z_eff_ss_d_fire.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_D_Fire/z_eff_ss_d_fire.c @@ -86,7 +86,7 @@ void EffectSsDFire_Draw(PlayState* play, u32 index, EffectSs* this) { if (mtx != NULL) { gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80094BC4(gfxCtx); + Gfx_SetupDL_60NoCDXlu(gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 0); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rPrimColorA); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Db/z_eff_ss_dead_db.c b/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Db/z_eff_ss_dead_db.c index c3bdb77d4..c39779f86 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Db/z_eff_ss_dead_db.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Db/z_eff_ss_dead_db.c @@ -82,7 +82,7 @@ void EffectSsDeadDb_Draw(PlayState* play, u32 index, EffectSs* this) { if (mtx != NULL) { gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80094BC4(gfxCtx); + Gfx_SetupDL_60NoCDXlu(gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, 0); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rPrimColorA); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Dd/z_eff_ss_dead_dd.c b/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Dd/z_eff_ss_dead_dd.c index 60accff06..bb0b52cc5 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Dd/z_eff_ss_dead_dd.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Dd/z_eff_ss_dead_dd.c @@ -107,7 +107,7 @@ void EffectSsDeadDd_Draw(PlayState* play, u32 index, EffectSs* this) { mtx = SkinMatrix_MtxFToNewMtx(gfxCtx, &mfResult); if (mtx != NULL) { - func_80094BC4(gfxCtx); + Gfx_SetupDL_60NoCDXlu(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rAlpha); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, this->rAlpha); gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Ds/z_eff_ss_dead_ds.c b/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Ds/z_eff_ss_dead_ds.c index 3f20ec7ad..1ba9289bf 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Ds/z_eff_ss_dead_ds.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Dead_Ds/z_eff_ss_dead_ds.c @@ -58,7 +58,7 @@ void EffectSsDeadDs_Draw(PlayState* play, u32 index, EffectSs* this) { OPEN_DISPS(play->state.gfxCtx); scale = this->rScale * 0.01f; - func_80094BC4(play->state.gfxCtx); + Gfx_SetupDL_60NoCDXlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 0, 0, 0, this->rAlpha); gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, 0); pos = this->pos; diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Dt_Bubble/z_eff_ss_dt_bubble.c b/soh/src/overlays/effects/ovl_Effect_Ss_Dt_Bubble/z_eff_ss_dt_bubble.c index 761d3d554..def1ee6c1 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Dt_Bubble/z_eff_ss_dt_bubble.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Dt_Bubble/z_eff_ss_dt_bubble.c @@ -83,7 +83,7 @@ void EffectSsDtBubble_Draw(PlayState* play, u32 index, EffectSs* this) { Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093C14(gfxCtx); + Gfx_SetupDL_25Xlu2(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, (this->rPrimColorA * this->life) / this->rLifespan); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Dust/z_eff_ss_dust.c b/soh/src/overlays/effects/ovl_Effect_Ss_Dust/z_eff_ss_dust.c index 2c1c299b3..fee75f447 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Dust/z_eff_ss_dust.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Dust/z_eff_ss_dust.c @@ -104,7 +104,7 @@ void EffectSsDust_Draw(PlayState* play, u32 index, EffectSs* this) { gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gDPPipeSync(POLY_XLU_DISP++); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(dustTextures[this->rTexIdx])); - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0); gDPPipeSync(POLY_XLU_DISP++); if (this->rDrawFlags & 1) { diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_En_Fire/z_eff_ss_en_fire.c b/soh/src/overlays/effects/ovl_Effect_Ss_En_Fire/z_eff_ss_en_fire.c index ad884cc35..b779f3279 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_En_Fire/z_eff_ss_en_fire.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_En_Fire/z_eff_ss_en_fire.c @@ -87,7 +87,7 @@ void EffectSsEnFire_Draw(PlayState* play, u32 index, EffectSs* this) { redGreen = 0; } - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, redGreen * 12.7f, 0, 0, 0); gDPSetPrimColor(POLY_XLU_DISP++, 0x0, 0x80, redGreen * 12.7f, redGreen * 12.7f, 0, 255); gSPSegment(POLY_XLU_DISP++, 0x08, diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_En_Ice/z_eff_ss_en_ice.c b/soh/src/overlays/effects/ovl_Effect_Ss_En_Ice/z_eff_ss_en_ice.c index 28033ee1d..ef4da7dc9 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_En_Ice/z_eff_ss_en_ice.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_En_Ice/z_eff_ss_en_ice.c @@ -120,7 +120,7 @@ void EffectSsEnIce_Draw(PlayState* play, u32 index, EffectSs* this) { hiliteLightDir.y = 0.0f; hiliteLightDir.z = 89.8f; - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); func_8002EB44(&this->pos, &play->view.eye, &hiliteLightDir, play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, gameplayFrames & 0xFF, 0x20, 0x10, 1, 0, diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Extra/z_eff_ss_extra.c b/soh/src/overlays/effects/ovl_Effect_Ss_Extra/z_eff_ss_extra.c index d45ecf941..711769bd2 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Extra/z_eff_ss_extra.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Extra/z_eff_ss_extra.c @@ -69,7 +69,7 @@ void EffectSsExtra_Draw(PlayState* play, u32 index, EffectSs* this) { gSPSegment(POLY_XLU_DISP++, 0x06, object); Matrix_Translate(this->pos.x, this->pos.y, this->pos.z, MTXMODE_NEW); Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_ReplaceRotation(&play->billboardMtxF); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Fcircle/z_eff_ss_fcircle.c b/soh/src/overlays/effects/ovl_Effect_Ss_Fcircle/z_eff_ss_fcircle.c index f6de3db27..26e6173b8 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Fcircle/z_eff_ss_fcircle.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Fcircle/z_eff_ss_fcircle.c @@ -60,7 +60,7 @@ void EffectSsFcircle_Draw(PlayState* play, u32 index, EffectSs* this) { Matrix_RotateY(this->rYaw * (M_PI / 0x8000), MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, play->gameplayFrames % 128, 0, 32, 64, 1, 0, ((play->gameplayFrames) * -0xF) % 256, 32, 64)); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Fhg_Flash/z_eff_ss_fhg_flash.c b/soh/src/overlays/effects/ovl_Effect_Ss_Fhg_Flash/z_eff_ss_fhg_flash.c index 47bf032e4..3bd4349dc 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Fhg_Flash/z_eff_ss_fhg_flash.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Fhg_Flash/z_eff_ss_fhg_flash.c @@ -99,7 +99,7 @@ void EffectSsFhgFlash_DrawLightBall(PlayState* play, u32 index, EffectSs* this) Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); gSegments[6] = VIRTUAL_TO_PHYSICAL(object); gSPSegment(POLY_XLU_DISP++, 0x06, object); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, this->rAlpha); gDPSetEnvColor(POLY_XLU_DISP++, sColors[this->rParam].r, sColors[this->rParam].g, sColors[this->rParam].b, 0); gDPPipeSync(POLY_XLU_DISP++); @@ -125,11 +125,11 @@ void EffectSsFhgFlash_DrawShock(PlayState* play, u32 index, EffectSs* this) { Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); if (this->rParam != FHGFLASH_SHOCK_NO_ACTOR) { - func_80094044(play->state.gfxCtx); + Gfx_SetupDL_44Xlu(play->state.gfxCtx); Matrix_RotateX((this->rXZRot / 32768.0f) * 1.1416f, MTXMODE_APPLY); gDPSetRenderMode(POLY_XLU_DISP++, G_RM_PASS, G_RM_AA_ZB_XLU_DECAL2); } else { - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); Matrix_ReplaceRotation(&play->billboardMtxF); gDPSetRenderMode(POLY_XLU_DISP++, G_RM_PASS, G_RM_AA_ZB_XLU_SURF2); } diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Fire_Tail/z_eff_ss_fire_tail.c b/soh/src/overlays/effects/ovl_Effect_Ss_Fire_Tail/z_eff_ss_fire_tail.c index 89e154aad..4d0edb6da 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Fire_Tail/z_eff_ss_fire_tail.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Fire_Tail/z_eff_ss_fire_tail.c @@ -121,7 +121,7 @@ void EffectSsFireTail_Draw(PlayState* play, u32 index, EffectSs* this) { gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, 255); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, 0); gSPSegment(POLY_XLU_DISP++, 0x08, diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_G_Magma2/z_eff_ss_g_magma2.c b/soh/src/overlays/effects/ovl_Effect_Ss_G_Magma2/z_eff_ss_g_magma2.c index 3ea4a4a58..386a59533 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_G_Magma2/z_eff_ss_g_magma2.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_G_Magma2/z_eff_ss_g_magma2.c @@ -90,9 +90,9 @@ void EffectSsGMagma2_Draw(PlayState* play, u32 index, EffectSs* this) { G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); if (this->rDrawMode == 0) { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0x3D); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0x3D); } else { - POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 0); + POLY_XLU_DISP = Gfx_SetupDL(POLY_XLU_DISP, 0); } gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, 0, this->rPrimColorA); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_G_Ripple/z_eff_ss_g_ripple.c b/soh/src/overlays/effects/ovl_Effect_Ss_G_Ripple/z_eff_ss_g_ripple.c index 7f49a298b..adfa868f9 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_G_Ripple/z_eff_ss_g_ripple.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_G_Ripple/z_eff_ss_g_ripple.c @@ -89,7 +89,7 @@ void EffectSsGRipple_DrawRipple(PlayState* play, EffectSs* this, void* segment) if (mtx != NULL) { gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80094BC4(gfxCtx); + Gfx_SetupDL_60NoCDXlu(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rPrimColorA); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, this->rEnvColorA); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_G_Spk/z_eff_ss_g_spk.c b/soh/src/overlays/effects/ovl_Effect_Ss_G_Spk/z_eff_ss_g_spk.c index fbd7fcef5..94468dc5a 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_G_Spk/z_eff_ss_g_spk.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_G_Spk/z_eff_ss_g_spk.c @@ -94,7 +94,7 @@ void EffectSsGSpk_Draw(PlayState* play, u32 index, EffectSs* this) { if (mtx != NULL) { gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sparkTextures[this->rTexIdx])); - func_80094BC4(gfxCtx); + Gfx_SetupDL_60NoCDXlu(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, 255); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, this->rEnvColorA); gSPDisplayList(POLY_XLU_DISP++, this->gfx); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Hahen/z_eff_ss_hahen.c b/soh/src/overlays/effects/ovl_Effect_Ss_Hahen/z_eff_ss_hahen.c index e63caae43..76a8b6c1e 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Hahen/z_eff_ss_hahen.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Hahen/z_eff_ss_hahen.c @@ -83,7 +83,7 @@ void EffectSsHahen_Draw(PlayState* play, u32 index, EffectSs* this) { Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gSPDisplayList(POLY_OPA_DISP++, this->gfx); CLOSE_DISPS(gfxCtx); @@ -107,7 +107,7 @@ void EffectSsHahen_DrawGray(PlayState* play, u32 index, EffectSs* this) { Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetCombineLERP(POLY_OPA_DISP++, SHADE, 0, PRIMITIVE, 0, SHADE, 0, PRIMITIVE, 0, SHADE, 0, PRIMITIVE, 0, SHADE, 0, PRIMITIVE, 0); gDPSetPrimColor(POLY_OPA_DISP++, 0x0, 0x01, 100, 100, 120, 255); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_HitMark/z_eff_ss_hitmark.c b/soh/src/overlays/effects/ovl_Effect_Ss_HitMark/z_eff_ss_hitmark.c index b4a9bad86..86ed36d8a 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_HitMark/z_eff_ss_hitmark.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_HitMark/z_eff_ss_hitmark.c @@ -93,7 +93,7 @@ void EffectSsHitMark_Draw(PlayState* play, u32 index, EffectSs* this) { if (mtx != NULL) { gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sTextures[(this->rType * 8) + (this->rTexIdx)])); - func_80094C50(gfxCtx); + Gfx_SetupDL_61Xlu(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, 255); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, 0); gSPDisplayList(POLY_XLU_DISP++, this->gfx); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Ice_Piece/z_eff_ss_ice_piece.c b/soh/src/overlays/effects/ovl_Effect_Ss_Ice_Piece/z_eff_ss_ice_piece.c index 167a33c9c..68bef6864 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Ice_Piece/z_eff_ss_ice_piece.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Ice_Piece/z_eff_ss_ice_piece.c @@ -67,7 +67,7 @@ void EffectSsIcePiece_Draw(PlayState* play, u32 index, EffectSs* this) { Matrix_RotateX(this->rPitch * (M_PI / 0x8000), MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gDPSetEnvColor(POLY_XLU_DISP++, 0, 50, 100, (s32)alpha & 0xFF); func_8003435C(&this->pos, play); gSPSegment(POLY_XLU_DISP++, 0x08, diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Ice_Smoke/z_eff_ss_ice_smoke.c b/soh/src/overlays/effects/ovl_Effect_Ss_Ice_Smoke/z_eff_ss_ice_smoke.c index 5b643ed4f..ec56ef130 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Ice_Smoke/z_eff_ss_ice_smoke.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Ice_Smoke/z_eff_ss_ice_smoke.c @@ -65,7 +65,7 @@ void EffectSsIceSmoke_Draw(PlayState* play, u32 index, EffectSs* this) { if ((objBankIdx > -1) && Object_IsLoaded(&play->objectCtx, objBankIdx)) { gDPPipeSync(POLY_XLU_DISP++); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSegments[6] = VIRTUAL_TO_PHYSICAL(object); gSPSegment(POLY_XLU_DISP++, 0x06, object); gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gFreezardSteamStartDL)); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_K_Fire/z_eff_ss_k_fire.c b/soh/src/overlays/effects/ovl_Effect_Ss_K_Fire/z_eff_ss_k_fire.c index 317f71d52..1ddaebcdd 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_K_Fire/z_eff_ss_k_fire.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_K_Fire/z_eff_ss_k_fire.c @@ -53,7 +53,7 @@ void EffectSsKFire_Draw(PlayState* play, u32 index, EffectSs* this) { Matrix_Translate(this->pos.x, this->pos.y, this->pos.z, MTXMODE_NEW); Matrix_Scale(xzScale, yScale, xzScale, MTXMODE_APPLY); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, play->state.frames * this->rScroll, 0x20, 0x80)); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Kakera/z_eff_ss_kakera.c b/soh/src/overlays/effects/ovl_Effect_Ss_Kakera/z_eff_ss_kakera.c index 7c4944aa1..1a0222e9f 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Kakera/z_eff_ss_kakera.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Kakera/z_eff_ss_kakera.c @@ -114,7 +114,7 @@ void EffectSsKakera_Draw(PlayState* play, u32 index, EffectSs* this) { if ((((this->rReg4 >> 7) & 1) << 7) == 0x80) { gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D84(play->state.gfxCtx); + Gfx_SetupDL_25Xlu(play->state.gfxCtx); if (colorIdx >= 0) { gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, colors[colorIdx].r, colors[colorIdx].g, colors[colorIdx].b, 255); @@ -124,7 +124,7 @@ void EffectSsKakera_Draw(PlayState* play, u32 index, EffectSs* this) { } else { gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D18(play->state.gfxCtx); + Gfx_SetupDL_25Opa(play->state.gfxCtx); if (colorIdx >= 0) { gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, colors[colorIdx].r, colors[colorIdx].g, colors[colorIdx].b, 255); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_KiraKira/z_eff_ss_kirakira.c b/soh/src/overlays/effects/ovl_Effect_Ss_KiraKira/z_eff_ss_kirakira.c index 078914439..83b412a07 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_KiraKira/z_eff_ss_kirakira.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_KiraKira/z_eff_ss_kirakira.c @@ -103,7 +103,7 @@ void EffectSsKiraKira_Draw(PlayState* play, u32 index, EffectSs* this) { if (mtx != NULL) { gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093C14(gfxCtx); + Gfx_SetupDL_25Xlu2(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, (((s8)((55.0f / this->rLifespan) * this->life) + 200))); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, this->rEnvColorA); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Lightning/z_eff_ss_lightning.c b/soh/src/overlays/effects/ovl_Effect_Ss_Lightning/z_eff_ss_lightning.c index f0ed53c12..8e0e35f01 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Lightning/z_eff_ss_lightning.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Lightning/z_eff_ss_lightning.c @@ -106,7 +106,7 @@ void EffectSsLightning_Draw(PlayState* play, u32 index, EffectSs* this) { if (mtx != NULL) { gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80094C50(gfxCtx); + Gfx_SetupDL_61Xlu(gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(lightningTextures[texIdx])); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rPrimColorA); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Sibuki/z_eff_ss_sibuki.c b/soh/src/overlays/effects/ovl_Effect_Ss_Sibuki/z_eff_ss_sibuki.c index 60bf9aba0..690320fed 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Sibuki/z_eff_ss_sibuki.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Sibuki/z_eff_ss_sibuki.c @@ -69,7 +69,7 @@ void EffectSsSibuki_Draw(PlayState* play, u32 index, EffectSs* this) { Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rPrimColorA); gDPSetEnvColor(POLY_OPA_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, this->rEnvColorA); gSPSegment(POLY_OPA_DISP++, 0x08, this->gfx); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Sibuki2/z_eff_ss_sibuki2.c b/soh/src/overlays/effects/ovl_Effect_Ss_Sibuki2/z_eff_ss_sibuki2.c index f944d4fa7..d3e127c13 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Sibuki2/z_eff_ss_sibuki2.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Sibuki2/z_eff_ss_sibuki2.c @@ -65,7 +65,7 @@ void EffectSsSibuki2_Draw(PlayState* play, u32 index, EffectSs* this) { Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rPrimColorA); gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, this->rEnvColorA); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(bubbleTextures[this->rTexIdx])); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Stick/z_eff_ss_stick.c b/soh/src/overlays/effects/ovl_Effect_Ss_Stick/z_eff_ss_stick.c index bdd1868ae..bcd9a5730 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Stick/z_eff_ss_stick.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Stick/z_eff_ss_stick.c @@ -66,7 +66,7 @@ void EffectSsStick_Draw(PlayState* play, u32 index, EffectSs* this) { gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80093D18(gfxCtx); + Gfx_SetupDL_25Opa(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x06, play->objectCtx.status[this->rObjBankIdx].segment); gSPSegment(POLY_OPA_DISP++, 0x0C, gCullBackDList); gSPDisplayList(POLY_OPA_DISP++, this->gfx); diff --git a/soh/src/overlays/effects/ovl_Effect_Ss_Stone1/z_eff_ss_stone1.c b/soh/src/overlays/effects/ovl_Effect_Ss_Stone1/z_eff_ss_stone1.c index 378990470..199a45dc3 100644 --- a/soh/src/overlays/effects/ovl_Effect_Ss_Stone1/z_eff_ss_stone1.c +++ b/soh/src/overlays/effects/ovl_Effect_Ss_Stone1/z_eff_ss_stone1.c @@ -64,7 +64,7 @@ void EffectSsStone1_Draw(PlayState* play, u32 index, EffectSs* this) { Matrix_Scale(scale, scale, scale, MTXMODE_APPLY); gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - func_80094C50(gfxCtx); + Gfx_SetupDL_61Xlu(gfxCtx); gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(drawParams->texture)); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, drawParams->primColor.r, drawParams->primColor.g, drawParams->primColor.b, 255); diff --git a/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c b/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c index 6c8882814..c74f8e513 100644 --- a/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c +++ b/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c @@ -1418,7 +1418,7 @@ void FileChoose_DrawWindowContents(GameState* thisx) { this->configMode == CM_NAME_ENTRY_TO_QUEST_MENU) { // draw control stick prompts. if (MIN_QUEST != MAX_QUEST) { - func_800944C4(this->state.gfxCtx); + Gfx_SetupDL_39Opa(this->state.gfxCtx); gDPSetCombineMode(POLY_OPA_DISP++, G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM); gDPLoadTextureBlock(POLY_OPA_DISP++, gArrowCursorTex, G_IM_FMT_IA, G_IM_SIZ_8b, 16, 24, 0, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP, 4, G_TX_NOMASK, G_TX_NOLOD, @@ -1741,7 +1741,7 @@ void FileChoose_ConfigModeDraw(GameState* thisx) { ZREG(11) += ZREG(10); Environment_UpdateSkybox(NULL, SKYBOX_NORMAL_SKY, &this->envCtx, &this->skyboxCtx); gDPPipeSync(POLY_OPA_DISP++); - func_800949A8(this->state.gfxCtx); + Gfx_SetupDL_42Opa(this->state.gfxCtx); FileChoose_SetView(this, 0.0f, 0.0f, 64.0f); FileChoose_SetWindowVtx(&this->state); FileChoose_SetWindowContentVtx(&this->state); @@ -2231,7 +2231,7 @@ void FileChoose_SelectModeDraw(GameState* thisx) { ZREG(11) += ZREG(10); Environment_UpdateSkybox(NULL, SKYBOX_NORMAL_SKY, &this->envCtx, &this->skyboxCtx); gDPPipeSync(POLY_OPA_DISP++); - func_800949A8(this->state.gfxCtx); + Gfx_SetupDL_42Opa(this->state.gfxCtx); FileChoose_SetView(this, 0.0f, 0.0f, 64.0f); FileChoose_SetWindowVtx(&this->state); FileChoose_SetWindowContentVtx(&this->state); @@ -2316,7 +2316,7 @@ void FileChoose_Main(GameState* thisx) { gSPSegment(POLY_OPA_DISP++, 0x01, this->staticSegment); gSPSegment(POLY_OPA_DISP++, 0x02, this->parameterSegment); - func_80095248(this->state.gfxCtx, 0, 0, 0); + Gfx_SetupFrame(this->state.gfxCtx, 0, 0, 0); this->stickRelX = input->rel.stick_x; this->stickRelY = input->rel.stick_y; @@ -2433,7 +2433,7 @@ void FileChoose_Main(GameState* thisx) { // do not draw controls text in the options menu if ((this->configMode <= CM_NAME_ENTRY_TO_MAIN) || (this->configMode >= CM_UNUSED_DELAY)) { - func_800944C4(this->state.gfxCtx); + Gfx_SetupDL_39Opa(this->state.gfxCtx); gDPSetCombineLERP(POLY_OPA_DISP++, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0); diff --git a/soh/src/overlays/gamestates/ovl_file_choose/z_file_nameset_PAL.c b/soh/src/overlays/gamestates/ovl_file_choose/z_file_nameset_PAL.c index 42ced48e1..46476a32c 100644 --- a/soh/src/overlays/gamestates/ovl_file_choose/z_file_nameset_PAL.c +++ b/soh/src/overlays/gamestates/ovl_file_choose/z_file_nameset_PAL.c @@ -250,7 +250,7 @@ void FileChoose_DrawKeyboard(GameState* thisx) { OPEN_DISPS(this->state.gfxCtx); - func_800949A8(this->state.gfxCtx); + Gfx_SetupDL_42Opa(this->state.gfxCtx); gDPSetCycleType(POLY_OPA_DISP++, G_CYC_2CYCLE); gDPSetRenderMode(POLY_OPA_DISP++, G_RM_PASS, G_RM_XLU_SURF2); gDPSetCombineLERP(POLY_OPA_DISP++, 0, 0, 0, PRIMITIVE, TEXEL1, TEXEL0, PRIM_LOD_FRAC, TEXEL0, 0, 0, 0, COMBINED, 0, @@ -365,7 +365,7 @@ void FileChoose_DrawNameEntry(GameState* thisx) { FileChoose_DrawKeyboard(&this->state); gDPPipeSync(POLY_OPA_DISP++); - func_800949A8(this->state.gfxCtx); + Gfx_SetupDL_42Opa(this->state.gfxCtx); gDPSetCombineLERP(POLY_OPA_DISP++, 0, 0, 0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0, 0, 0, 0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0); diff --git a/soh/src/overlays/gamestates/ovl_opening/z_opening.c b/soh/src/overlays/gamestates/ovl_opening/z_opening.c index 433523fd1..a45e2db74 100644 --- a/soh/src/overlays/gamestates/ovl_opening/z_opening.c +++ b/soh/src/overlays/gamestates/ovl_opening/z_opening.c @@ -25,7 +25,7 @@ void func_80803C5C(OpeningContext* this) { void Opening_Main(GameState* thisx) { OpeningContext* this = (OpeningContext*)thisx; - func_80095248(this->state.gfxCtx, 0, 0, 0); + Gfx_SetupFrame(this->state.gfxCtx, 0, 0, 0); Opening_SetupTitleScreen(this); func_80803C5C(this); } diff --git a/soh/src/overlays/gamestates/ovl_select/z_select.c b/soh/src/overlays/gamestates/ovl_select/z_select.c index 743bb43c9..082275c5f 100644 --- a/soh/src/overlays/gamestates/ovl_select/z_select.c +++ b/soh/src/overlays/gamestates/ovl_select/z_select.c @@ -1219,10 +1219,10 @@ void Select_DrawMenu(SelectContext* this) { OPEN_DISPS(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x00, NULL); - func_80095248(gfxCtx, 0, 0, 0); + Gfx_SetupFrame(gfxCtx, 0, 0, 0); SET_FULLSCREEN_VIEWPORT(&this->view); func_800AAA50(&this->view, 0xF); - func_80094140(gfxCtx); + Gfx_SetupDL_28Opa(gfxCtx); printer = alloca(sizeof(GfxPrint)); GfxPrint_Init(printer); @@ -1249,10 +1249,10 @@ void Select_DrawLoadingScreen(SelectContext* this) { OPEN_DISPS(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x00, NULL); - func_80095248(gfxCtx, 0, 0, 0); + Gfx_SetupFrame(gfxCtx, 0, 0, 0); SET_FULLSCREEN_VIEWPORT(&this->view); func_800AAA50(&this->view, 0xF); - func_80094140(gfxCtx); + Gfx_SetupDL_28Opa(gfxCtx); printer = alloca(sizeof(GfxPrint)); GfxPrint_Init(printer); @@ -1270,7 +1270,7 @@ void Select_Draw(SelectContext* this) { OPEN_DISPS(gfxCtx); gSPSegment(POLY_OPA_DISP++, 0x00, NULL); - func_80095248(gfxCtx, 0, 0, 0); + Gfx_SetupFrame(gfxCtx, 0, 0, 0); SET_FULLSCREEN_VIEWPORT(&this->view); func_800AAA50(&this->view, 0xF); diff --git a/soh/src/overlays/gamestates/ovl_title/z_title.c b/soh/src/overlays/gamestates/ovl_title/z_title.c index 296cc904e..29e420690 100644 --- a/soh/src/overlays/gamestates/ovl_title/z_title.c +++ b/soh/src/overlays/gamestates/ovl_title/z_title.c @@ -24,7 +24,7 @@ void Title_PrintBuildInfo(Gfx** gfxp) { GfxPrint printer; g = *gfxp; - g = func_8009411C(g); + g = Gfx_SetupDL_28(g); //printer = alloca(sizeof(GfxPrint)); GfxPrint_Init(&printer); GfxPrint_Open(&printer, g); @@ -199,14 +199,14 @@ void Title_Draw(TitleContext* this) { func_8002EABC(&v1, &v2, &v3, this->state.gfxCtx); gSPSetLights1(POLY_OPA_DISP++, sTitleLights); Title_SetupView(this, 0, 150.0, 300.0); - func_80093D18(this->state.gfxCtx); + Gfx_SetupDL_25Opa(this->state.gfxCtx); Matrix_Translate(-53.0, -5.0, 0, MTXMODE_NEW); Matrix_Scale(1.0, 1.0, 1.0, MTXMODE_APPLY); Matrix_RotateZYX(0, sTitleRotY, 0, MTXMODE_APPLY); gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(this->state.gfxCtx), G_MTX_LOAD); gSPDisplayList(POLY_OPA_DISP++, gNintendo64LogoDL); - func_800944C4(this->state.gfxCtx); + Gfx_SetupDL_39Opa(this->state.gfxCtx); gDPPipeSync(POLY_OPA_DISP++); gDPSetCycleType(POLY_OPA_DISP++, G_CYC_2CYCLE); gDPSetRenderMode(POLY_OPA_DISP++, G_RM_XLU_SURF2, G_RM_OPA_CI | CVG_DST_WRAP); @@ -242,7 +242,7 @@ void Title_Main(GameState* thisx) { gSPSegment(POLY_OPA_DISP++, 0, NULL); gSPSegment(POLY_OPA_DISP++, 1, this->staticSegment); - func_80095248(this->state.gfxCtx, 0, 0, 0); + Gfx_SetupFrame(this->state.gfxCtx, 0, 0, 0); Title_Calc(this); Title_Draw(this); diff --git a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_debug.c b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_debug.c index 5d2028c08..a160576d9 100644 --- a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_debug.c +++ b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_debug.c @@ -115,7 +115,7 @@ void KaleidoScope_DrawDebugEditor(PlayState* play) { pauseCtx->stickRelX = input->rel.stick_x; pauseCtx->stickRelY = input->rel.stick_y; - func_800944C4_KAL(play->state.gfxCtx); + Gfx_SetupDL_39Kal(play->state.gfxCtx); gDPSetRenderMode(POLY_KAL_DISP++, G_RM_XLU_SURF, G_RM_XLU_SURF2); gDPSetCombineMode(POLY_KAL_DISP++, G_CC_PRIMITIVE, G_CC_PRIMITIVE); diff --git a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_equipment.c b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_equipment.c index 15765d80e..34ac13afa 100644 --- a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_equipment.c +++ b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_equipment.c @@ -657,7 +657,7 @@ void KaleidoScope_DrawEquipment(PlayState* play) { } } - func_800949A8(play->state.gfxCtx); + Gfx_SetupDL_42Opa(play->state.gfxCtx); gDPSetCombineMode(POLY_KAL_DISP++, G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM); gDPSetPrimColor(POLY_KAL_DISP++, 0, 0, 255, 255, 255, pauseCtx->alpha); @@ -739,7 +739,7 @@ void KaleidoScope_DrawEquipment(PlayState* play) { gSPSegment(POLY_KAL_DISP++, 0x0B, play->interfaceCtx.mapSegment); //gSPSegment(POLY_KAL_DISP++, 0x0C, pauseCtx->iconItemAltSegment); - func_800949A8_KAL(play->state.gfxCtx); + Gfx_SetupDL_42Kal(play->state.gfxCtx); KaleidoScope_DrawEquipmentImage(play, pauseCtx->playerSegment, 64, 112); if (gUpgradeMasks[0]) {} diff --git a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_item.c b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_item.c index a237fc11b..607afb979 100644 --- a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_item.c +++ b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_item.c @@ -104,7 +104,7 @@ void KaleidoScope_DrawItemSelect(PlayState* play) { OPEN_DISPS(play->state.gfxCtx); - func_800949A8(play->state.gfxCtx); + Gfx_SetupDL_42Opa(play->state.gfxCtx); gDPSetCombineMode(POLY_KAL_DISP++, G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM); diff --git a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_map_PAL.c b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_map_PAL.c index f29647be6..1e0cdfaad 100644 --- a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_map_PAL.c +++ b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_map_PAL.c @@ -562,7 +562,7 @@ void KaleidoScope_DrawWorldMap(PlayState* play, GraphicsContext* gfxCtx) { gDPPipeSync(POLY_KAL_DISP++); gDPSetTextureFilter(POLY_KAL_DISP++, G_TF_BILERP); - func_800949A8(gfxCtx); + Gfx_SetupDL_42Opa(gfxCtx); gDPSetCombineLERP(POLY_KAL_DISP++, 1, 0, PRIMITIVE, 0, TEXEL0, 0, PRIMITIVE, 0, 1, 0, PRIMITIVE, 0, TEXEL0, 0, PRIMITIVE, 0); @@ -671,7 +671,7 @@ void KaleidoScope_DrawWorldMap(PlayState* play, GraphicsContext* gfxCtx) { pointPulseTimer = 20; } - func_800949A8(gfxCtx); + Gfx_SetupDL_42Opa(gfxCtx); gDPSetCombineLERP(POLY_KAL_DISP++, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0); diff --git a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c index 22821a5ac..7d6661696 100644 --- a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c +++ b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c @@ -1349,7 +1349,7 @@ void KaleidoScope_DrawPages(PlayState* play, GraphicsContext* gfxCtx) { if (sInDungeonScene) { KaleidoScope_DrawDungeonMap(play, gfxCtx); - func_800949A8(gfxCtx); + Gfx_SetupDL_42Opa(gfxCtx); gDPSetCombineMode(POLY_KAL_DISP++, G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM); @@ -1393,7 +1393,7 @@ void KaleidoScope_DrawPages(PlayState* play, GraphicsContext* gfxCtx) { if (sInDungeonScene) { KaleidoScope_DrawDungeonMap(play, gfxCtx); - func_800949A8(gfxCtx); + Gfx_SetupDL_42Opa(gfxCtx); gDPSetCombineMode(POLY_KAL_DISP++, G_CC_MODULATEIA_PRIM, G_CC_MODULATEIA_PRIM); @@ -1451,7 +1451,7 @@ void KaleidoScope_DrawPages(PlayState* play, GraphicsContext* gfxCtx) { } } - func_800949A8(gfxCtx); + Gfx_SetupDL_42Opa(gfxCtx); if ((pauseCtx->state == 7) || ((pauseCtx->state >= 8) && (pauseCtx->state < 0x12))) { KaleidoScope_UpdatePrompt(play); @@ -3006,7 +3006,7 @@ void KaleidoScope_DrawGameOver(PlayState* play) { OPEN_DISPS(gfxCtx); - func_800944C4(gfxCtx); + Gfx_SetupDL_39Opa(gfxCtx); gDPSetCycleType(POLY_KAL_DISP++, G_CYC_2CYCLE); gDPSetRenderMode(POLY_KAL_DISP++, G_RM_PASS, G_RM_XLU_SURF2); @@ -3068,11 +3068,11 @@ void KaleidoScope_Draw(PlayState* play) { { KaleidoScope_SetView(pauseCtx, pauseCtx->eye.x, pauseCtx->eye.y, pauseCtx->eye.z); - func_800949A8_KAL(play->state.gfxCtx); + Gfx_SetupDL_42Kal(play->state.gfxCtx); KaleidoScope_InitVertices(play, play->state.gfxCtx); KaleidoScope_DrawPages(play, play->state.gfxCtx); - func_800949A8_KAL(play->state.gfxCtx); + Gfx_SetupDL_42Kal(play->state.gfxCtx); gDPSetCombineLERP(POLY_KAL_DISP++, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0); From 7e9c5d428cba2a30eab325ff567a5220e635d94c Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Tue, 29 Nov 2022 18:30:52 -0500 Subject: [PATCH 18/25] Use gerudo fortress enum (#2040) Co-authored-by: briaguya --- soh/soh/Enhancements/presets.h | 2 +- soh/soh/Enhancements/randomizer/randomizer.cpp | 2 +- soh/src/code/z_sram.c | 7 +++---- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/soh/soh/Enhancements/presets.h b/soh/soh/Enhancements/presets.h index 02768cb86..64615914a 100644 --- a/soh/soh/Enhancements/presets.h +++ b/soh/soh/Enhancements/presets.h @@ -556,7 +556,7 @@ const std::vector s6PresetEntries = { PRESET_ENTRY_STRING("gRandomizeExcludedLocations", "48,"), PRESET_ENTRY_S32("gRandomizeForest", 1), PRESET_ENTRY_S32("gRandomizeGanonTrial", 0), - PRESET_ENTRY_S32("gRandomizeGerudoFortress", 1), + PRESET_ENTRY_S32("gRandomizeGerudoFortress", RO_GF_FAST), PRESET_ENTRY_S32("gRandomizeIceTraps", 0), PRESET_ENTRY_S32("gRandomizeKakarikoGate", 1), PRESET_ENTRY_S32("gRandomizeMedallionCount", 6), diff --git a/soh/soh/Enhancements/randomizer/randomizer.cpp b/soh/soh/Enhancements/randomizer/randomizer.cpp index 72055d921..fd54c2e29 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer.cpp @@ -2565,7 +2565,7 @@ void GenerateRandomizerImgui() { cvarSettings[RSK_DOOR_OF_TIME] = CVar_GetS32("gRandomizeDoorOfTime", RO_DOOROFTIME_CLOSED); cvarSettings[RSK_ZORAS_FOUNTAIN] = CVar_GetS32("gRandomizeZorasFountain", 0); cvarSettings[RSK_STARTING_AGE] = CVar_GetS32("gRandomizeStartingAge", 0); - cvarSettings[RSK_GERUDO_FORTRESS] = CVar_GetS32("gRandomizeGerudoFortress", 0); + cvarSettings[RSK_GERUDO_FORTRESS] = CVar_GetS32("gRandomizeGerudoFortress", RO_GF_NORMAL); cvarSettings[RSK_RAINBOW_BRIDGE] = CVar_GetS32("gRandomizeRainbowBridge", 0); cvarSettings[RSK_RAINBOW_BRIDGE_STONE_COUNT] = CVar_GetS32("gRandomizeStoneCount", 3); cvarSettings[RSK_RAINBOW_BRIDGE_MEDALLION_COUNT] = CVar_GetS32("gRandomizeMedallionCount", 6); diff --git a/soh/src/code/z_sram.c b/soh/src/code/z_sram.c index 9cdc54b01..822852bd6 100644 --- a/soh/src/code/z_sram.c +++ b/soh/src/code/z_sram.c @@ -539,8 +539,8 @@ void Sram_InitSave(FileChooseContext* fileChooseCtx) { // skip verbose lake owl, skip to "i'm on my way back to the castle" gSaveContext.infTable[25] |= 0x20; - // fast gerudo fortress - if (Randomizer_GetSettingValue(RSK_GERUDO_FORTRESS) == 1 || Randomizer_GetSettingValue(RSK_GERUDO_FORTRESS) == 2) { + if (Randomizer_GetSettingValue(RSK_GERUDO_FORTRESS) == RO_GF_FAST || + Randomizer_GetSettingValue(RSK_GERUDO_FORTRESS) == RO_GF_OPEN) { gSaveContext.eventChkInf[9] |= 2; gSaveContext.eventChkInf[9] |= 4; gSaveContext.eventChkInf[9] |= 8; @@ -558,8 +558,7 @@ void Sram_InitSave(FileChooseContext* fileChooseCtx) { gSaveContext.sceneFlags[12].collect |= (1 << 0x0F); } - // open gerudo fortress - if (Randomizer_GetSettingValue(RSK_GERUDO_FORTRESS) == 2) { + if (Randomizer_GetSettingValue(RSK_GERUDO_FORTRESS) == RO_GF_OPEN) { gSaveContext.eventChkInf[9] |= 1; gSaveContext.sceneFlags[12].swch |= (1 << 0x01); gSaveContext.sceneFlags[12].swch |= (1 << 0x05); From bfc0ca5388140c3924a5be5ea7c3ea7ce9df84e5 Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Tue, 29 Nov 2022 18:31:59 -0500 Subject: [PATCH 19/25] Use enum values for item pool (#2042) * use enum values for item pool * Update soh/soh/Enhancements/presets.h Co-authored-by: Garrett Cox Co-authored-by: briaguya Co-authored-by: Garrett Cox --- soh/soh/Enhancements/presets.h | 2 +- soh/soh/Enhancements/randomizer/randomizer.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/soh/soh/Enhancements/presets.h b/soh/soh/Enhancements/presets.h index 64615914a..a95ff6830 100644 --- a/soh/soh/Enhancements/presets.h +++ b/soh/soh/Enhancements/presets.h @@ -596,7 +596,7 @@ const std::vector hellModePresetEntries = { PRESET_ENTRY_S32("gRandomizeGerudoKeys", 3), PRESET_ENTRY_S32("gRandomizeGsExpectSunsSong", 1), PRESET_ENTRY_S32("gRandomizeIceTraps", 4), - PRESET_ENTRY_S32("gRandomizeItemPool", 1), + PRESET_ENTRY_S32("gRandomizeItemPool", RO_ITEM_POOL_MINIMAL), PRESET_ENTRY_S32("gRandomizeKakarikoGate", 1), PRESET_ENTRY_S32("gRandomizeKeysanity", 5), PRESET_ENTRY_S32("gRandomizeLinksPocket", 3), diff --git a/soh/soh/Enhancements/randomizer/randomizer.cpp b/soh/soh/Enhancements/randomizer/randomizer.cpp index fd54c2e29..0e4782015 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer.cpp @@ -2603,7 +2603,7 @@ void GenerateRandomizerImgui() { cvarSettings[RSK_SHUFFLE_GERUDO_MEMBERSHIP_CARD] = CVar_GetS32("gRandomizeShuffleGerudoToken", 0); cvarSettings[RSK_SHUFFLE_FROG_SONG_RUPEES] = CVar_GetS32("gRandomizeShuffleFrogSongRupees", 0); - cvarSettings[RSK_ITEM_POOL] = CVar_GetS32("gRandomizeItemPool", 1); + cvarSettings[RSK_ITEM_POOL] = CVar_GetS32("gRandomizeItemPool", RO_ITEM_POOL_BALANCED); cvarSettings[RSK_ICE_TRAPS] = CVar_GetS32("gRandomizeIceTraps", 1); cvarSettings[RSK_GOSSIP_STONE_HINTS] = CVar_GetS32("gRandomizeGossipStoneHints", 1); cvarSettings[RSK_HINT_CLARITY] = CVar_GetS32("gRandomizeHintClarity", 2); From ec8ec8d3225f0f9438303d388826ba000af67376 Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Tue, 29 Nov 2022 18:33:38 -0500 Subject: [PATCH 20/25] Use enum for kak gate (#2043) Co-authored-by: briaguya Co-authored-by: David Chavez --- soh/soh/Enhancements/presets.h | 4 ++-- soh/soh/Enhancements/randomizer/randomizer.cpp | 8 ++++---- soh/soh/Enhancements/randomizer/randomizerTypes.h | 4 ++++ soh/src/code/z_sram.c | 7 ++----- .../actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c | 2 +- 5 files changed, 13 insertions(+), 12 deletions(-) diff --git a/soh/soh/Enhancements/presets.h b/soh/soh/Enhancements/presets.h index a95ff6830..f3cb98a5c 100644 --- a/soh/soh/Enhancements/presets.h +++ b/soh/soh/Enhancements/presets.h @@ -558,7 +558,7 @@ const std::vector s6PresetEntries = { PRESET_ENTRY_S32("gRandomizeGanonTrial", 0), PRESET_ENTRY_S32("gRandomizeGerudoFortress", RO_GF_FAST), PRESET_ENTRY_S32("gRandomizeIceTraps", 0), - PRESET_ENTRY_S32("gRandomizeKakarikoGate", 1), + PRESET_ENTRY_S32("gRandomizeKakarikoGate", RO_KAK_GATE_OPEN), PRESET_ENTRY_S32("gRandomizeMedallionCount", 6), PRESET_ENTRY_S32("gRandomizeMqDungeons", 0), PRESET_ENTRY_S32("gRandomizeRainbowBridge", 3), @@ -597,7 +597,7 @@ const std::vector hellModePresetEntries = { PRESET_ENTRY_S32("gRandomizeGsExpectSunsSong", 1), PRESET_ENTRY_S32("gRandomizeIceTraps", 4), PRESET_ENTRY_S32("gRandomizeItemPool", RO_ITEM_POOL_MINIMAL), - PRESET_ENTRY_S32("gRandomizeKakarikoGate", 1), + PRESET_ENTRY_S32("gRandomizeKakarikoGate", RO_KAK_GATE_OPEN), PRESET_ENTRY_S32("gRandomizeKeysanity", 5), PRESET_ENTRY_S32("gRandomizeLinksPocket", 3), PRESET_ENTRY_S32("gRandomizeMqDungeons", 2), diff --git a/soh/soh/Enhancements/randomizer/randomizer.cpp b/soh/soh/Enhancements/randomizer/randomizer.cpp index 0e4782015..4427b0766 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer.cpp @@ -603,9 +603,9 @@ void Randomizer::ParseRandomizerSettingsFile(const char* spoilerFileName) { break; case RSK_KAK_GATE: if(it.value() == "Closed") { - gSaveContext.randoSettings[index].value = RO_GENERIC_OFF; + gSaveContext.randoSettings[index].value = RO_KAK_GATE_CLOSED; } else if(it.value() == "Open") { - gSaveContext.randoSettings[index].value = RO_GENERIC_ON; + gSaveContext.randoSettings[index].value = RO_KAK_GATE_OPEN; } break; case RSK_DOOR_OF_TIME: @@ -2561,7 +2561,7 @@ void GenerateRandomizerImgui() { std::unordered_map cvarSettings; cvarSettings[RSK_LOGIC_RULES] = CVar_GetS32("gRandomizeLogicRules", 0); cvarSettings[RSK_FOREST] = CVar_GetS32("gRandomizeForest", 0); - cvarSettings[RSK_KAK_GATE] = CVar_GetS32("gRandomizeKakarikoGate", 0); + cvarSettings[RSK_KAK_GATE] = CVar_GetS32("gRandomizeKakarikoGate", RO_KAK_GATE_CLOSED); cvarSettings[RSK_DOOR_OF_TIME] = CVar_GetS32("gRandomizeDoorOfTime", RO_DOOROFTIME_CLOSED); cvarSettings[RSK_ZORAS_FOUNTAIN] = CVar_GetS32("gRandomizeZorasFountain", 0); cvarSettings[RSK_STARTING_AGE] = CVar_GetS32("gRandomizeStartingAge", 0); @@ -2841,7 +2841,7 @@ void DrawRandoEditor(bool& open) { "Open - The gate is always open. The happy mask shop " "will open immediately after obtaining Zelda's letter." ); - UIWidgets::EnhancementCombobox("gRandomizeKakarikoGate", randoKakarikoGate, 2, RO_GENERIC_DONT_SKIP); + UIWidgets::EnhancementCombobox("gRandomizeKakarikoGate", randoKakarikoGate, 2, RO_KAK_GATE_CLOSED); UIWidgets::PaddedSeparator(); diff --git a/soh/soh/Enhancements/randomizer/randomizerTypes.h b/soh/soh/Enhancements/randomizer/randomizerTypes.h index 8af56dc70..f079a4f8c 100644 --- a/soh/soh/Enhancements/randomizer/randomizerTypes.h +++ b/soh/soh/Enhancements/randomizer/randomizerTypes.h @@ -1105,6 +1105,10 @@ typedef enum RandoOption { RO_GF_FAST, RO_GF_OPEN, + //Kakariko Gate settings (closed/open) + RO_KAK_GATE_CLOSED = 0, + RO_KAK_GATE_OPEN, + //Rainbow Bridge settings (always open, vanilla, stones, medallions, dungeon rewards, dungeons, tokens) RO_BRIDGE_ALWAYS_OPEN = 0, RO_BRIDGE_VANILLA, diff --git a/soh/src/code/z_sram.c b/soh/src/code/z_sram.c index 822852bd6..43d1712af 100644 --- a/soh/src/code/z_sram.c +++ b/soh/src/code/z_sram.c @@ -404,11 +404,8 @@ void Sram_InitSave(FileChooseContext* fileChooseCtx) { break; } - int kakGate = Randomizer_GetSettingValue(RSK_KAK_GATE); - switch (kakGate) { - case 1: // open - gSaveContext.infTable[7] |= 0x40; - break; + if (Randomizer_GetSettingValue(RSK_KAK_GATE) == RO_KAK_GATE_OPEN) { + gSaveContext.infTable[7] |= 0x40; } if(Randomizer_GetSettingValue(RSK_STARTING_KOKIRI_SWORD)) Item_Give(NULL, ITEM_SWORD_KOKIRI); diff --git a/soh/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c b/soh/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c index ff5ea2472..8e722c063 100644 --- a/soh/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c +++ b/soh/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c @@ -46,7 +46,7 @@ void BgGateShutter_Init(Actor* thisx, PlayState* play) { this->somePos.z = thisx->world.pos.z; if (((gSaveContext.infTable[7] & 0x40) || (!gSaveContext.n64ddFlag && (gSaveContext.eventChkInf[4] & 0x20)) || - (gSaveContext.n64ddFlag && Randomizer_GetSettingValue(RSK_KAK_GATE))) && + (gSaveContext.n64ddFlag && (Randomizer_GetSettingValue(RSK_KAK_GATE) == RO_KAK_GATE_OPEN))) && (play->sceneNum == SCENE_SPOT01)) { thisx->world.pos.x = -89.0f; thisx->world.pos.z = -1375.0f; From aba034ef53627e91dac059b2785cbe435abd4dad Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Tue, 29 Nov 2022 18:37:53 -0500 Subject: [PATCH 21/25] Use enum for links pocket, dungeon reward shuffle (#2045) Co-authored-by: briaguya --- soh/soh/Enhancements/presets.h | 6 +++--- soh/soh/Enhancements/randomizer/randomizer.cpp | 9 +++++---- soh/src/code/z_sram.c | 2 +- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/soh/soh/Enhancements/presets.h b/soh/soh/Enhancements/presets.h index f3cb98a5c..fbe7f8bd2 100644 --- a/soh/soh/Enhancements/presets.h +++ b/soh/soh/Enhancements/presets.h @@ -563,7 +563,7 @@ const std::vector s6PresetEntries = { PRESET_ENTRY_S32("gRandomizeMqDungeons", 0), PRESET_ENTRY_S32("gRandomizeRainbowBridge", 3), PRESET_ENTRY_S32("gRandomizeShuffleAdultTrade", 1), - PRESET_ENTRY_S32("gRandomizeShuffleDungeonReward", 0), + PRESET_ENTRY_S32("gRandomizeShuffleDungeonReward", RO_DUNGEON_REWARDS_END_OF_DUNGEON), PRESET_ENTRY_S32("gRandomizeShuffleGanonBossKey", 2), PRESET_ENTRY_S32("gRandomizeShuffleKokiriSword", 1), PRESET_ENTRY_S32("gRandomizeSkipChildStealth", 1), @@ -599,14 +599,14 @@ const std::vector hellModePresetEntries = { PRESET_ENTRY_S32("gRandomizeItemPool", RO_ITEM_POOL_MINIMAL), PRESET_ENTRY_S32("gRandomizeKakarikoGate", RO_KAK_GATE_OPEN), PRESET_ENTRY_S32("gRandomizeKeysanity", 5), - PRESET_ENTRY_S32("gRandomizeLinksPocket", 3), + PRESET_ENTRY_S32("gRandomizeLinksPocket", RO_LINKS_POCKET_NOTHING), PRESET_ENTRY_S32("gRandomizeMqDungeons", 2), PRESET_ENTRY_S32("gRandomizeRainbowBridge", 4), PRESET_ENTRY_S32("gRandomizeShopsanity", 5), PRESET_ENTRY_S32("gRandomizeShuffleAdultTrade", 1), PRESET_ENTRY_S32("gRandomizeShuffleBeans", 1), PRESET_ENTRY_S32("gRandomizeShuffleCows", 1), - PRESET_ENTRY_S32("gRandomizeShuffleDungeonReward", 3), + PRESET_ENTRY_S32("gRandomizeShuffleDungeonReward", RO_DUNGEON_REWARDS_ANYWHERE), PRESET_ENTRY_S32("gRandomizeShuffleFrogSongRupees", 1), PRESET_ENTRY_S32("gRandomizeShuffleGanonBossKey", 10), PRESET_ENTRY_S32("gRandomizeShuffleGerudoToken", 1), diff --git a/soh/soh/Enhancements/randomizer/randomizer.cpp b/soh/soh/Enhancements/randomizer/randomizer.cpp index 4427b0766..574994db7 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer.cpp @@ -2583,7 +2583,7 @@ void GenerateRandomizerImgui() { cvarSettings[RSK_STARTING_DEKU_SHIELD] = CVar_GetS32("gRandomizeStartingDekuShield", 0); cvarSettings[RSK_STARTING_SKULLTULA_TOKEN] = CVar_GetS32("gRandomizeStartingSkulltulaToken", 0); cvarSettings[RSK_STARTING_MAPS_COMPASSES] = CVar_GetS32("gRandomizeStartingMapsCompasses", 2); - cvarSettings[RSK_SHUFFLE_DUNGEON_REWARDS] = CVar_GetS32("gRandomizeShuffleDungeonReward", 0); + cvarSettings[RSK_SHUFFLE_DUNGEON_REWARDS] = CVar_GetS32("gRandomizeShuffleDungeonReward", RO_DUNGEON_REWARDS_END_OF_DUNGEON); cvarSettings[RSK_SHUFFLE_SONGS] = CVar_GetS32("gRandomizeShuffleSongs", 0); cvarSettings[RSK_SHUFFLE_TOKENS] = CVar_GetS32("gRandomizeShuffleTokens", 0); cvarSettings[RSK_SHOPSANITY] = CVar_GetS32("gRandomizeShopsanity", 0); @@ -2652,8 +2652,9 @@ void GenerateRandomizerImgui() { cvarSettings[RSK_SKULLS_SUNS_SONG] = CVar_GetS32("gRandomizeGsExpectSunsSong", 0); // Link's Pocket has to have a dungeon reward if the other rewards are shuffled to end of dungeon. - cvarSettings[RSK_LINKS_POCKET] = CVar_GetS32("gRandomizeShuffleDungeonReward", 0) != 0 ? - CVar_GetS32("gRandomizeLinksPocket", 0) : 0; + cvarSettings[RSK_LINKS_POCKET] = CVar_GetS32("gRandomizeShuffleDungeonReward", RO_DUNGEON_REWARDS_END_OF_DUNGEON) != RO_DUNGEON_REWARDS_END_OF_DUNGEON ? + CVar_GetS32("gRandomizeLinksPocket", RO_LINKS_POCKET_DUNGEON_REWARD) : + RO_LINKS_POCKET_DUNGEON_REWARD; if (OTRGlobals::Instance->HasMasterQuest() && OTRGlobals::Instance->HasOriginal()) { // If both OTRs are loaded. @@ -3951,7 +3952,7 @@ void DrawRandoEditor(bool& open) { ImGui::BeginChild("ChildStartingEquipment", ImVec2(0, -8)); // Don't display this option if Dungeon Rewards are Shuffled to End of Dungeon. // TODO: Show this but disabled when we have options for disabled Comboboxes. - if (CVar_GetS32("gRandomizeShuffleDungeonReward", 0) != 0) { + if (CVar_GetS32("gRandomizeShuffleDungeonReward", RO_DUNGEON_REWARDS_END_OF_DUNGEON) != RO_DUNGEON_REWARDS_END_OF_DUNGEON) { ImGui::Text(Settings::LinksPocketItem.GetName().c_str()); UIWidgets::EnhancementCombobox("gRandomizeLinksPocket", randoLinksPocket, 4, RO_LINKS_POCKET_DUNGEON_REWARD); UIWidgets::PaddedSeparator(); diff --git a/soh/src/code/z_sram.c b/soh/src/code/z_sram.c index 43d1712af..bf3718d50 100644 --- a/soh/src/code/z_sram.c +++ b/soh/src/code/z_sram.c @@ -97,7 +97,7 @@ void GiveLinkDekuNuts(int howManyNuts) { } void GiveLinksPocketItem() { - if (Randomizer_GetSettingValue(RSK_LINKS_POCKET) < 3) { + if (Randomizer_GetSettingValue(RSK_LINKS_POCKET) != RO_LINKS_POCKET_NOTHING) { GetItemEntry getItemEntry = Randomizer_GetItemFromKnownCheck(RC_LINKS_POCKET, RG_NONE); if (getItemEntry.modIndex == MOD_NONE) { From a15f89a3e48b4b599d1324b743b74d1d625c6d94 Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Tue, 29 Nov 2022 18:40:35 -0500 Subject: [PATCH 22/25] Use enum values for ice trap setting (#2041) Co-authored-by: briaguya Co-authored-by: David Chavez --- soh/soh/Enhancements/presets.h | 4 ++-- soh/soh/Enhancements/randomizer/randomizer.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/soh/soh/Enhancements/presets.h b/soh/soh/Enhancements/presets.h index fbe7f8bd2..458bfa188 100644 --- a/soh/soh/Enhancements/presets.h +++ b/soh/soh/Enhancements/presets.h @@ -557,7 +557,7 @@ const std::vector s6PresetEntries = { PRESET_ENTRY_S32("gRandomizeForest", 1), PRESET_ENTRY_S32("gRandomizeGanonTrial", 0), PRESET_ENTRY_S32("gRandomizeGerudoFortress", RO_GF_FAST), - PRESET_ENTRY_S32("gRandomizeIceTraps", 0), + PRESET_ENTRY_S32("gRandomizeIceTraps", RO_ICE_TRAPS_OFF), PRESET_ENTRY_S32("gRandomizeKakarikoGate", RO_KAK_GATE_OPEN), PRESET_ENTRY_S32("gRandomizeMedallionCount", 6), PRESET_ENTRY_S32("gRandomizeMqDungeons", 0), @@ -595,7 +595,7 @@ const std::vector hellModePresetEntries = { PRESET_ENTRY_S32("gRandomizeGanonTrialCount", 6), PRESET_ENTRY_S32("gRandomizeGerudoKeys", 3), PRESET_ENTRY_S32("gRandomizeGsExpectSunsSong", 1), - PRESET_ENTRY_S32("gRandomizeIceTraps", 4), + PRESET_ENTRY_S32("gRandomizeIceTraps", RO_ICE_TRAPS_ONSLAUGHT), PRESET_ENTRY_S32("gRandomizeItemPool", RO_ITEM_POOL_MINIMAL), PRESET_ENTRY_S32("gRandomizeKakarikoGate", RO_KAK_GATE_OPEN), PRESET_ENTRY_S32("gRandomizeKeysanity", 5), diff --git a/soh/soh/Enhancements/randomizer/randomizer.cpp b/soh/soh/Enhancements/randomizer/randomizer.cpp index 574994db7..95a148abc 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer.cpp @@ -2604,7 +2604,7 @@ void GenerateRandomizerImgui() { cvarSettings[RSK_SHUFFLE_GERUDO_MEMBERSHIP_CARD] = CVar_GetS32("gRandomizeShuffleGerudoToken", 0); cvarSettings[RSK_SHUFFLE_FROG_SONG_RUPEES] = CVar_GetS32("gRandomizeShuffleFrogSongRupees", 0); cvarSettings[RSK_ITEM_POOL] = CVar_GetS32("gRandomizeItemPool", RO_ITEM_POOL_BALANCED); - cvarSettings[RSK_ICE_TRAPS] = CVar_GetS32("gRandomizeIceTraps", 1); + cvarSettings[RSK_ICE_TRAPS] = CVar_GetS32("gRandomizeIceTraps", RO_ICE_TRAPS_NORMAL); cvarSettings[RSK_GOSSIP_STONE_HINTS] = CVar_GetS32("gRandomizeGossipStoneHints", 1); cvarSettings[RSK_HINT_CLARITY] = CVar_GetS32("gRandomizeHintClarity", 2); cvarSettings[RSK_HINT_DISTRIBUTION] = CVar_GetS32("gRandomizeHintDistribution", 1); From b976ef58fe14783c2e2ba2e4d0a4b6b85c628e58 Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Tue, 29 Nov 2022 20:01:41 -0500 Subject: [PATCH 23/25] use enum for ganon's boss key (#2046) --- soh/soh/Enhancements/presets.h | 4 ++-- soh/soh/Enhancements/randomizer/randomizer.cpp | 16 ++++++++++------ .../randomizer/randomizer_check_objects.cpp | 2 +- soh/soh/GameMenuBar.cpp | 4 +++- soh/src/code/z_play.c | 10 +++++----- soh/src/code/z_sram.c | 3 +-- 6 files changed, 22 insertions(+), 17 deletions(-) diff --git a/soh/soh/Enhancements/presets.h b/soh/soh/Enhancements/presets.h index 458bfa188..289c0b157 100644 --- a/soh/soh/Enhancements/presets.h +++ b/soh/soh/Enhancements/presets.h @@ -564,7 +564,7 @@ const std::vector s6PresetEntries = { PRESET_ENTRY_S32("gRandomizeRainbowBridge", 3), PRESET_ENTRY_S32("gRandomizeShuffleAdultTrade", 1), PRESET_ENTRY_S32("gRandomizeShuffleDungeonReward", RO_DUNGEON_REWARDS_END_OF_DUNGEON), - PRESET_ENTRY_S32("gRandomizeShuffleGanonBossKey", 2), + PRESET_ENTRY_S32("gRandomizeShuffleGanonBossKey", RO_GANON_BOSS_KEY_STARTWITH), PRESET_ENTRY_S32("gRandomizeShuffleKokiriSword", 1), PRESET_ENTRY_S32("gRandomizeSkipChildStealth", 1), PRESET_ENTRY_S32("gRandomizeSkipChildZelda", 1), @@ -608,7 +608,7 @@ const std::vector hellModePresetEntries = { PRESET_ENTRY_S32("gRandomizeShuffleCows", 1), PRESET_ENTRY_S32("gRandomizeShuffleDungeonReward", RO_DUNGEON_REWARDS_ANYWHERE), PRESET_ENTRY_S32("gRandomizeShuffleFrogSongRupees", 1), - PRESET_ENTRY_S32("gRandomizeShuffleGanonBossKey", 10), + PRESET_ENTRY_S32("gRandomizeShuffleGanonBossKey", RO_GANON_BOSS_KEY_LACS_DUNGEONS), PRESET_ENTRY_S32("gRandomizeShuffleGerudoToken", 1), PRESET_ENTRY_S32("gRandomizeShuffleKeyRings", 1), PRESET_ENTRY_S32("gRandomizeShuffleKokiriSword", 1), diff --git a/soh/soh/Enhancements/randomizer/randomizer.cpp b/soh/soh/Enhancements/randomizer/randomizer.cpp index 95a148abc..d40740d5c 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer.cpp @@ -1922,7 +1922,9 @@ GetItemID Randomizer::GetItemIdFromRandomizerGet(RandomizerGet randoGet, GetItem return (GetItemID)randoGet; } case RG_GANONS_CASTLE_BOSS_KEY: - if (GetRandoSettingValue(RSK_GANONS_BOSS_KEY) < 3) { + if (GetRandoSettingValue(RSK_GANONS_BOSS_KEY) == RO_GANON_BOSS_KEY_VANILLA || + GetRandoSettingValue(RSK_GANONS_BOSS_KEY) == RO_GANON_BOSS_KEY_OWN_DUNGEON || + GetRandoSettingValue(RSK_GANONS_BOSS_KEY) == RO_GANON_BOSS_KEY_STARTWITH) { return GI_KEY_BOSS; } else { return (GetItemID)randoGet; @@ -2133,10 +2135,12 @@ bool Randomizer::IsItemVanilla(RandomizerGet randoGet) { } return true; case RG_GANONS_CASTLE_BOSS_KEY: - if (GetRandoSettingValue(RSK_GANONS_BOSS_KEY) > 2) { - return false; + if (GetRandoSettingValue(RSK_GANONS_BOSS_KEY) == RO_GANON_BOSS_KEY_VANILLA || + GetRandoSettingValue(RSK_GANONS_BOSS_KEY) == RO_GANON_BOSS_KEY_OWN_DUNGEON || + GetRandoSettingValue(RSK_GANONS_BOSS_KEY) == RO_GANON_BOSS_KEY_STARTWITH) { + return true; } - return true; + return false; case RG_DEKU_TREE_COMPASS: case RG_DODONGOS_CAVERN_COMPASS: case RG_JABU_JABUS_BELLY_COMPASS: @@ -2623,7 +2627,7 @@ void GenerateRandomizerImgui() { cvarSettings[RSK_KEYRINGS_GTG] = CVar_GetS32("gRandomizeShuffleKeyRingsGTG", 0); cvarSettings[RSK_KEYRINGS_GANONS_CASTLE] = CVar_GetS32("gRandomizeShuffleKeyRingsGanonsCastle", 0); cvarSettings[RSK_BOSS_KEYSANITY] = CVar_GetS32("gRandomizeBossKeysanity", 2); - cvarSettings[RSK_GANONS_BOSS_KEY] = CVar_GetS32("gRandomizeShuffleGanonBossKey", 1); + cvarSettings[RSK_GANONS_BOSS_KEY] = CVar_GetS32("gRandomizeShuffleGanonBossKey", RO_GANON_BOSS_KEY_VANILLA); cvarSettings[RSK_LACS_STONE_COUNT] = CVar_GetS32("gRandomizeLacsStoneCount", 3); cvarSettings[RSK_LACS_MEDALLION_COUNT] = CVar_GetS32("gRandomizeLacsMedallionCount", 6); cvarSettings[RSK_LACS_REWARD_COUNT] = CVar_GetS32("gRandomizeLacsRewardCount", 9); @@ -3484,7 +3488,7 @@ void DrawRandoEditor(bool& open) { ); UIWidgets::EnhancementCombobox("gRandomizeShuffleGanonBossKey", randoShuffleGanonsBossKey, 12, RO_GANON_BOSS_KEY_VANILLA); ImGui::PopItemWidth(); - switch (CVar_GetS32("gRandomizeShuffleGanonBossKey", RO_GANON_BOSS_KEY_OWN_DUNGEON)) { + switch (CVar_GetS32("gRandomizeShuffleGanonBossKey", RO_GANON_BOSS_KEY_VANILLA)) { case RO_GANON_BOSS_KEY_LACS_MEDALLIONS: ImGui::Dummy(ImVec2(0.0f, 0.0f)); UIWidgets::EnhancementSliderInt("Medallion Count: %d", "##RandoLacsMedallionCount", diff --git a/soh/soh/Enhancements/randomizer/randomizer_check_objects.cpp b/soh/soh/Enhancements/randomizer/randomizer_check_objects.cpp index 482cf728d..6574ac7a4 100644 --- a/soh/soh/Enhancements/randomizer/randomizer_check_objects.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer_check_objects.cpp @@ -917,7 +917,7 @@ void RandomizerCheckObjects::UpdateImGuiVisibility() { ((locationIt.rcType != RCTYPE_SMALL_KEY) || CVar_GetS32("gRandomizeKeysanity", 0) != 1) && // 1 is the value for "vanilla" small keys ((locationIt.rcType != RCTYPE_GF_KEY) || CVar_GetS32("randoShuffleGerudoFortressKeys", 0) != 0) && // 0 is the value for "vanilla" gf keys ((locationIt.rcType != RCTYPE_BOSS_KEY) || CVar_GetS32("gRandomizeBossKeysanity", 0) != 1) && // 1 is the value for "vanilla" boss keys - ((locationIt.rcType != RCTYPE_GANON_BOSS_KEY) || CVar_GetS32("gRandomizeShuffleGanonBossKey", 0) != 0) // 0 is the value for "vanilla" ganon's boss key + ((locationIt.rcType != RCTYPE_GANON_BOSS_KEY) || CVar_GetS32("gRandomizeShuffleGanonBossKey", RO_GANON_BOSS_KEY_VANILLA) != RO_GANON_BOSS_KEY_VANILLA) ); } } diff --git a/soh/soh/GameMenuBar.cpp b/soh/soh/GameMenuBar.cpp index 01befbad2..a9ce0a9a5 100644 --- a/soh/soh/GameMenuBar.cpp +++ b/soh/soh/GameMenuBar.cpp @@ -1190,7 +1190,9 @@ namespace GameMenuBar { if (OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_KEYSANITY) > 2 || OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_GERUDO_KEYS) > 0 || OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_BOSS_KEYSANITY) > 2 || - OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_GANONS_BOSS_KEY) > 2 || + (OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_GANONS_BOSS_KEY) != RO_GANON_BOSS_KEY_VANILLA && + OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_GANONS_BOSS_KEY) != RO_GANON_BOSS_KEY_OWN_DUNGEON && + OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_GANONS_BOSS_KEY) != RO_GANON_BOSS_KEY_STARTWITH) || !gSaveContext.n64ddFlag) { disableKeyColors = false; } diff --git a/soh/src/code/z_play.c b/soh/src/code/z_play.c index 8282fef01..b08f9cee4 100644 --- a/soh/src/code/z_play.c +++ b/soh/src/code/z_play.c @@ -343,27 +343,27 @@ void GivePlayerRandoRewardZeldaLightArrowsGift(PlayState* play, RandomizerCheck u8 meetsRequirements = 0; switch (Randomizer_GetSettingValue(RSK_GANONS_BOSS_KEY)) { - case 7: + case RO_GANON_BOSS_KEY_LACS_MEDALLIONS: if (CheckMedallionCount() >= Randomizer_GetSettingValue(RSK_LACS_MEDALLION_COUNT)) { meetsRequirements = true; } break; - case 8: + case RO_GANON_BOSS_KEY_LACS_STONES: if (CheckStoneCount() >= Randomizer_GetSettingValue(RSK_LACS_STONE_COUNT)) { meetsRequirements = true; } break; - case 9: + case RO_GANON_BOSS_KEY_LACS_REWARDS: if ((CheckMedallionCount() + CheckStoneCount()) >= Randomizer_GetSettingValue(RSK_LACS_REWARD_COUNT)) { meetsRequirements = true; } break; - case 10: + case RO_GANON_BOSS_KEY_LACS_DUNGEONS: if (CheckDungeonCount() >= Randomizer_GetSettingValue(RSK_LACS_DUNGEON_COUNT)) { meetsRequirements = true; } break; - case 11: + case RO_GANON_BOSS_KEY_LACS_TOKENS: if (gSaveContext.inventory.gsTokens >= Randomizer_GetSettingValue(RSK_LACS_TOKEN_COUNT)) { meetsRequirements = true; } diff --git a/soh/src/code/z_sram.c b/soh/src/code/z_sram.c index bf3718d50..a6168a957 100644 --- a/soh/src/code/z_sram.c +++ b/soh/src/code/z_sram.c @@ -503,8 +503,7 @@ void Sram_InitSave(FileChooseContext* fileChooseCtx) { gSaveContext.inventory.dungeonItems[SCENE_HAKADAN] |= 1; // Shadow } - // "Start with" == 2 for Ganon's Boss Key - if(Randomizer_GetSettingValue(RSK_GANONS_BOSS_KEY) == 2) { + if(Randomizer_GetSettingValue(RSK_GANONS_BOSS_KEY) == RO_GANON_BOSS_KEY_STARTWITH) { gSaveContext.inventory.dungeonItems[SCENE_GANON] |= 1; } From 17c6a3653c98369435f281b6047b8a099b67a7ac Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Tue, 29 Nov 2022 20:05:11 -0500 Subject: [PATCH 24/25] use enum for keysanity (#2044) --- soh/soh/Enhancements/presets.h | 2 +- soh/soh/Enhancements/randomizer/randomizer.cpp | 6 ++++-- .../Enhancements/randomizer/randomizer_check_objects.cpp | 2 +- soh/soh/GameMenuBar.cpp | 4 +++- soh/src/code/z_sram.c | 3 +-- 5 files changed, 10 insertions(+), 7 deletions(-) diff --git a/soh/soh/Enhancements/presets.h b/soh/soh/Enhancements/presets.h index 289c0b157..7d190be11 100644 --- a/soh/soh/Enhancements/presets.h +++ b/soh/soh/Enhancements/presets.h @@ -598,7 +598,7 @@ const std::vector hellModePresetEntries = { PRESET_ENTRY_S32("gRandomizeIceTraps", RO_ICE_TRAPS_ONSLAUGHT), PRESET_ENTRY_S32("gRandomizeItemPool", RO_ITEM_POOL_MINIMAL), PRESET_ENTRY_S32("gRandomizeKakarikoGate", RO_KAK_GATE_OPEN), - PRESET_ENTRY_S32("gRandomizeKeysanity", 5), + PRESET_ENTRY_S32("gRandomizeKeysanity", RO_DUNGEON_ITEM_LOC_ANYWHERE), PRESET_ENTRY_S32("gRandomizeLinksPocket", RO_LINKS_POCKET_NOTHING), PRESET_ENTRY_S32("gRandomizeMqDungeons", 2), PRESET_ENTRY_S32("gRandomizeRainbowBridge", 4), diff --git a/soh/soh/Enhancements/randomizer/randomizer.cpp b/soh/soh/Enhancements/randomizer/randomizer.cpp index d40740d5c..16b4acb9a 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer.cpp @@ -1938,7 +1938,9 @@ GetItemID Randomizer::GetItemIdFromRandomizerGet(RandomizerGet randoGet, GetItem case RG_BOTTOM_OF_THE_WELL_SMALL_KEY: case RG_GERUDO_TRAINING_GROUNDS_SMALL_KEY: case RG_GANONS_CASTLE_SMALL_KEY: - if (GetRandoSettingValue(RSK_KEYSANITY) < 3) { + if (GetRandoSettingValue(RSK_KEYSANITY) == RO_DUNGEON_ITEM_LOC_STARTWITH || + GetRandoSettingValue(RSK_KEYSANITY) == RO_DUNGEON_ITEM_LOC_VANILLA || + GetRandoSettingValue(RSK_KEYSANITY) == RO_DUNGEON_ITEM_LOC_OWN_DUNGEON) { return GI_KEY_SMALL; } else { return (GetItemID)randoGet; @@ -2614,7 +2616,7 @@ void GenerateRandomizerImgui() { cvarSettings[RSK_HINT_DISTRIBUTION] = CVar_GetS32("gRandomizeHintDistribution", 1); cvarSettings[RSK_BLUE_FIRE_ARROWS] = CVar_GetS32("gRandomizeBlueFireArrows", 0); cvarSettings[RSK_SUNLIGHT_ARROWS] = CVar_GetS32("gRandomizeSunlightArrows", 0); - cvarSettings[RSK_KEYSANITY] = CVar_GetS32("gRandomizeKeysanity", 2); + cvarSettings[RSK_KEYSANITY] = CVar_GetS32("gRandomizeKeysanity", RO_DUNGEON_ITEM_LOC_OWN_DUNGEON); cvarSettings[RSK_GERUDO_KEYS] = CVar_GetS32("gRandomizeGerudoKeys", 0); cvarSettings[RSK_KEYRINGS] = CVar_GetS32("gRandomizeShuffleKeyRings", 0); cvarSettings[RSK_KEYRINGS_RANDOM_COUNT] = CVar_GetS32("gRandomizeShuffleKeyRingsRandomCount", 8); diff --git a/soh/soh/Enhancements/randomizer/randomizer_check_objects.cpp b/soh/soh/Enhancements/randomizer/randomizer_check_objects.cpp index 6574ac7a4..66e764d4b 100644 --- a/soh/soh/Enhancements/randomizer/randomizer_check_objects.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer_check_objects.cpp @@ -914,7 +914,7 @@ void RandomizerCheckObjects::UpdateImGuiVisibility() { ((locationIt.rc != RC_GF_GERUDO_MEMBERSHIP_CARD) || CVar_GetS32("gRandomizeShuffleGerudoToken", 0)) && ((locationIt.rcType != RCTYPE_FROG_SONG) || CVar_GetS32("gRandomizeShuffleFrogSongRupees", 0)) && ((locationIt.rcType != RCTYPE_MAP_COMPASS) || CVar_GetS32("gRandomizeStartingMapsCompasses", 0) != 1) && // 1 is the value for "vanilla" maps/compasses - ((locationIt.rcType != RCTYPE_SMALL_KEY) || CVar_GetS32("gRandomizeKeysanity", 0) != 1) && // 1 is the value for "vanilla" small keys + ((locationIt.rcType != RCTYPE_SMALL_KEY) || CVar_GetS32("gRandomizeKeysanity", RO_DUNGEON_ITEM_LOC_OWN_DUNGEON) != RO_DUNGEON_ITEM_LOC_VANILLA) && ((locationIt.rcType != RCTYPE_GF_KEY) || CVar_GetS32("randoShuffleGerudoFortressKeys", 0) != 0) && // 0 is the value for "vanilla" gf keys ((locationIt.rcType != RCTYPE_BOSS_KEY) || CVar_GetS32("gRandomizeBossKeysanity", 0) != 1) && // 1 is the value for "vanilla" boss keys ((locationIt.rcType != RCTYPE_GANON_BOSS_KEY) || CVar_GetS32("gRandomizeShuffleGanonBossKey", RO_GANON_BOSS_KEY_VANILLA) != RO_GANON_BOSS_KEY_VANILLA) diff --git a/soh/soh/GameMenuBar.cpp b/soh/soh/GameMenuBar.cpp index a9ce0a9a5..b3e3553be 100644 --- a/soh/soh/GameMenuBar.cpp +++ b/soh/soh/GameMenuBar.cpp @@ -1187,7 +1187,9 @@ namespace GameMenuBar { // Only disable the key colors checkbox when none of the keysanity settings are set to "Any Dungeon", "Overworld" or "Anywhere" bool disableKeyColors = true; - if (OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_KEYSANITY) > 2 || + if (OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_KEYSANITY) == RO_DUNGEON_ITEM_LOC_ANY_DUNGEON || + OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_KEYSANITY) == RO_DUNGEON_ITEM_LOC_OVERWORLD || + OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_KEYSANITY) == RO_DUNGEON_ITEM_LOC_ANYWHERE || OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_GERUDO_KEYS) > 0 || OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_BOSS_KEYSANITY) > 2 || (OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_GANONS_BOSS_KEY) != RO_GANON_BOSS_KEY_VANILLA && diff --git a/soh/src/code/z_sram.c b/soh/src/code/z_sram.c index a6168a957..e3f080e67 100644 --- a/soh/src/code/z_sram.c +++ b/soh/src/code/z_sram.c @@ -473,8 +473,7 @@ void Sram_InitSave(FileChooseContext* fileChooseCtx) { GiveLinkRupees(9001); } - // "Start with" == 0 for Keysanity - if(Randomizer_GetSettingValue(RSK_KEYSANITY) == 0) { + if(Randomizer_GetSettingValue(RSK_KEYSANITY) == RO_DUNGEON_ITEM_LOC_STARTWITH) { // TODO: If master quest there are different key counts gSaveContext.inventory.dungeonKeys[SCENE_BMORI1] = FOREST_TEMPLE_SMALL_KEY_MAX; // Forest gSaveContext.sohStats.dungeonKeys[SCENE_BMORI1] = FOREST_TEMPLE_SMALL_KEY_MAX; // Forest From 06df45efc718d04502018736921e520b5d7a5e40 Mon Sep 17 00:00:00 2001 From: briaguya <70942617+briaguya-ai@users.noreply.github.com> Date: Tue, 29 Nov 2022 20:32:22 -0500 Subject: [PATCH 25/25] use forest enum values instead of magic numbers (#2038) --- soh/soh/Enhancements/presets.h | 4 ++-- soh/soh/Enhancements/randomizer/randomizer.cpp | 8 ++++---- soh/src/code/z_sram.c | 10 +++++----- soh/src/overlays/actors/ovl_En_Md/z_en_md.c | 1 - 4 files changed, 11 insertions(+), 12 deletions(-) diff --git a/soh/soh/Enhancements/presets.h b/soh/soh/Enhancements/presets.h index 7d190be11..4c9897701 100644 --- a/soh/soh/Enhancements/presets.h +++ b/soh/soh/Enhancements/presets.h @@ -554,7 +554,7 @@ const std::vector s6PresetEntries = { PRESET_ENTRY_S32("gRandomizeCuccosToReturn", 4), PRESET_ENTRY_S32("gRandomizeDoorOfTime", RO_DOOROFTIME_OPEN), PRESET_ENTRY_STRING("gRandomizeExcludedLocations", "48,"), - PRESET_ENTRY_S32("gRandomizeForest", 1), + PRESET_ENTRY_S32("gRandomizeForest", RO_FOREST_CLOSED_DEKU), PRESET_ENTRY_S32("gRandomizeGanonTrial", 0), PRESET_ENTRY_S32("gRandomizeGerudoFortress", RO_GF_FAST), PRESET_ENTRY_S32("gRandomizeIceTraps", RO_ICE_TRAPS_OFF), @@ -590,7 +590,7 @@ const std::vector hellModePresetEntries = { PRESET_ENTRY_S32("gRandomizeDoorOfTime", RO_DOOROFTIME_OPEN), PRESET_ENTRY_S32("gRandomizeEnableBombchuDrops", 1), PRESET_ENTRY_S32("gRandomizeEnableGlitchCutscenes", 1), - PRESET_ENTRY_S32("gRandomizeForest", 2), + PRESET_ENTRY_S32("gRandomizeForest", RO_FOREST_OPEN), PRESET_ENTRY_S32("gRandomizeGanonTrial", 2), PRESET_ENTRY_S32("gRandomizeGanonTrialCount", 6), PRESET_ENTRY_S32("gRandomizeGerudoKeys", 3), diff --git a/soh/soh/Enhancements/randomizer/randomizer.cpp b/soh/soh/Enhancements/randomizer/randomizer.cpp index 16b4acb9a..91ff2622a 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer.cpp @@ -596,9 +596,9 @@ void Randomizer::ParseRandomizerSettingsFile(const char* spoilerFileName) { if(it.value() == "Closed") { gSaveContext.randoSettings[index].value = RO_FOREST_CLOSED; } else if(it.value() == "Open") { - gSaveContext.randoSettings[index].value = RO_FOREST_CLOSED_DEKU; - } else if(it.value() == "Closed Deku") { gSaveContext.randoSettings[index].value = RO_FOREST_OPEN; + } else if(it.value() == "Closed Deku") { + gSaveContext.randoSettings[index].value = RO_FOREST_CLOSED_DEKU; } break; case RSK_KAK_GATE: @@ -2566,7 +2566,7 @@ void GenerateRandomizerImgui() { std::unordered_map cvarSettings; cvarSettings[RSK_LOGIC_RULES] = CVar_GetS32("gRandomizeLogicRules", 0); - cvarSettings[RSK_FOREST] = CVar_GetS32("gRandomizeForest", 0); + cvarSettings[RSK_FOREST] = CVar_GetS32("gRandomizeForest", RO_FOREST_CLOSED); cvarSettings[RSK_KAK_GATE] = CVar_GetS32("gRandomizeKakarikoGate", RO_KAK_GATE_CLOSED); cvarSettings[RSK_DOOR_OF_TIME] = CVar_GetS32("gRandomizeDoorOfTime", RO_DOOROFTIME_CLOSED); cvarSettings[RSK_ZORAS_FOUNTAIN] = CVar_GetS32("gRandomizeZorasFountain", 0); @@ -2896,7 +2896,7 @@ void DrawRandoEditor(bool& open) { //Disabled when Forest is set to Closed or under very specific conditions //RANDOTODO: Replace magic number checks with enums bool disableRandoStartingAge = (CVar_GetS32("gRandomizeLogicRules", 0) == 0) && // glitchless logic - ((CVar_GetS32("gRandomizeForest", 0) == 0) || // Closed Forest + ((CVar_GetS32("gRandomizeForest", RO_FOREST_CLOSED) == RO_FOREST_CLOSED) || ((CVar_GetS32("gRandomizeDoorOfTime", RO_DOOROFTIME_CLOSED) == RO_DOOROFTIME_CLOSED) && (CVar_GetS32("gRandomizeShuffleOcarinas", 0) == 0))); // ocarinas not shuffled diff --git a/soh/src/code/z_sram.c b/soh/src/code/z_sram.c index e3f080e67..5fb913083 100644 --- a/soh/src/code/z_sram.c +++ b/soh/src/code/z_sram.c @@ -372,15 +372,15 @@ void Sram_InitSave(FileChooseContext* fileChooseCtx) { int openForest = Randomizer_GetSettingValue(RSK_FOREST); switch (openForest) { - case 0: // closed + case RO_FOREST_CLOSED: break; - case 1: // open + case RO_FOREST_CLOSED_DEKU: + Flags_SetEventChkInf(7); + break; + case RO_FOREST_OPEN: Flags_SetEventChkInf(7); gSaveContext.eventChkInf[0] |= 0x10; break; - case 2: // closed deku - Flags_SetEventChkInf(7); - break; } int startingAge = Randomizer_GetSettingValue(RSK_STARTING_AGE); diff --git a/soh/src/overlays/actors/ovl_En_Md/z_en_md.c b/soh/src/overlays/actors/ovl_En_Md/z_en_md.c index 99dd5605c..82d56124a 100644 --- a/soh/src/overlays/actors/ovl_En_Md/z_en_md.c +++ b/soh/src/overlays/actors/ovl_En_Md/z_en_md.c @@ -487,7 +487,6 @@ u8 EnMd_ShouldSpawn(EnMd* this, PlayState* play) { // if we have beaten deku tree or have open forest turned on // or have already shown mido we have an equipped sword/shield if (Flags_GetRandomizerInf(RAND_INF_DUNGEONS_DONE_DEKU_TREE) || - Randomizer_GetSettingValue(RSK_FOREST) == 1 || gSaveContext.eventChkInf[0] & 0x10) { return 0; }