Repository navigation
Fix code audit findings: stuck loading, audio interruptions, save format, collisions - #21
Merged
Merged
Conversation
- Player car is exempt from the in-race load hold and loaded on demand; a failed load shows an error with retry instead of a placeholder model. - Loading screen has a Menu button and a 60 s limit; waits stop on cancel. - Audio interruptions stop sound playback safely and pause the race; the same music track resumes after returning from the background. - Race rewards are settled when the player crosses the line. - Backgrounding during loading pauses the race once it is revealed. - Nothing runs under the track error screen. - Unreadable campaign save is backed up before a new game overwrites it; an unknown car no longer resets the whole profile. - Menu frame stats no longer grow for the whole session. - CI also builds Family and Release; README states UI tests run locally. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Add a format version and a custom decoder: missing keys fall back to defaults and unknown upgrade names are skipped instead of failing the whole save (which made the app start a new game and overwrite progress). Encoding is unchanged, so existing saves stay compatible. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The app swaps the catalog and starterCar for local models, which silently changed rival strength on every track. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…voidance - Rivals never wreck the player or each other; such hits fall back to the normal side damping or rear speed exchange (no more 20 -> 54 m/s jumps). - Wreck restart speed is reached over 0.3 s instead of in one step. - Walls, pickups and near misses use each car's own shape. - AI and autopilot steer around a wrecked car ahead. - Tests for the wall wreck threshold and rival/rival, rival/player hits. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The fixed delay often elapsed before the race screen opened, so the test passed on the old code too. Now the car starts loading exactly in the state that used to hang (race screen open, six cars loaded); the old code times out, the fix starts the race. Tests start from car 0, since the car picked in a previous run stays in the saved profile. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Fixes from the 21.10 code review (state 695114c). Each finding was first confirmed in the code.
App
RaceCore
versionfield and a tolerant decoder. Missing fields get defaults and unknown upgrades are skipped; the encoded format is unchanged apart fromversion.CI and README
Tests
swift test: 79 tests, 0 failures (65 before; the new tests failed on the old code).LoadingUITests: car picked before it loaded, failed car load, backgrounding during loading. The stuck-loading test hangs on the old code (over 100 s) and starts the race in 2.8 s with the fix.Not changed: the store/demo model (a product decision), the memory and rendering items (B11–B14), test isolation (T2).
🤖 Generated with Claude Code