using UnityEngine; namespace NightclubArcadia.Interaction { /// /// What a thing in the world is called and which conversation it starts. /// /// This replaces a set of public fields edited per scene object. The scaffold it /// grew out of had the name, colour, yarn node, ranges and font sizes all set on /// each sphere by hand, which meant two objects claiming to be the same character /// could disagree, and nothing outside the scene could see what existed. /// /// Generated from Assets/Characters/characters.json — edit the JSON, not the asset. /// Hand edits are overwritten, the same contract as Skills and Candidates. /// [CreateAssetMenu(menuName = "Nightclub Arcadia/Interactable Definition", order = 30)] public sealed class InteractableDefinition : ScriptableObject { [SerializeField] string id; [SerializeField] string displayName; [SerializeField] string yarnNode; [SerializeField] float interactionRange = 3f; [Tooltip("Shown as a floating label. Off for scenery that should not announce itself.")] [SerializeField] bool showLabel = true; public string Id => id; public string DisplayName => displayName; public string YarnNode => yarnNode; public float InteractionRange => interactionRange; public bool ShowLabel => showLabel; #if UNITY_EDITOR /// Editor-only, for the generator. Not part of the runtime surface. public void EditorSet(string newId, string newDisplayName, string newYarnNode, float newRange, bool newShowLabel) { id = newId; displayName = newDisplayName; yarnNode = newYarnNode; interactionRange = newRange; showLabel = newShowLabel; } #endif } }