feat(engine): contextual one-time tips — stall hint, radial menu teach (Phase I)
Two situation-fired teaches, each shown exactly once and recorded in Settings like shown_achievement_onboarding: - Stall tip: 45s with no board change in an active, started game (clock frozen while paused / a modal is open) points at Hint with platform-correct copy (H on desktop, bottom-bar Hint on touch). - Radial teach: a player 15 moves into a game who has never opened the radial menu learns the long-press / right-click gesture. Organic radial use marks the tip done silently — nobody is taught what they already know. Tips ride the queued InfoToastEvent path, so they render in the unified toast stack and never interrupt play. This completes Phase I. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -265,6 +265,16 @@ pub struct Settings {
|
||||
/// `#[serde(default)]`.
|
||||
#[serde(default)]
|
||||
pub last_seen_whats_new: String,
|
||||
/// `true` once the one-shot "Stuck? Try a hint" contextual tip has
|
||||
/// fired (or been suppressed as unnecessary). Phase I teach: fired
|
||||
/// by the situation, shown once, like `shown_achievement_onboarding`.
|
||||
#[serde(default)]
|
||||
pub shown_stall_hint_tip: bool,
|
||||
/// `true` once the one-shot radial-menu contextual tip has fired —
|
||||
/// or the player has already opened the radial menu on their own,
|
||||
/// which marks the tip as unnecessary without showing it.
|
||||
#[serde(default)]
|
||||
pub shown_radial_menu_tip: bool,
|
||||
/// Custom public name displayed on the leaderboard. When `None`, the
|
||||
/// player's server `username` is used instead. Trimmed to 32 characters
|
||||
/// before submission. Older `settings.json` files written before this
|
||||
@@ -434,6 +444,8 @@ impl Default for Settings {
|
||||
last_difficulty: None,
|
||||
last_mode: GameMode::Classic,
|
||||
last_seen_whats_new: String::new(),
|
||||
shown_stall_hint_tip: false,
|
||||
shown_radial_menu_tip: false,
|
||||
leaderboard_display_name: None,
|
||||
leaderboard_opted_in: false,
|
||||
take_from_foundation: true,
|
||||
|
||||
Reference in New Issue
Block a user