mirror of
https://github.com/isledecomp/isle.git
synced 2025-10-23 00:14:22 +00:00
Implement/match LegoControlManager::FUN_100293c0 (#970)
This commit is contained in:

committed by
GitHub

parent
689178f689
commit
ae859fbc19
@@ -206,9 +206,9 @@ MxBool MxControlPresenter::FUN_10044480(LegoControlManagerEvent* p_event, MxPres
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10044540
|
||||
void MxControlPresenter::VTable0x6c(MxS16 p_val)
|
||||
void MxControlPresenter::VTable0x6c(MxS16 p_unk0x4e)
|
||||
{
|
||||
if (p_val == -1) {
|
||||
if (p_unk0x4e == -1) {
|
||||
if ((MxS16) ((MxDSMultiAction*) m_action)->GetActionList()->GetCount() - m_unk0x4e == 1) {
|
||||
m_unk0x4e = 0;
|
||||
}
|
||||
@@ -217,7 +217,7 @@ void MxControlPresenter::VTable0x6c(MxS16 p_val)
|
||||
}
|
||||
}
|
||||
else {
|
||||
m_unk0x4e = p_val;
|
||||
m_unk0x4e = p_unk0x4e;
|
||||
}
|
||||
|
||||
m_action->SetUnknown90(Timer()->GetTime());
|
||||
|
@@ -116,9 +116,27 @@ void LegoControlManager::FUN_100292e0()
|
||||
}
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100293c0
|
||||
void LegoControlManager::FUN_100293c0(undefined4, const char*, undefined2)
|
||||
// FUNCTION: LEGO1 0x100293c0
|
||||
void LegoControlManager::FUN_100293c0(MxU32 p_objectId, const char* p_atom, MxS16 p_unk0x4e)
|
||||
{
|
||||
if (m_presenterList) {
|
||||
MxPresenterListCursor cursor(m_presenterList);
|
||||
MxPresenter* control;
|
||||
|
||||
while (cursor.Next(control)) {
|
||||
MxDSAction* action = control->GetAction();
|
||||
|
||||
if (action->GetObjectId() == p_objectId && action->GetAtomId().GetInternal() == p_atom) {
|
||||
((MxControlPresenter*) control)->VTable0x6c(p_unk0x4e);
|
||||
|
||||
if (((MxControlPresenter*) control)->GetUnknown0x4e() == 0) {
|
||||
g_unk0x100f31b0 = -1;
|
||||
g_unk0x100f31b4 = NULL;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100294e0
|
||||
|
@@ -246,7 +246,7 @@ MxLong Infocenter::HandleEndAction(MxEndActionNotificationParam& p_param)
|
||||
}
|
||||
|
||||
if (action->GetObjectId() == InfomainScript::c_iicx26in_RunAnim) {
|
||||
ControlManager()->FUN_100293c0(0x10, action->GetAtomId().GetInternal(), 0);
|
||||
ControlManager()->FUN_100293c0(InfomainScript::c_BigInfo_Ctl, action->GetAtomId().GetInternal(), 0);
|
||||
m_unk0x1d6 = 0;
|
||||
}
|
||||
|
||||
@@ -1159,16 +1159,16 @@ MxResult Infocenter::Tickle()
|
||||
m_unk0x1d6 += 100;
|
||||
|
||||
if (m_unk0x1d6 > 3400 && m_unk0x1d6 < 3650) {
|
||||
ControlManager()->FUN_100293c0(0x10, m_atom.GetInternal(), 1);
|
||||
ControlManager()->FUN_100293c0(InfomainScript::c_BigInfo_Ctl, m_atom.GetInternal(), 1);
|
||||
}
|
||||
else if (m_unk0x1d6 > 3650 && m_unk0x1d6 < 3900) {
|
||||
ControlManager()->FUN_100293c0(0x10, m_atom.GetInternal(), 0);
|
||||
ControlManager()->FUN_100293c0(InfomainScript::c_BigInfo_Ctl, m_atom.GetInternal(), 0);
|
||||
}
|
||||
else if (m_unk0x1d6 > 3900 && m_unk0x1d6 < 4150) {
|
||||
ControlManager()->FUN_100293c0(0x10, m_atom.GetInternal(), 1);
|
||||
ControlManager()->FUN_100293c0(InfomainScript::c_BigInfo_Ctl, m_atom.GetInternal(), 1);
|
||||
}
|
||||
else if (m_unk0x1d6 > 4400) {
|
||||
ControlManager()->FUN_100293c0(0x10, m_atom.GetInternal(), 0);
|
||||
ControlManager()->FUN_100293c0(InfomainScript::c_BigInfo_Ctl, m_atom.GetInternal(), 0);
|
||||
m_unk0x1d6 = 0;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user