Skip to content

task 8 brief

Xopher edited this page Oct 22, 2026 · 1 revision

Task 8: The other seven LTTP temples (boards #1458–#1464, one commit each)

Files per temple: tools/temples/classic/dress.ts (its CLASSIC_PLANS entry), tools/temples/regenerate.ts (PLANS loses it), src/lib/engine/temples/<id>.ts (generated), tools/temples/classic/overrides/<id>.json if the converter needs one.

Interfaces: consumes Task 7's ClassicPlan, dressClassic and renderClassicModule; produces nothing new.

Order (smallest first): Earth/Skull Woods, Light/Desert Palace, Water/Swamp Palace, Shadow/Palace of Darkness, Ice/Ice Palace, Fire/Turtle Rock, Moon/Ganon's Tower.

  • Step 1: Add the plan:
    • the theme and relic from today's PLANS entry;
    • mustClear sized to the report's count, with distinct beasts of the theme, keeping every beast of today's plan;
    • minibosses at 3–5, and the boss at 8 (13 for Fire, Ice) as today.
  • Step 2: Generate the temple. Then run chemx test tests/unit/ClassicTemples.spec.ts and chemx test tests/unit/ShippedTemplesAudit.spec.ts. Expected: PASS.
  • Step 3: Paste classicReport(id).repeats into the board task. For Moon, also paste the floor count and must-clear count: the owner decides on the Misery Mire fallback from those numbers.
  • Step 4: Commit feat(temples): the <Name> Temple follows <Dungeon>.

How it works now (binding; the plan text above predates Task 7's fix rounds)

  • The dress tool: tools/temples/classic/dress.ts (entry + CLI; run with esbuild exactly as its header says) and its modules (dressBoard.ts, dressPlace.ts, dressReach.ts, dressLinks.ts, dressDoors.ts, dressRooms.ts, dressChores.ts, dressPlans.ts). Plans live in CLASSIC_PLANS in dressPlans.ts (Storm is the model: read its entry and ClassicPlan); CLASSIC_IDS = Object.keys(CLASSIC_PLANS).
  • Per temple: add its CLASSIC_PLANS entry; remove it from PLANS in tools/temples/regenerate.ts; run the dress CLI for that id to write src/lib/engine/temples/<id>.ts; the existing specs then hold it to the classic rules (ClassicTemples.spec.ts iterates CLASSIC_IDS; ShippedTemplesAudit.spec.ts iterates the remaining SHIPPED_IDS).
  • tests/unit/ClassicDungeonGuards.spec.ts dresses every JSON in memory under the Storm plan as a stand-in and pins build/solve/reasons per temple. When you dress a temple with its own plan, move that temple's pin to its own plan (or have the guard use CLASSIC_PLANS[id] when present) and pin the real result. The two structural guards (every boss-blocking seal kept; with every seal blocked, no extra reach) must stay green for every temple.
  • Current stand-in results: Earth and Light clean; Ice, Fire, Moon, Shadow, Water solvable with one R4 each (the mini-boss choice: each temple's own plan settles it — choose minibosses so the audit has no R4); Wind R2 (not yours: Task 9).
  • The goal per temple: builds, solveTemple(...).solvable, the audit passes with no R-reasons, the Boss Key is needed to reach the boss, every guard green.
  • Chores, per the lead's rulings: must-clear plans start from today's beasts in PLANS[id].quests (every STARTER_QUESTS beast today's plan holds keeps a must-clear room; if a temple has fewer must-clear rooms than starter beasts, the overflow goes to side rooms as Storm did with Toybox Troll, recorded in classicReport(id).overflow), topped up with other beasts of the theme (BEAST_LIBRARY[].theme === id.replace("-temple","")) to the must-clear count; extras leave the temple; side rooms cycle through their floor's must-clear beasts; a plan short of beasts repeats one and lists it in classicReport(id).repeats (the art task reads it). Difficulty: must-clear monsters 1-2, minibosses 3-5, boss as today's plan (8, 13 for Fire and Ice).
  • Relics and shop items: keep each temple's from today's PLANS entry.
  • The swamps (Shadow Temple) keep Palace of Darkness (owner default; Misery Mire was offered and not chosen).
  • Moon (Ganon's Tower): GT Quad Pot (3F 12,24 in the JSON) has enemies that are all minibosses; make sure the dressing and plan treat it as the miniboss room it is (not a plain must-clear monster) if the tool does not already.
  • ShippedTemplesAudit.spec.ts and ClassicTemples.spec.ts must stay ≤ 500 lines; split a spec rather than grow it past.
  • Order: Earth, Light, Water, Shadow, Ice, Fire, Moon — one commit per temple (feat(temples): the <Name> Temple follows <Dungeon>), each with its specs green before the next.

Gate per temple

chemx test tests/unit/ClassicTemples.spec.ts, chemx test tests/unit/ClassicDungeonGuards.spec.ts, chemx test tests/unit/ShippedTemplesAudit.spec.ts (one at a time). Before the final commit: npx --yes chemx@26.10.19-530 audit --no-index --unroll > /tmp/audit-t8.txt 2>&1, check no file you touched newly appears under LINE_BUDGET_FILE / CONTROL_FLOW_INLINE_BOOLEAN / TYPE_COLOCATION / HOOK_RETURN_OVERLOAD / UNGUARDED_LOGGING, then git checkout -- chemx-ratchet.json. The generated temple modules may be long: if a module crosses 500 lines, say so in the report (the lead decides; do not hand-split generated files).

Global Constraints (part 2)

  • You work in your own isolated git worktree branched from origin/master; run pnpm install --frozen-lockfile --prefer-offline first. Commit on your branch only; the lead merges it into feat/classic-temples-2 and ships one PR. Never touch /home/xopher/www/x/do-it-for-the-xp itself (other sessions share it). Never git stash.
  • Use chemx only. Run only the spec(s) your brief names, one at a time: chemx test tests/unit/<Name>.spec.ts. Never raw pnpm test|typecheck|lint|jest or npx jest, never a bare chemx test, never chemx verify, no typecheck/lint/build (the lead runs those once per wave; CI runs the suite on the PR).
  • Keep every file you create or grow under 500 lines (the repo's audit ratchet counts files over 500 as LINE_BUDGET_FILE). Name inline conditions in ifs (const isX = ...; if (isX)), and give object-literal parameter types a named interface (TYPE_COLOCATION) — the ratchet blocks the PR otherwise.
  • Temple ids, names, regions and themes don't change (wind-temple, earth-temple, …). Theme = id.replace("-temple", "") against BEAST_LIBRARY[].theme.
  • Game rules go in pure modules under src/lib/services/** (or src/lib/engine/**) with jest specs; screens stay thin. New components use <script setup lang="ts">; pages keep defineComponent with a sibling .ts/.scss.
  • In-world text comes from the copy catalogue (src/lib/services/copy/catalog/, three voices) through useCopy(); in-world prompts use useRevealPrompt(), never Ionic alerts. Sounds use play$fx(<key of src/assets/fx/index.ts>).
  • Original beasts 001–093 are family art: never overwrite or re-point them.
  • Quest difficulty is Fibonacci: must-clear monsters 1–2, minibosses 3–5, boss 8–13. Schedules follow SCHEDULES (daily 19:00, am 08:00, bed 20:30, school weekdays, weekly 18:00, monthly custom).
  • Every door into a boss room is a Boss door (isBossRoom in authoredDoors.ts). Bombs never open locked doors.
  • Keep comment density and naming like the surrounding code (long, plain-English doc comments).
  • Do not dispatch subagents of any kind, and never a reviewer.

Table of Contents


Home - See Pages

Developer Docs

Start Screen

User Management

My Portal

My Home

The City (Hometown)

The World Map

The Dungeon

Game Master

Settings

Support & Glossary

About XP

Clone this wiki locally