From 47105e42cdef55bd1c5df094ba70d11644e4a308 Mon Sep 17 00:00:00 2001 From: Paul Chote Date: Sun, 2 Nov 2025 15:18:41 +0000 Subject: [PATCH] Populate lobby options when map status changes. --- OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyOptionsLogic.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyOptionsLogic.cs b/OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyOptionsLogic.cs index ba491a453d..5420dc1c39 100644 --- a/OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyOptionsLogic.cs +++ b/OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyOptionsLogic.cs @@ -34,6 +34,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic readonly OrderManager orderManager; readonly Func configurationDisabled; MapPreview mapPreview; + MapStatus mapStatus; [ObjectCreator.UseCtor] internal LobbyOptionsLogic(Widget widget, OrderManager orderManager, Func getMap, Func configurationDisabled) @@ -49,13 +50,14 @@ namespace OpenRA.Mods.Common.Widgets.Logic dropdownRowTemplate = optionsContainer.Get("DROPDOWN_ROW_TEMPLATE"); mapPreview = getMap(); + mapStatus = mapPreview.Status; RebuildOptions(); } public override void Tick() { var newMapPreview = getMap(); - if (newMapPreview == mapPreview) + if (newMapPreview == mapPreview && mapStatus == mapPreview.Status) return; // We are currently enumerating the widget tree and so can't modify any layout @@ -63,6 +65,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic Game.RunAfterTick(() => { mapPreview = newMapPreview; + mapStatus = mapPreview.Status; RebuildOptions(); }); }