Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 27 additions & 5 deletions .fallowrc.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,6 @@
"src/dev/**/*.tsx"
],

"entry": [
"scripts/generate-ridge-blockout-sources.test.mjs"
],

"health": {
"ignore": ["**/*.generated.ts", "dist/**", "storybook-static/**"]
},
Expand Down Expand Up @@ -77,5 +73,31 @@
{ "from": "core", "allow": ["core", "shared"], "allowTypeOnly": ["shared"] },
{ "from": "shared", "allow": ["shared"] }
]
}
},
"ignoreExports": [
{
"file": "src/game/core/ecs/systems/playerSystems.ts",
"exports": ["*"]
},
{
"file": "src/game/core/player/PlayerController.ts",
"exports": ["*"]
},
{
"file": "src/game/scenes/potassiumSlip/runtime/renderer.ts",
"exports": ["*"]
},
{
"file": "src/game/scenes/potassiumSlip/runtime/session.ts",
"exports": ["*"]
},
{
"file": "src/game/scenes/potassiumSlip/runtime/phaserData.ts",
"exports": ["*"]
},
{
"file": "src/game/scenes/potassiumSlip/runtime/waves.ts",
"exports": ["*"]
}
]
}
8 changes: 3 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,9 @@ Ridge Stage Debugger with `?mode=ridge-stage-debugger` after starting
`pnpm dev`; it hosts the live Bridge preview, route-beat controls, Walk Rail
readouts, Stage Spot movement, and Bridge Stage debug overlays.

Legacy Ridge blockout source files still live under
`src/game/scenes/ridge/blockout/sources/`. If you edit those files, run
`pnpm ridge:source` to refresh committed `.generated.ts` artifacts, or
`pnpm ridge:source:check` to verify freshness. `pnpm check` includes that
freshness gate.
Stampede Sketch remains a standalone mini-game scene (`stampedeSketch`) for
optional future content; reach it via the dev scene switcher or basement console
(`stampede`) until the Ridge rework wires a player-facing entry.

## Architecture

Expand Down
10 changes: 5 additions & 5 deletions docs/adr/0001-ridge-blockout-as-exploration-map-source.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Adopt Ridge Blockout As Exploration Map Source Of Truth

Status: accepted for the current/prototype Ridge runtime; superseded as future
Ridge route canon by the Ridge pre-production plan.
Status: **superseded** — blockout implementation removed from the repo (Bridge
Tracer is the active Ridge runtime). Kept as historical ADR.

This ADR explains why the existing Phaser Ridge prototype compiles a typed
blockout source into spatial facts. It does not require the desired
Expand All @@ -23,6 +23,6 @@ route, anchor, shortcut, and home-mutation facts before runtime presentation and
interaction modules consume it. This deepens the original runtime decision
rather than superseding it.

The current/prototype blockout source lives beside the generated runtime artifact at
`src/game/scenes/ridge/blockout/sources/folded-desk-ridge.source.ts`. The
language documentation remains in `docs/game-design/ridge/map-language.md`.
The folded-desk blockout source and compiler were removed from the repository.
The language documentation remains in `docs/game-design/ridge/map-language.md`
as a historical contract reference.
4 changes: 2 additions & 2 deletions docs/adr/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ override the Ridge pre-production route.

