Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -388,13 +388,13 @@ void GameLogic::reset( void )
#endif

m_pauseFrame = 0;
m_gamePaused = FALSE;
m_pauseSound = FALSE;
m_pauseMusic = FALSE;
m_pauseInput = FALSE;
m_inputEnabledMemory = TRUE;
m_mouseVisibleMemory = TRUE;
m_logicTimeScaleEnabledMemory = FALSE;
pauseGameLogic(FALSE);
pauseGameInput(FALSE);
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This means

	m_inputEnabledMemory = TRUE;
	m_mouseVisibleMemory = TRUE;

is set before pauseGameInput is called. Is this correct? Should not be called before?

Copy link
Copy Markdown
Author

@stephanmeesters stephanmeesters Feb 23, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's alright, with paused set to false and m_inputEnabledMemory set to true it will trigger an additional call to TheInGameUI->SetInputEnabled(TRUE) however very shortly after it will call the reset function of TheInGameUI and reset any changes anyway

So it should be fine regardless of order but I’ll check if swapping is more efficient here in case m_inputEnabledMemory is often false

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had another look still think it's OK: input=enabled and mouse=visible are the right default values to enforce, plus I was only ever able to see both m_inputEnabledMemory = TRUE and m_mouseVisibleMemory = TRUE in the debugger when entering reset.


setFPMode();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -400,13 +400,13 @@ void GameLogic::reset( void )
m_objVector.resize(OBJ_HASH_SIZE, nullptr);

m_pauseFrame = 0;
m_gamePaused = FALSE;
m_pauseSound = FALSE;
m_pauseMusic = FALSE;
m_pauseInput = FALSE;
m_inputEnabledMemory = TRUE;
m_mouseVisibleMemory = TRUE;
m_logicTimeScaleEnabledMemory = FALSE;
pauseGameLogic(FALSE);
pauseGameInput(FALSE);

setFPMode();

Expand Down
Loading