From 09a179960f1a82e1e337c38e424890c8224e0cd1 Mon Sep 17 00:00:00 2001 From: Jordan Longstaff Date: Sun, 8 Jun 2025 11:16:34 -0400 Subject: [PATCH 1/4] Child Ruto Actions: Enums (#2603) * Child Ruto Actions: Enums * Stronger typedefs * Fix wrong action enum usage Co-authored-by: Dragorn421 * Undo single-line formatting of actions array * Fix formatting * Remove trailing commas * Move all enums to header * Index action functions with comments --------- Co-authored-by: Dragorn421 --- src/overlays/actors/ovl_En_Ru1/z_en_ru1.c | 230 ++++++++++++---------- src/overlays/actors/ovl_En_Ru1/z_en_ru1.h | 77 ++++++++ 2 files changed, 201 insertions(+), 106 deletions(-) diff --git a/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c b/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c index 575755d445..6f897d28b0 100644 --- a/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c +++ b/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c @@ -90,28 +90,6 @@ void EnRu1_DrawNothing(EnRu1* this, PlayState* play); void EnRu1_DrawOpa(EnRu1* this, PlayState* play); void EnRu1_DrawXlu(EnRu1* this, PlayState* play); -typedef enum EnRu1Eyes { - /* 0 */ ENRU1_EYES_OPEN, - /* 1 */ ENRU1_EYES_HALF_BLINK, - /* 2 */ ENRU1_EYES_CLOSED, - /* 3 */ ENRU1_EYES_UP, - /* 4 */ ENRU1_EYES_GAZING, - /* 5 */ ENRU1_EYES_BLUSH, -} EnRu1Eyes; - -typedef enum EnRu1Mouth { - /* 0 */ ENRU1_MOUTH_SMILING, - /* 1 */ ENRU1_MOUTH_FROWNING, - /* 2 */ ENRU1_MOUTH_OPEN, -} EnRu1Mouth; - -typedef enum EnRu1WaterState { - /* 0 */ ENRU1_WATER_OUTSIDE, - /* 1 */ ENRU1_WATER_IMMERSED, - /* 2 */ ENRU1_WATER_BOBBING, - /* 3 */ ENRU1_WATER_SINKING, -} EnRu1WaterState; - static ColliderCylinderInitType1 sStandingCylinderInit = { { COL_MATERIAL_HIT0, @@ -154,13 +132,52 @@ static s32 sUnused = 0; static u32 D_80AF1938 = 0; static EnRu1ActionFunc sActionFuncs[] = { - func_80AEC0B4, func_80AEC100, func_80AEC130, func_80AEC17C, func_80AEC1D4, func_80AEC244, func_80AEC2C0, - func_80AECA94, func_80AECAB4, func_80AECAD4, func_80AECB18, func_80AECB60, func_80AECBB8, func_80AECC1C, - func_80AECC84, func_80AED304, func_80AED324, func_80AED344, func_80AED374, func_80AED3A4, func_80AED3E0, - func_80AED414, func_80AEF29C, func_80AEF2AC, func_80AEF2D0, func_80AEF354, func_80AEF3A8, func_80AEEBD4, - func_80AEEC5C, func_80AEECF0, func_80AEED58, func_80AEEDCC, func_80AEEE34, func_80AEEE9C, func_80AEEF08, - func_80AEEF5C, func_80AEF9D8, func_80AEFA2C, func_80AEFAAC, func_80AEFB04, func_80AEFB68, func_80AEFCE8, - func_80AEFBC8, func_80AEFC24, func_80AEFECC, func_80AEFF40, + func_80AEC0B4, // ENRU1_ACTION_00 + func_80AEC100, // ENRU1_ACTION_01 + func_80AEC130, // ENRU1_ACTION_02 + func_80AEC17C, // ENRU1_ACTION_03 + func_80AEC1D4, // ENRU1_ACTION_04 + func_80AEC244, // ENRU1_ACTION_05 + func_80AEC2C0, // ENRU1_ACTION_06 + func_80AECA94, // ENRU1_ACTION_07 + func_80AECAB4, // ENRU1_ACTION_08 + func_80AECAD4, // ENRU1_ACTION_09 + func_80AECB18, // ENRU1_ACTION_10 + func_80AECB60, // ENRU1_ACTION_11 + func_80AECBB8, // ENRU1_ACTION_12 + func_80AECC1C, // ENRU1_ACTION_13 + func_80AECC84, // ENRU1_ACTION_14 + func_80AED304, // ENRU1_ACTION_15 + func_80AED324, // ENRU1_ACTION_16 + func_80AED344, // ENRU1_ACTION_17 + func_80AED374, // ENRU1_ACTION_18 + func_80AED3A4, // ENRU1_ACTION_19 + func_80AED3E0, // ENRU1_ACTION_20 + func_80AED414, // ENRU1_ACTION_21 + func_80AEF29C, // ENRU1_ACTION_22 + func_80AEF2AC, // ENRU1_ACTION_23 + func_80AEF2D0, // ENRU1_ACTION_24 + func_80AEF354, // ENRU1_ACTION_25 + func_80AEF3A8, // ENRU1_ACTION_26 + func_80AEEBD4, // ENRU1_ACTION_27 + func_80AEEC5C, // ENRU1_ACTION_28 + func_80AEECF0, // ENRU1_ACTION_29 + func_80AEED58, // ENRU1_ACTION_30 + func_80AEEDCC, // ENRU1_ACTION_31 + func_80AEEE34, // ENRU1_ACTION_32 + func_80AEEE9C, // ENRU1_ACTION_33 + func_80AEEF08, // ENRU1_ACTION_34 + func_80AEEF5C, // ENRU1_ACTION_35 + func_80AEF9D8, // ENRU1_ACTION_36 + func_80AEFA2C, // ENRU1_ACTION_37 + func_80AEFAAC, // ENRU1_ACTION_38 + func_80AEFB04, // ENRU1_ACTION_39 + func_80AEFB68, // ENRU1_ACTION_40 + func_80AEFCE8, // ENRU1_ACTION_41 + func_80AEFBC8, // ENRU1_ACTION_42 + func_80AEFC24, // ENRU1_ACTION_43 + func_80AEFECC, // ENRU1_ACTION_44 + func_80AEFF40, // ENRU1_ACTION_45 }; static EnRu1PreLimbDrawFunc sPreLimbDrawFuncs[] = { @@ -325,7 +342,8 @@ s32 func_80AEB020(EnRu1* this, PlayState* play) { if (actorIt->id == ACTOR_EN_RU1) { someEnRu1 = (EnRu1*)actorIt; if (someEnRu1 != this) { - if ((someEnRu1->action == 31) || (someEnRu1->action == 32) || (someEnRu1->action == 24)) { + if ((someEnRu1->action == ENRU1_ACTION_31) || (someEnRu1->action == ENRU1_ACTION_32) || + (someEnRu1->action == ENRU1_ACTION_24)) { return true; } } @@ -385,8 +403,8 @@ s32 func_80AEB1B4(PlayState* play) { #if DEBUG_FEATURES void func_80AEB1D8(EnRu1* this) { - this->action = 36; - this->drawConfig = 0; + this->action = ENRU1_ACTION_36; + this->drawConfig = ENRU1_DRAW_NOTHING; this->actor.velocity.x = 0.0f; this->actor.velocity.y = 0.0f; this->actor.velocity.z = 0.0f; @@ -426,7 +444,7 @@ void EnRu1_AnimationChange(EnRu1* this, AnimationHeader* animation, u8 mode, f32 s32 EnRu1_UpdateSkelAnime(EnRu1* this) { // why? - if (this->action != 32) { + if (this->action != ENRU1_ACTION_32) { return SkelAnime_Update(&this->skelAnime); } else { return SkelAnime_Update(&this->skelAnime); @@ -449,8 +467,8 @@ void func_80AEB3CC(EnRu1* this) { void EnRu1_InitOutsideJabuJabu(EnRu1* this, PlayState* play) { EnRu1_AnimationChange(this, &gRutoChildWaitHandsBehindBackAnim, ANIMMODE_LOOP, 0, false); - this->action = 0; - this->drawConfig = 1; + this->action = ENRU1_ACTION_00; + this->drawConfig = ENRU1_DRAW_OPA; EnRu1_SetEyes(this, ENRU1_EYES_GAZING); EnRu1_SetMouth(this, ENRU1_MOUTH_SMILING); } @@ -653,8 +671,8 @@ void func_80AEBCB8(EnRu1* this, UNK_TYPE arg1) { void func_80AEBD1C(EnRu1* this, PlayState* play) { if (func_80AEB480(play, 2)) { - this->action = 1; - this->drawConfig = 0; + this->action = ENRU1_ACTION_01; + this->drawConfig = ENRU1_DRAW_NOTHING; func_80AEB914(this, play); func_80AEAECC(this, play); EnRu1_SpawnSplash(this, play); @@ -671,8 +689,8 @@ void func_80AEBD94(EnRu1* this, PlayState* play) { func_80AEB934(this, play); func_80AEB738(this, play); Animation_Change(&this->skelAnime, &gRutoChildResurfaceAnim, 1.0f, 0.0f, frameCount, ANIMMODE_ONCE, 0.0f); - this->action = 2; - this->drawConfig = 1; + this->action = ENRU1_ACTION_02; + this->drawConfig = ENRU1_DRAW_OPA; } } @@ -684,7 +702,7 @@ void func_80AEBE3C(EnRu1* this, PlayState* play, s32 arg2) { func_80AEB7D0(this); Animation_Change(&this->skelAnime, &gRutoChildTreadWaterAnim, 1.0f, 0, frameCount, ANIMMODE_LOOP, -8.0f); - this->action = 3; + this->action = ENRU1_ACTION_03; } else { func_80AEB954(this, play); } @@ -699,7 +717,7 @@ void func_80AEBEC8(EnRu1* this, PlayState* play) { func_80AEB738(this, play); Animation_Change(&this->skelAnime, &gRutoChildTransitionToSwimOnBackAnim, 1.0f, 0, frameCount, ANIMMODE_ONCE, -8.0f); - this->action = 4; + this->action = ENRU1_ACTION_04; } } @@ -708,7 +726,7 @@ void func_80AEBF60(EnRu1* this, PlayState* play) { s32 pad; func_80AEB7D0(this); - this->action = 5; + this->action = ENRU1_ACTION_05; this->unk_364 = this->actor.world.pos; } else { func_80AEBA0C(this, play); @@ -729,7 +747,7 @@ void func_80AEBFD8(EnRu1* this, PlayState* play) { frameCount = Animation_GetLastFrame(&gRutoChildTransitionFromSwimOnBackAnim); Animation_Change(&this->skelAnime, &gRutoChildTransitionFromSwimOnBackAnim, 1.0, 0, frameCount, ANIMMODE_ONCE, -8.0f); - this->action = 6; + this->action = ENRU1_ACTION_06; } } } @@ -807,7 +825,7 @@ void func_80AEC2C0(EnRu1* this, PlayState* play) { void EnRu1_InitInJabuJabuHolesRoom(EnRu1* this, PlayState* play) { if (!GET_INFTABLE(INFTABLE_141)) { EnRu1_AnimationChange(this, &gRutoChildWait2Anim, ANIMMODE_LOOP, 0, false); - this->action = 7; + this->action = ENRU1_ACTION_07; EnRu1_SetMouth(this, ENRU1_MOUTH_FROWNING); } else if (GET_INFTABLE(INFTABLE_147) && !GET_INFTABLE(INFTABLE_140) && !GET_INFTABLE(INFTABLE_145)) { if (!func_80AEB020(this, play)) { @@ -815,9 +833,9 @@ void EnRu1_InitInJabuJabuHolesRoom(EnRu1* this, PlayState* play) { EnRu1_AnimationChange(this, &gRutoChildWait2Anim, ANIMMODE_LOOP, 0, false); actorRoom = this->actor.room; - this->action = 22; + this->action = ENRU1_ACTION_22; this->actor.room = -1; - this->drawConfig = 0; + this->drawConfig = ENRU1_DRAW_NOTHING; this->roomNum1 = actorRoom; this->roomNum3 = actorRoom; this->roomNum2 = actorRoom; @@ -907,7 +925,7 @@ void func_80AEC780(EnRu1* this, PlayState* play) { play->csCtx.script = gRutoFirstMeetingCs; gSaveContext.cutsceneTrigger = 1; player->speedXZ = 0.0f; - this->action = 8; + this->action = ENRU1_ACTION_08; } } @@ -923,8 +941,8 @@ void func_80AEC81C(EnRu1* this, PlayState* play) { newRotY = cue->rot.y; this->actor.shape.rot.y = newRotY; this->actor.world.rot.y = newRotY; - this->action = 9; - this->drawConfig = 1; + this->action = ENRU1_ACTION_09; + this->drawConfig = ENRU1_DRAW_OPA; } } @@ -932,7 +950,7 @@ void func_80AEC8B8(EnRu1* this, PlayState* play) { if (func_80AEAFA0(play, 3, 3)) { Animation_Change(&this->skelAnime, &gRutoChildTurnAroundAnim, 1.0f, 0, Animation_GetLastFrame(&gRutoChildTurnAroundAnim), ANIMMODE_ONCE, -8.0f); - this->action = 10; + this->action = ENRU1_ACTION_10; } } @@ -941,7 +959,7 @@ void func_80AEC93C(EnRu1* this, UNK_TYPE arg1) { Animation_Change(&this->skelAnime, &gRutoChildWalkAnim, 1.0f, 0, Animation_GetLastFrame(&gRutoChildWalkAnim), ANIMMODE_LOOP, -8.0f); this->actor.world.rot.y += 0x8000; - this->action = 0xB; + this->action = ENRU1_ACTION_11; this->unk_26C = 0.0f; } } @@ -949,7 +967,7 @@ void func_80AEC93C(EnRu1* this, UNK_TYPE arg1) { void func_80AEC9C4(EnRu1* this) { this->unk_26C += 1.0f; if (this->unk_26C >= 8.0f) { - this->action = 12; + this->action = ENRU1_ACTION_12; this->unk_26C = 0.0f; this->actor.velocity.y = -1.0f; } @@ -959,7 +977,7 @@ void func_80AECA18(EnRu1* this) { if (!(this->actor.bgCheckFlags & BGCHECKFLAG_GROUND)) { s32 pad; - this->action = 13; + this->action = ENRU1_ACTION_13; this->unk_26C = 0.0f; this->actor.velocity.y = 0.0f; } @@ -968,7 +986,7 @@ void func_80AECA18(EnRu1* this) { void func_80AECA44(EnRu1* this, PlayState* play) { if (func_80AEAFA0(play, 5, 3)) { SET_INFTABLE(INFTABLE_141); - this->action = 14; + this->action = ENRU1_ACTION_14; } } @@ -1051,7 +1069,7 @@ void func_80AECCB0(EnRu1* this, PlayState* play) { void EnRu1_InitInBossRoom(EnRu1* this, PlayState* play) { EnRu1_AnimationChange(this, &gRutoChildWaitHandsOnHipsAnim, ANIMMODE_LOOP, 0, false); - this->action = 15; + this->action = ENRU1_ACTION_15; this->actor.shape.yOffset = -10000.0f; EnRu1_SetEyes(this, ENRU1_EYES_BLUSH); EnRu1_SetMouth(this, ENRU1_MOUTH_OPEN); @@ -1129,12 +1147,12 @@ void func_80AED0B0(EnRu1* this, s32 state) { } void func_80AED0C8(EnRu1* this, PlayState* play) { - this->action = 16; + this->action = ENRU1_ACTION_16; } void func_80AED0D8(EnRu1* this, PlayState* play) { - this->action = 17; - this->drawConfig = 1; + this->action = ENRU1_ACTION_17; + this->drawConfig = ENRU1_DRAW_OPA; this->actor.world.rot.y = this->actor.yawTowardsPlayer; this->actor.shape.rot.y = this->actor.yawTowardsPlayer; func_80AECCB0(this, play); @@ -1142,7 +1160,7 @@ void func_80AED0D8(EnRu1* this, PlayState* play) { void func_80AED110(EnRu1* this) { if (this->actor.shape.yOffset >= 0.0f) { - this->action = 18; + this->action = ENRU1_ACTION_18; this->actor.shape.yOffset = 0.0f; func_80AED0B0(this, WARP_BLUE_RUTO_STATE_READY); } @@ -1150,7 +1168,7 @@ void func_80AED110(EnRu1* this) { void func_80AED154(EnRu1* this, PlayState* play) { if (func_80AED084(this, WARP_BLUE_RUTO_STATE_ENTERED)) { - this->action = 0x13; + this->action = ENRU1_ACTION_19; this->unk_26C = 0.0f; func_80AECEB4(this, play); } @@ -1161,7 +1179,7 @@ void func_80AED19C(EnRu1* this, s32 cond) { Animation_Change(&this->skelAnime, &gRutoChildTransitionHandsOnHipToCrossArmsAndLegsAnim, 1.0f, 0, Animation_GetLastFrame(&gRutoChildTransitionHandsOnHipToCrossArmsAndLegsAnim), ANIMMODE_ONCE, -8.0f); - this->action = 20; + this->action = ENRU1_ACTION_20; func_80AED0B0(this, WARP_BLUE_RUTO_STATE_3); } } @@ -1175,7 +1193,7 @@ void func_80AED218(EnRu1* this, UNK_TYPE arg1) { } else if (func_80AED084(this, WARP_BLUE_RUTO_STATE_WARPING)) { Animation_Change(&this->skelAnime, &gRutoChildWaitInBlueWarpAnim, 1.0f, 0, Animation_GetLastFrame(&gRutoChildWaitInBlueWarpAnim), ANIMMODE_ONCE, -8.0f); - this->action = 21; + this->action = ENRU1_ACTION_21; this->unk_27C = this->actor.xzDistToPlayer; } } @@ -1223,7 +1241,7 @@ void EnRu1_InitInJabuJabuBasement(EnRu1* this, PlayState* play) { EnRu1_AnimationChange(this, &gRutoChildWait2Anim, ANIMMODE_LOOP, 0, false); actorRoom = this->actor.room; - this->action = 22; + this->action = ENRU1_ACTION_22; this->actor.room = -1; this->roomNum1 = actorRoom; this->roomNum3 = actorRoom; @@ -1273,9 +1291,9 @@ s32 func_80AED624(EnRu1* this, PlayState* play) { Actor_Kill(&this->actor); return false; } else if (((this->roomNum1 != curRoomNum) || (this->roomNum2 != curRoomNum)) && - (this->actor.depthInWater > kREG(16) + 50.0f) && (this->action != 33)) { - this->action = 33; - this->drawConfig = 2; + (this->actor.depthInWater > kREG(16) + 50.0f) && (this->action != ENRU1_ACTION_33)) { + this->action = ENRU1_ACTION_33; + this->drawConfig = ENRU1_DRAW_XLU; this->alpha = 0xFF; this->unk_2A4 = 0.0f; } @@ -1598,8 +1616,8 @@ s32 func_80AEE394(EnRu1* this, PlayState* play) { func_80AEE02C(this); play->csCtx.script = gRutoObtainingSapphireCs; gSaveContext.cutsceneTrigger = 1; - this->action = 36; - this->drawConfig = 0; + this->action = ENRU1_ACTION_36; + this->drawConfig = ENRU1_DRAW_NOTHING; this->bigOctoPlatform = (BgBdanObjects*)dynaPolyActor; this->actor.shape.shadowAlpha = 0; return true; @@ -1614,14 +1632,14 @@ void func_80AEE488(EnRu1* this, PlayState* play) { if (Actor_HasParent(&this->actor, play)) { curRoomNum = play->roomCtx.curRoom.num; this->roomNum3 = curRoomNum; - this->action = 31; + this->action = ENRU1_ACTION_31; func_80AED520(this, play); } else if (!func_80AEE394(this, play) && !(this->actor.bgCheckFlags & BGCHECKFLAG_GROUND)) { s32 pad; this->actor.minVelocityY = -((kREG(24) * 0.01f) + 6.8f); this->actor.gravity = -((kREG(23) * 0.01f) + 1.3f); - this->action = 28; + this->action = ENRU1_ACTION_28; } } @@ -1633,13 +1651,13 @@ void func_80AEE568(EnRu1* this, PlayState* play) { func_80AEE02C(this); Actor_OfferCarry(&this->actor, play); - this->action = 27; + this->action = ENRU1_ACTION_27; EnRu1_DisableSittingOC(this); return; } if (this->actor.depthInWater > 0.0f) { - this->action = 29; + this->action = ENRU1_ACTION_29; this->waterState = ENRU1_WATER_OUTSIDE; } } @@ -1653,7 +1671,7 @@ void func_80AEE628(EnRu1* this, PlayState* play) { Animation_Change(&this->skelAnime, &gRutoChildSittingAnim, 1.0f, 0, Animation_GetLastFrame(&gRutoChildSittingAnim), ANIMMODE_LOOP, -8.0f); SET_INFTABLE(INFTABLE_144); - this->action = 31; + this->action = ENRU1_ACTION_31; } this->roomNum3 = curRoomNum; } @@ -1667,7 +1685,7 @@ s32 func_80AEE6D0(EnRu1* this, PlayState* play) { Animation_Change(&this->skelAnime, &gRutoChildSeesSapphireAnim, 1.0f, 0, Animation_GetLastFrame(&gRutoChildSquirmAnim), ANIMMODE_LOOP, -8.0f); func_80AED600(this); - this->action = 34; + this->action = ENRU1_ACTION_34; this->unk_26C = 0.0f; play->csCtx.script = gRutoFoundSapphireCs; gSaveContext.cutsceneTrigger = 1; @@ -1694,7 +1712,7 @@ void EnRu1_UpdateCarriedBehavior(EnRu1* this, PlayState* play) { this->actor.minVelocityY = -((kREG(24) * 0.01f) + 6.8f); this->actor.gravity = -((kREG(23) * 0.01f) + 1.3f); func_80AED57C(this); - this->action = 28; + this->action = ENRU1_ACTION_28; *carryIdleTimer = 0.0f; } else if (func_80AEE6D0(this, play)) { s32 pad; @@ -1704,7 +1722,7 @@ void EnRu1_UpdateCarriedBehavior(EnRu1* this, PlayState* play) { player = GET_PLAYER(play); if (player->stateFlags2 & PLAYER_STATE2_IDLE_FIDGET) { this->carryIdleTimer += 1.0f; - if (this->action != 32) { + if (this->action != ENRU1_ACTION_32) { if (*carryIdleTimer > 30.0f) { if (Rand_S16Offset(0, 3) == 0) { f32 frameCount = Animation_GetLastFrame(&gRutoChildSquirmAnim); @@ -1712,7 +1730,7 @@ void EnRu1_UpdateCarriedBehavior(EnRu1* this, PlayState* play) { Animation_Change(&this->skelAnime, &gRutoChildSquirmAnim, 1.0f, 0, frameCount, ANIMMODE_LOOP, -8.0f); func_80AED5DC(this); - this->action = 32; + this->action = ENRU1_ACTION_32; } *carryIdleTimer = 0.0f; } @@ -1722,7 +1740,7 @@ void EnRu1_UpdateCarriedBehavior(EnRu1* this, PlayState* play) { Animation_Change(&this->skelAnime, &gRutoChildSittingAnim, 1.0f, 0, frameCount, ANIMMODE_LOOP, -8.0f); - this->action = 31; + this->action = ENRU1_ACTION_31; *carryIdleTimer = 0.0f; } } @@ -1741,7 +1759,7 @@ s32 EnRu1_CheckHitBottomUnderwater(EnRu1* this, PlayState* play) { func_80AEE02C(this); Actor_OfferCarry(&this->actor, play); - this->action = 27; + this->action = ENRU1_ACTION_27; EnRu1_DisableSittingOC(this); return true; } @@ -1749,8 +1767,8 @@ s32 EnRu1_CheckHitBottomUnderwater(EnRu1* this, PlayState* play) { } void EnRu1_CheckSinkingState(EnRu1* this, PlayState* play) { - if ((EnRu1_CheckHitBottomUnderwater(this, play) == 0) && (this->waterState == ENRU1_WATER_SINKING)) { - this->action = 30; + if ((!EnRu1_CheckHitBottomUnderwater(this, play)) && (this->waterState == ENRU1_WATER_SINKING)) { + this->action = ENRU1_ACTION_30; func_80AEE02C(this); this->actor.gravity = -0.1f; this->actor.minVelocityY = -((kREG(18) * 0.1f) + 0.7f); @@ -1881,7 +1899,7 @@ s32 func_80AEF0BC(EnRu1* this, PlayState* play) { Animation_Change(&this->skelAnime, &gRutoChildSitAnim, 1.0f, 0, frameCount, ANIMMODE_ONCE, -8.0f); play->msgCtx.msgMode = MSGMODE_PAUSED; - this->action = 26; + this->action = ENRU1_ACTION_26; this->actor.flags &= ~(ACTOR_FLAG_ATTENTION_ENABLED | ACTOR_FLAG_FRIENDLY); return true; } @@ -1890,7 +1908,7 @@ s32 func_80AEF0BC(EnRu1* this, PlayState* play) { void func_80AEF170(EnRu1* this, PlayState* play, s32 cond) { if (cond) { - this->action = 25; + this->action = ENRU1_ACTION_25; } } @@ -1898,7 +1916,7 @@ void func_80AEF188(EnRu1* this, PlayState* play) { if (func_80AEB174(play) && !func_80AEF0BC(this, play)) { Message_CloseTextbox(play); SET_INFTABLE(INFTABLE_142); - this->action = 24; + this->action = ENRU1_ACTION_24; } } @@ -1910,18 +1928,18 @@ void func_80AEF1F0(EnRu1* this, PlayState* play, UNK_TYPE arg2) { SET_INFTABLE(INFTABLE_143); func_80AED6DC(this, play); Actor_OfferCarry(&this->actor, play); - this->action = 27; + this->action = ENRU1_ACTION_27; EnRu1_DisableSittingOC(this); } } void func_80AEF29C(EnRu1* this, PlayState* play) { - this->action = 23; + this->action = ENRU1_ACTION_23; } void func_80AEF2AC(EnRu1* this, PlayState* play) { - this->action = 24; - this->drawConfig = 1; + this->action = ENRU1_ACTION_24; + this->drawConfig = ENRU1_DRAW_OPA; this->actor.flags |= ACTOR_FLAG_ATTENTION_ENABLED | ACTOR_FLAG_FRIENDLY; } @@ -2032,8 +2050,8 @@ void func_80AEF624(EnRu1* this, PlayState* play) { Animation_Change(&this->skelAnime, &gRutoChildWalkToAndHoldUpSapphireAnim, 1.0f, 0.0f, frameCount, ANIMMODE_ONCE, 0.0f); func_80AEB3A4(this, play); - this->action = 37; - this->drawConfig = 1; + this->action = ENRU1_ACTION_37; + this->drawConfig = ENRU1_DRAW_OPA; this->actor.shape.shadowAlpha = 0xFF; } } @@ -2043,7 +2061,7 @@ void func_80AEF728(EnRu1* this, UNK_TYPE arg1) { Animation_Change(&this->skelAnime, &gRutoChildHoldArmsUpAnim, 1.0f, 0.0f, Animation_GetLastFrame(&gRutoChildHoldArmsUpAnim), ANIMMODE_LOOP, 0.0f); func_80AEB3CC(this); - this->action = 38; + this->action = ENRU1_ACTION_38; } } @@ -2051,7 +2069,7 @@ void func_80AEF79C(EnRu1* this, PlayState* play) { if (func_80AEAFE0(play, 2, 3)) { Animation_Change(&this->skelAnime, &gRutoChildBringHandsDownAnim, 1.0f, 0, Animation_GetLastFrame(&gRutoChildBringHandsDownAnim), ANIMMODE_ONCE, -8.0f); - this->action = 39; + this->action = ENRU1_ACTION_39; } } @@ -2059,7 +2077,7 @@ void func_80AEF820(EnRu1* this, UNK_TYPE arg1) { if (arg1 != 0) { Animation_Change(&this->skelAnime, &gRutoChildWait2Anim, 1.0f, 0, Animation_GetLastFrame(&gRutoChildWait2Anim), ANIMMODE_LOOP, -8.0f); - this->action = 40; + this->action = ENRU1_ACTION_40; } } @@ -2072,7 +2090,7 @@ void func_80AEF890(EnRu1* this, PlayState* play) { SET_INFTABLE(INFTABLE_145); Flags_SetSwitch(play, EnRu1_GetSwitchFlag(this)); EnRu1_SetPlatformCamSetting(this, 1); - this->action = 42; + this->action = ENRU1_ACTION_42; this->actor.room = curRoomNum; } } @@ -2087,8 +2105,8 @@ void func_80AEF930(EnRu1* this, PlayState* play) { Message_StartTextbox(play, this->actor.textId, NULL); #endif func_80AEF4A8(this, play); - this->action = 43; - this->drawConfig = 0; + this->action = ENRU1_ACTION_43; + this->drawConfig = ENRU1_DRAW_NOTHING; } } @@ -2178,7 +2196,7 @@ void EnRu1_InitInSapphireRoom(EnRu1* this, PlayState* play) { s32 pad; EnRu1_AnimationChange(this, &gRutoChildWait2Anim, ANIMMODE_LOOP, 0, false); - this->action = 41; + this->action = ENRU1_ACTION_41; this->bigOctoPlatform = EnRu1_FindBigOctoPlatform(play); EnRu1_SetPlatformCamSetting(this, 1); this->actor.flags &= ~(ACTOR_FLAG_ATTENTION_ENABLED | ACTOR_FLAG_FRIENDLY); @@ -2190,8 +2208,8 @@ void EnRu1_InitInSapphireRoom(EnRu1* this, PlayState* play) { void func_80AEFCE8(EnRu1* this, PlayState* play) { this->bigOctoPlatform = EnRu1_FindBigOctoPlatform(play); if (this->bigOctoPlatform != NULL) { - this->action = 42; - this->drawConfig = 1; + this->action = ENRU1_ACTION_42; + this->drawConfig = ENRU1_DRAW_OPA; EnRu1_SetPlatformCamSetting(this, 1); } } @@ -2200,8 +2218,8 @@ void EnRu1_InitBesideKingZora(EnRu1* this, PlayState* play) { if (GET_EVENTCHKINF(EVENTCHKINF_37) && LINK_IS_CHILD) { EnRu1_AnimationChange(this, &gRutoChildWait2Anim, ANIMMODE_LOOP, 0, false); this->actor.flags &= ~ACTOR_FLAG_UPDATE_CULLING_DISABLED; - this->action = 44; - this->drawConfig = 1; + this->action = ENRU1_ACTION_44; + this->drawConfig = ENRU1_DRAW_OPA; } else { Actor_Kill(&this->actor); } @@ -2230,13 +2248,13 @@ s32 func_80AEFE38(EnRu1* this, PlayState* play) { void func_80AEFE84(EnRu1* this, PlayState* play, s32 cond) { if (cond) { - this->action = 45; + this->action = ENRU1_ACTION_45; } } void func_80AEFE9C(EnRu1* this, PlayState* play) { if (func_80AEFE38(this, play)) { - this->action = 44; + this->action = ENRU1_ACTION_44; } } @@ -2267,9 +2285,9 @@ void EnRu1_InitBesideDoorSwitch(EnRu1* this, PlayState* play) { (!(func_80AEB020(this, play)))) { EnRu1_AnimationChange(this, &gRutoChildWait2Anim, ANIMMODE_LOOP, 0, false); actorRoom = this->actor.room; - this->action = 22; + this->action = ENRU1_ACTION_22; this->actor.room = -1; - this->drawConfig = 0; + this->drawConfig = ENRU1_DRAW_NOTHING; this->roomNum1 = actorRoom; this->roomNum3 = actorRoom; this->roomNum2 = actorRoom; @@ -2283,7 +2301,7 @@ void EnRu1_InitBesideDoorSwitch(EnRu1* this, PlayState* play) { #if DEBUG_FEATURES void func_80AF0050(EnRu1* this, PlayState* play) { EnRu1_AnimationChange(this, &gRutoChildWait2Anim, ANIMMODE_LOOP, 0, false); - this->action = 36; + this->action = ENRU1_ACTION_36; this->roomNum1 = this->actor.room; this->bigOctoPlatform = EnRu1_FindBigOctoPlatform(play); this->actor.room = -1; diff --git a/src/overlays/actors/ovl_En_Ru1/z_en_ru1.h b/src/overlays/actors/ovl_En_Ru1/z_en_ru1.h index 6968b6fb0d..52e89effd1 100644 --- a/src/overlays/actors/ovl_En_Ru1/z_en_ru1.h +++ b/src/overlays/actors/ovl_En_Ru1/z_en_ru1.h @@ -60,6 +60,61 @@ typedef struct EnRu1 { /* 0x0374 */ NpcInteractInfo interactInfo; } EnRu1; // size = 0x039C +typedef enum EnRu1Action { + /* 0 */ ENRU1_ACTION_00, + /* 1 */ ENRU1_ACTION_01, + /* 2 */ ENRU1_ACTION_02, + /* 3 */ ENRU1_ACTION_03, + /* 4 */ ENRU1_ACTION_04, + /* 5 */ ENRU1_ACTION_05, + /* 6 */ ENRU1_ACTION_06, + /* 7 */ ENRU1_ACTION_07, + /* 8 */ ENRU1_ACTION_08, + /* 9 */ ENRU1_ACTION_09, + /* 10 */ ENRU1_ACTION_10, + /* 11 */ ENRU1_ACTION_11, + /* 12 */ ENRU1_ACTION_12, + /* 13 */ ENRU1_ACTION_13, + /* 14 */ ENRU1_ACTION_14, + /* 15 */ ENRU1_ACTION_15, + /* 16 */ ENRU1_ACTION_16, + /* 17 */ ENRU1_ACTION_17, + /* 18 */ ENRU1_ACTION_18, + /* 19 */ ENRU1_ACTION_19, + /* 20 */ ENRU1_ACTION_20, + /* 21 */ ENRU1_ACTION_21, + /* 22 */ ENRU1_ACTION_22, + /* 23 */ ENRU1_ACTION_23, + /* 24 */ ENRU1_ACTION_24, + /* 25 */ ENRU1_ACTION_25, + /* 26 */ ENRU1_ACTION_26, + /* 27 */ ENRU1_ACTION_27, + /* 28 */ ENRU1_ACTION_28, + /* 29 */ ENRU1_ACTION_29, + /* 30 */ ENRU1_ACTION_30, + /* 31 */ ENRU1_ACTION_31, + /* 32 */ ENRU1_ACTION_32, + /* 33 */ ENRU1_ACTION_33, + /* 34 */ ENRU1_ACTION_34, + /* 35 */ ENRU1_ACTION_35, + /* 36 */ ENRU1_ACTION_36, + /* 37 */ ENRU1_ACTION_37, + /* 38 */ ENRU1_ACTION_38, + /* 39 */ ENRU1_ACTION_39, + /* 40 */ ENRU1_ACTION_40, + /* 41 */ ENRU1_ACTION_41, + /* 42 */ ENRU1_ACTION_42, + /* 43 */ ENRU1_ACTION_43, + /* 44 */ ENRU1_ACTION_44, + /* 45 */ ENRU1_ACTION_45 +} EnRu1Action; + +typedef enum EnRu1DrawConfig { + /* 0 */ ENRU1_DRAW_NOTHING, + /* 1 */ ENRU1_DRAW_OPA, + /* 2 */ ENRU1_DRAW_XLU +} EnRu1DrawConfig; + typedef enum EnRu1Type { /* 0 */ ENRU1_TYPE_BOSS_ROOM, /* 1 */ ENRU1_TYPE_FOUNTAIN, @@ -73,6 +128,28 @@ typedef enum EnRu1Type { #endif } EnRu1Type; +typedef enum EnRu1Eyes { + /* 0 */ ENRU1_EYES_OPEN, + /* 1 */ ENRU1_EYES_HALF_BLINK, + /* 2 */ ENRU1_EYES_CLOSED, + /* 3 */ ENRU1_EYES_UP, + /* 4 */ ENRU1_EYES_GAZING, + /* 5 */ ENRU1_EYES_BLUSH +} EnRu1Eyes; + +typedef enum EnRu1Mouth { + /* 0 */ ENRU1_MOUTH_SMILING, + /* 1 */ ENRU1_MOUTH_FROWNING, + /* 2 */ ENRU1_MOUTH_OPEN +} EnRu1Mouth; + +typedef enum EnRu1WaterState { + /* 0 */ ENRU1_WATER_OUTSIDE, + /* 1 */ ENRU1_WATER_IMMERSED, + /* 2 */ ENRU1_WATER_BOBBING, + /* 3 */ ENRU1_WATER_SINKING +} EnRu1WaterState; + typedef enum RutoLimb { /* 0 */ RUTO_CHILD_NONE, /* 1 */ RUTO_CHILD_ROOT, From f213f6bae2cee6f39520b295d3d7ca41b4a6c28c Mon Sep 17 00:00:00 2001 From: Dragorn421 Date: Mon, 9 Jun 2025 00:52:10 +0200 Subject: [PATCH 2/4] .d files: use -MP (fixes make with deleted deps) (#2615) --- Makefile | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/Makefile b/Makefile index 56134bd7fc..5103d58691 100644 --- a/Makefile +++ b/Makefile @@ -366,8 +366,8 @@ CPPFLAGS += -P -xc -fno-dollars-in-identifiers $(CPP_DEFINES) ASFLAGS += -march=vr4300 -32 -no-pad-sections -Iinclude -I$(EXTRACTED_DIR) ifeq ($(COMPILER),gcc) - CFLAGS += $(CPP_DEFINES) $(GBI_DEFINES) -G 0 -nostdinc -MD $(INC) -march=vr4300 -mfix4300 -mabi=32 -mno-abicalls -mdivide-breaks -fno-PIC -fno-common -ffreestanding -funsigned-char -fbuiltin -fno-builtin-sinf -fno-builtin-cosf $(CHECK_WARNINGS) - CCASFLAGS += $(CPP_DEFINES) $(GBI_DEFINES) -G 0 -nostdinc -MD $(INC) -march=vr4300 -mfix4300 -mabi=32 -mno-abicalls -fno-PIC -fno-common -Wa,-no-pad-sections + CFLAGS += $(CPP_DEFINES) $(GBI_DEFINES) -G 0 -nostdinc -MD -MP $(INC) -march=vr4300 -mfix4300 -mabi=32 -mno-abicalls -mdivide-breaks -fno-PIC -fno-common -ffreestanding -funsigned-char -fbuiltin -fno-builtin-sinf -fno-builtin-cosf $(CHECK_WARNINGS) + CCASFLAGS += $(CPP_DEFINES) $(GBI_DEFINES) -G 0 -nostdinc -MD -MP $(INC) -march=vr4300 -mfix4300 -mabi=32 -mno-abicalls -fno-PIC -fno-common -Wa,-no-pad-sections MIPS_VERSION := -mips3 else # Suppress warnings for wrong number of macro arguments (to fake variadic @@ -385,7 +385,7 @@ endif ifeq ($(COMPILER),ido) # Have CC_CHECK pretend to be a MIPS compiler MIPS_BUILTIN_DEFS := -D_MIPS_ISA_MIPS2=2 -D_MIPS_ISA=_MIPS_ISA_MIPS2 -D_ABIO32=1 -D_MIPS_SIM=_ABIO32 -D_MIPS_SZINT=32 -D_MIPS_SZLONG=32 -D_MIPS_SZPTR=32 - CC_CHECK = gcc -nostdinc -MD -fno-builtin -fsyntax-only -funsigned-char -std=gnu90 -D_LANGUAGE_C $(CPP_DEFINES) $(MIPS_BUILTIN_DEFS) $(GBI_DEFINES) $(INC) $(CHECK_WARNINGS) + CC_CHECK = gcc -nostdinc -MD -MP -fno-builtin -fsyntax-only -funsigned-char -std=gnu90 -D_LANGUAGE_C $(CPP_DEFINES) $(MIPS_BUILTIN_DEFS) $(GBI_DEFINES) $(INC) $(CHECK_WARNINGS) ifeq ($(shell getconf LONG_BIT), 32) # Work around memory allocation bug in QEMU export QEMU_GUEST_BASE := 1 @@ -858,7 +858,7 @@ $(O_FILES): | asset_files .PHONY: o_files asset_files $(BUILD_DIR)/spec: $(SPEC) $(SPEC_INCLUDES) - $(CPP) $(CPPFLAGS) -MD -MF $@.d -MT $@ -I. $< | $(BUILD_DIR_REPLACE) > $@ + $(CPP) $(CPPFLAGS) -MD -MP -MF $@.d -MT $@ -I. $< | $(BUILD_DIR_REPLACE) > $@ $(LDSCRIPT): $(BUILD_DIR)/spec $(MKLDSCRIPT) $< $@ @@ -870,7 +870,7 @@ $(BUILD_DIR)/baserom/%.o: $(EXTRACTED_DIR)/baserom/% $(OBJCOPY) -I binary -O elf32-big $< $@ $(BUILD_DIR)/data/%.o: data/%.s - $(CPP) $(CPPFLAGS) -MD -MF $(@:.o=.d) -MT $@ -Iinclude $< | $(AS) $(ASFLAGS) -o $@ + $(CPP) $(CPPFLAGS) -MD -MP -MF $(@:.o=.d) -MT $@ -Iinclude $< | $(AS) $(ASFLAGS) -o $@ ifeq ($(PLATFORM),IQUE) NES_CHARMAP := assets/text/charmap.chn.txt @@ -879,10 +879,10 @@ else endif $(BUILD_DIR)/assets/text/%.enc.nes.h: assets/text/%.h $(EXTRACTED_DIR)/text/%.h $(NES_CHARMAP) - $(CPP) $(CPPFLAGS) -I$(EXTRACTED_DIR) -MD -MF $(@:.o=.d) -MT $@ $< | $(PYTHON) tools/msgenc.py --encoding utf-8 --charmap $(NES_CHARMAP) - $@ + $(CPP) $(CPPFLAGS) -I$(EXTRACTED_DIR) -MD -MP -MF $(@:.o=.d) -MT $@ $< | $(PYTHON) tools/msgenc.py --encoding utf-8 --charmap $(NES_CHARMAP) - $@ $(BUILD_DIR)/assets/text/%.enc.jpn.h: assets/text/%.h $(EXTRACTED_DIR)/text/%.h assets/text/charmap.jpn.txt - $(CPP) $(CPPFLAGS) -I$(EXTRACTED_DIR) -MD -MF $(@:.o=.d) -MT $@ $< | $(PYTHON) tools/msgenc.py --encoding SHIFT-JIS --wchar --charmap assets/text/charmap.jpn.txt - $@ + $(CPP) $(CPPFLAGS) -I$(EXTRACTED_DIR) -MD -MP -MF $(@:.o=.d) -MT $@ $< | $(PYTHON) tools/msgenc.py --encoding SHIFT-JIS --wchar --charmap assets/text/charmap.jpn.txt - $@ # Dependencies for encoded message headers. These dependencies are not automatic as these headers are generated # as part of the build. A clean build must know to generate them before the relevant .d files are created. @@ -895,7 +895,7 @@ $(BUILD_DIR)/assets/text/staff_message_data_static.o: $(BUILD_DIR)/assets/text/m $(BUILD_DIR)/assets/text/%.o: assets/text/%.c ifneq ($(COMPILER),gcc) # Preprocess text with modern cpp for varargs macros - $(CPP) -undef -D_LANGUAGE_C -D__sgi $(CPPFLAGS) -MD -MT $@ $(INC) $< -o $(@:.o=.c) + $(CPP) -undef -D_LANGUAGE_C -D__sgi $(CPPFLAGS) -MD -MP -MT $@ $(INC) $< -o $(@:.o=.c) $(CC) -c $(CFLAGS) $(MIPS_VERSION) $(OPTFLAGS) -o $@ $(@:.o=.c) else $(CC) -c $(CFLAGS) $(MIPS_VERSION) $(OPTFLAGS) -o $@ $< @@ -915,7 +915,7 @@ $(BUILD_DIR)/assets/%.o: $(EXTRACTED_DIR)/assets/%.c # Assemble the ROM header with GNU AS always $(BUILD_DIR)/src/makerom/rom_header.o: src/makerom/rom_header.s ifeq ($(COMPILER),ido) - $(CPP) $(CPPFLAGS) $(MIPS_BUILTIN_DEFS) $(INC) -MD -MF $(@:.o=.d) -MT $@ $< | $(AS) $(ASFLAGS) -o $@ + $(CPP) $(CPPFLAGS) $(MIPS_BUILTIN_DEFS) $(INC) -MD -MP -MF $(@:.o=.d) -MT $@ $< | $(AS) $(ASFLAGS) -o $@ else $(CCAS) -c $(CCASFLAGS) $(MIPS_VERSION) $(ASOPTFLAGS) -o $@ $< endif @@ -927,7 +927,7 @@ $(BUILD_DIR)/src/makerom/ipl3.o: $(EXTRACTED_DIR)/incbin/ipl3 $(BUILD_DIR)/src/%.o: src/%.s ifeq ($(COMPILER),ido) # For header dependencies - $(CPP) $(MIPS_BUILTIN_DEFS) $(CPPFLAGS) -x assembler-with-cpp $(INC) -MD -MF $(@:.o=.d) -MT $@ $< -o /dev/null + $(CPP) $(MIPS_BUILTIN_DEFS) $(CPPFLAGS) -x assembler-with-cpp $(INC) -MD -MP -MF $(@:.o=.d) -MT $@ $< -o /dev/null $(CCAS) -c $(CCASFLAGS) $(MIPS_VERSION) $(ASOPTFLAGS) -o $(@:.o=.tmp.o) $< # IDO generates bad symbol tables, fix the symbol table with strip.. $(STRIP) $(@:.o=.tmp.o) -N dummy-symbol-name @@ -1072,7 +1072,7 @@ $(BUILD_DIR)/assets/audio/soundfonts/%.c $(BUILD_DIR)/assets/audio/soundfonts/%. -include $(SOUNDFONT_DEP_FILES) $(BUILD_DIR)/assets/audio/soundfonts/%.o: $(BUILD_DIR)/assets/audio/soundfonts/%.c $(BUILD_DIR)/assets/audio/soundfonts/%.name - $(CPP) $(MIPS_BUILTIN_DEFS) $(CPPFLAGS) -x assembler-with-cpp $(INC) -I include/audio -MD -MF $(@:.o=.d) -MT $@ $< -o /dev/null + $(CPP) $(MIPS_BUILTIN_DEFS) $(CPPFLAGS) -x assembler-with-cpp $(INC) -I include/audio -MD -MP -MF $(@:.o=.d) -MT $@ $< -o /dev/null # compile c to unlinked object $(CC) -c $(CFLAGS) $(MIPS_VERSION) $(OPTFLAGS) -I include/audio -o $(@:.o=.tmp) $< # partial link @@ -1093,11 +1093,11 @@ endif # then assemble the sequences... $(BUILD_DIR)/assets/audio/sequences/%.o: assets/audio/sequences/%.seq include/audio/aseq.h $(SEQUENCE_TABLE) | $(SOUNDFONT_HEADERS) - $(SEQ_CPP) $(SEQ_CPPFLAGS) -MD -MT $@ $< -o $(@:.o=.s) + $(SEQ_CPP) $(SEQ_CPPFLAGS) -MD -MP -MT $@ $< -o $(@:.o=.s) $(AS) $(ASFLAGS) -I $(BUILD_DIR)/assets/audio/soundfonts -I include/audio -I $(dir $<) $(@:.o=.s) -o $@ $(BUILD_DIR)/assets/audio/sequences/%.o: $(EXTRACTED_DIR)/assets/audio/sequences/%.seq include/audio/aseq.h $(SEQUENCE_TABLE) | $(SOUNDFONT_HEADERS) - $(SEQ_CPP) $(SEQ_CPPFLAGS) -MD -MT $@ $< -o $(@:.o=.s) + $(SEQ_CPP) $(SEQ_CPPFLAGS) -MD -MP -MT $@ $< -o $(@:.o=.s) $(AS) $(ASFLAGS) -I $(BUILD_DIR)/assets/audio/soundfonts -I include/audio -I $(dir $<) $(@:.o=.s) -o $@ ifeq ($(AUDIO_BUILD_DEBUG),1) $(OBJCOPY) -O binary -j.data $@ $(@:.o=.aseq) From d4a87889ff974b7ce20625d5de556903745ae469 Mon Sep 17 00:00:00 2001 From: Dragorn421 Date: Mon, 9 Jun 2025 13:06:46 +0200 Subject: [PATCH 3/4] Commit some `assets/overlays/` 2 (#2610) * Commit some `assets/overlays/` 2 * format --- assets/xml/overlays/ovl_Elf_Msg.xml | 2 +- assets/xml/overlays/ovl_Elf_Msg2.xml | 2 +- .../actors/ovl_Boss_Ganon2/z_boss_ganon2.c | 159 +++++++++++++++++- src/overlays/actors/ovl_Elf_Msg/z_elf_msg.c | 23 ++- src/overlays/actors/ovl_Elf_Msg2/z_elf_msg2.c | 15 +- .../ovl_En_Ganon_Organ/z_en_ganon_organ.c | 91 +++++++++- .../actors/ovl_Magic_Dark/z_magic_dark.c | 19 ++- .../actors/ovl_Magic_Fire/z_magic_fire.c | 19 ++- .../actors/ovl_Oceff_Spot/z_oceff_spot.c | 19 ++- .../actors/ovl_Oceff_Storm/z_oceff_storm.c | 25 ++- .../actors/ovl_Oceff_Wipe/z_oceff_wipe.c | 19 ++- .../actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c | 25 ++- .../actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c | 19 ++- .../actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c | 25 ++- tools/assets/extract/write_source.txt | 12 -- 15 files changed, 445 insertions(+), 29 deletions(-) diff --git a/assets/xml/overlays/ovl_Elf_Msg.xml b/assets/xml/overlays/ovl_Elf_Msg.xml index 61e28d31b7..a6b07b2e37 100644 --- a/assets/xml/overlays/ovl_Elf_Msg.xml +++ b/assets/xml/overlays/ovl_Elf_Msg.xml @@ -1,7 +1,7 @@ - + diff --git a/assets/xml/overlays/ovl_Elf_Msg2.xml b/assets/xml/overlays/ovl_Elf_Msg2.xml index a0ea055e26..c4f10e8cd3 100644 --- a/assets/xml/overlays/ovl_Elf_Msg2.xml +++ b/assets/xml/overlays/ovl_Elf_Msg2.xml @@ -1,7 +1,7 @@ - + diff --git a/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c b/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c index efe3f9583f..3c19bf8eab 100644 --- a/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c +++ b/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c @@ -17,6 +17,7 @@ #include "sfx.h" #include "sys_math.h" #include "sys_matrix.h" +#include "tex_len.h" #include "versions.h" #include "z_lib.h" #include "effect.h" @@ -28,7 +29,7 @@ #include "assets/objects/object_ganon2/object_ganon2.h" #include "assets/objects/object_ganon_anime3/object_ganon_anime3.h" #include "assets/objects/object_geff/object_geff.h" -#include "assets/overlays/ovl_Boss_Ganon2/ovl_Boss_Ganon2.h" +#include "assets/objects/gameplay_keep/gameplay_keep.h" #pragma increment_block_number "gc-eu:128 gc-eu-mq:128 gc-jp:128 gc-jp-ce:128 gc-jp-mq:128 gc-us:128 gc-us-mq:128" \ "ique-cn:128 ntsc-1.0:128 ntsc-1.1:128 ntsc-1.2:128 pal-1.0:128 pal-1.1:128" @@ -75,6 +76,19 @@ void BossGanon2_DrawEffects(PlayState* play); void BossGanon2_GenShadowTexture(void* shadowTexture, BossGanon2* this, PlayState* play); void BossGanon2_DrawShadowTexture(void* shadowTexture, BossGanon2* this, PlayState* play); +static Gfx gGanonLightOrbMaterialDL[14]; +static Gfx gGanonLightOrbModelDL[3]; +static Gfx gGanonShadowMaterialDL[4]; +static Gfx gGanonShadowModelDL[6]; +static Vtx gGanonSwordTrailVtx[22]; +static Gfx gGanonSwordTrailDL[35]; +static Gfx gGanonTriforceDL[16]; +static Gfx gGanonLightningDL[17]; +static Gfx gGanonFireRingDL[36]; +static Gfx gGanonZeldaMagicDL[33]; +static Gfx gGanonMasterSwordShadowDL[16]; +static Gfx gGanonMasterSwordDL[122]; + ActorProfile Boss_Ganon2_Profile = { /**/ ACTOR_BOSS_GANON2, /**/ ACTORCAT_BOSS, @@ -3460,4 +3474,145 @@ void BossGanon2_DrawShadowTexture(void* shadowTexture, BossGanon2* this, PlaySta // padding static u32 D_809071FC[2] = { 0 }; -#include "assets/overlays/ovl_Boss_Ganon2/ovl_Boss_Ganon2.c" +#define gGanonLightOrbTex_WIDTH 64 +#define gGanonLightOrbTex_HEIGHT 64 +static u64 gGanonLightOrbTex[TEX_LEN(u64, gGanonLightOrbTex_WIDTH, gGanonLightOrbTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonLightOrbTex.i8.inc.c" +}; + +static Vtx gGanonLightOrbModelVtx[] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonLightOrbModelVtx.inc.c" +}; + +static Gfx gGanonLightOrbMaterialDL[14] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonLightOrbMaterialDL.inc.c" +}; + +static Gfx gGanonLightOrbModelDL[3] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonLightOrbModelDL.inc.c" +}; + +static Vtx gGanonShadowModelVtx[] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonShadowModelVtx.inc.c" +}; + +static Gfx gGanonShadowMaterialDL[4] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonShadowMaterialDL.inc.c" +}; + +static Gfx gGanonShadowModelDL[6] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonShadowModelDL.inc.c" +}; + +#define gGanonSwordTrailTex_WIDTH 32 +#define gGanonSwordTrailTex_HEIGHT 32 +static u64 gGanonSwordTrailTex[TEX_LEN(u64, gGanonSwordTrailTex_WIDTH, gGanonSwordTrailTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonSwordTrailTex.i8.inc.c" +}; + +#define gGanonSwordTrailMaskTex_WIDTH 32 +#define gGanonSwordTrailMaskTex_HEIGHT 32 +static u64 gGanonSwordTrailMaskTex[TEX_LEN(u64, gGanonSwordTrailMaskTex_WIDTH, gGanonSwordTrailMaskTex_HEIGHT, 4)] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonSwordTrailMaskTex.i4.inc.c" +}; + +static Vtx gGanonSwordTrailVtx[22] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonSwordTrailVtx.inc.c" +}; + +static Gfx gGanonSwordTrailDL[35] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonSwordTrailDL.inc.c" +}; + +#define gGanonTriforceTex_WIDTH 64 +#define gGanonTriforceTex_HEIGHT 64 +static u64 gGanonTriforceTex[TEX_LEN(u64, gGanonTriforceTex_WIDTH, gGanonTriforceTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonTriforceTex.i8.inc.c" +}; + +static Vtx gGanonTriforceVtx[] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonTriforceVtx.inc.c" +}; + +static Gfx gGanonTriforceDL[16] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonTriforceDL.inc.c" +}; + +#define gGanonLightningTex_WIDTH 32 +#define gGanonLightningTex_HEIGHT 160 +static u64 gGanonLightningTex[TEX_LEN(u64, gGanonLightningTex_WIDTH, gGanonLightningTex_HEIGHT, 4)] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonLightningTex.i4.inc.c" +}; + +static Vtx gGanonLightningVtx[] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonLightningVtx.inc.c" +}; + +static Gfx gGanonLightningDL[17] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonLightningDL.inc.c" +}; + +#define gGanonFireRingTex_WIDTH 32 +#define gGanonFireRingTex_HEIGHT 64 +static u64 gGanonFireRingTex[TEX_LEN(u64, gGanonFireRingTex_WIDTH, gGanonFireRingTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonFireRingTex.i8.inc.c" +}; + +static Vtx gGanonFireRingVtx[] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonFireRingVtx.inc.c" +}; + +static Gfx gGanonFireRingDL[36] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonFireRingDL.inc.c" +}; + +#define gGanonZeldaMagicTex_WIDTH 32 +#define gGanonZeldaMagicTex_HEIGHT 64 +static u64 gGanonZeldaMagicTex[TEX_LEN(u64, gGanonZeldaMagicTex_WIDTH, gGanonZeldaMagicTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonZeldaMagicTex.i8.inc.c" +}; + +static Vtx gGanonZeldaMagicVtx[] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonZeldaMagicVtx.inc.c" +}; + +static Gfx gGanonZeldaMagicDL[33] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonZeldaMagicDL.inc.c" +}; + +#define gGanonMasterSwordShadowTex_WIDTH 32 +#define gGanonMasterSwordShadowTex_HEIGHT 32 +static u64 + gGanonMasterSwordShadowTex[TEX_LEN(u64, gGanonMasterSwordShadowTex_WIDTH, gGanonMasterSwordShadowTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonMasterSwordShadowTex.i8.inc.c" + }; + +static Vtx gGanonMasterSwordShadowVtx[] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonMasterSwordShadowVtx.inc.c" +}; + +static Gfx gGanonMasterSwordShadowDL[16] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonMasterSwordShadowDL.inc.c" +}; + +#define gGanonMasterSwordPommelTex_WIDTH 16 +#define gGanonMasterSwordPommelTex_HEIGHT 16 +static u64 gGanonMasterSwordPommelTex[TEX_LEN(u64, gGanonMasterSwordPommelTex_WIDTH, gGanonMasterSwordPommelTex_HEIGHT, + 16)] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonMasterSwordPommelTex.rgba16.inc.c" +}; + +#define gGanonMasterSwordGuardTex_WIDTH 32 +#define gGanonMasterSwordGuardTex_HEIGHT 32 +static u64 + gGanonMasterSwordGuardTex[TEX_LEN(u64, gGanonMasterSwordGuardTex_WIDTH, gGanonMasterSwordGuardTex_HEIGHT, 16)] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonMasterSwordGuardTex.rgba16.inc.c" + }; + +static Vtx gGanonMasterSwordVtx[] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonMasterSwordVtx.inc.c" +}; + +static Gfx gGanonMasterSwordDL[122] = { +#include "assets/overlays/ovl_Boss_Ganon2/gGanonMasterSwordDL.inc.c" +}; diff --git a/src/overlays/actors/ovl_Elf_Msg/z_elf_msg.c b/src/overlays/actors/ovl_Elf_Msg/z_elf_msg.c index fd54803e25..abfbb1d29b 100644 --- a/src/overlays/actors/ovl_Elf_Msg/z_elf_msg.c +++ b/src/overlays/actors/ovl_Elf_Msg/z_elf_msg.c @@ -181,7 +181,26 @@ void ElfMsg_Update(Actor* thisx, PlayState* play) { } #if DEBUG_ASSETS -#include "assets/overlays/ovl_Elf_Msg/ovl_Elf_Msg.c" + +static Gfx sMaterialDL[8] = { +#include "assets/overlays/ovl_Elf_Msg/sMaterialDL.inc.c" +}; + +static Vtx sCylinderVtx[] = { +#include "assets/overlays/ovl_Elf_Msg/sCylinderVtx.inc.c" +}; + +static Gfx sCylinderDL[16] = { +#include "assets/overlays/ovl_Elf_Msg/sCylinderDL.inc.c" +}; + +static Vtx sCubeVtx[] = { +#include "assets/overlays/ovl_Elf_Msg/sCubeVtx.inc.c" +}; + +static Gfx sCubeDL[8] = { +#include "assets/overlays/ovl_Elf_Msg/sCubeDL.inc.c" +}; void ElfMsg_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx, "../z_elf_msg.c", 436); @@ -198,7 +217,7 @@ void ElfMsg_Draw(Actor* thisx, PlayState* play) { } MATRIX_FINALIZE_AND_LOAD(POLY_XLU_DISP++, play->state.gfxCtx, "../z_elf_msg.c", 448); - gSPDisplayList(POLY_XLU_DISP++, D_809AD278); + gSPDisplayList(POLY_XLU_DISP++, sMaterialDL); if (PARAMS_GET_NOSHIFT(thisx->params, 14, 1)) { gSPDisplayList(POLY_XLU_DISP++, sCubeDL); diff --git a/src/overlays/actors/ovl_Elf_Msg2/z_elf_msg2.c b/src/overlays/actors/ovl_Elf_Msg2/z_elf_msg2.c index 11a01bc4b8..9a7401619e 100644 --- a/src/overlays/actors/ovl_Elf_Msg2/z_elf_msg2.c +++ b/src/overlays/actors/ovl_Elf_Msg2/z_elf_msg2.c @@ -163,7 +163,18 @@ void ElfMsg2_Update(Actor* thisx, PlayState* play) { } #if DEBUG_ASSETS -#include "assets/overlays/ovl_Elf_Msg2/ovl_Elf_Msg2.c" + +static Gfx sMaterialDL[8] = { +#include "assets/overlays/ovl_Elf_Msg2/sMaterialDL.inc.c" +}; + +static Vtx sCubeVtx[] = { +#include "assets/overlays/ovl_Elf_Msg2/sCubeVtx.inc.c" +}; + +static Gfx sCubeDL[8] = { +#include "assets/overlays/ovl_Elf_Msg2/sCubeDL.inc.c" +}; void ElfMsg2_Draw(Actor* thisx, PlayState* play) { OPEN_DISPS(play->state.gfxCtx, "../z_elf_msg2.c", 355); @@ -175,7 +186,7 @@ void ElfMsg2_Draw(Actor* thisx, PlayState* play) { Gfx_SetupDL_25Opa(play->state.gfxCtx); gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 100, 100, 255, R_NAVI_MSG_REGION_ALPHA); MATRIX_FINALIZE_AND_LOAD(POLY_XLU_DISP++, play->state.gfxCtx, "../z_elf_msg2.c", 362); - gSPDisplayList(POLY_XLU_DISP++, D_809ADC38); + gSPDisplayList(POLY_XLU_DISP++, sMaterialDL); gSPDisplayList(POLY_XLU_DISP++, sCubeDL); CLOSE_DISPS(play->state.gfxCtx, "../z_elf_msg2.c", 367); diff --git a/src/overlays/actors/ovl_En_Ganon_Organ/z_en_ganon_organ.c b/src/overlays/actors/ovl_En_Ganon_Organ/z_en_ganon_organ.c index 6237f84e06..0830301e04 100644 --- a/src/overlays/actors/ovl_En_Ganon_Organ/z_en_ganon_organ.c +++ b/src/overlays/actors/ovl_En_Ganon_Organ/z_en_ganon_organ.c @@ -10,6 +10,7 @@ #include "gfx_setupdl.h" #include "printf.h" #include "sys_matrix.h" +#include "tex_len.h" #include "play_state.h" #include "overlays/actors/ovl_Boss_Ganon/z_boss_ganon.h" @@ -35,7 +36,95 @@ ActorProfile En_Ganon_Organ_Profile = { static u64 sForceAlignment = 0; -#include "assets/overlays/ovl_En_Ganon_Organ/ovl_En_Ganon_Organ.c" +#define sRoomCarpetTex_WIDTH 64 +#define sRoomCarpetTex_HEIGHT 16 +static u64 sRoomCarpetTex[TEX_LEN(u64, sRoomCarpetTex_WIDTH, sRoomCarpetTex_HEIGHT, 16)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomCarpetTex.rgba16.inc.c" +}; + +#define sRoomOrganPipeTex_WIDTH 16 +#define sRoomOrganPipeTex_HEIGHT 64 +static u64 sRoomOrganPipeTex[TEX_LEN(u64, sRoomOrganPipeTex_WIDTH, sRoomOrganPipeTex_HEIGHT, 4)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomOrganPipeTex.i4.inc.c" +}; + +#define sRoomOrganCorbelsTex_WIDTH 16 +#define sRoomOrganCorbelsTex_HEIGHT 16 +static u64 sRoomOrganCorbelsTex[TEX_LEN(u64, sRoomOrganCorbelsTex_WIDTH, sRoomOrganCorbelsTex_HEIGHT, 4)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomOrganCorbelsTex.i4.inc.c" +}; + +#define sRoomOrganGrillTex_WIDTH 16 +#define sRoomOrganGrillTex_HEIGHT 16 +static u64 sRoomOrganGrillTex[TEX_LEN(u64, sRoomOrganGrillTex_WIDTH, sRoomOrganGrillTex_HEIGHT, 16)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomOrganGrillTex.rgba16.inc.c" +}; + +#define sRoomCrestFriezeTex_WIDTH 32 +#define sRoomCrestFriezeTex_HEIGHT 32 +static u64 sRoomCrestFriezeTex[TEX_LEN(u64, sRoomCrestFriezeTex_WIDTH, sRoomCrestFriezeTex_HEIGHT, 4)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomCrestFriezeTex.i4.inc.c" +}; + +#define sRoomColumnFriezeAndCanopyTex_WIDTH 16 +#define sRoomColumnFriezeAndCanopyTex_HEIGHT 16 +static u64 sRoomColumnFriezeAndCanopyTex[TEX_LEN(u64, sRoomColumnFriezeAndCanopyTex_WIDTH, + sRoomColumnFriezeAndCanopyTex_HEIGHT, 4)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomColumnFriezeAndCanopyTex.i4.inc.c" +}; + +#define sRoomColumnMetalEdgingTex_WIDTH 16 +#define sRoomColumnMetalEdgingTex_HEIGHT 16 +static u64 + sRoomColumnMetalEdgingTex[TEX_LEN(u64, sRoomColumnMetalEdgingTex_WIDTH, sRoomColumnMetalEdgingTex_HEIGHT, 16)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomColumnMetalEdgingTex.rgba16.inc.c" + }; + +#define sRoomStatueWingTex_WIDTH 16 +#define sRoomStatueWingTex_HEIGHT 16 +static u64 sRoomStatueWingTex[TEX_LEN(u64, sRoomStatueWingTex_WIDTH, sRoomStatueWingTex_HEIGHT, 16)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomStatueWingTex.rgba16.inc.c" +}; + +#define sRoomPillarTex_WIDTH 8 +#define sRoomPillarTex_HEIGHT 32 +static u64 sRoomPillarTex[TEX_LEN(u64, sRoomPillarTex_WIDTH, sRoomPillarTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomPillarTex.i8.inc.c" +}; + +#define sRoomOrganKeyboardTex_WIDTH 32 +#define sRoomOrganKeyboardTex_HEIGHT 8 +static u64 sRoomOrganKeyboardTex[TEX_LEN(u64, sRoomOrganKeyboardTex_WIDTH, sRoomOrganKeyboardTex_HEIGHT, 16)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomOrganKeyboardTex.rgba16.inc.c" +}; + +#define sRoomOrganKeyEndTex_WIDTH 4 +#define sRoomOrganKeyEndTex_HEIGHT 8 +static u64 sRoomOrganKeyEndTex[TEX_LEN(u64, sRoomOrganKeyEndTex_WIDTH, sRoomOrganKeyEndTex_HEIGHT, 16)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomOrganKeyEndTex.rgba16.inc.c" +}; + +#define sRoomStepTex_WIDTH 16 +#define sRoomStepTex_HEIGHT 16 +static u64 sRoomStepTex[TEX_LEN(u64, sRoomStepTex_WIDTH, sRoomStepTex_HEIGHT, 4)] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomStepTex.i4.inc.c" +}; + +static Vtx sRoomOrganAndFloorVtx[] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomOrganAndFloorVtx.inc.c" +}; + +static Gfx sRoomOrganAndFloorDL[429] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomOrganAndFloorDL.inc.c" +}; + +static Vtx sRoomStatuesVtx[] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomStatuesVtx.inc.c" +}; + +static Gfx sRoomStatuesDL[152] = { +#include "assets/overlays/ovl_En_Ganon_Organ/sRoomStatuesDL.inc.c" +}; void EnGanonOrgan_Init(Actor* thisx, PlayState* play) { thisx->flags &= ~ACTOR_FLAG_ATTENTION_ENABLED; diff --git a/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c b/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c index 21827f32c0..13acab8d46 100644 --- a/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c +++ b/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c @@ -11,6 +11,7 @@ #include "gfx_setupdl.h" #include "sfx.h" #include "sys_matrix.h" +#include "tex_len.h" #include "z_lib.h" #include "play_state.h" #include "player.h" @@ -41,7 +42,23 @@ ActorProfile Magic_Dark_Profile = { /**/ MagicDark_OrbDraw, }; -#include "assets/overlays/ovl_Magic_Dark/ovl_Magic_Dark.c" +#define sDiamondTex_WIDTH 32 +#define sDiamondTex_HEIGHT 64 +static u64 sDiamondTex[TEX_LEN(u64, sDiamondTex_WIDTH, sDiamondTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Magic_Dark/sDiamondTex.i8.inc.c" +}; + +static Vtx sDiamondVtx[] = { +#include "assets/overlays/ovl_Magic_Dark/sDiamondVtx.inc.c" +}; + +static Gfx sDiamondMaterialDL[22] = { +#include "assets/overlays/ovl_Magic_Dark/sDiamondMaterialDL.inc.c" +}; + +static Gfx sDiamondModelDL[8] = { +#include "assets/overlays/ovl_Magic_Dark/sDiamondModelDL.inc.c" +}; // unused static Color_RGBA8 D_80B88B10[] = { { 50, 100, 150, 200 }, { 255, 200, 150, 100 } }; diff --git a/src/overlays/actors/ovl_Magic_Fire/z_magic_fire.c b/src/overlays/actors/ovl_Magic_Fire/z_magic_fire.c index 103a7ee1b8..a5938c8fca 100644 --- a/src/overlays/actors/ovl_Magic_Fire/z_magic_fire.c +++ b/src/overlays/actors/ovl_Magic_Fire/z_magic_fire.c @@ -11,6 +11,7 @@ #include "ichain.h" #include "sfx.h" #include "sys_matrix.h" +#include "tex_len.h" #include "z_lib.h" #include "play_state.h" #include "player.h" @@ -51,7 +52,23 @@ ActorProfile Magic_Fire_Profile = { /**/ MagicFire_Draw, }; -#include "assets/overlays/ovl_Magic_Fire/ovl_Magic_Fire.c" +#define sTex_WIDTH 64 +#define sTex_HEIGHT 64 +static u64 sTex[TEX_LEN(u64, sTex_WIDTH, sTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Magic_Fire/sTex.i8.inc.c" +}; + +static Vtx sSphereVtx[] = { +#include "assets/overlays/ovl_Magic_Fire/sSphereVtx.inc.c" +}; + +static Gfx sMaterialDL[5] = { +#include "assets/overlays/ovl_Magic_Fire/sMaterialDL.inc.c" +}; + +static Gfx sModelDL[45] = { +#include "assets/overlays/ovl_Magic_Fire/sModelDL.inc.c" +}; static ColliderCylinderInit sCylinderInit = { { diff --git a/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c b/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c index 61772fa0c1..15f6308e1e 100644 --- a/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c +++ b/src/overlays/actors/ovl_Oceff_Spot/z_oceff_spot.c @@ -13,6 +13,7 @@ #include "regs.h" #include "sys_matrix.h" #include "terminal.h" +#include "tex_len.h" #include "translation.h" #include "z_lib.h" #include "light.h" @@ -42,7 +43,23 @@ ActorProfile Oceff_Spot_Profile = { /**/ OceffSpot_Draw, }; -#include "assets/overlays/ovl_Oceff_Spot/ovl_Oceff_Spot.c" +#define sTex_WIDTH 32 +#define sTex_HEIGHT 32 +static u64 sTex[TEX_LEN(u64, sTex_WIDTH, sTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Oceff_Spot/sTex.i8.inc.c" +}; + +static Vtx sCylinderVtx[] = { +#include "assets/overlays/ovl_Oceff_Spot/sCylinderVtx.inc.c" +}; + +static Gfx sCylinderMaterialDL[19] = { +#include "assets/overlays/ovl_Oceff_Spot/sCylinderMaterialDL.inc.c" +}; + +static Gfx sCylinderModelDL[18] = { +#include "assets/overlays/ovl_Oceff_Spot/sCylinderModelDL.inc.c" +}; static InitChainEntry sInitChain[] = { ICHAIN_VEC3F_DIV1000(scale, 0, ICHAIN_CONTINUE), diff --git a/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c b/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c index 036349d0e9..e7e623f024 100644 --- a/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c +++ b/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm.c @@ -9,10 +9,13 @@ #include "gfx.h" #include "gfx_setupdl.h" #include "sys_matrix.h" +#include "tex_len.h" #include "play_state.h" #include "player.h" #include "save.h" +#include "assets/objects/gameplay_keep/gameplay_keep.h" + #define FLAGS (ACTOR_FLAG_UPDATE_CULLING_DISABLED | ACTOR_FLAG_DRAW_CULLING_DISABLED | ACTOR_FLAG_UPDATE_DURING_OCARINA) void OceffStorm_Init(Actor* thisx, PlayState* play); @@ -127,7 +130,27 @@ void OceffStorm_Update(Actor* thisx, PlayState* play) { this->actionFunc(this, play); } -#include "assets/overlays/ovl_Oceff_Storm/ovl_Oceff_Storm.c" +#define sTex_WIDTH 64 +#define sTex_HEIGHT 64 +static u64 sTex[TEX_LEN(u64, sTex_WIDTH, sTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Oceff_Storm/sTex.i8.inc.c" +}; + +static Gfx sMaterialDL[21] = { +#include "assets/overlays/ovl_Oceff_Storm/sMaterialDL.inc.c" +}; + +static Vtx sCylinderVtx[] = { +#include "assets/overlays/ovl_Oceff_Storm/sCylinderVtx.inc.c" +}; + +static Gfx sCylinderMaterialDL[21] = { +#include "assets/overlays/ovl_Oceff_Storm/sCylinderMaterialDL.inc.c" +}; + +static Gfx sCylinderModelDL[18] = { +#include "assets/overlays/ovl_Oceff_Storm/sCylinderModelDL.inc.c" +}; void OceffStorm_Draw2(Actor* thisx, PlayState* play) { u32 scroll = play->state.frames & 0xFFF; diff --git a/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c b/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c index 8346407c9a..e07daebbfd 100644 --- a/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c +++ b/src/overlays/actors/ovl_Oceff_Wipe/z_oceff_wipe.c @@ -11,6 +11,7 @@ #include "printf.h" #include "sys_matrix.h" #include "terminal.h" +#include "tex_len.h" #include "z_lib.h" #include "play_state.h" #include "player.h" @@ -65,7 +66,23 @@ void OceffWipe_Update(Actor* thisx, PlayState* play) { } } -#include "assets/overlays/ovl_Oceff_Wipe/ovl_Oceff_Wipe.c" +#define sTex_WIDTH 32 +#define sTex_HEIGHT 32 +static u64 sTex[TEX_LEN(u64, sTex_WIDTH, sTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Oceff_Wipe/sTex.i8.inc.c" +}; + +static Vtx sFrustumVtx[] = { +#include "assets/overlays/ovl_Oceff_Wipe/sFrustumVtx.inc.c" +}; + +static Gfx sMaterialDL[17] = { +#include "assets/overlays/ovl_Oceff_Wipe/sMaterialDL.inc.c" +}; + +static Gfx sFrustumDL[23] = { +#include "assets/overlays/ovl_Oceff_Wipe/sFrustumDL.inc.c" +}; static u8 sAlphaIndices[] = { 0x01, 0x10, 0x22, 0x01, 0x20, 0x12, 0x01, 0x20, 0x12, 0x01, diff --git a/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c b/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c index 71498caa13..b71ddef91a 100644 --- a/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c +++ b/src/overlays/actors/ovl_Oceff_Wipe2/z_oceff_wipe2.c @@ -11,6 +11,7 @@ #include "printf.h" #include "sys_matrix.h" #include "terminal.h" +#include "tex_len.h" #include "z_lib.h" #include "play_state.h" #include "player.h" @@ -65,7 +66,29 @@ void OceffWipe2_Update(Actor* thisx, PlayState* play) { } } -#include "assets/overlays/ovl_Oceff_Wipe2/ovl_Oceff_Wipe2.c" +#define s1Tex_WIDTH 64 +#define s1Tex_HEIGHT 64 +static u64 s1Tex[TEX_LEN(u64, s1Tex_WIDTH, s1Tex_HEIGHT, 4)] = { +#include "assets/overlays/ovl_Oceff_Wipe2/s1Tex.i4.inc.c" +}; + +#define s2Tex_WIDTH 64 +#define s2Tex_HEIGHT 64 +static u64 s2Tex[TEX_LEN(u64, s2Tex_WIDTH, s2Tex_HEIGHT, 4)] = { +#include "assets/overlays/ovl_Oceff_Wipe2/s2Tex.i4.inc.c" +}; + +static Vtx sFrustumVtx[] = { +#include "assets/overlays/ovl_Oceff_Wipe2/sFrustumVtx.inc.c" +}; + +static Gfx sMaterialDL[21] = { +#include "assets/overlays/ovl_Oceff_Wipe2/sMaterialDL.inc.c" +}; + +static Gfx sFrustumDL[12] = { +#include "assets/overlays/ovl_Oceff_Wipe2/sFrustumDL.inc.c" +}; void OceffWipe2_Draw(Actor* thisx, PlayState* play) { u32 scroll = play->state.frames & 0xFF; diff --git a/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c b/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c index 6ec42324a2..eb62318ce7 100644 --- a/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c +++ b/src/overlays/actors/ovl_Oceff_Wipe3/z_oceff_wipe3.c @@ -11,6 +11,7 @@ #include "printf.h" #include "sys_matrix.h" #include "terminal.h" +#include "tex_len.h" #include "z_lib.h" #include "play_state.h" #include "player.h" @@ -35,7 +36,23 @@ ActorProfile Oceff_Wipe3_Profile = { /**/ OceffWipe3_Draw, }; -#include "assets/overlays/ovl_Oceff_Wipe3/ovl_Oceff_Wipe3.c" +#define sTex_WIDTH 64 +#define sTex_HEIGHT 64 +static u64 sTex[TEX_LEN(u64, sTex_WIDTH, sTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Oceff_Wipe3/sTex.i8.inc.c" +}; + +static Vtx sFrustumVtx[] = { +#include "assets/overlays/ovl_Oceff_Wipe3/sFrustumVtx.inc.c" +}; + +static Gfx sMaterialDL[17] = { +#include "assets/overlays/ovl_Oceff_Wipe3/sMaterialDL.inc.c" +}; + +static Gfx sFrustumDL[12] = { +#include "assets/overlays/ovl_Oceff_Wipe3/sFrustumDL.inc.c" +}; void OceffWipe3_Init(Actor* thisx, PlayState* play) { OceffWipe3* this = (OceffWipe3*)thisx; diff --git a/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c b/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c index 8b860cc0c1..00b97cc756 100644 --- a/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c +++ b/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c @@ -11,9 +11,12 @@ #include "printf.h" #include "sys_matrix.h" #include "terminal.h" +#include "tex_len.h" #include "z_lib.h" #include "play_state.h" +#include "assets/objects/gameplay_keep/gameplay_keep.h" + #define FLAGS (ACTOR_FLAG_UPDATE_CULLING_DISABLED | ACTOR_FLAG_UPDATE_DURING_OCARINA) void OceffWipe4_Init(Actor* thisx, PlayState* play); @@ -62,7 +65,27 @@ void OceffWipe4_Update(Actor* thisx, PlayState* play) { } } -#include "assets/overlays/ovl_Oceff_Wipe4/ovl_Oceff_Wipe4.c" +#define sTex_WIDTH 32 +#define sTex_HEIGHT 64 +static u64 sTex[TEX_LEN(u64, sTex_WIDTH, sTex_HEIGHT, 8)] = { +#include "assets/overlays/ovl_Oceff_Wipe4/sTex.i8.inc.c" +}; + +static Vtx sFrustumVtx[] = { +#include "assets/overlays/ovl_Oceff_Wipe4/sFrustumVtx.inc.c" +}; + +static Gfx sMaterialDL[13] = { +#include "assets/overlays/ovl_Oceff_Wipe4/sMaterialDL.inc.c" +}; + +static Gfx sUnusedMaterialDL[13] = { +#include "assets/overlays/ovl_Oceff_Wipe4/sUnusedMaterialDL.inc.c" +}; + +static Gfx sMaterial2DL[23] = { +#include "assets/overlays/ovl_Oceff_Wipe4/sMaterial2DL.inc.c" +}; void OceffWipe4_Draw(Actor* thisx, PlayState* play) { u32 scroll = play->state.frames & 0xFFF; diff --git a/tools/assets/extract/write_source.txt b/tools/assets/extract/write_source.txt index 4d77381e33..640767216e 100644 --- a/tools/assets/extract/write_source.txt +++ b/tools/assets/extract/write_source.txt @@ -382,29 +382,17 @@ assets/objects/object_zl2_anime2/object_zl2_anime2.c assets/objects/object_zl2/object_zl2.c assets/objects/object_zl4/object_zl4.c assets/objects/object_zo/object_zo.c -assets/overlays/ovl_Boss_Ganon2/ovl_Boss_Ganon2.c assets/overlays/ovl_Boss_Ganon/ovl_Boss_Ganon.c assets/overlays/ovl_Boss_Sst/ovl_Boss_Sst.c assets/overlays/ovl_Demo_Shd/ovl_Demo_Shd.c -assets/overlays/ovl_Elf_Msg2/ovl_Elf_Msg2.c -assets/overlays/ovl_Elf_Msg/ovl_Elf_Msg.c assets/overlays/ovl_En_Bili/ovl_En_Bili.c assets/overlays/ovl_En_Clear_Tag/ovl_En_Clear_Tag.c -assets/overlays/ovl_En_Ganon_Organ/ovl_En_Ganon_Organ.c assets/overlays/ovl_En_Mag/ovl_En_Mag.c assets/overlays/ovl_En_Sda/ovl_En_Sda.c assets/overlays/ovl_En_Ssh/ovl_En_Ssh.c assets/overlays/ovl_En_Sth/ovl_En_Sth.c assets/overlays/ovl_file_choose/ovl_file_choose.c -assets/overlays/ovl_Magic_Dark/ovl_Magic_Dark.c -assets/overlays/ovl_Magic_Fire/ovl_Magic_Fire.c assets/overlays/ovl_Magic_Wind/ovl_Magic_Wind.c -assets/overlays/ovl_Oceff_Spot/ovl_Oceff_Spot.c -assets/overlays/ovl_Oceff_Storm/ovl_Oceff_Storm.c -assets/overlays/ovl_Oceff_Wipe2/ovl_Oceff_Wipe2.c -assets/overlays/ovl_Oceff_Wipe3/ovl_Oceff_Wipe3.c -assets/overlays/ovl_Oceff_Wipe4/ovl_Oceff_Wipe4.c -assets/overlays/ovl_Oceff_Wipe/ovl_Oceff_Wipe.c assets/scenes/dungeons/bdan/bdan_room_0.c assets/scenes/dungeons/bdan/bdan_room_10.c assets/scenes/dungeons/bdan/bdan_room_11.c From 939b29299119888e486a41a10329580b22d6b9bd Mon Sep 17 00:00:00 2001 From: Dragorn421 Date: Mon, 9 Jun 2025 21:07:35 +0200 Subject: [PATCH 4/4] Commit `object_ganon_anime3` (#2611) * Commit object_ganon_anime3 * rm from write_source.txt * bss --- .../objects/object_ganon_anime3/gGanonRoarAnim.c | 15 +++++++++++++++ .../gGanonUncurlAndFlailAnim.c | 15 +++++++++++++++ .../object_ganon_anime3/gGanondorfBurstOutAnim.c | 15 +++++++++++++++ .../gGanondorfFloatingHeavyBreathingAnim.c | 15 +++++++++++++++ .../gGanondorfShowTriforceLoopAnim.c | 15 +++++++++++++++ .../gGanondorfShowTriforceStartAnim.c | 15 +++++++++++++++ .../gGanondorfTransformEndAnim.c | 15 +++++++++++++++ .../gGanondorfTransformLoopAnim.c | 15 +++++++++++++++ .../gGanondorfTransformStartAnim.c | 15 +++++++++++++++ .../object_ganon_anime3/object_ganon_anime3.h | 16 ++++++++++++++++ spec/spec | 10 +++++++++- .../actors/ovl_Boss_Ganon2/z_boss_ganon2.c | 4 ++-- tools/assets/extract/write_source.txt | 1 - 13 files changed, 162 insertions(+), 4 deletions(-) create mode 100644 assets/objects/object_ganon_anime3/gGanonRoarAnim.c create mode 100644 assets/objects/object_ganon_anime3/gGanonUncurlAndFlailAnim.c create mode 100644 assets/objects/object_ganon_anime3/gGanondorfBurstOutAnim.c create mode 100644 assets/objects/object_ganon_anime3/gGanondorfFloatingHeavyBreathingAnim.c create mode 100644 assets/objects/object_ganon_anime3/gGanondorfShowTriforceLoopAnim.c create mode 100644 assets/objects/object_ganon_anime3/gGanondorfShowTriforceStartAnim.c create mode 100644 assets/objects/object_ganon_anime3/gGanondorfTransformEndAnim.c create mode 100644 assets/objects/object_ganon_anime3/gGanondorfTransformLoopAnim.c create mode 100644 assets/objects/object_ganon_anime3/gGanondorfTransformStartAnim.c create mode 100644 assets/objects/object_ganon_anime3/object_ganon_anime3.h diff --git a/assets/objects/object_ganon_anime3/gGanonRoarAnim.c b/assets/objects/object_ganon_anime3/gGanonRoarAnim.c new file mode 100644 index 0000000000..cbc274b118 --- /dev/null +++ b/assets/objects/object_ganon_anime3/gGanonRoarAnim.c @@ -0,0 +1,15 @@ +#include "object_ganon_anime3.h" + +#include "ultra64.h" + +s16 gGanonRoarFrameData[] = { +#include "assets/objects/object_ganon_anime3/gGanonRoarFrameData.inc.c" +}; + +JointIndex gGanonRoarJointIndices[] = { +#include "assets/objects/object_ganon_anime3/gGanonRoarJointIndices.inc.c" +}; + +AnimationHeader gGanonRoarAnim = { +#include "assets/objects/object_ganon_anime3/gGanonRoarAnim.inc.c" +}; diff --git a/assets/objects/object_ganon_anime3/gGanonUncurlAndFlailAnim.c b/assets/objects/object_ganon_anime3/gGanonUncurlAndFlailAnim.c new file mode 100644 index 0000000000..a19de40d93 --- /dev/null +++ b/assets/objects/object_ganon_anime3/gGanonUncurlAndFlailAnim.c @@ -0,0 +1,15 @@ +#include "object_ganon_anime3.h" + +#include "ultra64.h" + +s16 gGanonUncurlAndFlailFrameData[] = { +#include "assets/objects/object_ganon_anime3/gGanonUncurlAndFlailFrameData.inc.c" +}; + +JointIndex gGanonUncurlAndFlailJointIndices[] = { +#include "assets/objects/object_ganon_anime3/gGanonUncurlAndFlailJointIndices.inc.c" +}; + +AnimationHeader gGanonUncurlAndFlailAnim = { +#include "assets/objects/object_ganon_anime3/gGanonUncurlAndFlailAnim.inc.c" +}; diff --git a/assets/objects/object_ganon_anime3/gGanondorfBurstOutAnim.c b/assets/objects/object_ganon_anime3/gGanondorfBurstOutAnim.c new file mode 100644 index 0000000000..a3a6625c0a --- /dev/null +++ b/assets/objects/object_ganon_anime3/gGanondorfBurstOutAnim.c @@ -0,0 +1,15 @@ +#include "object_ganon_anime3.h" + +#include "ultra64.h" + +s16 gGanondorfBurstOutFrameData[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfBurstOutFrameData.inc.c" +}; + +JointIndex gGanondorfBurstOutJointIndices[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfBurstOutJointIndices.inc.c" +}; + +AnimationHeader gGanondorfBurstOutAnim = { +#include "assets/objects/object_ganon_anime3/gGanondorfBurstOutAnim.inc.c" +}; diff --git a/assets/objects/object_ganon_anime3/gGanondorfFloatingHeavyBreathingAnim.c b/assets/objects/object_ganon_anime3/gGanondorfFloatingHeavyBreathingAnim.c new file mode 100644 index 0000000000..bbfa588465 --- /dev/null +++ b/assets/objects/object_ganon_anime3/gGanondorfFloatingHeavyBreathingAnim.c @@ -0,0 +1,15 @@ +#include "object_ganon_anime3.h" + +#include "ultra64.h" + +s16 gGanondorfFloatingHeavyBreathingFrameData[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfFloatingHeavyBreathingFrameData.inc.c" +}; + +JointIndex gGanondorfFloatingHeavyBreathingJointIndices[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfFloatingHeavyBreathingJointIndices.inc.c" +}; + +AnimationHeader gGanondorfFloatingHeavyBreathingAnim = { +#include "assets/objects/object_ganon_anime3/gGanondorfFloatingHeavyBreathingAnim.inc.c" +}; diff --git a/assets/objects/object_ganon_anime3/gGanondorfShowTriforceLoopAnim.c b/assets/objects/object_ganon_anime3/gGanondorfShowTriforceLoopAnim.c new file mode 100644 index 0000000000..5505f1aa08 --- /dev/null +++ b/assets/objects/object_ganon_anime3/gGanondorfShowTriforceLoopAnim.c @@ -0,0 +1,15 @@ +#include "object_ganon_anime3.h" + +#include "ultra64.h" + +s16 gGanondorfShowTriforceLoopFrameData[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfShowTriforceLoopFrameData.inc.c" +}; + +JointIndex gGanondorfShowTriforceLoopJointIndices[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfShowTriforceLoopJointIndices.inc.c" +}; + +AnimationHeader gGanondorfShowTriforceLoopAnim = { +#include "assets/objects/object_ganon_anime3/gGanondorfShowTriforceLoopAnim.inc.c" +}; diff --git a/assets/objects/object_ganon_anime3/gGanondorfShowTriforceStartAnim.c b/assets/objects/object_ganon_anime3/gGanondorfShowTriforceStartAnim.c new file mode 100644 index 0000000000..3092cccff4 --- /dev/null +++ b/assets/objects/object_ganon_anime3/gGanondorfShowTriforceStartAnim.c @@ -0,0 +1,15 @@ +#include "object_ganon_anime3.h" + +#include "ultra64.h" + +s16 gGanondorfShowTriforceStartFrameData[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfShowTriforceStartFrameData.inc.c" +}; + +JointIndex gGanondorfShowTriforceStartJointIndices[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfShowTriforceStartJointIndices.inc.c" +}; + +AnimationHeader gGanondorfShowTriforceStartAnim = { +#include "assets/objects/object_ganon_anime3/gGanondorfShowTriforceStartAnim.inc.c" +}; diff --git a/assets/objects/object_ganon_anime3/gGanondorfTransformEndAnim.c b/assets/objects/object_ganon_anime3/gGanondorfTransformEndAnim.c new file mode 100644 index 0000000000..21a0913e97 --- /dev/null +++ b/assets/objects/object_ganon_anime3/gGanondorfTransformEndAnim.c @@ -0,0 +1,15 @@ +#include "object_ganon_anime3.h" + +#include "ultra64.h" + +s16 gGanondorfTransformEndFrameData[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfTransformEndFrameData.inc.c" +}; + +JointIndex gGanondorfTransformEndJointIndices[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfTransformEndJointIndices.inc.c" +}; + +AnimationHeader gGanondorfTransformEndAnim = { +#include "assets/objects/object_ganon_anime3/gGanondorfTransformEndAnim.inc.c" +}; diff --git a/assets/objects/object_ganon_anime3/gGanondorfTransformLoopAnim.c b/assets/objects/object_ganon_anime3/gGanondorfTransformLoopAnim.c new file mode 100644 index 0000000000..464178153d --- /dev/null +++ b/assets/objects/object_ganon_anime3/gGanondorfTransformLoopAnim.c @@ -0,0 +1,15 @@ +#include "object_ganon_anime3.h" + +#include "ultra64.h" + +s16 gGanondorfTransformLoopFrameData[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfTransformLoopFrameData.inc.c" +}; + +JointIndex gGanondorfTransformLoopJointIndices[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfTransformLoopJointIndices.inc.c" +}; + +AnimationHeader gGanondorfTransformLoopAnim = { +#include "assets/objects/object_ganon_anime3/gGanondorfTransformLoopAnim.inc.c" +}; diff --git a/assets/objects/object_ganon_anime3/gGanondorfTransformStartAnim.c b/assets/objects/object_ganon_anime3/gGanondorfTransformStartAnim.c new file mode 100644 index 0000000000..dc5b31a367 --- /dev/null +++ b/assets/objects/object_ganon_anime3/gGanondorfTransformStartAnim.c @@ -0,0 +1,15 @@ +#include "object_ganon_anime3.h" + +#include "ultra64.h" + +s16 gGanondorfTransformStartFrameData[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfTransformStartFrameData.inc.c" +}; + +JointIndex gGanondorfTransformStartJointIndices[] = { +#include "assets/objects/object_ganon_anime3/gGanondorfTransformStartJointIndices.inc.c" +}; + +AnimationHeader gGanondorfTransformStartAnim = { +#include "assets/objects/object_ganon_anime3/gGanondorfTransformStartAnim.inc.c" +}; diff --git a/assets/objects/object_ganon_anime3/object_ganon_anime3.h b/assets/objects/object_ganon_anime3/object_ganon_anime3.h new file mode 100644 index 0000000000..80fcc0bc56 --- /dev/null +++ b/assets/objects/object_ganon_anime3/object_ganon_anime3.h @@ -0,0 +1,16 @@ +#ifndef OBJECT_GANON_ANIME3_H +#define OBJECT_GANON_ANIME3_H + +#include "animation.h" + +extern AnimationHeader gGanondorfShowTriforceStartAnim; +extern AnimationHeader gGanondorfBurstOutAnim; +extern AnimationHeader gGanondorfTransformEndAnim; +extern AnimationHeader gGanondorfFloatingHeavyBreathingAnim; +extern AnimationHeader gGanondorfTransformStartAnim; +extern AnimationHeader gGanondorfTransformLoopAnim; +extern AnimationHeader gGanondorfShowTriforceLoopAnim; +extern AnimationHeader gGanonUncurlAndFlailAnim; +extern AnimationHeader gGanonRoarAnim; + +#endif diff --git a/spec/spec b/spec/spec index 60437c4bf9..1a3fe91cea 100644 --- a/spec/spec +++ b/spec/spec @@ -3875,7 +3875,15 @@ beginseg name "object_ganon_anime3" compress romalign 0x1000 - include "$(BUILD_DIR)/assets/objects/object_ganon_anime3/object_ganon_anime3.o" + include "$(BUILD_DIR)/assets/objects/object_ganon_anime3/gGanondorfShowTriforceStartAnim.o" + include "$(BUILD_DIR)/assets/objects/object_ganon_anime3/gGanondorfBurstOutAnim.o" + include "$(BUILD_DIR)/assets/objects/object_ganon_anime3/gGanondorfTransformEndAnim.o" + include "$(BUILD_DIR)/assets/objects/object_ganon_anime3/gGanondorfFloatingHeavyBreathingAnim.o" + include "$(BUILD_DIR)/assets/objects/object_ganon_anime3/gGanondorfTransformStartAnim.o" + include "$(BUILD_DIR)/assets/objects/object_ganon_anime3/gGanondorfTransformLoopAnim.o" + include "$(BUILD_DIR)/assets/objects/object_ganon_anime3/gGanondorfShowTriforceLoopAnim.o" + include "$(BUILD_DIR)/assets/objects/object_ganon_anime3/gGanonUncurlAndFlailAnim.o" + include "$(BUILD_DIR)/assets/objects/object_ganon_anime3/gGanonRoarAnim.o" number 6 endseg diff --git a/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c b/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c index 3c19bf8eab..cafa822410 100644 --- a/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c +++ b/src/overlays/actors/ovl_Boss_Ganon2/z_boss_ganon2.c @@ -31,8 +31,8 @@ #include "assets/objects/object_geff/object_geff.h" #include "assets/objects/gameplay_keep/gameplay_keep.h" -#pragma increment_block_number "gc-eu:128 gc-eu-mq:128 gc-jp:128 gc-jp-ce:128 gc-jp-mq:128 gc-us:128 gc-us-mq:128" \ - "ique-cn:128 ntsc-1.0:128 ntsc-1.1:128 ntsc-1.2:128 pal-1.0:128 pal-1.1:128" +#pragma increment_block_number "gc-eu:0 gc-eu-mq:0 gc-jp:0 gc-jp-ce:0 gc-jp-mq:0 gc-us:0 gc-us-mq:0 ique-cn:128" \ + "ntsc-1.0:128 ntsc-1.1:128 ntsc-1.2:128 pal-1.0:128 pal-1.1:128" #define FLAGS \ (ACTOR_FLAG_ATTENTION_ENABLED | ACTOR_FLAG_HOSTILE | ACTOR_FLAG_UPDATE_CULLING_DISABLED | \ diff --git a/tools/assets/extract/write_source.txt b/tools/assets/extract/write_source.txt index 640767216e..161826ca2b 100644 --- a/tools/assets/extract/write_source.txt +++ b/tools/assets/extract/write_source.txt @@ -87,7 +87,6 @@ assets/objects/object_fz/object_fz.c assets/objects/object_ganon2/object_ganon2.c assets/objects/object_ganon_anime1/object_ganon_anime1.c assets/objects/object_ganon_anime2/object_ganon_anime2.c -assets/objects/object_ganon_anime3/object_ganon_anime3.c assets/objects/object_ganon/object_ganon.c assets/objects/object_ganon_objects/object_ganon_objects.c assets/objects/object_ge1/object_ge1.c