Remove getters/setters that (likely) don't exist (#1583)

Co-authored-by: jonschz <jonschz@users.noreply.github.com>
This commit is contained in:
jonschz 2025-06-23 20:58:16 +02:00 committed by GitHub
parent 1701117e6f
commit edae5f58ec
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 14 additions and 22 deletions

View File

@ -223,14 +223,8 @@ public:
Act GetCurrentAct() { return m_currentAct; }
Act GetLoadedAct() { return m_loadedAct; }
Area GetPreviousArea() { return m_previousArea; }
Area GetUnknown0x42c() { return m_unk0x42c; }
void SetDirty(MxBool p_isDirty) { m_isDirty = p_isDirty; }
void SetPreviousArea(Area p_previousArea) { m_previousArea = p_previousArea; }
void SetActorId(MxU8 p_actorId) { m_actorId = p_actorId; }
Username* GetPlayersIndex(MxS32 p_index) { return &m_players[p_index]; }
MxS16 GetPlayerCount() { return m_playerCount; }
LegoBackgroundColor* GetBackgroundColor() { return m_backgroundColor; }
void SetCurrentAct(Act p_currentAct);
@ -254,14 +248,11 @@ private:
LegoBackgroundColor* m_tempBackgroundColor; // 0x1c
LegoFullScreenMovie* m_fullScreenMovie; // 0x20
// TODO: Most likely getters/setters are not used according to BETA for the following members:
public:
MxS16 m_currentPlayerId; // 0x24
MxS16 m_playerCount; // 0x26
Username m_players[9]; // 0x28
History m_history; // 0xa6
undefined2 m_unk0x41a; // 0x41a
JukeboxScript::Script m_jukeboxMusic; // 0x41c
MxBool m_isDirty; // 0x420
Area m_currentArea; // 0x424

View File

@ -1629,6 +1629,7 @@ void LegoGameState::SerializeScoreHistory(MxS16 p_flags)
}
// FUNCTION: LEGO1 0x1003cea0
// FUNCTION: BETA10 0x10017840
void LegoGameState::SetCurrentAct(Act p_currentAct)
{
m_currentAct = p_currentAct;

View File

@ -488,7 +488,7 @@ MxResult Act3::Create(MxDSAction& p_dsAction)
case LegoGameState::e_act1:
case LegoGameState::e_actNotFound:
GameState()->StopArea(LegoGameState::e_undefined);
if (GameState()->GetPreviousArea() == LegoGameState::e_infomain) {
if (GameState()->m_previousArea == LegoGameState::e_infomain) {
GameState()->StopArea(LegoGameState::e_isle);
}
}
@ -505,7 +505,7 @@ MxResult Act3::Create(MxDSAction& p_dsAction)
GameState()->m_currentArea = LegoGameState::e_act3script;
GameState()->SetCurrentAct(LegoGameState::e_act3);
GameState()->SetDirty(TRUE);
GameState()->m_isDirty = TRUE;
}
return result;
@ -883,7 +883,7 @@ void Act3::Enable(MxBool p_enable)
FUN_10015820(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
PlayMusic(JukeboxScript::c_Act3Music);
GameState()->SetDirty(TRUE);
GameState()->m_isDirty = TRUE;
if (m_time > 0) {
MxFloat delta = Timer()->GetTime() - m_time - 100.0f;

View File

@ -219,7 +219,7 @@ MxResult Infocenter::Create(MxDSAction& p_dsAction)
if (m_infocenterState->m_unk0x74 == 4) {
LegoGameState* state = GameState();
state->SetPreviousArea(GameState()->GetUnknown0x42c());
state->m_previousArea = GameState()->m_unk0x42c;
}
InputManager()->Register(this);
@ -1020,13 +1020,13 @@ MxU8 Infocenter::HandleControl(LegoControlManagerNotificationParam& p_param)
case InfomainScript::c_BigInfo_Ctl:
switch (state->GetCurrentAct()) {
case LegoGameState::e_act1:
if (state->GetPreviousArea()) {
switch (state->GetPreviousArea()) {
if (state->m_previousArea) {
switch (state->m_previousArea) {
case LegoGameState::e_infodoor:
case LegoGameState::e_regbook:
case LegoGameState::e_infoscor:
m_infocenterState->m_unk0x74 = 5;
m_destLocation = state->GetPreviousArea();
m_destLocation = state->m_previousArea;
actionToPlay = (InfomainScript::Script) m_infocenterState->GetNextLeaveDialogue();
m_radio.Stop();
InputManager()->DisableInputProcessing();
@ -1081,7 +1081,7 @@ MxU8 Infocenter::HandleControl(LegoControlManagerNotificationParam& p_param)
actionToPlay = GameState()->GetCurrentAct() != LegoGameState::e_act1 ? InfomainScript::c_GoTo_RegBook_Red
: InfomainScript::c_GoTo_RegBook;
m_radio.Stop();
GameState()->m_unk0x42c = GameState()->GetPreviousArea();
GameState()->m_unk0x42c = GameState()->m_previousArea;
InputManager()->DisableInputProcessing();
break;
case InfomainScript::c_Mama_Ctl:
@ -1390,7 +1390,7 @@ void Infocenter::Reset()
AnimationManager()->Reset(FALSE);
CharacterManager()->ReleaseAllActors();
GameState()->SetCurrentAct(LegoGameState::e_act1);
GameState()->SetPreviousArea(LegoGameState::e_undefined);
GameState()->m_previousArea = LegoGameState::e_undefined;
GameState()->m_unk0x42c = LegoGameState::e_undefined;
InitializeBitmaps();

View File

@ -121,7 +121,7 @@ MxResult Isle::Create(MxDSAction& p_dsAction)
m_act1state = act1state;
EnableAnimations(TRUE);
GameState()->SetDirty(TRUE);
GameState()->m_isDirty = TRUE;
}
return result;

View File

@ -141,7 +141,7 @@ MxResult LegoAct2::Create(MxDSAction& p_dsAction)
case LegoGameState::e_act1:
case LegoGameState::e_actNotFound:
GameState()->StopArea(LegoGameState::e_undefined);
if (GameState()->GetPreviousArea() == LegoGameState::e_infomain) {
if (GameState()->m_previousArea == LegoGameState::e_infomain) {
GameState()->StopArea(LegoGameState::e_isle);
}
}
@ -149,7 +149,7 @@ MxResult LegoAct2::Create(MxDSAction& p_dsAction)
GameState()->m_currentArea = LegoGameState::e_act2main;
GameState()->SetCurrentAct(LegoGameState::e_act2);
InputManager()->Register(this);
GameState()->SetDirty(TRUE);
GameState()->m_isDirty = TRUE;
}
return result;
@ -536,7 +536,7 @@ void LegoAct2::Enable(MxBool p_enable)
((IslePathActor*) m_pepper->GetEntity())->VTable0xec(m_unk0x10dc, m_unk0x1124, TRUE);
if (GameState()->GetPreviousArea() == LegoGameState::e_infomain) {
if (GameState()->m_previousArea == LegoGameState::e_infomain) {
GameState()->StopArea(LegoGameState::e_infomain);
}