mirror of
https://github.com/encounter/tp.git
synced 2026-03-30 11:40:53 -07:00
a61e3491f7
* initial freezard actor struct + setActionMode OK * daE_FZ_Draw * setReflectAngle * mBoundSoundset * daE_FZ_Execute & execute * demoDelete * daE_FZ_Delete & _delete * CreateHeap * useHeapInit * cc_set * mtx_set * action WIP * way_gake_check * executeRollMove * executeMove * draw WIP * executeDamage * checkpoint * create * checkpoint * daE_FZ_c::executeWait * checkpoint * daE_FZ_c::damage_check almost done * rm asm * rm headers * setup_profile WIP + doxygen update * fix merge issues * docs fix? * fix2 * doxygen updates * setup g_profile_E_FZ, profile setup script WIP * update github actions * update progress.md
41 lines
1.1 KiB
C++
41 lines
1.1 KiB
C++
#ifndef Z2SOUNDHANDLES_H
|
|
#define Z2SOUNDHANDLES_H
|
|
|
|
#include "JSystem/JAudio2/JAISoundHandles.h"
|
|
#include "JSystem/JAudio2/JASHeapCtrl.h"
|
|
#include "dolphin/types.h"
|
|
|
|
class Z2SoundHandlePool : public JAISoundHandle, public JSULink<Z2SoundHandlePool> { // , public JASPoolAllocObject<Z2SoundHandlePool> {
|
|
public:
|
|
Z2SoundHandlePool() : JAISoundHandle(), JSULink<Z2SoundHandlePool>(this) {}
|
|
~Z2SoundHandlePool() {}
|
|
};
|
|
|
|
class Z2SoundHandles : protected JSUList<Z2SoundHandlePool> {
|
|
public:
|
|
Z2SoundHandles();
|
|
~Z2SoundHandles();
|
|
|
|
void initHandlesPool(u8 pNumHandles);
|
|
void deleteHandlesPool();
|
|
Z2SoundHandlePool* getFreeHandle();
|
|
Z2SoundHandlePool* getLowPrioSound(JAISoundID pSoundId);
|
|
|
|
bool isActive() const;
|
|
|
|
Z2SoundHandlePool* getHandleSoundID(JAISoundID pSoundId);
|
|
Z2SoundHandlePool* getHandleUserData(u32 pUserData);
|
|
|
|
void stopAllSounds(u32 fadeout);
|
|
|
|
void setPos(const JGeometry::TVec3<f32>& pos);
|
|
|
|
int getNumHandles() const { return getNumLinks(); }
|
|
Z2SoundHandlePool* getHandle(int index) { return (Z2SoundHandlePool*)getNth(index); }
|
|
|
|
private:
|
|
/* 0xC */ u8 mNumHandles;
|
|
};
|
|
|
|
#endif /* Z2SOUNDHANDLES_H */
|