Files
Project-M/Assets/_Project/Scripts/Client/Onboarding/OnboardingState.cs
T
kronic ab657fa578 Onboarding + loop flow for a hands-off demo; GoalTarget 4->2
Lap-1 Fabricator affordable (StartingOre 50->90); mine prompt shows IN the room;
Return no longer false-completes on death (WasOnExpedition latch + soft timeout,
never the 1-tick Returning edge); HUD keeps room/siege/ammo cues during combat
steps; Welcome needs an explicit confirm; READY panel shows FINAL DEFENSE when
goal-full; dev Force-Each-Launch hidden from public Settings. GoalProgress.Target
4->2 (~10-20 min demo). Onboarding tests updated to the new contracts (456/456).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-05 20:21:42 -07:00

27 lines
1.4 KiB
C#

using UnityEngine;
namespace ProjectM.Client
{
/// <summary>
/// Tiny static coordination bridge for the first-run onboarding overlay. <see cref="Active"/> is true while a
/// coach-mark step is on screen (set each frame by <see cref="OnboardingSystem"/>); <see cref="HudSystem"/>
/// reads it to suppress its own ad-hoc location/gate hint so the player ever sees a single prompt voice.
/// A presentation-layer static, so it is RESET on play-enter (the CLAUDE.md stale-static rule) to avoid a
/// stale flag surviving a fast-enter-playmode domain reload and leaving the HUD hint suppressed.
/// </summary>
public static class OnboardingState
{
/// <summary>True while the coach-mark sequence is the active prompt voice (a step is being shown).</summary>
public static bool Active;
/// <summary>True only while an EARLY base-framing step (Welcome/Move/Build/Fabricator/ReadyUp) is showing, so
/// HudSystem blanks its own location line for those (the coach-mark owns the voice) but LEAVES the room/siege/
/// out-of-ammo cues visible during the combat steps (D4). Set each frame by OnboardingSystem.</summary>
public static bool SuppressLocationLine;
[RuntimeInitializeOnLoadMethod(RuntimeInitializeLoadType.SubsystemRegistration)]
static void ResetOnPlayEnter() { Active = false; SuppressLocationLine = false; }
}
}