implement/match Hospital::~Hospital() (#669)

This commit is contained in:
Ramen2X 2024-03-13 15:10:53 -04:00 committed by GitHub
parent 0f2aee1849
commit a9a564b25e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -6,9 +6,13 @@
#include "misc.h" #include "misc.h"
#include "mxmisc.h" #include "mxmisc.h"
#include "mxnotificationmanager.h" #include "mxnotificationmanager.h"
#include "mxticklemanager.h"
DECOMP_SIZE_ASSERT(Hospital, 0x12c) DECOMP_SIZE_ASSERT(Hospital, 0x12c)
// GLOBAL: LEGO1 0x100f7918
undefined4 g_unk0x100f7918 = 3;
// FUNCTION: LEGO1 0x100745e0 // FUNCTION: LEGO1 0x100745e0
Hospital::Hospital() Hospital::Hospital()
{ {
@ -33,10 +37,21 @@ MxBool Hospital::VTable0x5c()
return TRUE; return TRUE;
} }
// STUB: LEGO1 0x100747f0 // FUNCTION: LEGO1 0x100747f0
Hospital::~Hospital() Hospital::~Hospital()
{ {
// TODO InputManager()->UnRegister(this);
if (InputManager()->GetWorld() == this) {
InputManager()->ClearWorld();
}
ControlManager()->Unregister(this);
TickleManager()->UnregisterClient(this);
m_hospitalState->m_unk0x08.m_unk0x00 = 3;
NotificationManager()->Unregister(this);
g_unk0x100f7918 = 3;
} }
// FUNCTION: LEGO1 0x100748c0 // FUNCTION: LEGO1 0x100748c0