| ADR | Current Scope |
| --- | --- |
| [`0001-ridge-blockout-as-exploration-map-source.md`](./0001-ridge-blockout-as-exploration-map-source.md) | Current/prototype Ridge blockout runtime only; superseded as future route canon. |
| [`0001-ridge-blockout-as-exploration-map-source.md`](./0001-ridge-blockout-as-exploration-map-source.md) | Historical folded-desk blockout runtime (removed from repo); superseded as future route canon. |
| [`0002-audio-adapter-boundary.md`](./0002-audio-adapter-boundary.md) | Current audio ownership boundary. |
| [`0003-ridge-blockout-source-contract.md`](./0003-ridge-blockout-source-contract.md) | Current/prototype Ridge blockout tooling contract only; superseded as future route canon. |
| [`0003-ridge-blockout-source-contract.md`](./0003-ridge-blockout-source-contract.md) | Historical blockout tooling contract (removed from repo); superseded as future route canon. |
| [`0004-ridge-stage-composition-source.md`](./0004-ridge-stage-composition-source.md) | Experimental Ridge exploration and First Playable Route staging source. |
15 changes: 9 additions & 6 deletions docs/architecture-direction.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,12 @@ why behind the runtime shape, and the direction future refactors should preserve
For what exists in code today, treat [`runtime-architecture.md`](runtime-architecture.md),
`AGENTS.md`, and the scoped `.agents/rules/` files as the operational guidance.

Ridge caveat: architecture notes about the typed Ridge blockout apply to the
current Phaser prototype/runtime. They do not override the Ridge pre-production
route in [`game-design/ridge/README.md`](./game-design/ridge/README.md).
Ridge caveat: the folded-desk blockout stack was removed from the repo. Active
Ridge runtime spatial truth lives in Bridge stage composition
(`src/game/scenes/ridge/bridge/`). Historical blockout notes in ADRs and
[`game-design/ridge/map-language.md`](./game-design/ridge/map-language.md) do
not override the pre-production route in
[`game-design/ridge/README.md`](./game-design/ridge/README.md).

## 1. Architectural Philosophy

Expand Down Expand Up @@ -51,9 +54,9 @@ paths, prefer [`runtime-architecture.md`](runtime-architecture.md). When
proposing future refactors:

- Prefer extending existing lifecycle, bridge, overlay, scene UI, and shared runtime seams instead of re-introducing callback-only scene orchestration, ad-hoc overlay maps, or ad-hoc global state.
- For current/prototype Ridge runtime work, keep spatial truth in the typed
Ridge blockout source and compiled facts instead of rebuilding parallel
parent/route/spatial catalogs.
- For current Ridge runtime work, keep spatial truth in Bridge stage
composition (`stageComposition.ts`) instead of rebuilding parallel catalogs or
resurrecting the removed blockout pipeline.
- Introduce shared render helpers only when repeated render policy code appears.

---
Expand Down
21 changes: 8 additions & 13 deletions docs/game-design/README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Game Design

This directory separates shipped behavior, active Ridge pre-production design,
current runtime prototype truth, long-term direction, runtime blockout source,
and reference material. Do not treat every file here as equally active.
current runtime prototype truth, long-term direction, and reference material.
Do not treat every file here as equally active.

## Source Of Truth

Expand All @@ -13,8 +13,7 @@ and reference material. Do not treat every file here as equally active.
- **Current Ridge runtime/prototype snapshot:** [`ridge/ridge-snapshot.md`](./ridge/ridge-snapshot.md).
- **Current Bridge runtime spatial source:** [`stageComposition.ts`](../../src/game/scenes/ridge/bridge/stageComposition.ts), described by
[`ridge/ridge-snapshot.md`](./ridge/ridge-snapshot.md).
- **Legacy folded blockout source:** [`folded-desk-ridge.source.ts`](../../src/game/scenes/ridge/blockout/sources/folded-desk-ridge.source.ts), described by
[`ridge/map-language.md`](./ridge/map-language.md).
- **Legacy blockout contract (historical):** [`ridge/map-language.md`](./ridge/map-language.md) — source removed from repo.
- **Pre-production product vision:** [`ridge/summit.md`](./ridge/summit.md).
- **Milestone map:** [`ridge/milestone-plan.md`](./ridge/milestone-plan.md)
for current route-reset milestones and prototype reuse rules.
Expand Down Expand Up @@ -66,12 +65,9 @@ prefer GitHub Issues.
- **[Sketchbook Ridge Milestone Plan](./ridge/milestone-plan.md)**:
Current route-reset milestones, source stack, prototype reuse rules, and
first-agent checklist. It is not the live issue tracker.
- **[Ridge Blockout Source](./ridge/map-language.md)**: Typed blockout source
contract for Ridge room beats, environment tags, traversal primitives, and
greybox generation.
- **[Legacy Ridge Blockout Source](../../src/game/scenes/ridge/blockout/sources/folded-desk-ridge.source.ts)**:
Folded prototype authoring data retained as build input and reference, not
the active Bridge rail/stage authoring surface.
- **[Ridge Blockout Source](./ridge/map-language.md)**: Historical typed
blockout contract (removed from repo; Bridge stage composition is the active
spatial source).
- **[Ridge Legacy Docs](./ridge/legacy/README.md)**: Superseded folded/Cicka
Home map plans, old summit/milestone history, and blockout reviews. Reference
only unless a current active doc explicitly links there.
Expand Down Expand Up @@ -105,9 +101,8 @@ prefer GitHub Issues.
`mini-games/stampede-sketch.md`. These are local mini-game contracts, not
required first-ending Living Proof.
- **Current Ridge runtime/prototype reality:** `ridge/ridge-snapshot.md`.
- **Current runtime source:**
`../../src/game/scenes/ridge/blockout/sources/folded-desk-ridge.source.ts`.
- **Current runtime source documentation:** `ridge/map-language.md`.
- **Current runtime source:** `../../src/game/scenes/ridge/bridge/stageComposition.ts`.
- **Historical blockout documentation:** `ridge/map-language.md`.
- **Legacy/prototype topology and planning history:** `ridge/legacy/`.
- **Reference/provenance:** `ridge/reference/` plus `docs/research/`. These can
guide future work, but should not override active Ridge design, shipped
Expand Down
8 changes: 4 additions & 4 deletions docs/game-design/ridge/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Use each file for exactly one concern:
| Active open questions | [`open-questions.md`](./open-questions.md) | True design unknowns and blockout-detail TBD. Area premises may already be accepted even when prompt/topology details remain open. |
| Product vision | [`summit.md`](./summit.md) | Durable fantasy and pillars, not detailed route implementation. |
| Implementation sequencing | [`milestone-plan.md`](./milestone-plan.md) | Current route-reset milestones, Bridge Tracer Slice, source stack, Agent-Ready Slice Contract, prototype reuse rules, and agent checklist. Not live backlog. |
| Runtime blockout contract | [`map-language.md`](./map-language.md) | Source format and generated facts for the current/prototype blockout. |
| Historical blockout contract | [`map-language.md`](./map-language.md) | Superseded source format (removed from repo); Bridge stage composition is active. |
| Legacy prototype history | [`legacy/`](./legacy/README.md) | Superseded folded/Cicka Home plans, old summit/milestone history, map plans, and reviews. Reference only unless an active doc links there. |
| Art/audio/asset support | [`reference/`](./reference/README.md) | Reference packs that support active docs but do not override route canon. |
| Live work | GitHub Issues | PRDs, current backlog, triage state, and agent briefs. |
Expand Down Expand Up @@ -69,9 +69,9 @@ Treat these as prototype/reference unless a task explicitly says to adapt them:
- Main-path slopes, ramps, wall jumps, double jumps, or precision platforming.
- Mini-game clears as required first-ending proof.

Useful legacy pieces may still be preserved or adapted: the Ridge Blockout
Source contract, compiler, generated facts, validation, and preview/debugger
workflow.
The Ridge Blockout Source implementation was removed from the repo; keep
[`map-language.md`](./map-language.md) and git history as contract reference.
The Ridge Stage Debugger (`?mode=ridge-stage-debugger`) remains Bridge-first.

Superseded planning docs live under [`legacy/`](./legacy/README.md). Do not
search that folder first when updating active route design.
Expand Down
4 changes: 2 additions & 2 deletions docs/game-design/ridge/legacy/reviews/blockout-fun-review.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Ridge Blockout Fun Review

Status: design review of
[`folded-desk-ridge.source.ts`](../../../../../src/game/scenes/ridge/blockout/sources/folded-desk-ridge.source.ts).
Status: design review of the removed `folded-desk-ridge.source.ts` blockout
(see git history; source no longer in the repo).

This review scores the first text skeleton against the current research notes on
2D map design, Lucky Luna, and Nine Sols.
Expand Down
58 changes: 23 additions & 35 deletions docs/game-design/ridge/map-language.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,27 @@
# Ridge Blockout Source

Status: active runtime source and design tool.
> Status: **superseded / removed from repo.** The folded-desk blockout source,
> compiler, and generated artifacts were deleted when the active Ridge runtime
> became the Bridge Tracer Slice only. This doc remains as historical contract
> reference; do not run `pnpm ridge:source` (scripts removed).

Status: historical design tool (no longer in `src/`).

The Ridge Blockout Source is a typed TypeScript authoring contract for
designing Ridge room beats before final assets exist. It should be readable by
Danilo, easy for agents to edit, and strict enough that TypeScript plus the
source generator can produce a Phaser greybox, typed facts, traversal
connectors, numeric tile rows, and progress-gated presentation inputs.

## Decision

`folded-desk-ridge.source.ts` is the authoring source for Ridge greybox
generation. It is not design prose. Runtime imports the committed generated
artifact next to it.
## Decision (historical)

The first full skeleton lives in
[`src/game/scenes/ridge/blockout/sources/folded-desk-ridge.source.ts`](../../../src/game/scenes/ridge/blockout/sources/folded-desk-ridge.source.ts).
Source-contract work should use that file, not a toy example, so the language
evolves against the real Ridge topology.
`folded-desk-ridge.source.ts` was the authoring source for Ridge greybox
generation. It was not design prose. Runtime imported a committed generated
artifact compiled from typed `.source.ts` files.

Location note: the blockout used to live under `docs/game-design/` and then as
a raw `.blockout.txt` runtime import because the language started as a design
artifact. It now lives beside the generated Ridge source artifact because the
build checks it as typed source data. If it moves again, update the generator,
runtime import, this document, and ADR-0001 in the same migration.
That implementation was removed from the repository when the active Ridge
scene became the Bridge Tracer Slice only. Restore from git history if the
contract is needed again for a future area blockout.

The default grid cell size is **48px**, declared at the source level instead of
hard-coded into the runtime:
Expand Down Expand Up @@ -95,20 +93,12 @@ encounter logic stay outside v0.
separate enough that one can change without rewriting all three.
- **Asset-light:** symbols reserve intent before final art exists.

Agents should edit `.source.ts` files and then run `pnpm ridge:source`.
`pnpm ridge:source:check` and the standard `pnpm check` command fail when a
generated artifact is stale or when source validation rejects the contract.

## Tooling Status

This contract is retained for the legacy folded Ridge prototype source,
compiler, generated facts, and validation tests. It is no longer the main Ridge
development surface. Current Bridge rail/stage work uses the Ridge Stage
Debugger at `?mode=ridge-stage-debugger` and the Bridge Stage Composition Source
under `src/game/scenes/ridge/bridge/`.

If this legacy source is edited, source edits still happen in `.source.ts`
followed by `pnpm ridge:source`.
The blockout generator scripts and the former Ridge blockout source tree were
removed. Current Bridge rail/stage work uses the Ridge Stage Debugger at
`?mode=ridge-stage-debugger` and the Bridge Stage Composition Source under
`src/game/scenes/ridge/bridge/stageComposition.ts`.

## Core Shape

Expand Down Expand Up @@ -263,12 +253,10 @@ beats should not overlap unless the map explicitly declares a merge rule. v0
should avoid merge rules and treat conflicting non-empty overlap as a validation
error.

