2023-06-29 04:10:08 -04:00
|
|
|
#include "legohideanimpresenter.h"
|
|
|
|
|
2024-05-14 10:15:35 -04:00
|
|
|
#include "legomain.h"
|
|
|
|
#include "legoworld.h"
|
|
|
|
#include "misc.h"
|
|
|
|
|
2024-01-17 12:24:05 -05:00
|
|
|
DECOMP_SIZE_ASSERT(LegoHideAnimPresenter, 0xc4)
|
|
|
|
|
2023-12-06 07:10:45 -05:00
|
|
|
// FUNCTION: LEGO1 0x1006d7e0
|
2023-06-29 04:10:08 -04:00
|
|
|
LegoHideAnimPresenter::LegoHideAnimPresenter()
|
|
|
|
{
|
2023-10-24 19:38:27 -04:00
|
|
|
Init();
|
2023-06-29 04:10:08 -04:00
|
|
|
}
|
|
|
|
|
2024-05-14 10:15:35 -04:00
|
|
|
// FUNCTION: LEGO1 0x1006d860
|
2024-02-27 11:49:31 -05:00
|
|
|
void LegoHideAnimPresenter::VTable0x8c()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2024-05-14 10:15:35 -04:00
|
|
|
// FUNCTION: LEGO1 0x1006d870
|
2024-02-27 11:49:31 -05:00
|
|
|
void LegoHideAnimPresenter::VTable0x90()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2024-01-17 12:24:05 -05:00
|
|
|
// FUNCTION: LEGO1 0x1006d9f0
|
2024-01-14 16:28:46 -05:00
|
|
|
LegoHideAnimPresenter::~LegoHideAnimPresenter()
|
|
|
|
{
|
2024-01-17 12:24:05 -05:00
|
|
|
Destroy(TRUE);
|
2024-01-14 16:28:46 -05:00
|
|
|
}
|
|
|
|
|
2024-01-17 12:24:05 -05:00
|
|
|
// FUNCTION: LEGO1 0x1006da50
|
2023-06-29 04:10:08 -04:00
|
|
|
void LegoHideAnimPresenter::Init()
|
|
|
|
{
|
2024-01-17 12:24:05 -05:00
|
|
|
m_unk0xc0 = NULL;
|
|
|
|
}
|
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1006da60
|
|
|
|
void LegoHideAnimPresenter::Destroy(MxBool p_fromDestructor)
|
|
|
|
{
|
|
|
|
m_criticalSection.Enter();
|
|
|
|
|
2024-02-01 15:42:10 -05:00
|
|
|
if (m_unk0xc0) {
|
2024-01-17 12:24:05 -05:00
|
|
|
delete m_unk0xc0;
|
2024-02-01 15:42:10 -05:00
|
|
|
}
|
2024-01-17 12:24:05 -05:00
|
|
|
Init();
|
|
|
|
|
|
|
|
m_criticalSection.Leave();
|
|
|
|
|
|
|
|
// This appears to be a bug, since it results in an endless loop
|
2024-02-01 15:42:10 -05:00
|
|
|
if (!p_fromDestructor) {
|
2024-01-17 12:24:05 -05:00
|
|
|
LegoHideAnimPresenter::Destroy();
|
2024-02-01 15:42:10 -05:00
|
|
|
}
|
2024-01-17 12:24:05 -05:00
|
|
|
}
|
|
|
|
|
2024-02-03 07:38:57 -05:00
|
|
|
// FUNCTION: LEGO1 0x1006dab0
|
2024-01-20 18:04:46 -05:00
|
|
|
MxResult LegoHideAnimPresenter::AddToManager()
|
|
|
|
{
|
2024-02-03 07:38:57 -05:00
|
|
|
return LegoAnimPresenter::AddToManager();
|
2024-01-20 18:04:46 -05:00
|
|
|
}
|
|
|
|
|
2024-01-17 12:24:05 -05:00
|
|
|
// FUNCTION: LEGO1 0x1006dac0
|
|
|
|
void LegoHideAnimPresenter::Destroy()
|
|
|
|
{
|
|
|
|
Destroy(FALSE);
|
2023-06-29 04:10:08 -04:00
|
|
|
}
|
2024-01-20 18:04:46 -05:00
|
|
|
|
2024-05-14 10:15:35 -04:00
|
|
|
// FUNCTION: LEGO1 0x1006dad0
|
2024-01-20 18:04:46 -05:00
|
|
|
void LegoHideAnimPresenter::PutFrame()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2024-05-14 10:15:35 -04:00
|
|
|
// FUNCTION: LEGO1 0x1006dae0
|
|
|
|
// FUNCTION: BETA10 0x100530f4
|
2024-01-20 18:04:46 -05:00
|
|
|
void LegoHideAnimPresenter::ReadyTickle()
|
|
|
|
{
|
2024-05-14 10:15:35 -04:00
|
|
|
LegoLoopingAnimPresenter::ReadyTickle();
|
|
|
|
|
|
|
|
if (m_currentWorld) {
|
|
|
|
if (m_currentTickleState == e_starting && m_compositePresenter != NULL) {
|
|
|
|
SendToCompositePresenter(Lego());
|
|
|
|
}
|
|
|
|
|
|
|
|
m_currentWorld->Add(this);
|
|
|
|
}
|
2024-01-20 18:04:46 -05:00
|
|
|
}
|
|
|
|
|
2024-05-14 10:15:35 -04:00
|
|
|
// FUNCTION: LEGO1 0x1006db20
|
|
|
|
// FUNCTION: BETA10 0x1005316b
|
2024-01-20 18:04:46 -05:00
|
|
|
void LegoHideAnimPresenter::StartingTickle()
|
2024-05-14 10:15:35 -04:00
|
|
|
{
|
|
|
|
LegoLoopingAnimPresenter::StartingTickle();
|
|
|
|
|
|
|
|
if (m_currentTickleState == e_streaming) {
|
|
|
|
FUN_1006dc10();
|
|
|
|
FUN_1006db40(0);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// STUB: LEGO1 0x1006db40
|
|
|
|
// FUNCTION: BETA10 0x100531ab
|
|
|
|
void LegoHideAnimPresenter::FUN_1006db40(undefined4)
|
2024-01-20 18:04:46 -05:00
|
|
|
{
|
|
|
|
// TODO
|
|
|
|
}
|
|
|
|
|
2024-05-14 10:15:35 -04:00
|
|
|
// STUB: LEGO1 0x1006dc10
|
|
|
|
// FUNCTION: BETA10 0x100532fd
|
|
|
|
void LegoHideAnimPresenter::FUN_1006dc10()
|
2024-01-20 18:04:46 -05:00
|
|
|
{
|
|
|
|
// TODO
|
|
|
|
}
|
2024-05-14 10:15:35 -04:00
|
|
|
|
|
|
|
// FUNCTION: LEGO1 0x1006e9e0
|
|
|
|
// FUNCTION: BETA10 0x100535ef
|
|
|
|
void LegoHideAnimPresenter::EndAction()
|
|
|
|
{
|
|
|
|
if (m_action) {
|
|
|
|
MxVideoPresenter::EndAction();
|
|
|
|
|
|
|
|
if (m_currentWorld) {
|
|
|
|
m_currentWorld->Remove(this);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|