mirror of
https://github.com/PlayableIntelligence/game-creator.git
synced 2026-09-19 07:34:10 +08:00
bc0ca6e08b
Add the 3D parallel to the 2D pixel art pipeline: - scripts/find-3d-asset.mjs: search & download GLBs from Sketchfab, Poly Haven, Poly.pizza - skills/game-3d-assets: full skill with AssetLoader (SkeletonUtils.clone), OrbitControls camera, fadeToAction animation crossfade, camera-relative WASD, per-model facingOffset - skills/add-3d-assets: user-invocable /add-3d-assets command - 3d-character-library/: 4 animated GLBs (Soldier, Xbot, Robot, Fox) with manifest.json - templates/threejs-3d: updated with animated character controller, OrbitControls, AssetLoader, third-person camera follow pattern - examples/3d-asset-test: working demo with character cycling (C key), preloading, world props (barrels, crates), animated enemies - make-game pipeline: Step 1.5 now works for 3D — character selection from library, world object search via find-3d-asset.mjs, full subagent instructions Key learnings baked into skill: - SkeletonUtils.clone() is mandatory for skeletal models (regular .clone breaks → T-pose) - Model facing varies: facingOffset per character (Soldier -Z needs +PI, Robot +Z needs 0) - OrbitControls + target-follow is the proven third-person pattern (from official three.js example) - Preload all GLBs with Promise.all on startup for instant character cycling Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>