Implement Infocenter::StartCredits

This commit is contained in:
Christian Semmler 2024-02-07 10:39:29 -05:00
parent 18dff31dbd
commit 2dcf46d147
3 changed files with 55 additions and 2 deletions

View File

@ -37,6 +37,7 @@ class LegoVideoManager : public MxVideoManager {
void SetSkyColor(float p_red, float p_green, float p_blue);
void OverrideSkyColor(MxBool p_shouldOverride);
void FUN_1007c520();
inline Lego3DManager* Get3DManager() { return this->m_3dManager; }
inline MxDirect3D* GetDirect3D() { return this->m_direct3d; }

View File

@ -1163,10 +1163,56 @@ MxBool Infocenter::VTable0x64()
return FALSE;
}
// STUB: LEGO1 0x10071030
// FUNCTION: LEGO1 0x10071030
void Infocenter::StartCredits()
{
// TODO
while (!m_set0xa8.empty()) {
MxCoreSet::iterator it = m_set0xa8.begin();
MxCore* object = *it;
m_set0xa8.erase(it);
if (object->IsA("MxPresenter")) {
MxPresenter* presenter = (MxPresenter*) object;
MxDSAction* action = presenter->GetAction();
if (action) {
FUN_100b7220(action, MxDSAction::c_world, FALSE);
presenter->EndAction();
}
}
else {
delete object;
}
}
MxPresenterListCursor cursor(&m_controlPresenters);
MxPresenter* presenter;
while (cursor.First(presenter)) {
cursor.Detach();
MxDSAction* action = presenter->GetAction();
if (action) {
FUN_100b7220(action, MxDSAction::c_world, FALSE);
presenter->EndAction();
}
}
BackgroundAudioManager()->Stop();
MxS16 i = 0;
do {
if (m_infocenterState->GetInfocenterBufferElement(i) != NULL) {
m_infocenterState->GetInfocenterBufferElement(i)->Enable(FALSE);
}
i++;
} while (i < m_infocenterState->GetInfocenterBufferSize());
VideoManager()->FUN_1007c520();
GetViewManager()->RemoveAll(NULL);
InvokeAction(Extra::e_opendisk, *g_creditsScript, c_unk499, NULL);
SetAppCursor(0);
}
// FUNCTION: LEGO1 0x10071250

View File

@ -471,6 +471,12 @@ void LegoVideoManager::UpdateView(MxU32 p_x, MxU32 p_y, MxU32 p_width, MxU32 p_h
}
}
// STUB: LEGO1 0x1007c520
void LegoVideoManager::FUN_1007c520()
{
// TODO
}
// STUB: LEGO1 0x1007c560
int LegoVideoManager::EnableRMDevice()
{