Add pose icon capture pipeline, icon scale, Esc/Tab opens overview in paint mode
- PoseIconStage: permanent editor capture pipeline (context menu 'Capture All Icons') — renders each entry at 4096x4096, alpha-crops, writes Icon_pose_*.png and wires sprites onto matching PlayerPose assets - PlayerPose: new iconScale property (0.1-2), applied to the icon child in PoseMenu's radial layout - OverviewMenu: paint-mode special-case removed — Esc/Tab opens the overview menu in every mode Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
2de153d8fe
commit
5f5892047c
4 files changed
+214
-11
No files matched your search
@@ -9,8 +9,7 @@ using UnityEngine.InputSystem;
|
||||
/// The Esc overview menu (the "Overview UI" canvas in Main). Owns ALL Escape handling (Tab acts as an
|
||||
/// alternative to Esc): Esc toggles
|
||||
/// this panel as a modal pause overlay (gameplay suspended via <see cref="GameModeManager.SetPaused"/>);
|
||||
/// while the session browser, match results or pose menu overlay is open instead, Esc closes that, and while paint
|
||||
/// mode is active Esc exits to the camera mode (Player Control, or First Person for the hunter). Buttons
|
||||
/// while the session browser, match results or pose menu overlay is open instead, Esc closes that. Buttons
|
||||
/// switch game modes (via <see cref="GameModeManager.TrySwitchTo{T}"/>) or open the session browser /
|
||||
/// match results overlay, and every click closes the panel. Mode buttons are only shown for modes present in the current role-scoped set
|
||||
/// (<see cref="GameModeManager.Modes"/>); the active mode's button is disabled. Hotkeys mirror the
|
||||
@@ -124,13 +123,6 @@ public class OverviewMenu : MonoBehaviour
|
||||
// pausing or switching modes here corrupts the camera rigs - Esc/Tab do nothing.
|
||||
else if (MatchManager.Instance && MatchManager.Instance.IsLoadingLocally)
|
||||
{ }
|
||||
// Paint mode: Esc exits back to the camera mode instead of opening the menu. Player Control
|
||||
// first; the hunter's role-scoped set has none, so it falls through to First Person.
|
||||
else if (gameMode && gameMode.EffectiveMode is PaintMode)
|
||||
{
|
||||
if (!gameMode.TrySwitchTo<PlayerControlMode>() && !gameMode.TrySwitchTo<FirstPersonMode>())
|
||||
Open();
|
||||
}
|
||||
// No active/paused mode = the inert no-player state (pre-lobby Main, where the session panel
|
||||
// is always shown) - nothing to pause, don't open.
|
||||
else if (gameMode && gameMode.EffectiveMode != null)
|
||||
|
||||
@@ -132,6 +132,7 @@ public class PoseMenu : MonoBehaviour
|
||||
icon.sprite = p ? p.Icon : null;
|
||||
icon.preserveAspect = true;
|
||||
icon.enabled = icon.sprite; // no icon authored -> no solid white square
|
||||
icon.rectTransform.localScale = Vector3.one * (p ? p.IconScale : 1f);
|
||||
}
|
||||
TMP_Text label = item.GetComponentInChildren<TMP_Text>(true);
|
||||
if (label) label.text = p && !string.IsNullOrEmpty(p.Title) ? p.Title : (p ? p.name : "");
|
||||
|
||||
Reference in new issue
Block a user