fix(templates): enforce consumed 3D config - #3
Merged
Conversation
added 3 commits
August 4, 2026 18:46
The three.js renderer sizes from its container and never consumes the inherited 2D reference dimensions. Removing the unused leaves gives both standalone core3d and threed_basic a zero-dead-config baseline.
Generated v1.1 code duplicated fog, pickup, and count values. Make the builder keep one canonical path per runtime value, remove superseded aliases, and record the leaf-to-consumer map in GDD completion notes.
The universal GDD reminder contradicted threed_basic zero-dead-config rules by forbidding deletion of inherited fields. Keep the Phaser reminder unchanged while requiring consumed, single-source leaves for 3D.
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.
结论
threed_basicv1.2 removes dead 3D configuration and makes the builder contract require every emitted config leaf to have a runtime consumer. A real POST-produced game verifies the versioned template path end to end.Production evidence
three-js-prism-causeway-3d-v1-2-slug-pri(3a179ad6fa430dc3)three-js-crystal-switchback-3d-v1-2-5-sc(8a7e3739cc6d0e80)CollisionResolver.tsandInputController.tsare byte-identical to this branch's templatesRoot cause and change
The production classifier/GDD used a versioned worktree, while scaffold and Phase 5 still referenced the canonical OpenGame checkout. That allowed a generated game to consume stale templates and rewrite
CollisionResolver.This PR keeps the frozen-layer change small:
screenSizeleaves from both 3D config fragments;threed_basicbuilder manuals;generate_gddguidance for 3D while preserving the prior Phaser reminder verbatim;The protocol-side root-cause fix is in non-Git
/Users/admin/Desktop/opengame-kimi/agent/opengame.md: scaffold paths now honorGAME_TEMPLATES_DIR/GAME_DOCS_DIR, Phase 3 reads the workspace asset protocol, and Phase 4 requires zero dead 3D config. It cannot be represented honestly in this repository's Git diff.Verification
npm run build --workspace=packages/corenpm test --workspace=packages/coregenerate-gddtestsmake checkin opengame-kimicore3dbuild + WebGL/non-black/console-zero smokecore3d + threed_basicbuild/self-checkneon-flotillaregressionEnter: WebGL/non-black, console zero, ESC pause/resumeFrozen-layer delta
agent-test/templates/core3d/src/gameConfig.jsonscreenSizeobjectagent-test/templates/modules/threed_basic/src/gameConfig.jsonscreenSizeoverridesagent-test/docs/modules/threed_basic/{design_rules,template_api,threed_basic}.mdpackages/core/src/tools/generate-gdd.tspackages/core/src/tools/generate-gdd.test.tsRisk and rollback
Risk is limited to builder guidance and deletion of proven-unused 3D config. Phaser output is covered by an explicit regression test and real smoke. Roll back the three Conventional Commits independently in reverse order if needed.
Upstream dependency: this iteration builds on the 3D v1/v1.1 series tracked in upstream PRs leigest519#47 and leigest519#48.