Skip to content

[GEN][ZH] Make Debug MessageBoxWrapper show message box before game window creation #1000

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

Caball009
Copy link

Calls to DEBUG_ASSERTCRASH may go unnoticed prior to the creation of any game window. There's no message box if the game window isn't created yet. For the initialization of static / global variables, it may be preferable to get a clear alert in the form of the message box instead of a quiet log entry.

@Caball009
Copy link
Author

Caball009 commented Jun 3, 2025

Is this problematic with headless mode? TheGlobalData->m_headless cannot be checked yet because TheGlobalData isn't initialized yet.

@xezon
Copy link

xezon commented Jun 13, 2025

The opening text says "For the initialization of static / global variables, it may be preferable to get a clear alert in the form of the message box instead of a quiet log entry."

But isn't this what this change touches? Why is describes as may be preferable if it is actually changed?

@@ -422,8 +419,10 @@ void DebugLog(const char *format, ...)
ScopedCriticalSection scopedCriticalSection(TheDebugLogCriticalSection);
#endif

#ifdef DEBUG_LOGGING
Copy link

Choose a reason for hiding this comment

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

This #ifdef looks redundant. The whole function already is in the same #ifdef condition.

@xezon xezon added Minor Severity: Minor < Major < Critical < Blocker Debug Is mostly debug functionality Fix Is fixing something, but is not user facing labels Jun 13, 2025
@xezon
Copy link

xezon commented Jun 25, 2025

I think this change can be finalized.

@Mauller
Copy link

Mauller commented Jul 15, 2025

Needs rebasing with main and updating

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Debug Is mostly debug functionality Fix Is fixing something, but is not user facing Minor Severity: Minor < Major < Critical < Blocker
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants