{
  "schemaVersion": "1.0.0",
  "adventure": {
    "id": "ashes-of-thornwatch",
    "title": "ASHES OF THORNWATCH",
    "subtitle": "A one-room demonstration adventure",
    "author": "Terminal Realms",
    "version": "0.1.0",
    "startRoom": "watchmans-gatehouse",
    "intro": [
      "Rain needles the ruined keep. Somewhere below, an old mechanism counts the thunder.",
      "You wake on cold flagstones with a taste of iron in your mouth and one question burning behind your eyes: who locked the western gate?"
    ]
  },
  "commandSet": [
    { "code": "REGISTER", "syntax": "REGISTER [USER]", "description": "Create a local game account." },
    { "code": "LOGIN", "syntax": "LOGIN [USER]", "description": "Open an existing account session." },
    { "code": "ACCOUNT", "syntax": "WHOAMI | LOGOUT", "description": "Show or close the current session." },
    { "code": "PASSWD", "syntax": "PASSWD", "description": "Change the current account password." },
    { "code": "DELETE_ACCOUNT", "syntax": "DELETE ACCOUNT", "description": "Permanently delete the account and saves." },
    { "code": "MOVE", "syntax": "N | S | E | W", "description": "Move in a cardinal direction." },
    { "code": "OPEN", "syntax": "OPEN DOOR W", "description": "Open or unlock a door." },
    { "code": "LOOK", "syntax": "L", "description": "Look around the current room." },
    { "code": "CLOSER", "syntax": "LC [TARGET]", "description": "Examine a room, item, person, or exit." },
    { "code": "INVENTORY", "syntax": "I", "description": "List carried and equipped items." },
    { "code": "TAKE", "syntax": "TAKE [ITEM]", "description": "Pick up a portable item." },
    { "code": "DROP", "syntax": "DROP [ITEM]", "description": "Leave a carried item in the room." },
    { "code": "EQUIP", "syntax": "EQUIP [ITEM]", "description": "Equip a carried item." },
    { "code": "USE", "syntax": "USE [ITEM]", "description": "Use or consume an item." },
    { "code": "TALK", "syntax": "TALK [NAME]", "description": "Speak with a present character." },
    { "code": "STATUS", "syntax": "STATUS", "description": "Show character statistics." },
    { "code": "SAVE", "syntax": "SAVE | LOAD", "description": "Write or retrieve this expedition." },
    { "code": "DATA", "syntax": "DATA", "description": "Explain the JSON adventure format." },
    { "code": "SYSTEM", "syntax": "CLEAR | RESTART", "description": "Clear output or restart the adventure." }
  ],
  "playerTemplates": [
    {
      "id": "rowan-vale",
      "name": "Rowan Vale",
      "class": "Wayfarer",
      "level": 1,
      "description": "A road-worn courier with a careful eye and a talent for surviving bad roads.",
      "hp": { "current": 8, "max": 10 },
      "stats": { "might": 2, "mind": 3, "guile": 4 },
      "inventory": ["notched-blade", "travellers-cloak", "hooded-lantern", "ashroot-tonic"],
      "equipment": {
        "mainHand": "notched-blade",
        "offHand": null,
        "body": "travellers-cloak"
      }
    }
  ],
  "items": [
    {
      "id": "iron-gate-key",
      "name": "black iron key",
      "aliases": ["key", "iron key", "black key"],
      "description": "A heavy iron key lies beside the dead brazier.",
      "closer": "Its bit is cut like the battlements of Thornwatch. Rust stains the bow, but the teeth are newly polished.",
      "portable": true,
      "slot": null
    },
    {
      "id": "notched-blade",
      "name": "notched blade",
      "aliases": ["blade", "knife", "sword"],
      "description": "A short, serviceable blade.",
      "closer": "Three deliberate notches score the spine. You do not remember making them.",
      "portable": true,
      "slot": "mainHand"
    },
    {
      "id": "travellers-cloak",
      "name": "traveller's cloak",
      "aliases": ["cloak", "traveller cloak", "coat"],
      "description": "A rain-dark travelling cloak.",
      "closer": "The hem is stiff with road salt. A hidden inner seam bears the initials R.V.",
      "portable": true,
      "slot": "body"
    },
    {
      "id": "hooded-lantern",
      "name": "hooded lantern",
      "aliases": ["lantern", "lamp"],
      "description": "A brass lantern with a sliding hood.",
      "closer": "There is enough whale oil for perhaps an hour. The wick has already been trimmed.",
      "portable": true,
      "slot": "offHand"
    },
    {
      "id": "ashroot-tonic",
      "name": "ashroot tonic",
      "aliases": ["tonic", "potion", "medicine"],
      "description": "A thumb-sized bottle of bitter tonic.",
      "closer": "The cloudy draught smells of roots and woodsmoke. The wax seal is intact.",
      "portable": true,
      "slot": null,
      "effect": { "type": "heal", "amount": 3, "consume": true }
    }
  ],
  "characters": [
    {
      "id": "gate-warden",
      "name": "the Gate Warden",
      "aliases": ["warden", "automaton", "statue"],
      "type": "npc",
      "description": "A brass-faced warden sits motionless beneath the western arch.",
      "closer": "It is no statue. Tiny cogs turn behind its cracked porcelain eyes, and one metal finger points towards the dead brazier.",
      "dialogue": [
        "Passage requires the black tooth. The dead fire keeps what the living forget.",
        "Key. Brazier. West gate. Even the newly dead should manage three facts."
      ]
    }
  ],
  "rooms": [
    {
      "id": "watchmans-gatehouse",
      "name": "Watchman's Gatehouse",
      "code": "GATE-01",
      "description": "A low stone chamber crouches beneath a web of blackened rafters. Rain whispers through an arrow slit to the east. An iron-bound door seals the western arch; the other passages have suffered the years less gracefully.",
      "closer": "Old boot marks overlap in the dust, but one fresh drag-line runs from your resting place to the dead brazier. The western door has no handle on this side—only a deep keyway beneath the lock plate.",
      "ambient": [
        "Water ticks steadily into a bronze bowl.",
        "The Gate Warden's hidden gears click once, then fall silent.",
        "Cold air breathes through the western keyway."
      ],
      "items": ["iron-gate-key"],
      "characters": ["gate-warden"],
      "exits": {
        "north": {
          "label": "collapsed stair",
          "to": null,
          "status": "blocked",
          "description": "A stair once climbed into the keep. Masonry now fills it to the ceiling.",
          "blockedText": "The northern stair is buried beneath several tonnes of wet stone."
        },
        "south": {
          "label": "flooded passage",
          "to": null,
          "status": "blocked",
          "description": "Black water fills the descending passage almost to its arch.",
          "blockedText": "The southern passage vanishes under deep, lightless water."
        },
        "east": {
          "label": "arrow slit",
          "to": null,
          "status": "blocked",
          "description": "A narrow arrow slit overlooks the rain and the ravine far below.",
          "blockedText": "The eastern opening is far too narrow, and the drop beyond is fatal."
        },
        "west": {
          "label": "iron-bound door",
          "to": null,
          "status": "locked",
          "key": "iron-gate-key",
          "description": "Black oak planks sit inside a cage of riveted iron. The lock is ancient and recently oiled.",
          "lockedText": "The western door refuses you. Its lock wants a broad iron key.",
          "edgeText": "You step across Thornwatch's threshold. Rain takes you, the ravine answers with thunder, and the one-room demonstration ends—ready for the next room JSON to be added."
        }
      }
    }
  ]
}