## Current Runtime Output
## Historical Runtime Output

`src/game/scenes/ridge/blockout/` generates a committed `.generated.ts`
artifact from the typed `.source.ts` file. `RidgeScene` renders every room into
one whole-world greybox by default, derives typed traversal connectors from
`movement` metadata, compiles typed facts for presentation/interaction modules,
resolves shortcuts from durable Ridge progress, and keeps future routes, locked
shortcuts, and future Cicka Home mutations as inactive promises until their
progress source exists.
The removed pipeline generated a committed `.generated.ts` artifact from typed
`.source.ts` files, derived traversal connectors from `movement` metadata,
compiled facts for presentation/interaction modules, and resolved shortcuts from
durable Ridge progress. None of that runs in the current Bridge-only
`RidgeScene`.
42 changes: 10 additions & 32 deletions docs/game-design/ridge/ridge-snapshot.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,14 @@
- **Ridge source router:** [`README.md`](./README.md).
- **Active story/route canon:** [`story-level-bible.md`](./story-level-bible.md).
- **Active area design:** [`areas/`](./areas/README.md).
- **Legacy blockout spatial data:** [`folded-desk-ridge.source.ts`](../../../src/game/scenes/ridge/blockout/sources/folded-desk-ridge.source.ts).
- **Blockout language contract:** [`map-language.md`](./map-language.md).
- **Legacy blockout language (historical):** [`map-language.md`](./map-language.md) — superseded; folded-desk source removed from the repo.
- **Legacy folded topology reference:** [`legacy/`](./legacy/README.md).
- **Product vision:** [`summit.md`](./summit.md).
- **Live implementation work:** GitHub Issues.

If this file disagrees with the current Ridge runtime code about implemented
behavior, the code wins. If this file describes the legacy folded desk blockout
and disagrees with the folded desk Ridge blockout about room layout, route
order, anchors, shortcuts, or progress-gated geometry, the blockout wins.
If this file disagrees with GitHub about active work state, GitHub wins.
behavior, the code wins. If this file disagrees with GitHub about active work
state, GitHub wins.
If this file disagrees with `story-level-bible.md` or the matching `areas/`
doc about future route intent, the active design docs win.

Expand Down Expand Up @@ -56,32 +53,13 @@ Current runtime characteristics:
post-Bridge area state.
- Bridge prompts and dialogue are mirrored into a small typed runtime data layer
from the accepted Bridge dialogue IDs.
- The folded desk blockout, generated facts, traversal helpers, Cicka Home
mutation code, Trail Cards, and Stampede reward path remain in the repo as
protected prototype/reference assets, but they are not the active Ridge route
presented by the `ridge` scene.
- Stampede remains loadable as its own scene and through development tooling,
but the active Bridge slice does not route to Stampede/Telegraph/Domino.

## Protected PoC Assets

The valuable Ridge proof-of-concept investment is the authoring and QA spine,
not the current moment-to-moment traversal model.

Preserve or adapt:

- Ridge Blockout Source / source contract.
- compiler and generated spatial facts.
- route, anchor, shortcut, collider, validation, and mutation facts.
- read-only previewer/debugger workflow.
- map-loading path that lets agents and Danilo inspect topology quickly.

Disposable if a better Ridge emerges:

- current required-jump traversal feel.
- slope/ramp-first geometry assumptions.
- current folded-desk room arrangement.
- any runtime module whose main job was proving the old platformer-like route.
- The legacy folded-desk blockout stack (source compiler, generated map,
traversal helpers, Cicka Home mutations, trail-card anchors) was removed from
the repo; see git history and [`map-language.md`](./map-language.md) for the
old contract description.
- **Stampede Sketch** remains as a standalone scene and development entry point
(dev switcher, basement `stampede` command). It is not on the active Bridge
route; keep it for optional mini-game content in a future rework.

## Active Runtime Route Read

Expand Down
Loading
Loading