Jungle Rabbit: drop prewarmScene, which the preloader now does - #1673
Merged
Merged
Conversation
`prewarmScene` drew the whole scene once behind the loading screen to pay the first-draw shader cost early. It shipped in #1670 as an unwired export — with a `// TEMP` hold left in it that waits 90 frames where the logic wants 2. My pre-commit sweep grepped for TODO/FIXME/XXX/HACK and matched none of them. It is redundant as well as dead now. `renderer.prewarm()` runs from `loader.preload()` by default, so this example gets the engine's programs built behind the loading screen without doing anything, and the stall the function was written for is covered by the transition fade that #1671 made render. Its own documented blocker also still stands: the built-in progress bar is a world-space renderable, so a 3D warm-up scene buries it. 195 lines, plus the eight imports that existed only for it and a comment in `createGame.ts` that described the loading screen popping its logo out on `LOADER_COMPLETE` — which stopped being true when that teardown moved to stage destroy. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01NGvtaUNATVCVxD2qcbiY4t
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.
prewarmScenedrew the whole scene once behind the loading screen to pay the first-draw shader cost early. It shipped in #1670 as an unwired export, with a debug leftover in it:My pre-commit sweep grepped for
TODO|FIXME|XXX|HACKand matched none of those, which is how it got in.Why delete rather than wire it up
It is now redundant as well as dead:
renderer.prewarm()(Renderer: prewarm the built-in shaders during preload #1672) runs fromloader.preload()by default, so this example already gets the engine's programs built behind the loading screen without doing anythingDefaultLoadingScreen's progress bar is a world-space renderable, so a 3D warm-up scene drawn beside it buries it under the depth bufferKeeping a function that advertises itself as working-but-unused is worse than not having it.
What goes
195 lines, the eight imports that existed only for it, and a comment in
createGame.tsdescribing the loading screen popping its logo out onLOADER_COMPLETE— which stopped being true when that teardown moved to stage destroy.Verified: the example renders with no page errors, types and lint clean.
🤖 Generated with Claude Code
https://claude.ai/code/session_01NGvtaUNATVCVxD2qcbiY4t