{
  "version": 1,
  "status": "Browser review and playable walkthrough implemented; live-game integration pending.",
  "name": "Buried Pyramid — Crystal Passage",
  "scope": "One new non-boss floor; five semantic rooms.",
  "delivery": {
    "requested_finish_line": "A playable level accessible through a staging URL.",
    "frontend_preview": "Movement, camera, visual collision checks, local crystal/door state and a completion condition can run in the browser and use static hosting.",
    "authentic_gameplay": "Existing Runiverse battles, party state, rewards and dungeon completion use server systems. A real-game playtest must register the floor content and use the existing staging backend.",
    "recommended_sequence": [
      "Browser exploration graybox",
      "Detailed room assembly",
      "Integrate authoritative collision, encounters and progression",
      "Publish and test the playable staging link"
    ],
    "current_status": "Five-room browser walkthrough with original art, local progression and simplified solo encounters. Real-game backend integration remains pending.",
    "architecture_evidence": [
      "source/packages/client/actions/BattlerHandler.ts",
      "source/packages/client/actions/FinishDungeonHandler.ts",
      "source/packages/client/utils/battler/BattlerRoomJoiner.ts"
    ]
  },
  "existing_prototype_role": "The Site uses the source assembly kit with the five semantic room roles, encounters, crystal gate, and local progression implemented. The earlier random assembly experiment remains separate.",
  "pipeline": [
    "dungeon brief",
    "room graph and progression",
    "encounter and reward plan",
    "room contracts",
    "connected graybox",
    "sprite assembly",
    "in-game validation"
  ],
  "source_context": {
    "story": "The Radiant Elixir",
    "story_id": "669ed04a097ba39743ee2cde",
    "source_story_level": 25,
    "balance_note": "The story lists level 25 while the selected source enemy entities list level 30. Target difficulty and reward balance require a separate pass; do not infer balance from labels.",
    "files": [
      "source/content/definitions/dungeonStories.json",
      "source/content/definitions/battlerEncounters.json",
      "source/content/definitions/battlerEntities.json",
      "source/content/definitions/Interactions/dungeons/the-buried-pyramid.json"
    ]
  },
  "rooms": [
    {
      "id": "entry",
      "name": "Arrival chamber",
      "required": true,
      "purpose": "Orient the party and show the pyramid theme.",
      "encounter": null,
      "intensity": "quiet",
      "reward": "None required.",
      "objectives": [
        "Provide safe spawn and a readable forward route."
      ],
      "brief": {
        "connections": [
          "outside entrance",
          "opening hall"
        ],
        "anchors": [
          "party spawn",
          "entry stairs",
          "forward approach"
        ],
        "layout_intent": "Compact, uncluttered arrival space. No traps or encounters in the spawn clearance."
      }
    },
    {
      "id": "opening",
      "name": "Bee hall",
      "required": true,
      "purpose": "Introduce combat with a standard pyramid encounter.",
      "encounter": "opening",
      "intensity": "standard encounter",
      "reward": "Use the chosen encounter reward table after balance review.",
      "objectives": [
        "Clear the opening encounter to progress."
      ],
      "brief": {
        "connections": [
          "arrival chamber",
          "crystal chamber"
        ],
        "anchors": [
          "encounter trigger",
          "clear approach",
          "forward exit"
        ],
        "layout_intent": "Readable route to the encounter. Decorative rubble frames the room without hiding the exit."
      }
    },
    {
      "id": "objective",
      "name": "Crystal chamber",
      "required": true,
      "purpose": "Give a quiet objective and a choice of continuing or exploring.",
      "encounter": null,
      "intensity": "quiet objective",
      "reward": "Exactly 3 guaranteed progression Honey Crystals, once per floor.",
      "objectives": [
        "Collect 3 Honey Crystals.",
        "Reveal the optional vault and the 3-crystal gate."
      ],
      "brief": {
        "connections": [
          "bee hall",
          "optional vault",
          "sealed passage to guardian"
        ],
        "anchors": [
          "three reachable crystal interactions",
          "gate interaction",
          "optional branch landmark"
        ],
        "layout_intent": "Hub with a clear main exit. Three object interactions can be reached without entering the optional vault."
      },
      "design_change": "Use existing amber art with new floor-scoped logic. Disable crystal ambush randomness in this first design to preserve pacing. Do not copy original quest trackers."
    },
    {
      "id": "optional",
      "name": "Side vault",
      "required": false,
      "purpose": "Offer a deliberate extra fight for an optional reward.",
      "encounter": "optional",
      "intensity": "optional encounter",
      "reward": "One optional vault payout after victory; exact rewards pending.",
      "objectives": [
        "Let the party choose whether to challenge the vault.",
        "Return to the crystal chamber afterwards."
      ],
      "brief": {
        "connections": [
          "crystal chamber; shared entry and return"
        ],
        "anchors": [
          "vault interaction",
          "encounter trigger",
          "reward",
          "return route"
        ],
        "layout_intent": "A short, clearly optional branch. Reward interaction sits beyond the encounter commitment point."
      },
      "design_change": "Use the source Mummy formation directly as a battle baseline. The original vault has randomized outcomes; this proposal uses a deliberate encounter followed by a reward."
    },
    {
      "id": "climax",
      "name": "Amber guardian chamber",
      "required": true,
      "purpose": "End the floor with one elite encounter and a clear exit.",
      "encounter": "climax",
      "intensity": "elite encounter",
      "reward": "Floor completion reward and onward exit; contents pending.",
      "objectives": [
        "Defeat the Amber Specter encounter.",
        "Unlock the onward stairs after victory."
      ],
      "brief": {
        "connections": [
          "crystal gate",
          "outside exit"
        ],
        "anchors": [
          "entrance approach",
          "elite encounter trigger",
          "reward",
          "exit stairs"
        ],
        "layout_intent": "Largest focal space on this small floor. Keep entry and exit approaches legible and unblocked."
      },
      "design_change": "Reuse the elite formation, not the Golden Queen boss. Source party-size variants include supporting bees for larger parties."
    }
  ],
  "edges": [
    {
      "a": "entry",
      "b": "opening",
      "optional": false,
      "requires": []
    },
    {
      "a": "opening",
      "b": "objective",
      "optional": false,
      "requires": [
        "opening_cleared"
      ]
    },
    {
      "a": "objective",
      "b": "optional",
      "optional": true,
      "requires": [],
      "return_allowed": true
    },
    {
      "a": "objective",
      "b": "climax",
      "optional": false,
      "requires": [
        "crystal_gate_open"
      ]
    }
  ],
  "progression": {
    "entry_room": "entry",
    "exit_room": "climax",
    "main_path": [
      "entry",
      "opening",
      "objective",
      "climax"
    ],
    "mandatory_encounters": [
      "opening",
      "climax"
    ],
    "optional_encounters": [
      "optional"
    ],
    "crystals": {
      "item_source_id": "66bf62ff0871e62657ba8ab2",
      "guaranteed_quantity": 3,
      "gate_cost": 3,
      "optional_spending_allowed": false,
      "random_required_drops": false,
      "party_progress": "one shared floor objective; exact runtime inventory binding pending"
    },
    "gate": {
      "open_once": true,
      "persists_on_revisit": true,
      "deduct_crystals_once": true,
      "position": "objective -> climax",
      "state": "crystal_gate_open",
      "reuse": "Existing door/statue/amber art as appropriate; new floor-scoped state and actions required."
    },
    "exit_requires": [
      "climax_cleared"
    ],
    "pacing": [
      "safe arrival",
      "standard fight",
      "quiet objective and choice",
      "elite climax"
    ],
    "rest_policy": "Quiet rooms are breathing space, not automatic healing."
  },
  "encounter_profiles": {
    "opening": {
      "source_interaction": "D-PYR-Amber-A-1",
      "source_interaction_id": "66bf71a00871e62657bbaa35",
      "evidence": "Verified local content definitions; not a live-server capture.",
      "usage": "Existing formations are balance baselines, not a claim that difficulty is tuned for this new floor.",
      "party_size_variants": {
        "1": {
          "encounter_id": "668ea498471363959a15bd0b",
          "source_name": "The Pyramid - The Hall - 2 - 1p",
          "enemies": [
            {
              "entity_id": "645924cdb7edc89002ad8fa2",
              "name": "Honey Bee (The Pyramid)",
              "quantity": 1,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/honeybee.png"
              }
            }
          ]
        },
        "2": {
          "encounter_id": "668ea4ae471363959a15bd22",
          "source_name": "The Pyramid - The Hall - 2 - 2p",
          "enemies": [
            {
              "entity_id": "645924cdb7edc89002ad8fa2",
              "name": "Honey Bee (The Pyramid)",
              "quantity": 2,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/honeybee.png"
              }
            }
          ]
        },
        "3": {
          "encounter_id": "668ea562471363959a15bd55",
          "source_name": "The Pyramid - The Hall - 2 - 3p",
          "enemies": [
            {
              "entity_id": "645924cdb7edc89002ad8fa2",
              "name": "Honey Bee (The Pyramid)",
              "quantity": 3,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/honeybee.png"
              }
            }
          ]
        },
        "4": {
          "encounter_id": "668ea587471363959a15bd6c",
          "source_name": "The Pyramid - The Hall - 2 - 4p",
          "enemies": [
            {
              "entity_id": "645924cdb7edc89002ad8fa2",
              "name": "Honey Bee (The Pyramid)",
              "quantity": 4,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/honeybee.png"
              }
            }
          ]
        }
      }
    },
    "optional": {
      "source_interaction": "D-PYR-Vault-A-1",
      "source_interaction_id": "66c34cb14192e5e11efeba34",
      "evidence": "Verified local content definitions; not a live-server capture.",
      "usage": "Existing formations are balance baselines, not a claim that difficulty is tuned for this new floor.",
      "party_size_variants": {
        "1": {
          "encounter_id": "668eb92d471363959a15cb72",
          "source_name": "The Pyramid - Vault Encounter - 22 - 1p",
          "enemies": [
            {
              "entity_id": "6690175aedc1c2090e83645c",
              "name": "Mummy (The Pyramid)",
              "quantity": 2,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/mummy_completed.png"
              }
            }
          ]
        },
        "2": {
          "encounter_id": "668eb962471363959a15cb8a",
          "source_name": "The Pyramid - Vault Encounter - 22 - 2p",
          "enemies": [
            {
              "entity_id": "6690175aedc1c2090e83645c",
              "name": "Mummy (The Pyramid)",
              "quantity": 2,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/mummy_completed.png"
              }
            }
          ]
        },
        "3": {
          "encounter_id": "668eb99c471363959a15cba1",
          "source_name": "The Pyramid - Vault Encounter - 22 - 3p",
          "enemies": [
            {
              "entity_id": "6690175aedc1c2090e83645c",
              "name": "Mummy (The Pyramid)",
              "quantity": 2,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/mummy_completed.png"
              }
            },
            {
              "entity_id": "66901727edc1c2090e8363f9",
              "name": "Sand Bat (The Pyramid)",
              "quantity": 1,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/sandbat.png"
              }
            }
          ]
        },
        "4": {
          "encounter_id": "668eb9ce471363959a15cbb8",
          "source_name": "The Pyramid - Vault Encounter - 22 - 4p",
          "enemies": [
            {
              "entity_id": "6690175aedc1c2090e83645c",
              "name": "Mummy (The Pyramid)",
              "quantity": 3,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/mummy_completed.png"
              }
            },
            {
              "entity_id": "66901727edc1c2090e8363f9",
              "name": "Sand Bat (The Pyramid)",
              "quantity": 1,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/sandbat.png"
              }
            }
          ]
        }
      }
    },
    "climax": {
      "source_interaction": "D-PYR-AmberSpecter-A",
      "source_interaction_id": "66cf40db9581d5c9600d6d76",
      "evidence": "Verified local content definitions; not a live-server capture.",
      "usage": "Existing formations are balance baselines, not a claim that difficulty is tuned for this new floor.",
      "party_size_variants": {
        "1": {
          "encounter_id": "668eac2b471363959a15c121",
          "source_name": "The Pyramid - The Hall - Elite (Sand) - 1p",
          "enemies": [
            {
              "entity_id": "6626dc8e6e4bbca68f52d9df",
              "name": "Amber Specter (The Pyramid)",
              "quantity": 1,
              "rank": "Elite",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/amberspectre_anim.png"
              }
            }
          ]
        },
        "2": {
          "encounter_id": "668ead1b471363959a15c164",
          "source_name": "The Pyramid - The Hall - Elite (Sand) - 2p",
          "enemies": [
            {
              "entity_id": "6626dc8e6e4bbca68f52d9df",
              "name": "Amber Specter (The Pyramid)",
              "quantity": 1,
              "rank": "Elite",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/amberspectre_anim.png"
              }
            }
          ]
        },
        "3": {
          "encounter_id": "668ead47471363959a15c17c",
          "source_name": "The Pyramid - The Hall - Elite (Sand) - 3p",
          "enemies": [
            {
              "entity_id": "67b233975c75aee0bc15ef58",
              "name": "Honey Bee (Pyramid) (Elite)",
              "quantity": 1,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/honeybee.png"
              }
            },
            {
              "entity_id": "6626dc8e6e4bbca68f52d9df",
              "name": "Amber Specter (The Pyramid)",
              "quantity": 1,
              "rank": "Elite",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/amberspectre_anim.png"
              }
            }
          ]
        },
        "4": {
          "encounter_id": "668ead66471363959a15c1b2",
          "source_name": "The Pyramid - The Hall - Elite (Sand) - 4p",
          "enemies": [
            {
              "entity_id": "67b233975c75aee0bc15ef58",
              "name": "Honey Bee (Pyramid) (Elite)",
              "quantity": 2,
              "rank": "Standard",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/honeybee.png"
              }
            },
            {
              "entity_id": "6626dc8e6e4bbca68f52d9df",
              "name": "Amber Specter (The Pyramid)",
              "quantity": 1,
              "rank": "Elite",
              "source_level": 30,
              "sprite": {
                "base": "sprites/enemies/amberspectre_anim.png"
              }
            }
          ]
        }
      }
    }
  },
  "fixed_rules": [
    "Preserve mandatory room order and the optional branch relationship.",
    "Keep a safe entrance and clear space around every transition and interaction.",
    "Place all required crystals before the gate, reachable without optional content.",
    "The optional vault cannot consume progression crystals or contain a mandatory item.",
    "Opening the gate persists; retreat and revisiting cannot charge again.",
    "The onward exit stays locked until the elite encounter is cleared.",
    "Assign encounter profiles by party size. One exploration trigger may represent a multi-enemy battle team.",
    "Use fresh floor-scoped trackers; existing story trackers and nextChapter links are references, not drop-in bindings.",
    "Use existing art. Keep gameplay state, encounter specification and sprite geometry separate."
  ],
  "allowed_randomness": [
    "Compatible room dimensions and silhouettes",
    "Physical orientation and optional-branch side",
    "Supported decoration positions",
    "Later, encounter variants within an approved difficulty budget"
  ],
  "not_randomized_initially": [
    "Main path order",
    "Mandatory resource supply and gate cost",
    "Number of required encounters",
    "Progression-item location behind optional content"
  ],
  "before_room_construction": [
    "Review this five-room overview and choose the target party/difficulty.",
    "Build an annotated graybox showing room roles, doors, encounter triggers, crystal nodes, rewards and exit.",
    "Validate all progression states, optional-branch skips, retreat/revisit behavior and party-size variants.",
    "Only then choose room shapes and place the original sprites."
  ]
}
