mirror of
https://github.com/Xeeynamo/sotn-decomp.git
synced 2025-02-18 12:08:16 +00:00
parent
83d5c2bea9
commit
74ac0fe998
@ -150,7 +150,7 @@ segments:
|
||||
- [0x41F48, rodata]
|
||||
- [0x41F50, .rodata, 92F60] # jtbl_800E1F50
|
||||
- [0x41F78, .rodata, 93290] # jtbl_800E1F78
|
||||
- [0x41F90, rodata] # jtbl_800E1F90
|
||||
- [0x41F90, .rodata, 93290] # CdSoundCommand12
|
||||
- [0x41FA8, .rodata, 93BDC] # CdSoundCommand14
|
||||
- [0x41FD0, .rodata, 94F50] # jtbl_800E1FD0
|
||||
- [0x42270, .rodata, 953A0]
|
||||
|
@ -159,7 +159,7 @@ segments:
|
||||
- [0x4202C, rodata]
|
||||
- [0x42034, .rodata, 92F60] # CdSoundCommand4
|
||||
- [0x4205C, .rodata, 93290] # CdSoundCommand6
|
||||
- [0x42074, rodata] # CdSoundCommand12
|
||||
- [0x42074, .rodata, 93290] # CdSoundCommand12
|
||||
- [0x4208C, .rodata, 93BDC] # CdSoundCommand14
|
||||
- [0x420B4, .rodata, 94F50] # func_80134F50
|
||||
- [0x42354, .rodata, 953A0]
|
||||
|
@ -198,5 +198,71 @@ bool CdSoundCommandQueueEmpty(void) { return g_CdSoundCommandQueuePos == 0; }
|
||||
|
||||
bool func_80133950(void) { return D_8013980C == 0; }
|
||||
|
||||
INCLUDE_ASM("dra/nonmatchings/93290", CdSoundCommand12);
|
||||
void CdSoundCommand12();
|
||||
void CdSoundCommand12(void) {
|
||||
s32 temp_a2;
|
||||
s32 i;
|
||||
s32 var_t0;
|
||||
|
||||
switch (g_CdSoundCommandStep) {
|
||||
case 0:
|
||||
if (g_CdSoundCommand16 >= 2) {
|
||||
g_CdSoundCommand16 = 0;
|
||||
}
|
||||
if (D_8013901C == 0) {
|
||||
D_8013980C = 0;
|
||||
AdvanceCdSoundCommandQueue();
|
||||
return;
|
||||
}
|
||||
D_801390A0 = 1;
|
||||
g_CdSoundCommandStep++;
|
||||
break;
|
||||
case 1:
|
||||
if (g_CdVolume <= 0 || (g_CdVolume -= 0xC, g_CdVolume <= 0)) {
|
||||
g_CdVolume = 0;
|
||||
}
|
||||
SetCdVolume(0, g_CdVolume, g_CdVolume);
|
||||
if (g_CdVolume == 0) {
|
||||
g_CdSoundCommandStep++;
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
if (DoCdCommand(CdlGetlocL, NULL, D_8013B688) == 0) {
|
||||
g_CdSoundCommandStep++;
|
||||
}
|
||||
break;
|
||||
case 3:
|
||||
temp_a2 = VSync(-1);
|
||||
for (i = 0; i < 8; i++) {
|
||||
D_8013B5F4[g_CdSoundCommand16].unk0[i] = D_8013B688[i];
|
||||
}
|
||||
var_t0 = D_8013AE90 - (temp_a2 - D_8013AEF4);
|
||||
if (var_t0 <= 0) {
|
||||
var_t0 = 1;
|
||||
}
|
||||
|
||||
D_8013B5F4[g_CdSoundCommand16].unk8 = var_t0;
|
||||
D_8013B5F4[g_CdSoundCommand16].unkc = D_8013901C;
|
||||
D_8013B5F4[g_CdSoundCommand16].unke = D_80139014;
|
||||
SsSetSerialAttr(0, 0, 0);
|
||||
if (DoCdCommand(CdlPause, NULL, NULL) == 0) {
|
||||
g_CdSoundCommandStep++;
|
||||
}
|
||||
break;
|
||||
case 4:
|
||||
D_8013901C = 0;
|
||||
D_801390A0 = 0;
|
||||
D_8013980C = 0;
|
||||
g_CdSoundCommandStep = 0;
|
||||
g_CdSoundCommand16 += 1;
|
||||
AdvanceCdSoundCommandQueue();
|
||||
break;
|
||||
default:
|
||||
g_CdSoundCommandStep = 0;
|
||||
D_8013980C = 0;
|
||||
D_801390A0 = g_CdSoundCommandStep;
|
||||
AdvanceCdSoundCommandQueue();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
const u32 padding_CdSoundCommand12 = 0;
|
||||
|
@ -2,19 +2,9 @@
|
||||
#include "objects.h"
|
||||
#include "sfx.h"
|
||||
|
||||
struct Cmd14 {
|
||||
u8 unk0[8];
|
||||
s32 unk8;
|
||||
s16 unkc;
|
||||
s8 unke;
|
||||
};
|
||||
|
||||
extern s32 D_8013AE90;
|
||||
extern s32 D_8013AEF4;
|
||||
|
||||
extern u8 D_8013B688[];
|
||||
extern struct Cmd14 D_8013B5F4[];
|
||||
|
||||
void CdSoundCommand14(void) {
|
||||
s32 i;
|
||||
|
||||
|
@ -341,6 +341,13 @@ struct XaMusicConfig {
|
||||
u8 pad[3];
|
||||
};
|
||||
|
||||
struct Cmd14 {
|
||||
u8 unk0[8];
|
||||
s32 unk8;
|
||||
s16 unkc;
|
||||
s8 unke;
|
||||
};
|
||||
|
||||
// Used for the button combos to signal successfully completing the sequence
|
||||
#define COMBO_COMPLETE 0xFF
|
||||
|
||||
@ -847,6 +854,8 @@ extern void (*D_80170000)(s32 arg0);
|
||||
extern ImgSrc* g_imgUnk8013C200;
|
||||
extern ImgSrc* g_imgUnk8013C270;
|
||||
extern u8 D_801EC000[];
|
||||
extern u8 D_8013B688[];
|
||||
extern struct Cmd14 D_8013B5F4[];
|
||||
|
||||
void InitializePads(void);
|
||||
void ReadPads(void);
|
||||
|
Loading…
x
Reference in New Issue
Block a user