You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Verify GUI and hook lifecycle on dedicated servers and repeated mission loads #28
There are a couple of lifecycle assumptions that may be worth checking on a dedicated server and when loading more than one mission in the same game process.
RmAscSettings.initGui() runs when the file is sourced and immediately reads g_inGameMenu.pageSettings. It checks whether pageSettings exists, but not whether g_inGameMenu itself is available. If a dedicated server does not initialize that GUI global, the mod may fail while loading.
Several other registrations run whenever a mission starts:
The three custom dialogs are registered.
Menu integration is initialized.
Vehicle detection is initialized.
PlayerInputComponent.registerGlobalPlayerActionEvents is wrapped.
Menu methods such as updateMenuButtons, setVehicle, and setPlaceable are wrapped.
The input action is added to Gui.NAV_ACTIONS.
deleteMap() removes the console commands and clears capacity data, but it does not undo those registrations. If FS25 can start a second mission without restarting the process, the wrappers and navigation action may be installed more than once.
I have not reproduced a crash or duplicate callback in-game, so this should be treated as an investigation rather than a confirmed defect.
Suggested checks:
Start the mod on a dedicated server and load a save.
Confirm that loading does not depend on client GUI globals.
Return to the menu and load another save without restarting the game.
Check for duplicated menu buttons, input actions, callbacks, or log entries.
Repeat the second-mission test as both a single-player host and a multiplayer client.
If either case exposes a problem, likely directions would be to keep GUI setup on clients, make initialization idempotent, and clean up or avoid reinstalling global hooks between missions.
Relevant code:
scripts/RmAscSettings.lua: initGui and the source-time initialization
scripts/RmAdjustStorageCapacity.lua: onMissionStarted and deleteMap
scripts/RmMenuIntegration.lua: init, initWorkshopScreen, and initPlaceableInfoDialog
Activity