Skip to content

Commit

Permalink
attempt to fix demo initiate
Browse files Browse the repository at this point in the history
  • Loading branch information
EpochFlame committed Sep 27, 2023
1 parent 27fa895 commit 6fa1293
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 19 deletions.
1 change: 0 additions & 1 deletion include/JSystem/JAudio/JAI/JAISound.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
namespace JAInter {
struct Actor;
struct MoveParaSet;
struct SoundInfo;
} // namespace JAInter

/**
Expand Down
28 changes: 13 additions & 15 deletions include/JSystem/JAudio/JAI/JAInter.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,19 @@ namespace JAInter {
struct Actor;
struct DummyVec;
struct SeqUpdateData;
struct SoundInfo;
struct SoundInfo {
int unk1; // _00
union count_t {
unsigned long v1;
unsigned char v2[4];
unsigned short v3[2];
} count; // _04
f32 pitch; // _08
union volume_t {
unsigned long v1;
unsigned char v2[2];
} volume; // _0C
};

namespace SequenceMgr {
struct CustomHeapInfo {
Expand Down Expand Up @@ -284,20 +296,6 @@ struct SeqParameter : MoveParaSet {
JASOuterParam mOuterParam; // _62C
};

struct SoundInfo {
int unk1; // _00
union count_t {
unsigned long v1;
unsigned char v2[4];
unsigned short v3[2];
} count; // _04
f32 pitch; // _08
union volume_t {
unsigned long v1;
unsigned char v2[2];
} volume; // _0C
};

namespace SoundTable {
void init(u8*, u32);
SoundInfo* getInfoPointer(u32);
Expand Down
1 change: 0 additions & 1 deletion include/JSystem/JAudio/JAI/JAInter/SeMgr.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ struct Actor;
struct LinkSound;
struct MoveParaSet;
struct SeqUpdateData;
struct SoundInfo;

namespace SeMgr {
/** @fabricatedName */
Expand Down
4 changes: 2 additions & 2 deletions src/utilityU/PSMainSide_Demo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -446,7 +446,7 @@ PSSystem::BgmSeq* Demo::initiate(DemoArg demoArg, u8* unk)
init.setDefault("s11_dopebin_first_r", 0xc0011008);

if (!streq("s01_dayend", init.mName)) {
bool is_key = demoArg.mPelletName && streq(demoArg.mPelletName, "key");
bool is_key = demoArg.mName && streq(demoArg.mName, "key");

init.setDefault("s17_suck_equipment", demoArg.mBgmID, !is_key);
init.setDefault("s17_suck_equipment", 0xc0011007, is_key);
Expand Down Expand Up @@ -601,7 +601,7 @@ PSSystem::BgmSeq* Demo::initiate(DemoArg demoArg, u8* unk)
} else if (streq("x20_blackman", init.mName) || streq("x03_find_red_onyon", init.mName)) {
mDoStartWithAudio = false;
} else if (streq("s01_dayend", init.mName)) {
switch ((u32)demoArg.mPelletName) {
switch ((u32)demoArg.mName) {
case 1:
mSoundID = PSSE_PL_DAYEND_KAISAN_LUI;
break;
Expand Down

0 comments on commit 6fa1293

Please sign in to comment.