{
  "version": "1.1",
  "requiredCapabilities": [
    "smart-prose-v1",
    "story-rules-v1",
    "record-replay-v1",
    "object-contents-v1",
    "creator-features-v1"
  ],
  "name": "The Jammed Observatory",
  "playerConfig": {
    "scoreEnabled": true,
    "healthEnabled": false,
    "moneyEnabled": false
  },
  "author": "TAGMaker",
  "description": "A three-room first game. Read a clue, unlock a door and repair a beacon with a tool you keep. HINT offers three levels of help. Maximum score: 100.",
  "startRoom": "atrium",
  "created": "2026-10-23T00:00:00.000Z",
  "modified": "2026-10-23T00:00:00.000Z",
  "gameBrief": {
    "version": 1,
    "playerRole": "A visitor helping the missing observatory keeper.",
    "goal": "Restore the beacon so the rescue boat can reach the landing.",
    "success": "Use the crank to repair the signal, then return to the atrium. Award the repair points once."
  },
  "gameOutliner": {
    "title": "The Island of Failed Prophets",
    "hook": "You are invited to a remote island gathering of disgraced doomsday prophets, but when one of them predicts a final catastrophe before sunrise, the island turns into a deadly puzzle of lies, traps, rituals, and hidden machinery.",
    "coreIdea": "The player is trapped on Saint Orison Island with failed prophets, cult leaders, fake mystics, disgraced scientists, wealthy believers, and dangerous followers. A new prophecy claims that before sunrise the island will burn, the sea will rise, and only the true believer will leave alive. The player investigates, survives escalating danger, builds NPC relationships, uncovers the truth, stops the final ritual, and escapes before dawn.",
    "playerRole": "You are a skeptical investigator and writer known for exposing cults, false prophets, fake miracles, and end-times frauds. You begin confident and rational, but the island is designed to make you doubt what is staged and what might be real.",
    "mainObjective": "Survive the island, expose the false prophecy, stop the final ritual, rescue key allies, and escape before sunrise.",
    "secondaryObjectives": "Repair the radio tower and call for help. Rescue the sidekick if captured. Collect evidence proving the prophecy is staged. Discover who invited you to the island. Learn the mentor's hidden connection to the island. Expose the true villain. Escape with enough proof to destroy the cult network. Find the secret ending by proving the prophecy may be partly real.",
    "toneGenre": "Genre: mystery, survival horror, psychological thriller, cult investigation.\nTone: dark, tense, strange, suspicious, atmospheric.\nPerspective: second person, present tense.\nStyle: exploration-heavy text adventure with story-driven puzzles, NPC relationships, survival mechanics, clue gathering, danger events, and combat.",
    "settingOverview": "Remote Saint Orison Island: dock, guest lodge, dining hall, chapel, Prophets' Hall, observatory, gardens, radio tower, sea caves, maintenance tunnels, underground bunker, and burning shrine. The island should feel like a classic text adventure map with connected rooms, locked areas, hidden exits, puzzles, danger zones, and meaningful objects.",
    "storyTheme": "Main theme: What happens when people would rather believe a terrifying lie than face an ordinary truth?\n\nSecondary themes: fear as a weapon, cult manipulation, shame and redemption, skepticism versus faith, truth versus performance, the need to be believed, and the danger of charismatic leaders.",
    "mainConflict": "The player believes the prophecy is fake. The island is designed to make the player doubt that belief. The enemies want the player silenced, converted, discredited, or killed. The mystery is whether the prophecy is a fraud, staged ritual, murder plot, or something partly real.",
    "coreMechanics": "Health, fear meter, trust system, evidence score, time until dawn, and combat.\n\nFear may distort descriptions or choices. Trust unlocks help and secrets. Evidence improves endings. Time phases move from arrival to sunrise.",
    "mainNpcs": "Sidekick: Mara Voss, a documentary filmmaker and secret investigator.\nMentor: Dr. Elias Crowe, a former psychologist and cult-deprogramming expert.\nAllies: Nina Vale, Brother Amos, Tessa Quill.\nNeutral: Boat Captain, Archivist, Silent Gardener, Rich Patron.\nEnemies: Mother Sable, Jonah Flint, White-Robed Disciples, Masked Bell-Ringer, the True Architect.",
    "objectCategories": "Key objects: rusted key, brass chapel key, observatory crank, bunker access card.\nSurvival: bandages, clean water, lantern oil, coffee tin, matches, raincoat, rope.\nClue objects: torn prophecy page, burned journal, wet invitation, old photograph, audio tape, star chart, guest registry, payment ledger.\nWeapons: walking stick, kitchen knife, broken bottle, flare gun, rusted spear.\nPuzzle, trade, and dangerous objects as needed.",
    "mainRooms": "Dock: arrival — no easy way back.\nGuest Lodge: safe hub and early clues.\nDining Hall: prophecy announced, first danger.\nProphets' Hall: history of failed predictions.\nChapel: ritual room and bell puzzle.\nObservatory: false blood moon.\nGarden Maze: navigation/fear puzzle.\nRadio Tower: call for help.\nSea Caves: tide danger.\nMaintenance Tunnels: staged miracles revealed.\nUnderground Bunker: truth of the prophecy.\nBurning Shrine: final confrontation.",
    "puzzleDesign": "Example — The Chapel Bell Sequence:\nLocation: Chapel of the Last Hour.\nRequired objects: silver bell, torn hymn page, wax seal.\nClues: hymn page gives numbers; floor symbols show order.\nSolution: ring the bell according to the hymn pattern while standing on the correct symbol.\nFailure: chapel locks, fear rises, Bell-Ringer may appear.\nReward: hidden crypt stairs open.",
    "eventDesign": "Example events: The First Bell, The Poisoned Toast, The False Moon, Mara's Capture, The Rising Tide, The Shrine Fire.\n\nEach event should have a trigger, player choices, consequences, and story effect.",
    "combatDesign": "Example — White-Robed Disciple:\nLocation: Radio Tower or tunnels.\nWeapon: club or knife. Danger: medium.\nOptions: fight, flee, distract, use flare, call Mara for help, hide in maintenance closet.\nVictory reward: patrol key, robe disguise, or restricted path access.\nFailure penalty: health loss, capture, item loss, or fear increase.",
    "dialogueDesign": "Dialogue should reveal story, build relationships, unlock clues, and create consequences.\n\nTopics may include island, prophecy, specific NPCs, accusations, showing evidence, offering items, requesting help, threatening, comforting, lying, or telling the truth.\n\nExample: showing Tessa the red glass disc unlocks her explanation of the false blood moon effect.",
    "scoringSystem": "+5 useful object found\n+10 minor puzzle solved\n+20 major puzzle solved\n+25 rescue an ally\n+30 expose a fake omen\n+50 stop the final ritual\n+50 escape with evidence\n\nNegative score for: harming innocents, abandoning sidekick, destroying evidence, or killing when avoidable.",
    "endings": "Best: expose prophecy, save Mara, stop ritual, escape with evidence.\nGood: escape and stop ritual but lack enough proof.\nDark: escape alone while the island burns.\nCult: fail the final mind puzzle and become the new prophet.\nDeath: die from fire, tide, combat, poison, or final trap.\nSecret: prove most was fake but discover one part was real.",
    "builderChecklist": "Before building, answer:\n• What is the main objective?\n• What is the locked setting?\n• Who is the sidekick?\n• Who is the mentor?\n• Who are allies, neutrals, enemies?\n• What objects are essential, optional, dangerous, or misleading?\n• What are the rooms, puzzles, traps, combat encounters, mechanics, and endings?\n• What is the first scene the player experiences?\n• What is the emotional core of the story?",
    "finalNotes": "What makes this idea exciting as a text adventure: the island setting creates a natural locked environment, the NPC network rewards exploration and relationship-building, and the prophecy mystery gives the player a reason to investigate every room.\n\nBuild first: the core island loop — dock, lodge, dining hall, chapel — with working NPCs and the evidence system."
  },
  "story": {
    "version": 1,
    "states": [
      {
        "id": "signal_restored",
        "name": "Signal restored",
        "description": "The crank has repaired the signal mechanism.",
        "type": "boolean",
        "initial": false
      }
    ],
    "rules": [],
    "features": {
      "version": 1,
      "commandContext": true,
      "recipes": [
        {
          "id": "repair_signal",
          "name": "Repair the signal mechanism",
          "enabled": true,
          "verbs": [
            "use"
          ],
          "unordered": false,
          "inputs": [
            {
              "objectId": "brass_crank",
              "disposition": "retain"
            }
          ],
          "tools": [],
          "target": {
            "kind": "object",
            "id": "signal_mechanism"
          },
          "roomId": "observatory",
          "conditions": [],
          "match": "all",
          "actions": [
            {
              "kind": "state",
              "target": "signal_restored",
              "value": true
            },
            {
              "kind": "score",
              "value": 100
            }
          ],
          "once": true,
          "success": "The crank catches with a satisfying clunk. Gears turn, the beacon sweeps over the water, and a boat answers with three flashes. You keep the crank. +100 points. Return west to the atrium.",
          "failure": "Carry the brass crank into the observatory, then use it with the signal mechanism.",
          "repeat": "The beacon is already turning smoothly. There is no second repair reward."
        }
      ],
      "endings": [
        {
          "id": "signal_sent",
          "name": "Signal sent",
          "enabled": true,
          "automatic": true,
          "priority": 1,
          "conditions": [
            {
              "kind": "state",
              "target": "signal_restored",
              "operator": "==",
              "value": true
            },
            {
              "kind": "room",
              "target": "atrium",
              "operator": "==",
              "value": true
            }
          ],
          "match": "all",
          "actions": [],
          "text": "You reach the atrium as the rescue boat nudges the landing. Above you, the restored beacon draws a bright circle through the mist. The keeper is safe, and the observatory shines again. You win! Final score: 100."
        }
      ],
      "hints": [
        {
          "id": "atrium_help",
          "name": "atrium help",
          "enabled": true,
          "scope": {
            "kind": "room",
            "target": "atrium"
          },
          "priority": 1,
          "conditions": [],
          "match": "all",
          "completedConditions": [
            {
              "kind": "state",
              "target": "signal_restored",
              "operator": "==",
              "value": true
            }
          ],
          "completedMatch": "all",
          "completedText": "The signal is working. Return to the atrium, west of the observatory, to finish.",
          "progressStateId": "signal_restored",
          "levels": [
            {
              "level": "gentle",
              "text": "A locked route is easier to solve after exploring the open one.",
              "conditions": [],
              "match": "all"
            },
            {
              "level": "strong",
              "text": "The workshop to the north keeps maintenance supplies.",
              "conditions": [],
              "match": "all"
            },
            {
              "level": "solution",
              "text": "Go north. Read the maintenance note and take the brass key and crank. Return south, UNLOCK OBSERVATORY DOOR WITH BRASS KEY, OPEN OBSERVATORY DOOR, then go east.",
              "conditions": [],
              "match": "all"
            }
          ]
        },
        {
          "id": "workshop_help",
          "name": "workshop help",
          "enabled": true,
          "scope": {
            "kind": "room",
            "target": "workshop"
          },
          "priority": 1,
          "conditions": [],
          "match": "all",
          "completedConditions": [
            {
              "kind": "state",
              "target": "signal_restored",
              "operator": "==",
              "value": true
            }
          ],
          "completedMatch": "all",
          "completedText": "The signal is working. Return to the atrium, west of the observatory, to finish.",
          "progressStateId": "signal_restored",
          "levels": [
            {
              "level": "gentle",
              "text": "The workbench has both information and useful equipment.",
              "conditions": [],
              "match": "all"
            },
            {
              "level": "strong",
              "text": "Read the maintenance note, then take the key and crank.",
              "conditions": [],
              "match": "all"
            },
            {
              "level": "solution",
              "text": "READ MAINTENANCE NOTE. TAKE BRASS KEY. TAKE BRASS CRANK. Go south, unlock and open the observatory door, then go east.",
              "conditions": [],
              "match": "all"
            }
          ]
        },
        {
          "id": "observatory_help",
          "name": "observatory help",
          "enabled": true,
          "scope": {
            "kind": "room",
            "target": "observatory"
          },
          "priority": 1,
          "conditions": [],
          "match": "all",
          "completedConditions": [
            {
              "kind": "state",
              "target": "signal_restored",
              "operator": "==",
              "value": true
            }
          ],
          "completedMatch": "all",
          "completedText": "The signal is working. Return to the atrium, west of the observatory, to finish.",
          "progressStateId": "signal_restored",
          "levels": [
            {
              "level": "gentle",
              "text": "The signal needs a turning handle, rather than a key.",
              "conditions": [],
              "match": "all"
            },
            {
              "level": "strong",
              "text": "Bring the brass crank from the workshop. You must be carrying it.",
              "conditions": [],
              "match": "all"
            },
            {
              "level": "solution",
              "text": "USE BRASS CRANK WITH SIGNAL MECHANISM, then go west to the atrium.",
              "conditions": [],
              "match": "all"
            }
          ]
        }
      ]
    }
  },
  "puzzleBoard": {
    "version": 1,
    "nodes": [
      {
        "id": "restore_beacon",
        "kind": "goal",
        "title": "Bring the rescue boat to the landing",
        "notes": "Restore the signal, then return to the atrium. This goal describes the design; the ending below implements success."
      },
      {
        "id": "locked_door",
        "kind": "obstacle",
        "title": "The east observatory door is locked",
        "notes": "Native locked-container contents require the carried brass key. Unlocking alone does not open the door; the east exit checks the real open state.",
        "binding": {
          "kind": "object",
          "id": "observatory_door"
        }
      },
      {
        "id": "maintenance_clue",
        "kind": "clue",
        "title": "The maintenance note explains both steps",
        "notes": "READ prints the authored instructions. The clue reveals the key and retained crank; reading it is helpful information, not a required discovery flag.",
        "binding": {
          "kind": "object-event",
          "ownerId": "maintenance_note",
          "id": "read_note"
        }
      },
      {
        "id": "door_key",
        "kind": "item",
        "title": "Carry the brass key to unlock the door",
        "notes": "The key starts in the workshop. A dropped key cannot unlock the door.",
        "binding": {
          "kind": "object",
          "id": "brass_key"
        }
      },
      {
        "id": "turning_crank",
        "kind": "item",
        "title": "Carry the brass crank to the signal",
        "notes": "The repair retains this tool; it is not consumed.",
        "binding": {
          "kind": "object",
          "id": "brass_crank"
        }
      },
      {
        "id": "stalled_signal",
        "kind": "obstacle",
        "title": "The beacon mechanism is stalled",
        "notes": "Reach the observatory with the crank before using it with this real target.",
        "binding": {
          "kind": "object",
          "id": "signal_mechanism"
        }
      },
      {
        "id": "repair_beacon",
        "kind": "interaction",
        "title": "Repair the signal mechanism once",
        "notes": "Native recipe requires the carried crank and observatory target/room. Success sets signal_restored and awards 100 points; repeated repair has no second reward.",
        "binding": {
          "kind": "recipe",
          "id": "repair_signal"
        }
      },
      {
        "id": "restoration_fact",
        "kind": "fact",
        "title": "The signal has been restored",
        "notes": "This managed boolean begins false. The recipe sets it true; changing descriptions and the ending read it.",
        "binding": {
          "kind": "story-state",
          "id": "signal_restored"
        }
      },
      {
        "id": "rescue_arrives",
        "kind": "consequence",
        "title": "Return west to the atrium and reach rescue",
        "notes": "The automatic Signal sent ending requires both signal_restored and the atrium. Repairing the beacon in the observatory does not end the game immediately.",
        "binding": {
          "kind": "ending",
          "id": "signal_sent"
        }
      },
      {
        "id": "winning_route",
        "kind": "test",
        "title": "Replay the full 100-point rescue route",
        "notes": "Saved Test Lab commands contain room, inventory, door, state, score and ending assertions. Opening this route does not execute it or establish a saved PASS.",
        "binding": {
          "kind": "test-route",
          "id": "first_game_signal_route"
        }
      }
    ],
    "links": [
      {
        "id": "goal_requires_rescue",
        "from": "restore_beacon",
        "to": "rescue_arrives",
        "relation": "requires",
        "notes": "Success includes the return journey."
      },
      {
        "id": "door_blocks_signal",
        "from": "locked_door",
        "to": "stalled_signal",
        "relation": "blocks",
        "notes": "The closed-door state gates the east exit."
      },
      {
        "id": "door_requires_key",
        "from": "locked_door",
        "to": "door_key",
        "relation": "requires",
        "notes": "The matching key must be carried for unlocking."
      },
      {
        "id": "note_reveals_key",
        "from": "maintenance_clue",
        "to": "door_key",
        "relation": "reveals",
        "notes": "The note explains the key's purpose."
      },
      {
        "id": "note_reveals_crank",
        "from": "maintenance_clue",
        "to": "turning_crank",
        "relation": "reveals",
        "notes": "The note gives the repair command."
      },
      {
        "id": "repair_requires_crank",
        "from": "repair_beacon",
        "to": "turning_crank",
        "relation": "requires",
        "notes": "The tool is retained after success."
      },
      {
        "id": "repair_requires_target",
        "from": "repair_beacon",
        "to": "stalled_signal",
        "relation": "requires",
        "notes": "The actual recipe binds the target and observatory room."
      },
      {
        "id": "repair_causes_fact",
        "from": "repair_beacon",
        "to": "restoration_fact",
        "relation": "causes",
        "notes": "A native state action marks restoration."
      },
      {
        "id": "fact_causes_rescue",
        "from": "restoration_fact",
        "to": "rescue_arrives",
        "relation": "causes",
        "notes": "The ending additionally requires returning to the atrium."
      },
      {
        "id": "route_tests_goal",
        "from": "winning_route",
        "to": "restore_beacon",
        "relation": "tests",
        "notes": "Assertions check the intended completion."
      },
      {
        "id": "route_tests_door",
        "from": "winning_route",
        "to": "locked_door",
        "relation": "tests",
        "notes": "Checks prove unlocking, opening and entering on this route."
      },
      {
        "id": "route_tests_repair",
        "from": "winning_route",
        "to": "repair_beacon",
        "relation": "tests",
        "notes": "Checks verify retained crank, restored state and 100 points."
      },
      {
        "id": "route_tests_ending",
        "from": "winning_route",
        "to": "rescue_arrives",
        "relation": "tests",
        "notes": "The final check requires the named ending and completed game."
      }
    ]
  },
  "files": [
    {
      "path": "scripts/game_start.taml",
      "content": "script on_game_start\n  set score = 0\n  goto: atrium\nend"
    },
    {
      "path": "scripts/on_turn_end.taml",
      "content": "script on_turn_end\nend"
    },
    {
      "path": "rooms/atrium.taml",
      "content": "room atrium\n  name: \"Observatory Atrium\"\n  narrative: \"The keeper has gone missing in the fog. Restore the observatory beacon so the rescue boat can find the landing, then meet it back here. Type LOOK, EXAMINE an object, a direction such as NORTH, or HINT for help.\"\n  description: \"Moonlight glints on wet stone. The workshop is north; an observatory door guards the east passage. The rescue landing is just beyond the windows.\"\n  smart_description: \"{\\\"version\\\":1,\\\"parts\\\":[{\\\"type\\\":\\\"text\\\",\\\"text\\\":\\\"Moonlight glints on wet stone. The workshop is north. \\\"},{\\\"type\\\":\\\"conditional\\\",\\\"id\\\":\\\"atrium_door_open\\\",\\\"when\\\":{\\\"kind\\\":\\\"flag_equals\\\",\\\"flag\\\":\\\"observatory_door_open\\\",\\\"value\\\":true},\\\"then\\\":\\\"The observatory door stands open to the east.\\\",\\\"otherwise\\\":\\\"The closed observatory door blocks the east passage.\\\"},{\\\"type\\\":\\\"conditional\\\",\\\"id\\\":\\\"atrium_door_locked\\\",\\\"when\\\":{\\\"kind\\\":\\\"flag_equals\\\",\\\"flag\\\":\\\"observatory_door_locked\\\",\\\"value\\\":true},\\\"then\\\":\\\" It is locked.\\\",\\\"otherwise\\\":\\\"\\\"},{\\\"type\\\":\\\"text\\\",\\\"text\\\":\\\" The rescue landing is just beyond the windows.\\\"}]}\"\n  dark: false\n  exit north: workshop\n  exit east: observatory when: observatory_door_open\n  blocked east: \"The observatory door is closed. Find its key, unlock it, and open it first.\"\nend"
    },
    {
      "path": "rooms/workshop.taml",
      "content": "room workshop\n  name: \"Keeper's Workshop\"\n  description: \"Warm oil and cedar scent the tiny workshop. A maintenance note lies on the workbench. The atrium is south.\"\n  smart_description: \"{\\\"version\\\":1,\\\"parts\\\":[{\\\"type\\\":\\\"text\\\",\\\"text\\\":\\\"Warm oil and cedar scent the tiny workshop. A maintenance note lies on the workbench.\\\"},{\\\"type\\\":\\\"conditional\\\",\\\"id\\\":\\\"workshop_key\\\",\\\"when\\\":{\\\"kind\\\":\\\"object_at\\\",\\\"objectId\\\":\\\"brass_key\\\",\\\"roomId\\\":\\\"workshop\\\"},\\\"then\\\":\\\" A brass key is here.\\\",\\\"otherwise\\\":\\\"\\\"},{\\\"type\\\":\\\"conditional\\\",\\\"id\\\":\\\"workshop_crank\\\",\\\"when\\\":{\\\"kind\\\":\\\"object_at\\\",\\\"objectId\\\":\\\"brass_crank\\\",\\\"roomId\\\":\\\"workshop\\\"},\\\"then\\\":\\\" A brass crank is here.\\\",\\\"otherwise\\\":\\\"\\\"},{\\\"type\\\":\\\"text\\\",\\\"text\\\":\\\" The atrium is south.\\\"}]}\"\n  dark: false\n  exit south: atrium\nend"
    },
    {
      "path": "rooms/observatory.taml",
      "content": "room observatory\n  name: \"Glass Observatory\"\n  description: \"The stalled signal mechanism waits beneath a glass dome. The atrium is west.\"\n  smart_description: \"{\\\"version\\\":1,\\\"parts\\\":[{\\\"type\\\":\\\"conditional\\\",\\\"id\\\":\\\"signal_condition\\\",\\\"when\\\":{\\\"kind\\\":\\\"flag_equals\\\",\\\"flag\\\":\\\"signal_restored\\\",\\\"value\\\":true},\\\"then\\\":\\\"The signal mechanism turns steadily. A bright sweep of light circles the bay; the rescue boat is approaching. The atrium is west.\\\",\\\"otherwise\\\":\\\"A stalled brass mechanism holds the beacon motionless. Its square socket is missing a turning handle. Mist swirls beyond the glass dome. The atrium is west.\\\"}]}\"\n  dark: false\n  exit west: atrium\nend"
    },
    {
      "path": "objects/observatory_door.taml",
      "content": "object observatory_door\n  name: \"observatory door\"\n  description: \"A heavy door guards the east passage. A brass keyhole sits beneath a handle. Unlock it with the matching key, then open it.\"\n  contents_v1: \"{\\\"version\\\":1,\\\"kind\\\":\\\"container\\\",\\\"locked\\\":true,\\\"keyId\\\":\\\"brass_key\\\"}\"\n  location: atrium\n  aliases: [\"door\"]\n  droppable: false\n  container: true\n  weight: 0.1\nend"
    },
    {
      "path": "objects/brass_key.taml",
      "content": "object brass_key\n  name: \"brass key\"\n  description: \"A small brass key tagged OBSERVATORY.\"\n  location: workshop\n  aliases: [\"key\"]\n  takeable: true\n  weight: 0.1\nend"
    },
    {
      "path": "objects/brass_crank.taml",
      "content": "object brass_crank\n  name: \"brass crank\"\n  description: \"A sturdy turning handle with a square spindle. It looks like a useful repair tool.\"\n  location: workshop\n  aliases: [\"crank\", \"handle\"]\n  takeable: true\n  use_give: true\n  weight: 0.1\nend"
    },
    {
      "path": "objects/maintenance_note.taml",
      "content": "object maintenance_note\n  name: \"maintenance note\"\n  description: \"MAINTENANCE: The brass key unlocks the observatory door. Open it before going east. Carry the brass crank and USE BRASS CRANK WITH SIGNAL MECHANISM. Once the beacon turns, return west to the atrium to meet the rescue boat.\"\n  location: workshop\n  aliases: [\"note\", \"instructions\"]\n  droppable: false\n  weight: 0.1\n  on read:\n    print \"MAINTENANCE: The brass key unlocks the observatory door. Open it before going east. Carry the brass crank and USE BRASS CRANK WITH SIGNAL MECHANISM. Once the beacon turns, return west to the atrium to meet the rescue boat.\"\n  end\nend"
    },
    {
      "path": "objects/signal_mechanism.taml",
      "content": "object signal_mechanism\n  name: \"signal mechanism\"\n  description: \"The beacon mechanism has a square socket for a turning crank.\"\n  smart_description: \"{\\\"version\\\":1,\\\"parts\\\":[{\\\"type\\\":\\\"conditional\\\",\\\"id\\\":\\\"signal_condition\\\",\\\"when\\\":{\\\"kind\\\":\\\"flag_equals\\\",\\\"flag\\\":\\\"signal_restored\\\",\\\"value\\\":true},\\\"then\\\":\\\"The signal mechanism turns steadily. A bright sweep of light circles the bay; the rescue boat is approaching. The atrium is west.\\\",\\\"otherwise\\\":\\\"A stalled brass mechanism holds the beacon motionless. Its square socket is missing a turning handle. Mist swirls beyond the glass dome. The atrium is west.\\\"}]}\"\n  location: observatory\n  aliases: [\"mechanism\", \"signal\", \"beacon\"]\n  droppable: false\n  weight: 0.1\nend"
    }
  ],
  "mapRooms": [
    {
      "smartProse": {
        "description": {
          "version": 1,
          "parts": [
            {
              "type": "text",
              "text": "Moonlight glints on wet stone. The workshop is north. "
            },
            {
              "type": "conditional",
              "id": "atrium_door_open",
              "when": {
                "kind": "flag_equals",
                "flag": "observatory_door_open",
                "value": true
              },
              "then": "The observatory door stands open to the east.",
              "otherwise": "The closed observatory door blocks the east passage."
            },
            {
              "type": "conditional",
              "id": "atrium_door_locked",
              "when": {
                "kind": "flag_equals",
                "flag": "observatory_door_locked",
                "value": true
              },
              "then": " It is locked.",
              "otherwise": ""
            },
            {
              "type": "text",
              "text": " The rescue landing is just beyond the windows."
            }
          ]
        }
      },
      "id": "atrium",
      "name": "Observatory Atrium",
      "narrative": "The keeper has gone missing in the fog. Restore the observatory beacon so the rescue boat can find the landing, then meet it back here. Type LOOK, EXAMINE an object, a direction such as NORTH, or HINT for help.",
      "description": "Moonlight glints on wet stone. The workshop is north; an observatory door guards the east passage. The rescue landing is just beyond the windows.",
      "reentryEnabled": false,
      "reentryDesc": "",
      "hint": "",
      "dark": false,
      "roomType": "regular",
      "x": 100,
      "y": 220,
      "width": 160,
      "height": 64,
      "color": "#000000"
    },
    {
      "smartProse": {
        "description": {
          "version": 1,
          "parts": [
            {
              "type": "text",
              "text": "Warm oil and cedar scent the tiny workshop. A maintenance note lies on the workbench."
            },
            {
              "type": "conditional",
              "id": "workshop_key",
              "when": {
                "kind": "object_at",
                "objectId": "brass_key",
                "roomId": "workshop"
              },
              "then": " A brass key is here.",
              "otherwise": ""
            },
            {
              "type": "conditional",
              "id": "workshop_crank",
              "when": {
                "kind": "object_at",
                "objectId": "brass_crank",
                "roomId": "workshop"
              },
              "then": " A brass crank is here.",
              "otherwise": ""
            },
            {
              "type": "text",
              "text": " The atrium is south."
            }
          ]
        }
      },
      "id": "workshop",
      "name": "Keeper's Workshop",
      "description": "Warm oil and cedar scent the tiny workshop. A maintenance note lies on the workbench. The atrium is south.",
      "reentryEnabled": false,
      "reentryDesc": "",
      "hint": "",
      "dark": false,
      "roomType": "regular",
      "x": 100,
      "y": 60,
      "width": 160,
      "height": 64,
      "color": "#000000"
    },
    {
      "smartProse": {
        "description": {
          "version": 1,
          "parts": [
            {
              "type": "conditional",
              "id": "signal_condition",
              "when": {
                "kind": "flag_equals",
                "flag": "signal_restored",
                "value": true
              },
              "then": "The signal mechanism turns steadily. A bright sweep of light circles the bay; the rescue boat is approaching. The atrium is west.",
              "otherwise": "A stalled brass mechanism holds the beacon motionless. Its square socket is missing a turning handle. Mist swirls beyond the glass dome. The atrium is west."
            }
          ]
        }
      },
      "id": "observatory",
      "name": "Glass Observatory",
      "description": "The stalled signal mechanism waits beneath a glass dome. The atrium is west.",
      "reentryEnabled": false,
      "reentryDesc": "",
      "hint": "",
      "dark": false,
      "roomType": "regular",
      "x": 340,
      "y": 220,
      "width": 160,
      "height": 64,
      "color": "#000000"
    }
  ],
  "mapExits": [
    {
      "id": "atrium_workshop",
      "fromRoom": "atrium",
      "toRoom": "workshop",
      "direction": "north",
      "locked": false
    },
    {
      "id": "workshop_atrium",
      "fromRoom": "workshop",
      "toRoom": "atrium",
      "direction": "south",
      "locked": false
    },
    {
      "id": "atrium_observatory",
      "fromRoom": "atrium",
      "toRoom": "observatory",
      "direction": "east",
      "when": "observatory_door_open",
      "locked": false
    },
    {
      "id": "observatory_atrium",
      "fromRoom": "observatory",
      "toRoom": "atrium",
      "direction": "west",
      "locked": false
    }
  ],
  "objects": [
    {
      "id": "observatory_door",
      "name": "observatory door",
      "description": "A heavy door guards the east passage. A brass keyhole sits beneath a handle. Unlock it with the matching key, then open it.",
      "article": "",
      "location": "atrium",
      "aliases": [
        "door"
      ],
      "visible": true,
      "takeable": false,
      "droppable": false,
      "useGive": false,
      "container": true,
      "switchable": false,
      "edible": false,
      "drinkable": false,
      "wearable": false,
      "weapon": false,
      "weight": 0.1,
      "locked": false,
      "lockKey": "",
      "events": [],
      "contents": {
        "version": 1,
        "kind": "container",
        "locked": true,
        "keyId": "brass_key"
      }
    },
    {
      "id": "brass_key",
      "name": "brass key",
      "description": "A small brass key tagged OBSERVATORY.",
      "article": "",
      "location": "workshop",
      "aliases": [
        "key"
      ],
      "visible": true,
      "takeable": true,
      "droppable": true,
      "useGive": false,
      "container": false,
      "switchable": false,
      "edible": false,
      "drinkable": false,
      "wearable": false,
      "weapon": false,
      "weight": 0.1,
      "locked": false,
      "lockKey": "",
      "events": []
    },
    {
      "id": "brass_crank",
      "name": "brass crank",
      "description": "A sturdy turning handle with a square spindle. It looks like a useful repair tool.",
      "article": "",
      "location": "workshop",
      "aliases": [
        "crank",
        "handle"
      ],
      "visible": true,
      "takeable": true,
      "droppable": true,
      "useGive": true,
      "container": false,
      "switchable": false,
      "edible": false,
      "drinkable": false,
      "wearable": false,
      "weapon": false,
      "weight": 0.1,
      "locked": false,
      "lockKey": "",
      "events": []
    },
    {
      "id": "maintenance_note",
      "name": "maintenance note",
      "description": "MAINTENANCE: The brass key unlocks the observatory door. Open it before going east. Carry the brass crank and USE BRASS CRANK WITH SIGNAL MECHANISM. Once the beacon turns, return west to the atrium to meet the rescue boat.",
      "article": "",
      "location": "workshop",
      "aliases": [
        "note",
        "instructions"
      ],
      "visible": true,
      "takeable": false,
      "droppable": false,
      "useGive": false,
      "container": false,
      "switchable": false,
      "edible": false,
      "drinkable": false,
      "wearable": false,
      "weapon": false,
      "weight": 0.1,
      "locked": false,
      "lockKey": "",
      "events": [
        {
          "id": "read_note",
          "event": "read",
          "withTarget": "",
          "body": "print \"MAINTENANCE: The brass key unlocks the observatory door. Open it before going east. Carry the brass crank and USE BRASS CRANK WITH SIGNAL MECHANISM. Once the beacon turns, return west to the atrium to meet the rescue boat.\""
        }
      ]
    },
    {
      "id": "signal_mechanism",
      "name": "signal mechanism",
      "description": "The beacon mechanism has a square socket for a turning crank.",
      "article": "",
      "location": "observatory",
      "aliases": [
        "mechanism",
        "signal",
        "beacon"
      ],
      "visible": true,
      "takeable": false,
      "droppable": false,
      "useGive": false,
      "container": false,
      "switchable": false,
      "edible": false,
      "drinkable": false,
      "wearable": false,
      "weapon": false,
      "weight": 0.1,
      "locked": false,
      "lockKey": "",
      "events": [],
      "smartProse": {
        "description": {
          "version": 1,
          "parts": [
            {
              "type": "conditional",
              "id": "signal_condition",
              "when": {
                "kind": "flag_equals",
                "flag": "signal_restored",
                "value": true
              },
              "then": "The signal mechanism turns steadily. A bright sweep of light circles the bay; the rescue boat is approaching. The atrium is west.",
              "otherwise": "A stalled brass mechanism holds the beacon motionless. Its square socket is missing a turning handle. Mist swirls beyond the glass dome. The atrium is west."
            }
          ]
        }
      }
    }
  ],
  "npcs": [],
  "activeMechanics": [],
  "verbAliases": [],
  "scripts": [
    {
      "id": "on_game_start",
      "name": "On Game Start",
      "description": "Runs automatically when the game starts.",
      "body": "set score = 0\n  goto: atrium",
      "kind": "global"
    },
    {
      "id": "on_turn_end",
      "name": "on_turn_end",
      "description": "Turn end",
      "body": "",
      "kind": "global"
    }
  ],
  "testRoutes": [
    {
      "version": 1,
      "id": "first_game_signal_route",
      "name": "Restore the signal and reach rescue (100 points)",
      "build": "route-replay-v2",
      "sourceHash": "42d27d3b4279f348",
      "start": "restart",
      "randomness": "deterministic-runtime-v1",
      "steps": [
        {
          "input": "north",
          "checks": [
            {
              "kind": "room",
              "target": "",
              "expected": "workshop"
            },
            {
              "kind": "state",
              "target": "signal_restored",
              "expected": false
            }
          ]
        },
        {
          "input": "read maintenance note",
          "checks": [
            {
              "kind": "room",
              "target": "",
              "expected": "workshop"
            },
            {
              "kind": "score",
              "target": "",
              "expected": 0
            }
          ]
        },
        {
          "input": "take brass key",
          "checks": [
            {
              "kind": "inventory",
              "target": "brass_key",
              "expected": true
            }
          ]
        },
        {
          "input": "take brass crank",
          "checks": [
            {
              "kind": "inventory",
              "target": "brass_crank",
              "expected": true
            }
          ]
        },
        {
          "input": "south",
          "checks": [
            {
              "kind": "room",
              "target": "",
              "expected": "atrium"
            },
            {
              "kind": "inventory",
              "target": "brass_key",
              "expected": true
            },
            {
              "kind": "inventory",
              "target": "brass_crank",
              "expected": true
            }
          ]
        },
        {
          "input": "unlock observatory door with brass key",
          "checks": [
            {
              "kind": "locked",
              "target": "observatory_door",
              "expected": false
            },
            {
              "kind": "open",
              "target": "observatory_door",
              "expected": false
            }
          ]
        },
        {
          "input": "open observatory door",
          "checks": [
            {
              "kind": "open",
              "target": "observatory_door",
              "expected": true
            }
          ]
        },
        {
          "input": "east",
          "checks": [
            {
              "kind": "room",
              "target": "",
              "expected": "observatory"
            },
            {
              "kind": "state",
              "target": "signal_restored",
              "expected": false
            },
            {
              "kind": "score",
              "target": "",
              "expected": 0
            }
          ]
        },
        {
          "input": "use brass crank with signal mechanism",
          "checks": [
            {
              "kind": "room",
              "target": "",
              "expected": "observatory"
            },
            {
              "kind": "inventory",
              "target": "brass_crank",
              "expected": true
            },
            {
              "kind": "state",
              "target": "signal_restored",
              "expected": true
            },
            {
              "kind": "score",
              "target": "",
              "expected": 100
            },
            {
              "kind": "ending",
              "target": "",
              "expected": false
            }
          ]
        },
        {
          "input": "west",
          "checks": [
            {
              "kind": "room",
              "target": "",
              "expected": "atrium"
            },
            {
              "kind": "inventory",
              "target": "brass_crank",
              "expected": true
            },
            {
              "kind": "state",
              "target": "signal_restored",
              "expected": true
            },
            {
              "kind": "score",
              "target": "",
              "expected": 100
            },
            {
              "kind": "ending",
              "target": "",
              "expected": true
            },
            {
              "kind": "selected_ending",
              "target": "",
              "expected": "signal_sent"
            }
          ]
        }
      ]
    }
  ],
  "worldEvents": [],
  "customMechanicDefs": [],
  "savedMechanicTemplates": [],
  "objectiveSets": [],
  "customRoomTemplates": [],
  "customObjectTemplates": [],
  "customNpcTemplates": [],
  "customSavedScripts": []
}
