dc42425c01
Single player on its server thread could not be opened to the LAN: the window is a client of that server, and Open to LAN, /publish and `horizon-ctl lan` tried to start a second hub on the window's side. The server thread now publishes itself, as IntegratedServer.publishServer does: - The window asks its server with `Integrated::call` (executeBlocking): a task run between two ticks, while paused too, with its answer. - Publishing binds the port at once (a busy port fails right away), then the hub starts listening and announcing the world (LanServerPinger) with the MOTD "<owner> - <world>". Until then only the owner may log in; afterwards anyone may, and status pings are answered. - Unpublishing stops the listener and sends every player but the owner away (multiplayer.disconnect.server_shutdown). - /publish and /unpublish run on the server for the player who types them, and the integrated server's command tree (with publish, without the dedicated-only commands) is what its players get. - The owner's level follows Allow Commands; other players get game master commands only when guests may use commands and the world allows them (IntegratedServer.getCustomPermissionLevel). Every player's command runs at their own level. - The world options screen reads and applies its settings on the server: difficulty, default and personal game mode, Allow Commands and the LAN settings; the window shows the outcome. - A published world does not pause (Minecraft.pause needs !isPublished), and F3+Escape follows the same rule. - Memory connections are never compressed, whatever the threshold (Connection.isMemoryConnection), so network players get the usual 256. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>