diff --git a/AstraSkinsPlugin.cs b/AstraSkinsPlugin.cs index 0d2abbe..7a17632 100644 --- a/AstraSkinsPlugin.cs +++ b/AstraSkinsPlugin.cs @@ -936,6 +936,7 @@ private HookResult OnBotTakeover(EventBotTakeover @event, GameEventInfo info) private HookResult OnRoundPrestart(EventRoundPrestart @event, GameEventInfo info) { _pendingMvpCue = null; + _menuManager?.CloseAll(); // Valve fills team_intro Xuid on this event; write after the assignment lands. ScheduleTeamPreviewApply(); return HookResult.Continue; diff --git a/MenuManager.cs b/MenuManager.cs index 826ddec..300589a 100644 --- a/MenuManager.cs +++ b/MenuManager.cs @@ -165,6 +165,17 @@ public void Close(CCSPlayerController player, bool clearScreen = true) } } + public void CloseAll() + { + foreach (var player in Utilities.GetPlayers()) + { + if (player is { IsValid: true }) + { + Close(player); + } + } + } + public void CloseSlot(int slot) { _states.Remove(slot); diff --git a/README.md b/README.md index 98f299b..6411fef 100644 --- a/README.md +++ b/README.md @@ -124,7 +124,7 @@ Both can be disabled entirely in the config. | `Shift` | Back | | `R` | Close | -The menu items are numbered as a visual guide for orientation; navigation is by keys, not numbers. While the menu is open the player is held in place. Heads up: `E` still performs its normal in-world action (open doors, pick up weapons, defuse), so avoid confirming a selection while standing on the bomb. +The menu items are numbered as a visual guide for orientation; navigation is by keys, not numbers. While the menu is open the player is held in place. The menu closes when a new round starts. Heads up: `E` still performs its normal in-world action (open doors, pick up weapons, defuse), so avoid confirming a selection while standing on the bomb. Every skin, knife, glove, agent and music kit list starts with a **Default** row that removes the selection and is marked when nothing is selected: the stock finish of a gun or knife (stickers, charms, name tags and counters saved for it stay on), the default knife, the default gloves, the default agent (back on the next spawn) and the default music kit.