Files
nightclub-arcadia/NightclubArcadia/Assets/Dialogue/Common.yarn
T
2026-08-15 13:01:04 +02:00

51 lines
2.1 KiB
Plaintext

// Shared declarations for the whole project.
//
// This node is never played. Declaring every variable in one place means the
// compiler catches typos ("$reputaton") instead of silently creating a second
// variable at runtime.
//
// Writing rules the code deliberately does not enforce (Skill Bible §7 / refactor plan §2.1):
// - Wrong Truth failures carry no failure signal in the prose — the UI banner is the only tell.
// - Documentary routes are gated on Act and errand state, never on a voice.
//
// Modifier Yarn commands (see YarnSkillCommands):
// <<skill_mod scene facework 2>> — source key "scene" = situational; clear on scene exit
// <<clear_skill_mods scene>>
// Other source keys (drunk, injured, …) are state buckets.
title: Declarations
---
// How much the door staff likes you.
<<declare $reputation = 0 as number>>
// Set when the player has tried the "I'm on the list" line at least once.
<<declare $claimed_to_be_on_list = false as bool>>
// The bouncer's verdict, read by the scene that called him.
<<declare $went_inside = false as bool>>
// Smart variable: derived, not stored. Can never drift out of sync with
// $reputation, so there's nothing to remember to update.
<<declare $is_vip = $reputation > 10>>
// Written by <<check>> (YarnSkillCommands). Never <<set>> these by hand.
<<declare $check_result = false as bool>>
<<declare $check_roll = 0 as number>>
<<declare $check_total = 0 as number>>
<<declare $check_dc = 0 as number>>
<<declare $check_modifier = 0 as number>>
<<declare $check_degree = "" as string>>
<<declare $check_skill = "" as string>>
// Candidate lean. Three permanently-live readings of who the PC is; they are
// not mutually exclusive and never resolve. Writers <<set>> these; no code
// reads them. There is deliberately NO derived "winning candidate" variable —
// see docs/candidate-system-plan.md §5.
<<declare $self_lean_made_asset = 0 as number>>
<<declare $self_lean_journalist = 0 as number>>
<<declare $self_lean_inheritor = 0 as number>>
// Scene witnessed. New convention: $seen_<scene_id>.
<<declare $seen_sc_101 = false as bool>>
===