mirror of https://github.com/zeldaret/tp.git
Z2AudioLib work (#2339)
* Z2LinkMgr work, Z2AudioArcLoader matching * Z2SeMgr matching * Z2SpeechMgr2 almost done, Z2SoundHandles matching
This commit is contained in:
parent
cf87a207b6
commit
5a7b9f62d6
1
.clangd
1
.clangd
|
@ -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
|
||||
|
|
24
configure.py
24
configure.py
|
@ -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();
|
||||
}
|
||||
|
|
|
@ -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) {
|
||||
|
|
|
@ -52,7 +52,6 @@ bool JAIStreamMgr::startSound(JAISoundID param_1, JAISoundHandle* param_2,
|
|||
|
||||
/* 802A3D70-802A3E68 29E6B0 00F8+00 1/1 0/0 0/0 .text freeDeadStream___12JAIStreamMgrFv
|
||||
*/
|
||||
// NONMATCHING JASPoolAllocObject<_> locations
|
||||
void JAIStreamMgr::freeDeadStream_() {
|
||||
JSULink<JAIStream>* link = mStreamList.getFirst();
|
||||
while (link != NULL) {
|
||||
|
@ -111,7 +110,6 @@ void JAIStreamMgr::mixOut() {
|
|||
}
|
||||
|
||||
/* 802A4174-802A4244 29EAB4 00D0+00 1/1 0/0 0/0 .text newStream___12JAIStreamMgrFv */
|
||||
// NONMATCHING JASPoolAllocObject<_> locations
|
||||
JAIStream* JAIStreamMgr::newStream_() {
|
||||
if (mStreamAramMgr == NULL) {
|
||||
JUT_WARN(229, "JAIStreamAramMgr must be set.\n");
|
||||
|
|
|
@ -9,163 +9,6 @@
|
|||
#include "JSystem/JAudio2/JASBank.h"
|
||||
#include "JSystem/JAudio2/JASAiCtrl.h"
|
||||
#include "JSystem/JAudio2/JASDSPInterface.h"
|
||||
#include "dol2asm.h"
|
||||
|
||||
//
|
||||
// Types:
|
||||
//
|
||||
|
||||
/* JASMemPool_MultiThreaded<JASTrack> */
|
||||
struct JASMemPool_MultiThreaded__template0 {
|
||||
/* 802932E0 */ void func_802932E0(void* _this);
|
||||
};
|
||||
|
||||
/* JASMemPool_MultiThreaded<JASTrack::TChannelMgr> */
|
||||
struct JASMemPool_MultiThreaded__template1 {
|
||||
/* 80293334 */ void func_80293334(void* _this);
|
||||
};
|
||||
|
||||
struct JASBankTable__template0 {
|
||||
/* 80293528 */ void func_80293528(void* _this, u32) /* const */;
|
||||
};
|
||||
|
||||
//
|
||||
// Forward References:
|
||||
//
|
||||
|
||||
extern "C" void __ct__8JASTrackFv();
|
||||
extern "C" void __dt__8JASTrackFv();
|
||||
extern "C" void setChannelMgrCount__8JASTrackFUl();
|
||||
extern "C" void init__8JASTrackFv();
|
||||
extern "C" void initTimed__8JASTrackFv();
|
||||
extern "C" void inherit__8JASTrackFRC8JASTrack();
|
||||
extern "C" void assignExtBuffer__8JASTrackFUlP14JASSoundParams();
|
||||
extern "C" void setSeqData__8JASTrackFPvUl();
|
||||
extern "C" void startSeq__8JASTrackFv();
|
||||
extern "C" void stopSeq__8JASTrackFv();
|
||||
extern "C" void start__8JASTrackFv();
|
||||
extern "C" void close__8JASTrackFv();
|
||||
extern "C" void connectChild__8JASTrackFUlP8JASTrack();
|
||||
extern "C" void closeChild__8JASTrackFUl();
|
||||
extern "C" void openChild__8JASTrackFUl();
|
||||
extern "C" void connectBus__8JASTrackFii();
|
||||
extern "C" void setLatestKey__8JASTrackFUc();
|
||||
extern "C" void channelStart__8JASTrackFPQ28JASTrack11TChannelMgrUlUlUl();
|
||||
extern "C" void noteOn__8JASTrackFUlUlUl();
|
||||
extern "C" void gateOn__8JASTrackFUlUlfUl();
|
||||
extern "C" void noteOff__8JASTrackFUlUs();
|
||||
extern "C" void checkNoteStop__8JASTrackCFUl();
|
||||
extern "C" void overwriteOsc__8JASTrackFP10JASChannel();
|
||||
extern "C" void updateTimedParam__8JASTrackFv();
|
||||
extern "C" void updateTrack__8JASTrackFf();
|
||||
extern "C" void updateTempo__8JASTrackFv();
|
||||
extern "C" void updateSeq__8JASTrackFbf();
|
||||
extern "C" void seqTimeToDspTime__8JASTrackFf();
|
||||
extern "C" void setParam__8JASTrackFUlfUl();
|
||||
extern "C" void noteOffAll__8JASTrackFUs();
|
||||
extern "C" void mute__8JASTrackFb();
|
||||
extern "C" void setOscScale__8JASTrackFUlf();
|
||||
extern "C" void setOscTable__8JASTrackFUlPCQ213JASOscillator5Point();
|
||||
extern "C" void setOscAdsr__8JASTrackFssssUs();
|
||||
extern "C" void setFIR__8JASTrackFPCs();
|
||||
extern "C" void setIIR__8JASTrackFPCs();
|
||||
extern "C" void readPortSelf__8JASTrackFUl();
|
||||
extern "C" void writePortSelf__8JASTrackFUlUs();
|
||||
extern "C" void writePort__8JASTrackFUlUs();
|
||||
extern "C" void readPort__8JASTrackFUl();
|
||||
extern "C" void setChannelPauseFlag__8JASTrackFb();
|
||||
extern "C" void pause__8JASTrackFb();
|
||||
extern "C" void getTransposeTotal__8JASTrackCFv();
|
||||
extern "C" void isMute__8JASTrackCFv();
|
||||
extern "C" void setTempo__8JASTrackFUs();
|
||||
extern "C" void setTempoRate__8JASTrackFf();
|
||||
extern "C" void setTimebase__8JASTrackFUs();
|
||||
extern "C" void updateChannel__8JASTrackFP10JASChannelPQ26JASDsp8TChannel();
|
||||
extern "C" void channelUpdateCallback__8JASTrackFUlP10JASChannelPQ26JASDsp8TChannelPv();
|
||||
extern "C" void getRootTrack__8JASTrackFv();
|
||||
extern "C" void tickProc__8JASTrackFv();
|
||||
extern "C" void seqMain__8JASTrackFv();
|
||||
extern "C" void cbSeqMain__Q28JASTrack5TListFPv();
|
||||
extern "C" void append__Q28JASTrack5TListFP8JASTrack();
|
||||
extern "C" void seqMain__Q28JASTrack5TListFv();
|
||||
extern "C" void __ct__Q28JASTrack11TChannelMgrFP8JASTrack();
|
||||
extern "C" void init__Q28JASTrack11TChannelMgrFv();
|
||||
extern "C" void releaseAll__Q28JASTrack11TChannelMgrFv();
|
||||
extern "C" void noteOff__Q28JASTrack11TChannelMgrFUlUs();
|
||||
extern "C" void setPauseFlag__Q28JASTrack11TChannelMgrFb();
|
||||
extern "C" void __ct__Q28JASTrack10MoveParam_Fv();
|
||||
extern "C" void func_802932E0(void* _this);
|
||||
extern "C" void func_80293334(void* _this);
|
||||
extern "C" void __sinit_JASTrack_cpp();
|
||||
extern "C" void __dt__Q28JASTrack5TListFv();
|
||||
extern "C" void __dt__19JASDefaultBankTableFv();
|
||||
extern "C" void func_80293528(void* _this, u32);
|
||||
extern "C" u8 const sAdsTable__8JASTrack[24];
|
||||
extern "C" u8 const sEnvOsc__8JASTrack[24];
|
||||
extern "C" u8 const sPitchEnvOsc__8JASTrack[24];
|
||||
extern "C" u8 sDefaultBankTable__8JASTrack[1036];
|
||||
extern "C" u8 sTrackList__8JASTrack[16];
|
||||
extern "C" u32 FILTER_MODE_IIR__6JASDsp;
|
||||
|
||||
//
|
||||
// External References:
|
||||
//
|
||||
|
||||
extern "C" void __ct__17JASGenericMemPoolFv();
|
||||
extern "C" void __dt__17JASGenericMemPoolFv();
|
||||
extern "C" void alloc__17JASGenericMemPoolFUl();
|
||||
extern "C" void free__17JASGenericMemPoolFPvUl();
|
||||
extern "C" void init__12JASTrackPortFv();
|
||||
extern "C" void readImport__12JASTrackPortFUl();
|
||||
extern "C" void readExport__12JASTrackPortFUl();
|
||||
extern "C" void writeImport__12JASTrackPortFUlUs();
|
||||
extern "C" void writeExport__12JASTrackPortFUlUs();
|
||||
extern "C" void __ct__16JASRegisterParamFv();
|
||||
extern "C" void init__16JASRegisterParamFv();
|
||||
extern "C" void __ct__10JASSeqCtrlFv();
|
||||
extern "C" void init__10JASSeqCtrlFv();
|
||||
extern "C" void start__10JASSeqCtrlFPvUl();
|
||||
extern "C" void tickProc__10JASSeqCtrlFP8JASTrack();
|
||||
extern "C" void interrupt__10JASSeqCtrlFQ210JASSeqCtrl8IntrType();
|
||||
extern "C" void noteOn__7JASBankFPC7JASBankiUcUcUsPFUlP10JASChannelPQ26JASDsp8TChannelPv_vPv();
|
||||
extern "C" void release__10JASChannelFUs();
|
||||
extern "C" void setOscInit__10JASChannelFUlPCQ213JASOscillator4Data();
|
||||
extern "C" void setMixConfig__10JASChannelFUlUs();
|
||||
extern "C" void setKeySweepTarget__10JASChannelFlUl();
|
||||
extern "C" void free__10JASChannelFv();
|
||||
extern "C" void getDacRate__9JASDriverFv();
|
||||
extern "C" void getSubFrames__9JASDriverFv();
|
||||
extern "C" void setFilterMode__Q26JASDsp8TChannelFUs();
|
||||
extern "C" void setIIRFilterParam__Q26JASDsp8TChannelFPs();
|
||||
extern "C" void setFIR8FilterParam__Q26JASDsp8TChannelFPs();
|
||||
extern "C" void setDistFilter__Q26JASDsp8TChannelFs();
|
||||
extern "C" void registerSubFrameCallback__9JASDriverFPFPv_lPv();
|
||||
extern "C" void __dl__FPv();
|
||||
extern "C" void __dt__Q27JGadget13TNodeLinkListFv();
|
||||
extern "C" void
|
||||
Insert__Q27JGadget13TNodeLinkListFQ37JGadget13TNodeLinkList8iteratorPQ27JGadget13TLinkListNode();
|
||||
extern "C" void Remove__Q27JGadget13TNodeLinkListFPQ27JGadget13TLinkListNode();
|
||||
extern "C" void __register_global_object();
|
||||
extern "C" void __construct_array();
|
||||
extern "C" void __cvt_fp2unsigned();
|
||||
extern "C" void _savegpr_20();
|
||||
extern "C" void _savegpr_23();
|
||||
extern "C" void _savegpr_26();
|
||||
extern "C" void _savegpr_27();
|
||||
extern "C" void _savegpr_28();
|
||||
extern "C" void _savegpr_29();
|
||||
extern "C" void _restgpr_20();
|
||||
extern "C" void _restgpr_23();
|
||||
extern "C" void _restgpr_26();
|
||||
extern "C" void _restgpr_27();
|
||||
extern "C" void _restgpr_28();
|
||||
extern "C" void _restgpr_29();
|
||||
extern "C" extern u8 struct_80451230[8];
|
||||
extern "C" extern u8 __OSReport_disable;
|
||||
|
||||
//
|
||||
// Declarations:
|
||||
//
|
||||
|
||||
/* 80291228-8029131C 28BB68 00F4+00 1/1 3/3 0/0 .text __ct__8JASTrackFv */
|
||||
// NONMATCHING
|
||||
|
@ -301,15 +144,15 @@ void JASTrack::init() {
|
|||
|
||||
/* 802918FC-8029194C 28C23C 0050+00 1/1 0/0 0/0 .text initTimed__8JASTrackFv */
|
||||
void JASTrack::initTimed() {
|
||||
mMoveParam[0].mValue = 1.0f;
|
||||
mMoveParam[1].mValue = 0.0f;
|
||||
mMoveParam[3].mValue = 0.5f;
|
||||
mMoveParam[2].mValue = 0.0f;
|
||||
mMoveParam[4].mValue = 0.0f;
|
||||
mMoveParam[5].mValue = 0.0f;
|
||||
mMoveParam.params.volume.mValue = 1.0f;
|
||||
mMoveParam.params.pitch.mValue = 0.0f;
|
||||
mMoveParam.params.pan.mValue = 0.5f;
|
||||
mMoveParam.params.fxmix.mValue = 0.0f;
|
||||
mMoveParam.params.dolby.mValue = 0.0f;
|
||||
mMoveParam.params.distFilter.mValue = 0.0f;
|
||||
for (int i = 0; i < 6; i++) {
|
||||
mMoveParam[i].mCount = 0;
|
||||
mMoveParam[i].mTarget = mMoveParam[i].mValue;
|
||||
mMoveParam.array[i].mCount = 0;
|
||||
mMoveParam.array[i].mTarget = mMoveParam.array[i].mValue;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -575,7 +418,7 @@ void JASTrack::overwriteOsc(JASChannel* i_channel) {
|
|||
/* 802922D8-80292348 28CC18 0070+00 1/1 0/0 0/0 .text updateTimedParam__8JASTrackFv */
|
||||
void JASTrack::updateTimedParam() {
|
||||
for (u32 i = 0; i < 6; i++) {
|
||||
MoveParam_* param = &mMoveParam[i];
|
||||
MoveParam_* param = &mMoveParam.array[i];
|
||||
if (param->mCount != 0) {
|
||||
param->mValue += (param->mTarget - param->mValue) / param->mCount;
|
||||
param->mCount--;
|
||||
|
@ -589,13 +432,13 @@ void JASTrack::updateTrack(f32 param_0) {
|
|||
for (u32 i = 0; i < mChannelMgrCount; i++) {
|
||||
TChannelMgr* channel_mgr = mChannelMgrs[i];
|
||||
if (channel_mgr != NULL) {
|
||||
f32 volume = mMoveParam[0].mValue;
|
||||
f32 volume = mMoveParam.params.volume.mValue;
|
||||
volume = volume * volume;
|
||||
f32 pitch = 1.0f;
|
||||
f32 fvar6 = mMoveParam[1].mValue * mBendSense * (1.0f / 3.0f);
|
||||
f32 pan = (mMoveParam[3].mValue - 0.5f) * mPanPower;
|
||||
f32 fxmix = mMoveParam[2].mValue;
|
||||
f32 dolby = mMoveParam[4].mValue;
|
||||
f32 fvar6 = mMoveParam.params.pitch.mValue * mBendSense * (1.0f / 3.0f);
|
||||
f32 pan = (mMoveParam.params.pan.mValue - 0.5f) * mPanPower;
|
||||
f32 fxmix = mMoveParam.params.fxmix.mValue;
|
||||
f32 dolby = mMoveParam.params.dolby.mValue;
|
||||
JASSoundParams* sound_params = channel_mgr->mSoundParams;
|
||||
if (sound_params != NULL) {
|
||||
volume *= sound_params->mVolume;
|
||||
|
@ -671,7 +514,7 @@ u32 JASTrack::seqTimeToDspTime(f32 i_seqTime) {
|
|||
|
||||
/* 802926E0-80292708 28D020 0028+00 0/0 4/4 0/0 .text setParam__8JASTrackFUlfUl */
|
||||
void JASTrack::setParam(u32 i_index, f32 i_target, u32 i_count) {
|
||||
MoveParam_* param = &mMoveParam[i_index];
|
||||
MoveParam_* param = &mMoveParam.array[i_index];
|
||||
param->mTarget = i_target;
|
||||
if (i_count == 0) {
|
||||
param->mValue = param->mTarget;
|
||||
|
@ -847,7 +690,7 @@ void JASTrack::updateChannel(JASChannel* param_0, JASDsp::TChannel* param_1) {
|
|||
param_1->setFIR8FilterParam(mFIR);
|
||||
}
|
||||
param_1->setFilterMode(mFilterMode);
|
||||
param_1->setDistFilter(mMoveParam[5].mValue * 32767.0f);
|
||||
param_1->setDistFilter(mMoveParam.params.distFilter.mValue * 32767.0f);
|
||||
}
|
||||
|
||||
|
||||
|
@ -955,9 +798,12 @@ void JASTrack::TList::append(JASTrack* i_track) {
|
|||
}
|
||||
|
||||
/* 8029301C-802930DC 28D95C 00C0+00 1/1 0/0 0/0 .text seqMain__Q28JASTrack5TListFv */
|
||||
// NONMATCHING problems with the iterator
|
||||
// NONMATCHING missing load instruction
|
||||
void JASTrack::TList::seqMain() {
|
||||
for (iterator it = begin(); it != end(); it++) {
|
||||
iterator it, it2;
|
||||
for (it = begin(); it != end(); it = it2) {
|
||||
it2 = it;
|
||||
it2++;
|
||||
if (it->seqMain() < 0) {
|
||||
Remove(&*it);
|
||||
if (it->mFlags.autoDelete) {
|
||||
|
|
|
@ -172,17 +172,3 @@ bool Dsp_Running_Check() {
|
|||
void Dsp_Running_Start() {
|
||||
struct_80451308 = 1;
|
||||
}
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 80451310-80451318 000810 0008+00 0/0 3/3 0/0 .sbss None */
|
||||
u8 data_80451310[8];
|
||||
|
||||
/* 80451318-80451320 000818 0008+00 0/0 7/7 0/0 .sbss None */
|
||||
u8 data_80451318[8];
|
||||
|
||||
/* 80451320-80451328 000820 0008+00 0/0 4/4 0/0 .sbss None */
|
||||
u8 data_80451320[8];
|
||||
|
||||
/* 80451328-80451330 000828 0008+00 0/0 3/3 0/0 .sbss None */
|
||||
// init$localstatic4$getMemPool__30JASPoolAllocObject<9JAIStream>Fv
|
||||
u8 data_80451328[8];
|
||||
|
|
|
@ -30,7 +30,7 @@ bool Z2AudioArcLoader::readCommandMore(u32 param_0) {
|
|||
// NONMATCHING regalloc
|
||||
void Z2AudioArcLoader::readBFCA(void const* param_0) {
|
||||
JKRHeap* heap = JAUSectionHeap::getInstance()->getHeap();
|
||||
JKRArchive* archive = JKRArchive::mount((void*)param_0, JKRGetCurrentHeap(), JKRArchive::MOUNT_DIRECTION_TAIL);
|
||||
JKRArchive* archive = JKRMountArchive((void*)param_0, JKRGetCurrentHeap(), JKRArchive::MOUNT_DIRECTION_TAIL);
|
||||
Z2GetFxLineMgr()->initDataArc(archive, heap);
|
||||
JKRUnmountArchive(archive);
|
||||
}
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
*/
|
||||
|
||||
#include "Z2AudioLib/Z2Creature.h"
|
||||
#include "SSystem/SComponent/c_xyz.h"
|
||||
#include "Z2AudioLib/Z2Param.h"
|
||||
#include "Z2AudioLib/Z2Calc.h"
|
||||
#include "Z2AudioLib/Z2AudioMgr.h"
|
||||
|
@ -180,7 +181,7 @@ Z2SoundHandlePool* Z2Creature::startCreatureSound(JAISoundID i_soundID, u32 para
|
|||
return mSoundObjSimple1.startSound(i_soundID, param_1, 0);
|
||||
default:
|
||||
Z2SoundHandlePool* handle = mSoundObjAnime.startSound(i_soundID, param_1, param_2);
|
||||
if (handle != NULL && *handle != NULL) {
|
||||
if (handle != NULL && *handle) {
|
||||
switch (i_soundID) {
|
||||
case Z2SE_FAIRY_S_FLY:
|
||||
f32 pitch = Z2Calc::getParamByExp((f32)param_1, 30.0f, 100.0f, 0.3f,
|
||||
|
@ -199,12 +200,12 @@ Z2SoundHandlePool* Z2Creature::startCreatureSound(JAISoundID i_soundID, u32 para
|
|||
* startCreatureSoundLevel__10Z2CreatureF10JAISoundIDUlSc */
|
||||
Z2SoundHandlePool* Z2Creature::startCreatureSoundLevel(JAISoundID i_soundID, u32 param_1, s8 param_2) {
|
||||
switch (i_soundID) {
|
||||
case 0x600d6:
|
||||
case Z2SE_FAIRY_S_LV:
|
||||
Z2GetAudioMgr()->seStartLevel(i_soundID, mpPos, 0, 0, 1.0f, 1.0f, -1.0f, -1.0f, 0);
|
||||
return NULL;
|
||||
default:
|
||||
Z2SoundHandlePool* handle = mSoundObjAnime.startLevelSound(i_soundID, param_1, param_2);
|
||||
if (handle != NULL && *handle != NULL) {
|
||||
if (handle != NULL && *handle) {
|
||||
if (i_soundID == Z2SE_YM_SNOBO_RIDE || i_soundID == Z2SE_YW_SNOBO_RIDE) {
|
||||
f32 volume = 0.0f;
|
||||
if (param_1 != 0) {
|
||||
|
@ -486,7 +487,7 @@ Z2SoundHandlePool* Z2CreatureEnemy::startCreatureSoundLevel(JAISoundID i_soundID
|
|||
|
||||
switch (mEnemyID) {
|
||||
case Z2_ENEMY_FZ:
|
||||
if (handle != NULL && *handle != NULL && i_soundID == Z2SE_EN_FZ_MOVE) {
|
||||
if (handle != NULL && *handle && i_soundID == Z2SE_EN_FZ_MOVE) {
|
||||
f32 volume = Z2Calc::getParamByExp(param_1, 1.0f, 50.0f, 0.4f, 0.1f, 1.1f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
(*handle)->getAuxiliary().moveVolume(volume, 0);
|
||||
|
@ -496,7 +497,7 @@ Z2SoundHandlePool* Z2CreatureEnemy::startCreatureSoundLevel(JAISoundID i_soundID
|
|||
Z2_E_sw_modPitch(handle, param_1);
|
||||
break;
|
||||
case Z2_ENEMY_RB:
|
||||
if (handle != NULL && *handle != NULL && i_soundID == Z2SE_EN_RB_MOVE) {
|
||||
if (handle != NULL && *handle && i_soundID == Z2SE_EN_RB_MOVE) {
|
||||
f32 volume = Z2Calc::getParamByExp(param_1, 4.0f, 35.0f, 0.6f, 0.7f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
f32 pitch = Z2Calc::getParamByExp(param_1, 4.0f, 35.0f, 0.4f, 0.8f, 1.0f,
|
||||
|
@ -507,7 +508,7 @@ Z2SoundHandlePool* Z2CreatureEnemy::startCreatureSoundLevel(JAISoundID i_soundID
|
|||
}
|
||||
// no break
|
||||
default:
|
||||
if (handle != NULL && *handle != NULL && i_soundID == Z2SE_EN_PH_PROPELLER) {
|
||||
if (handle != NULL && *handle && i_soundID == Z2SE_EN_PH_PROPELLER) {
|
||||
f32 volume = Z2Calc::getParamByExp(param_1, 0.0f, 30.0f, 0.4f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
f32 pitch = Z2Calc::getParamByExp(param_1, 4000.0f, 13000.0f, 0.4f, 0.8f, 1.2f,
|
||||
|
@ -856,7 +857,7 @@ Z2SoundHandlePool* Z2CreatureFM::startChainSoundLevel(JAISoundID i_soundID, u8 p
|
|||
switch (param_1) {
|
||||
case 0:
|
||||
handle = field_0xa4.startLevelSound(i_soundID, param_3, param_4);
|
||||
if (handle != NULL && *handle != NULL) {
|
||||
if (handle != NULL && *handle) {
|
||||
if (param_2 > 30.0f) {
|
||||
pitch = 1.06f;
|
||||
} else {
|
||||
|
@ -872,7 +873,7 @@ Z2SoundHandlePool* Z2CreatureFM::startChainSoundLevel(JAISoundID i_soundID, u8 p
|
|||
return NULL;
|
||||
case 1:
|
||||
handle = field_0xa4.startLevelSound(i_soundID, param_3, param_4);
|
||||
if (handle != NULL && *handle != NULL) {
|
||||
if (handle != NULL && *handle) {
|
||||
if (param_2 > 30.0f) {
|
||||
pitch = 1.06f;
|
||||
} else {
|
||||
|
@ -1052,7 +1053,7 @@ Z2SoundHandlePool* Z2CreatureOI::startTentacleSoundLevel(JAISoundID i_soundID, u
|
|||
f32 param_2, u32 param_3, s8 param_4) {
|
||||
Z2SoundHandlePool* handle =
|
||||
mTentacleSounds[param_1].startLevelSound(i_soundID, param_3, param_4);
|
||||
if (handle != NULL && *handle != NULL) {
|
||||
if (handle != NULL && *handle) {
|
||||
f32 volume = Z2Calc::getParamByExp(param_2, 0.0f, 60.0f, 0.4f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
f32 pitch = Z2Calc::getParamByExp(param_2, 0.0f, 60.0f, 0.4f, 0.9f, 1.1f,
|
||||
|
|
|
@ -211,20 +211,20 @@ Z2EnvSeMgr::Z2EnvSeMgr()
|
|||
field_0x39 = 0;
|
||||
field_0x2e8.setParam(0.1f, 0.007823764f, 0.06f);
|
||||
field_0x2f8.setParam(0.2f, 0.007823764f, 0.06f);
|
||||
field_0x90.setParam(0.1f, 0.02630252f, 0.005f);
|
||||
field_0xa0.setParam(0.9f, 0.02331011f, 0.003f);
|
||||
field_0xb0.setParam(0.2f, 0.006385157f, 0.004f);
|
||||
field_0x90.setParam(0.1f, 0.026302524f, 0.005f);
|
||||
field_0xa0.setParam(0.9f, 0.023310114f, 0.003f);
|
||||
field_0xb0.setParam(0.2f, 0.0063851574f, 0.004f);
|
||||
field_0xc0.setParam(0.8f, 0.006188805f, 0.0045f);
|
||||
field_0xd0.setParam(0.3f, 0.05343298f, 0.002f);
|
||||
field_0xe0.setParam(0.7f, 0.04256627f, 0.0025f);
|
||||
field_0xf0.setParam(0.4f, 0.01293395f, 0.006f);
|
||||
field_0x100.setParam(0.6f, 0.01215741f, 0.0065f);
|
||||
field_0x18c.setParam(0.1f, 0.02331011f, 0.005f);
|
||||
field_0x19c.setParam(0.5f, 0.05343298f, 0.0025f);
|
||||
field_0xd0.setParam(0.3f, 0.053432982f, 0.002f);
|
||||
field_0xe0.setParam(0.7f, 0.042566273f, 0.0025f);
|
||||
field_0xf0.setParam(0.4f, 0.012933955f, 0.006f);
|
||||
field_0x100.setParam(0.6f, 0.012157413f, 0.0065f);
|
||||
field_0x18c.setParam(0.1f, 0.023310114f, 0.005f);
|
||||
field_0x19c.setParam(0.5f, 0.053432982f, 0.0025f);
|
||||
field_0x64.setVolumeScale(1.0f);
|
||||
mWolfSmellSeMgr.setVolumeScale(1.0f);
|
||||
field_0x120.setParam(0.5f, 0.02092357f, 0.001f);
|
||||
field_0x130.setParam(0.1f, 0.003790878f, 0.005f);
|
||||
field_0x120.setParam(0.5f, 0.020923574f, 0.001f);
|
||||
field_0x130.setParam(0.1f, 0.0037908785f, 0.005f);
|
||||
}
|
||||
|
||||
/* 802C6540-802C66B0 2C0E80 0170+00 0/0 1/1 0/0 .text __dt__10Z2EnvSeMgrFv */
|
||||
|
@ -968,7 +968,7 @@ void Z2EnvSeMgr::setHyrulSewerOpen(bool param_0) {
|
|||
}
|
||||
|
||||
/* 802C8300-802C8730 2C2C40 0430+00 2/1 1/1 0/0 .text startRiverSe__10Z2EnvSeMgrFSc */
|
||||
// NONMATCHING missing branch and JAISound stack issues
|
||||
// NONMATCHING JAISound stack issues
|
||||
bool Z2EnvSeMgr::startRiverSe(s8 param_1) {
|
||||
if (Z2GetStatusMgr()->mCameraMapInfo == 6) {
|
||||
switch (Z2GetSceneMgr()->getCurrentSceneNum()) {
|
||||
|
@ -981,14 +981,18 @@ bool Z2EnvSeMgr::startRiverSe(s8 param_1) {
|
|||
break;
|
||||
}
|
||||
case 8:
|
||||
default:
|
||||
registRiverSePos(&Z2GetStatusMgr()->mPolygonPosition);
|
||||
// fake match: should be 2000.0f according to debug, but that generates an extra entry in sdata2
|
||||
if (Z2GetStatusMgr()->mPolygonPosition.y < -14500.0f) {
|
||||
break;
|
||||
}
|
||||
case 0x15:
|
||||
case 0x1e:
|
||||
case 0x1f:
|
||||
case 0x2e:
|
||||
break;
|
||||
default:
|
||||
registRiverSePos(&Z2GetStatusMgr()->mPolygonPosition);
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (mRiverSeMgr.getPosCount() < 0) {
|
||||
|
|
|
@ -4,18 +4,7 @@
|
|||
//
|
||||
|
||||
#include "Z2AudioLib/Z2LinkMgr.h"
|
||||
#include "Z2AudioLib/Z2Creature.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "dol2asm.h"
|
||||
#include "global.h"
|
||||
|
||||
struct Z2SoundObjCoach {
|
||||
/* 802C54B8 */ Z2SoundObjCoach();
|
||||
/* 802C54FC */ void init(Vec*, u8);
|
||||
/* 802C551C */ void startWheelSound(f32);
|
||||
/* 802C56C0 */ void startFireSound(u16);
|
||||
/* 802C57C0 */ int startSound(JAISoundID, u32, s8);
|
||||
};
|
||||
|
||||
/* 802C321C-802C3220 2BDB5C 0004+00 0/0 1/1 0/0 .text setLinkGroupInfo__14Z2CreatureLinkFUc */
|
||||
void Z2CreatureLink::setLinkGroupInfo(u8) {}
|
||||
|
@ -355,14 +344,113 @@ JAISoundHandle* Z2CreatureLink::startLinkSoundLevel(JAISoundID i_soundID, u32 pa
|
|||
|
||||
/* 802C4320-802C45B0 2BEC60 0290+00 1/1 1/1 0/0 .text
|
||||
* startLinkVoice__14Z2CreatureLinkF10JAISoundIDSc */
|
||||
void Z2CreatureLink::startLinkVoice(JAISoundID param_0, s8 param_1) {
|
||||
// NONMATCHING
|
||||
Z2SoundHandlePool* Z2CreatureLink::startLinkVoice(JAISoundID i_soundID, s8 param_1) {
|
||||
if (mLinkState == 1) {
|
||||
switch (i_soundID) {
|
||||
case Z2SE_WL_V_BREATH_WAIT:
|
||||
case Z2SE_WL_V_BREATH_TIRED:
|
||||
case Z2SE_WL_V_BREATH_SIT:
|
||||
if (Z2GetStatusMgr()->getDemoStatus() == 2 || !Z2GetSceneMgr()->isInGame()) {
|
||||
return NULL;
|
||||
}
|
||||
// fallthrough
|
||||
case Z2SE_WL_V_BREATH_WALK:
|
||||
case Z2SE_WL_V_BREATH_RUN:
|
||||
if (field_0xc1 < 5) {
|
||||
return NULL;
|
||||
}
|
||||
field_0xc1 = 0;
|
||||
break;
|
||||
case Z2SE_WL_V_BITE_ATTACK:
|
||||
if (mSoundObjSimple1.getHandleSoundID(Z2SE_WL_V_BITE_THROAT) != NULL) {
|
||||
return NULL;
|
||||
}
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
if (i_soundID == Z2SE_AL_V_ATTACK_RUN) {
|
||||
if (field_0xc1 < 10) {
|
||||
return NULL;
|
||||
}
|
||||
field_0xc1 = 0;
|
||||
}
|
||||
|
||||
if (mMarkState != 3 && Z2GetSoundObjMgr()->getEnemyNumNear() == 0
|
||||
&& !Z2GetSoundObjMgr()->isForceBattle())
|
||||
{
|
||||
switch (i_soundID) {
|
||||
case Z2SE_AL_V_ATTACK_S:
|
||||
i_soundID = Z2SE_AL_V_ATTACK_S_FREE;
|
||||
break;
|
||||
case Z2SE_AL_V_ATTACK_M:
|
||||
case Z2SE_AL_V_TATE_OSHI:
|
||||
i_soundID = Z2SE_AL_V_ATTACK_M_FREE;
|
||||
break;
|
||||
case Z2SE_AL_V_ATTACK_L:
|
||||
i_soundID = Z2SE_AL_V_ATTACK_L_FREE;
|
||||
break;
|
||||
case Z2SE_AL_V_KAITEN:
|
||||
i_soundID = Z2SE_AL_V_KAITEN_FREE;
|
||||
break;
|
||||
case Z2SE_AL_V_BACKTEN:
|
||||
case Z2SE_AL_V_SOTOMO_ROLL:
|
||||
i_soundID = Z2SE_AL_V_BACKTEN_FREE;
|
||||
break;
|
||||
case Z2SE_AL_V_ATTACK_RUN:
|
||||
i_soundID = Z2SE_AL_V_ATTACK_RUN_FREE;
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
if (i_soundID == Z2SE_AL_V_JUMP_S) {
|
||||
i_soundID = Z2SE_AL_V_BACKTEN;
|
||||
}
|
||||
}
|
||||
|
||||
if (isInWater()) {
|
||||
i_soundID = Z2SE_AL_V_UNDER_WATER;
|
||||
}
|
||||
}
|
||||
|
||||
return startCreatureVoice(i_soundID, param_1);
|
||||
}
|
||||
|
||||
/* 802C45B0-802C46F0 2BEEF0 0140+00 0/0 1/1 0/0 .text
|
||||
* startLinkVoiceLevel__14Z2CreatureLinkF10JAISoundIDSc */
|
||||
void Z2CreatureLink::startLinkVoiceLevel(JAISoundID param_0, s8 param_1) {
|
||||
// NONMATCHING
|
||||
Z2SoundHandlePool* Z2CreatureLink::startLinkVoiceLevel(JAISoundID i_soundID, s8 param_1) {
|
||||
if (mLinkState == 1) {
|
||||
switch (i_soundID) {
|
||||
case Z2SE_WL_V_ROAR:
|
||||
f32 volume = 0.0f;
|
||||
u8 port_data = 0;
|
||||
switch (mMarkState) {
|
||||
case 0:
|
||||
volume = 1.0f;
|
||||
port_data = 2;
|
||||
break;
|
||||
case 1:
|
||||
volume = 0.3f;
|
||||
port_data = 1;
|
||||
break;
|
||||
case 2:
|
||||
volume = 0.5f;
|
||||
port_data = 1;
|
||||
break;
|
||||
case 3:
|
||||
volume = 0.8f;
|
||||
port_data = 2;
|
||||
break;
|
||||
}
|
||||
|
||||
Z2SoundHandlePool* handle = startCreatureVoiceLevel(Z2SE_WL_V_ROAR, param_1);
|
||||
if (handle != NULL && *handle) {
|
||||
(*handle)->getAuxiliary().moveVolume(volume, 0);
|
||||
Z2GetSoundStarter()->setPortData(handle, 8, port_data, -1);
|
||||
}
|
||||
return handle;
|
||||
}
|
||||
}
|
||||
|
||||
return startCreatureVoiceLevel(i_soundID, param_1);
|
||||
}
|
||||
|
||||
/* 802C46F0-802C4784 2BF030 0094+00 0/0 2/2 0/0 .text
|
||||
|
@ -401,15 +489,26 @@ Z2SoundHandlePool* Z2CreatureLink::startCollisionSE(u32 hitID, u32 mapinfo) {
|
|||
return mSoundObjAnime.startCollisionSE(hitID, mapinfo, NULL);
|
||||
}
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 80455D18-80455D1C 004318 0004+00 1/1 0/0 0/0 .sdata2 @4178 */
|
||||
SECTION_SDATA2 static f32 lit_4178 = 100.0f;
|
||||
|
||||
/* 802C4814-802C48D8 2BF154 00C4+00 0/0 4/4 2/2 .text
|
||||
* startHitItemSE__14Z2CreatureLinkFUlUlP14Z2SoundObjBasef */
|
||||
int Z2CreatureLink::startHitItemSE(u32 param_0, u32 param_1, Z2SoundObjBase* param_2,
|
||||
f32 speed) {
|
||||
// NONMATCHING
|
||||
Z2SoundHandlePool* Z2CreatureLink::startHitItemSE(u32 i_soundID, u32 param_1,
|
||||
Z2SoundObjBase* param_2, f32 speed) {
|
||||
if (param_2 == NULL) {
|
||||
param_2 = &mSoundObjSimple2;
|
||||
}
|
||||
|
||||
if (i_soundID == Z2SE_HIT_SHIELD_ATTACK) {
|
||||
return mSoundObjAnime.startCollisionSE(i_soundID, param_1, NULL);
|
||||
}
|
||||
|
||||
Z2SoundHandlePool* handle = param_2->startCollisionSE(i_soundID, param_1, NULL);
|
||||
if (speed >= 0.0f && handle != NULL && *handle) {
|
||||
if (speed >= 100.0f) {
|
||||
speed = 100.0f;
|
||||
}
|
||||
(*handle)->getAuxiliary().moveVolume(speed / 100.0f, 0);
|
||||
}
|
||||
return handle;
|
||||
}
|
||||
|
||||
/* 802C48D8-802C48E8 2BF218 0010+00 0/0 1/1 0/0 .text setResumeAttack__14Z2CreatureLinkFb
|
||||
|
@ -421,17 +520,158 @@ void Z2CreatureLink::setResumeAttack(bool i_resumeAttack) {
|
|||
/* 802C48E8-802C4928 2BF228 0040+00 1/1 0/0 0/0 .text __ct__18Z2LinkSoundStarterFv */
|
||||
Z2LinkSoundStarter::Z2LinkSoundStarter() : Z2SoundStarter(false) {}
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 80455D1C-80455D20 00431C 0004+00 2/2 0/0 0/0 .sdata2 @4399 */
|
||||
SECTION_SDATA2 static f32 lit_4399 = 9.0f / 10.0f;
|
||||
|
||||
/* 802C4928-802C4FFC 2BF268 06D4+00 2/0 0/0 0/0 .text
|
||||
* startSound__18Z2LinkSoundStarterF10JAISoundIDP14JAISoundHandlePCQ29JGeometry8TVec3<f>UlfffffUl */
|
||||
bool Z2LinkSoundStarter::startSound(JAISoundID param_0, JAISoundHandle* param_1,
|
||||
// NONMATCHING stack alloc
|
||||
bool Z2LinkSoundStarter::startSound(JAISoundID i_soundID, JAISoundHandle* param_1,
|
||||
JGeometry::TVec3<f32> const* param_2, u32 param_3,
|
||||
f32 param_4, f32 param_5, f32 param_6, f32 param_7,
|
||||
f32 param_8, u32 param_9) {
|
||||
// NONMATCHING
|
||||
bool bVar2 = false;
|
||||
bool bVar3 = false;
|
||||
|
||||
if (Z2GetLink()->isInWater() && Z2GetStatusMgr()->getCameraInWaterDepthRatio() > 0.0f) {
|
||||
switch (i_soundID) {
|
||||
case Z2SE_AL_SWIM:
|
||||
case Z2SE_AL_DIVE_SWIM:
|
||||
i_soundID = Z2SE_AL_SWIM_UNDERWATER;
|
||||
break;
|
||||
case Z2SE_AL_SWORD_SWING_S:
|
||||
case Z2SE_AL_FINISH_SWING1:
|
||||
case Z2SE_AL_FINISH_SWING2:
|
||||
case Z2SE_AL_WAIT_SWORD_SWING:
|
||||
i_soundID = Z2SE_AL_WATER_STROKE_S;
|
||||
break;
|
||||
case Z2SE_AL_SWORD_SWING_L:
|
||||
i_soundID = Z2SE_AL_WATER_STROKE_L;
|
||||
break;
|
||||
case Z2SE_AL_SWORD_THRUST:
|
||||
i_soundID = Z2SE_AL_WATER_STROKE_FAST;
|
||||
break;
|
||||
case Z2SE_AL_KAITENGIRI:
|
||||
i_soundID = Z2SE_AL_WATER_STROKE_CIRCLE;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (i_soundID.mId.mBytes.b1 == 3 && param_3 > 26) {
|
||||
if (param_3 == 44) {
|
||||
param_3 = 23;
|
||||
} else {
|
||||
param_3 = 0;
|
||||
}
|
||||
}
|
||||
|
||||
switch (i_soundID) {
|
||||
case Z2SE_AL_INTO_WATER:
|
||||
case Z2SE_AL_DIVE_INTO_WATER:
|
||||
case Z2SE_WL_INTO_WATER:
|
||||
if (Z2GetLink()->mSoundObjSimple1.isActive()) {
|
||||
Z2GetLink()->mSoundObjSimple1.stopAllSounds(1);
|
||||
}
|
||||
break;
|
||||
case Z2SE_FN_WALK_DUMMY:
|
||||
case Z2SE_FN_LADDER_CLIMB:
|
||||
case Z2SE_FN_LADDER_DOWN:
|
||||
bVar2 = true;
|
||||
// fallthrough
|
||||
case Z2SE_GORON_FOOTNOTE:
|
||||
case Z2SE_FN_GOB_JUMP:
|
||||
if (Z2GetLink()->mLinkBootsType == 1) {
|
||||
i_soundID = Z2SE_FN_WALK_HEAVY;
|
||||
if (Z2GetLink()->mMagnetized) {
|
||||
param_3 = 127;
|
||||
}
|
||||
}
|
||||
bVar3 = true;
|
||||
break;
|
||||
case Z2SE_FN_JUMP_DUMMY:
|
||||
bVar2 = true;
|
||||
bVar3 = true;
|
||||
if (Z2GetLink()->mLinkBootsType == 1) {
|
||||
i_soundID = Z2SE_FN_JUMP_HEAVY;
|
||||
if (Z2GetLink()->mMagnetized) {
|
||||
param_3 = 127;
|
||||
}
|
||||
}
|
||||
if (Z2GetLink()->mSoundObjSimple1.getHandleSoundID(Z2SE_AL_V_FALL) != NULL) {
|
||||
Z2GetLink()->startLinkVoice(Z2SE_AL_V_FOOT_MISS, -1);
|
||||
}
|
||||
break;
|
||||
case Z2SE_FN_BOUND_DUMMY:
|
||||
case Z2SE_FN_HAND_DUMMY:
|
||||
bVar2 = true;
|
||||
break;
|
||||
case Z2SE_BODY_FALL_DOWN:
|
||||
if (Z2GetLink()->mSoundObjSimple1.getHandleSoundID(Z2SE_AL_V_FALL) != NULL) {
|
||||
Z2GetLink()->startLinkVoice(Z2SE_AL_V_LANDING_FAIL, -1);
|
||||
}
|
||||
break;
|
||||
case Z2SE_OBJ_ARROW_SHOT_NORMAL:
|
||||
case Z2SE_OBJ_ARROW_SHOT_GAIN:
|
||||
case Z2SE_OBJ_ARROWBOMB_SHOT:
|
||||
case Z2SE_OBJ_ARROWBOMB_SHOTGAIN:
|
||||
Z2SoundHandlePool* handle = Z2GetLink()->mSoundObjAnime.getHandleSoundID(Z2SE_AL_DRAW_BOW);
|
||||
if (handle != NULL) {
|
||||
(*handle)->stop(0);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
if (Z2GetLink()->mSinkDepth > 0) {
|
||||
switch (i_soundID) {
|
||||
case Z2SE_FN_WALK_DUMMY:
|
||||
case Z2SE_FN_JUMP_DUMMY:
|
||||
case Z2SE_FN_BOUND_DUMMY:
|
||||
case Z2SE_FN_HAND_DUMMY:
|
||||
case Z2SE_FN_WALK_HEAVY:
|
||||
case Z2SE_FN_JUMP_HEAVY:
|
||||
case Z2SE_WL_WALK_L_DUMMY:
|
||||
case Z2SE_WL_WALK_R_DUMMY:
|
||||
case Z2SE_WL_RUN_L_DUMMY:
|
||||
case Z2SE_WL_RUN_R_DUMMY:
|
||||
if (param_3 == 3) {
|
||||
param_5 *= Z2Calc::linearTransform(Z2GetLink()->mSinkDepth,
|
||||
0.0f, 127.0f, 1.0f, 0.5f, true);
|
||||
} else if (param_3 == 25) {
|
||||
param_5 *= Z2Calc::linearTransform(Z2GetLink()->mSinkDepth,
|
||||
0.0f, 23.0f, 1.0f, 0.7f, true);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
bool ret = Z2SoundStarter::startSound(i_soundID, param_1, param_2, param_3, param_4, param_5,
|
||||
param_6, param_7, param_8, param_9);
|
||||
|
||||
if (bVar2 && Z2GetSceneMgr()->getDemoSeWaveNum() != 114) {
|
||||
if (Z2GetLink()->mFlag5) {
|
||||
Z2GetLink()->startLinkSound(Z2SE_AL_SWORD_SHIELD_ADD, 0, param_4 * 127.0f);
|
||||
}
|
||||
|
||||
if (Z2GetLink()->mUsingIronBall) {
|
||||
Z2GetLink()->startLinkSound(Z2SE_AL_IB_CHAIN_ADD, 0, param_4 * 127.0f);
|
||||
}
|
||||
|
||||
if (Z2GetLink()->mKanteraState != 0) {
|
||||
Z2SoundHandlePool* handle =
|
||||
Z2GetLink()->mKantera.startSound(Z2SE_AL_KANTERA_SWING_ADD, 0, param_4 * 127.0f);
|
||||
if (Z2GetLink()->mKanteraState == 2 && handle != NULL && *handle) {
|
||||
(*handle)->getAuxiliary().moveVolume(0.6f, 0);
|
||||
(*handle)->getAuxiliary().movePitch(0.9f, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (bVar3) {
|
||||
if (Z2GetLink()->mLinkState == 4) {
|
||||
Z2GetLink()->startLinkSound(Z2SE_FN_ARMER_LIGHT_ADD, 0, param_4 * 127.0f);
|
||||
} else if (Z2GetLink()->mLinkState == 5) {
|
||||
Z2GetLink()->startLinkSound(Z2SE_FN_ARMER_HEAVY_ADD, 0, param_4 * 127.0f);
|
||||
}
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* 802C4FFC-802C5078 2BF93C 007C+00 0/0 0/0 3/3 .text __ct__14Z2CreatureRideFv */
|
||||
|
@ -441,14 +681,9 @@ Z2CreatureRide::Z2CreatureRide() : Z2RideSoundStarter(this) {
|
|||
setSoundStarter(this);
|
||||
}
|
||||
|
||||
/* 802C5078-802C5114 2BF9B8 009C+00 1/0 0/0 0/0 .text __dt__18Z2RideSoundStarterFv */
|
||||
inline Z2RideSoundStarter::~Z2RideSoundStarter() {
|
||||
// NONMATCHING
|
||||
}
|
||||
|
||||
/* 802C5114-802C51EC 2BFA54 00D8+00 2/1 0/0 2/2 .text __dt__14Z2CreatureRideFv */
|
||||
Z2CreatureRide::~Z2CreatureRide() {
|
||||
// NONMATCHING
|
||||
deleteObject();
|
||||
}
|
||||
|
||||
/* 802C51EC-802C520C 2BFB2C 0020+00 1/0 0/0 0/0 .text deleteObject__14Z2CreatureRideFv */
|
||||
|
@ -475,61 +710,133 @@ Z2RideSoundStarter::Z2RideSoundStarter(Z2CreatureRide* ride) : Z2SoundStarter(fa
|
|||
|
||||
/* 802C5284-802C54B8 2BFBC4 0234+00 2/0 0/0 0/0 .text
|
||||
* startSound__18Z2RideSoundStarterF10JAISoundIDP14JAISoundHandlePCQ29JGeometry8TVec3<f>UlfffffUl */
|
||||
bool Z2RideSoundStarter::startSound(JAISoundID param_0, JAISoundHandle* param_1,
|
||||
// NONMATCHING regalloc / extra load
|
||||
bool Z2RideSoundStarter::startSound(JAISoundID i_soundID, JAISoundHandle* param_1,
|
||||
JGeometry::TVec3<f32> const* param_2, u32 param_3,
|
||||
f32 param_4, f32 param_5, f32 param_6, f32 param_7,
|
||||
f32 param_8, u32 param_9) {
|
||||
// NONMATCHING
|
||||
if (!Z2GetSceneMgr()->isInGame()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
u8 uVar3 = 0;
|
||||
switch (i_soundID) {
|
||||
case Z2SE_HS_WALK_L_DUMMY:
|
||||
case Z2SE_HS_WALK_R_DUMMY:
|
||||
case Z2SE_HS_TROT_L_DUMMY:
|
||||
case Z2SE_HS_TROT_R_DUMMY:
|
||||
case Z2SE_HS_GALLOP_L_DUMMY:
|
||||
uVar3 = 1;
|
||||
break;
|
||||
case Z2SE_WB_FRONT_L_DUMMY:
|
||||
case Z2SE_WB_FRONT_R_DUMMY:
|
||||
case Z2SE_WB_REAR_L_DUMMY:
|
||||
uVar3 = 2;
|
||||
break;
|
||||
}
|
||||
|
||||
bool ret = Z2SoundStarter::startSound(i_soundID, param_1, param_2, param_3, param_4, param_5,
|
||||
param_6, param_7, param_8, param_9);
|
||||
|
||||
if (mRide->isLinkRiding() && uVar3 != 0) {
|
||||
if (Z2GetLink()->mFlag5) {
|
||||
Z2GetLink()->startLinkSound(Z2SE_AL_SWORD_SHIELD_ADD, 0, param_4 * 127.0f);
|
||||
}
|
||||
|
||||
if (Z2GetLink()->mKanteraState != 0) {
|
||||
Z2SoundHandlePool* handle =
|
||||
Z2GetLink()->mKantera.startSound(Z2SE_AL_KANTERA_SWING_ADD, 0, param_4 * 127.0f);
|
||||
if (Z2GetLink()->mKanteraState == 2 && handle != NULL && *handle) {
|
||||
(*handle)->getAuxiliary().moveVolume(0.6f, 0);
|
||||
(*handle)->getAuxiliary().movePitch(0.9f, 0);
|
||||
}
|
||||
}
|
||||
|
||||
switch (uVar3) {
|
||||
case 1:
|
||||
Z2GetLink()->startLinkSound(Z2SE_AL_HARNESS_ADD_HS, 0, param_4 * 127.0f);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
Z2GetLink()->startLinkSound(Z2SE_AL_HARNESS_ADD_WB, 0, param_4 * 127.0f);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* 802C54B8-802C54FC 2BFDF8 0044+00 0/0 0/0 1/1 .text __ct__15Z2SoundObjCoachFv */
|
||||
Z2SoundObjCoach::Z2SoundObjCoach() {
|
||||
// NONMATCHING
|
||||
field_0x20 = 0.0f;
|
||||
}
|
||||
|
||||
/* 802C54FC-802C551C 2BFE3C 0020+00 1/0 0/0 0/0 .text init__15Z2SoundObjCoachFP3VecUc */
|
||||
void Z2SoundObjCoach::init(Vec* param_0, u8 param_1) {
|
||||
// NONMATCHING
|
||||
void Z2SoundObjCoach::init(Vec* i_soundPos, u8 i_numHandles) {
|
||||
Z2SoundObjBase::init(i_soundPos, i_numHandles);
|
||||
}
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 80455D20-80455D24 004320 0004+00 1/1 0/0 0/0 .sdata2 @4621 */
|
||||
SECTION_SDATA2 static f32 lit_4621 = 2.0f;
|
||||
|
||||
/* 80455D24-80455D28 004324 0004+00 1/1 0/0 0/0 .sdata2 @4622 */
|
||||
SECTION_SDATA2 static f32 lit_4622 = 35.0f;
|
||||
|
||||
/* 80455D28-80455D2C 004328 0004+00 1/1 0/0 0/0 .sdata2 @4623 */
|
||||
SECTION_SDATA2 static f32 lit_4623 = 22.0f / 25.0f;
|
||||
|
||||
/* 80455D2C-80455D30 00432C 0004+00 3/3 0/0 0/0 .sdata2 @4624 */
|
||||
SECTION_SDATA2 static f32 lit_4624 = 1.25f;
|
||||
|
||||
/* 80455D30-80455D34 004330 0004+00 2/2 0/0 0/0 .sdata2 @4625 */
|
||||
SECTION_SDATA2 static f32 lit_4625 = 50.0f;
|
||||
|
||||
/* 802C551C-802C56C0 2BFE5C 01A4+00 0/0 0/0 1/1 .text startWheelSound__15Z2SoundObjCoachFf */
|
||||
void Z2SoundObjCoach::startWheelSound(f32 param_0) {
|
||||
// NONMATCHING
|
||||
Z2SoundHandlePool* Z2SoundObjCoach::startWheelSound(f32 param_0) {
|
||||
Z2SoundHandlePool* handle = NULL;
|
||||
|
||||
if (!(param_0 < 2.0f)) {
|
||||
if (param_0 < 35.0f) {
|
||||
handle = startLevelSound(Z2SE_COACH_WHEEL_ROLL_A, 0, -1);
|
||||
if (handle != NULL && *handle) {
|
||||
f32 pitch = Z2Calc::getParamByExp(param_0, 0.0f, 35.0f, 0.25f, 0.88f, 1.25f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
(*handle)->getAuxiliary().movePitch(pitch, 0);
|
||||
f32 volume = Z2Calc::getParamByExp(param_0, 0.0f, 35.0f, 0.3f, 0.7f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
(*handle)->getAuxiliary().moveVolume(volume, 0);
|
||||
}
|
||||
} else {
|
||||
handle = startLevelSound(Z2SE_COACH_WHEEL_ROLL_B, 0, -1);
|
||||
if (handle != NULL && *handle) {
|
||||
f32 pitch = Z2Calc::getParamByExp(param_0, 35.0f, 50.0f, 0.25f, 0.88f, 1.25f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
(*handle)->getAuxiliary().movePitch(pitch, 0);
|
||||
f32 volume = Z2Calc::getParamByExp(param_0, 35.0f, 50.0f, 0.3f, 0.8f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
(*handle)->getAuxiliary().moveVolume(volume, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 80455D34-80455D38 004334 0004+00 1/1 0/0 0/0 .sdata2 @4645 */
|
||||
SECTION_SDATA2 static f32 lit_4645 = 1500.0f;
|
||||
|
||||
/* 80455D38-80455D3C 004338 0004+00 2/2 0/0 0/0 .sdata2 @4646 */
|
||||
SECTION_SDATA2 static f32 lit_4646 = 1.0f / 5.0f;
|
||||
|
||||
/* 80455D3C-80455D40 00433C 0004+00 2/2 0/0 0/0 .sdata2 @4647 */
|
||||
SECTION_SDATA2 static f32 lit_4647 = 17.0f / 20.0f;
|
||||
field_0x20 = param_0;
|
||||
return handle;
|
||||
}
|
||||
|
||||
/* 802C56C0-802C57C0 2C0000 0100+00 0/0 0/0 1/1 .text startFireSound__15Z2SoundObjCoachFUs */
|
||||
void Z2SoundObjCoach::startFireSound(u16 param_0) {
|
||||
// NONMATCHING
|
||||
Z2SoundHandlePool* Z2SoundObjCoach::startFireSound(u16 param_0) {
|
||||
Z2SoundHandlePool* handle = startLevelSound(Z2SE_COACH_FIRE, 0, -1);
|
||||
|
||||
if (handle != NULL && *handle) {
|
||||
f32 pitch = Z2Calc::getParamByExp(param_0, 0.0f, 1500.0f, 0.2f, 0.85f, 1.25f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
(*handle)->getAuxiliary().movePitch(pitch, 0);
|
||||
f32 volume = Z2Calc::getParamByExp(param_0, 0.0f, 1500.0f, 0.2f, 0.6f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
(*handle)->getAuxiliary().moveVolume(volume, 0);
|
||||
}
|
||||
|
||||
return handle;
|
||||
}
|
||||
|
||||
/* 802C57C0-802C588C 2C0100 00CC+00 1/0 0/0 0/0 .text
|
||||
* startSound__15Z2SoundObjCoachF10JAISoundIDUlSc */
|
||||
int Z2SoundObjCoach::startSound(JAISoundID param_0, u32 param_1, s8 param_2) {
|
||||
// NONMATCHING
|
||||
Z2SoundHandlePool* Z2SoundObjCoach::startSound(JAISoundID i_soundID, u32 param_1, s8 param_2) {
|
||||
Z2SoundHandlePool* handle = Z2SoundObjBase::startSound(i_soundID, param_1, param_2);
|
||||
|
||||
if (handle != NULL && *handle && i_soundID == Z2SE_COACH_SHAKE) {
|
||||
f32 pitch = Z2Calc::getParamByExp(field_0x20, 0.0f, 50.0f, 0.2f, 0.85f, 1.25f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
(*handle)->getAuxiliary().movePitch(pitch, 0);
|
||||
f32 volume = Z2Calc::getParamByExp(field_0x20, 0.0f, 50.0f, 0.2f, 0.8f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
(*handle)->getAuxiliary().moveVolume(volume, 0);
|
||||
}
|
||||
|
||||
return handle;
|
||||
}
|
||||
|
|
|
@ -167,7 +167,3 @@ u8 struct_80451341;
|
|||
u8 struct_80451342;
|
||||
u8 pad_80451344[4];
|
||||
#pragma pop
|
||||
|
||||
/* 80451348-80451350 000848 0008+00 0/0 4/4 0/0 .sbss None */
|
||||
extern u8 data_80451348[8];
|
||||
u8 data_80451348[8];
|
|
@ -6,49 +6,14 @@
|
|||
#include "Z2AudioLib/Z2SeMgr.h"
|
||||
#include "Z2AudioLib/Z2Audience.h"
|
||||
#include "Z2AudioLib/Z2Calc.h"
|
||||
#include "Z2AudioLib/Z2LinkMgr.h"
|
||||
#include "Z2AudioLib/Z2SoundMgr.h"
|
||||
#include "Z2AudioLib/Z2SceneMgr.h"
|
||||
#include "Z2AudioLib/Z2SpeechMgr2.h"
|
||||
#include "Z2AudioLib/Z2StatusMgr.h"
|
||||
#include "Z2AudioLib/Z2Param.h"
|
||||
#include "Z2AudioLib/Z2SeqMgr.h"
|
||||
#include "dol2asm.h"
|
||||
|
||||
//
|
||||
// Forward References:
|
||||
//
|
||||
|
||||
extern "C" void __ct__7Z2SeMgrFv();
|
||||
extern "C" void __ct__12Z2MultiSeObjFv();
|
||||
extern "C" void initSe__7Z2SeMgrFv();
|
||||
extern "C" void resetModY__7Z2SeMgrFv();
|
||||
extern "C" void modHeightAtCamera__7Z2SeMgrFPPC3Vec();
|
||||
extern "C" void incrCrowdSize__7Z2SeMgrFv();
|
||||
extern "C" void decrCrowdSize__7Z2SeMgrFv();
|
||||
extern "C" void seStart__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc();
|
||||
extern "C" void seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc();
|
||||
extern "C" void seStop__7Z2SeMgrF10JAISoundIDUl();
|
||||
extern "C" void seStopAll__7Z2SeMgrFUl();
|
||||
extern "C" void seMoveVolumeAll__7Z2SeMgrFfUl();
|
||||
extern "C" void messageSePlay__7Z2SeMgrFUsP3VecSc();
|
||||
extern "C" void talkInSe__7Z2SeMgrFv();
|
||||
extern "C" void talkOutSe__7Z2SeMgrFv();
|
||||
extern "C" void menuInSe__7Z2SeMgrFv();
|
||||
extern "C" void setLevObjSE__7Z2SeMgrFUlP3VecSc();
|
||||
extern "C" void setMultiTriggerSE__7Z2SeMgrFUlP3VecSc();
|
||||
extern "C" void processSeFramework__7Z2SeMgrFv();
|
||||
extern "C" void isLevelSe__7Z2SeMgrF10JAISoundID();
|
||||
extern "C" void isSoundCulling__7Z2SeMgrF10JAISoundID();
|
||||
extern "C" void __ct__12Z2MultiSeMgrFv();
|
||||
extern "C" void __dt__12Z2MultiSeMgrFv();
|
||||
extern "C" void registMultiSePos__12Z2MultiSeMgrFP3Vec();
|
||||
extern "C" void resetMultiSePos__12Z2MultiSeMgrFv();
|
||||
extern "C" void getPanPower__12Z2MultiSeMgrFv();
|
||||
extern "C" void getDolbyPower__12Z2MultiSeMgrFv();
|
||||
|
||||
//
|
||||
// Declarations:
|
||||
//
|
||||
#include "JSystem/J3DU/J3DUD.h"
|
||||
|
||||
/* 802AB64C-802AB710 2A5F8C 00C4+00 0/0 1/1 0/0 .text __ct__7Z2SeMgrFv */
|
||||
Z2SeMgr::Z2SeMgr() : JASGlobalInstance(this), mSoundHandles(mSoundHandle, 0x18) {
|
||||
|
@ -145,12 +110,12 @@ void Z2SeMgr::decrCrowdSize() {
|
|||
|
||||
/* 802AB984-802AC50C 2A62C4 0B88+00 1/1 196/196 549/549 .text
|
||||
* seStart__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc */
|
||||
// NONMATCHING something is wrong with the switch, also isMovieDemo needs to not get inlined
|
||||
bool Z2SeMgr::seStart(JAISoundID i_soundID, Vec const* i_pos, u32 param_2, s8 i_reverb,
|
||||
f32 i_pitch, f32 i_volume, f32 i_pan, f32 i_dolby, u8 param_8) {
|
||||
if (i_soundID == 0xffffffff) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (param_8 != 1) {
|
||||
switch (i_soundID) {
|
||||
case Z2SE_OBJ_L8_STAIR_ON:
|
||||
|
@ -165,6 +130,7 @@ bool Z2SeMgr::seStart(JAISoundID i_soundID, Vec const* i_pos, u32 param_2, s8 i_
|
|||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
switch (i_soundID) {
|
||||
case Z2SE_QUIT_GAME:
|
||||
Z2GetStatusMgr()->menuOut();
|
||||
|
@ -177,7 +143,7 @@ bool Z2SeMgr::seStart(JAISoundID i_soundID, Vec const* i_pos, u32 param_2, s8 i_
|
|||
seStop(JA_SE_OBJ_STN_DOOR_MOVE_D, 0);
|
||||
break;
|
||||
case JA_SE_OBJ_STN_DOOR_STOP_D:
|
||||
seStop(JA_SE_OBJ_STN_DOOR_STOP_D, 0);
|
||||
seStop(JA_SE_OBJ_STN_DOOR_MOVE_U, 0);
|
||||
seStop(JA_SE_OBJ_STN_DOOR_MOVE_D, 0);
|
||||
break;
|
||||
case JA_SE_OBJ_STN_DOOR_MOVE_D:
|
||||
|
@ -185,6 +151,7 @@ bool Z2SeMgr::seStart(JAISoundID i_soundID, Vec const* i_pos, u32 param_2, s8 i_
|
|||
seStop(JA_SE_OBJ_STN_DOOR_MOVE_U, 0);
|
||||
seStop(JA_SE_OBJ_STN_DOOR_MOVE_D, 0);
|
||||
break;
|
||||
case Z2SE_OBJ_WOOD_DOOR_ROLLOPEN:
|
||||
case Z2SE_OBJ_WOOD_DOOR_ROLLOPEN2:
|
||||
case Z2SE_OBJ_WOOD_DR_OP_MDN:
|
||||
case Z2SE_OBJ_WOOD_DR_OP_MDN_FX:
|
||||
|
@ -193,11 +160,10 @@ bool Z2SeMgr::seStart(JAISoundID i_soundID, Vec const* i_pos, u32 param_2, s8 i_
|
|||
seStop(Z2SE_OBJ_WOOD_DOOR_ROLLCLOSE, 0);
|
||||
break;
|
||||
case Z2SE_OBJ_WOOD_DOOR_CLOSE_STOP:
|
||||
seStop(Z2SE_OBJ_WOOD_DOOR_CLOSE_STOP, 0);
|
||||
seStop(Z2SE_OBJ_WOOD_DOOR_ROLLOPEN, 0);
|
||||
seStop(Z2SE_OBJ_WOOD_DOOR_ROLLOPEN2, 0);
|
||||
seStop(Z2SE_OBJ_WOOD_DOOR_ROLLCLOSE, 0);
|
||||
break;
|
||||
case Z2SE_OBJ_WOOD_DOOR_ROLLOPEN:
|
||||
case Z2SE_OBJ_WOOD_DOOR_ROLLCLOSE:
|
||||
case Z2SE_OBJ_WOOD_DOOR_OPEN_STOP:
|
||||
seStop(Z2SE_OBJ_WOOD_DOOR_ROLLOPEN, 0);
|
||||
|
@ -314,12 +280,13 @@ bool Z2SeMgr::seStart(JAISoundID i_soundID, Vec const* i_pos, u32 param_2, s8 i_
|
|||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 41.0f, 0.4f, 0.3f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_2);
|
||||
break;
|
||||
case Z2SE_OBJ_L8_B_FOG_FLY:
|
||||
case Z2SE_OBJ_L8_B_FOG_FLY: {
|
||||
Vec tmp = Z2GetAudience()->getAudioCamPos(0);
|
||||
if (i_pos->y > tmp.y) {
|
||||
return false;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case Z2SE_OBJ_BLN_BREAK_S:
|
||||
case Z2SE_OBJ_BLN_BREAK_M:
|
||||
case Z2SE_OBJ_BLN_BREAK_L:
|
||||
|
@ -354,157 +321,387 @@ bool Z2SeMgr::seStart(JAISoundID i_soundID, Vec const* i_pos, u32 param_2, s8 i_
|
|||
i_soundID = Z2SE_OBJ_DARK_GATE_RIPPLE_WLF;
|
||||
}
|
||||
break;
|
||||
case Z2SE_OBJ_ARMOR_SWING:
|
||||
case Z2SE_OBJ_ARMOR_HIT:
|
||||
break;
|
||||
}
|
||||
|
||||
if (isLevelSe(i_soundID)) {
|
||||
return seStartLevel(i_soundID, i_pos, param_2, i_reverb, i_pitch,
|
||||
i_volume, i_pan, i_dolby, param_8);
|
||||
}
|
||||
|
||||
if (isSoundCulling(i_soundID)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
JAISoundHandle* handle = mSoundHandles.getFreeHandle();
|
||||
if (handle == NULL) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return Z2GetSoundStarter()->startSound(i_soundID, handle, (JGeometry::TVec3<f32>*)i_pos,
|
||||
param_2, i_reverb / 127.0f,
|
||||
i_pitch, i_volume, i_pan, i_dolby, 0);
|
||||
}
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 803C9D98-803C9DF8 -00001 0060+00 1/1 0/0 0/0 .data @4619 */
|
||||
SECTION_DATA static void* lit_4619[24] = {
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xF78),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xF78),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xF78),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xF78),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xF84),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xF90),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xF9C),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xFA8),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xFB4),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xFC0),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xFCC),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xFD8),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0x1028),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0x1028),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0x1028),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0x1028),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0x1028),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0x1028),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xFE4),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xFF0),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0xFFC),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0x1008),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0x1014),
|
||||
(void*)(((char*)seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc) + 0x1020),
|
||||
};
|
||||
|
||||
/* 804558E8-804558EC 003EE8 0004+00 1/1 0/0 0/0 .sdata2 @4586 */
|
||||
SECTION_SDATA2 static f32 lit_4586 = 25.0f;
|
||||
|
||||
/* 804558EC-804558F0 003EEC 0004+00 1/1 0/0 0/0 .sdata2 @4587 */
|
||||
SECTION_SDATA2 static f32 lit_4587 = 1.0f / 10.0f;
|
||||
|
||||
/* 804558F0-804558F4 003EF0 0004+00 1/1 0/0 0/0 .sdata2 @4588 */
|
||||
SECTION_SDATA2 static f32 lit_4588 = 10.0f;
|
||||
|
||||
/* 804558F4-804558F8 003EF4 0004+00 1/1 0/0 0/0 .sdata2 @4589 */
|
||||
SECTION_SDATA2 static f32 lit_4589 = 2.0f;
|
||||
|
||||
/* 804558F8-80455900 003EF8 0004+04 2/2 0/0 0/0 .sdata2 @4590 */
|
||||
SECTION_SDATA2 static f32 lit_4590[1 + 1 /* padding */] = {
|
||||
13.0f / 10.0f,
|
||||
/* padding */
|
||||
0.0f,
|
||||
};
|
||||
|
||||
/* 80455900-80455908 003F00 0008+00 1/1 0/0 0/0 .sdata2 @4591 */
|
||||
SECTION_SDATA2 static f64 lit_4591 = 0.7;
|
||||
|
||||
/* 80455908-80455910 003F08 0008+00 1/1 0/0 0/0 .sdata2 @4592 */
|
||||
SECTION_SDATA2 static f64 lit_4592 = 0.0006;
|
||||
|
||||
/* 80455910-80455918 003F10 0008+00 1/1 0/0 0/0 .sdata2 @4593 */
|
||||
SECTION_SDATA2 static f64 lit_4593 = 1.0;
|
||||
|
||||
/* 80455918-80455920 003F18 0008+00 1/1 0/0 0/0 .sdata2 @4594 */
|
||||
SECTION_SDATA2 static f64 lit_4594 = 0.0015;
|
||||
|
||||
/* 80455920-80455928 003F20 0008+00 1/1 0/0 0/0 .sdata2 @4595 */
|
||||
SECTION_SDATA2 static f64 lit_4595 = 0.005;
|
||||
|
||||
/* 80455928-80455930 003F28 0008+00 1/1 0/0 0/0 .sdata2 @4596 */
|
||||
SECTION_SDATA2 static f64 lit_4596 = 0.3;
|
||||
|
||||
/* 80455930-80455938 003F30 0008+00 1/1 0/0 0/0 .sdata2 @4597 */
|
||||
SECTION_SDATA2 static f64 lit_4597 = 0.001;
|
||||
|
||||
/* 80455938-8045593C 003F38 0004+00 1/1 0/0 0/0 .sdata2 @4598 */
|
||||
SECTION_SDATA2 static f32 lit_4598 = 4000.0f;
|
||||
|
||||
/* 8045593C-80455940 003F3C 0004+00 1/1 0/0 0/0 .sdata2 @4599 */
|
||||
SECTION_SDATA2 static f32 lit_4599 = 3500.0f;
|
||||
|
||||
/* 80455940-80455944 003F40 0004+00 1/1 0/0 0/0 .sdata2 @4600 */
|
||||
SECTION_SDATA2 static f32 lit_4600 = 26.0f;
|
||||
|
||||
/* 80455944-80455948 003F44 0004+00 1/1 0/0 0/0 .sdata2 @4601 */
|
||||
SECTION_SDATA2 static f32 lit_4601 = 3.0f / 5.0f;
|
||||
|
||||
/* 80455948-8045594C 003F48 0004+00 1/1 0/0 0/0 .sdata2 @4602 */
|
||||
SECTION_SDATA2 static f32 lit_4602 = 64.0f;
|
||||
|
||||
/* 8045594C-80455950 003F4C 0004+00 1/1 0/0 0/0 .sdata2 @4603 */
|
||||
SECTION_SDATA2 static f32 lit_4603 = 4500.0f;
|
||||
|
||||
/* 80455950-80455954 003F50 0004+00 1/1 0/0 0/0 .sdata2 @4604 */
|
||||
SECTION_SDATA2 static f32 lit_4604 = 40.0f;
|
||||
|
||||
/* 80455954-80455958 003F54 0004+00 1/1 0/0 0/0 .sdata2 @4605 */
|
||||
SECTION_SDATA2 static f32 lit_4605 = 120.0f;
|
||||
|
||||
/* 80455958-80455960 003F58 0004+04 1/1 0/0 0/0 .sdata2 @4606 */
|
||||
SECTION_SDATA2 static f32 lit_4606[1 + 1 /* padding */] = {
|
||||
5.0f,
|
||||
/* padding */
|
||||
0.0f,
|
||||
};
|
||||
|
||||
/* 80455960-80455968 003F60 0008+00 1/1 0/0 0/0 .sdata2 @4607 */
|
||||
SECTION_SDATA2 static f64 lit_4607 = 0.5;
|
||||
|
||||
/* 80455968-80455970 003F68 0008+00 1/1 0/0 0/0 .sdata2 @4608 */
|
||||
SECTION_SDATA2 static f64 lit_4608 = 3.0;
|
||||
|
||||
/* 80455970-80455978 003F70 0008+00 1/1 0/0 0/0 .sdata2 @4609 */
|
||||
SECTION_SDATA2 static u8 lit_4609[8] = {
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
};
|
||||
|
||||
/* 80455978-8045597C 003F78 0004+00 1/1 0/0 0/0 .sdata2 @4610 */
|
||||
SECTION_SDATA2 static f32 lit_4610 = 2000.0f;
|
||||
|
||||
/* 8045597C-80455980 003F7C 0004+00 1/1 0/0 0/0 .sdata2 @4611 */
|
||||
SECTION_SDATA2 static f32 lit_4611 = 5000.0f;
|
||||
|
||||
/* 80455980-80455984 003F80 0004+00 1/1 0/0 0/0 .sdata2 @4612 */
|
||||
SECTION_SDATA2 static f32 lit_4612 = 9.0f / 20.0f;
|
||||
|
||||
/* 80455984-80455988 003F84 0004+00 1/1 0/0 0/0 .sdata2 @4613 */
|
||||
SECTION_SDATA2 static f32 lit_4613 = 50.0f;
|
||||
|
||||
/* 80455988-8045598C 003F88 0004+00 1/1 0/0 0/0 .sdata2 @4614 */
|
||||
SECTION_SDATA2 static f32 lit_4614 = 600.0f;
|
||||
|
||||
/* 8045598C-80455990 003F8C 0004+00 1/1 0/0 0/0 .sdata2 @4615 */
|
||||
SECTION_SDATA2 static f32 lit_4615 = 90.0f;
|
||||
|
||||
/* 802AC50C-802AD8B0 2A6E4C 13A4+00 3/2 19/19 199/199 .text
|
||||
* seStartLevel__7Z2SeMgrF10JAISoundIDPC3VecUlScffffUc */
|
||||
bool Z2SeMgr::seStartLevel(JAISoundID param_0, Vec const* param_1, u32 param_2, s8 param_3,
|
||||
f32 param_4, f32 param_5, f32 param_6, f32 param_7, u8 param_8) {
|
||||
// NONMATCHING
|
||||
bool Z2SeMgr::seStartLevel(JAISoundID i_soundID, Vec const* i_pos, u32 param_2, s8 i_reverb,
|
||||
f32 i_pitch, f32 i_volume, f32 i_pan, f32 i_dolby, u8 param_8) {
|
||||
if (param_8 != 1) {
|
||||
switch (i_soundID) {
|
||||
case Z2SE_OBJ_FIRE_BURNING:
|
||||
if (Z2GetStatusMgr()->getDemoStatus() == 2 || !Z2GetSceneMgr()->isInGame()) {
|
||||
return false;
|
||||
}
|
||||
// fallthrough
|
||||
case Z2SE_FAIRY_S_LV:
|
||||
case Z2SE_EN_ZZ_MV:
|
||||
case Z2SE_OBJ_L8_L_BALL_SW:
|
||||
case Z2SE_OBJ_GANON_BARRIER:
|
||||
case Z2SE_OBJ_CRVN_BURNING:
|
||||
setLevObjSE(i_soundID, const_cast<Vec*>(i_pos), i_reverb);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
switch (i_soundID) {
|
||||
case Z2SE_OBJ_FLAG_TRAILING:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 25.0f, 127.0f, 0.4f, 0.1f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 25.0f, 127.0f, 0.4f, 0.7f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_BRIDGE_TRAILING:
|
||||
case Z2SE_OBJ_BROKENBRIDGE:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 127.0f, 0.4f, 0.1f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 0.0f, 127.0f, 0.4f, 0.7f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_BOOMSHTR_SWITCH:
|
||||
if (param_2 < 10) {
|
||||
param_2 = 10;
|
||||
}
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 10.0f, 127.0f, 2.0f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 10.0f, 127.0f, 2.0f, 0.7f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
break;
|
||||
case Z2SE_OBJ_FAN_WIND_S:
|
||||
modHeightAtCamera(&i_pos);
|
||||
break;
|
||||
case Z2SE_OBJ_FAN_ROLL_S:
|
||||
case Z2SE_OBJ_FAN_ROLL_M:
|
||||
case Z2SE_OBJ_FAN_ROLL_L:
|
||||
if (param_2 < 10) {
|
||||
param_2 = 10;
|
||||
}
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 10.0f, 127.0f, 2.0f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 10.0f, 127.0f, 2.0f, 0.7f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
break;
|
||||
case Z2SE_OBJ_AMI_ROLL:
|
||||
if (param_2 < 10) {
|
||||
param_2 = 10;
|
||||
}
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 10.0f, 127.0f, 2.0f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 10.0f, 127.0f, 2.0f, 0.7f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
break;
|
||||
case Z2SE_OBJ_BRDG_MOVE:
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 0.0f, 127.0f, 2.0f, 0.7f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
break;
|
||||
case Z2SE_ENV_WIND_SARUDAN:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 25.0f, 127.0f, 0.4f, 0.4f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 25.0f, 127.0f, 0.4f, 0.8f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_CHANDLV9_SWING:
|
||||
if (param_2 < 10) {
|
||||
param_2 = 10;
|
||||
}
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 10.0f, 127.0f, 2.0f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 10.0f, 127.0f, 2.0f, 0.7f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_1);
|
||||
break;
|
||||
case Z2SE_OBJ_BOMB_HOUSE_BURN:
|
||||
if (param_2 > 300) {
|
||||
seStartLevel(Z2SE_OBJ_BOMB_HOUSE_BURN_S, NULL, param_2, 0, 1.0f, 1.0f, -1.0f, -1.0f, 0);
|
||||
}
|
||||
if (param_2 > 500) {
|
||||
i_volume = 1.0f;
|
||||
i_pitch = 1.3f;
|
||||
} else {
|
||||
i_volume = param_2 * 0.0006 + 0.7;
|
||||
i_pitch = param_2 * 0.0006 + 1.0;
|
||||
}
|
||||
break;
|
||||
case Z2SE_OBJ_BOMB_HOUSE_BURN_S:
|
||||
if (param_2 > 500) {
|
||||
i_volume = 1.0f;
|
||||
i_pitch = (param_2 - 500) * 0.0015 + 1.0;
|
||||
} else if (param_2 < 300) {
|
||||
i_volume = 0.0f;
|
||||
} else {
|
||||
i_volume = (param_2 - 300) * 0.005;
|
||||
}
|
||||
break;
|
||||
case Z2SE_OBJ_WTR_CLMN_UP:
|
||||
if (param_2 <= 500) {
|
||||
i_pitch = 0.8f;
|
||||
} else if (param_2 > 500 && param_2 <= 1000) {
|
||||
i_pitch = 1.0f;
|
||||
} else if (param_2 > 1000 && param_2 <= 1500) {
|
||||
i_pitch = 1.0f;
|
||||
} else {
|
||||
i_pitch = 1.2f;
|
||||
}
|
||||
modHeightAtCamera(&i_pos);
|
||||
break;
|
||||
case Z2SE_OBJ_WTR_CLMN_DOWN:
|
||||
if (param_2 > 700) {
|
||||
i_pitch = 1.0f;
|
||||
} else {
|
||||
i_pitch = param_2 * 0.001 + 0.3;
|
||||
}
|
||||
modHeightAtCamera(&i_pos);
|
||||
break;
|
||||
case Z2SE_OBJ_STN_SPRL_RAIL:
|
||||
case Z2SE_OBJ_STN_SPRL_RAIL_DW:
|
||||
modHeightAtCamera(&i_pos);
|
||||
break;
|
||||
case Z2SE_OBJ_SPNR_GEAR_S:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 4000.0f, 0.4f, 0.3f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 0.0f, 4000.0f, 0.4f, 0.7f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_SPNR_GEAR_L:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 3500.0f, 0.4f, 0.3f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 0.0f, 3500.0f, 0.4f, 0.7f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_TOGE_SPIN:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 26.0f, 0.4f, 0.6f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 0.0f, 26.0f, 0.4f, 0.8f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_STN_WL_RL:
|
||||
case Z2SE_OBJ_STN_WL_RL_OP:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 64.0f, 0.4f, 0.3f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 0.0f, 64.0f, 0.4f, 0.6f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_SPNR_SW_RL:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 4500.0f, 0.4f, 0.6f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 0.0f, 4500.0f, 0.4f, 0.7f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_TOGE_ROLL_MV:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 40.0f, 0.4f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 0.0f, 40.0f, 0.4f, 0.8f, 1.2f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_L8_L_TORCH_SW:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 120.0f, 0.4f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 0.0f, 120.0f, 0.4f, 0.9f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_L8_B_FOG_STAY:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 100.0f, 0.4f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_L8_B_FALL_S:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 100.0f, 0.4f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_L8_B_FALL_L:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 100.0f, 0.4f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_L8_L_LIFT_MV:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 5.0f, 0.4f, 0.5f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 0.0f, 5.0f, 0.4f, 0.7f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_AMATA_CRK:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 400.0f, 0.4f, 0.5f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
i_pitch = Z2Calc::getParamByExp(param_2, 0.0f, 400.0f, 0.4f, 0.8f, 1.1f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_OBJ_HYRULE_BARRIER:
|
||||
if (Z2GetSceneMgr()->getCurrentSceneNum() != 0x16) {
|
||||
break;
|
||||
}
|
||||
// fallthrough
|
||||
case Z2SE_OBJ_DARK_GATE:
|
||||
if (!Z2GetSceneMgr()->isInDarkness() && i_pos != NULL
|
||||
&& Z2GetLink() != NULL && Z2GetLink()->getCurrentPos() != NULL)
|
||||
{
|
||||
f32 dist = sqrtf(VECSquareDistance(i_pos, Z2GetLink()->getCurrentPos()));
|
||||
f32 gate_volume = 1.0f;
|
||||
if (dist < 2000.0f) {
|
||||
gate_volume = 0.0f;
|
||||
} else if (dist < 4000.0f) {
|
||||
gate_volume = Z2Calc::getParamByExp(dist, 2000.0f, 5000.0f, 0.45f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
}
|
||||
Z2GetSeqMgr()->setTwilightGateVol(gate_volume);
|
||||
}
|
||||
break;
|
||||
case Z2SE_OBJ_HASU_WTR:
|
||||
i_volume = Z2Calc::getParamByExp(param_2, 0.0f, 50.0f, 0.4f, 0.5f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
case Z2SE_ENV_PEOPLE_CROWD: {
|
||||
f32 scale = 1.0f;
|
||||
if (Z2GetSceneMgr()->getCurrentRoomNum() == 3) {
|
||||
scale = Z2Calc::linearTransform(J3DUD::JMAAbs(Z2GetLink()->getCurrentPos()->x),
|
||||
600.0f, 3500.0f, 1.0f, 0.1f, false);
|
||||
}
|
||||
switch (Z2GetStatusMgr()->getHour()) {
|
||||
case 0:
|
||||
case 1:
|
||||
case 2:
|
||||
case 3:
|
||||
scale *= 0.1f;
|
||||
break;
|
||||
case 4:
|
||||
scale *= 0.2f;
|
||||
break;
|
||||
case 5:
|
||||
scale *= 0.3f;
|
||||
break;
|
||||
case 6:
|
||||
scale *= 0.4f;
|
||||
break;
|
||||
case 7:
|
||||
scale *= 0.5f;
|
||||
break;
|
||||
case 8:
|
||||
scale *= 0.6f;
|
||||
break;
|
||||
case 9:
|
||||
scale *= 0.7f;
|
||||
break;
|
||||
case 10:
|
||||
scale *= 0.8f;
|
||||
break;
|
||||
case 11:
|
||||
scale *= 0.9f;
|
||||
break;
|
||||
case 18:
|
||||
scale *= 0.9f;
|
||||
break;
|
||||
case 19:
|
||||
scale *= 0.8f;
|
||||
break;
|
||||
case 20:
|
||||
scale *= 0.7f;
|
||||
break;
|
||||
case 21:
|
||||
scale *= 0.5f;
|
||||
break;
|
||||
case 22:
|
||||
scale *= 0.4f;
|
||||
break;
|
||||
case 23:
|
||||
scale *= 0.2f;
|
||||
break;
|
||||
}
|
||||
i_volume = Z2Calc::getParamByExp(mCrowdSize * scale, 5.0f, 90.0f, 0.2f, 0.0f, 1.0f,
|
||||
Z2Calc::CURVE_SIGN_0);
|
||||
break;
|
||||
}
|
||||
case Z2SE_AL_COPYROD_WAIT:
|
||||
param_2++;
|
||||
break;
|
||||
}
|
||||
|
||||
for (int i = 0; i < 24; i++) {
|
||||
if (mSoundHandles[i] && mSoundHandles[i]->getID() == i_soundID
|
||||
&& i_pos == (Vec*)mSoundHandles[i]->getUserData())
|
||||
{
|
||||
if (param_8 == 1) {
|
||||
i_volume = Z2GetAudience()->calcOffMicSound(i_volume);
|
||||
}
|
||||
|
||||
mSoundHandles[i]->updateLifeTime(1);
|
||||
|
||||
if (i_pos != NULL) {
|
||||
mSoundHandles[i]->setPos((JGeometry::TVec3<f32>)*i_pos);
|
||||
}
|
||||
|
||||
if (param_2 != 0) {
|
||||
JAISoundHandle* handle = &mSoundHandles[i];
|
||||
Z2GetSoundStarter()->setPortData(handle, 6, param_2, -1);
|
||||
}
|
||||
|
||||
if (i_reverb != 0) {
|
||||
mSoundHandles[i]->getAuxiliary().moveFxMix(i_reverb / 127.0f, 0);
|
||||
}
|
||||
if (i_pitch != 1.0f) {
|
||||
mSoundHandles[i]->getAuxiliary().movePitch(i_pitch, 0);
|
||||
}
|
||||
if (i_volume != 1.0f) {
|
||||
mSoundHandles[i]->getAuxiliary().moveVolume(i_volume, 0);
|
||||
}
|
||||
if (i_pan != -1.0f) {
|
||||
mSoundHandles[i]->getAuxiliary().movePan(i_pan, 0);
|
||||
}
|
||||
if (i_dolby != -1.0f) {
|
||||
mSoundHandles[i]->getAuxiliary().moveDolby(i_dolby, 0);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
if (isSoundCulling(i_soundID)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
JAISoundHandle* handle = mSoundHandles.getFreeHandle();
|
||||
if (handle == NULL) {
|
||||
return false;
|
||||
}
|
||||
|
||||
bool ret = Z2GetSoundStarter()->startSound(i_soundID, handle, (JGeometry::TVec3<f32>*)i_pos,
|
||||
param_2, i_reverb / 127.0f, i_pitch, i_volume,
|
||||
i_pan, i_dolby, false);
|
||||
|
||||
if (handle != NULL && *handle) {
|
||||
if (i_soundID == Z2SE_OBJ_BOMB_HOUSE_BURN) {
|
||||
Z2GetSeqMgr()->bgmStart(Z2BGM_EVENT02, 0, 0);
|
||||
}
|
||||
|
||||
if (param_8 == 1) {
|
||||
Z2GetAudience()->calcOffMicSound(i_volume);
|
||||
}
|
||||
|
||||
(*handle)->setUserData((u32)i_pos);
|
||||
|
||||
if (ret) {
|
||||
(*handle)->setLifeTime(1, false);
|
||||
}
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* 802AD8B0-802AD94C 2A81F0 009C+00 1/1 0/0 4/4 .text seStop__7Z2SeMgrF10JAISoundIDUl */
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
//
|
||||
|
||||
#include "Z2AudioLib/Z2SeqMgr.h"
|
||||
#include "Z2AudioLib/Z2Creature.h"
|
||||
#include "Z2AudioLib/Z2LinkMgr.h"
|
||||
#include "Z2AudioLib/Z2Param.h"
|
||||
#include "Z2AudioLib/Z2SceneMgr.h"
|
||||
#include "Z2AudioLib/Z2SoundMgr.h"
|
||||
|
|
|
@ -19,7 +19,6 @@ void Z2SoundHandles::initHandlesPool(u8 pNumHandles) {
|
|||
}
|
||||
|
||||
/* 802AB120-802AB200 2A5A60 00E0+00 1/1 1/1 0/0 .text deleteHandlesPool__14Z2SoundHandlesFv */
|
||||
// NONMATCHING JASPoolAllocObject<_> locations
|
||||
void Z2SoundHandles::deleteHandlesPool() {
|
||||
JSULink<Z2SoundHandlePool>* link;
|
||||
while (link = getFirst(), link != NULL) {
|
||||
|
@ -60,7 +59,6 @@ Z2SoundHandlePool* Z2SoundHandles::getHandleUserData(u32 pUserData) {
|
|||
|
||||
/* 802AB2D8-802AB3D0 2A5C18 00F8+00 0/0 3/3 0/0 .text getFreeHandle__14Z2SoundHandlesFv
|
||||
*/
|
||||
// NONMATCHING JASPoolAllocObject<_> locations
|
||||
Z2SoundHandlePool* Z2SoundHandles::getFreeHandle() {
|
||||
JSULink<Z2SoundHandlePool>* link;
|
||||
for (link = getFirst(); link != NULL; link = link->getNext()) {
|
||||
|
@ -133,7 +131,6 @@ bool Z2SoundHandles::isActive() const {
|
|||
|
||||
/* 802AB538-802AB64C 2A5E78 0114+00 0/0 1/1 0/0 .text
|
||||
* setPos__14Z2SoundHandlesFRCQ29JGeometry8TVec3<f> */
|
||||
// NONMATCHING JASPoolAllocObject<_> locations
|
||||
void Z2SoundHandles::setPos(JGeometry::TVec3<f32> const& param_0) {
|
||||
JSULink<Z2SoundHandlePool>* link;
|
||||
for (link = getFirst(); link != NULL; link = link->getNext()) {
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
#include "Z2AudioLib/Z2SeqMgr.h"
|
||||
#include "Z2AudioLib/Z2Calc.h"
|
||||
#include "Z2AudioLib/Z2SceneMgr.h"
|
||||
#include "Z2AudioLib/Z2LinkMgr.h"
|
||||
|
||||
/* 802BF920-802BF980 2BA260 0060+00 0/0 1/1 0/0 .text __ct__13Z2SoundObjMgrFv */
|
||||
Z2SoundObjMgr::Z2SoundObjMgr() : JASGlobalInstance<Z2SoundObjMgr>(this) {
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -573,7 +573,7 @@ int daArrow_c::procWait() {
|
|||
}
|
||||
}
|
||||
|
||||
mSoundObjArrow.startLevelSound(0x8000a, 0, mReverb);
|
||||
mSoundObjArrow.startLevelSound(Z2SE_OBJ_BOMB_IGNITION, 0, mReverb);
|
||||
}
|
||||
|
||||
if(dComIfGp_checkCameraAttentionStatus(dComIfGp_getPlayerCameraID(0), 2)) {
|
||||
|
@ -614,7 +614,7 @@ int daArrow_c::procMove() {
|
|||
bVar14 = TRUE;
|
||||
} else if (water_next_pos == 1) {
|
||||
fopKyM_createWpillar(field_0x5dc.GetCrossP(), 0.3f, 0);
|
||||
mDoAud_seStart(0x60031, field_0x5dc.GetCrossP(), 0, mReverb);
|
||||
mDoAud_seStart(Z2SE_CM_BODYFALL_WATER_S, field_0x5dc.GetCrossP(), 0, mReverb);
|
||||
}
|
||||
|
||||
field_0x945 = 1;
|
||||
|
@ -787,13 +787,13 @@ int daArrow_c::procMove() {
|
|||
0.0f
|
||||
);
|
||||
if (mArrowType == 4) {
|
||||
se_id = 0x40018;
|
||||
se_id = Z2SE_HIT_PACHINKO;
|
||||
current.angle = angle;
|
||||
procSlingHitInit(¤t.pos, NULL);
|
||||
} else {
|
||||
procReturnInit(0);
|
||||
dComIfGp_setHitMark(9, this, ¤t.pos, &angle, NULL, 0);
|
||||
se_id = 0x40017;
|
||||
se_id = Z2SE_HIT_AL_ARROW_REBOUND;
|
||||
}
|
||||
} else {
|
||||
setBlur();
|
||||
|
@ -860,7 +860,7 @@ int daArrow_c::procMove() {
|
|||
|
||||
u32 sound_id;
|
||||
if (mArrowType == 2) {
|
||||
sound_id = 0x6001c;
|
||||
sound_id = Z2SE_ZELDA_ARROW_FLY;
|
||||
} else {
|
||||
if (fopAcM_GetParam(this) == 2) {
|
||||
if (mArrowType == 1) {
|
||||
|
@ -1032,7 +1032,7 @@ int daArrow_c::procSlingHitInit(cXyz* param_0, dCcD_GObjInf* param_1) {
|
|||
hitmark = 9;
|
||||
if (hit_ac != NULL && param_1->GetAtHitGObj() != NULL) {
|
||||
if (param_1->GetAtHitGObj()->ChkTgNoSlingHitInfSet()) {
|
||||
mDoAud_seStart(0x40018, param_0, 0x2d, mReverb);
|
||||
mDoAud_seStart(Z2SE_HIT_PACHINKO, param_0, 0x2d, mReverb);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1369,7 +1369,7 @@ static int daB_BH_Execute(b_bh_class* i_this) {
|
|||
}
|
||||
}
|
||||
} else {
|
||||
i_this->mSound.startCreatureSoundLevel(0x70109, 0, -1);
|
||||
i_this->mSound.startCreatureSoundLevel(Z2SE_EN_BH_BURST, 0, -1);
|
||||
|
||||
if (i_this->field_0x909[i] == 0) {
|
||||
i_this->field_0x909[i] = (YREG_S(5) + 1);
|
||||
|
|
|
@ -731,7 +731,7 @@ void daE_OC_c::setStabPos() {
|
|||
/* 8072E528-8072E5A4 002048 007C+00 1/1 0/0 0/0 .text setWaitSound__8daE_OC_cFv */
|
||||
void daE_OC_c::setWaitSound() {
|
||||
if (checkBck(0x1b) && mpMorf->checkFrame(0.0f)) {
|
||||
mSound.startCreatureVoice(0x70180, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT, -1);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -739,9 +739,9 @@ void daE_OC_c::setWaitSound() {
|
|||
void daE_OC_c::setWalkSound() {
|
||||
if (checkBck(0x1d)) {
|
||||
if (mpMorf->checkFrame(14.0f)) {
|
||||
mSound.startCreatureSound(0x70178, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_FOOTNOTE_L, 0, -1);
|
||||
} else if (mpMorf->checkFrame(30.0f)) {
|
||||
mSound.startCreatureSound(0x70179, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_FOOTNOTE_R, 0, -1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -750,11 +750,11 @@ void daE_OC_c::setWalkSound() {
|
|||
void daE_OC_c::setWalkStSound() {
|
||||
if (checkBck(0x1e)) {
|
||||
if (mpMorf->checkFrame(0.0f)) {
|
||||
mSound.startCreatureVoice(0x7018e, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WALK_ST, -1);
|
||||
} else if (mpMorf->checkFrame(1.0f)) {
|
||||
mSound.startCreatureSound(0x70178, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_FOOTNOTE_L, 0, -1);
|
||||
} else if (mpMorf->checkFrame(9.0f)) {
|
||||
mSound.startCreatureSound(0x70179, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_FOOTNOTE_R, 0, -1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -763,16 +763,16 @@ void daE_OC_c::setWalkStSound() {
|
|||
void daE_OC_c::setDashSound() {
|
||||
if (checkBck(0xb)) {
|
||||
if (mpMorf->checkFrame(0.0f)) {
|
||||
mSound.startCreatureVoice(0x7017f, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_DASH, -1);
|
||||
} else if (mpMorf->checkFrame(1.0f)) {
|
||||
mSound.startCreatureSound(0x70178, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_FOOTNOTE_L, 0, -1);
|
||||
} else if (mpMorf->checkFrame(8.5f)) {
|
||||
mSound.startCreatureSound(0x70179, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_FOOTNOTE_R, 0, -1);
|
||||
}
|
||||
if (mName == "E_OC") {
|
||||
mSound.startCreatureSoundLevel(0x70193, 0, -1);
|
||||
mSound.startCreatureSoundLevel(Z2SE_EN_OC_CLUB_DAGGLE, 0, -1);
|
||||
} else {
|
||||
mSound.startCreatureSoundLevel(0x70537, 0, -1);
|
||||
mSound.startCreatureSoundLevel(Z2SE_EN_OC_NATA_DAGGLE, 0, -1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -781,11 +781,11 @@ void daE_OC_c::setDashSound() {
|
|||
void daE_OC_c::setWaitStSound() {
|
||||
if (checkBck(0x1c)) {
|
||||
if (mpMorf->checkFrame(0.0f)) {
|
||||
mSound.startCreatureVoice(0x7018d, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT_ST, -1);
|
||||
} else if (mpMorf->checkFrame(6.5f) || mpMorf->checkFrame(20.0f)) {
|
||||
mSound.startCreatureSound(0x70178, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_FOOTNOTE_L, 0, -1);
|
||||
} else if (mpMorf->checkFrame(13.0f) || mpMorf->checkFrame(28.5f)) {
|
||||
mSound.startCreatureSound(0x70179, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_FOOTNOTE_R, 0, -1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -821,10 +821,10 @@ void daE_OC_c::executeWait() {
|
|||
case 0:
|
||||
if (field_0x6b4 == 0) {
|
||||
setBck(0x1b, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x70180, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT, -1);
|
||||
} else {
|
||||
setBck(0x18, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018b, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_STAND_WAIT, -1);
|
||||
}
|
||||
speedF = 0.0f;
|
||||
field_0x6bc = shape_angle.y;
|
||||
|
@ -848,7 +848,7 @@ void daE_OC_c::executeWait() {
|
|||
cLib_addCalcAngleS(&shape_angle.y, field_0x6bc, 4, 0x800, 0x100);
|
||||
if (field_0x6c0 == 0) {
|
||||
setBck(0x16, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7017c, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_SEARCH, -1);
|
||||
mOcState = 2;
|
||||
}
|
||||
break;
|
||||
|
@ -858,7 +858,7 @@ void daE_OC_c::executeWait() {
|
|||
} else {
|
||||
if (mpMorf->isStop()) {
|
||||
setBck(0x1b, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x70180, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT, -1);
|
||||
if (field_0x6b4 == 0) {
|
||||
field_0x6c0 = cM_rndF(10.0f) + 10.0f;
|
||||
mOcState = 3;
|
||||
|
@ -977,15 +977,15 @@ void daE_OC_c::executeTalk() {
|
|||
if (rand_val < 0.2f) {
|
||||
setBck(0x1a, 0, 5.0f, 1.0f);
|
||||
mOcState = 3;
|
||||
mSound.startCreatureVoice(0x7018f, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_TALK_B, -1);
|
||||
} else if (rand_val < 0.6f) {
|
||||
setBck(0x19, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018a, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_TALK, -1);
|
||||
mOcState = 2;
|
||||
field_0x6c0 = cM_rndF(30.0f) + 30.0f;
|
||||
} else {
|
||||
setBck(0x18, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018b, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_STAND_WAIT, -1);
|
||||
mOcState = 2;
|
||||
field_0x6c0 = cM_rndF(30.0f) + 30.0f;
|
||||
}
|
||||
|
@ -1044,7 +1044,7 @@ void daE_OC_c::executeFind() {
|
|||
field_0x6c2 = field_0x6c0 + 0x14;
|
||||
if (checkBck(0x1c) == 0) {
|
||||
setBck(0x1c, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018d, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT_ST, -1);
|
||||
}
|
||||
field_0x6de = 1;
|
||||
} else if (mOcState == 1) {
|
||||
|
@ -1056,11 +1056,11 @@ void daE_OC_c::executeFind() {
|
|||
field_0x6e2 = 0;
|
||||
field_0x6ca = 0x96;
|
||||
setBck(0xd, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7017e, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_FIND, -1);
|
||||
} else {
|
||||
field_0x6c0 = cM_rndF(5.0f) + 5.0f;
|
||||
setBck(0xd, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7017e, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_FIND, -1);
|
||||
}
|
||||
mOcState = 3;
|
||||
speedF = 0.0f;
|
||||
|
@ -1069,10 +1069,10 @@ void daE_OC_c::executeFind() {
|
|||
if (field_0x6de || pl_dist < 400.0f) {
|
||||
setBck(0x1e, 2, 5.0f, 1.3f);
|
||||
field_0x6de = 1;
|
||||
mSound.startCreatureVoice(0x7018e, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WALK_ST, -1);
|
||||
} else {
|
||||
setBck(0xb, 2, 5.0f, 1.2f);
|
||||
mSound.startCreatureVoice(0x7017f, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_DASH, -1);
|
||||
}
|
||||
mOcState = 4;
|
||||
field_0x6c0 = 0x1e;
|
||||
|
@ -1124,17 +1124,17 @@ void daE_OC_c::executeFind() {
|
|||
if (speedF < 0.0f) {
|
||||
if (checkBck(0x1c) == 0 || mpMorf->getPlaySpeed() != 1.0f) {
|
||||
setBck(0x1c, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018d, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT_ST, -1);
|
||||
}
|
||||
} else if (!speedF && (s16)cLib_distanceAngleS(shape_angle.y, pl_ang) < 0x1000) {
|
||||
if (checkBck(0x1c) == 0) {
|
||||
setBck(0x1c, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018d, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT_ST, -1);
|
||||
}
|
||||
} else {
|
||||
if (checkBck(0x1e) == 0 || mpMorf->getPlaySpeed() != 1.3f) {
|
||||
setBck(0x1e, 2, 5.0f, 1.3f);
|
||||
mSound.startCreatureVoice(0x7018e, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WALK_ST, -1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1151,17 +1151,17 @@ void daE_OC_c::executeFind() {
|
|||
if (speedF < 0.0f) {
|
||||
if (checkBck(0x1e) == 0 || mpMorf->getPlaySpeed() != -1.0f) {
|
||||
setBck(0x1e, 2, 5.0f, -1.0f);
|
||||
mSound.startCreatureVoice(0x7018e, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WALK_ST, -1);
|
||||
}
|
||||
} else if (!speedF && (s16)cLib_distanceAngleS(shape_angle.y, pl_ang) < 0x1000) {
|
||||
if (checkBck(0x1c) == 0) {
|
||||
setBck(0x1c, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018d, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT_ST, -1);
|
||||
}
|
||||
} else {
|
||||
if (checkBck(0x1e) == 0 || mpMorf->getPlaySpeed() != 1.3f) {
|
||||
setBck(0x1e, 2, 5.0f, 1.3f);
|
||||
mSound.startCreatureVoice(0x7018e, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WALK_ST, -1);
|
||||
}
|
||||
}
|
||||
if (0 == strcmp("D_MN05", dComIfGp_getStartStageName())
|
||||
|
@ -1187,7 +1187,7 @@ void daE_OC_c::executeFind() {
|
|||
break;
|
||||
case 5:
|
||||
setBck(0x16, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7017c, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_SEARCH, -1);
|
||||
mOcState = 6;
|
||||
field_0x6de = 0;
|
||||
// fallthrough intentional.
|
||||
|
@ -1265,11 +1265,11 @@ void daE_OC_c::executeAttack() {
|
|||
if (cLib_chaseF(&speedF, 0.0f, 1.0f)) {
|
||||
if (cM_rndF(1.0f) < 0.5f) {
|
||||
setBck(5, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x70184, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_ATTACK_B, -1);
|
||||
mOcState = 1;
|
||||
} else {
|
||||
setBck(6, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x70185, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_ATTACK_C, -1);
|
||||
mOcState = 2;
|
||||
}
|
||||
field_0x6a0 = 0.0f;
|
||||
|
@ -1288,21 +1288,21 @@ void daE_OC_c::executeAttack() {
|
|||
case 1: {
|
||||
if (mOcState == 1) {
|
||||
if (mpMorf->checkFrame(10.0f)) {
|
||||
mSound.startCreatureVoice(0x70186, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_ATTACK_B2, -1);
|
||||
} else if (mpMorf->checkFrame(12.5f)) {
|
||||
mSound.startCreatureSound(0x70188, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_ATTACK_B, 0, -1);
|
||||
} else if (mpMorf->checkFrame(19.0f)) {
|
||||
if (mName == "E_OC") {
|
||||
mSound.startCreatureSound(0x70192, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_CLUB_HIT, 0, -1);
|
||||
} else {
|
||||
mSound.startCreatureSound(0x70536, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_NATA_HIT, 0, -1);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (mpMorf->checkFrame(7.0f)) {
|
||||
mSound.startCreatureVoice(0x70187, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_ATTACK_C2, -1);
|
||||
} else if (mpMorf->checkFrame(11.5f)) {
|
||||
mSound.startCreatureSound(0x70189, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_ATTACK_C, 0, -1);
|
||||
}
|
||||
}
|
||||
if (mpMorf->getFrame() >= 14.0f && mpMorf->getFrame() <= 22.0f) {
|
||||
|
@ -1335,7 +1335,7 @@ void daE_OC_c::executeAttack() {
|
|||
field_0x6a0 = my_float;
|
||||
if (mpMorf->isStop()) {
|
||||
setBck(0x1c, 2, 0.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018d, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT_ST, -1);
|
||||
if (field_0x6e3) {
|
||||
setActionMode(0x10, 0);
|
||||
} else {
|
||||
|
@ -1354,7 +1354,7 @@ void daE_OC_c::executeAttack() {
|
|||
field_0x6a0 = my_float;
|
||||
if (mpMorf->isStop()) {
|
||||
setBck(0x1c, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018d, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT_ST, -1);
|
||||
if (field_0x6e3) {
|
||||
setActionMode(0x10, 0);
|
||||
} else {
|
||||
|
@ -1382,24 +1382,24 @@ void daE_OC_c::executeDamage() {
|
|||
case 0:
|
||||
speedF = 0.0f;
|
||||
setBck(0x9, 0, 0.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x70182, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_DAMAGE_LR, -1);
|
||||
mOcState = 5;
|
||||
break;
|
||||
case 1:
|
||||
speedF = 0.0f;
|
||||
setBck(0xa, 0, 0.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x70182, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_DAMAGE_LR, -1);
|
||||
mOcState = 5;
|
||||
break;
|
||||
case 2:
|
||||
speedF = 0.0f;
|
||||
setBck(0x8, 0, 0.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x70182, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_DAMAGE_LR, -1);
|
||||
mOcState = 5;
|
||||
break;
|
||||
case 3: {
|
||||
setBck(0x8, 0, 0.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x70181, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_DAMAGE, -1);
|
||||
mOcState = 5;
|
||||
s16 half_val = cLib_distanceAngleS(shape_angle.y, fopAcM_searchPlayerAngleY(this));
|
||||
if (half_val < 0x4000) {
|
||||
|
@ -1412,7 +1412,7 @@ void daE_OC_c::executeDamage() {
|
|||
}
|
||||
case 4:
|
||||
setBck(0xf, 0, 0.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x701a2, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_GALE, -1);
|
||||
mOcState = 6;
|
||||
speedF = 0.0f;
|
||||
break;
|
||||
|
@ -1465,18 +1465,18 @@ void daE_OC_c::executeBigDamage() {
|
|||
field_0x6bc = -0x1f60;
|
||||
}
|
||||
if (health < 1) {
|
||||
mSound.startCreatureVoice(0x70191, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_DEATH, -1);
|
||||
} else {
|
||||
mSound.startCreatureVoice(0x70190, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_LEAP_SPIN, -1);
|
||||
}
|
||||
} else {
|
||||
field_0x6dc = 0;
|
||||
setBck(0x13, 0, 0.0f, 1.0f);
|
||||
field_0x6bc = 0;
|
||||
if (health < 1) {
|
||||
mSound.startCreatureVoice(0x70191, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_DEATH, -1);
|
||||
} else {
|
||||
mSound.startCreatureVoice(0x7017a, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_LEAP_A, -1);
|
||||
}
|
||||
}
|
||||
offTgSph();
|
||||
|
@ -1508,10 +1508,10 @@ void daE_OC_c::executeBigDamage() {
|
|||
field_0x6d8 = 0;
|
||||
shape_angle.x = 0;
|
||||
setBck(0x14, 0, 0.0f, 1.0f);
|
||||
mSound.startCreatureSound(0x6002c, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_CM_BODYFALL_M, 0, -1);
|
||||
if (field_0x6dc) {
|
||||
mpMorf->setFrame(5.0f);
|
||||
mSound.startCreatureSound(0x7017b, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_LEAP_B, 0, -1);
|
||||
}
|
||||
mOcState = 4;
|
||||
fopAcM_effSmokeSet1(&field_0xe60, &field_0xe64, ¤t.pos, NULL, 2.0f, &tevStr, 1);
|
||||
|
@ -1520,10 +1520,10 @@ void daE_OC_c::executeBigDamage() {
|
|||
case 4:
|
||||
setGroundAngle();
|
||||
if (mpMorf->checkFrame(15.0f)) {
|
||||
mSound.startCreatureSound(0x6002c, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_CM_BODYFALL_M, 0, -1);
|
||||
}
|
||||
if (field_0x6dc == 0 && mpMorf->checkFrame(5.0f)) {
|
||||
mSound.startCreatureSound(0x7017b, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_LEAP_B, 0, -1);
|
||||
}
|
||||
checkDamageBg();
|
||||
if (mAcch.ChkWallHit()) {
|
||||
|
@ -1557,7 +1557,7 @@ void daE_OC_c::executeBigDamage() {
|
|||
}
|
||||
if (field_0x6c0 == 0) {
|
||||
setBck(0x17, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7017d, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_STAND, -1);
|
||||
mOcState = 6;
|
||||
offDownFlg();
|
||||
}
|
||||
|
@ -1581,10 +1581,10 @@ void daE_OC_c::executeWatch() {
|
|||
speedF = 0.0f;
|
||||
if (field_0x6de) {
|
||||
setBck(0x1c, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018d, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT_ST, -1);
|
||||
} else {
|
||||
setBck(0x1b, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x70180, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT, -1);
|
||||
}
|
||||
field_0x6c0 = (s8) (cM_rndFX(15.0f) + 35.0f);
|
||||
mOcState = 1;
|
||||
|
@ -1600,10 +1600,10 @@ void daE_OC_c::executeWatch() {
|
|||
speedF = 0.0f;
|
||||
if (field_0x6de) {
|
||||
setBck(0x1c, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018d, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT_ST, -1);
|
||||
} else {
|
||||
setBck(0x1b, 2, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x70180, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_WAIT, -1);
|
||||
}
|
||||
field_0x6c0 = (s8) (cM_rndFX(15.0f) + 35.0f);
|
||||
mOcState = 3;
|
||||
|
@ -1612,7 +1612,7 @@ void daE_OC_c::executeWatch() {
|
|||
if (field_0x6c0 == 0) {
|
||||
mOcState = 4;
|
||||
setBck(7, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x70183, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_CRY, -1);
|
||||
}
|
||||
break;
|
||||
case 4:
|
||||
|
@ -1645,13 +1645,13 @@ void daE_OC_c::executeSoundWatch() {
|
|||
case 0:
|
||||
speedF = 0.0f;
|
||||
setBck(0xd, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7017e, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_FIND, -1);
|
||||
field_0x6c0 = cM_rndF(30.0f) + 60.0f;
|
||||
mOcState = 1;
|
||||
case 1:
|
||||
if (field_0x6c0 == 0) {
|
||||
setBck(0xb, 2, 5.0f, 1.2f);
|
||||
mSound.startCreatureVoice(0x7017f, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_DASH, -1);
|
||||
mOcState = 2;
|
||||
field_0x6c0 = 0x3c;
|
||||
}
|
||||
|
@ -1699,7 +1699,7 @@ void daE_OC_c::executeDeath() {
|
|||
} else {
|
||||
field_0x6c0 = 0x2d;
|
||||
setBck(0xe, 0, 0.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x7018c, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_FINISH, -1);
|
||||
mOcState = 3;
|
||||
offDownFlg();
|
||||
}
|
||||
|
@ -1707,7 +1707,7 @@ void daE_OC_c::executeDeath() {
|
|||
case 3:
|
||||
setSpitEffect();
|
||||
if (mpMorf->checkFrame(28.5f)) {
|
||||
mSound.startCreatureSound(0x6002b, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_CM_BODYFALL_S, 0, -1);
|
||||
}
|
||||
case 2:
|
||||
cLib_chaseF(&speedF, 0.0f, 1.0f);
|
||||
|
@ -1750,14 +1750,14 @@ void daE_OC_c::executeWaterDeath() {
|
|||
switch (mOcState) {
|
||||
case 0:
|
||||
setBck(0xC, 0, 0.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x701AF, -1);
|
||||
mSound.startCreatureSound(0x701B0, 0, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_DROWNED, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_DROWNED, 0, -1);
|
||||
current.pos.y += 140.0f;
|
||||
mOcState = 1;
|
||||
speedF = 0.0f;
|
||||
gravity = 0.0f;
|
||||
setWaterEffect();
|
||||
mSound.startCreatureSound(0x60032, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_CM_BODYFALL_WATER_M, 0, -1);
|
||||
offTgSph();
|
||||
break;
|
||||
case 1:
|
||||
|
@ -1831,7 +1831,7 @@ void daE_OC_c::executeDemoMaster() {
|
|||
return;
|
||||
}
|
||||
case 1:
|
||||
mSound.startCreatureVoice(0x701B1, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_SAKEBU, -1);
|
||||
setBck(7, 0, 5.0f, 1.0f);
|
||||
mOcState = 2;
|
||||
field_0x6c0 = 15;
|
||||
|
@ -1849,19 +1849,19 @@ void daE_OC_c::executeDemoMaster() {
|
|||
if (mOcState == 4) {
|
||||
if (mpMorf->isStop()) {
|
||||
setBck(4, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x701A4, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_ANGRY_B, -1);
|
||||
mOcState = 5;
|
||||
}
|
||||
} else {
|
||||
if (mpMorf->checkFrame(9.0f)) {
|
||||
mSound.startCreatureSound(0x70189, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_EN_OC_ATTACK_C, 0, -1);
|
||||
}
|
||||
s16 angle = fopAcM_searchPlayerAngleY(this);
|
||||
cLib_chaseAngleS(&field_0x6bc, angle + 0x8000, 0x200);
|
||||
if (mpMorf->isStop()) {
|
||||
mOcState = 6;
|
||||
setBck(0x10, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x701B2, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_JUMP, -1);
|
||||
speedF = 10.0f;
|
||||
speed.y = 40.0f;
|
||||
field_0x6c0 = 0x28;
|
||||
|
@ -1898,7 +1898,7 @@ void daE_OC_c::executeDemoMaster() {
|
|||
cLib_addCalc2(&field_0x6f8.y, my_vec_0.y + 2950.0f, 0.1f, 10.0f);
|
||||
}
|
||||
if (mAcch.ChkGroundHit()) {
|
||||
mSound.startCreatureSound(0x6002B, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_CM_BODYFALL_S, 0, -1);
|
||||
fopAcM_effSmokeSet1(&field_0xe60, &field_0xe64, ¤t.pos, NULL, 2.0f, &tevStr, 1);
|
||||
setBck(0x12, 0, 5.0f, 1.0f);
|
||||
mOcState = 8;
|
||||
|
@ -1908,7 +1908,7 @@ void daE_OC_c::executeDemoMaster() {
|
|||
field_0x704 = 47.0f;
|
||||
cLib_addCalc2(&field_0x6f8.y, my_vec_0.y + 2950.0f, 0.1f, 10.0f);
|
||||
if (mpMorf->checkFrame(34.0f)) {
|
||||
mSound.startCreatureVoice(0x7017E, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_FIND, -1);
|
||||
}
|
||||
if (mpMorf->isStop()) {
|
||||
field_0x6c8 = 30;
|
||||
|
@ -1945,14 +1945,14 @@ void daE_OC_c::executeDemoChild() {
|
|||
case 1:
|
||||
if (mpParent->mOcState == 5) {
|
||||
setBck(3, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x701A3, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_ANGRY_A, -1);
|
||||
mOcState = 5;
|
||||
}
|
||||
break;
|
||||
case 5:
|
||||
if (mpMorf->isStop()) {
|
||||
setBck(0x10, 0, 5.0f, 1.0f);
|
||||
mSound.startCreatureVoice(0x701B2, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_JUMP, -1);
|
||||
mOcState = 6;
|
||||
speedF = 10.0f;
|
||||
speed.y = 40.0f;
|
||||
|
@ -1975,7 +1975,7 @@ void daE_OC_c::executeDemoChild() {
|
|||
break;
|
||||
case 7:
|
||||
if (mAcch.ChkGroundHit()) {
|
||||
mSound.startCreatureSound(0x6002B, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_CM_BODYFALL_S, 0, -1);
|
||||
fopAcM_effSmokeSet1(&field_0xe60, &field_0xe64, ¤t.pos, NULL, 2.0f, &tevStr, 1);
|
||||
setBck(0x12, 0, 5.0f, 1.0f);
|
||||
mOcState = 8;
|
||||
|
@ -1983,7 +1983,7 @@ void daE_OC_c::executeDemoChild() {
|
|||
break;
|
||||
case 8:
|
||||
if (mpMorf->checkFrame(34.0f)) {
|
||||
mSound.startCreatureVoice(0x7017E, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_FIND, -1);
|
||||
}
|
||||
if (mpMorf->isStop()) {
|
||||
setActionMode(3, 0);
|
||||
|
@ -2025,7 +2025,7 @@ void daE_OC_c::executeFallDead() {
|
|||
mPrevShapeAngle = shape_angle.y;
|
||||
switch (mOcState) {
|
||||
case 0:
|
||||
mSound.startCreatureVoice(0x701A5, -1);
|
||||
mSound.startCreatureVoice(Z2SE_EN_OC_V_FALL, -1);
|
||||
if (checkBck(0x15) || checkBck(0x13)) {
|
||||
mOcState = 1;
|
||||
} else {
|
||||
|
@ -2071,7 +2071,7 @@ void daE_OC_c::executeFall() {
|
|||
case 1:
|
||||
if (mAcch.ChkGroundHit()) {
|
||||
speedF = 0.0f;
|
||||
mSound.startCreatureSound(0x6002B, 0, -1);
|
||||
mSound.startCreatureSound(Z2SE_CM_BODYFALL_S, 0, -1);
|
||||
fopAcM_effSmokeSet1(&field_0xe60, &field_0xe64, ¤t.pos, NULL, 2.0f, &tevStr, 1);
|
||||
setBck(0x12, 0, 5.0f, 1.0f);
|
||||
mOcState = 2;
|
||||
|
|
|
@ -31,12 +31,12 @@ static void ccHitCallback(fopAc_ac_c* param_0, dCcD_GObjInf* param_1, fopAc_ac_c
|
|||
int iVar1 = ((daObjYtaihou_c*)param_0)->getIronBallId();
|
||||
if (iVar1 == 0xffffffff && ((daObjCarry_c*)param_2)->getType() == daObjCarry_c::TYPE_IRON_BALL) {
|
||||
((daObjYtaihou_c*)param_0)->setIronBall((daObjCarry_c*)param_2);
|
||||
fopAcM_seStartCurrent(param_0, 0x801c9, 0);
|
||||
fopAcM_seStartCurrent(param_0, Z2SE_OBJ_CANNON_CHARGE, 0);
|
||||
}
|
||||
} else if (fopAcM_GetProfName(param_2) == 0x221) {
|
||||
((daObjYtaihou_c*)param_0)->startBomb();
|
||||
fopAcM_delete(param_2);
|
||||
fopAcM_seStartCurrent(param_0, 0x801c9, 0);
|
||||
fopAcM_seStartCurrent(param_0, Z2SE_OBJ_CANNON_CHARGE, 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -220,9 +220,9 @@ void daObjYtaihou_c::rotateCheck() {
|
|||
field_0x772 = 0;
|
||||
daPy_getLinkPlayerActorClass()->offPushPullKeep();
|
||||
field_0x774 = -1;
|
||||
fopAcM_seStartCurrent(this, 0x801cb, 0);
|
||||
fopAcM_seStartCurrent(this, Z2SE_OBJ_CANNON_STOP, 0);
|
||||
} else {
|
||||
fopAcM_seStartCurrentLevel(this, 0x801ca, 0);
|
||||
fopAcM_seStartCurrentLevel(this, Z2SE_OBJ_CANNON_MOVE, 0);
|
||||
}
|
||||
} else if (field_0x774) {
|
||||
daPy_py_c* player_class = daPy_getLinkPlayerActorClass();
|
||||
|
@ -301,7 +301,7 @@ void daObjYtaihou_c::shotCheck() {
|
|||
mParticleKeys[1] = dComIfGp_particle_set(mParticleKeys[1], 0x1df, &my_vec_0, &tevStr,
|
||||
NULL, &l_effectScale, 0xff, NULL, -1,
|
||||
NULL, NULL, NULL);
|
||||
fopAcM_seStartCurrentLevel(this, 0x8000a, 0);
|
||||
fopAcM_seStartCurrentLevel(this, Z2SE_OBJ_BOMB_IGNITION, 0);
|
||||
} else if (mStartBomb == 4) {
|
||||
daObjCarry_c* pCarry = (daObjCarry_c*) fopAcM_SearchByID(mIronBallId);
|
||||
if (pCarry) {
|
||||
|
@ -323,7 +323,7 @@ void daObjYtaihou_c::shotCheck() {
|
|||
dComIfGp_particle_set(0x8ae5, &my_vec_1, &tevStr, &shape_angle, 0);
|
||||
dComIfGp_particle_set(0x8ae6, &my_vec_1, &tevStr, &shape_angle, 0);
|
||||
dComIfGp_getVibration().StartShock(8, 0x1f, cXyz(0.0f, 1.0f, 0.0f));
|
||||
fopAcM_seStartCurrent(this, 0x8000b, 0);
|
||||
fopAcM_seStartCurrent(this, Z2SE_OBJ_BOMB_EXPLODE, 0);
|
||||
speed.y = 40.0f;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -200,7 +200,7 @@ const daObjCarry_dt_t daObjCarry_c::mData[] = {
|
|||
1000000.0f,
|
||||
50.0f,
|
||||
Z2SE_OBJ_BREAK_WOOD_S,
|
||||
0x801D4,
|
||||
Z2SE_OBJ_IRONBALL_HIT,
|
||||
Z2SE_OBJ_PUT_WATER_M,
|
||||
JA_SE_OBJ_FALL_MAGMA_S,
|
||||
Z2SE_OBJ_FALL_WATER_S,
|
||||
|
@ -287,8 +287,8 @@ const daObjCarry_dt_t daObjCarry_c::mData[] = {
|
|||
48.0f,
|
||||
250.0f,
|
||||
0.0f,
|
||||
0x800F6,
|
||||
0x800F7,
|
||||
Z2SE_OBJ_SKULL_BREAK,
|
||||
Z2SE_OBJ_SKULL_PUT,
|
||||
Z2SE_OBJ_PUT_WATER_S,
|
||||
JA_SE_OBJ_FALL_MAGMA_S,
|
||||
Z2SE_OBJ_FALL_WATER_S,
|
||||
|
@ -331,8 +331,8 @@ const daObjCarry_dt_t daObjCarry_c::mData[] = {
|
|||
60.0f,
|
||||
250.0f,
|
||||
0.0f,
|
||||
0x800B9,
|
||||
0x800B8,
|
||||
Z2SE_OBJ_BOKKURI_BURST,
|
||||
Z2SE_OBJ_BOKKURI_PUT,
|
||||
Z2SE_OBJ_PUT_WATER_S,
|
||||
JA_SE_OBJ_FALL_MAGMA_M,
|
||||
Z2SE_OBJ_FALL_WATER_M,
|
||||
|
|
|
@ -185,7 +185,8 @@ int daLv1Cdl00_c::Execute() {
|
|||
g_whiteColor, g_whiteColor, 0, 0.0f);
|
||||
dComIfGp_particle_setSimple(0x103, &mTorchPos, 0xff,
|
||||
g_whiteColor, g_whiteColor, 0, 0.0f);
|
||||
mDoAud_seStartLevel(0x80018, &mTorchPos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
mDoAud_seStartLevel(Z2SE_OBJ_FIRE_BURNING, &mTorchPos, 0,
|
||||
dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
}
|
||||
|
||||
setBaseMtx();
|
||||
|
@ -200,7 +201,8 @@ int daLv1Cdl00_c::Execute() {
|
|||
} else {
|
||||
fopAcM_offSwitch(this, fopAcM_GetParam(this) & 0xff);
|
||||
}
|
||||
mDoAud_seStart(0x80017, &mTorchPos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
mDoAud_seStart(Z2SE_OBJ_FIRE_IGNITION, &mTorchPos, 0,
|
||||
dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
setLight();
|
||||
}
|
||||
if (gobj->GetAtType() == AT_TYPE_BOOMERANG && gobj->GetAtMtrl() == dCcD_MTRL_WIND && mIsLit == true) {
|
||||
|
@ -211,7 +213,8 @@ int daLv1Cdl00_c::Execute() {
|
|||
} else {
|
||||
fopAcM_onSwitch(this, fopAcM_GetParam(this) & 0xff);
|
||||
}
|
||||
mDoAud_seStart(0x80019, &mTorchPos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
mDoAud_seStart(Z2SE_OBJ_FIRE_OFF, &mTorchPos, 0,
|
||||
dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
cutLight();
|
||||
}
|
||||
cCcD_Obj* obj = mCyl.GetTgHitObj();
|
||||
|
|
|
@ -149,7 +149,8 @@ int daLv1Cdl01_c::Execute(f32 (**param_0)[3][4]) {
|
|||
g_whiteColor, g_whiteColor, 0, 0.0f);
|
||||
dComIfGp_particle_setSimple(0x103, &mTorchPos, 0xff,
|
||||
g_whiteColor, g_whiteColor, 0, 0.0f);
|
||||
mDoAud_seStartLevel(0x80018, &mTorchPos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
mDoAud_seStartLevel(Z2SE_OBJ_FIRE_BURNING, &mTorchPos, 0,
|
||||
dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
}
|
||||
|
||||
setBaseMtx();
|
||||
|
@ -159,12 +160,14 @@ int daLv1Cdl01_c::Execute(f32 (**param_0)[3][4]) {
|
|||
if (gobj->GetAtType() == AT_TYPE_LANTERN_SWING && gobj->GetAtMtrl() == dCcD_MTRL_FIRE && !mIsLit) {
|
||||
mIsLit = true;
|
||||
setLight();
|
||||
mDoAud_seStart(0x80017, &mTorchPos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
mDoAud_seStart(Z2SE_OBJ_FIRE_IGNITION, &mTorchPos, 0,
|
||||
dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
}
|
||||
if (gobj->GetAtType() == AT_TYPE_BOOMERANG && gobj->GetAtMtrl() == dCcD_MTRL_WIND && mIsLit == true) {
|
||||
mTimer = 30;
|
||||
mIsLit = false;
|
||||
mDoAud_seStart(0x80019, &mTorchPos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
mDoAud_seStart(Z2SE_OBJ_FIRE_OFF, &mTorchPos, 0,
|
||||
dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
cutLight();
|
||||
}
|
||||
cCcD_Obj* obj = mCyl.GetTgHitObj();
|
||||
|
|
|
@ -280,7 +280,8 @@ int daLv2Candle_c::Execute() {
|
|||
g_whiteColor, g_whiteColor, 0, 0.0f);
|
||||
dComIfGp_particle_setSimple(0x103, &mTorchPos, 0xff,
|
||||
g_whiteColor, g_whiteColor, 0, 0.0f);
|
||||
mDoAud_seStartLevel(0x80018, &mTorchPos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
mDoAud_seStartLevel(Z2SE_OBJ_FIRE_BURNING, &mTorchPos, 0,
|
||||
dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
}
|
||||
|
||||
if (field_0x734 != NULL) {
|
||||
|
@ -305,7 +306,8 @@ int daLv2Candle_c::Execute() {
|
|||
} else {
|
||||
fopAcM_offSwitch(this, mSw);
|
||||
}
|
||||
mDoAud_seStart(0x80017, &mTorchPos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
mDoAud_seStart(Z2SE_OBJ_FIRE_IGNITION, &mTorchPos, 0,
|
||||
dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
setLight();
|
||||
}
|
||||
if (gobj->GetAtType() == AT_TYPE_BOOMERANG && gobj->GetAtMtrl() == dCcD_MTRL_WIND &&
|
||||
|
@ -313,7 +315,8 @@ int daLv2Candle_c::Execute() {
|
|||
mIsLit = false;
|
||||
mCyl.SetAtMtrl(dCcD_MTRL_NONE);
|
||||
cutLight();
|
||||
mDoAud_seStart(0x80019, &mTorchPos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
mDoAud_seStart(Z2SE_OBJ_FIRE_OFF, &mTorchPos, 0,
|
||||
dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
if (mSw == 0xff) {
|
||||
mTimer = l_HIO.mTimer;
|
||||
}
|
||||
|
|
|
@ -147,7 +147,8 @@ int daLv3Candle_c::Execute() {
|
|||
dComIfGp_particle_setSimple(0x101, &mTorchPos, 0xff, g_whiteColor, g_whiteColor, 0, 0.0f);
|
||||
dComIfGp_particle_setSimple(0x103, &mTorchPos, 0xff, g_whiteColor, g_whiteColor, 0, 0.0f);
|
||||
|
||||
mDoAud_seStartLevel(0x80018, &mTorchPos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
mDoAud_seStartLevel(Z2SE_OBJ_FIRE_BURNING, &mTorchPos, 0,
|
||||
dComIfGp_getReverb(fopAcM_GetRoomNo(this)));
|
||||
|
||||
if (mSph.ChkTgHit()) {
|
||||
cCcD_Obj* obj = mSph.GetTgHitObj();
|
||||
|
|
|
@ -363,7 +363,7 @@ void dMsgScrnExplain_c::move_proc() {
|
|||
{
|
||||
mStatus = 5;
|
||||
dMeter2Info_set2DVibrationM();
|
||||
mDoAud_seStart(0x52, 0, 0, 0);
|
||||
mDoAud_seStart(Z2SE_SY_EXP_WIN_CLOSE, 0, 0, 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue