Skip to content

BDSP AutoStory: pick the language and the player's look in the new-game intro - #305

Draft
dayfine wants to merge 20 commits into
bdsp/center-run-settlefrom
bdsp/autostory-intro-picks
Draft

dayfine wants to merge 20 commits into
bdsp/center-run-settlefrom
bdsp/autostory-intro-picks

Conversation

@dayfine

@dayfine dayfine commented Nov 9, 2026 •

Copy link
Copy Markdown
Owner

Depends on #375 (base bdsp/center-run-settle, the consolidated BDSP console stage; the diff shows only this change).

The new-game intro now picks the game's language and the player's look on their menus instead of pressing A on whatever the cursor starts on, so 00.00 can run from a fresh save with no one at the console.

  • NintendoSwitch/Programs/MenuCursor (new, nothing BDSP in it, meant for PLZA's new game too): the D-pad presses from one item of a list or grid to another, none across an edge, so they hold whether the menu wraps or not.
  • PokemonBDSP_AutoStory_IntroMenuDetector (new): both intro menus are grids of flat cards, the cursor's blue and the rest grey (lab-B frames 2026-11-09). It reads which card the cursor is on: the language select's 2 x 5 buttons, and the look select's 2 x 4 portraits.
  • The intro treats each select as its own screen: read the cursor, move to the pick, read again (up to 3 tries), then A. A screenshot of the cursor on each pick goes to the StepTrace folder. The player's name keyboard showing with a pick still to make fails the intro.
  • Language comes from the existing Language option (Japanese is picked on its kana button). New option Player's look: Model N is portrait N-1, row by row: 1 Lucas light, 2 Lucas dark, 3 Dawn dark-haired, 4 Dawn dark; 5 Lucas blond, 6 Lucas brown, 7 Dawn blond, 8 Dawn brown-haired.

Console B: the language pick worked at f84574a (game in French). The look pick by detector is not run yet.

Testing

  • Headless runner (local scratch merge of upstream/headless-tests): NintendoSwitch::MenuCursor, the BDSP new-game intro tests and "intro menu screenshots", 10/10 pass with the lab frames copied into the local unit-test resources (each select reads cursor 0; the frames before and after the look select read neither). The frames still need adding to CommandLineTests under PokemonBDSP/AutoStory/: LanguageSelect-20261109.png, LookSelect-20261109.png, LookSelectBefore-20261109.png, LookSelectAfterA-20261109.png; without them that test is skipped.
  • ninja SerialPrograms builds on macOS; Code Health has 0 failures against the base.

🤖 Generated with Claude Code

https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss

dayfine and others added 16 commits November 9, 2026 10:35
…me intro

The intro pressed A on every screen, so it took the language the cursor
starts on and the first look (Lucas); run 3 (French, Dawn) needed both
picked by hand.

NintendoSwitch/Programs/MenuCursor: the D-pad presses from one item of a
list or grid to another, none across an edge, so they hold whether or
not the menu wraps; and a D-pad probe (press, opposite press, measure)
that tells a screen with a cursor from one without, for menus no
detector knows. Nothing in it is BDSP's, for PLZA's new game too.

BDSP: the language select's order and the appearance grid's shape are
data. Until a pick is made, screens that would take A get a probe
first: a list that moves up/down but not sideways takes the language
pick, a grid that moves sideways takes the look pick, then A. The
player's keyboard with a pick still to make fails. New options: Switch
language (where the list's cursor starts) and Player's look (models
1-8, PlayerModelOption's icons). Defaults keep the old behavior.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
The language select is a 2 x 5 grid of buttons, not a 9-item list
(lab-B frame, 2026-11-09): English, Espanol, Francais, Deutsch, Italiano
on the left; Japanese kana and kanji, Korean, Simplified and Traditional
Chinese on the right; the cursor starts on English. Right moves on it,
so the probe rule took it for the appearance grid.

A detector reads it from its ten buttons (grey, the cursor's blue) and
which one the cursor is on. The intro classifies it as its own screen,
moves from the read cursor to the game's language, reads it again (up
to three tries), then A. The look grid keeps the D-pad probe, only after
the language is picked. The Switch language option is gone: the cursor
is read, not assumed. The wrong-game guard is back to 60 s.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
A missing negative screenshot no longer skips the whole test, and a
black screen must not read as the language select.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
The Right/Left probe never saw the look select's cursor move (console B,
2026-11-09: 20 probes, then the name keyboard). The look select is a
2 x 4 grid of portraits, the cursor's background blue and the others
grey, like the language select's buttons (lab-B frame).

The language detector becomes IntroMenuDetector, one card-grid reader
with a layout per menu: language buttons, and two background strips
beside each portrait's face. The intro classifies the look select as
its own screen and picks on it as on the language select: read the
cursor, move to the chosen look, read again (3 tries), then A.

Model N is portrait N - 1, row by row, matching PlayerModelOption's
icons: 1 Lucas light, 2 Lucas dark, 3 Dawn dark-haired, 4 Dawn dark;
5 Lucas blond, 6 Lucas brown, 7 Dawn blond, 8 Dawn brown-haired. The
option text says so. The D-pad probe is gone from MenuCursor: nothing
uses it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
Brings in the base stack's code-health splits, including the split of
NewGame.h into IntroSteps.h and IntroProbe.h.

Conflict resolutions:
- NewGame.h: keeps this branch's language/look picks (grids, IntroPicks,
  pick moves) and detail::intro_start; the intro state machine moved to
  the base's IntroSteps.h and IntroProbe.h, and NewGame.h no longer
  needs its header_symbols allow tag.
- IntroSteps.h: this branch's new steps (FAIL_PICK_MISSED, PICK_LANGUAGE,
  PICK_LOOK), the pending-pick fields, string_view screens and its detail
  namespace for the limits, record_intro_step and note_intro_screen; the
  allow tag is dropped, as detail names are not counted.
- IntroProbe.h: the X/B probe in detail, as this branch had it.
- NewGame.cpp: this branch's menu picking; includes unioned.
- Actions_Tests.cpp: this branch's screen list with the base's const.
- StoryExecutor.h, SourceFiles.cmake: union, cmake block regenerated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
…ro-picks

Brings #128's seam work down through #167 and #226.
Conflict: PokemonBDSP_AutoStory.cpp includes, both NewGame.h (this
branch's IntroPicks) and Actions.h, as lab/dev-bdsp has them.
Semantic: ScreenState gained a field in the base; the language-select
and look-select states pass nullptr for it, as lab/dev-bdsp does.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
…ro-picks

Picks up #226's code-health fixes after the #128 merge. No conflicts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
Retargets onto the consolidated BDSP console stage (#375's branch). No conflicts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
Picks up the consolidated stage's StorySim split and code-health fixes. No conflicts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
@dayfine
dayfine changed the base branch from bdsp/autostory-mine-floaroma-wip to bdsp/center-run-settle November 12, 2026 06:12
Picks up the consolidated stage's test-file split. No conflicts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
dayfine and others added 2 commits November 12, 2026 07:01
…not a crash

gray_box() sorted and indexed an empty vector when the box was outside the
frame or the image empty (SIGSEGV at 0x0, 2026-11-12). read_move_name now
returns "" for it and the menu falls back to the PP guess.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
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.

1 participant