Skip to content
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

Fix: Added a blocking layer to prevent interaction with the game while in the exit menu #2574

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
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
29 changes: 27 additions & 2 deletions Patch104pZH/GameFilesEdited/Data/INI/WindowTransitions.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2258,10 +2258,16 @@ WindowTransition QuitNoSave

Window
WinName = QuitNoSave.wnd:QuitMenuParent
Style = FLASH
Style = WINFADE
FrameDelay = 0
END

Window
WinName = QuitNoSave.wnd:MenuBox
Style = FLASH
FrameDelay = 1
Copy link
Collaborator

Choose a reason for hiding this comment

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

What does this frame delay do? Before it was 0.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The delay defines the order in which the elements appear, and I defined that the menu will appear one delay after the blocking screen. You can see in the buttons that the delay increases from button to button, and thus the buttons appear one after the other and not all at once.
Now that we have made the blocking element completely transparent, we can return it to 0.

END

Window
WinName = QuitNoSave.wnd:ButtonOptions
Style = BUTTONFLASH
Expand Down Expand Up @@ -2292,9 +2298,16 @@ WindowTransition QuitNoSaveBack

Window
WinName = QuitNoSave.wnd:QuitMenuParent
Style = WINFADE
FrameDelay = 0
END

Window
WinName = QuitNoSave.wnd:MenuBox
Style = FLASH
FrameDelay = 0
END

Window
WinName = MainMenu.wnd:MapBorder2
Style = REVERSESOUND
Expand Down Expand Up @@ -2330,10 +2343,16 @@ WindowTransition QuitFull

Window
WinName = QuitMenu.wnd:QuitMenuParent
Style = FLASH
Style = WINFADE
FrameDelay = 0
END

Window
WinName = QuitMenu.wnd:MenuBox
Style = FLASH
FrameDelay = 1
END

Window
WinName = QuitMenu.wnd:ButtonSaveLoad
Style = BUTTONFLASH
Expand Down Expand Up @@ -2371,6 +2390,12 @@ WindowTransition QuitFullBack

Window
WinName = QuitMenu.wnd:QuitMenuParent
Style = WINFADE
FrameDelay = 0
END

Window
WinName = QuitMenu.wnd:MenuBox
Style = FLASH
FrameDelay = 0
END
Expand Down
2 changes: 1 addition & 1 deletion Patch104pZH/GameFilesEdited/Window/Menus/QuitMenu.wnd
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ WINDOW
SCREENRECT = UPPERLEFT: 252 100,
BOTTOMRIGHT: 552 428,
CREATIONRESOLUTION: 800 600;
NAME = "QuitMenu.wnd:";
NAME = "QuitMenu.wnd:MenuBox";
STATUS = ENABLED;
STYLE = USER;
SYSTEMCALLBACK = "PassMessagesToParentSystem";
Expand Down
2 changes: 1 addition & 1 deletion Patch104pZH/GameFilesEdited/Window/Menus/QuitNoSave.wnd
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ WINDOW
SCREENRECT = UPPERLEFT: 252 114,
BOTTOMRIGHT: 547 393,
CREATIONRESOLUTION: 800 600;
NAME = "QuitNoSave.wnd:";
NAME = "QuitNoSave.wnd:MenuBox";
STATUS = ENABLED;
STYLE = USER;
SYSTEMCALLBACK = "PassMessagesToParentSystem";
Expand Down