mirror of
https://github.com/encounter/tp.git
synced 2026-07-11 06:18:46 -07:00
Z2AudioLib work (#2339)
* Z2LinkMgr work, Z2AudioArcLoader matching * Z2SeMgr matching * Z2SpeechMgr2 almost done, Z2SoundHandles matching
This commit is contained in:
@@ -3,6 +3,7 @@ CompileFlags:
|
||||
Diagnostics:
|
||||
Suppress:
|
||||
- "warn_char_constant_too_large"
|
||||
- "illegal_union_or_anon_struct_member"
|
||||
---
|
||||
If:
|
||||
PathMatch: .*/*.inc
|
||||
|
||||
@@ -2067,7 +2067,7 @@ JSystem/JAudio2/osdsp.cpp:
|
||||
JSystem/JAudio2/osdsp_task.cpp:
|
||||
.text start:0x8029EB20 end:0x8029EFAC
|
||||
.bss start:0x80434060 end:0x80434078
|
||||
.sbss start:0x80451308 end:0x80451330
|
||||
.sbss start:0x80451308 end:0x80451310
|
||||
|
||||
JSystem/JAudio2/JAIAudible.cpp:
|
||||
.text start:0x8029EFAC end:0x8029EFF4
|
||||
@@ -2087,6 +2087,7 @@ JSystem/JAudio2/JAISeMgr.cpp:
|
||||
.rodata start:0x8039B8F8 end:0x8039B910
|
||||
.data start:0x803C98B0 end:0x803C98D8
|
||||
.bss start:0x80434078 end:0x80434098
|
||||
.sbss start:0x80451310 end:0x80451320
|
||||
.sdata2 start:0x80455788 end:0x80455798
|
||||
|
||||
JSystem/JAudio2/JAISeq.cpp:
|
||||
@@ -2103,6 +2104,7 @@ JSystem/JAudio2/JAISeqMgr.cpp:
|
||||
.text start:0x802A1804 end:0x802A2184
|
||||
.data start:0x803C9958 end:0x803C9970
|
||||
.bss start:0x804340C0 end:0x804340E0
|
||||
.sbss start:0x80451320 end:0x80451328
|
||||
.sdata2 start:0x804557A8 end:0x804557B8
|
||||
|
||||
JSystem/JAudio2/JAISound.cpp:
|
||||
@@ -2143,6 +2145,7 @@ JSystem/JAudio2/JAIStreamDataMgr.cpp:
|
||||
JSystem/JAudio2/JAIStreamMgr.cpp:
|
||||
.text start:0x802A3B68 end:0x802A4244
|
||||
.bss start:0x804340F0 end:0x80434110
|
||||
.sbss start:0x80451328 end:0x80451330
|
||||
.sdata2 start:0x80455800 end:0x80455810
|
||||
|
||||
JSystem/JAudio2/JAUAudioArcInterpreter.cpp:
|
||||
@@ -2216,7 +2219,7 @@ Z2AudioLib/Z2Calc.cpp:
|
||||
|
||||
Z2AudioLib/Z2Param.cpp:
|
||||
.sdata start:0x804507D8 end:0x80450870
|
||||
.sbss start:0x80451338 end:0x80451350
|
||||
.sbss start:0x80451338 end:0x80451348
|
||||
|
||||
Z2AudioLib/Z2AudioArcLoader.cpp:
|
||||
.text start:0x802A9A34 end:0x802A9B58
|
||||
@@ -2238,6 +2241,7 @@ Z2AudioLib/Z2SoundStarter.cpp:
|
||||
Z2AudioLib/Z2SoundHandles.cpp:
|
||||
.text start:0x802AB07C end:0x802AB64C
|
||||
.bss start:0x804341B8 end:0x804341D8
|
||||
.sbss start:0x80451348 end:0x80451350
|
||||
|
||||
Z2AudioLib/Z2SeMgr.cpp:
|
||||
.text start:0x802AB64C end:0x802AEEA0
|
||||
|
||||
@@ -21177,10 +21177,10 @@ memPool_$localstatic3$getMemPool___26JASPoolAllocObject<5JAISe>Fv = .bss:0x80434
|
||||
@896 = .bss:0x804340A4; // type:object size:0xC scope:local align:4
|
||||
memPool_$localstatic3$getMemPool___35JASPoolAllocObject<13JAISoundChild>Fv = .bss:0x804340B0; // type:object size:0x10 scope:local align:4
|
||||
@715 = .bss:0x804340C0; // type:object size:0xC scope:local align:4
|
||||
memPool_$localstatic3$getMemPool___27JASPoolAllocObject<6JAISeq>Fv = .bss:0x804340CC; // type:object size:0x10 scope:local align:4
|
||||
memPool_$localstatic3$getMemPool___27JASPoolAllocObject<6JAISeq>Fv = .bss:0x804340CC; // type:object size:0x10 scope:weak align:4
|
||||
@881 = .bss:0x804340E0; // type:object size:0xC scope:local align:4
|
||||
@745 = .bss:0x804340F0; // type:object size:0xC scope:local align:4
|
||||
memPool_$localstatic3$getMemPool___30JASPoolAllocObject<9JAIStream>Fv = .bss:0x804340FC; // type:object size:0x10 scope:local align:4
|
||||
memPool_$localstatic3$getMemPool___30JASPoolAllocObject<9JAIStream>Fv = .bss:0x804340FC; // type:object size:0x10 scope:weak align:4
|
||||
...bss.0 = .bss:0x80434110; // type:label scope:local
|
||||
@757 = .bss:0x80434110; // type:object size:0xC scope:local align:4
|
||||
@763 = .bss:0x8043411C; // type:object size:0xC scope:local align:4
|
||||
@@ -21189,7 +21189,7 @@ memPool_$localstatic3$getMemPool___30JASPoolAllocObject<9JAIStream>Fv = .bss:0x8
|
||||
@863 = .bss:0x80434140; // type:object size:0xC scope:local align:4
|
||||
@867 = .bss:0x8043414C; // type:object size:0xC scope:local align:4
|
||||
@632 = .bss:0x804341B8; // type:object size:0xC scope:local align:4
|
||||
memPool_$localstatic3$getMemPool___39JASPoolAllocObject<17Z2SoundHandlePool>Fv = .bss:0x804341C4; // type:object size:0x10 scope:local align:4
|
||||
memPool_$localstatic3$getMemPool___39JASPoolAllocObject<17Z2SoundHandlePool>Fv = .bss:0x804341C4; // type:object size:0x10 scope:weak align:4
|
||||
@1539 = .bss:0x804341D8; // type:object size:0xC scope:local align:4
|
||||
memPool_$localstatic3$getMemPool___30JASPoolAllocObject<9Z2Audible>Fv = .bss:0x804341E4; // type:object size:0x10 scope:local align:4
|
||||
...bss.0 = .bss:0x804341F8; // type:label scope:local
|
||||
@@ -21509,7 +21509,7 @@ sStickHigh = .sdata:0x80450898; // type:object size:0x4 scope:global align:4 dat
|
||||
sStickCenter = .sdata:0x8045089C; // type:object size:0x4 scope:global align:4 data:float
|
||||
sHowlTobikusa = .sdata:0x804508A0; // type:object size:0x8 scope:global align:4
|
||||
cm2hw$539 = .sdata:0x804508A8; // type:object size:0x4 scope:local align:4
|
||||
data_804508B0 = .sdata:0x804508B0; // type:object size:0x8 scope:global align:4 data:byte
|
||||
data_804508B0 = .sdata:0x804508B0; // type:object size:0x1 scope:global align:4 data:byte
|
||||
sSZSBufferSize__7JKRAram = .sdata:0x804508B8; // type:object size:0x4 scope:global align:4 data:4byte
|
||||
rootPath$2498 = .sdata:0x804508C0; // type:object size:0x2 scope:local align:4 data:string
|
||||
errorRetry = .sdata:0x804508C8; // type:object size:0x1 scope:local align:1 data:byte
|
||||
@@ -22087,8 +22087,8 @@ struct_80451309 = .sbss:0x80451309; // type:object size:0x1 scope:local align:1
|
||||
DSP_prior_task = .sbss:0x8045130C; // type:object size:0x4 scope:global align:4 data:4byte
|
||||
data_80451310 = .sbss:0x80451310; // type:object size:0x8 scope:global align:4 data:byte
|
||||
data_80451318 = .sbss:0x80451318; // type:object size:0x8 scope:global align:4 data:byte
|
||||
data_80451320 = .sbss:0x80451320; // type:object size:0x8 scope:global align:4 data:byte
|
||||
data_80451328 = .sbss:0x80451328; // type:object size:0x8 scope:global align:4 data:byte
|
||||
init$localstatic4$getMemPool___27JASPoolAllocObject<6JAISeq>Fv = .sbss:0x80451320; // type:object size:0x1 scope:global align:1 data:byte
|
||||
init$localstatic4$getMemPool___30JASPoolAllocObject<9JAIStream>Fv = .sbss:0x80451328; // type:object size:0x1 scope:global align:1 data:byte
|
||||
init$80 = .sbss:0x80451330; // type:object size:0x1 scope:local align:1 data:byte
|
||||
oRandom$401 = .sbss:0x80451334; // type:object size:0x4 scope:local align:4 data:4byte
|
||||
MIN_DISTANCE_VOLUME__7Z2Param = .sbss:0x80451338; // type:object size:0x4 scope:global align:4 data:float
|
||||
@@ -22097,7 +22097,7 @@ struct_80451340 = .sbss:0x80451340; // type:object size:0x1 scope:global align:1
|
||||
struct_80451341 = .sbss:0x80451341; // type:object size:0x1 scope:global align:1 data:byte
|
||||
struct_80451342 = .sbss:0x80451342; // type:object size:0x1 scope:global align:1 data:byte
|
||||
pad_80451344 = .sbss:0x80451344; // type:object size:0x4 scope:global align:4
|
||||
data_80451348 = .sbss:0x80451348; // type:object size:0x8 scope:global align:4 data:byte
|
||||
init$localstatic4$getMemPool___39JASPoolAllocObject<17Z2SoundHandlePool>Fv = .sbss:0x80451348; // type:object size:0x1 scope:global align:1 data:byte
|
||||
cNearFarRatio = .sbss:0x80451350; // type:object size:0x4 scope:local align:4 data:float
|
||||
data_80451354 = .sbss:0x80451354; // type:object size:0x4 scope:global align:4 data:byte
|
||||
data_80451358 = .sbss:0x80451358; // type:object size:0x1 scope:global align:1 data:byte
|
||||
|
||||
+12
-12
@@ -823,7 +823,7 @@ config.libs = [
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JASProbe.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JASReport.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JASCmdStack.cpp"),
|
||||
Object(NonMatching, "JSystem/JAudio2/JASTrack.cpp"),
|
||||
Object(NonMatching, "JSystem/JAudio2/JASTrack.cpp", extra_cflags=['-pragma "nosyminline off"']),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JASTrackPort.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JASRegisterParam.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JASSeqCtrl.cpp"),
|
||||
@@ -840,7 +840,7 @@ config.libs = [
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JASWSParser.cpp"),
|
||||
Object(NonMatching, "JSystem/JAudio2/JASBNKParser.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JASWaveArcLoader.cpp", extra_cflags=['-pragma "nosyminline off"']),
|
||||
Object(NonMatching, "JSystem/JAudio2/JASChannel.cpp", extra_cflags=['-pragma "nosyminline off"']),
|
||||
Object(Equivalent, "JSystem/JAudio2/JASChannel.cpp", extra_cflags=['-pragma "nosyminline off"']), # bss locations
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JASLfo.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JASOscillator.cpp"),
|
||||
Object(NonMatching, "JSystem/JAudio2/JASAiCtrl.cpp"),
|
||||
@@ -857,25 +857,25 @@ config.libs = [
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAIAudible.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAIAudience.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAISe.cpp"),
|
||||
Object(NonMatching, "JSystem/JAudio2/JAISeMgr.cpp"),
|
||||
Object(NonMatching, "JSystem/JAudio2/JAISeq.cpp"),
|
||||
Object(Equivalent, "JSystem/JAudio2/JAISeMgr.cpp", extra_cflags=['-pragma "nosyminline off"']), # weak function order
|
||||
Object(Equivalent, "JSystem/JAudio2/JAISeq.cpp", extra_cflags=['-pragma "nosyminline off"']), # bss locations
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAISeqDataMgr.cpp"),
|
||||
Object(NonMatching, "JSystem/JAudio2/JAISeqMgr.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAISeqMgr.cpp", extra_cflags=['-pragma "nosyminline off"']),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAISound.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAISoundChild.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAISoundHandles.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAISoundInfo.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAISoundParams.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAISoundStarter.cpp"),
|
||||
Object(NonMatching, "JSystem/JAudio2/JAIStream.cpp", extra_cflags=["-sym off"]),
|
||||
Object(Equivalent, "JSystem/JAudio2/JAIStream.cpp", extra_cflags=['-pragma "nosyminline off"']), # bss locations
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAIStreamDataMgr.cpp"),
|
||||
Object(NonMatching, "JSystem/JAudio2/JAIStreamMgr.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAIStreamMgr.cpp", extra_cflags=['-pragma "nosyminline off"']),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAUAudioArcInterpreter.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAUAudioArcLoader.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAUAudioMgr.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAUBankTable.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAUClusterSound.cpp"),
|
||||
Object(NonMatching, "JSystem/JAudio2/JAUInitializer.cpp"),
|
||||
Object(Equivalent, "JSystem/JAudio2/JAUInitializer.cpp", extra_cflags=['-pragma "nosyminline off"']), # bss locations
|
||||
Object(NonMatching, "JSystem/JAudio2/JAUSectionHeap.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAUSeqCollection.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "JSystem/JAudio2/JAUSeqDataBlockMgr.cpp"),
|
||||
@@ -902,12 +902,12 @@ config.libs = [
|
||||
"host": True,
|
||||
"objects": [
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2Calc.cpp"),
|
||||
Object(NonMatching, "Z2AudioLib/Z2AudioArcLoader.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2AudioArcLoader.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2Param.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2SoundMgr.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2SoundStarter.cpp"),
|
||||
Object(NonMatching, "Z2AudioLib/Z2SoundHandles.cpp"),
|
||||
Object(NonMatching, "Z2AudioLib/Z2SeMgr.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2SoundHandles.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2SeMgr.cpp"),
|
||||
Object(NonMatching, "Z2AudioLib/Z2SeqMgr.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2StatusMgr.cpp"),
|
||||
Object(NonMatching, "Z2AudioLib/Z2SceneMgr.cpp"),
|
||||
@@ -917,7 +917,7 @@ config.libs = [
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2SoundObject.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2SoundObjMgr.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2Creature.cpp"),
|
||||
Object(NonMatching, "Z2AudioLib/Z2LinkMgr.cpp"),
|
||||
Object(NonMatching, "Z2AudioLib/Z2LinkMgr.cpp", extra_cflags=['-pragma "nosyminline on"']),
|
||||
Object(NonMatching, "Z2AudioLib/Z2EnvSeMgr.cpp"),
|
||||
Object(MatchingFor("GZ2E01"), "Z2AudioLib/Z2WolfHowlMgr.cpp"),
|
||||
Object(NonMatching, "Z2AudioLib/Z2SpeechMgr2.cpp"),
|
||||
|
||||
@@ -49,7 +49,12 @@ public:
|
||||
/* 8029FE78 */ void stopSoundID(JAISoundID);
|
||||
/* 8029FEEC */ void pause(bool);
|
||||
/* 8029FF18 */ void JAISeMgr_mixOut_(JAISoundParamsMove const&, JAISoundActivity);
|
||||
/* 802A0994 */ JAISeCategoryMgr();
|
||||
/* 802A0994 */ JAISeCategoryMgr() {
|
||||
mParams.init();
|
||||
mMaxActiveSe = 0;
|
||||
mMaxInactiveSe = 0;
|
||||
field_0x4.field_0x0 = 0;
|
||||
}
|
||||
|
||||
/* 800078DC */ virtual ~JAISeCategoryMgr() {}
|
||||
/* 8029F8B0 */ virtual bool isUsingSeqData(JAISeqDataRegion const&);
|
||||
|
||||
@@ -241,23 +241,23 @@ template <typename T>
|
||||
class JASPoolAllocObject {
|
||||
public:
|
||||
static void* operator new(size_t n) {
|
||||
JASMemPool<T>* memPool = getMemPool();
|
||||
JASMemPool<T>* memPool = getMemPool_();
|
||||
return memPool->alloc(sizeof(T));
|
||||
}
|
||||
static void* operator new(size_t n, void* ptr) {
|
||||
return ptr;
|
||||
}
|
||||
static void operator delete(void* ptr, size_t n) {
|
||||
JASMemPool<T>* memPool_ = getMemPool();
|
||||
JASMemPool<T>* memPool_ = getMemPool_();
|
||||
memPool_->free(ptr, sizeof(T));
|
||||
}
|
||||
static void newMemPool(int param_0) {
|
||||
JASMemPool<T>* memPool_ = getMemPool();
|
||||
JASMemPool<T>* memPool_ = getMemPool_();
|
||||
memPool_->newMemPool(param_0);
|
||||
}
|
||||
|
||||
private:
|
||||
static JASMemPool<T>* getMemPool() {
|
||||
static JASMemPool<T>* getMemPool_() {
|
||||
static JASMemPool<T> memPool_;
|
||||
return &memPool_;
|
||||
}
|
||||
|
||||
@@ -169,7 +169,17 @@ struct JASTrack : public JASPoolAllocObject_MultiThreaded<JASTrack> {
|
||||
/* 0x000 */ JASSeqCtrl mSeqCtrl;
|
||||
/* 0x05C */ JASTrackPort mTrackPort;
|
||||
/* 0x080 */ JASRegisterParam mRegisterParam;
|
||||
/* 0x09C */ MoveParam_ mMoveParam[6]; // volume, pitch, fxmix, pan, dolby, distFilter
|
||||
/* 0x09C */ union {
|
||||
struct {
|
||||
MoveParam_ volume;
|
||||
MoveParam_ pitch;
|
||||
MoveParam_ fxmix;
|
||||
MoveParam_ pan;
|
||||
MoveParam_ dolby;
|
||||
MoveParam_ distFilter;
|
||||
} params;
|
||||
MoveParam_ array[6];
|
||||
} mMoveParam;
|
||||
/* 0x0e4 */ JASOscillator::Data mOscParam[2];
|
||||
/* 0x114 */ JASOscillator::Point mOscPoint[4];
|
||||
/* 0x12C */ JASTrack* mParent;
|
||||
|
||||
@@ -22,7 +22,9 @@ public:
|
||||
|
||||
struct TNodeLinkList {
|
||||
struct iterator {
|
||||
iterator() { node = NULL; }
|
||||
explicit iterator(TLinkListNode* pNode) { node = pNode; }
|
||||
iterator& operator=(const iterator& other) { node = other.node; return *this; }
|
||||
|
||||
iterator& operator++() { node = node->getNext(); return *this; }
|
||||
iterator& operator--() { node = node->getPrev(); return *this; }
|
||||
@@ -117,6 +119,7 @@ struct TLinkList : public TNodeLinkList {
|
||||
TLinkList() : TNodeLinkList() {}
|
||||
|
||||
struct iterator {
|
||||
iterator() {}
|
||||
explicit iterator(TNodeLinkList::iterator iter) : base(iter) {}
|
||||
|
||||
iterator& operator++() {
|
||||
|
||||
@@ -238,6 +238,11 @@ inline bool JKRRemoveResource(void* resource, JKRFileLoader* fileLoader) {
|
||||
return JKRFileLoader::removeResource(resource, fileLoader);
|
||||
}
|
||||
|
||||
inline JKRArchive* JKRMountArchive(void* ptr, JKRHeap* heap,
|
||||
JKRArchive::EMountDirection mountDirection) {
|
||||
return JKRArchive::mount(ptr, heap, mountDirection);
|
||||
}
|
||||
|
||||
inline void JKRUnmountArchive(JKRArchive* arc) {
|
||||
arc->unmount();
|
||||
}
|
||||
@@ -246,4 +251,4 @@ inline void JKRReadIdxResource(void* param_1, u32 param_2, u32 param_3, JKRArchi
|
||||
param_4->readIdxResource(param_1, param_2, param_3);
|
||||
}
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -12,7 +12,7 @@ void JMAVECScaleAdd(register const Vec* vec1, register const Vec* vec2, register
|
||||
register f32 scale);
|
||||
|
||||
inline int JMAAbs(int value) {
|
||||
return (value >> 0x1f ^ value) - (value >> 0x1f);
|
||||
return value > 0 ? value : -value;
|
||||
}
|
||||
|
||||
inline f32 JMAFastReciprocal(f32 value) {
|
||||
|
||||
@@ -20,7 +20,7 @@ struct TRandom_fast_ {
|
||||
|
||||
u32 get_bit32(void) { return this->get(); }
|
||||
|
||||
s8 get_uint8(u8 param_0) {
|
||||
u8 get_uint8(u8 param_0) {
|
||||
return get_ufloat_1() * param_0;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
#ifndef Z2CREATURE_H
|
||||
#define Z2CREATURE_H
|
||||
|
||||
#include "SSystem/SComponent/c_xyz.h"
|
||||
#include "Z2AudioLib/Z2SoundObject.h"
|
||||
#include "Z2AudioLib/Z2SoundStarter.h"
|
||||
|
||||
@@ -35,122 +34,6 @@ public:
|
||||
/* 0x70 */ Z2SoundObjSimple mSoundObjSimple2;
|
||||
}; // Size: 0x90
|
||||
|
||||
struct Z2LinkSoundStarter : public Z2SoundStarter {
|
||||
Z2LinkSoundStarter();
|
||||
|
||||
inline virtual ~Z2LinkSoundStarter();
|
||||
virtual bool startSound(JAISoundID, JAISoundHandle*, JGeometry::TVec3<f32> const*, u32, f32,
|
||||
f32, f32, f32, f32, u32);
|
||||
};
|
||||
|
||||
class Z2CreatureLink : public Z2Creature, public Z2LinkSoundStarter {
|
||||
public:
|
||||
Z2CreatureLink();
|
||||
~Z2CreatureLink();
|
||||
|
||||
void setLinkState(u8);
|
||||
void setLinkGroupInfo(u8);
|
||||
void setLinkHp(s32, s32);
|
||||
void setLinkSwordType(s32, s32);
|
||||
void setLinkShieldType(s32, s32);
|
||||
void setLinkBootsType(s32);
|
||||
virtual void deleteObject();
|
||||
void init(Vec*, Vec*, Vec*);
|
||||
void initKantera(Vec*);
|
||||
void deleteKantera(void);
|
||||
void setKanteraState(u8);
|
||||
virtual void framework(u32, s8);
|
||||
void setSinkDepth(s8);
|
||||
void setRiding(bool);
|
||||
void setMagnetized(bool);
|
||||
void setWolfEyeOpen(bool);
|
||||
Z2SoundHandlePool* startLinkSound(JAISoundID, u32, s8);
|
||||
JAISoundHandle* startLinkSoundLevel(JAISoundID, u32, s8);
|
||||
void startLinkVoice(JAISoundID, s8);
|
||||
void startLinkVoiceLevel(JAISoundID, s8);
|
||||
void startLinkSwordSound(JAISoundID, u32, s8);
|
||||
virtual Z2SoundHandlePool* startCollisionSE(u32, u32);
|
||||
int startHitItemSE(u32, u32, Z2SoundObjBase*, float);
|
||||
void setResumeAttack(bool);
|
||||
|
||||
void setInWater(bool status) { mInWater = status; }
|
||||
bool isInWater() { return mInWater; }
|
||||
u8 getLinkState() const { return mLinkState; }
|
||||
u8 getMoveSpeed() const { return mMoveSpeed; }
|
||||
bool isRiding() const { return mRiding; }
|
||||
void i_setLinkState(u8 i_state) { mLinkState = i_state; }
|
||||
Z2SoundObjSimple& getKantera() { return mKantera; }
|
||||
u8 getLinkHp() const { return mLinkHp; }
|
||||
u8 getMovingTime() { return mMovingTime; }
|
||||
u8 isWolfSmellOpen() const { return mWolfEyeOpen; }
|
||||
void setUsingIronBall(bool i_using) { mUsingIronBall = i_using; }
|
||||
void setMarkState(u8 i_state) { mMarkState = i_state; }
|
||||
|
||||
static Z2CreatureLink* mLinkPtr;
|
||||
|
||||
private:
|
||||
/* 0x90 Z2LinkSoundStarter */
|
||||
/* 0x94 */ Z2SoundObjSimple mKantera;
|
||||
/* 0xB4 */ cXyz field_0xb4;
|
||||
/* 0xC0 */ u8 mLinkState;
|
||||
/* 0xC1 */ u8 field_0xc1;
|
||||
/* 0xC2 */ u8 mMarkState;
|
||||
/* 0xC3 */ u8 mLinkHp;
|
||||
/* 0xC4 */ u8 mLinkBootsType;
|
||||
/* 0xC5 */ u8 mKanteraState;
|
||||
/* 0xC6 */ u8 mLinkSwordType;
|
||||
/* 0xC7 */ u8 mLinkShieldType;
|
||||
/* 0xC8 */ u8 mMoveSpeed;
|
||||
/* 0xC9 */ u8 mMovingTime;
|
||||
/* 0xCA */ s8 mSinkDepth;
|
||||
/* 0xCB */ bool mWolfEyeOpen : 1;
|
||||
/* 0xCB */ bool mInWater : 1;
|
||||
/* 0xCB */ bool mResumeAttack : 1;
|
||||
/* 0xCB */ bool mFlag3 : 1;
|
||||
/* 0xCB */ bool mFlag4 : 1;
|
||||
/* 0xCB */ bool mFlag5 : 1;
|
||||
/* 0xCB */ bool mRiding : 1;
|
||||
/* 0xCB */ bool mMagnetized : 1;
|
||||
/* 0xCC */ bool mFlag8 : 1;
|
||||
/* 0xCC */ bool mUsingIronBall : 1;
|
||||
/* 0xCC */ bool mFlag10 : 1;
|
||||
/* 0xCC */ bool mFlag11 : 1;
|
||||
/* 0xCC */ bool mFlag12 : 1;
|
||||
/* 0xCC */ bool mFlag13 : 1;
|
||||
/* 0xCC */ bool mFlag14 : 1;
|
||||
/* 0xCC */ bool mFlag15 : 1;
|
||||
}; // Size: 0xD0
|
||||
|
||||
inline Z2CreatureLink* Z2GetLink() {
|
||||
return Z2CreatureLink::mLinkPtr;
|
||||
}
|
||||
|
||||
class Z2CreatureRide;
|
||||
struct Z2RideSoundStarter : public Z2SoundStarter {
|
||||
/* 802C5234 */ Z2RideSoundStarter(Z2CreatureRide*);
|
||||
|
||||
/* 802C5078 */ inline virtual ~Z2RideSoundStarter();
|
||||
/* 802C5284 */ virtual bool startSound(JAISoundID, JAISoundHandle*,
|
||||
JGeometry::TVec3<f32> const*, u32, f32, f32, f32, f32,
|
||||
f32, u32);
|
||||
|
||||
/* 0x4 */ Z2CreatureRide* mRide;
|
||||
};
|
||||
|
||||
class Z2CreatureRide : public Z2Creature, public Z2RideSoundStarter {
|
||||
public:
|
||||
Z2CreatureRide();
|
||||
~Z2CreatureRide();
|
||||
void init(Vec*, Vec*, u8, u8);
|
||||
void setLinkRiding(bool);
|
||||
|
||||
virtual void deleteObject();
|
||||
|
||||
private:
|
||||
/* 0x90 */ // Z2RideSoundStarter mSoundStarter;
|
||||
/* 0x98 */ bool mLinkRiding;
|
||||
}; // Size: 0x9C
|
||||
|
||||
class Z2CreatureEnemy : public Z2Creature, public JSULink<Z2CreatureEnemy> {
|
||||
public:
|
||||
/* 802C0F64 */ Z2CreatureEnemy();
|
||||
|
||||
@@ -1,5 +1,141 @@
|
||||
#ifndef Z2LINKMGR_H
|
||||
#define Z2LINKMGR_H
|
||||
|
||||
#include "SSystem/SComponent/c_xyz.h"
|
||||
#include "Z2AudioLib/Z2Creature.h"
|
||||
|
||||
class Z2LinkSoundStarter : public Z2SoundStarter {
|
||||
public:
|
||||
Z2LinkSoundStarter();
|
||||
|
||||
inline virtual ~Z2LinkSoundStarter();
|
||||
virtual bool startSound(JAISoundID, JAISoundHandle*, JGeometry::TVec3<f32> const*, u32, f32,
|
||||
f32, f32, f32, f32, u32);
|
||||
};
|
||||
|
||||
class Z2CreatureLink : public Z2Creature, public Z2LinkSoundStarter {
|
||||
public:
|
||||
Z2CreatureLink();
|
||||
~Z2CreatureLink();
|
||||
|
||||
void setLinkState(u8);
|
||||
void setLinkGroupInfo(u8);
|
||||
void setLinkHp(s32, s32);
|
||||
void setLinkSwordType(s32, s32);
|
||||
void setLinkShieldType(s32, s32);
|
||||
void setLinkBootsType(s32);
|
||||
virtual void deleteObject();
|
||||
void init(Vec*, Vec*, Vec*);
|
||||
void initKantera(Vec*);
|
||||
void deleteKantera(void);
|
||||
void setKanteraState(u8);
|
||||
virtual void framework(u32, s8);
|
||||
void setSinkDepth(s8);
|
||||
void setRiding(bool);
|
||||
void setMagnetized(bool);
|
||||
void setWolfEyeOpen(bool);
|
||||
Z2SoundHandlePool* startLinkSound(JAISoundID, u32, s8);
|
||||
JAISoundHandle* startLinkSoundLevel(JAISoundID, u32, s8);
|
||||
Z2SoundHandlePool* startLinkVoice(JAISoundID, s8);
|
||||
Z2SoundHandlePool* startLinkVoiceLevel(JAISoundID, s8);
|
||||
void startLinkSwordSound(JAISoundID, u32, s8);
|
||||
virtual Z2SoundHandlePool* startCollisionSE(u32, u32);
|
||||
Z2SoundHandlePool* startHitItemSE(u32, u32, Z2SoundObjBase*, float);
|
||||
void setResumeAttack(bool);
|
||||
|
||||
void setInWater(bool status) { mInWater = status; }
|
||||
bool isInWater() { return mInWater; }
|
||||
u8 getLinkState() const { return mLinkState; }
|
||||
u8 getMoveSpeed() const { return mMoveSpeed; }
|
||||
bool isRiding() const { return mRiding; }
|
||||
void i_setLinkState(u8 i_state) { mLinkState = i_state; }
|
||||
Z2SoundObjSimple& getKantera() { return mKantera; }
|
||||
u8 getLinkHp() const { return mLinkHp; }
|
||||
u8 getMovingTime() { return mMovingTime; }
|
||||
u8 isWolfSmellOpen() const { return mWolfEyeOpen; }
|
||||
void setUsingIronBall(bool i_using) { mUsingIronBall = i_using; }
|
||||
void setMarkState(u8 i_state) { mMarkState = i_state; }
|
||||
|
||||
static Z2CreatureLink* mLinkPtr;
|
||||
|
||||
friend class Z2LinkSoundStarter;
|
||||
friend class Z2RideSoundStarter;
|
||||
|
||||
private:
|
||||
/* 0x90 Z2LinkSoundStarter */
|
||||
/* 0x94 */ Z2SoundObjSimple mKantera;
|
||||
/* 0xB4 */ cXyz field_0xb4;
|
||||
/* 0xC0 */ u8 mLinkState;
|
||||
/* 0xC1 */ u8 field_0xc1;
|
||||
/* 0xC2 */ u8 mMarkState;
|
||||
/* 0xC3 */ u8 mLinkHp;
|
||||
/* 0xC4 */ u8 mLinkBootsType;
|
||||
/* 0xC5 */ u8 mKanteraState;
|
||||
/* 0xC6 */ u8 mLinkSwordType;
|
||||
/* 0xC7 */ u8 mLinkShieldType;
|
||||
/* 0xC8 */ u8 mMoveSpeed;
|
||||
/* 0xC9 */ u8 mMovingTime;
|
||||
/* 0xCA */ s8 mSinkDepth;
|
||||
/* 0xCB */ bool mWolfEyeOpen : 1;
|
||||
/* 0xCB */ bool mInWater : 1;
|
||||
/* 0xCB */ bool mResumeAttack : 1;
|
||||
/* 0xCB */ bool mFlag3 : 1;
|
||||
/* 0xCB */ bool mFlag4 : 1;
|
||||
/* 0xCB */ bool mFlag5 : 1;
|
||||
/* 0xCB */ bool mRiding : 1;
|
||||
/* 0xCB */ bool mMagnetized : 1;
|
||||
/* 0xCC */ bool mFlag8 : 1;
|
||||
/* 0xCC */ bool mUsingIronBall : 1;
|
||||
/* 0xCC */ bool mFlag10 : 1;
|
||||
/* 0xCC */ bool mFlag11 : 1;
|
||||
/* 0xCC */ bool mFlag12 : 1;
|
||||
/* 0xCC */ bool mFlag13 : 1;
|
||||
/* 0xCC */ bool mFlag14 : 1;
|
||||
/* 0xCC */ bool mFlag15 : 1;
|
||||
}; // Size: 0xD0
|
||||
|
||||
inline Z2CreatureLink* Z2GetLink() {
|
||||
return Z2CreatureLink::mLinkPtr;
|
||||
}
|
||||
|
||||
class Z2CreatureRide;
|
||||
struct Z2RideSoundStarter : public Z2SoundStarter {
|
||||
/* 802C5234 */ Z2RideSoundStarter(Z2CreatureRide*);
|
||||
|
||||
/* 802C5078 */ virtual ~Z2RideSoundStarter() {}
|
||||
/* 802C5284 */ virtual bool startSound(JAISoundID, JAISoundHandle*,
|
||||
JGeometry::TVec3<f32> const*, u32, f32, f32, f32, f32,
|
||||
f32, u32);
|
||||
|
||||
/* 0x4 */ Z2CreatureRide* mRide;
|
||||
};
|
||||
|
||||
class Z2CreatureRide : public Z2Creature, public Z2RideSoundStarter {
|
||||
public:
|
||||
Z2CreatureRide();
|
||||
~Z2CreatureRide();
|
||||
void init(Vec*, Vec*, u8, u8);
|
||||
void setLinkRiding(bool);
|
||||
|
||||
bool isLinkRiding() { return mLinkRiding; }
|
||||
|
||||
virtual void deleteObject();
|
||||
|
||||
private:
|
||||
/* 0x90 */ // Z2RideSoundStarter mSoundStarter;
|
||||
/* 0x98 */ bool mLinkRiding;
|
||||
}; // Size: 0x9C
|
||||
|
||||
class Z2SoundObjCoach : public Z2SoundObjBase {
|
||||
public:
|
||||
/* 802C54B8 */ Z2SoundObjCoach();
|
||||
/* 802C54FC */ void init(Vec*, u8);
|
||||
/* 802C551C */ Z2SoundHandlePool* startWheelSound(f32);
|
||||
/* 802C56C0 */ Z2SoundHandlePool* startFireSound(u16);
|
||||
/* 802C57C0 */ Z2SoundHandlePool* startSound(JAISoundID, u32, s8);
|
||||
|
||||
private:
|
||||
/* 0x20 */ f32 field_0x20;
|
||||
};
|
||||
|
||||
#endif /* Z2LINKMGR_H */
|
||||
|
||||
@@ -40,6 +40,7 @@ public:
|
||||
bool isMovieDemo() { return sceneNum == 2 || sceneNum == 8 || sceneNum == 9; }
|
||||
s32 getSeLoadStatus(u32 wave) { return getWaveLoadStatus(wave, 0); }
|
||||
s32 getBgmLoadStatus(u32 wave) { return getWaveLoadStatus(wave, 1); }
|
||||
u8 getDemoSeWaveNum() { return loadedDemoWave; }
|
||||
|
||||
private:
|
||||
/* 0x00 */ JAISoundID BGM_ID;
|
||||
|
||||
@@ -4,13 +4,9 @@
|
||||
#include "JSystem/JAudio2/JAISoundHandles.h"
|
||||
#include "JSystem/JAudio2/JASHeapCtrl.h"
|
||||
|
||||
// This should inherit JASPoolAllocObject (without which some functions in Z2SoundHandles.cpp badly mismatch)
|
||||
// but this inheritance causes the memPool_ to be generated in the first file that includes this header.
|
||||
// Perhaps this class definition should belong to a different header.
|
||||
class Z2SoundHandlePool : public JAISoundHandle, public JSULink<Z2SoundHandlePool> { // , public JASPoolAllocObject<Z2SoundHandlePool> {
|
||||
class Z2SoundHandlePool : public JAISoundHandle, public JSULink<Z2SoundHandlePool>, public JASPoolAllocObject<Z2SoundHandlePool> {
|
||||
public:
|
||||
Z2SoundHandlePool() : JAISoundHandle(), JSULink<Z2SoundHandlePool>(this) {}
|
||||
~Z2SoundHandlePool() {}
|
||||
};
|
||||
|
||||
class Z2SoundHandles : protected JSUList<Z2SoundHandlePool> {
|
||||
|
||||
@@ -93,6 +93,7 @@ public:
|
||||
bool removeEnemy(JSULink<Z2CreatureEnemy>*);
|
||||
u8 isTwilightBattle();
|
||||
|
||||
u8 getEnemyNumNear() { return mEnemyNumNear; }
|
||||
u8 getEnemyNumVeryFar() { return mEnemyNumVeryFar; }
|
||||
bool isForceBattle() { return mForceBattle; }
|
||||
JSUList<Z2CreatureEnemy>* getEnemyList() { return this; }
|
||||
|
||||
@@ -35,11 +35,11 @@ struct Z2SpeechMgr2 : public JASGlobalInstance<Z2SpeechMgr2> {
|
||||
/* 0x004 */ JAISoundHandle field_0x4;
|
||||
/* 0x008 */ JMath::TRandom_fast_ random;
|
||||
/* 0x00C */ Z2SpeechStarter mSpeech;
|
||||
/* 0x010 */ u16 field_0x10[500];
|
||||
/* 0x3F8 */ s16 field_0x3f8;
|
||||
/* 0x3FA */ s16 field_0x3fa;
|
||||
/* 0x3FC */ u16 field_0x3fc;
|
||||
/* 0x3FE */ u8 field_0x3fe;
|
||||
/* 0x010 */ u16 mText[500];
|
||||
/* 0x3F8 */ s16 mTextNum;
|
||||
/* 0x3FA */ s16 mTextCount;
|
||||
/* 0x3FC */ u16 mMood;
|
||||
/* 0x3FE */ u8 mVoice;
|
||||
/* 0x3FF */ u8 field_0x3ff;
|
||||
/* 0x400 */ u8 field_0x400;
|
||||
/* 0x401 */ u8 field_0x401;
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
#include "Z2AudioLib/Z2AudioMgr.h"
|
||||
#include "Z2AudioLib/Z2EnvSeMgr.h"
|
||||
#include "Z2AudioLib/Z2Creature.h"
|
||||
#include "Z2AudioLib/Z2LinkMgr.h"
|
||||
|
||||
class mDoAud_zelAudio_c : public Z2AudioMgr {
|
||||
public:
|
||||
|
||||
@@ -258,7 +258,6 @@ void JAISeMgr::resetSeqDataMgr() {
|
||||
}
|
||||
|
||||
/* 802A0484-802A0574 29ADC4 00F0+00 1/1 0/0 0/0 .text newSe___8JAISeMgrFiUl */
|
||||
// NONMATCHING JASPollAllocObject<_> locations
|
||||
JAISe* JAISeMgr::newSe_(int i_category, u32 param_1) {
|
||||
if (i_category < 0) {
|
||||
i_category = 0;
|
||||
@@ -338,10 +337,7 @@ int JAISeMgr::getNumActiveSe() const {
|
||||
return sum;
|
||||
}
|
||||
|
||||
/* 802A0994-802A0A6C 29B2D4 00D8+00 1/1 0/0 0/0 .text __ct__16JAISeCategoryMgrFv */
|
||||
JAISeCategoryMgr::JAISeCategoryMgr() {
|
||||
mParams.init();
|
||||
mMaxActiveSe = 0;
|
||||
mMaxInactiveSe = 0;
|
||||
field_0x4.field_0x0 = 0;
|
||||
}
|
||||
u8 data_80451310[8];
|
||||
|
||||
/* 80451318-80451320 000818 0008+00 0/0 7/7 0/0 .sbss None */
|
||||
u8 data_80451318[8];
|
||||
|
||||
@@ -48,7 +48,6 @@ JAISeqMgr::JAISeqMgr(bool param_1) : JASGlobalInstance<JAISeqMgr>(param_1), mAud
|
||||
}
|
||||
|
||||
/* 802A1A08-802A1AF4 29C348 00EC+00 1/1 0/0 0/0 .text freeDeadSeq___9JAISeqMgrFv */
|
||||
// NONMATCHING JASPoolAllocObject<_> locations
|
||||
void JAISeqMgr::freeDeadSeq_() {
|
||||
JSULink<JAISeq>* link = mSeqList.getFirst();
|
||||
while (link != NULL) {
|
||||
@@ -132,7 +131,6 @@ void JAISeqMgr::mixOut() {
|
||||
}
|
||||
|
||||
/* 802A1F58-802A1FE8 29C898 0090+00 1/1 0/0 0/0 .text beginStartSeq___9JAISeqMgrFv */
|
||||
// NONMATCHING JASPoolAllocObject<_> locations
|
||||
JAISeq* JAISeqMgr::beginStartSeq_() {
|
||||
JAISeq* seq = new JAISeq(this, field_0x10);
|
||||
if (seq == NULL) {
|
||||
@@ -143,7 +141,6 @@ JAISeq* JAISeqMgr::beginStartSeq_() {
|
||||
|
||||
/* 802A1FE8-802A20F0 29C928 0108+00 1/1 0/0 0/0 .text
|
||||
* endStartSeq___9JAISeqMgrFP6JAISeqP14JAISoundHandle */
|
||||
// NONMATCHING JASPoolAllocObject<_> locations
|
||||
bool JAISeqMgr::endStartSeq_(JAISeq* param_1, JAISoundHandle* param_2) {
|
||||
JAISeq* sound = param_1->getObject();
|
||||
if (sound != NULL) {
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user