Skip to content

Start new Modern towers with bridge floors between rooms off - #2345

Merged
maniator merged 2 commits into
mainfrom
claude/project-thread-4u57k0
Nov 16, 2026
Merged

maniator merged 2 commits into
mainfrom
claude/project-thread-4u57k0

Conversation

@maniator

Copy link
Copy Markdown
Owner

Requested by Naftali · project thread

What & why

A new Modern tower now starts with Bridge floors between rooms off (owner, 2026-11-15). The New Tower window's box starts unticked, so the tower is founded unbridged unless the player ticks it.

Why it was on: when the switch was added it was an opt-out on top of the bridging every tower already did (the 1994 behavior, which Classic keeps), so "on" kept play unchanged for existing players. #2246 later reworded the "Don't bridge" box to "Bridge floors between rooms" and kept it checked to preserve that same default.

Only the founding default moves. The engine, its foundTower flag and the save format are unchanged: a save carries its own autoBridge, and an older save without the field still reads as bridged, so every existing tower keeps the setting it had.

Analytics (standing rule): two app_action codes, found_bridged (the box at a Modern founding, on/off) and auto_bridge (the Settings switch, with the engine's answer), with a data map section and a dashboard tile, so we can see how many players turn it back on. Help: Settings and Floors and lobbies now say it starts off.

Closes n/a: owner request in the project thread.

Type of change

  • Bug fix (non-breaking change that fixes an issue)
  • Classic-canon fix (matches the 1994 original for all towers)
  • Modern-mode feature (opt-in, "what the original couldn't do")
  • New player-facing feature (mode-agnostic)
  • Refactor / internal-only (no player-facing behavior change)
  • Docs / tooling

Game mode impact

  • This change is classic-canon (affects all towers, stays faithful to the 1994 original)
  • This change is modern-only (gated behind Modern mode, does not alter Classic behavior)
  • This change is mode-agnostic (identical in both modes)
  • Any mode-divergent behavior is isolated in the mode rule-set (resolved once at founding), not smeared into the simulation with ad-hoc mode checks

A Classic founding still pins bridged and sends no found_bridged (tested).

Quality gates

  • npm run typecheck
  • npm run lint
  • npm test (the touched suites pass locally: the new newTowerModal.integration.test.ts, uiDialogs.integration.test.ts, uiCallbacks.test.ts, analyticsDataMap.test.ts, newTower.test.ts, the file-size guard; full run left to CI)
  • npm run build (VC_TOOLING=1, in the pinned Playwright image)

Versioning

  • Added a .changes note with the right app: and crate: levels, or this PR changes no deployed path
  • Engine change: updated packages/verticopolis-engine/README.md and/or engine-rs/CRATE_README.md, or read both and put readmes: unchanged in the note, or this PR changes no engine source

app: patch (a default the player notices, no new feature), crate: none.

Complexity

n/a: one checkbox default in a dialog and one trackAppAction per founding and per Settings toggle; no loop, scan or cache is touched.

Hot-path record (section 6): no hot-path surface beyond two one-shot analytics sends on user clicks.

Screenshots / recordings

docs/screenshots/00b-onboarding-modern.png, re-rendered in the pinned mcr.microsoft.com/playwright:v1.61.1-jammy image (ONLY=first-run). The Classic shot from the same scene came out byte-identical.

New Tower, Modern, box unticked

Notes for reviewers

  • The New Tower dialog tests moved out of the oversized uiDialogs.integration.test.ts (a ratchet file) into newTowerModal.integration.test.ts, which mocks the analytics send to check the reported choice.
  • settings-modern (02b-settings-modern) founds through the tooling handle, which stays bridged, so that shot does not change.

Generated by Claude Code

@vercel

vercel Bot commented Nov 15, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
verticopolis Ready Ready Preview Nov 16, 2026 1:01am UTC

Request Review

@maniator maniator self-assigned this Nov 15, 2026
@github-actions github-actions Bot added this to the 4.x milestone Nov 15, 2026
@maniator
maniator marked this pull request as ready for review November 15, 2026 23:14
@chatgpt-codex-connector

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-15T23:14:50.423597Z
We couldn’t complete this review. Comment @codex review to try again.
75f09d5 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

@github-actions

Copy link
Copy Markdown
Contributor

📸 Screenshot drift check

No drift: the committed screenshots already match a fresh deterministic generation. ✅

@maniator maniator left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Independent review: CONDITIONAL GO at 1088a9b

I ran /gds-code-review and the stand-in Copilot pass (Codex hit its usage limit on this PR, and Copilot is down) as one lean pass with three lenses: Blind Hunter, Edge Case Hunter and Acceptance Auditor. The diff mixes a gameplay default with UI and analytics plumbing, so gds is the right skill.

Condition: fix the one patch finding (the em-dash in the new test file, inline). It is a one-character change, and the verdict carries to the fix commit if that line is the only change.

What I checked

  • Every founding path goes through the dialog. titleScreen.ts:81 and UI.ts:172 both reach newTowerModal and then saveLoad.newGame with startUnbridged. No other player path founds a tower. The tooling Engine.newGame(seed, mode) and the scenes still found bridged, so only 00b-onboarding-modern changes, as the PR says.
  • Existing saves keep their setting. The engine is untouched. load/assemble.rs:40 still reads a missing autoBridge as bridged for Modern and forces bridged for Classic.
  • Classic is unchanged. startUnbridged stays false outside the Modern branch, and no found_bridged is sent. The moved Classic test still proves the box is ignored: the box is now unticked, which would found a Modern tower unbridged, yet Classic still gets false.
  • Analytics. found_bridged and auto_bridge are added to AppActionName. auto_bridge reports the engine's answer and is not sent if the flip throws. The data map section and the dashboard tile both match the code, and the tile's ["action","detail"] breakdown is the same shape as the other ActionsTable tiles.
  • Help. settings.mdx and floors-and-lobbies.mdx now say the switch starts off. first-tower.mdx and classic-vs-modern.md don't depend on bridging, so they need no change.
  • Tests are honest. The analytics send is a vi.fn spy, no engine runs, and each new assertion fails if the default flips back.
  • History and version. The branch has two logical commits, is rebased on main (d0df552) and has no merge-from-main commits. The change note is app: patch and crate: none, which fits the 2026-11-14 bump rule for a behavior correction.
  • CI. All 39 check runs on 1088a9b are green or skipped by path, including the test, e2e shards, smoke, help-site build and every capture / shoot shard. So the screenshot drift check passes with the re-rendered 00b-onboarding-modern.png.

Findings

# Severity Triage Finding
1 Low patch newTowerModal.integration.test.ts:32: a new file adds an em-dash. Details are inline.
2 Low optional The dashboard tile counts events, not players. Someone who flips the Settings switch on, off and on again counts three times. The data map says "how often", which matches the tile. Only the PR body says "how many players". To count players, add a unique-users series (series("app_action", "Players", "dau")). Otherwise leave it.
3 Low optional The data map and the tile description say "From 2026-11-15". Players get the new default only when the next release deploys. Both codes are new, so no data from before the change gets mixed in, but naming the release would be more accurate.
4 Nit optional In uiCallbacks.test.ts, the trackAppAction spy now lives in the hoisted object named files, next to the file-module spies. A separate vi.hoisted object would read more clearly.

I dismissed one finding: found_bridged is sent just before onFound. If founding then throws, the event still reports the player's choice, which is what the data map promises.

Hot-path record (section 6), commit 1088a9b, whole diff

The diff touches src/game/, src/ui/ and src/analyticsCore.ts, so the table applies.

Item Result What was checked Findings and resolution
HP-1 clear newTowerModal commit handler: a click in the New Tower dialog, once per founding. onToggleAutoBridge: the Settings checkbox change listener (uiSettings.ts:80), once per user flip. AppActionName: a type union with no runtime cost. Neither function is called per frame, per tick or per command. none
HP-2 clear No loops or scans added. querySelector runs once per click on the open dialog. none
HP-3 clear One small {action, detail} object per click, built inside trackAppAction. none
HP-4 n/a The diff adds no sort or ordered rebuild. none
HP-5 n/a The diff adds no container or hashing. none
HP-6 n/a The diff adds no lookup by id or removal. none
HP-7 n/a No algorithm was ported or inherited. The test block move is test code. none
HP-8 n/a No cache was added, dropped or bypassed. none
HP-9 n/a HP-2 to HP-6 have no findings. none
HP-10 clear Engine results are unchanged. The switch still shows the engine's answer, and analytics only reads that value. none
HP-11 n/a The WASM boundary, the hosts and the build are untouched. flipAutoBridge is called once, as before. none
HP-12 clear No per-frame render or HUD work. The dialog template changes one attribute. none

Verdict: CONDITIONAL GO at 1088a9b42f52738d1e100c8ed67b79ade65482f8. The only condition is finding 1. After that commit, check that its diff touches only that line before arming auto-merge.

Reviewed against Verticopolis conventions (.github/copilot-instructions.md).


Generated by Claude Code

@maniator
maniator force-pushed the claude/project-thread-4u57k0 branch 2 times, most recently from 4d3ff70 to 52f0af8 Compare November 15, 2026 23:40
@maniator
maniator enabled auto-merge November 15, 2026 23:40
@maniator
maniator force-pushed the claude/project-thread-4u57k0 branch from 52f0af8 to 65e328e Compare November 15, 2026 23:48
@maniator
maniator disabled auto-merge November 15, 2026 23:50
@maniator
maniator force-pushed the claude/project-thread-4u57k0 branch 2 times, most recently from 6e04a28 to e87f63e Compare November 15, 2026 23:53

Copy link
Copy Markdown
Owner Author

The smoke failure on 65e328e was this PR's. After the rebase onto #2346/#2347, src/analyticsCore.ts reached 503 lines (main has it at 500), so the 500-line file-size guard failed.

Fixed in e87f63e. I folded the two new AppActionName codes into the preference-toggles group (| "mute" | "reduced_motion" | "steady_clock" | "found_bridged" | "auto_bridge" on one line, plus a two-line comment). The file is now 499 lines. No names or types changed. Locally, fileSize.guard and analyticsDataMap pass and typecheck is clean.

Auto-merge stays off while the 4.5.1 release PR (#2348) is open.


Generated by Claude Code

The New Tower window's "Bridge floors between rooms" box now starts
unticked, so a new Modern tower is founded unbridged unless the player
ticks it. Existing towers keep the setting their save carries; the
engine and save format are unchanged.

Adds two app_action codes, found_bridged (the box at a Modern founding)
and auto_bridge (the Settings switch), with their data map rows and a
dashboard tile, and updates the help pages that described bridging as
on by default. The New Tower dialog tests move into their own file.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Ms7trXSDbcT7Vci3GZYmQw
Rendered in the pinned mcr.microsoft.com/playwright:v1.61.1-jammy image
(ONLY=first-run); the Classic shot in the same scene came out
byte-identical.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Ms7trXSDbcT7Vci3GZYmQw
@maniator
maniator force-pushed the claude/project-thread-4u57k0 branch from 711c95a to 7d7bed2 Compare November 16, 2026 00:52
@maniator
maniator merged commit de1aa93 into main Nov 16, 2026
47 checks passed
@maniator
maniator deleted the claude/project-thread-4u57k0 branch November 16, 2026 01:07

This branch was successfully deployed

1 active deployment
Preview — 7d7bed2a Deployed Nov 16, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants