Repository navigation
AutoStory: start gate before a story run presses anything - #396
Merged
Merged
Conversation
prepare_story_start() now logs the checkpoint that starts, then runs the game's preflight (video alive, controller ready, game not on HOME); one that fails returns precondition_failed with nothing pressed. A shared console reader lends the same preflight to BDSP and FRLG. story_first_save_allowed(): only a new game saves at its first checkpoint's start; after a load the save is there, and from the game as it is the place is unconfirmed (console B, 2026-11-11 13:32). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
StoryStartGate.h mixed the start enum, the preflight reading, its failure code and two start rules. StoryPreflight is now the one concept in its own header: the preflight hook's reading, its check() and its FAILURE code. StoryStart and story_first_save_allowed() go back to Pokemon_StoryRun.h with the start sequence; story_start_name() is internal to it. Behavior is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
Keeps Pokemon_StoryRun.h at its symbol limit. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
dayfine
added a commit
that referenced
this pull request
Nov 11, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
dayfine
added a commit
that referenced
this pull request
Nov 11, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
StoryStart moves to Types/Pokemon_StoryStart.h. The console reader joins StoryPreflight as StoryPreflight::read(); the picture check is internal. Behavior unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On console B (2026-11-11 13:32) a BDSP run started with the game on the HOME menu: its first checkpoint saved anyway, pressed X/R/ZL on HOME as a blind fallback, then "loaded" nothing. This adds a preflight hook to the shared story run's start:
prepare_story_start()logs the checkpoint that actually starts, then runs the game'sStoryGameHooks::preflightand returnsStoryPreflight::FAILUREwith nothing pressed when itscheck()fails (video alive, controller ready, game not on HOME).StoryPreflightholds the readings,check()andStoryPreflight::read(), the console reader both games lend;story_first_save_allowed(), besideStoryStartin Types/Pokemon_StoryStart.h, says only a new game saves at its first checkpoint's start (after a load the save is already there; from the game as it is the place is unconfirmed). FROM_SAVE still always loads and checks the place. Tested with the StoryRun suite (new cases red first) via SerialProgramsTests; BDSP and FRLG wiring follows on #381 and #382.🤖 Generated with Claude Code
https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss