Name Disable function in LegoOmni and misc (#1616)

This commit is contained in:
Fabian Neundorf 2025-07-12 02:10:36 +02:00 committed by GitHub
parent 6497cb42b7
commit a34c293177
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
28 changed files with 47 additions and 47 deletions

View File

@ -129,7 +129,7 @@ public:
LegoROI* FindROI(const char* p_name);
void AddWorld(LegoWorld* p_world);
void DeleteWorld(LegoWorld* p_world);
void FUN_1005b4f0(MxBool p_disable, MxU16 p_flags);
void Disable(MxBool p_disable, MxU16 p_flags);
void CreateBackgroundAudio();
void RemoveWorld(const MxAtomId& p_atom, MxLong p_objectId);
MxResult RegisterWorlds();

View File

@ -48,7 +48,7 @@ LegoPlantManager* PlantManager();
LegoBuildingManager* BuildingManager();
LegoTextureContainer* TextureContainer();
ViewLODListManager* GetViewLODListManager();
void FUN_10015820(MxBool p_disable, MxU16 p_flags);
void Disable(MxBool p_disable, MxU16 p_flags);
LegoROI* FindROI(const char* p_name);
void SetROIVisible(const char* p_name, MxBool p_visible);
void SetUserActor(LegoPathActor* p_userActor);

View File

@ -372,7 +372,7 @@ MxLong Ambulance::HandleClick()
return 1;
}
FUN_10015820(TRUE, 0);
Disable(TRUE, 0);
((Isle*) CurrentWorld())->SetDestLocation(LegoGameState::e_ambulance);
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);

View File

@ -54,7 +54,7 @@ MxLong Bike::HandleClick()
{
if (CanExit()) {
Act1State* state = (Act1State*) GameState()->GetState("Act1State");
FUN_10015820(TRUE, 0);
Disable(TRUE, 0);
((Isle*) CurrentWorld())->SetDestLocation(LegoGameState::Area::e_bike);
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, TRUE);

View File

@ -92,7 +92,7 @@ MxLong DuneBuggy::HandleClick()
return 1;
}
FUN_10015820(TRUE, 0);
Disable(TRUE, 0);
((Isle*) CurrentWorld())->SetDestLocation(LegoGameState::Area::e_dunecar);
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, TRUE);

View File

@ -148,7 +148,7 @@ MxLong Helicopter::HandleClick()
IslePathActor::c_spawnBit1 | IslePathActor::c_playMusic | IslePathActor::c_spawnBit3
);
((Isle*) CurrentWorld())->SetDestLocation(LegoGameState::e_copter);
FUN_10015820(TRUE, 0);
Disable(TRUE, 0);
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, TRUE);
SetActorState(c_disabled);
PlayMusic(JukeboxScript::c_Jail_Music);

View File

@ -85,7 +85,7 @@ MxLong Jetski::HandleClick()
return 1;
}
FUN_10015820(TRUE, 0);
Disable(TRUE, 0);
((Isle*) CurrentWorld())->SetDestLocation(LegoGameState::Area::e_jetski);
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, TRUE);

View File

@ -88,7 +88,7 @@ MxLong Motocycle::HandleClick()
return 1;
}
FUN_10015820(TRUE, 0);
Disable(TRUE, 0);
((Isle*) CurrentWorld())->SetDestLocation(LegoGameState::Area::e_motocycle);
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, TRUE);

View File

@ -79,7 +79,7 @@ MxLong SkateBoard::HandleClick()
return 1;
}
FUN_10015820(TRUE, 0);
Disable(TRUE, 0);
((Isle*) CurrentWorld())->SetDestLocation(LegoGameState::Area::e_skateboard);
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, TRUE);

View File

@ -411,7 +411,7 @@ MxLong TowTrack::HandleClick()
return 1;
}
FUN_10015820(TRUE, 0);
Disable(TRUE, 0);
((Isle*) CurrentWorld())->SetDestLocation(LegoGameState::e_towtrack);
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);

View File

@ -1253,7 +1253,7 @@ void LegoCarBuild::FUN_10024ef0()
m_buildState->m_animationState = LegoVehicleBuildState::e_cutscene;
FUN_10025720(FUN_10025d70());
m_buildState->m_unk0x4c += 1;
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
// FUNCTION: LEGO1 0x10024f30

View File

@ -851,7 +851,7 @@ void LegoGameState::SwitchArea(Area p_area)
m_previousArea = m_currentArea;
m_currentArea = p_area;
FUN_10015820(TRUE, LegoOmni::c_disableInput | LegoOmni::c_disable3d);
Disable(TRUE, LegoOmni::c_disableInput | LegoOmni::c_disable3d);
BackgroundAudioManager()->Stop();
AnimationManager()->Suspend();
VideoManager()->SetUnk0x554(FALSE);

View File

@ -140,10 +140,10 @@ ViewLODListManager* GetViewLODListManager()
// FUNCTION: LEGO1 0x10015820
// FUNCTION: BETA10 0x100e4c92
void FUN_10015820(MxBool p_disable, MxU16 p_flags)
void Disable(MxBool p_disable, MxU16 p_flags)
{
assert(LegoOmni::GetInstance());
LegoOmni::GetInstance()->FUN_1005b4f0(p_disable, p_flags);
LegoOmni::GetInstance()->Disable(p_disable, p_flags);
}
// FUNCTION: LEGO1 0x10015840

View File

@ -62,7 +62,7 @@ LegoWorldPresenter::~LegoWorldPresenter()
}
if (result == FALSE) {
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
if (m_entity) {

View File

@ -518,7 +518,7 @@ LegoOmni::World LegoOmni::GetWorldId(const char* p_key)
}
// FUNCTION: LEGO1 0x1005b4f0
void LegoOmni::FUN_1005b4f0(MxBool p_disable, MxU16 p_flags)
void LegoOmni::Disable(MxBool p_disable, MxU16 p_flags)
{
if (p_disable) {
if (p_flags & c_disableInput) {

View File

@ -124,7 +124,7 @@ void CarRace::ReadyWorld()
BackgroundAudioManager()->PlayMusic(action, 5, MxPresenter::e_repeating);
AnimationManager()->Resume();
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
m_unk0x144 = g_unk0x100d5d10[rand() & 7];

View File

@ -95,7 +95,7 @@ void JetskiRace::ReadyWorld()
m_unk0x12c = (MxStillPresenter*) Find("MxPresenter", "JetskiLocator3");
m_unk0x12c->SetPosition(m_unk0x130.GetLeft(), m_unk0x130.GetTop());
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
VariableTable()->SetVariable("DISTANCE", "0.036");

View File

@ -552,7 +552,7 @@ MxLong Act3::Notify(MxParam& p_param)
if (param.GetAction() != NULL && param.GetAction()->GetAtomId() == *g_act3Script) {
if (param.GetAction()->GetObjectId() == Act3Script::c_HelicopterDashboard) {
MxDSAction action;
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
SetAppCursor(e_cursorArrow);
VideoManager()->Get3DManager()->SetFrustrum(45.0f, 0.1f, 125.0f);
@ -634,7 +634,7 @@ MxLong Act3::Notify(MxParam& p_param)
assert(m_copter && m_brickster && m_cop1 && m_cop2);
m_unk0x4220.FUN_100720d0(0);
m_state->m_unk0x08 = 0;
FUN_10015820(TRUE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(TRUE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
m_copter->HandleClick();
m_copter->m_state->m_unk0x08 = 1;
m_copter->HandleEndAnim((LegoEndAnimNotificationParam&) param);
@ -685,7 +685,7 @@ MxResult Act3::Tickle()
if (m_unk0x426c != (Act3Script::Script) 0) {
if (AnimationManager()->FUN_10064ee0(m_unk0x426c)) {
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
TickleManager()->UnregisterClient(this);
m_unk0x426c = (Act3Script::Script) 0;
}
@ -880,7 +880,7 @@ void Act3::Enable(MxBool p_enable)
GameState()->StopArea(LegoGameState::e_infomain);
}
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
PlayMusic(JukeboxScript::c_Act3Music);
GameState()->m_isDirty = TRUE;

View File

@ -79,7 +79,7 @@ void ElevatorBottom::ReadyWorld()
{
LegoWorld::ReadyWorld();
PlayMusic(JukeboxScript::c_InformationCenter_Music);
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
// FUNCTION: LEGO1 0x100181d0

View File

@ -265,7 +265,7 @@ void GasStation::ReadyWorld()
break;
}
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
// FUNCTION: LEGO1 0x10005590

View File

@ -214,7 +214,7 @@ void Hospital::ReadyWorld()
m_setWithCurrentAction = 1;
}
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
// FUNCTION: LEGO1 0x10074dd0

View File

@ -465,7 +465,7 @@ void Infocenter::ReadyWorld()
PlayAction(InfomainScript::c_iicx18in_RunAnim);
PlayMusic(JukeboxScript::c_InformationCenter_Music);
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
return;
case 5:
default: {
@ -478,7 +478,7 @@ void Infocenter::ReadyWorld()
m_bigInfoBlinkTimer = 1;
}
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
if (!m_infocenterState->HasRegistered()) {
m_bookAnimationTimer = 1;
@ -489,7 +489,7 @@ void Infocenter::ReadyWorld()
case 8:
PlayMusic(JukeboxScript::c_InformationCenter_Music);
PlayAction(InfomainScript::c_iic043in_RunAnim);
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
return;
case 0xf:
m_infocenterState->m_unk0x74 = 2;
@ -499,7 +499,7 @@ void Infocenter::ReadyWorld()
PlayAction(InfomainScript::c_iicx17in_RunAnim);
PlayMusic(JukeboxScript::c_InformationCenter_Music);
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
return;
}
break;
@ -508,7 +508,7 @@ void Infocenter::ReadyWorld()
PlayMusic(JukeboxScript::c_InformationCenter_Music);
bgRed->Enable(TRUE);
PlayAction(InfomainScript::c_iic043in_RunAnim);
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
return;
}
@ -538,7 +538,7 @@ void Infocenter::ReadyWorld()
PlayAction(script);
InputManager()->DisableInputProcessing();
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
return;
}
@ -553,7 +553,7 @@ void Infocenter::ReadyWorld()
PlayMusic(JukeboxScript::c_InformationCenter_Music);
bgRed->Enable(TRUE);
PlayAction(InfomainScript::c_iic043in_RunAnim);
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
return;
}
@ -590,7 +590,7 @@ void Infocenter::ReadyWorld()
PlayAction(script);
InputManager()->DisableInputProcessing();
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
return;
}
@ -603,7 +603,7 @@ void Infocenter::ReadyWorld()
}
m_infocenterState->m_unk0x74 = 11;
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
// FUNCTION: LEGO1 0x1006f9a0
@ -1284,7 +1284,7 @@ void Infocenter::StopCutscene()
VideoManager()->EnableFullScreenMovie(FALSE);
InputManager()->SetUnknown335(FALSE);
SetAppCursor(e_cursorArrow);
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
// FUNCTION: LEGO1 0x10070d00

View File

@ -88,7 +88,7 @@ void InfocenterDoor::ReadyWorld()
{
LegoWorld::ReadyWorld();
PlayMusic(JukeboxScript::c_InformationCenter_Music);
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
// FUNCTION: LEGO1 0x10037a90

View File

@ -277,7 +277,7 @@ void Isle::ReadyWorld()
EnableAnimations(TRUE);
FUN_10032620();
m_act1state->PlaceActors();
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
}
@ -839,7 +839,7 @@ void Isle::Enable(MxBool p_enable)
(m_act1state->m_unk0x018 != 0 || GameState()->m_currentArea != LegoGameState::e_jetski) &&
(m_act1state->m_unk0x018 != 0 || GameState()->m_currentArea != LegoGameState::e_skateboard) &&
(m_act1state->m_unk0x018 != 0 || GameState()->m_currentArea != LegoGameState::e_jetrace2)) {
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
SetROIVisible("stretch", FALSE);
@ -961,7 +961,7 @@ MxLong Isle::HandleTransitionEnd()
m_destLocation = LegoGameState::e_undefined;
VariableTable()->SetVariable("VISIBILITY", "Show Gas");
AnimationManager()->Resume();
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
SetAppCursor(e_cursorArrow);
SetIsWorldActive(TRUE);
break;
@ -971,7 +971,7 @@ MxLong Isle::HandleTransitionEnd()
m_destLocation = LegoGameState::e_undefined;
VariableTable()->SetVariable("VISIBILITY", "Show Policsta");
AnimationManager()->Resume();
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
SetAppCursor(e_cursorArrow);
SetIsWorldActive(TRUE);
break;
@ -1082,7 +1082,7 @@ void Isle::FUN_10032d30(
VariableTable()->SetVariable(g_varCAMERALOCATION, p_cameraLocation);
}
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
SetAppCursor(e_cursorArrow);
m_destLocation = LegoGameState::e_undefined;
m_act1state->m_unk0x01f = FALSE;

View File

@ -247,7 +247,7 @@ MxResult JukeBox::Tickle()
if (m_unk0x100 == 1) {
m_unk0x100 = 0;
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
return SUCCESS;

View File

@ -192,7 +192,7 @@ MxResult LegoAct2::Tickle()
case 2:
if (g_unk0x100f4474) {
if (AnimationManager()->FUN_10064ee0(g_unk0x100f4474)) {
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
g_unk0x100f4474 = (Act2mainScript::Script) 0;
}
}
@ -200,7 +200,7 @@ MxResult LegoAct2::Tickle()
m_unk0x10d0 += 50;
break;
case 3:
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
m_unk0x10d0 = 0;
m_unk0x10c4 = 4;
FUN_10052560(Act2mainScript::c_tja009ni_RunAnim, TRUE, TRUE, NULL, NULL, NULL);
@ -540,7 +540,7 @@ void LegoAct2::Enable(MxBool p_enable)
GameState()->StopArea(LegoGameState::e_infomain);
}
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
if (m_unk0x10c4 != 6 && m_unk0x10c4 != 12) {
PlayMusic(m_music);

View File

@ -95,7 +95,7 @@ void Police::ReadyWorld()
{
LegoWorld::ReadyWorld();
PlayMusic(JukeboxScript::c_PoliceStation_Music);
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
// FUNCTION: LEGO1 0x1005e550

View File

@ -159,7 +159,7 @@ void Score::ReadyWorld()
PlayMusic(JukeboxScript::c_InformationCenter_Music);
}
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
}
// FUNCTION: LEGO1 0x100016d0