mirror of
https://github.com/isledecomp/isle-portable.git
synced 2026-01-17 21:01:15 +00:00
65 lines
1.3 KiB
C++
65 lines
1.3 KiB
C++
#include "lego3dwavepresenter.h"
|
|
|
|
#include "mxcompositepresenter.h"
|
|
#include "mxdsaction.h"
|
|
#include "mxmain.h"
|
|
|
|
DECOMP_SIZE_ASSERT(Lego3DWavePresenter, 0xa0)
|
|
|
|
// FUNCTION: LEGO1 0x1004a7c0
|
|
MxResult Lego3DWavePresenter::AddToManager()
|
|
{
|
|
MxResult result = MxWavePresenter::AddToManager();
|
|
MxWavePresenter::Init();
|
|
|
|
if (MxOmni::IsSound3D()) {
|
|
m_is3d = TRUE;
|
|
}
|
|
|
|
return result;
|
|
}
|
|
|
|
// FUNCTION: LEGO1 0x1004a7f0
|
|
void Lego3DWavePresenter::Destroy()
|
|
{
|
|
MxWavePresenter::Destroy();
|
|
MxWavePresenter::Init();
|
|
|
|
if (MxOmni::IsSound3D()) {
|
|
m_is3d = TRUE;
|
|
}
|
|
}
|
|
|
|
// FUNCTION: LEGO1 0x1004a810
|
|
// FUNCTION: BETA10 0x1003a3b0
|
|
void Lego3DWavePresenter::StartingTickle()
|
|
{
|
|
if (MxOmni::IsSound3D()) {
|
|
m_is3d = TRUE;
|
|
}
|
|
|
|
MxWavePresenter::StartingTickle();
|
|
|
|
if (MxWavePresenter::m_sound) {
|
|
MxU16 extraLength;
|
|
char* buff;
|
|
m_action->GetExtra(extraLength, buff);
|
|
|
|
if (!strcmp(buff, "FROM_PARENT") && m_compositePresenter != NULL) {
|
|
m_compositePresenter->GetAction()->GetExtra(extraLength, buff);
|
|
}
|
|
|
|
if (m_sound.Create(MxWavePresenter::m_sound, buff, m_volume) != SUCCESS) {
|
|
EndAction();
|
|
}
|
|
}
|
|
}
|
|
|
|
// FUNCTION: LEGO1 0x1004a8b0
|
|
// FUNCTION: BETA10 0x1003a4cc
|
|
void Lego3DWavePresenter::StreamingTickle()
|
|
{
|
|
MxWavePresenter::StreamingTickle();
|
|
m_sound.UpdatePosition(MxWavePresenter::m_sound);
|
|
}
|