diff --git a/src/game/bondhead.c b/src/game/bondhead.c index 40b0cbf48..b80cdec75 100644 --- a/src/game/bondhead.c +++ b/src/game/bondhead.c @@ -143,7 +143,7 @@ void bheadUpdate(f32 arg0, f32 arg1) } { - struct objticksp476 sp80 = {NULL, 1, 3}; + struct modelrenderdata sp80 = {NULL, 1, 3}; Mtxf sp40; struct coord modelpos = {0, 0, 0}; bool somebool = model0001e2a8(); @@ -156,7 +156,7 @@ void bheadUpdate(f32 arg0, f32 arg1) model0001b3bc(&g_Vars.currentplayer->model); mtx4LoadIdentity(&sp40); - sp80.matrix = &sp40; + sp80.unk00 = &sp40; sp80.unk10 = g_Vars.currentplayer->bondheadmatrices; model0001cebc(&sp80, &g_Vars.currentplayer->model); diff --git a/src/game/chr/chr.c b/src/game/chr/chr.c index 758d71c4d..bd3c6dd47 100644 --- a/src/game/chr/chr.c +++ b/src/game/chr/chr.c @@ -6640,7 +6640,7 @@ glabel var7f1a87a8 // && (obj->hidden & OBJHFLAG_00000800) == 0 // && (obj->flags2 & OBJFLAG2_INVISIBLE) == 0) { // Mtxf *sp104 = model0001a5cc(model->attachedtomodel, model->attachedtonode, 0); -// struct objticksp476 thing = {NULL, 1, 3}; +// struct modelrenderdata thing = {NULL, 1, 3}; // u32 stack; // Mtxf sp80; // Mtxf sp40; @@ -7027,7 +7027,7 @@ bool chrTickBeams(struct prop *prop) */ s32 chrTick(struct prop *prop) { - struct objticksp476 sp210 = {0, 1, 3}; + struct modelrenderdata sp210 = {0, 1, 3}; struct chrdata *chr = prop->chr; struct model *model = chr->model; bool onscreen; @@ -7347,7 +7347,7 @@ s32 chrTick(struct prop *prop) mtx4LoadTranslation(&sp190, &sp1a8); mtx4MultMtx4InPlace(currentPlayerGetMatrix1740(), &sp1a8); - sp210.matrix = &sp1a8; + sp210.unk00 = &sp1a8; } else if (prop->type == PROPTYPE_PLAYER) { u8 stack[0x14]; f32 sp130; @@ -7364,12 +7364,12 @@ s32 chrTick(struct prop *prop) mtx4LoadTranslation(&sp17c, &sp1a8); mtx4MultMtx4InPlace(currentPlayerGetMatrix1740(), &sp1a8); - sp210.matrix = &sp1a8; + sp210.unk00 = &sp1a8; } else { - sp210.matrix = currentPlayerGetMatrix1740(); + sp210.unk00 = currentPlayerGetMatrix1740(); } } else { - sp210.matrix = currentPlayerGetMatrix1740(); + sp210.unk00 = currentPlayerGetMatrix1740(); } sp210.unk10 = gfxAllocate(model->filedata->nummatrices * sizeof(Mtxf)); diff --git a/src/game/credits.c b/src/game/credits.c index 3f7a7860e..bd8f7ea4e 100644 --- a/src/game/credits.c +++ b/src/game/credits.c @@ -5213,7 +5213,7 @@ glabel var7f1b5948 /* f13be0c: ad2034a4 */ sw $zero,0x34a4($t1) /* f13be10: 8ce50000 */ lw $a1,0x0($a3) /* f13be14: ac22fc3c */ sw $v0,-0x3c4($at) -/* f13be18: 0fc3d001 */ jal menuRenderHudPiece +/* f13be18: 0fc3d001 */ jal menuRenderModels /* f13be1c: 24a52ef0 */ addiu $a1,$a1,0x2ef0 /* f13be20: 3c0e0102 */ lui $t6,0x102 /* f13be24: 35ce0040 */ ori $t6,$t6,0x40 @@ -5522,7 +5522,7 @@ glabel var7f1b5948 /* f13b2a8: ad2034a4 */ sw $zero,0x34a4($t1) /* f13b2ac: 8ce50000 */ lw $a1,0x0($a3) /* f13b2b0: ac22f6dc */ sw $v0,%lo(var8007f6dc)($at) -/* f13b2b4: 0fc3ce2c */ jal menuRenderHudPiece +/* f13b2b4: 0fc3ce2c */ jal menuRenderModels /* f13b2b8: 24a52ef0 */ addiu $a1,$a1,0x2ef0 /* f13b2bc: 3c0e0102 */ lui $t6,0x102 /* f13b2c0: 35ce0040 */ ori $t6,$t6,0x40 @@ -5831,7 +5831,7 @@ glabel var7f1b5948 /* f135da8: ad2034a4 */ sw $zero,0x34a4($t1) /* f135dac: 8ce50000 */ lw $a1,0x0($a3) /* f135db0: ac221f30 */ sw $v0,0x1f30($at) -/* f135db4: 0fc3c0fd */ jal menuRenderHudPiece +/* f135db4: 0fc3c0fd */ jal menuRenderModels /* f135db8: 24a52ef0 */ addiu $a1,$a1,0x2ef0 /* f135dbc: 3c0e0102 */ lui $t6,0x102 /* f135dc0: 35ce0040 */ ori $t6,$t6,0x40 @@ -6023,7 +6023,7 @@ glabel var7f1b5948 // g_CreditsData->unk34a1 |= 0x02; // g_CreditsData->unk34a4 = 0; // -// gdl = menuRenderHudPiece(gdl, &g_CreditsData->unk2ef0, 4); +// gdl = menuRenderModels(gdl, &g_CreditsData->unk2ef0, 4); // // gSPMatrix(gdl++, osVirtualToPhysical(matrix), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); // @@ -6112,17 +6112,17 @@ void creditsInit(void) creditsInitSlides(); func0f0f8bb4(&g_CreditsData->unk2ef0, 0x25800, 1); - g_CreditsData->unk3470 = 0; + g_CreditsData->unk2ef0.unk580 = 0; func0f0f372c(&g_CreditsData->unk2ef0, 0, 0, 0, 0, 0, 0, 1, 5); - g_CreditsData->unk342c = 90; - g_CreditsData->unk3400 = 8.2; - g_CreditsData->unk3404 = -4.1; - g_CreditsData->unk340c = 0.00393; - g_CreditsData->unk343c = 0; - g_CreditsData->unk3414 = g_CreditsData->unk343c; - g_CreditsData->unk3468 = 60; + g_CreditsData->unk2ef0.unk53c = 90; + g_CreditsData->unk2ef0.unk510 = 8.2; + g_CreditsData->unk2ef0.unk514 = -4.1; + g_CreditsData->unk2ef0.unk51c = 0.00393; + g_CreditsData->unk2ef0.unk54c = 0; + g_CreditsData->unk2ef0.unk524 = g_CreditsData->unk2ef0.unk54c; + g_CreditsData->unk2ef0.unk578 = 60; g_CreditsUsingAltTitle = g_CreditsAltTitleRequested; diff --git a/src/game/endscreen.c b/src/game/endscreen.c index 2a3e51d88..ba198731e 100644 --- a/src/game/endscreen.c +++ b/src/game/endscreen.c @@ -412,16 +412,16 @@ glabel func0f10d730 void func0f10d770(void) { func0f0f8bb4(&g_Menus[0].unk840, bgunCalculateGunMemCapacity() - func0f0e4fe0(), 0); - g_Menus[0].mpconfigbuffer = bgunGetGunMem() + func0f0e4fe0(); + g_Menus[0].unk840.unk004 = bgunGetGunMem() + func0f0e4fe0(); func0f0f8bb4(&g_Menus[1].unk840, bgunCalculateGunMemCapacity() - func0f0e4fe0(), 0); - g_Menus[1].mpconfigbuffer = bgunGetGunMem() + func0f0e4fe0(); + g_Menus[1].unk840.unk004 = bgunGetGunMem() + func0f0e4fe0(); func0f0f8bb4(&g_Menus[2].unk840, bgunCalculateGunMemCapacity() - func0f0e4fe0(), 0); - g_Menus[2].mpconfigbuffer = bgunGetGunMem() + func0f0e4fe0(); + g_Menus[2].unk840.unk004 = bgunGetGunMem() + func0f0e4fe0(); func0f0f8bb4(&g_Menus[3].unk840, bgunCalculateGunMemCapacity() - func0f0e4fe0(), 0); - g_Menus[3].mpconfigbuffer = bgunGetGunMem() + func0f0e4fe0(); + g_Menus[3].unk840.unk004 = bgunGetGunMem() + func0f0e4fe0(); } #if VERSION >= VERSION_NTSC_1_0 diff --git a/src/game/game_0125a0.c b/src/game/game_0125a0.c index 948fb169d..3959fee11 100644 --- a/src/game/game_0125a0.c +++ b/src/game/game_0125a0.c @@ -96,14 +96,14 @@ void currentPlayerInitAnimation(void) } { - struct objticksp476 sp88 = {NULL, 1, 3}; + struct modelrenderdata sp88 = {NULL, 1, 3}; Mtxf sp48; modelSetAnimation(&g_Vars.currentplayer->model, 1, 0, 0, 0.5f, 0); model0001b3bc(&g_Vars.currentplayer->model); mtx4LoadIdentity(&sp48); - sp88.matrix = &sp48; + sp88.unk00 = &sp48; sp88.unk10 = g_Vars.currentplayer->bondheadmatrices; model0001cebc(&sp88, &g_Vars.currentplayer->model); diff --git a/src/game/game_01bea0.c b/src/game/game_01bea0.c index a2539f531..a0c8f08ee 100644 --- a/src/game/game_01bea0.c +++ b/src/game/game_01bea0.c @@ -695,9 +695,9 @@ void menuTick(void) if (g_Vars.currentplayer->gunctrl.gunmemowner == 1 && g_Vars.stagenum != STAGE_CITRAINING) { g_MenuData.unk5d5_01 = true; - if (g_Menus[0].unk844) { + if (g_Menus[0].unk840.unk004) { bgun0f09df50(); - g_Menus[0].unk844 = 0; + g_Menus[0].unk840.unk004 = NULL; } } } diff --git a/src/game/game_0b4950.c b/src/game/game_0b4950.c index d5c70bb05..4108ca3dd 100644 --- a/src/game/game_0b4950.c +++ b/src/game/game_0b4950.c @@ -873,12 +873,12 @@ Mtxf *currentPlayerGetUnk1768(void) return g_Vars.currentplayer->unk1768; } -void currentPlayerSetUnk175c(void *value) +void currentPlayerSetUnk175c(Mtxf *mtx) { - g_Vars.currentplayer->unk175c = value; + g_Vars.currentplayer->unk175c = mtx; } -void *currentPlayerGetUnk175c(void) +Mtxf *currentPlayerGetUnk175c(void) { return g_Vars.currentplayer->unk175c; } diff --git a/src/game/game_0f09f0.c b/src/game/game_0f09f0.c index 3d2bfced4..30b84fdcd 100644 --- a/src/game/game_0f09f0.c +++ b/src/game/game_0f09f0.c @@ -10,6 +10,7 @@ #include "game/game_0b3350.h" #include "game/game_0b4950.h" #include "game/game_0b69d0.h" +#include "game/game_1a7560.h" #include "game/savebuffer.h" #include "game/game_0e0770.h" #include "game/menu/items.h" @@ -27,6 +28,7 @@ #include "game/training/training.h" #include "game/game_1a78b0.h" #include "game/gamefile.h" +#include "game/gfxmemory.h" #include "game/lang.h" #include "game/mplayer/mplayer.h" #include "game/pak/pak.h" @@ -36,6 +38,7 @@ #include "lib/joy.h" #include "lib/vi.h" #include "lib/main.h" +#include "lib/model.h" #include "lib/snd.h" #include "lib/memp.h" #include "lib/rng.h" @@ -65,40 +68,7 @@ s32 g_MenuScissorX1; s32 g_MenuScissorX2; s32 g_MenuScissorY1; s32 g_MenuScissorY2; -u32 var800a2048; -u32 var800a204c; -u32 var800a2050; -u32 var800a2054; -u32 var800a2058; -u32 var800a205c; -u32 var800a2060; -u32 var800a2064; -u32 var800a2068; -u32 var800a206c; -u32 var800a2070; -u32 var800a2074; -u32 var800a2078; -u32 var800a207c; -u32 var800a2080; -u32 var800a2084; -u32 var800a2088; -u32 var800a208c; -u32 var800a2090; -u32 var800a2094; -u32 var800a2098; -u32 var800a209c; -u32 var800a20a0; -u32 var800a20a4; -u32 var800a20a8; -u32 var800a20ac; -u32 var800a20b0; -u32 var800a20b4; -u32 var800a20b8; -u32 var800a20bc; -u32 var800a20c0; -u32 var800a20c4; -u32 var800a20c8; -u32 var800a20cc; +Vp var800a2048[8]; #if VERSION >= VERSION_NTSC_1_0 struct menudialogdef g_PakCannotReadGameBoyMenuDialog; @@ -3216,12 +3186,11 @@ u32 var80073b6cnb[3] = {0}; #endif u32 var800714c0 = 0x0000000a; - u32 var800714c4 = 0x0000012c; #if VERSION >= VERSION_PAL_FINAL GLOBAL_ASM( -glabel menuRenderHudPiece +glabel menuRenderModels .late_rodata glabel var7f1b3c1cpf .word 0x40f33333 @@ -4827,7 +4796,7 @@ glabel var7f1b3c40pf ); #elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( -glabel menuRenderHudPiece +glabel menuRenderModels .late_rodata glabel var7f1b292c .word 0x40f33333 @@ -6436,7 +6405,7 @@ glabel var7f1b2948 ); #else GLOBAL_ASM( -glabel menuRenderHudPiece +glabel menuRenderModels .late_rodata glabel var7f1b292c .word 0x40f33333 @@ -8070,6 +8039,602 @@ glabel var7f1b2948 ); #endif +/** + * Render the hudpiece as well as any models within dialogs. + */ +// Mismatch: Not functionally identical (hudpiece/chrbios/vehicles do not render). +// Revisit when more is known about the menu840 struct. +//Gfx *menuRenderModels(Gfx *gdl, struct menu840 *thing, s32 arg2) +//{ +// f32 sp430; +// f32 sp42c; +// f32 sp428; +// f32 sp424; +// s32 bodyfilelen; // 420 +// s32 sp410; +// s32 bodyfilelen2; // 40c +// u16 bodyfilenum; // 408 +// s32 bodynum; // 404 +// s32 headnum; // 400 +// struct modelrenderdata renderdata; // 3b8 +// Mtxf *sp3b4; +// struct coord sp398; +// f32 sp390[2]; +// Mtxf sp350; +// Mtxf sp310; +// f32 sp30c; +// s32 sp308; +// struct coord sp2fc; +// f32 sp2f8; +// s32 sp2f4; +// f32 sp2d0; +// struct coord sp2bc; +// struct coord sp2ac; +// f32 sp29c; +// struct coord sp290; +// Mtxf sp244; +// Mtxf sp204; +// Mtxf sp1c4; +// Mtxf sp184; +// f32 aspect; // 17c +// f32 sp178; +// s32 sp160; +// Mtxf sp120; +// Mtxf spe0; +// struct coord spd0; +// f32 spc8[2]; +// Mtxf sp70; +// s32 headfilenum; +// s32 i; +// s32 j; +// s32 totalfilelen; +// +// if (g_Vars.stagenum != STAGE_CITRAINING && g_Vars.stagenum != STAGE_CREDITS) { +// if (g_MenuData.unk5d5_01 && arg2 != 1 && arg2 < 3) { +// return gdl; +// } +// +// if (thing->unk004 == NULL) { +// if (bgun0f09e004(1)) { +// thing->unk004 = bgunGetGunMem(); +// thing->unk008 = bgunCalculateGunMemCapacity(); +// } else { +// return gdl; +// } +// } +// } +// +// if (thing->unk004 == NULL) { +// return gdl; +// } +// +// if (thing->unk00c != 0) { +// if (thing->unk010 == thing->unk00c) { +// thing->unk00c = 0; +// thing->unk000 = 0; +// } else { +// if (thing->unk010 == 0x4fac5ace) { +// mpClearCurrentChallenge(); +// } +// +// if (thing->unk000 == 0) { +// thing->unk000 = 1; +// return gdl; +// } +// +// thing->unk000--; +// +// if (thing->unk000 == 0) { +// if ((thing->unk00c & 0xffff) == 0xffff || (thing->unk00c & 0x80000000)) { +// if (thing->unk00c & 0x80000000) { +// headnum = thing->unk00c & 0x3ff; +// bodynum = (thing->unk00c & 0xffc00) >> 10; +// } else { +// s32 mpheadnum = (thing->unk00c >> 16) & 0xff; +// s32 mpbodynum = (thing->unk00c >> 24) & 0xff; +// bodynum = mpGetBodyId(mpbodynum); +// +// if (mpheadnum < mpGetNumHeads2()) { +// headnum = mpGetHeadId(mpheadnum); +// } else { +// headnum = mpGetBeauHeadId(func0f14a9f8(mpheadnum - mpGetNumHeads2())); +// thing->unk5b0 = mpheadnum - mpGetNumHeads2(); +// } +// } +// +// bodyfilenum = g_HeadsAndBodies[bodynum].filenum; +// totalfilelen = ALIGN64(fileGetInflatedLength(g_HeadsAndBodies[bodynum].filenum)); +// +// if (g_HeadsAndBodies[bodynum].unk00_01) { +// headnum = -1; +// headfilenum = 0xffff; +// } else { +// headfilenum = g_HeadsAndBodies[headnum].filenum; +// totalfilelen += ALIGN64(fileGetInflatedLength(headfilenum)); +// } +// +// totalfilelen += 0x4000; +// +// func0f172e70(&sp410, thing->unk004 + totalfilelen, thing->unk008 - totalfilelen); +// +// thing->headnum = headnum; +// thing->bodynum = bodynum; +// thing->bodymodeldef = func0f1a7794(bodyfilenum, thing->unk004, totalfilelen, &sp410); +// bodyfilelen2 = ALIGN64(fileGetSize(bodyfilenum)); +// modelCalculateRwDataLen(thing->bodymodeldef); +// +// if (headnum < 0) { +// thing->headmodeldef = NULL; +// } else { +// thing->headmodeldef = func0f1a7794(headfilenum, thing->unk004 + bodyfilelen2, totalfilelen - bodyfilelen2, &sp410); +// fileGetSize(headfilenum); +// bodyCalculateHeadOffset(thing->headmodeldef, headnum, bodynum); +// modelCalculateRwDataLen(thing->headmodeldef); +// } +// +// modelInit(&thing->bodymodel, thing->bodymodeldef, &thing->unk110, true); +// animInit(&thing->bodyanim); +// +// thing->bodymodel.unk02 = 256; +// thing->bodymodel.anim = &thing->bodyanim; +// +// func0f02ce8c(bodynum, headnum, thing->bodymodeldef, thing->headmodeldef, false, &thing->bodymodel, false, 1); +// } else { +// totalfilelen = ALIGN64(fileGetInflatedLength(thing->unk00c)) + 0x4000; +// +// func0f172e70(&sp410, thing->unk004 + totalfilelen, thing->unk008 - totalfilelen); +// +// thing->headnum = -1; +// thing->bodynum = -1; +// thing->bodymodeldef = func0f1a7794(thing->unk00c, thing->unk004, totalfilelen, &sp410); +// +// fileGetSize(thing->unk00c); +// modelCalculateRwDataLen(thing->bodymodeldef); +// modelInit(&thing->bodymodel, thing->bodymodeldef, &thing->unk110, true); +// animInit(&thing->bodyanim); +// +// thing->bodymodel.unk02 = 256; +// thing->bodymodel.anim = &thing->bodyanim; +// } +// +// thing->unk010 = thing->unk00c; +// thing->unk05e = 0; +// thing->unk00c = 0; +// } else { +// return gdl; +// } +// } +// } +// +// if (thing->bodymodeldef != NULL) { +// struct modelrenderdata sp3b8 = {NULL, false, 3}; +// +// if (arg2 < 3 && g_MenuData.unk5d5_03) { +// gdl = vi0000b280(gdl); +// gdl = vi0000b1d0(gdl); +// +// g_MenuData.unk5d5_03 = false; +// +// if (arg2 != 2) { +// gdl = menuApplyScissor(gdl); +// } +// +// gSPSetGeometryMode(gdl++, G_ZBUFFER); +// } +// +// gSPDisplayList(gdl++, var80061380); +// gSPDisplayList(gdl++, var800613a0); +// +// sp308 = 0; +// +// if (thing->unk554 > 0.0f) { +// sp2f4 = 1; +// +// if (thing->bodymodeldef->skel == &g_SkelChr) { +// struct modelnode *node = modelGetPart(thing->bodymodeldef, MODELPART_CHR_0006); +// +// if (node) { +// struct modelrodata_position *rodata = &node->rodata->position; +// f32 temp_f0 = func0f006bd0(thing->unk574 / 480.0f); +// +// sp2fc.x = 0.0f; +// sp2fc.y = 0.0f - (rodata->pos.y / 7.6f * (1.0f - temp_f0 * temp_f0)); +// sp2fc.z = 0.0f; +// +// thing->unk554 = (1.0f - temp_f0) * 270.0f + 100.0f; +// sp2f4 = 0; +// sp2f8 = thing->unk554 / (rodata->pos.f[1] * 0.5f); +// sp308 = 1; +// +// modelFindBboxRodata(&thing->bodymodel); +// } +// } +// +// if (sp2f4 != 0) { +// struct modelrodata_bbox *bbox = modelFindBboxRodata(&thing->bodymodel); +// +// if (bbox) { +// sp2fc.x = -(bbox->xmax - ((bbox->xmax - bbox->xmin) * 0.5f)); +// sp2fc.y = -(bbox->ymax - ((bbox->ymax - bbox->ymin) * 0.5f)); +// sp2fc.z = -(bbox->zmax - ((bbox->zmax - bbox->zmin) * 0.5f)); +// sp308 = 1; +// sp2f8 = thing->unk554 / ((bbox->ymax - bbox->ymin) * 0.5f); +// } +// } +// } +// +// mtx4LoadIdentity(&sp350); +// +// if (arg2 == 1) { +// if (IS8MB()) { +// s32 i; +// if (thing->unk538 != thing->unk510) { +// for (i = 0; i < g_Vars.diffframe60; i++) { +// thing->unk510 = (thing->unk538 * 0.002f) + (0.998f * thing->unk510); +// } +// } +// +// if (thing->unk53c != thing->unk514) { +// for (i = 0; i < g_Vars.diffframe60; i++) { +// thing->unk514 = (thing->unk53c * 0.002f) + (0.998f * thing->unk514); +// } +// } +// +// if (thing->unk540 != thing->unk518) { +// for (i = 0; i < g_Vars.diffframe60; i++) { +// thing->unk518 = (thing->unk540 * 0.002f) + (0.998f * thing->unk518); +// } +// } +// +// if (thing->unk544 != thing->unk51c) { +// for (i = 0; i < g_Vars.diffframe60; i++) { +// thing->unk51c = (thing->unk544 * 0.002f) + (0.998f * thing->unk51c); +// } +// } +// +// sp430 = thing->unk510; +// +// if (g_ViRes == VIRES_HI) { +// sp430 += sp430; +// } +// +// sp42c = thing->unk514; +// sp428 = thing->unk518; +// sp424 = thing->unk51c; +// +// sp398.x = thing->unk520 = thing->unk548; +// sp398.y = thing->unk524 = thing->unk54c; +// sp398.z = thing->unk528 = thing->unk550; +// +// mtx4LoadRotation(&sp398, &sp350); +// } +// } else { +// if (thing->unk5b1_05) { +// thing->unk564 += g_Vars.diffframe60f / 40.0f; +// +// if (thing->unk564 > 1.0f) { +// thing->unk5b1_05 = false; +// thing->unk510 = thing->unk538; +// thing->unk514 = thing->unk53c; +// thing->unk518 = thing->unk540; +// thing->unk51c = thing->unk544; +// } else { +// f32 sp2d0 = (-cosf(thing->unk564 * M_PI) * 0.5f) + 0.5f; +// f32 f12 = 1.0f - sp2d0; +// +// if (thing->unk568 & 2) { +// sp430 = (thing->unk510 * f12) + (sp2d0 * thing->unk538); +// sp42c = (thing->unk514 * f12) + (sp2d0 * thing->unk53c); +// sp428 = (thing->unk518 * f12) + (sp2d0 * thing->unk540); +// } else { +// sp430 = thing->unk510 = thing->unk538; +// sp42c = thing->unk514 = thing->unk53c; +// sp428 = thing->unk518 = thing->unk540; +// } +// +// if (thing->unk568 & 1) { +// sp424 = (thing->unk51c * f12) + (sp2d0 * thing->unk544); +// } else { +// sp424 = thing->unk51c = thing->unk544; +// } +// +// if (thing->unk568 & 4) { +// sp290.x = thing->unk520; +// sp290.y = thing->unk524; +// sp290.z = thing->unk528; +// +// func0f096ca0(&sp290, &sp2bc); +// +// sp290.x = thing->unk548; +// sp290.y = thing->unk54c; +// sp290.z = thing->unk550; +// +// func0f096ca0(&sp290, &sp2ac); +// func0f0972b8(&sp2bc, &sp2ac, sp2d0, &sp29c); +// func0f096ed4(&sp29c, &sp350); +// } else { +// sp398.x = thing->unk520 = thing->unk548; +// sp398.y = thing->unk524 = thing->unk54c; +// sp398.z = thing->unk528 = thing->unk550; +// +// mtx4LoadRotation(&sp398, &sp350); +// } +// } +// } +// +// if (!thing->unk5b1_05) { +// sp430 = thing->unk510 = thing->unk538; +// sp42c = thing->unk514 = thing->unk53c; +// sp428 = thing->unk518 = thing->unk540; +// sp424 = thing->unk51c = thing->unk544; +// +// thing->unk520 = thing->unk548; +// thing->unk524 = thing->unk54c; +// thing->unk528 = thing->unk550; +// +// sp398.x = thing->unk548; +// sp398.y = thing->unk54c; +// sp398.z = thing->unk550; +// +// mtx4LoadRotation(&sp398, &sp350); +// } +// } +// +// sp30c = -100.0f + sp428; +// +// if (arg2 == 1) { +// if (IS8MB()) { +// sp390[0] = thing->unk510 * g_ScaleX; +// sp390[1] = thing->unk514; +// } +// } else { +// sp390[0] = viGetViewLeft() + g_ScaleX * sp430 + 0.5f * viGetViewWidth(); +// sp390[1] = viGetViewTop() + viGetViewHeight() * 0.5f + sp42c; +// } +// +// func0f0b4c3c(sp390, &sp398, 1.0f); +// mtx4LoadIdentity(&sp310); +// +// if (thing->partvisibility != NULL) { +// struct modelpartvisibility *ptr = thing->partvisibility; +// +// while (ptr->part != 255) { +// struct modelnode *node = modelGetPart(thing->bodymodeldef, ptr->part); +// +// if (node) { +// union modelrwdata *rwdata = modelGetNodeRwData(&thing->bodymodel, node); +// +// if (rwdata) { +// if (ptr->visible) { +// rwdata->toggle.visible = true; +// } else { +// rwdata->toggle.visible = false; +// } +// } +// } +// +// ptr++; +// } +// } +// +// if (arg2 == 3) { +// sp398.x = thing->unk510; +// sp398.y = thing->unk514; +// sp398.z = thing->unk518; +// } else { +// f32 mult = sp30c / sp398.z; +// sp398.x *= mult; +// sp398.y *= mult; +// sp398.z *= mult; +// } +// +//#if VERSION < VERSION_NTSC_1_0 +// if (thing->unk010 < 0) { +// struct coord newpos = {0, 0, 0}; +// struct coord oldpos; +// +// model0001b3bc(&thing->bodymodel); +// +// modelGetRootPosition(&thing->bodymodel, &oldpos); +// +// if (joyGetButtons(0, L_TRIG)) { +// modelSetRootPosition(&thing->bodymodel, &newpos); +// } +// } +//#endif +// +// mtx4LoadTranslation(&sp398, &sp310); +// +// if (sp308) { +// mtx00015f04(sp424 * sp2f8, &sp310); +// } else { +// mtx00015f04(sp424, &sp310); +// } +// +// if (sp308) { +// mtx4LoadTranslation(&sp2fc, &sp204); +// } else { +// sp398.x = thing->unk52c; +// sp398.y = thing->unk530; +// sp398.z = thing->unk534; +// mtx4LoadTranslation(&sp398, &sp204); +// } +// +// mtx4MultMtx4(&sp310, &sp350, &sp244); +// +// if (arg2 == 3) { +// func0f13ae04(&sp1c4); +// mtx4MultMtx4(&sp1c4, &sp244, &sp184); +// mtx4MultMtx4(&sp184, &sp204, &thing->unk014); +// } else { +// mtx4MultMtx4(&sp244, &sp204, &thing->unk014); +// } +// +// gdl = func0f0e2348(gdl); +// +// if (arg2 < 3) { +// if (arg2 != 0) { +// gdl = func0f0d49c8(gdl); +// gSPMatrix(gdl++, osVirtualToPhysical(currentPlayerGetUnk1750()), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_PROJECTION); +// } else { +// static u32 znear = 10; +// static u32 zfar = 300; +// +// aspect = (f32) (g_MenuScissorX2 - g_MenuScissorX1) / (f32) (g_MenuScissorY2 - g_MenuScissorY1); +// +// mainOverrideVariable("mzn", &znear); +// mainOverrideVariable("mzf", &zfar); +// +// gdl = func0f0d49c8(gdl); +// +// viSetViewPosition(g_MenuScissorX1 * g_ScaleX, g_MenuScissorY1); +// viSetFovAspectAndSize(g_Vars.currentplayer->fovy, aspect, (g_MenuScissorX2 - g_MenuScissorX1) * g_ScaleX, g_MenuScissorY2 - g_MenuScissorY1); +// +// gdl = vi0000af00(gdl, &var800a2048[g_MpPlayerNum]); +// gdl = vi0000aca4(gdl, znear, zfar); +// } +// } +// +// sp3b4 = gfxAllocate(thing->bodymodeldef->nummatrices * sizeof(Mtxf)); +// +// for (i = 0; i < thing->bodymodeldef->nummatrices; i++) { +// mtx4LoadIdentity(&sp3b4[i]); +// } +// +// thing->bodymodel.matrices = sp3b4; +// +// if (thing->unk05c && thing->unk05c != thing->unk05e) { +// if (thing->unk5b1_04) { +// modelSetAnimation(&thing->bodymodel, thing->unk05c, false, 0, -0.5f, 0.0f); +// model0001e018(&thing->bodymodel, modelGetNumAnimFrames(&thing->bodymodel)); +// } else { +// modelSetAnimation(&thing->bodymodel, thing->unk05c, false, 0, 0.5f, 0.0f); +// } +// +// thing->unk05e = thing->unk05c; +// } +// +// thing->unk05c = 0; +// +// if (thing->unk05e != 0) { +// model0001ee18(&thing->bodymodel, g_Vars.diffframe240, true); +// +// if (thing->unk5b1_04) { +// sp178 = modelGetNumAnimFrames(&thing->bodymodel) - modelGetCurAnimFrame(&thing->bodymodel); +// } else { +// sp178 = modelGetCurAnimFrame(&thing->bodymodel); +// } +// +// if (sp178 >= modelGetNumAnimFrames(&thing->bodymodel) - 1) { +// thing->unk05e = 0; +// } +// } +// +// mtx4Copy(&thing->unk014, sp3b4); +// +// renderdata.unk00 = &thing->unk014; +// renderdata.unk10 = thing->bodymodel.matrices; +// +// model0001cebc(&renderdata, &thing->bodymodel); +// +// if (thing->bodymodeldef->skel == &g_SkelHudPiece) { +// struct modelnode *node = modelGetPart(thing->bodymodeldef, MODELPART_HUDPIECE_0000); +// +// if (node) { +// struct modelrodata_gundl *rodata = &node->rodata->gundl; +// s32 i; +// +// for (i = 0; i < rodata->unk10; i++) { +// rodata->unk0c[i].unk08 -= g_Vars.diffframe60 * 100; +// +// if (rodata->unk0c[i].unk08 < -0x6000) { +// for (j = 0; j < rodata->unk10; j++) { +// rodata->unk0c[j].unk08 += 0x2000; +// } +// } +// } +// } +// +// node = modelGetPart(thing->bodymodeldef, MODELPART_HUDPIECE_0002); +// +// if (node) { +// sp160 = model0001a524(node, 0); +// mtx4LoadIdentity(&sp120); +// mtx4LoadXRotation(func0f006b54(4), &sp120); +// mtx4MultMtx4(&sp3b4[sp160], &sp120, &spe0); +// mtx4Copy(&spe0, &sp3b4[sp160]); +// } +// +// node = modelGetPart(thing->bodymodeldef, MODELPART_HUDPIECE_0001); +// +// if (node) { +// if (g_MenuData.root == MENUROOT_MAINMENU +// || g_MenuData.root == MENUROOT_FILEMGR +// || g_MenuData.root == MENUROOT_MPSETUP +// || g_MenuData.root == MENUROOT_TRAINING) { +// Mtxf *mtx = &sp3b4[model0001a524(node, 0)]; +// +// spd0.x = mtx->m[3][0]; +// spd0.y = mtx->m[3][1]; +// spd0.z = mtx->m[3][2]; +// +// func0f0b4d04(&spd0, spc8); +// var8009de98 = ((s32)spc8[0] - viGetWidth() / 2) / g_ScaleX; +// var8009de9c = (s32)spc8[1] - viGetHeight() / 2; +// } +// } +// } +// +// gSPNumLights(gdl++, 1); +// gSPLight(gdl++, &var80071470, 1); +// gSPLight(gdl++, &var80071468, 2); +// gSPLookAtX(gdl++, currentPlayerGetUnk175c()->m[0]); +// gSPLookAtY(gdl++, currentPlayerGetUnk175c()->m[1]); +// +// renderdata.unk30 = 1; +// renderdata.envcolour = 0xffffffff; +// renderdata.fogcolour = 0xffffffff; +// +// gSPSetGeometryMode(gdl++, G_ZBUFFER); +// +// renderdata.zbufferenabled = true; +// +// renderdata.gdl = gdl; +// modelRender(&renderdata, &thing->bodymodel); +// gdl = renderdata.gdl; +// +// mtx00016760(); +// +// for (i = 0; i < thing->bodymodeldef->nummatrices; i++) { +// mtx4Copy(&thing->bodymodel.matrices[i], &sp70); +// mtx00016054(&sp70, &thing->bodymodel.matrices[i]); +// } +// +// mtx00016784(); +// +// if (arg2 < 3) { +// gdl = func0f0d479c(gdl); +// } +// +// gDPPipeSync(gdl++); +// gDPSetCycleType(gdl++, G_CYC_1CYCLE); +// gDPSetAlphaCompare(gdl++, G_AC_NONE); +// gDPSetCombineMode(gdl++, G_CC_MODULATEI, G_CC_MODULATEI); +// gSPClearGeometryMode(gdl++, G_CULL_BOTH); +// gDPSetTextureFilter(gdl++, G_TF_BILERP); +// +// func0f0b39c0(&gdl, NULL, 2, 0, 2, 1, NULL); +// +// gDPSetRenderMode(gdl++, G_RM_XLU_SURF, G_RM_XLU_SURF2); +// +// func0f0b39c0(&gdl, NULL, 2, 0, 2, 1, NULL); +// +// gSPDisplayList(gdl++, var800613a0); +// } +// +// return gdl; +//} + GLOBAL_ASM( glabel func0f0f5004 /* f0f5004: 27bdffa0 */ addiu $sp,$sp,-96 @@ -8350,7 +8915,7 @@ glabel dialogRender /* f0f5558: 256c0840 */ addiu $t4,$t3,0x840 /* f0f555c: 018d2821 */ addu $a1,$t4,$t5 /* f0f5560: 8fa401e8 */ lw $a0,0x1e8($sp) -/* f0f5564: 0fc3ce2c */ jal menuRenderHudPiece +/* f0f5564: 0fc3ce2c */ jal menuRenderModels /* f0f5568: 24060002 */ addiu $a2,$zero,0x2 /* f0f556c: 24590008 */ addiu $t9,$v0,0x8 /* f0f5570: afb901e8 */ sw $t9,0x1e8($sp) @@ -9358,7 +9923,7 @@ glabel dialogRender /* f0f6430: 272f0840 */ addiu $t7,$t9,0x840 /* f0f6434: 24840008 */ addiu $a0,$a0,0x8 /* f0f6438: 01ed2821 */ addu $a1,$t7,$t5 -/* f0f643c: 0fc3ce2c */ jal menuRenderHudPiece +/* f0f643c: 0fc3ce2c */ jal menuRenderModels /* f0f6440: 00003025 */ or $a2,$zero,$zero /* f0f6444: 244c0008 */ addiu $t4,$v0,0x8 /* f0f6448: afac01e8 */ sw $t4,0x1e8($sp) @@ -10579,7 +11144,7 @@ glabel dialogRender /* f0f1f3c: 25f8079c */ addiu $t8,$t7,0x79c /* f0f1f40: 03192821 */ addu $a1,$t8,$t9 /* f0f1f44: 8fa401e8 */ lw $a0,0x1e8($sp) -/* f0f1f48: 0fc3c0fd */ jal menuRenderHudPiece +/* f0f1f48: 0fc3c0fd */ jal menuRenderModels /* f0f1f4c: 24060002 */ addiu $a2,$zero,0x2 /* f0f1f50: 244e0008 */ addiu $t6,$v0,0x8 /* f0f1f54: afae01e8 */ sw $t6,0x1e8($sp) @@ -11572,7 +12137,7 @@ glabel dialogRender /* f0f2de4: 25d9079c */ addiu $t9,$t6,0x79c /* f0f2de8: 24840008 */ addiu $a0,$a0,0x8 /* f0f2dec: 03382821 */ addu $a1,$t9,$t8 -/* f0f2df0: 0fc3c0fd */ jal menuRenderHudPiece +/* f0f2df0: 0fc3c0fd */ jal menuRenderModels /* f0f2df4: 00003025 */ or $a2,$zero,$zero /* f0f2df8: 244f0008 */ addiu $t7,$v0,0x8 /* f0f2dfc: afaf01e8 */ sw $t7,0x1e8($sp) @@ -13086,7 +13651,7 @@ void menuPushRootDialog(struct menudialogdef *dialogdef, s32 root) || root == MENUROOT_MPSETUP || root == MENUROOT_TRAINING || root == MENUROOT_FILEMGR) { - if (IS8MB() && (g_MenuData.unk5d4 == 0 || g_MenuData.unk5cd_04)) { + if (IS8MB() && (g_MenuData.unk5d4 == 0 || g_MenuData.unk01c.unk5b1_04)) { if (!g_MenuData.unk5d5_04) { g_MenuData.unk5d5_05 = true; } @@ -13359,10 +13924,10 @@ void menuInit(void) } for (i = 0; i < 4; i++) { - g_Menus[i].unk844 = 0; + g_Menus[i].unk840.unk004 = NULL; } - g_MenuData.unk020 = 0; + g_MenuData.unk01c.unk004 = NULL; if (g_Vars.stagenum == STAGE_CITRAINING) { g_MissionConfig.iscoop = false; @@ -13389,17 +13954,17 @@ void menuInit(void) func0f0f8bb4(&g_MenuData.unk01c, 0xc800, 1); } - g_MenuData.unk028 = 0x259; - g_MenuData.unk540 = g_MenuData.unk568 = -M_PI; - g_MenuData.unk53c = g_MenuData.unk564 = 0; - g_MenuData.unk544 = g_MenuData.unk56c = 0; - g_MenuData.unk52c = g_MenuData.hudpiecex = -205.5f; - g_MenuData.unk530 = g_MenuData.hudpiecey = 244.7f; - g_MenuData.unk534 = g_MenuData.unk55c = 68.3f; - g_MenuData.unk538 = g_MenuData.unk560 = 0.12209f; - g_MenuData.unk5cd_01 = false; - g_MenuData.unk590 = 0; - g_MenuData.unk59c = 0; + g_MenuData.unk01c.unk00c = 0x259; + g_MenuData.unk01c.unk524 = g_MenuData.unk01c.unk54c = -M_PI; + g_MenuData.unk01c.unk520 = g_MenuData.unk01c.unk548 = 0; + g_MenuData.unk01c.unk528 = g_MenuData.unk01c.unk550 = 0; + g_MenuData.unk01c.unk510 = g_MenuData.unk01c.unk538 = -205.5f; + g_MenuData.unk01c.unk514 = g_MenuData.unk01c.unk53c = 244.7f; + g_MenuData.unk01c.unk518 = g_MenuData.unk01c.unk540 = 68.3f; + g_MenuData.unk01c.unk51c = g_MenuData.unk01c.unk544 = 0.12209f; + g_MenuData.unk01c.unk5b1_01 = false; + g_MenuData.unk01c.unk574 = 0; + g_MenuData.unk01c.unk580 = 0; } g_MenuData.unk5d4 = 0; @@ -17891,10 +18456,10 @@ Gfx *menuRender(Gfx *gdl) // Calculate hudpiece things then render it if (g_MenuData.unk5d5_05) { - g_MenuData.unk07a = 0; - g_MenuData.unk078 = 0x40d; - g_MenuData.unk59c = 0; - g_MenuData.unk5cd_04 = false; + g_MenuData.unk01c.unk05e = 0; + g_MenuData.unk01c.unk05c = 0x40d; + g_MenuData.unk01c.unk580 = 0; + g_MenuData.unk01c.unk5b1_04 = false; g_MenuData.unk5d4 = 1; g_MenuData.unk5d5_05 = false; } @@ -17907,8 +18472,8 @@ Gfx *menuRender(Gfx *gdl) // Everyone 1 in 100 frames on average, calculate a new X/Y for the hudpiece // Note: unintentional 64-bit float comparison done here if (random() * (1.0f / U32_MAX) < 0.01) { - g_MenuData.hudpiecex = random() * (1.0f / U32_MAX) * 80.0f + -205.5f - 40.0f; - g_MenuData.hudpiecey = random() * (1.0f / U32_MAX) * 80.0f + 244.7f - 40.0f; + g_MenuData.unk01c.unk538 = random() * (1.0f / U32_MAX) * 80.0f + -205.5f - 40.0f; + g_MenuData.unk01c.unk53c = random() * (1.0f / U32_MAX) * 80.0f + 244.7f - 40.0f; } var8009de98 = var8009de9c = 0; @@ -17939,13 +18504,13 @@ Gfx *menuRender(Gfx *gdl) } if (removepiece) { - if (g_MenuData.unk59c == 0) { - g_MenuData.unk5cd_04 = true; - g_MenuData.unk07a = 0; - g_MenuData.unk078 = 0x40d; - g_MenuData.unk59c = 1; - } else if (g_MenuData.unk07a == 0) { - g_MenuData.unk59c = 0; + if (g_MenuData.unk01c.unk580 == 0) { + g_MenuData.unk01c.unk5b1_04 = true; + g_MenuData.unk01c.unk05e = 0; + g_MenuData.unk01c.unk05c = 0x40d; + g_MenuData.unk01c.unk580 = 1; + } else if (g_MenuData.unk01c.unk05e == 0) { + g_MenuData.unk01c.unk580 = 0; g_MenuData.unk5d4 = 0; } } @@ -17955,7 +18520,7 @@ Gfx *menuRender(Gfx *gdl) if (usepiece) { g_MenuData.unk5d5_03 = false; - gdl = menuRenderHudPiece(gdl, &g_MenuData.unk01c, 1); + gdl = menuRenderModels(gdl, &g_MenuData.unk01c, 1); gSPClearGeometryMode(gdl++, G_ZBUFFER); g_MenuData.unk5d5_03 = true; diff --git a/src/game/mainmenu.c b/src/game/mainmenu.c index 8bb6137ce..214545f7a 100644 --- a/src/game/mainmenu.c +++ b/src/game/mainmenu.c @@ -798,11 +798,11 @@ s32 menudialog00103608(s32 operation, struct menudialogdef *dialogdef, union han { switch (operation) { case MENUOP_OPEN: - g_Menus[g_MpPlayerNum].unk850 = 0; + g_Menus[g_MpPlayerNum].unk840.unk010 = 0; func0f00e980(g_MissionConfig.stagenum, - g_Menus[g_MpPlayerNum].unk844, - g_Menus[g_MpPlayerNum].unk848, &g_Briefing); + g_Menus[g_MpPlayerNum].unk840.unk004, + g_Menus[g_MpPlayerNum].unk840.unk008, &g_Briefing); break; case MENUOP_CLOSE: langClearBank(g_Briefing.langbank); @@ -4836,52 +4836,51 @@ void func0f105948(s32 weaponnum) if (weaponHasFlag(weaponnum, WEAPONFLAG_HIDEMENUMODEL) == false && (u32)wantindex >= 0 && useindex >= 0) { weapon = weaponFindById(weaponnum); - g_Menus[g_MpPlayerNum].unk840 = 8; - g_Menus[g_MpPlayerNum].unk850 = 0; - - g_Menus[g_MpPlayerNum].unk84c = weaponGetModelNum(weaponnum); - g_Menus[g_MpPlayerNum].unkd78 = 0; - g_Menus[g_MpPlayerNum].unkd50 = 0; - g_Menus[g_MpPlayerNum].unkd7c = 0; - g_Menus[g_MpPlayerNum].unkd54 = 0; - g_Menus[g_MpPlayerNum].unkd80 = 0; - g_Menus[g_MpPlayerNum].unkd58 = 0; - g_Menus[g_MpPlayerNum].unkd90 = 0; - g_Menus[g_MpPlayerNum].unkd68 = 0; - g_Menus[g_MpPlayerNum].unkd6c = gunconfig[useindex][0]; - g_Menus[g_MpPlayerNum].unkd70 = gunconfig[useindex][1]; - g_Menus[g_MpPlayerNum].unkd74 = gunconfig[useindex][2]; - g_Menus[g_MpPlayerNum].unkd88 = gunconfig[useindex][3]; - g_Menus[g_MpPlayerNum].unkd60 = gunconfig[useindex][3]; // @bug? Wrong index? + g_Menus[g_MpPlayerNum].unk840.unk000 = 8; + g_Menus[g_MpPlayerNum].unk840.unk010 = 0; + g_Menus[g_MpPlayerNum].unk840.unk00c = weaponGetModelNum(weaponnum); + g_Menus[g_MpPlayerNum].unk840.unk538 = 0; + g_Menus[g_MpPlayerNum].unk840.unk510 = 0; + g_Menus[g_MpPlayerNum].unk840.unk53c = 0; + g_Menus[g_MpPlayerNum].unk840.unk514 = 0; + g_Menus[g_MpPlayerNum].unk840.unk540 = 0; + g_Menus[g_MpPlayerNum].unk840.unk518 = 0; + g_Menus[g_MpPlayerNum].unk840.unk550 = 0; + g_Menus[g_MpPlayerNum].unk840.unk528 = 0; + g_Menus[g_MpPlayerNum].unk840.unk52c = gunconfig[useindex][0]; + g_Menus[g_MpPlayerNum].unk840.unk530 = gunconfig[useindex][1]; + g_Menus[g_MpPlayerNum].unk840.unk534 = gunconfig[useindex][2]; + g_Menus[g_MpPlayerNum].unk840.unk548 = gunconfig[useindex][3]; + g_Menus[g_MpPlayerNum].unk840.unk520 = gunconfig[useindex][3]; // @bug? Wrong index? func0f0f372c(&g_Menus[g_MpPlayerNum].unk840, 0, 0, 0, 0, 0, 0, gunconfig[useindex][4], 1); - g_Menus[g_MpPlayerNum].unkd5c = 0; - g_Menus[g_MpPlayerNum].partvisibility = weapon->partvisibility; - g_Menus[g_MpPlayerNum].unkd94 = -1; + g_Menus[g_MpPlayerNum].unk840.unk51c = 0; + g_Menus[g_MpPlayerNum].unk840.partvisibility = weapon->partvisibility; + g_Menus[g_MpPlayerNum].unk840.unk554 = -1; // These indexes correspond to WEAPON_DISGUISE40 and WEAPON_DISGUISE41 if (wantindex == 0x3e || wantindex == 0x3f) { if ((u32)wantindex == 0x3e) { - g_Menus[g_MpPlayerNum].unk84c = 0x0a01ffff; + g_Menus[g_MpPlayerNum].unk840.unk00c = 0x0a01ffff; } else { - g_Menus[g_MpPlayerNum].unk84c = 0x0400ffff; + g_Menus[g_MpPlayerNum].unk840.unk00c = 0x0400ffff; } - g_Menus[g_MpPlayerNum].partvisibility = NULL; - g_Menus[g_MpPlayerNum].unkdc0 = 0; + g_Menus[g_MpPlayerNum].unk840.partvisibility = NULL; + g_Menus[g_MpPlayerNum].unk840.unk580 = 0; func0f0f372c(&g_Menus[g_MpPlayerNum].unk840, 0, 0, 0, 0, 0, 0, 1, 1); - g_Menus[g_MpPlayerNum].unkdb8 = PALDOWN(60); - g_Menus[g_MpPlayerNum].unkdb4 = PALDOWN(120); - g_Menus[g_MpPlayerNum].unkd8c = -0.2f; - g_Menus[g_MpPlayerNum].unkd64 = -0.2f; + g_Menus[g_MpPlayerNum].unk840.unk578 = PALDOWN(60); + g_Menus[g_MpPlayerNum].unk840.unk574 = PALDOWN(120); + g_Menus[g_MpPlayerNum].unk840.unk54c = -0.2f; + g_Menus[g_MpPlayerNum].unk840.unk524 = -0.2f; } } else { - g_Menus[g_MpPlayerNum].unk894 = 0; - g_Menus[g_MpPlayerNum].unk850 = 0; - g_Menus[g_MpPlayerNum].unk84c = 0; + g_Menus[g_MpPlayerNum].unk840.bodymodeldef = NULL; + g_Menus[g_MpPlayerNum].unk840.unk010 = 0; + g_Menus[g_MpPlayerNum].unk840.unk00c = 0; } } @@ -4889,11 +4888,11 @@ s32 inventoryMenuDialog(s32 operation, struct menudialogdef *dialogdef, union ha { if (operation == MENUOP_TICK) { if (g_Menus[g_MpPlayerNum].curdialog && g_Menus[g_MpPlayerNum].curdialog->definition == dialogdef) { - g_Menus[g_MpPlayerNum].unkdb4 -= g_Vars.diffframe60; - g_Menus[g_MpPlayerNum].unkd8c = 18.849555969238f * var80061630; - g_Menus[g_MpPlayerNum].unkd64 = 18.849555969238f * var80061630; - g_Menus[g_MpPlayerNum].unkd68 = 0; - g_Menus[g_MpPlayerNum].unkd90 = 0; + g_Menus[g_MpPlayerNum].unk840.unk574 -= g_Vars.diffframe60; + g_Menus[g_MpPlayerNum].unk840.unk54c = 18.849555969238f * var80061630; + g_Menus[g_MpPlayerNum].unk840.unk524 = 18.849555969238f * var80061630; + g_Menus[g_MpPlayerNum].unk840.unk528 = 0; + g_Menus[g_MpPlayerNum].unk840.unk550 = 0; if (var80072d88 != g_InventoryWeapon) { func0f105948(g_InventoryWeapon); @@ -4901,9 +4900,9 @@ s32 inventoryMenuDialog(s32 operation, struct menudialogdef *dialogdef, union ha } if (g_InventoryWeapon == WEAPON_DISGUISE40 || g_InventoryWeapon == WEAPON_DISGUISE41) { - g_Menus[g_MpPlayerNum].unk89c = 0x6a; - g_Menus[g_MpPlayerNum].unkdb8 = PALDOWN(60); - g_Menus[g_MpPlayerNum].unkdb4 = PALDOWN(120); + g_Menus[g_MpPlayerNum].unk840.unk05c = ANIM_006A; + g_Menus[g_MpPlayerNum].unk840.unk578 = PALDOWN(60); + g_Menus[g_MpPlayerNum].unk840.unk574 = PALDOWN(120); } } else { var80072d88 = 255; diff --git a/src/game/menu/items.c b/src/game/menu/items.c index 042ba95b8..3df115e4f 100644 --- a/src/game/menu/items.c +++ b/src/game/menu/items.c @@ -8875,8 +8875,8 @@ char *menuitemScrollableGetText(u32 type) return mpconfigGetDescription(g_Menus[g_MpPlayerNum].training.mpconfig); case DESCRIPTION_MPCHALLENGE: if (!mpIsChallengeLoaded()) { - g_Menus[g_MpPlayerNum].unk850 = 0x4fac5ace; - mpLoadAndStoreCurrentChallenge(g_Menus[g_MpPlayerNum].mpconfigbuffer, g_Menus[g_MpPlayerNum].mpconfigbufferlen); + g_Menus[g_MpPlayerNum].unk840.unk010 = 0x4fac5ace; + mpLoadAndStoreCurrentChallenge(g_Menus[g_MpPlayerNum].unk840.unk004, g_Menus[g_MpPlayerNum].unk840.unk008); } return mpGetCurrentChallengeDescription(); case DESCRIPTION_CHRBIO: return ciGetChrBioDescription(); diff --git a/src/game/mplayer/setup.c b/src/game/mplayer/setup.c index 8e69dfb99..d68a3baab 100644 --- a/src/game/mplayer/setup.c +++ b/src/game/mplayer/setup.c @@ -534,28 +534,28 @@ s32 mpCharacterBodyMenuHandler(s32 operation, struct menuitem *item, union handl data->carousel.value = mpGetNumBodies(); break; case MENUOP_11: - g_Menus[g_MpPlayerNum].unk89c = 0x1fc; - g_Menus[g_MpPlayerNum].unk84c = mpbodynum << 16 | 0xffff | mpheadnum << 24; - g_Menus[g_MpPlayerNum].unkdb4 += g_Vars.diffframe60; + g_Menus[g_MpPlayerNum].unk840.unk05c = 0x1fc; + g_Menus[g_MpPlayerNum].unk840.unk00c = mpbodynum << 16 | 0xffff | mpheadnum << 24; + g_Menus[g_MpPlayerNum].unk840.unk574 += g_Vars.diffframe60; - if (g_Menus[g_MpPlayerNum].unkdb4 > PALDOWN(480)) { - g_Menus[g_MpPlayerNum].unkdb4 -= PALDOWN(480); + if (g_Menus[g_MpPlayerNum].unk840.unk574 > PALDOWN(480)) { + g_Menus[g_MpPlayerNum].unk840.unk574 -= PALDOWN(480); } - if (g_Menus[g_MpPlayerNum].unkdb8 > 0) { - g_Menus[g_MpPlayerNum].unkdb8 -= g_Vars.diffframe60; + if (g_Menus[g_MpPlayerNum].unk840.unk578 > 0) { + g_Menus[g_MpPlayerNum].unk840.unk578 -= g_Vars.diffframe60; } else { #if VERSION >= VERSION_PAL_FINAL - f32 value = g_Menus[g_MpPlayerNum].unkd64 + 0.01f * g_Vars.diffframe60freal; + f32 value = g_Menus[g_MpPlayerNum].unk840.unk524 + 0.01f * g_Vars.diffframe60freal; #else - f32 value = g_Menus[g_MpPlayerNum].unkd64 + 0.01f * g_Vars.diffframe60f; + f32 value = g_Menus[g_MpPlayerNum].unk840.unk524 + 0.01f * g_Vars.diffframe60f; #endif - g_Menus[g_MpPlayerNum].unkd8c = value; - g_Menus[g_MpPlayerNum].unkd64 = value; + g_Menus[g_MpPlayerNum].unk840.unk54c = value; + g_Menus[g_MpPlayerNum].unk840.unk524 = value; } - g_Menus[g_MpPlayerNum].partvisibility = NULL; - g_Menus[g_MpPlayerNum].unkd94 = 30; + g_Menus[g_MpPlayerNum].unk840.partvisibility = NULL; + g_Menus[g_MpPlayerNum].unk840.unk554 = 30; break; case MENUOP_21: if (!mpIsFeatureUnlocked(mpGetBodyRequiredFeature(data->carousel.value))) { @@ -564,7 +564,7 @@ s32 mpCharacterBodyMenuHandler(s32 operation, struct menuitem *item, union handl break; #if VERSION >= VERSION_NTSC_1_0 case MENUOP_FOCUS: - g_Menus[g_MpPlayerNum].unk840 = 3; + g_Menus[g_MpPlayerNum].unk840.unk000 = 3; break; #endif case MENUOP_GETOPTIONVALUE: @@ -572,26 +572,26 @@ s32 mpCharacterBodyMenuHandler(s32 operation, struct menuitem *item, union handl break; case MENUOP_SET: case MENUOP_CHECKPREFOCUSED: - g_Menus[g_MpPlayerNum].unkdc0 = 0; + g_Menus[g_MpPlayerNum].unk840.unk580 = 0; func0f0f372c(&g_Menus[g_MpPlayerNum].unk840, 0, 0, 0, 0, 0, 0, 1, 1); - g_Menus[g_MpPlayerNum].unkd50 = 8.2f; - g_Menus[g_MpPlayerNum].unkd54 = -4.1f; - g_Menus[g_MpPlayerNum].unkd7c = -4.1f; + g_Menus[g_MpPlayerNum].unk840.unk510 = 8.2f; + g_Menus[g_MpPlayerNum].unk840.unk514 = -4.1f; + g_Menus[g_MpPlayerNum].unk840.unk53c = -4.1f; - g_Menus[g_MpPlayerNum].unkd78 = 8.2f; - g_Menus[g_MpPlayerNum].unkd5c = 0.002f; - g_Menus[g_MpPlayerNum].unkd64 = -0.2f; - g_Menus[g_MpPlayerNum].unkd8c = -0.2f; + g_Menus[g_MpPlayerNum].unk840.unk538 = 8.2f; + g_Menus[g_MpPlayerNum].unk840.unk51c = 0.002f; + g_Menus[g_MpPlayerNum].unk840.unk524 = -0.2f; + g_Menus[g_MpPlayerNum].unk840.unk54c = -0.2f; - g_Menus[g_MpPlayerNum].unkdb8 = PALDOWN(60); - g_Menus[g_MpPlayerNum].unkdb4 = PALDOWN(120); - g_Menus[g_MpPlayerNum].unk840 = 8; + g_Menus[g_MpPlayerNum].unk840.unk578 = PALDOWN(60); + g_Menus[g_MpPlayerNum].unk840.unk574 = PALDOWN(120); + g_Menus[g_MpPlayerNum].unk840.unk000 = 8; #if VERSION >= VERSION_NTSC_1_0 if (operation == MENUOP_CHECKPREFOCUSED) { - g_Menus[g_MpPlayerNum].unk840 = 16; + g_Menus[g_MpPlayerNum].unk840.unk000 = 16; } #endif @@ -1272,30 +1272,30 @@ s32 mpCharacterHeadMenuHandler(s32 operation, struct menuitem *item, union handl break; case MENUOP_11: #if VERSION >= VERSION_PAL_FINAL - diffframe = g_Menus[g_MpPlayerNum].unkd64 + 0.01f * g_Vars.diffframe60freal; + diffframe = g_Menus[g_MpPlayerNum].unk840.unk524 + 0.01f * g_Vars.diffframe60freal; #else - diffframe = g_Menus[g_MpPlayerNum].unkd64 + 0.01f * g_Vars.diffframe60f; + diffframe = g_Menus[g_MpPlayerNum].unk840.unk524 + 0.01f * g_Vars.diffframe60f; #endif - g_Menus[g_MpPlayerNum].unkd8c = diffframe; - g_Menus[g_MpPlayerNum].unkd64 = diffframe; + g_Menus[g_MpPlayerNum].unk840.unk54c = diffframe; + g_Menus[g_MpPlayerNum].unk840.unk524 = diffframe; if (mpheadnum < mpGetNumHeads2()) { headnum = mpGetHeadId(mpheadnum); - g_Menus[g_MpPlayerNum].unk84c = g_HeadsAndBodies[headnum].filenum; - g_Menus[g_MpPlayerNum].unkdf1 = false; + g_Menus[g_MpPlayerNum].unk840.unk00c = g_HeadsAndBodies[headnum].filenum; + g_Menus[g_MpPlayerNum].unk840.unk5b1_01 = false; } else { headnum = mpGetBeauHeadId(func0f14a9f8(mpheadnum - mpGetNumHeads2())); - g_Menus[g_MpPlayerNum].unk84c = g_HeadsAndBodies[headnum].filenum; - g_Menus[g_MpPlayerNum].unkdf1 = true; - g_Menus[g_MpPlayerNum].unkdf0 = mpheadnum - mpGetNumHeads2(); + g_Menus[g_MpPlayerNum].unk840.unk00c = g_HeadsAndBodies[headnum].filenum; + g_Menus[g_MpPlayerNum].unk840.unk5b1_01 = true; + g_Menus[g_MpPlayerNum].unk840.unk5b0 = mpheadnum - mpGetNumHeads2(); } - g_Menus[g_MpPlayerNum].unkdb4 = 0; - g_Menus[g_MpPlayerNum].partvisibility = visibility; - g_Menus[g_MpPlayerNum].unkd94 = 30; + g_Menus[g_MpPlayerNum].unk840.unk574 = 0; + g_Menus[g_MpPlayerNum].unk840.partvisibility = visibility; + g_Menus[g_MpPlayerNum].unk840.unk554 = 30; break; case MENUOP_21: if (!mpIsFeatureUnlocked(mpGetHeadRequiredFeature(data->carousel.value))) { @@ -1308,24 +1308,22 @@ s32 mpCharacterHeadMenuHandler(s32 operation, struct menuitem *item, union handl case MENUOP_SET: case MENUOP_FOCUS: #if VERSION >= VERSION_NTSC_1_0 - g_Menus[g_MpPlayerNum].unk840 = 3; + g_Menus[g_MpPlayerNum].unk840.unk000 = 3; #endif mpGetNumHeads2(); func0f0f372c(&g_Menus[g_MpPlayerNum].unk840, 0, 0, 0, 0, 0, 0, 1, 1); - g_Menus[g_MpPlayerNum].unkd50 = 0; - g_Menus[g_MpPlayerNum].unkd54 = 0; - g_Menus[g_MpPlayerNum].unkd7c = -3; - - g_Menus[g_MpPlayerNum].unkd78 = 0; - g_Menus[g_MpPlayerNum].unkd5c = 0.01f; - g_Menus[g_MpPlayerNum].unkd64 = -0.3f; - g_Menus[g_MpPlayerNum].unkd8c = -0.3f; - - g_Menus[g_MpPlayerNum].unkd84 = 1; - g_Menus[g_MpPlayerNum].unkd94 = 30; + g_Menus[g_MpPlayerNum].unk840.unk510 = 0; + g_Menus[g_MpPlayerNum].unk840.unk514 = 0; + g_Menus[g_MpPlayerNum].unk840.unk53c = -3; + g_Menus[g_MpPlayerNum].unk840.unk538 = 0; + g_Menus[g_MpPlayerNum].unk840.unk51c = 0.01f; + g_Menus[g_MpPlayerNum].unk840.unk524 = -0.3f; + g_Menus[g_MpPlayerNum].unk840.unk54c = -0.3f; + g_Menus[g_MpPlayerNum].unk840.unk544 = 1; + g_Menus[g_MpPlayerNum].unk840.unk554 = 30; break; } @@ -3005,12 +3003,12 @@ s32 menudialog0017e3fc(s32 operation, struct menudialogdef *dialogdef, union han { switch (operation) { case MENUOP_OPEN: - g_Menus[g_MpPlayerNum].unk850 = 0; + g_Menus[g_MpPlayerNum].unk840.unk010 = 0; g_Menus[g_MpPlayerNum].training.mpconfig = mpGetNthAvailableChallengeSomething( g_Menus[g_MpPlayerNum].training.unke1c, - g_Menus[g_MpPlayerNum].mpconfigbuffer, - g_Menus[g_MpPlayerNum].mpconfigbufferlen); + g_Menus[g_MpPlayerNum].unk840.unk004, + g_Menus[g_MpPlayerNum].unk840.unk008); break; case MENUOP_CLOSE: break; @@ -3351,16 +3349,16 @@ s32 mpCombatChallengesMenuDialog(s32 operation, struct menudialogdef *dialogdef, && g_Menus[g_MpPlayerNum].curdialog && g_Menus[g_MpPlayerNum].curdialog->definition == dialogdef && !mpIsChallengeLoaded()) { - g_Menus[g_MpPlayerNum].unk850 = 0x4fac5ace; + g_Menus[g_MpPlayerNum].unk840.unk010 = 0x4fac5ace; mpLoadAndStoreCurrentChallenge( - g_Menus[g_MpPlayerNum].mpconfigbuffer, - g_Menus[g_MpPlayerNum].mpconfigbufferlen); + g_Menus[g_MpPlayerNum].unk840.unk004, + g_Menus[g_MpPlayerNum].unk840.unk008); } } if (operation == MENUOP_CLOSE) { - if (g_Menus[g_MpPlayerNum].unk850 == 0x4fac5ace) { + if (g_Menus[g_MpPlayerNum].unk840.unk010 == 0x4fac5ace) { mpClearCurrentChallenge(); } } diff --git a/src/game/propobj.c b/src/game/propobj.c index 2b1d19571..04f50d23a 100644 --- a/src/game/propobj.c +++ b/src/game/propobj.c @@ -49470,14 +49470,14 @@ void objInitMatrices(struct prop *prop) hangingmonitorInitMatrices(prop); } else { if (obj->model->filedata->nummatrices >= 2) { - struct objticksp476 thing = {NULL, 1, 3}; + struct modelrenderdata thing = {NULL, 1, 3}; u32 stack; Mtxf sp28; mtx4Copy(obj->model->matrices, &sp28); thing.unk10 = obj->model->matrices; - thing.matrix = &sp28; + thing.unk00 = &sp28; model0001ce64(&thing, obj->model); } @@ -49672,7 +49672,7 @@ s32 objTick(struct prop *prop) model->anim = NULL; } else { // In cutscene - struct objticksp476 sp476 = {0, 1, 3}; + struct modelrenderdata sp476 = {0, 1, 3}; Mtxf sp412; struct coord sp400; s16 sp384[8]; @@ -49700,7 +49700,7 @@ s32 objTick(struct prop *prop) sp556 = true; sp476.unk10 = gfxAllocate(model->filedata->nummatrices * sizeof(Mtxf)); - sp476.matrix = currentPlayerGetMatrix1740(); + sp476.unk00 = currentPlayerGetMatrix1740(); model0001cebc(&sp476, model); if (fulltick) { @@ -49758,7 +49758,7 @@ s32 objTick(struct prop *prop) } } } else { - struct objticksp476 sp312 = {0, 1, 3}; + struct modelrenderdata sp312 = {0, 1, 3}; Mtxf sp248; struct coord sp236; s16 sp220[8]; @@ -49798,7 +49798,7 @@ s32 objTick(struct prop *prop) sp556 = true; sp312.unk10 = gfxAllocate(model->filedata->nummatrices * sizeof(Mtxf)); - sp312.matrix = &sp152; + sp312.unk00 = &sp152; model0001cebc(&sp312, model); if (fulltick) { diff --git a/src/game/training/menus.c b/src/game/training/menus.c index 1eaa2e96a..15905f5f5 100644 --- a/src/game/training/menus.c +++ b/src/game/training/menus.c @@ -224,11 +224,11 @@ s32 frTrainingInfoMenuDialog(s32 operation, struct menudialogdef *dialogdef, uni break; case MENUOP_TICK: if (g_Menus[g_MpPlayerNum].curdialog && g_Menus[g_MpPlayerNum].curdialog->definition == dialogdef) { - g_Menus[g_MpPlayerNum].unkdb4 -= g_Vars.diffframe60; - g_Menus[g_MpPlayerNum].unkd8c = 18.849555969238f * var80061630; - g_Menus[g_MpPlayerNum].unkd64 = 18.849555969238f * var80061630; - g_Menus[g_MpPlayerNum].unkd68 = 0; - g_Menus[g_MpPlayerNum].unkd90 = 0; + g_Menus[g_MpPlayerNum].unk840.unk574 -= g_Vars.diffframe60; + g_Menus[g_MpPlayerNum].unk840.unk54c = 18.849555969238f * var80061630; + g_Menus[g_MpPlayerNum].unk840.unk524 = 18.849555969238f * var80061630; + g_Menus[g_MpPlayerNum].unk840.unk528 = 0; + g_Menus[g_MpPlayerNum].unk840.unk550 = 0; } break; case MENUOP_CLOSE: @@ -1102,14 +1102,14 @@ s32 ciCharacterProfileMenuDialog(s32 operation, struct menudialogdef *dialogdef, case MENUOP_OPEN: if (bodynum == BODY_DRCAROLL) { scale = 0.7f; - g_Menus[g_MpPlayerNum].unkd94 = -1; + g_Menus[g_MpPlayerNum].unk840.unk554 = -1; } else { - g_Menus[g_MpPlayerNum].unkd94 = 30; + g_Menus[g_MpPlayerNum].unk840.unk554 = 30; scale = 1.0f; } - g_Menus[g_MpPlayerNum].unkdb4 = PALDOWN(120); - g_Menus[g_MpPlayerNum].unkdc0 = 0; + g_Menus[g_MpPlayerNum].unk840.unk574 = PALDOWN(120); + g_Menus[g_MpPlayerNum].unk840.unk580 = 0; #if VERSION >= VERSION_PAL_FINAL if (g_ViRes != VIRES_HI) { @@ -1145,12 +1145,12 @@ s32 ciCharacterProfileMenuDialog(s32 operation, struct menudialogdef *dialogdef, func0f0f372c(&g_Menus[g_MpPlayerNum].unk840, x, y, 0, 0, 0, 0, scale, 7); - g_Menus[g_MpPlayerNum].unkd50 = 8.2f; - g_Menus[g_MpPlayerNum].unkd54 = -4.1f; - g_Menus[g_MpPlayerNum].unkd5c = 0.00393f; - g_Menus[g_MpPlayerNum].unkd64 = 0; - g_Menus[g_MpPlayerNum].unkd8c = 0; - g_Menus[g_MpPlayerNum].unkdb8 = PALDOWN(60); + g_Menus[g_MpPlayerNum].unk840.unk510 = 8.2f; + g_Menus[g_MpPlayerNum].unk840.unk514 = -4.1f; + g_Menus[g_MpPlayerNum].unk840.unk51c = 0.00393f; + g_Menus[g_MpPlayerNum].unk840.unk524 = 0; + g_Menus[g_MpPlayerNum].unk840.unk54c = 0; + g_Menus[g_MpPlayerNum].unk840.unk578 = PALDOWN(60); break; case MENUOP_CLOSE: break; @@ -1170,10 +1170,10 @@ s32 ciCharacterProfileMenuDialog(s32 operation, struct menudialogdef *dialogdef, { 255 }, }; - g_Menus[g_MpPlayerNum].partvisibility = vis; - g_Menus[g_MpPlayerNum].unk89c = 318; + g_Menus[g_MpPlayerNum].unk840.partvisibility = vis; + g_Menus[g_MpPlayerNum].unk840.unk05c = 318; } else { - g_Menus[g_MpPlayerNum].unk89c = 106; + g_Menus[g_MpPlayerNum].unk840.unk05c = 106; } if (bodynum == BODY_THEKING) { @@ -1182,23 +1182,23 @@ s32 ciCharacterProfileMenuDialog(s32 operation, struct menudialogdef *dialogdef, { 255 }, }; - g_Menus[g_MpPlayerNum].partvisibility = vis; + g_Menus[g_MpPlayerNum].unk840.partvisibility = vis; } - g_Menus[g_MpPlayerNum].unk84c = 0xffff; - g_Menus[g_MpPlayerNum].unk84c |= (mpheadnum << 16); - g_Menus[g_MpPlayerNum].unk84c |= (mpbodynum << 24); + g_Menus[g_MpPlayerNum].unk840.unk00c = 0xffff; + g_Menus[g_MpPlayerNum].unk840.unk00c |= (mpheadnum << 16); + g_Menus[g_MpPlayerNum].unk840.unk00c |= (mpbodynum << 24); - if (g_Menus[g_MpPlayerNum].unkdb8 > 0) { - g_Menus[g_MpPlayerNum].unkdb8 -= g_Vars.diffframe60; + if (g_Menus[g_MpPlayerNum].unk840.unk578 > 0) { + g_Menus[g_MpPlayerNum].unk840.unk578 -= g_Vars.diffframe60; } else { #if VERSION >= VERSION_PAL_FINAL - f32 tmp = g_Menus[g_MpPlayerNum].unkd64 + 0.01f * g_Vars.diffframe60freal; + f32 tmp = g_Menus[g_MpPlayerNum].unk840.unk524 + 0.01f * g_Vars.diffframe60freal; #else - f32 tmp = g_Menus[g_MpPlayerNum].unkd64 + 0.01f * g_Vars.diffframe60f; + f32 tmp = g_Menus[g_MpPlayerNum].unk840.unk524 + 0.01f * g_Vars.diffframe60f; #endif - g_Menus[g_MpPlayerNum].unkd8c = tmp; - g_Menus[g_MpPlayerNum].unkd64 = tmp; + g_Menus[g_MpPlayerNum].unk840.unk54c = tmp; + g_Menus[g_MpPlayerNum].unk840.unk524 = tmp; } break; @@ -1361,32 +1361,32 @@ s32 dtTrainingDetailsMenuDialog(s32 operation, struct menudialogdef *dialogdef, #if VERSION >= VERSION_PAL_FINAL if (g_ViRes == VIRES_HI) { if (optionsGetScreenRatio() == SCREENRATIO_16_9) { - g_Menus[g_MpPlayerNum].unkd78 = 84; - g_Menus[g_MpPlayerNum].unkd50 = 84; + g_Menus[g_MpPlayerNum].unk840.unk538 = 84; + g_Menus[g_MpPlayerNum].unk840.unk510 = 84; } else { - g_Menus[g_MpPlayerNum].unkd78 = 104; - g_Menus[g_MpPlayerNum].unkd50 = 104; + g_Menus[g_MpPlayerNum].unk840.unk538 = 104; + g_Menus[g_MpPlayerNum].unk840.unk510 = 104; } } else { if (optionsGetScreenRatio() == SCREENRATIO_16_9) { - g_Menus[g_MpPlayerNum].unkd78 = 64; - g_Menus[g_MpPlayerNum].unkd50 = 64; + g_Menus[g_MpPlayerNum].unk840.unk538 = 64; + g_Menus[g_MpPlayerNum].unk840.unk510 = 64; } else { - g_Menus[g_MpPlayerNum].unkd78 = 84; - g_Menus[g_MpPlayerNum].unkd50 = 84; + g_Menus[g_MpPlayerNum].unk840.unk538 = 84; + g_Menus[g_MpPlayerNum].unk840.unk510 = 84; } } #else if (optionsGetScreenRatio() == SCREENRATIO_16_9) { - g_Menus[g_MpPlayerNum].unkd78 = 70; - g_Menus[g_MpPlayerNum].unkd50 = 70; + g_Menus[g_MpPlayerNum].unk840.unk538 = 70; + g_Menus[g_MpPlayerNum].unk840.unk510 = 70; } else { - g_Menus[g_MpPlayerNum].unkd78 = 90; - g_Menus[g_MpPlayerNum].unkd50 = 90; + g_Menus[g_MpPlayerNum].unk840.unk538 = 90; + g_Menus[g_MpPlayerNum].unk840.unk510 = 90; } #endif - g_Menus[g_MpPlayerNum].unkd84 /= 2.5f; + g_Menus[g_MpPlayerNum].unk840.unk544 /= 2.5f; } break; case MENUOP_CLOSE: @@ -1396,15 +1396,15 @@ s32 dtTrainingDetailsMenuDialog(s32 operation, struct menudialogdef *dialogdef, s32 weaponnum = dtGetWeaponByDeviceIndex(dtGetIndexBySlot(g_DtSlot)); if (weaponnum == WEAPON_DISGUISE41) { - g_Menus[g_MpPlayerNum].unk89c = 0x6a; - g_Menus[g_MpPlayerNum].unkdb8 = PALDOWN(60); - g_Menus[g_MpPlayerNum].unkdb4 = PALDOWN(120); + g_Menus[g_MpPlayerNum].unk840.unk05c = ANIM_006A; + g_Menus[g_MpPlayerNum].unk840.unk578 = PALDOWN(60); + g_Menus[g_MpPlayerNum].unk840.unk574 = PALDOWN(120); } - g_Menus[g_MpPlayerNum].unkd8c = 18.849555969238f * var80061630; - g_Menus[g_MpPlayerNum].unkd64 = 18.849555969238f * var80061630; - g_Menus[g_MpPlayerNum].unkd90 = 0; - g_Menus[g_MpPlayerNum].unkd68 = 0; + g_Menus[g_MpPlayerNum].unk840.unk54c = 18.849555969238f * var80061630; + g_Menus[g_MpPlayerNum].unk840.unk524 = 18.849555969238f * var80061630; + g_Menus[g_MpPlayerNum].unk840.unk550 = 0; + g_Menus[g_MpPlayerNum].unk840.unk528 = 0; } break; } diff --git a/src/include/game/credits.h b/src/include/game/credits.h index 37885a7cc..0b0787cfc 100644 --- a/src/include/game/credits.h +++ b/src/include/game/credits.h @@ -23,7 +23,7 @@ void creditsInitSlides(void); struct credit *creditGetByRow(s32 row); void creditsTickSlide(void); Gfx *func0f13a3ec(Gfx *gdl); -u32 func0f13ae04(void); +void func0f13ae04(Mtxf *mtx); void creditsTick(void); Gfx *creditsRender(Gfx *gdl); void creditsInit(void); @@ -66,373 +66,7 @@ struct creditsdata { /*0x2eed*/ u8 unk2eed; /*0x2eee*/ u8 unk2eee; /*0x2eef*/ u8 unk2eef; - /*0x2ef0*/ u8 unk2ef0; - /*0x2ef4*/ u32 unk2ef4; - /*0x2ef8*/ u32 unk2ef8; - /*0x2efc*/ u32 unk2efc; - /*0x2f00*/ u32 unk2f00; - /*0x2f04*/ u32 unk2f04; - /*0x2f08*/ u32 unk2f08; - /*0x2f0c*/ u32 unk2f0c; - /*0x2f10*/ u32 unk2f10; - /*0x2f14*/ u32 unk2f14; - /*0x2f18*/ u32 unk2f18; - /*0x2f1c*/ u32 unk2f1c; - /*0x2f20*/ u32 unk2f20; - /*0x2f24*/ u32 unk2f24; - /*0x2f28*/ u32 unk2f28; - /*0x2f2c*/ u32 unk2f2c; - /*0x2f30*/ u32 unk2f30; - /*0x2f34*/ u32 unk2f34; - /*0x2f38*/ u32 unk2f38; - /*0x2f3c*/ u32 unk2f3c; - /*0x2f40*/ u32 unk2f40; - /*0x2f44*/ u32 unk2f44; - /*0x2f48*/ u32 unk2f48; - /*0x2f4c*/ u32 unk2f4c; - /*0x2f50*/ u32 unk2f50; - /*0x2f54*/ u32 unk2f54; - /*0x2f58*/ u32 unk2f58; - /*0x2f5c*/ u32 unk2f5c; - /*0x2f60*/ u32 unk2f60; - /*0x2f64*/ u32 unk2f64; - /*0x2f68*/ u32 unk2f68; - /*0x2f6c*/ u32 unk2f6c; - /*0x2f70*/ u32 unk2f70; - /*0x2f74*/ u32 unk2f74; - /*0x2f78*/ u32 unk2f78; - /*0x2f7c*/ u32 unk2f7c; - /*0x2f80*/ u32 unk2f80; - /*0x2f84*/ u32 unk2f84; - /*0x2f88*/ u32 unk2f88; - /*0x2f8c*/ u32 unk2f8c; - /*0x2f90*/ u32 unk2f90; - /*0x2f94*/ u32 unk2f94; - /*0x2f98*/ u32 unk2f98; - /*0x2f9c*/ u32 unk2f9c; - /*0x2fa0*/ u32 unk2fa0; - /*0x2fa4*/ u32 unk2fa4; - /*0x2fa8*/ u32 unk2fa8; - /*0x2fac*/ u32 unk2fac; - /*0x2fb0*/ u32 unk2fb0; - /*0x2fb4*/ u32 unk2fb4; - /*0x2fb8*/ u32 unk2fb8; - /*0x2fbc*/ u32 unk2fbc; - /*0x2fc0*/ u32 unk2fc0; - /*0x2fc4*/ u32 unk2fc4; - /*0x2fc8*/ u32 unk2fc8; - /*0x2fcc*/ u32 unk2fcc; - /*0x2fd0*/ u32 unk2fd0; - /*0x2fd4*/ u32 unk2fd4; - /*0x2fd8*/ u32 unk2fd8; - /*0x2fdc*/ u32 unk2fdc; - /*0x2fe0*/ u32 unk2fe0; - /*0x2fe4*/ u32 unk2fe4; - /*0x2fe8*/ u32 unk2fe8; - /*0x2fec*/ u32 unk2fec; - /*0x2ff0*/ u32 unk2ff0; - /*0x2ff4*/ u32 unk2ff4; - /*0x2ff8*/ u32 unk2ff8; - /*0x2ffc*/ u32 unk2ffc; - /*0x3000*/ u32 unk3000; - /*0x3004*/ u32 unk3004; - /*0x3008*/ u32 unk3008; - /*0x300c*/ u32 unk300c; - /*0x3010*/ u32 unk3010; - /*0x3014*/ u32 unk3014; - /*0x3018*/ u32 unk3018; - /*0x301c*/ u32 unk301c; - /*0x3020*/ u32 unk3020; - /*0x3024*/ u32 unk3024; - /*0x3028*/ u32 unk3028; - /*0x302c*/ u32 unk302c; - /*0x3030*/ u32 unk3030; - /*0x3034*/ u32 unk3034; - /*0x3038*/ u32 unk3038; - /*0x303c*/ u32 unk303c; - /*0x3040*/ u32 unk3040; - /*0x3044*/ u32 unk3044; - /*0x3048*/ u32 unk3048; - /*0x304c*/ u32 unk304c; - /*0x3050*/ u32 unk3050; - /*0x3054*/ u32 unk3054; - /*0x3058*/ u32 unk3058; - /*0x305c*/ u32 unk305c; - /*0x3060*/ u32 unk3060; - /*0x3064*/ u32 unk3064; - /*0x3068*/ u32 unk3068; - /*0x306c*/ u32 unk306c; - /*0x3070*/ u32 unk3070; - /*0x3074*/ u32 unk3074; - /*0x3078*/ u32 unk3078; - /*0x307c*/ u32 unk307c; - /*0x3080*/ u32 unk3080; - /*0x3084*/ u32 unk3084; - /*0x3088*/ u32 unk3088; - /*0x308c*/ u32 unk308c; - /*0x3090*/ u32 unk3090; - /*0x3094*/ u32 unk3094; - /*0x3098*/ u32 unk3098; - /*0x309c*/ u32 unk309c; - /*0x30a0*/ u32 unk30a0; - /*0x30a4*/ u32 unk30a4; - /*0x30a8*/ u32 unk30a8; - /*0x30ac*/ u32 unk30ac; - /*0x30b0*/ u32 unk30b0; - /*0x30b4*/ u32 unk30b4; - /*0x30b8*/ u32 unk30b8; - /*0x30bc*/ u32 unk30bc; - /*0x30c0*/ u32 unk30c0; - /*0x30c4*/ u32 unk30c4; - /*0x30c8*/ u32 unk30c8; - /*0x30cc*/ u32 unk30cc; - /*0x30d0*/ u32 unk30d0; - /*0x30d4*/ u32 unk30d4; - /*0x30d8*/ u32 unk30d8; - /*0x30dc*/ u32 unk30dc; - /*0x30e0*/ u32 unk30e0; - /*0x30e4*/ u32 unk30e4; - /*0x30e8*/ u32 unk30e8; - /*0x30ec*/ u32 unk30ec; - /*0x30f0*/ u32 unk30f0; - /*0x30f4*/ u32 unk30f4; - /*0x30f8*/ u32 unk30f8; - /*0x30fc*/ u32 unk30fc; - /*0x3100*/ u32 unk3100; - /*0x3104*/ u32 unk3104; - /*0x3108*/ u32 unk3108; - /*0x310c*/ u32 unk310c; - /*0x3110*/ u32 unk3110; - /*0x3114*/ u32 unk3114; - /*0x3118*/ u32 unk3118; - /*0x311c*/ u32 unk311c; - /*0x3120*/ u32 unk3120; - /*0x3124*/ u32 unk3124; - /*0x3128*/ u32 unk3128; - /*0x312c*/ u32 unk312c; - /*0x3130*/ u32 unk3130; - /*0x3134*/ u32 unk3134; - /*0x3138*/ u32 unk3138; - /*0x313c*/ u32 unk313c; - /*0x3140*/ u32 unk3140; - /*0x3144*/ u32 unk3144; - /*0x3148*/ u32 unk3148; - /*0x314c*/ u32 unk314c; - /*0x3150*/ u32 unk3150; - /*0x3154*/ u32 unk3154; - /*0x3158*/ u32 unk3158; - /*0x315c*/ u32 unk315c; - /*0x3160*/ u32 unk3160; - /*0x3164*/ u32 unk3164; - /*0x3168*/ u32 unk3168; - /*0x316c*/ u32 unk316c; - /*0x3170*/ u32 unk3170; - /*0x3174*/ u32 unk3174; - /*0x3178*/ u32 unk3178; - /*0x317c*/ u32 unk317c; - /*0x3180*/ u32 unk3180; - /*0x3184*/ u32 unk3184; - /*0x3188*/ u32 unk3188; - /*0x318c*/ u32 unk318c; - /*0x3190*/ u32 unk3190; - /*0x3194*/ u32 unk3194; - /*0x3198*/ u32 unk3198; - /*0x319c*/ u32 unk319c; - /*0x31a0*/ u32 unk31a0; - /*0x31a4*/ u32 unk31a4; - /*0x31a8*/ u32 unk31a8; - /*0x31ac*/ u32 unk31ac; - /*0x31b0*/ u32 unk31b0; - /*0x31b4*/ u32 unk31b4; - /*0x31b8*/ u32 unk31b8; - /*0x31bc*/ u32 unk31bc; - /*0x31c0*/ u32 unk31c0; - /*0x31c4*/ u32 unk31c4; - /*0x31c8*/ u32 unk31c8; - /*0x31cc*/ u32 unk31cc; - /*0x31d0*/ u32 unk31d0; - /*0x31d4*/ u32 unk31d4; - /*0x31d8*/ u32 unk31d8; - /*0x31dc*/ u32 unk31dc; - /*0x31e0*/ u32 unk31e0; - /*0x31e4*/ u32 unk31e4; - /*0x31e8*/ u32 unk31e8; - /*0x31ec*/ u32 unk31ec; - /*0x31f0*/ u32 unk31f0; - /*0x31f4*/ u32 unk31f4; - /*0x31f8*/ u32 unk31f8; - /*0x31fc*/ u32 unk31fc; - /*0x3200*/ u32 unk3200; - /*0x3204*/ u32 unk3204; - /*0x3208*/ u32 unk3208; - /*0x320c*/ u32 unk320c; - /*0x3210*/ u32 unk3210; - /*0x3214*/ u32 unk3214; - /*0x3218*/ u32 unk3218; - /*0x321c*/ u32 unk321c; - /*0x3220*/ u32 unk3220; - /*0x3224*/ u32 unk3224; - /*0x3228*/ u32 unk3228; - /*0x322c*/ u32 unk322c; - /*0x3230*/ u32 unk3230; - /*0x3234*/ u32 unk3234; - /*0x3238*/ u32 unk3238; - /*0x323c*/ u32 unk323c; - /*0x3240*/ u32 unk3240; - /*0x3244*/ u32 unk3244; - /*0x3248*/ u32 unk3248; - /*0x324c*/ u32 unk324c; - /*0x3250*/ u32 unk3250; - /*0x3254*/ u32 unk3254; - /*0x3258*/ u32 unk3258; - /*0x325c*/ u32 unk325c; - /*0x3260*/ u32 unk3260; - /*0x3264*/ u32 unk3264; - /*0x3268*/ u32 unk3268; - /*0x326c*/ u32 unk326c; - /*0x3270*/ u32 unk3270; - /*0x3274*/ u32 unk3274; - /*0x3278*/ u32 unk3278; - /*0x327c*/ u32 unk327c; - /*0x3280*/ u32 unk3280; - /*0x3284*/ u32 unk3284; - /*0x3288*/ u32 unk3288; - /*0x328c*/ u32 unk328c; - /*0x3290*/ u32 unk3290; - /*0x3294*/ u32 unk3294; - /*0x3298*/ u32 unk3298; - /*0x329c*/ u32 unk329c; - /*0x32a0*/ u32 unk32a0; - /*0x32a4*/ u32 unk32a4; - /*0x32a8*/ u32 unk32a8; - /*0x32ac*/ u32 unk32ac; - /*0x32b0*/ u32 unk32b0; - /*0x32b4*/ u32 unk32b4; - /*0x32b8*/ u32 unk32b8; - /*0x32bc*/ u32 unk32bc; - /*0x32c0*/ u32 unk32c0; - /*0x32c4*/ u32 unk32c4; - /*0x32c8*/ u32 unk32c8; - /*0x32cc*/ u32 unk32cc; - /*0x32d0*/ u32 unk32d0; - /*0x32d4*/ u32 unk32d4; - /*0x32d8*/ u32 unk32d8; - /*0x32dc*/ u32 unk32dc; - /*0x32e0*/ u32 unk32e0; - /*0x32e4*/ u32 unk32e4; - /*0x32e8*/ u32 unk32e8; - /*0x32ec*/ u32 unk32ec; - /*0x32f0*/ u32 unk32f0; - /*0x32f4*/ u32 unk32f4; - /*0x32f8*/ u32 unk32f8; - /*0x32fc*/ u32 unk32fc; - /*0x3300*/ u32 unk3300; - /*0x3304*/ u32 unk3304; - /*0x3308*/ u32 unk3308; - /*0x330c*/ u32 unk330c; - /*0x3310*/ u32 unk3310; - /*0x3314*/ u32 unk3314; - /*0x3318*/ u32 unk3318; - /*0x331c*/ u32 unk331c; - /*0x3320*/ u32 unk3320; - /*0x3324*/ u32 unk3324; - /*0x3328*/ u32 unk3328; - /*0x332c*/ u32 unk332c; - /*0x3330*/ u32 unk3330; - /*0x3334*/ u32 unk3334; - /*0x3338*/ u32 unk3338; - /*0x333c*/ u32 unk333c; - /*0x3340*/ u32 unk3340; - /*0x3344*/ u32 unk3344; - /*0x3348*/ u32 unk3348; - /*0x334c*/ u32 unk334c; - /*0x3350*/ u32 unk3350; - /*0x3354*/ u32 unk3354; - /*0x3358*/ u32 unk3358; - /*0x335c*/ u32 unk335c; - /*0x3360*/ u32 unk3360; - /*0x3364*/ u32 unk3364; - /*0x3368*/ u32 unk3368; - /*0x336c*/ u32 unk336c; - /*0x3370*/ u32 unk3370; - /*0x3374*/ u32 unk3374; - /*0x3378*/ u32 unk3378; - /*0x337c*/ u32 unk337c; - /*0x3380*/ u32 unk3380; - /*0x3384*/ u32 unk3384; - /*0x3388*/ u32 unk3388; - /*0x338c*/ u32 unk338c; - /*0x3390*/ u32 unk3390; - /*0x3394*/ u32 unk3394; - /*0x3398*/ u32 unk3398; - /*0x339c*/ u32 unk339c; - /*0x33a0*/ u32 unk33a0; - /*0x33a4*/ u32 unk33a4; - /*0x33a8*/ u32 unk33a8; - /*0x33ac*/ u32 unk33ac; - /*0x33b0*/ u32 unk33b0; - /*0x33b4*/ u32 unk33b4; - /*0x33b8*/ u32 unk33b8; - /*0x33bc*/ u32 unk33bc; - /*0x33c0*/ u32 unk33c0; - /*0x33c4*/ u32 unk33c4; - /*0x33c8*/ u32 unk33c8; - /*0x33cc*/ u32 unk33cc; - /*0x33d0*/ u32 unk33d0; - /*0x33d4*/ u32 unk33d4; - /*0x33d8*/ u32 unk33d8; - /*0x33dc*/ u32 unk33dc; - /*0x33e0*/ u32 unk33e0; - /*0x33e4*/ u32 unk33e4; - /*0x33e8*/ u32 unk33e8; - /*0x33ec*/ u32 unk33ec; - /*0x33f0*/ u32 unk33f0; - /*0x33f4*/ u32 unk33f4; - /*0x33f8*/ u32 unk33f8; - /*0x33fc*/ u32 unk33fc; - /*0x3400*/ f32 unk3400; - /*0x3404*/ f32 unk3404; - /*0x3408*/ u32 unk3408; - /*0x340c*/ f32 unk340c; - /*0x3410*/ f32 unk3410; - /*0x3414*/ f32 unk3414; - /*0x3418*/ f32 unk3418; - /*0x341c*/ u32 unk341c; - /*0x3420*/ u32 unk3420; - /*0x3424*/ u32 unk3424; - /*0x3428*/ f32 unk3428; - /*0x342c*/ f32 unk342c; - /*0x3430*/ f32 unk3430; - /*0x3434*/ f32 unk3434; - /*0x3438*/ f32 unk3438; - /*0x343c*/ f32 unk343c; - /*0x3440*/ f32 unk3440; - /*0x3444*/ u32 unk3444; - /*0x3448*/ u32 unk3448; - /*0x344c*/ u32 unk344c; - /*0x3450*/ u32 unk3450; - /*0x3454*/ u32 unk3454; - /*0x3458*/ u32 unk3458; - /*0x345c*/ u32 unk345c; - /*0x3460*/ u32 unk3460; - /*0x3464*/ u32 unk3464; - /*0x3468*/ u32 unk3468; - /*0x346c*/ u32 unk346c; - /*0x3470*/ u32 unk3470; - /*0x3474*/ u32 unk3474; - /*0x3478*/ u32 unk3478; - /*0x347c*/ u32 unk347c; - /*0x3480*/ u32 unk3480; - /*0x3484*/ u32 unk3484; - /*0x3488*/ u32 unk3488; - /*0x348c*/ u32 unk348c; - /*0x3490*/ u32 unk3490; - /*0x3494*/ u32 unk3494; - /*0x3498*/ u32 unk3498; - /*0x349c*/ u32 unk349c; - /*0x34a0*/ u8 unk34a0; - /*0x34a1*/ u8 unk34a1; // flags? - /*0x34a4*/ u32 unk34a4; + /*0x2ef0*/ struct menu840 unk2ef0; /*0x34a8*/ u32 unk34a8; /*0x34ac*/ u32 unk34ac; /*0x34b0*/ u32 unk34b0; diff --git a/src/include/game/game_00c490.h b/src/include/game/game_00c490.h index 2f7ec960b..2a63d150a 100644 --- a/src/include/game/game_00c490.h +++ b/src/include/game/game_00c490.h @@ -27,7 +27,7 @@ s32 func0f00e1f8(s32 padnum); s32 func0f00e2b0(s32 padnum); void setupDoor(struct doorobj *door, s32 cmdindex); void setupHov(struct defaultobj *obj, struct hov *hov); -void func0f00e980(s32 stagenum, s32 arg0, s32 arg1, struct briefing *briefing); +void func0f00e980(s32 stagenum, u8 *arg0, s32 arg1, struct briefing *briefing); void setupLoadFiles(s32 stagenum); void setupParseObjects(s32 stagenum); diff --git a/src/include/game/game_0b4950.h b/src/include/game/game_0b4950.h index f0fb13f41..618a8b2e9 100644 --- a/src/include/game/game_0b4950.h +++ b/src/include/game/game_0b4950.h @@ -32,8 +32,8 @@ void currentPlayerSetUnk1754(Mtxf *matrix); Mtxf *currentPlayerGetUnk1754(void); void currentPlayerSetUnk174c(Mtxf *matrix); Mtxf *currentPlayerGetUnk174c(void); -void currentPlayerSetUnk175c(void *value); -void *currentPlayerGetUnk175c(void); +void currentPlayerSetUnk175c(Mtxf *matrix); +Mtxf *currentPlayerGetUnk175c(void); f32 currentPlayerGetLodScaleZ(void); f32 currentPlayerGetScreenWidth(void); f32 currentPlayerGetScreenHeight(void); diff --git a/src/include/game/game_0f09f0.h b/src/include/game/game_0f09f0.h index ee87af341..9b4582c4a 100644 --- a/src/include/game/game_0f09f0.h +++ b/src/include/game/game_0f09f0.h @@ -56,9 +56,9 @@ void menuCloseDialog(void); void menuUpdateCurFrame(void); void menuPopDialog(void); void func0f0f3704(struct menudialogdef *dialogdef); -void func0f0f372c(u8 *arg0, f32 x, f32 y, f32 arg3, f32 arg4, f32 arg5, f32 arg6, f32 arg7, s32 arg8); -void func0f0f37a4(u8 *arg0); -Gfx *menuRenderHudPiece(Gfx *gdl, u8 *arg1, u32 arg2); +void func0f0f372c(struct menu840 *arg0, f32 x, f32 y, f32 arg3, f32 arg4, f32 arg5, f32 arg6, f32 arg7, s32 arg8); +void func0f0f37a4(struct menu840 *arg0); +Gfx *menuRenderModels(Gfx *gdl, struct menu840 *arg1, s32 arg2); u32 func0f0f5004(void); Gfx *menuApplyScissor(Gfx *gdl); Gfx *dialogRender(Gfx *gdl, struct menudialog *dialog, struct menu *menu, s32 arg3); @@ -75,7 +75,7 @@ void menuPushRootDialog(struct menudialogdef *dialogdef, s32 arg1); void func0f0f85e0(struct menudialogdef *dialogdef, s32 root); Gfx *menuRenderDialog(Gfx *gdl, struct menudialog *dialog, struct menu *menu, s32 arg3); Gfx *menuRenderDialogs(Gfx *gdl); -void func0f0f8bb4(u8 *arg0, u32 arg1, u32 arg2); +void func0f0f8bb4(struct menu840 *arg0, u32 arg1, u32 arg2); void menuInit(void); void menuSwipe(s32 direction); void dialogTick(struct menudialog *dialog, struct menuinputs *inputs, u32 tickflags); diff --git a/src/include/lib/model.h b/src/include/lib/model.h index e007b2bf0..6d8bd2b3f 100644 --- a/src/include/lib/model.h +++ b/src/include/lib/model.h @@ -34,11 +34,11 @@ f32 model0001afe8(f32 arg0, f32 angle, f32 frac); void model0001b07c(struct coord *arg0, struct coord *arg1, f32 mult); void model0001b0e8(struct model *model, struct modelnode *node); void model0001b3bc(struct model *model); -void model0001b400(struct objticksp476 *arg0, struct model *model, struct modelnode *node); +void model0001b400(struct modelrenderdata *arg0, struct model *model, struct modelnode *node); u32 model0001b80c(void); u32 model0001bc14(void); -void model0001bfa8(struct objticksp476 *arg0, struct model *model, struct modelnode *node); -void model0001c5b4(struct objticksp476 *arg0, struct model *model, struct modelnode *node); +void model0001bfa8(struct modelrenderdata *arg0, struct model *model, struct modelnode *node); +void model0001c5b4(struct modelrenderdata *arg0, struct model *model, struct modelnode *node); void model0001c664(struct model *model, struct modelnode *node); void model0001c784(struct model *model, struct modelnode *node); void model0001c7d0(struct model *model, struct modelnode *node); @@ -48,9 +48,9 @@ void modelRenderNodeReorder(struct model *model, struct modelnode *node); void model0001c950(struct model *model, struct modelnode *node); void model0001cb0c(struct model *model, struct modelnode *node); void model0001cc20(struct model *model); -void model0001cd18(struct objticksp476 *arg0, struct model *model); -void model0001ce64(struct objticksp476 *arg0, struct model *model); -void model0001cebc(struct objticksp476 *arg0, struct model *model); +void model0001cd18(struct modelrenderdata *arg0, struct model *model); +void model0001ce64(struct modelrenderdata *arg0, struct model *model); +void model0001cebc(struct modelrenderdata *renderdata, struct model *model); s16 modelGetAnimNum(struct model *model); bool modelIsFlipped(struct model *model); f32 modelGetCurAnimFrame(struct model *model); diff --git a/src/include/types.h b/src/include/types.h index 2fe061a6a..10bcc6a99 100644 --- a/src/include/types.h +++ b/src/include/types.h @@ -550,12 +550,18 @@ struct modelrodata_position { // type 0x02 f32 drawdist; }; +struct modelrodata_gundl0c { + u32 unk00; + u32 unk04; + s16 unk08; +}; + struct modelrodata_gundl { // type 0x04 Gfx *primary; Gfx *secondary; void *baseaddr; - void *unk0c; - u16 unk10; + struct modelrodata_gundl0c *unk0c; + s16 unk10; s16 unk12; }; @@ -2759,7 +2765,7 @@ struct player { /*0x1750*/ void *unk1750; /*0x1754*/ Mtxf *unk1754; /*0x1758*/ Mtx *unk1758; - /*0x175c*/ void *unk175c; + /*0x175c*/ Mtxf *unk175c; /*0x1760*/ Mtxf *prev1740; /*0x1764*/ s32 c_prevviewfmdynticknum; /*0x1768*/ Mtxf *unk1768; @@ -3927,6 +3933,327 @@ struct perfectheadtexturelist { struct textureconfig selectedtexture; }; +struct menu840 { + /*0x000*/ u8 unk000; + /*0x001*/ u8 unk001; + /*0x002*/ s16 headnum; + /*0x004*/ u8 *unk004; + /*0x008*/ u32 unk008; + /*0x00c*/ u32 unk00c; + /*0x010*/ s32 unk010; + /*0x014*/ Mtxf unk014; + /*0x054*/ struct modelfiledata *bodymodeldef; + /*0x058*/ struct modelfiledata *headmodeldef; + /*0x05c*/ s16 unk05c; + /*0x05e*/ s16 unk05e; + /*0x060*/ struct model bodymodel; + /*0x084*/ struct anim bodyanim; + /*0x110*/ union modelrwdata *unk110; + /*0x114*/ u32 unk114; + /*0x118*/ u32 unk118; + /*0x11c*/ u32 unk11c; + /*0x120*/ u32 unk120; + /*0x124*/ u32 unk124; + /*0x128*/ u32 unk128; + /*0x12c*/ u32 unk12c; + /*0x130*/ u32 unk130; + /*0x134*/ u32 unk134; + /*0x138*/ u32 unk138; + /*0x13c*/ u32 unk13c; + /*0x140*/ u32 unk140; + /*0x144*/ u32 unk144; + /*0x148*/ u32 unk148; + /*0x14c*/ u32 unk14c; + /*0x150*/ u32 unk150; + /*0x154*/ u32 unk154; + /*0x158*/ u32 unk158; + /*0x15c*/ u32 unk15c; + /*0x160*/ u32 unk160; + /*0x164*/ u32 unk164; + /*0x168*/ u32 unk168; + /*0x16c*/ u32 unk16c; + /*0x170*/ u32 unk170; + /*0x174*/ u32 unk174; + /*0x178*/ u32 unk178; + /*0x17c*/ u32 unk17c; + /*0x180*/ u32 unk180; + /*0x184*/ u32 unk184; + /*0x188*/ u32 unk188; + /*0x18c*/ u32 unk18c; + /*0x190*/ u32 unk190; + /*0x194*/ u32 unk194; + /*0x198*/ u32 unk198; + /*0x19c*/ u32 unk19c; + /*0x1a0*/ u32 unk1a0; + /*0x1a4*/ u32 unk1a4; + /*0x1a8*/ u32 unk1a8; + /*0x1ac*/ u32 unk1ac; + /*0x1b0*/ u32 unk1b0; + /*0x1b4*/ u32 unk1b4; + /*0x1b8*/ u32 unk1b8; + /*0x1bc*/ u32 unk1bc; + /*0x1c0*/ u32 unk1c0; + /*0x1c4*/ u32 unk1c4; + /*0x1c8*/ u32 unk1c8; + /*0x1cc*/ u32 unk1cc; + /*0x1d0*/ u32 unk1d0; + /*0x1d4*/ u32 unk1d4; + /*0x1d8*/ u32 unk1d8; + /*0x1dc*/ u32 unk1dc; + /*0x1e0*/ u32 unk1e0; + /*0x1e4*/ u32 unk1e4; + /*0x1e8*/ u32 unk1e8; + /*0x1ec*/ u32 unk1ec; + /*0x1f0*/ u32 unk1f0; + /*0x1f4*/ u32 unk1f4; + /*0x1f8*/ u32 unk1f8; + /*0x1fc*/ u32 unk1fc; + /*0x200*/ u32 unk200; + /*0x204*/ u32 unk204; + /*0x208*/ u32 unk208; + /*0x20c*/ u32 unk20c; + /*0x210*/ u32 unk210; + /*0x214*/ u32 unk214; + /*0x218*/ u32 unk218; + /*0x21c*/ u32 unk21c; + /*0x220*/ u32 unk220; + /*0x224*/ u32 unk224; + /*0x228*/ u32 unk228; + /*0x22c*/ u32 unk22c; + /*0x230*/ u32 unk230; + /*0x234*/ u32 unk234; + /*0x238*/ u32 unk238; + /*0x23c*/ u32 unk23c; + /*0x240*/ u32 unk240; + /*0x244*/ u32 unk244; + /*0x248*/ u32 unk248; + /*0x24c*/ u32 unk24c; + /*0x250*/ u32 unk250; + /*0x254*/ u32 unk254; + /*0x258*/ u32 unk258; + /*0x25c*/ u32 unk25c; + /*0x260*/ u32 unk260; + /*0x264*/ u32 unk264; + /*0x268*/ u32 unk268; + /*0x26c*/ u32 unk26c; + /*0x270*/ u32 unk270; + /*0x274*/ u32 unk274; + /*0x278*/ u32 unk278; + /*0x27c*/ u32 unk27c; + /*0x280*/ u32 unk280; + /*0x284*/ u32 unk284; + /*0x288*/ u32 unk288; + /*0x28c*/ u32 unk28c; + /*0x290*/ u32 unk290; + /*0x294*/ u32 unk294; + /*0x298*/ u32 unk298; + /*0x29c*/ u32 unk29c; + /*0x2a0*/ u32 unk2a0; + /*0x2a4*/ u32 unk2a4; + /*0x2a8*/ u32 unk2a8; + /*0x2ac*/ u32 unk2ac; + /*0x2b0*/ u32 unk2b0; + /*0x2b4*/ u32 unk2b4; + /*0x2b8*/ u32 unk2b8; + /*0x2bc*/ u32 unk2bc; + /*0x2c0*/ u32 unk2c0; + /*0x2c4*/ u32 unk2c4; + /*0x2c8*/ u32 unk2c8; + /*0x2cc*/ u32 unk2cc; + /*0x2d0*/ u32 unk2d0; + /*0x2d4*/ u32 unk2d4; + /*0x2d8*/ u32 unk2d8; + /*0x2dc*/ u32 unk2dc; + /*0x2e0*/ u32 unk2e0; + /*0x2e4*/ u32 unk2e4; + /*0x2e8*/ u32 unk2e8; + /*0x2ec*/ u32 unk2ec; + /*0x2f0*/ u32 unk2f0; + /*0x2f4*/ u32 unk2f4; + /*0x2f8*/ u32 unk2f8; + /*0x2fc*/ u32 unk2fc; + /*0x300*/ u32 unk300; + /*0x304*/ u32 unk304; + /*0x308*/ u32 unk308; + /*0x30c*/ u32 unk30c; + /*0x310*/ u32 unk310; + /*0x314*/ u32 unk314; + /*0x318*/ u32 unk318; + /*0x31c*/ u32 unk31c; + /*0x320*/ u32 unk320; + /*0x324*/ u32 unk324; + /*0x328*/ u32 unk328; + /*0x32c*/ u32 unk32c; + /*0x330*/ u32 unk330; + /*0x334*/ u32 unk334; + /*0x338*/ u32 unk338; + /*0x33c*/ u32 unk33c; + /*0x340*/ u32 unk340; + /*0x344*/ u32 unk344; + /*0x348*/ u32 unk348; + /*0x34c*/ u32 unk34c; + /*0x350*/ u32 unk350; + /*0x354*/ u32 unk354; + /*0x358*/ u32 unk358; + /*0x35c*/ u32 unk35c; + /*0x360*/ u32 unk360; + /*0x364*/ u32 unk364; + /*0x368*/ u32 unk368; + /*0x36c*/ u32 unk36c; + /*0x370*/ u32 unk370; + /*0x374*/ u32 unk374; + /*0x378*/ u32 unk378; + /*0x37c*/ u32 unk37c; + /*0x380*/ u32 unk380; + /*0x384*/ u32 unk384; + /*0x388*/ u32 unk388; + /*0x38c*/ u32 unk38c; + /*0x390*/ u32 unk390; + /*0x394*/ u32 unk394; + /*0x398*/ u32 unk398; + /*0x39c*/ u32 unk39c; + /*0x3a0*/ u32 unk3a0; + /*0x3a4*/ u32 unk3a4; + /*0x3a8*/ u32 unk3a8; + /*0x3ac*/ u32 unk3ac; + /*0x3b0*/ u32 unk3b0; + /*0x3b4*/ u32 unk3b4; + /*0x3b8*/ u32 unk3b8; + /*0x3bc*/ u32 unk3bc; + /*0x3c0*/ u32 unk3c0; + /*0x3c4*/ u32 unk3c4; + /*0x3c8*/ u32 unk3c8; + /*0x3cc*/ u32 unk3cc; + /*0x3d0*/ u32 unk3d0; + /*0x3d4*/ u32 unk3d4; + /*0x3d8*/ u32 unk3d8; + /*0x3dc*/ u32 unk3dc; + /*0x3e0*/ u32 unk3e0; + /*0x3e4*/ u32 unk3e4; + /*0x3e8*/ u32 unk3e8; + /*0x3ec*/ u32 unk3ec; + /*0x3f0*/ u32 unk3f0; + /*0x3f4*/ u32 unk3f4; + /*0x3f8*/ u32 unk3f8; + /*0x3fc*/ u32 unk3fc; + /*0x400*/ u32 unk400; + /*0x404*/ u32 unk404; + /*0x408*/ u32 unk408; + /*0x40c*/ u32 unk40c; + /*0x410*/ u32 unk410; + /*0x414*/ u32 unk414; + /*0x418*/ u32 unk418; + /*0x41c*/ u32 unk41c; + /*0x420*/ u32 unk420; + /*0x424*/ u32 unk424; + /*0x428*/ u32 unk428; + /*0x42c*/ u32 unk42c; + /*0x430*/ u32 unk430; + /*0x434*/ u32 unk434; + /*0x438*/ u32 unk438; + /*0x43c*/ u32 unk43c; + /*0x440*/ u32 unk440; + /*0x444*/ u32 unk444; + /*0x448*/ u32 unk448; + /*0x44c*/ u32 unk44c; + /*0x450*/ u32 unk450; + /*0x454*/ u32 unk454; + /*0x458*/ u32 unk458; + /*0x45c*/ u32 unk45c; + /*0x460*/ u32 unk460; + /*0x464*/ u32 unk464; + /*0x468*/ u32 unk468; + /*0x46c*/ u32 unk46c; + /*0x470*/ u32 unk470; + /*0x474*/ u32 unk474; + /*0x478*/ u32 unk478; + /*0x47c*/ u32 unk47c; + /*0x480*/ u32 unk480; + /*0x484*/ u32 unk484; + /*0x488*/ u32 unk488; + /*0x48c*/ u32 unk48c; + /*0x490*/ u32 unk490; + /*0x494*/ u32 unk494; + /*0x498*/ u32 unk498; + /*0x49c*/ u32 unk49c; + /*0x4a0*/ u32 unk4a0; + /*0x4a4*/ u32 unk4a4; + /*0x4a8*/ u32 unk4a8; + /*0x4ac*/ u32 unk4ac; + /*0x4b0*/ u32 unk4b0; + /*0x4b4*/ u32 unk4b4; + /*0x4b8*/ u32 unk4b8; + /*0x4bc*/ u32 unk4bc; + /*0x4c0*/ u32 unk4c0; + /*0x4c4*/ u32 unk4c4; + /*0x4c8*/ u32 unk4c8; + /*0x4cc*/ u32 unk4cc; + /*0x4d0*/ u32 unk4d0; + /*0x4d4*/ u32 unk4d4; + /*0x4d8*/ u32 unk4d8; + /*0x4dc*/ u32 unk4dc; + /*0x4e0*/ u32 unk4e0; + /*0x4e4*/ u32 unk4e4; + /*0x4e8*/ u32 unk4e8; + /*0x4ec*/ u32 unk4ec; + /*0x4f0*/ u32 unk4f0; + /*0x4f4*/ u32 unk4f4; + /*0x4f8*/ u32 unk4f8; + /*0x4fc*/ u32 unk4fc; + /*0x500*/ u32 unk500; + /*0x504*/ u32 unk504; + /*0x508*/ u32 unk508; + /*0x50c*/ u32 unk50c; + /*0x510*/ f32 unk510; + /*0x514*/ f32 unk514; + /*0x518*/ f32 unk518; + /*0x51c*/ f32 unk51c; + /*0x520*/ f32 unk520; + /*0x524*/ f32 unk524; + /*0x528*/ f32 unk528; + /*0x52c*/ f32 unk52c; + /*0x530*/ f32 unk530; + /*0x534*/ f32 unk534; + /*0x538*/ f32 unk538; + /*0x53c*/ f32 unk53c; + /*0x540*/ f32 unk540; + /*0x544*/ f32 unk544; + /*0x548*/ f32 unk548; + /*0x54c*/ f32 unk54c; + /*0x550*/ f32 unk550; + /*0x554*/ f32 unk554; + /*0x558*/ u32 unk558; + /*0x55c*/ u32 unk55c; + /*0x560*/ u32 unk560; + /*0x564*/ f32 unk564; + /*0x568*/ u8 unk568; + /*0x56a*/ s16 bodynum; + /*0x56c*/ u32 unk56c; + /*0x570*/ u32 unk570; + /*0x574*/ s32 unk574; + /*0x578*/ s32 unk578; + /*0x57c*/ u32 unk57c; + /*0x580*/ u32 unk580; + /*0x584*/ u32 unk584; + /*0x588*/ u32 unk588; + /*0x58c*/ u32 unk58c; + /*0x590*/ u32 unk590; + /*0x594*/ u32 unk594; + /*0x598*/ u32 unk598; + /*0x59c*/ u32 unk59c; + /*0x5a0*/ u32 unk5a0; + /*0x5a4*/ u32 unk5a4; + /*0x5a8*/ u32 unk5a8; + /*0x5ac*/ u32 unk5ac; + /*0x5b0*/ u8 unk5b0; + /*0x5b1*/ u8 unk5b1_01 : 1; + /*0x5b1*/ u8 unk5b1_02 : 1; + /*0x5b1*/ u8 unk5b1_03 : 1; + /*0x5b1*/ u8 unk5b1_04 : 1; + /*0x5b1*/ u8 unk5b1_05 : 1; + /*0x5b4*/ struct modelpartvisibility *partvisibility; +}; + struct menurow { s16 height; u8 itemindex; @@ -3968,383 +4295,7 @@ struct menu { /*0x83d*/ u8 unk83d; /*0x83e*/ u8 unk83e; /*0x83f*/ u8 unk83f; - /*0x840*/ u8 unk840; - - union { - /*0x844*/ u32 unk844; - /*0x844*/ u8 *mpconfigbuffer; // for MENUROOT_TRAINING - }; - - union { - /*0x848*/ u32 unk848; - /*0x848*/ u32 mpconfigbufferlen; // for MENUROOT_TRAINING - }; - - /*0x84c*/ u32 unk84c; - /*0x850*/ u32 unk850; - /*0x854*/ u8 unk854; - /*0x855*/ u8 unk855; - /*0x858*/ u32 unk858; - /*0x85c*/ u32 unk85c; - /*0x860*/ u32 unk860; - /*0x864*/ u32 unk864; - /*0x868*/ u32 unk868; - /*0x86c*/ u32 unk86c; - /*0x870*/ u32 unk870; - /*0x874*/ u32 unk874; - /*0x878*/ u32 unk878; - /*0x87c*/ u32 unk87c; - /*0x880*/ u32 unk880; - /*0x884*/ u32 unk884; - /*0x888*/ u32 unk888; - /*0x88c*/ u32 unk88c; - /*0x890*/ u32 unk890; - /*0x894*/ u32 unk894; - /*0x898*/ u32 unk898; - /*0x89c*/ u16 unk89c; - /*0x8a0*/ u32 unk8a0; - /*0x8a4*/ u32 unk8a4; - /*0x8a8*/ u32 unk8a8; - /*0x8ac*/ u32 unk8ac; - /*0x8b0*/ u32 unk8b0; - /*0x8b4*/ u32 unk8b4; - /*0x8b8*/ u32 unk8b8; - /*0x8bc*/ u32 unk8bc; - /*0x8c0*/ u32 unk8c0; - /*0x8c4*/ u32 unk8c4; - /*0x8c8*/ u32 unk8c8; - /*0x8cc*/ u32 unk8cc; - /*0x8d0*/ u32 unk8d0; - /*0x8d4*/ u32 unk8d4; - /*0x8d8*/ u32 unk8d8; - /*0x8dc*/ u32 unk8dc; - /*0x8e0*/ u32 unk8e0; - /*0x8e4*/ u32 unk8e4; - /*0x8e8*/ u32 unk8e8; - /*0x8ec*/ u32 unk8ec; - /*0x8f0*/ u32 unk8f0; - /*0x8f4*/ u32 unk8f4; - /*0x8f8*/ u32 unk8f8; - /*0x8fc*/ u32 unk8fc; - /*0x900*/ u32 unk900; - /*0x904*/ u32 unk904; - /*0x908*/ u32 unk908; - /*0x90c*/ u32 unk90c; - /*0x910*/ u32 unk910; - /*0x914*/ u32 unk914; - /*0x918*/ u32 unk918; - /*0x91c*/ u32 unk91c; - /*0x920*/ u32 unk920; - /*0x924*/ u32 unk924; - /*0x928*/ u32 unk928; - /*0x92c*/ u32 unk92c; - /*0x930*/ u32 unk930; - /*0x934*/ u32 unk934; - /*0x938*/ u32 unk938; - /*0x93c*/ u32 unk93c; - /*0x940*/ u32 unk940; - /*0x944*/ u32 unk944; - /*0x948*/ u32 unk948; - /*0x94c*/ u32 unk94c; - /*0x950*/ u32 unk950; - /*0x954*/ u32 unk954; - /*0x958*/ u32 unk958; - /*0x95c*/ u32 unk95c; - /*0x960*/ u32 unk960; - /*0x964*/ u32 unk964; - /*0x968*/ u32 unk968; - /*0x96c*/ u32 unk96c; - /*0x970*/ u32 unk970; - /*0x974*/ u32 unk974; - /*0x978*/ u32 unk978; - /*0x97c*/ u32 unk97c; - /*0x980*/ u32 unk980; - /*0x984*/ u32 unk984; - /*0x988*/ u32 unk988; - /*0x98c*/ u32 unk98c; - /*0x990*/ u32 unk990; - /*0x994*/ u32 unk994; - /*0x998*/ u32 unk998; - /*0x99c*/ u32 unk99c; - /*0x9a0*/ u32 unk9a0; - /*0x9a4*/ u32 unk9a4; - /*0x9a8*/ u32 unk9a8; - /*0x9ac*/ u32 unk9ac; - /*0x9b0*/ u32 unk9b0; - /*0x9b4*/ u32 unk9b4; - /*0x9b8*/ u32 unk9b8; - /*0x9bc*/ u32 unk9bc; - /*0x9c0*/ u32 unk9c0; - /*0x9c4*/ u32 unk9c4; - /*0x9c8*/ u32 unk9c8; - /*0x9cc*/ u32 unk9cc; - /*0x9d0*/ u32 unk9d0; - /*0x9d4*/ u32 unk9d4; - /*0x9d8*/ u32 unk9d8; - /*0x9dc*/ u32 unk9dc; - /*0x9e0*/ u32 unk9e0; - /*0x9e4*/ u32 unk9e4; - /*0x9e8*/ u32 unk9e8; - /*0x9ec*/ u32 unk9ec; - /*0x9f0*/ u32 unk9f0; - /*0x9f4*/ u32 unk9f4; - /*0x9f8*/ u32 unk9f8; - /*0x9fc*/ u32 unk9fc; - /*0xa00*/ u32 unka00; - /*0xa04*/ u32 unka04; - /*0xa08*/ u32 unka08; - /*0xa0c*/ u32 unka0c; - /*0xa10*/ u32 unka10; - /*0xa14*/ u32 unka14; - /*0xa18*/ u32 unka18; - /*0xa1c*/ u32 unka1c; - /*0xa20*/ u32 unka20; - /*0xa24*/ u32 unka24; - /*0xa28*/ u32 unka28; - /*0xa2c*/ u32 unka2c; - /*0xa30*/ u32 unka30; - /*0xa34*/ u32 unka34; - /*0xa38*/ u32 unka38; - /*0xa3c*/ u32 unka3c; - /*0xa40*/ u32 unka40; - /*0xa44*/ u32 unka44; - /*0xa48*/ u32 unka48; - /*0xa4c*/ u32 unka4c; - /*0xa50*/ u32 unka50; - /*0xa54*/ u32 unka54; - /*0xa58*/ u32 unka58; - /*0xa5c*/ u32 unka5c; - /*0xa60*/ u32 unka60; - /*0xa64*/ u32 unka64; - /*0xa68*/ u32 unka68; - /*0xa6c*/ u32 unka6c; - /*0xa70*/ u32 unka70; - /*0xa74*/ u32 unka74; - /*0xa78*/ u32 unka78; - /*0xa7c*/ u32 unka7c; - /*0xa80*/ u32 unka80; - /*0xa84*/ u32 unka84; - /*0xa88*/ u32 unka88; - /*0xa8c*/ u32 unka8c; - /*0xa90*/ u32 unka90; - /*0xa94*/ u32 unka94; - /*0xa98*/ u32 unka98; - /*0xa9c*/ u32 unka9c; - /*0xaa0*/ u32 unkaa0; - /*0xaa4*/ u32 unkaa4; - /*0xaa8*/ u32 unkaa8; - /*0xaac*/ u32 unkaac; - /*0xab0*/ u32 unkab0; - /*0xab4*/ u32 unkab4; - /*0xab8*/ u32 unkab8; - /*0xabc*/ u32 unkabc; - /*0xac0*/ u32 unkac0; - /*0xac4*/ u32 unkac4; - /*0xac8*/ u32 unkac8; - /*0xacc*/ u32 unkacc; - /*0xad0*/ u32 unkad0; - /*0xad4*/ u32 unkad4; - /*0xad8*/ u32 unkad8; - /*0xadc*/ u32 unkadc; - /*0xae0*/ u32 unkae0; - /*0xae4*/ u32 unkae4; - /*0xae8*/ u32 unkae8; - /*0xaec*/ u32 unkaec; - /*0xaf0*/ u32 unkaf0; - /*0xaf4*/ u32 unkaf4; - /*0xaf8*/ u32 unkaf8; - /*0xafc*/ u32 unkafc; - /*0xb00*/ u32 unkb00; - /*0xb04*/ u32 unkb04; - /*0xb08*/ u32 unkb08; - /*0xb0c*/ u32 unkb0c; - /*0xb10*/ u32 unkb10; - /*0xb14*/ u32 unkb14; - /*0xb18*/ u32 unkb18; - /*0xb1c*/ u32 unkb1c; - /*0xb20*/ u32 unkb20; - /*0xb24*/ u32 unkb24; - /*0xb28*/ u32 unkb28; - /*0xb2c*/ u32 unkb2c; - /*0xb30*/ u32 unkb30; - /*0xb34*/ u32 unkb34; - /*0xb38*/ u32 unkb38; - /*0xb3c*/ u32 unkb3c; - /*0xb40*/ u32 unkb40; - /*0xb44*/ u32 unkb44; - /*0xb48*/ u32 unkb48; - /*0xb4c*/ u32 unkb4c; - /*0xb50*/ u32 unkb50; - /*0xb54*/ u32 unkb54; - /*0xb58*/ u32 unkb58; - /*0xb5c*/ u32 unkb5c; - /*0xb60*/ u32 unkb60; - /*0xb64*/ u32 unkb64; - /*0xb68*/ u32 unkb68; - /*0xb6c*/ u32 unkb6c; - /*0xb70*/ u32 unkb70; - /*0xb74*/ u32 unkb74; - /*0xb78*/ u32 unkb78; - /*0xb7c*/ u32 unkb7c; - /*0xb80*/ u32 unkb80; - /*0xb84*/ u32 unkb84; - /*0xb88*/ u32 unkb88; - /*0xb8c*/ u32 unkb8c; - /*0xb90*/ u32 unkb90; - /*0xb94*/ u32 unkb94; - /*0xb98*/ u32 unkb98; - /*0xb9c*/ u32 unkb9c; - /*0xba0*/ u32 unkba0; - /*0xba4*/ u32 unkba4; - /*0xba8*/ u32 unkba8; - /*0xbac*/ u32 unkbac; - /*0xbb0*/ u32 unkbb0; - /*0xbb4*/ u32 unkbb4; - /*0xbb8*/ u32 unkbb8; - /*0xbbc*/ u32 unkbbc; - /*0xbc0*/ u32 unkbc0; - /*0xbc4*/ u32 unkbc4; - /*0xbc8*/ u32 unkbc8; - /*0xbcc*/ u32 unkbcc; - /*0xbd0*/ u32 unkbd0; - /*0xbd4*/ u32 unkbd4; - /*0xbd8*/ u32 unkbd8; - /*0xbdc*/ u32 unkbdc; - /*0xbe0*/ u32 unkbe0; - /*0xbe4*/ u32 unkbe4; - /*0xbe8*/ u32 unkbe8; - /*0xbec*/ u32 unkbec; - /*0xbf0*/ u32 unkbf0; - /*0xbf4*/ u32 unkbf4; - /*0xbf8*/ u32 unkbf8; - /*0xbfc*/ u32 unkbfc; - /*0xc00*/ u32 unkc00; - /*0xc04*/ u32 unkc04; - /*0xc08*/ u32 unkc08; - /*0xc0c*/ u32 unkc0c; - /*0xc10*/ u32 unkc10; - /*0xc14*/ u32 unkc14; - /*0xc18*/ u32 unkc18; - /*0xc1c*/ u32 unkc1c; - /*0xc20*/ u32 unkc20; - /*0xc24*/ u32 unkc24; - /*0xc28*/ u32 unkc28; - /*0xc2c*/ u32 unkc2c; - /*0xc30*/ u32 unkc30; - /*0xc34*/ u32 unkc34; - /*0xc38*/ u32 unkc38; - /*0xc3c*/ u32 unkc3c; - /*0xc40*/ u32 unkc40; - /*0xc44*/ u32 unkc44; - /*0xc48*/ u32 unkc48; - /*0xc4c*/ u32 unkc4c; - /*0xc50*/ u32 unkc50; - /*0xc54*/ u32 unkc54; - /*0xc58*/ u32 unkc58; - /*0xc5c*/ u32 unkc5c; - /*0xc60*/ u32 unkc60; - /*0xc64*/ u32 unkc64; - /*0xc68*/ u32 unkc68; - /*0xc6c*/ u32 unkc6c; - /*0xc70*/ u32 unkc70; - /*0xc74*/ u32 unkc74; - /*0xc78*/ u32 unkc78; - /*0xc7c*/ u32 unkc7c; - /*0xc80*/ u32 unkc80; - /*0xc84*/ u32 unkc84; - /*0xc88*/ u32 unkc88; - /*0xc8c*/ u32 unkc8c; - /*0xc90*/ u32 unkc90; - /*0xc94*/ u32 unkc94; - /*0xc98*/ u32 unkc98; - /*0xc9c*/ u32 unkc9c; - /*0xca0*/ u32 unkca0; - /*0xca4*/ u32 unkca4; - /*0xca8*/ u32 unkca8; - /*0xcac*/ u32 unkcac; - /*0xcb0*/ u32 unkcb0; - /*0xcb4*/ u32 unkcb4; - /*0xcb8*/ u32 unkcb8; - /*0xcbc*/ u32 unkcbc; - /*0xcc0*/ u32 unkcc0; - /*0xcc4*/ u32 unkcc4; - /*0xcc8*/ u32 unkcc8; - /*0xccc*/ u32 unkccc; - /*0xcd0*/ u32 unkcd0; - /*0xcd4*/ u32 unkcd4; - /*0xcd8*/ u32 unkcd8; - /*0xcdc*/ u32 unkcdc; - /*0xce0*/ u32 unkce0; - /*0xce4*/ u32 unkce4; - /*0xce8*/ u32 unkce8; - /*0xcec*/ u32 unkcec; - /*0xcf0*/ u32 unkcf0; - /*0xcf4*/ u32 unkcf4; - /*0xcf8*/ u32 unkcf8; - /*0xcfc*/ u32 unkcfc; - /*0xd00*/ u32 unkd00; - /*0xd04*/ u32 unkd04; - /*0xd08*/ u32 unkd08; - /*0xd0c*/ u32 unkd0c; - /*0xd10*/ u32 unkd10; - /*0xd14*/ u32 unkd14; - /*0xd18*/ u32 unkd18; - /*0xd1c*/ u32 unkd1c; - /*0xd20*/ u32 unkd20; - /*0xd24*/ u32 unkd24; - /*0xd28*/ u32 unkd28; - /*0xd2c*/ u32 unkd2c; - /*0xd30*/ u32 unkd30; - /*0xd34*/ u32 unkd34; - /*0xd38*/ u32 unkd38; - /*0xd3c*/ u32 unkd3c; - /*0xd40*/ u32 unkd40; - /*0xd44*/ u32 unkd44; - /*0xd48*/ u32 unkd48; - /*0xd4c*/ u32 unkd4c; - /*0xd50*/ f32 unkd50; - /*0xd54*/ f32 unkd54; - /*0xd58*/ f32 unkd58; - /*0xd5c*/ f32 unkd5c; - /*0xd60*/ f32 unkd60; - /*0xd64*/ f32 unkd64; - /*0xd68*/ f32 unkd68; - /*0xd6c*/ f32 unkd6c; - /*0xd70*/ f32 unkd70; - /*0xd74*/ f32 unkd74; - /*0xd78*/ f32 unkd78; - /*0xd7c*/ f32 unkd7c; - /*0xd80*/ f32 unkd80; - /*0xd84*/ f32 unkd84; - /*0xd88*/ f32 unkd88; - /*0xd8c*/ f32 unkd8c; - /*0xd90*/ f32 unkd90; - /*0xd94*/ f32 unkd94; - /*0xd98*/ u32 unkd98; - /*0xd9c*/ u32 unkd9c; - /*0xda0*/ u32 unkda0; - /*0xda4*/ u32 unkda4; - /*0xda8*/ u32 unkda8; - /*0xdac*/ u32 unkdac; - /*0xdb0*/ u32 unkdb0; - /*0xdb4*/ s32 unkdb4; - /*0xdb8*/ s32 unkdb8; - /*0xdbc*/ u32 unkdbc; - /*0xdc0*/ u32 unkdc0; - /*0xdc4*/ u32 unkdc4; - /*0xdc8*/ u32 unkdc8; - /*0xdcc*/ u32 unkdcc; - /*0xdd0*/ u32 unkdd0; - /*0xdd4*/ u32 unkdd4; - /*0xdd8*/ u32 unkdd8; - /*0xddc*/ u32 unkddc; - /*0xde0*/ u32 unkde0; - /*0xde4*/ u32 unkde4; - /*0xde8*/ u32 unkde8; - /*0xdec*/ u32 unkdec; - /*0xdf0*/ u8 unkdf0; - /*0xdf1*/ u8 unkdf1 : 1; - /*0xdf4*/ struct modelpartvisibility *partvisibility; + /*0x840*/ struct menu840 unk840; /*0xdf8*/ s8 bannernum; /*0xdfc*/ struct menudfc unkdfc[4]; @@ -5152,377 +5103,7 @@ struct menudata { /*0x016*/ u8 screenshottimer; /*0x017*/ u8 playerjoinalpha[4]; /*0x01b*/ s8 bannernum; - /*0x01c*/ u8 unk01c; - /*0x020*/ u32 unk020; - /*0x024*/ u32 unk024; - /*0x028*/ u32 unk028; - /*0x02c*/ u32 unk02c; - /*0x030*/ u32 unk030; - /*0x034*/ u32 unk034; - /*0x038*/ u32 unk038; - /*0x03c*/ u32 unk03c; - /*0x040*/ u32 unk040; - /*0x044*/ u32 unk044; - /*0x048*/ u32 unk048; - /*0x04c*/ u32 unk04c; - /*0x050*/ u32 unk050; - /*0x054*/ u32 unk054; - /*0x058*/ u32 unk058; - /*0x05c*/ u32 unk05c; - /*0x060*/ u32 unk060; - /*0x064*/ u32 unk064; - /*0x068*/ u32 unk068; - /*0x06c*/ u32 unk06c; - /*0x070*/ u32 unk070; - /*0x074*/ u32 unk074; - /*0x078*/ u16 unk078; - /*0x07a*/ s16 unk07a; - /*0x07c*/ u32 unk07c; - /*0x080*/ u32 unk080; - /*0x084*/ u32 unk084; - /*0x088*/ u32 unk088; - /*0x08c*/ u32 unk08c; - /*0x090*/ u32 unk090; - /*0x094*/ u32 unk094; - /*0x098*/ u32 unk098; - /*0x09c*/ u32 unk09c; - /*0x0a0*/ u32 unk0a0; - /*0x0a4*/ u32 unk0a4; - /*0x0a8*/ u32 unk0a8; - /*0x0ac*/ u32 unk0ac; - /*0x0b0*/ u32 unk0b0; - /*0x0b4*/ u32 unk0b4; - /*0x0b8*/ u32 unk0b8; - /*0x0bc*/ u32 unk0bc; - /*0x0c0*/ u32 unk0c0; - /*0x0c4*/ u32 unk0c4; - /*0x0c8*/ u32 unk0c8; - /*0x0cc*/ u32 unk0cc; - /*0x0d0*/ u32 unk0d0; - /*0x0d4*/ u32 unk0d4; - /*0x0d8*/ u32 unk0d8; - /*0x0dc*/ u32 unk0dc; - /*0x0e0*/ u32 unk0e0; - /*0x0e4*/ u32 unk0e4; - /*0x0e8*/ u32 unk0e8; - /*0x0ec*/ u32 unk0ec; - /*0x0f0*/ u32 unk0f0; - /*0x0f4*/ u32 unk0f4; - /*0x0f8*/ u32 unk0f8; - /*0x0fc*/ u32 unk0fc; - /*0x100*/ u32 unk100; - /*0x104*/ u32 unk104; - /*0x108*/ u32 unk108; - /*0x10c*/ u32 unk10c; - /*0x110*/ u32 unk110; - /*0x114*/ u32 unk114; - /*0x118*/ u32 unk118; - /*0x11c*/ u32 unk11c; - /*0x120*/ u32 unk120; - /*0x124*/ u32 unk124; - /*0x128*/ u32 unk128; - /*0x12c*/ u32 unk12c; - /*0x130*/ u32 unk130; - /*0x134*/ u32 unk134; - /*0x138*/ u32 unk138; - /*0x13c*/ u32 unk13c; - /*0x140*/ u32 unk140; - /*0x144*/ u32 unk144; - /*0x148*/ u32 unk148; - /*0x14c*/ u32 unk14c; - /*0x150*/ u32 unk150; - /*0x154*/ u32 unk154; - /*0x158*/ u32 unk158; - /*0x15c*/ u32 unk15c; - /*0x160*/ u32 unk160; - /*0x164*/ u32 unk164; - /*0x168*/ u32 unk168; - /*0x16c*/ u32 unk16c; - /*0x170*/ u32 unk170; - /*0x174*/ u32 unk174; - /*0x178*/ u32 unk178; - /*0x17c*/ u32 unk17c; - /*0x180*/ u32 unk180; - /*0x184*/ u32 unk184; - /*0x188*/ u32 unk188; - /*0x18c*/ u32 unk18c; - /*0x190*/ u32 unk190; - /*0x194*/ u32 unk194; - /*0x198*/ u32 unk198; - /*0x19c*/ u32 unk19c; - /*0x1a0*/ u32 unk1a0; - /*0x1a4*/ u32 unk1a4; - /*0x1a8*/ u32 unk1a8; - /*0x1ac*/ u32 unk1ac; - /*0x1b0*/ u32 unk1b0; - /*0x1b4*/ u32 unk1b4; - /*0x1b8*/ u32 unk1b8; - /*0x1bc*/ u32 unk1bc; - /*0x1c0*/ u32 unk1c0; - /*0x1c4*/ u32 unk1c4; - /*0x1c8*/ u32 unk1c8; - /*0x1cc*/ u32 unk1cc; - /*0x1d0*/ u32 unk1d0; - /*0x1d4*/ u32 unk1d4; - /*0x1d8*/ u32 unk1d8; - /*0x1dc*/ u32 unk1dc; - /*0x1e0*/ u32 unk1e0; - /*0x1e4*/ u32 unk1e4; - /*0x1e8*/ u32 unk1e8; - /*0x1ec*/ u32 unk1ec; - /*0x1f0*/ u32 unk1f0; - /*0x1f4*/ u32 unk1f4; - /*0x1f8*/ u32 unk1f8; - /*0x1fc*/ u32 unk1fc; - /*0x200*/ u32 unk200; - /*0x204*/ u32 unk204; - /*0x208*/ u32 unk208; - /*0x20c*/ u32 unk20c; - /*0x210*/ u32 unk210; - /*0x214*/ u32 unk214; - /*0x218*/ u32 unk218; - /*0x21c*/ u32 unk21c; - /*0x220*/ u32 unk220; - /*0x224*/ u32 unk224; - /*0x228*/ u32 unk228; - /*0x22c*/ u32 unk22c; - /*0x230*/ u32 unk230; - /*0x234*/ u32 unk234; - /*0x238*/ u32 unk238; - /*0x23c*/ u32 unk23c; - /*0x240*/ u32 unk240; - /*0x244*/ u32 unk244; - /*0x248*/ u32 unk248; - /*0x24c*/ u32 unk24c; - /*0x250*/ u32 unk250; - /*0x254*/ u32 unk254; - /*0x258*/ u32 unk258; - /*0x25c*/ u32 unk25c; - /*0x260*/ u32 unk260; - /*0x264*/ u32 unk264; - /*0x268*/ u32 unk268; - /*0x26c*/ u32 unk26c; - /*0x270*/ u32 unk270; - /*0x274*/ u32 unk274; - /*0x278*/ u32 unk278; - /*0x27c*/ u32 unk27c; - /*0x280*/ u32 unk280; - /*0x284*/ u32 unk284; - /*0x288*/ u32 unk288; - /*0x28c*/ u32 unk28c; - /*0x290*/ u32 unk290; - /*0x294*/ u32 unk294; - /*0x298*/ u32 unk298; - /*0x29c*/ u32 unk29c; - /*0x2a0*/ u32 unk2a0; - /*0x2a4*/ u32 unk2a4; - /*0x2a8*/ u32 unk2a8; - /*0x2ac*/ u32 unk2ac; - /*0x2b0*/ u32 unk2b0; - /*0x2b4*/ u32 unk2b4; - /*0x2b8*/ u32 unk2b8; - /*0x2bc*/ u32 unk2bc; - /*0x2c0*/ u32 unk2c0; - /*0x2c4*/ u32 unk2c4; - /*0x2c8*/ u32 unk2c8; - /*0x2cc*/ u32 unk2cc; - /*0x2d0*/ u32 unk2d0; - /*0x2d4*/ u32 unk2d4; - /*0x2d8*/ u32 unk2d8; - /*0x2dc*/ u32 unk2dc; - /*0x2e0*/ u32 unk2e0; - /*0x2e4*/ u32 unk2e4; - /*0x2e8*/ u32 unk2e8; - /*0x2ec*/ u32 unk2ec; - /*0x2f0*/ u32 unk2f0; - /*0x2f4*/ u32 unk2f4; - /*0x2f8*/ u32 unk2f8; - /*0x2fc*/ u32 unk2fc; - /*0x300*/ u32 unk300; - /*0x304*/ u32 unk304; - /*0x308*/ u32 unk308; - /*0x30c*/ u32 unk30c; - /*0x310*/ u32 unk310; - /*0x314*/ u32 unk314; - /*0x318*/ u32 unk318; - /*0x31c*/ u32 unk31c; - /*0x320*/ u32 unk320; - /*0x324*/ u32 unk324; - /*0x328*/ u32 unk328; - /*0x32c*/ u32 unk32c; - /*0x330*/ u32 unk330; - /*0x334*/ u32 unk334; - /*0x338*/ u32 unk338; - /*0x33c*/ u32 unk33c; - /*0x340*/ u32 unk340; - /*0x344*/ u32 unk344; - /*0x348*/ u32 unk348; - /*0x34c*/ u32 unk34c; - /*0x350*/ u32 unk350; - /*0x354*/ u32 unk354; - /*0x358*/ u32 unk358; - /*0x35c*/ u32 unk35c; - /*0x360*/ u32 unk360; - /*0x364*/ u32 unk364; - /*0x368*/ u32 unk368; - /*0x36c*/ u32 unk36c; - /*0x370*/ u32 unk370; - /*0x374*/ u32 unk374; - /*0x378*/ u32 unk378; - /*0x37c*/ u32 unk37c; - /*0x380*/ u32 unk380; - /*0x384*/ u32 unk384; - /*0x388*/ u32 unk388; - /*0x38c*/ u32 unk38c; - /*0x390*/ u32 unk390; - /*0x394*/ u32 unk394; - /*0x398*/ u32 unk398; - /*0x39c*/ u32 unk39c; - /*0x3a0*/ u32 unk3a0; - /*0x3a4*/ u32 unk3a4; - /*0x3a8*/ u32 unk3a8; - /*0x3ac*/ u32 unk3ac; - /*0x3b0*/ u32 unk3b0; - /*0x3b4*/ u32 unk3b4; - /*0x3b8*/ u32 unk3b8; - /*0x3bc*/ u32 unk3bc; - /*0x3c0*/ u32 unk3c0; - /*0x3c4*/ u32 unk3c4; - /*0x3c8*/ u32 unk3c8; - /*0x3cc*/ u32 unk3cc; - /*0x3d0*/ u32 unk3d0; - /*0x3d4*/ u32 unk3d4; - /*0x3d8*/ u32 unk3d8; - /*0x3dc*/ u32 unk3dc; - /*0x3e0*/ u32 unk3e0; - /*0x3e4*/ u32 unk3e4; - /*0x3e8*/ u32 unk3e8; - /*0x3ec*/ u32 unk3ec; - /*0x3f0*/ u32 unk3f0; - /*0x3f4*/ u32 unk3f4; - /*0x3f8*/ u32 unk3f8; - /*0x3fc*/ u32 unk3fc; - /*0x400*/ u32 unk400; - /*0x404*/ u32 unk404; - /*0x408*/ u32 unk408; - /*0x40c*/ u32 unk40c; - /*0x410*/ u32 unk410; - /*0x414*/ u32 unk414; - /*0x418*/ u32 unk418; - /*0x41c*/ u32 unk41c; - /*0x420*/ u32 unk420; - /*0x424*/ u32 unk424; - /*0x428*/ u32 unk428; - /*0x42c*/ u32 unk42c; - /*0x430*/ u32 unk430; - /*0x434*/ u32 unk434; - /*0x438*/ u32 unk438; - /*0x43c*/ u32 unk43c; - /*0x440*/ u32 unk440; - /*0x444*/ u32 unk444; - /*0x448*/ u32 unk448; - /*0x44c*/ u32 unk44c; - /*0x450*/ u32 unk450; - /*0x454*/ u32 unk454; - /*0x458*/ u32 unk458; - /*0x45c*/ u32 unk45c; - /*0x460*/ u32 unk460; - /*0x464*/ u32 unk464; - /*0x468*/ u32 unk468; - /*0x46c*/ u32 unk46c; - /*0x470*/ u32 unk470; - /*0x474*/ u32 unk474; - /*0x478*/ u32 unk478; - /*0x47c*/ u32 unk47c; - /*0x480*/ u32 unk480; - /*0x484*/ u32 unk484; - /*0x488*/ u32 unk488; - /*0x48c*/ u32 unk48c; - /*0x490*/ u32 unk490; - /*0x494*/ u32 unk494; - /*0x498*/ u32 unk498; - /*0x49c*/ u32 unk49c; - /*0x4a0*/ u32 unk4a0; - /*0x4a4*/ u32 unk4a4; - /*0x4a8*/ u32 unk4a8; - /*0x4ac*/ u32 unk4ac; - /*0x4b0*/ u32 unk4b0; - /*0x4b4*/ u32 unk4b4; - /*0x4b8*/ u32 unk4b8; - /*0x4bc*/ u32 unk4bc; - /*0x4c0*/ u32 unk4c0; - /*0x4c4*/ u32 unk4c4; - /*0x4c8*/ u32 unk4c8; - /*0x4cc*/ u32 unk4cc; - /*0x4d0*/ u32 unk4d0; - /*0x4d4*/ u32 unk4d4; - /*0x4d8*/ u32 unk4d8; - /*0x4dc*/ u32 unk4dc; - /*0x4e0*/ u32 unk4e0; - /*0x4e4*/ u32 unk4e4; - /*0x4e8*/ u32 unk4e8; - /*0x4ec*/ u32 unk4ec; - /*0x4f0*/ u32 unk4f0; - /*0x4f4*/ u32 unk4f4; - /*0x4f8*/ u32 unk4f8; - /*0x4fc*/ u32 unk4fc; - /*0x500*/ u32 unk500; - /*0x504*/ u32 unk504; - /*0x508*/ u32 unk508; - /*0x50c*/ u32 unk50c; - /*0x510*/ u32 unk510; - /*0x514*/ u32 unk514; - /*0x518*/ u32 unk518; - /*0x51c*/ u32 unk51c; - /*0x520*/ u32 unk520; - /*0x524*/ u32 unk524; - /*0x528*/ u32 unk528; - /*0x52c*/ f32 unk52c; - /*0x530*/ f32 unk530; - /*0x534*/ f32 unk534; - /*0x538*/ f32 unk538; - /*0x53c*/ f32 unk53c; - /*0x540*/ f32 unk540; - /*0x544*/ f32 unk544; - /*0x548*/ u32 unk548; - /*0x54c*/ u32 unk54c; - /*0x550*/ u32 unk550; - /*0x554*/ f32 hudpiecex; // screen coords of the base of the stem - usually off-screen - /*0x558*/ f32 hudpiecey; - /*0x55c*/ f32 unk55c; - /*0x560*/ f32 unk560; - /*0x564*/ f32 unk564; - /*0x568*/ f32 unk568; - /*0x56c*/ f32 unk56c; - /*0x570*/ u32 unk570; - /*0x574*/ u32 unk574; - /*0x578*/ u32 unk578; - /*0x57c*/ u32 unk57c; - /*0x580*/ u32 unk580; - /*0x584*/ u32 unk584; - /*0x588*/ u32 unk588; - /*0x58c*/ u32 unk58c; - /*0x590*/ u32 unk590; - /*0x594*/ u32 unk594; - /*0x598*/ u32 unk598; - /*0x59c*/ u32 unk59c; - /*0x5a0*/ u32 unk5a0; - /*0x5a4*/ u32 unk5a4; - /*0x5a8*/ u32 unk5a8; - /*0x5ac*/ u32 unk5ac; - /*0x5b0*/ u32 unk5b0; - /*0x5b4*/ u32 unk5b4; - /*0x5b8*/ u32 unk5b8; - /*0x5bc*/ u32 unk5bc; - /*0x5c0*/ u32 unk5c0; - /*0x5c4*/ u32 unk5c4; - /*0x5c8*/ u32 unk5c8; - /*0x5cc*/ u8 unk5cc; - /*0x5cd*/ u8 unk5cd_01 : 1; - /*0x5cd*/ u8 unk5cd_02 : 1; - /*0x5cd*/ u8 unk5cd_03 : 1; - /*0x5cd*/ u8 unk5cd_04 : 1; - /*0x5d0*/ u32 unk5d0; + /*0x01c*/ struct menu840 unk01c; /*0x5d4*/ u8 unk5d4; /*0x5d5*/ u8 unk5d5_01 : 1; /*0x5d5*/ u8 unk5d5_02 : 1; @@ -5817,26 +5398,6 @@ struct animsummary { /*0x0b*/ u8 flags; }; -struct objticksp476 { - /*0x00*/ Mtxf *matrix; - /*0x04*/ u32 unk04; - /*0x08*/ u32 unk08; - /*0x0c*/ u32 unk0c; - /*0x10*/ Mtxf *unk10; - /*0x14*/ u32 unk14; - /*0x18*/ u32 unk18; - /*0x1c*/ u32 unk1c; - /*0x20*/ u32 unk20; - /*0x24*/ u32 unk24; - /*0x28*/ u32 unk28; - /*0x2c*/ u32 unk2c; - /*0x30*/ u32 unk30; - /*0x34*/ u32 unk34; - /*0x38*/ u32 unk38; - /*0x3c*/ u32 unk3c; -}; - -// Suspected to be the same as objticksp476 struct modelrenderdata { /*0x00*/ Mtxf *unk00; /*0x04*/ bool zbufferenabled; diff --git a/src/lib/model.c b/src/lib/model.c index dd0f9a122..4636255f1 100644 --- a/src/lib/model.c +++ b/src/lib/model.c @@ -655,7 +655,7 @@ void model0001b3bc(struct model *model) } } -void model0001b400(struct objticksp476 *arg0, struct model *model, struct modelnode *node) +void model0001b400(struct modelrenderdata *arg0, struct model *model, struct modelnode *node) { struct anim *anim = model->anim; union modelrodata *rodata = node->rodata; @@ -698,7 +698,7 @@ void model0001b400(struct objticksp476 *arg0, struct model *model, struct modeln if (node->parent) { sp24c = model0001a5cc(model, node->parent, 0); } else { - sp24c = arg0->matrix; + sp24c = arg0->unk00; } anim00024050(sp240, anim->flip, skel, anim->animnum, anim->unk04, &sp230, &sp224, &sp218); @@ -2172,7 +2172,7 @@ glabel model0001bfa8 ); #endif -void model0001c5b4(struct objticksp476 *arg0, struct model *model, struct modelnode *node) +void model0001c5b4(struct modelrenderdata *arg0, struct model *model, struct modelnode *node) { union modelrodata *rodata = node->rodata; Mtxf *sp68; @@ -2183,7 +2183,7 @@ void model0001c5b4(struct objticksp476 *arg0, struct model *model, struct modeln if (node->parent) { sp68 = model0001a5cc(model, node->parent, 0); } else { - sp68 = arg0->matrix; + sp68 = arg0->unk00; } if (sp68) { @@ -2472,7 +2472,7 @@ void model0001cc20(struct model *model) } } -void model0001cd18(struct objticksp476 *arg0, struct model *model) +void model0001cd18(struct modelrenderdata *arg0, struct model *model) { struct modelnode *node = model->filedata->rootnode; @@ -2521,7 +2521,7 @@ void model0001cd18(struct objticksp476 *arg0, struct model *model) } } -void model0001ce64(struct objticksp476 *arg0, struct model *model) +void model0001ce64(struct modelrenderdata *arg0, struct model *model) { model->matrices = arg0->unk10; @@ -2538,7 +2538,7 @@ void model0001ce64(struct objticksp476 *arg0, struct model *model) #endif } -void model0001cebc(struct objticksp476 *arg0, struct model *model) +void model0001cebc(struct modelrenderdata *arg0, struct model *model) { struct anim *anim = model->anim; f32 speed;