Repository navigation
Skip the start menu in multiplayer - #29
Merged
Merged
Conversation
The host starts its world right away; a client starts the world named in the host's Welcome once it is welcomed (the menu stays while connecting or if connecting fails). New game and loading a save are refused while in a multiplayer session, since both would replace the session's world. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019dyusVFME4gJhJqqEh2dDn
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Requested by Mateusz · project thread
Before: with
-hostor-connectthe game still opened the main menu and the player had to pick "New game". While the host sat in the menu, connected clients saw no NPCs, items or chests. A client always started its own default world, ignoring the one the host named inWelcome. "New game" and "Load" (menu and F9) worked during a session and replaced the world under the other players.After: the host starts its world right away. A client keeps the menu only while connecting, then loads the host's world as soon as it is welcomed; if connecting fails the menu stays usable for singleplayer. During a session "New game" prints "New game is disabled in multiplayer" and loading prints "Loading is disabled in multiplayer" (saving was already off since MP-13).
-saveis ignored in multiplayer.How:
NetSessionkeeps the world name fromWelcomeand hands it out once viatakeJoinedWorld();MainWindow::tickstarts that world aftertickNetwork()and closes the menu. TheMainWindowconstructor starts the host's world instead of showing the menu.Gothic::loadand theNEW_GAMEmenu action refuse in multiplayer.NetSessionTestchecks that the client gets the host's world exactly once.Built Gothic2Notr and ran all six net tests locally (passing). Not run with game data.
🤖 Generated with Claude Code
https://claude.ai/code/session_019dyusVFME4gJhJqqEh2dDn
Generated by Claude Code