From 396379a4ef36b6fc0727a5583c708c15f5999112 Mon Sep 17 00:00:00 2001 From: mzxrules Date: Mon, 16 Oct 2023 16:44:21 -0400 Subject: [PATCH] TransiActor ->TransitionActor --- include/z64scene.h | 68 +++++++++++++++++----------------- src/code/z_play.c | 2 +- src/code/z_scene.c | 10 ++--- tools/disasm/functions.txt | 4 +- tools/sizes/code_functions.csv | 2 +- 5 files changed, 44 insertions(+), 42 deletions(-) diff --git a/include/z64scene.h b/include/z64scene.h index edb99fb68..e91b25777 100644 --- a/include/z64scene.h +++ b/include/z64scene.h @@ -111,7 +111,9 @@ typedef struct { /* 0x0 */ u8 code; /* 0x1 */ u8 num; /* 0x4 */ void* segment; -} SCmdTransiActorList; // size = 0x8 +} SCmdTransitionActorList; // size = 0x8 + +#define SCmdTransiActorList SCmdTransitionActorList typedef struct { /* 0x0 */ u8 code; @@ -525,38 +527,38 @@ typedef struct { typedef ActorCsCamInfo CsCameraEntry; // TODO: Remove once ZAPD updates its structs typedef union { - /* Command: N/A */ SCmdBase base; - /* Command: 0x00 */ SCmdSpawnList spawnList; - /* Command: 0x01 */ SCmdActorList actorList; - /* Command: 0x02 */ SCmdCsCameraList actorCsCamList; - /* Command: 0x03 */ SCmdColHeader colHeader; - /* Command: 0x04 */ SCmdRoomList roomList; - /* Command: 0x05 */ SCmdWindSettings windSettings; - /* Command: 0x06 */ SCmdEntranceList entranceList; - /* Command: 0x07 */ SCmdSpecialFiles specialFiles; - /* Command: 0x08 */ SCmdRoomBehavior roomBehavior; + /* Command: N/A */ SCmdBase base; + /* Command: 0x00 */ SCmdSpawnList spawnList; + /* Command: 0x01 */ SCmdActorList actorList; + /* Command: 0x02 */ SCmdCsCameraList actorCsCamList; + /* Command: 0x03 */ SCmdColHeader colHeader; + /* Command: 0x04 */ SCmdRoomList roomList; + /* Command: 0x05 */ SCmdWindSettings windSettings; + /* Command: 0x06 */ SCmdEntranceList entranceList; + /* Command: 0x07 */ SCmdSpecialFiles specialFiles; + /* Command: 0x08 */ SCmdRoomBehavior roomBehavior; /* Command: 0x09 */ // Unused - /* Command: 0x0A */ SCmdMesh mesh; - /* Command: 0x0B */ SCmdObjectList objectList; - /* Command: 0x0C */ SCmdLightList lightList; - /* Command: 0x0D */ SCmdPathList pathList; - /* Command: 0x0E */ SCmdTransiActorList transiActorList; - /* Command: 0x0F */ SCmdLightSettingList lightSettingList; - /* Command: 0x10 */ SCmdTimeSettings timeSettings; - /* Command: 0x11 */ SCmdSkyboxSettings skyboxSettings; - /* Command: 0x12 */ SCmdSkyboxDisables skyboxDisables; - /* Command: 0x13 */ SCmdExitList exitList; - /* Command: 0x14 */ SCmdEndMarker endMarker; - /* Command: 0x15 */ SCmdSoundSettings soundSettings; - /* Command: 0x16 */ SCmdEchoSettings echoSettings; - /* Command: 0x17 */ SCmdCsScriptList scriptList; - /* Command: 0x18 */ SCmdAltHeaders altHeaders; - /* Command: 0x19 */ SCmdRegionVisited regionVisited; - /* Command: 0x1A */ SCmdTextureAnimations textureAnimations; - /* Command: 0x1B */ SCmdCutsceneList cutsceneList; - /* Command: 0x1C */ SCmdMinimapSettings minimapSettings; + /* Command: 0x0A */ SCmdMesh mesh; + /* Command: 0x0B */ SCmdObjectList objectList; + /* Command: 0x0C */ SCmdLightList lightList; + /* Command: 0x0D */ SCmdPathList pathList; + /* Command: 0x0E */ SCmdTransitionActorList transitionActorList; + /* Command: 0x0F */ SCmdLightSettingList lightSettingList; + /* Command: 0x10 */ SCmdTimeSettings timeSettings; + /* Command: 0x11 */ SCmdSkyboxSettings skyboxSettings; + /* Command: 0x12 */ SCmdSkyboxDisables skyboxDisables; + /* Command: 0x13 */ SCmdExitList exitList; + /* Command: 0x14 */ SCmdEndMarker endMarker; + /* Command: 0x15 */ SCmdSoundSettings soundSettings; + /* Command: 0x16 */ SCmdEchoSettings echoSettings; + /* Command: 0x17 */ SCmdCsScriptList scriptList; + /* Command: 0x18 */ SCmdAltHeaders altHeaders; + /* Command: 0x19 */ SCmdRegionVisited regionVisited; + /* Command: 0x1A */ SCmdTextureAnimations textureAnimations; + /* Command: 0x1B */ SCmdCutsceneList cutsceneList; + /* Command: 0x1C */ SCmdMinimapSettings minimapSettings; /* Command: 0x1D */ // Unused - /* Command: 0x1E */ SCmdMinimapChests minimapChests; + /* Command: 0x1E */ SCmdMinimapChests minimapChests; } SceneCmd; // size = 0x8 // Sets cursor point options on the world map @@ -920,8 +922,8 @@ void Scene_CommandMesh(struct PlayState* play, SceneCmd* cmd); void Scene_CommandObjectList(struct PlayState* play, SceneCmd* cmd); void Scene_CommandLightList(struct PlayState* play, SceneCmd* cmd); void Scene_CommandPathList(struct PlayState* play, SceneCmd* cmd); -void Scene_CommandTransiActorList(struct PlayState* play, SceneCmd* cmd); -void Scene_ResetTransiActorList(GameState* gameState, TransitionActorList* transitionActors); +void Scene_CommandTransitionActorList(struct PlayState* play, SceneCmd* cmd); +void Scene_ResetTransitionActorList(GameState* gameState, TransitionActorList* transitionActors); void Scene_CommandEnvLightSettings(struct PlayState* play, SceneCmd* cmd); void Scene_LoadAreaTextures(struct PlayState* play, s32 fileIndex); void Scene_CommandSkyboxSettings(struct PlayState* play, SceneCmd* cmd); diff --git a/src/code/z_play.c b/src/code/z_play.c index d2c4510b3..1c47a7002 100644 --- a/src/code/z_play.c +++ b/src/code/z_play.c @@ -1587,7 +1587,7 @@ void Play_InitScene(PlayState* this, s32 spawn) { this->numSetupActors = 0; Object_InitContext(&this->state, &this->objectCtx); LightContext_Init(this, &this->lightCtx); - Scene_ResetTransiActorList(&this->state, &this->transitionActors); + Scene_ResetTransitionActorList(&this->state, &this->transitionActors); Room_Init(this, &this->roomCtx); gSaveContext.worldMapArea = 0; Scene_ExecuteCommands(this, this->sceneSegment); diff --git a/src/code/z_scene.c b/src/code/z_scene.c index 2890797c5..059fbfb0d 100644 --- a/src/code/z_scene.c +++ b/src/code/z_scene.c @@ -333,14 +333,14 @@ void Scene_CommandPathList(PlayState* play, SceneCmd* cmd) { } // SceneTableEntry Header Command 0x0E: Transition Actor List -void Scene_CommandTransiActorList(PlayState* play, SceneCmd* cmd) { - play->transitionActors.count = cmd->transiActorList.num; - play->transitionActors.list = Lib_SegmentedToVirtual(cmd->transiActorList.segment); +void Scene_CommandTransitionActorList(PlayState* play, SceneCmd* cmd) { + play->transitionActors.count = cmd->transitionActorList.num; + play->transitionActors.list = Lib_SegmentedToVirtual(cmd->transitionActorList.segment); func_80105818(play, play->transitionActors.count, play->transitionActors.list); } // Init function for the transition system. -void Scene_ResetTransiActorList(GameState* state, TransitionActorList* transitionActors) { +void Scene_ResetTransitionActorList(GameState* state, TransitionActorList* transitionActors) { transitionActors->count = 0; } @@ -564,7 +564,7 @@ void (*sSceneCmdHandlers[SCENE_CMD_MAX])(PlayState*, SceneCmd*) = { Scene_CommandObjectList, // SCENE_CMD_ID_OBJECT_LIST Scene_CommandLightList, // SCENE_CMD_ID_LIGHT_LIST Scene_CommandPathList, // SCENE_CMD_ID_PATH_LIST - Scene_CommandTransiActorList, // SCENE_CMD_ID_TRANSI_ACTOR_LIST + Scene_CommandTransitionActorList, // SCENE_CMD_ID_TRANSI_ACTOR_LIST Scene_CommandEnvLightSettings, // SCENE_CMD_ID_ENV_LIGHT_SETTINGS Scene_CommandTimeSettings, // SCENE_CMD_ID_TIME_SETTINGS Scene_CommandSkyboxSettings, // SCENE_CMD_ID_SKYBOX_SETTINGS diff --git a/tools/disasm/functions.txt b/tools/disasm/functions.txt index 6c4c6af13..c978a43d4 100644 --- a/tools/disasm/functions.txt +++ b/tools/disasm/functions.txt @@ -2434,8 +2434,8 @@ 0x8012FC18:("Scene_CommandObjectList",), 0x8012FDA4:("Scene_CommandLightList",), 0x8012FE2C:("Scene_CommandPathList",), - 0x8012FE5C:("Scene_CommandTransiActorList",), - 0x8012FEBC:("Scene_ResetTransiActorList",), + 0x8012FE5C:("Scene_CommandTransitionActorList",), + 0x8012FEBC:("Scene_ResetTransitionActorList",), 0x8012FECC:("Scene_CommandEnvLightSettings",), 0x8012FF10:("Scene_LoadAreaTextures",), 0x8012FF8C:("Scene_CommandSkyboxSettings",), diff --git a/tools/sizes/code_functions.csv b/tools/sizes/code_functions.csv index 247eee68a..0b55a55d7 100644 --- a/tools/sizes/code_functions.csv +++ b/tools/sizes/code_functions.csv @@ -1948,7 +1948,7 @@ asm/non_matchings/code/z_scene/Scene_CommandMesh.s,Scene_CommandMesh,0x8012FBE8, asm/non_matchings/code/z_scene/Scene_CommandObjectList.s,Scene_CommandObjectList,0x8012FC18,0x63 asm/non_matchings/code/z_scene/Scene_CommandLightList.s,Scene_CommandLightList,0x8012FDA4,0x22 asm/non_matchings/code/z_scene/Scene_CommandPathList.s,Scene_CommandPathList,0x8012FE2C,0xC -asm/non_matchings/code/z_scene/Scene_CommandTransiActorList.s,Scene_CommandTransiActorList,0x8012FE5C,0x18 +asm/non_matchings/code/z_scene/Scene_CommandTransitionActorList.s,Scene_CommandTransitionActorList,0x8012FE5C,0x18 asm/non_matchings/code/z_scene/Door_InitContext.s,Door_InitContext,0x8012FEBC,0x4 asm/non_matchings/code/z_scene/Scene_CommandEnvLightSettings.s,Scene_CommandEnvLightSettings,0x8012FECC,0x11 asm/non_matchings/code/z_scene/Scene_LoadAreaTextures.s,Scene_LoadAreaTextures,0x8012FF10,0x1F