evomeme-dev 0.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (101) hide show
  1. package/README.md +247 -0
  2. package/bin/evomeme +28 -0
  3. package/dist/canvas-public/app.js +5857 -0
  4. package/dist/canvas-public/cycle-detect.js +166 -0
  5. package/dist/canvas-public/index.html +395 -0
  6. package/dist/canvas-public/sequence-sheet.js +59 -0
  7. package/dist/canvas-public/smart-split.js +185 -0
  8. package/dist/canvas-public/styles.css +2276 -0
  9. package/dist/canvas-public/vendor/painterro.min.js +3 -0
  10. package/dist/index.js +25586 -0
  11. package/package.json +69 -0
  12. package/skills/evomeme-cloud-fs/SKILL.md +176 -0
  13. package/skills/evomeme-cloud-fs/agents/openai.yaml +7 -0
  14. package/skills/evomeme-cover/SKILL.md +132 -0
  15. package/skills/evomeme-cover/agents/openai.yaml +7 -0
  16. package/skills/evomeme-game-maker/SKILL.md +214 -0
  17. package/skills/evomeme-game-maker/agents/openai.yaml +4 -0
  18. package/skills/evomeme-login/SKILL.md +92 -0
  19. package/skills/evomeme-login/agents/openai.yaml +7 -0
  20. package/skills/evomeme-native-bridge-sdk/SKILL.md +286 -0
  21. package/skills/evomeme-native-bridge-sdk/agents/openai.yaml +7 -0
  22. package/skills/evomeme-tos-upload/SKILL.md +46 -0
  23. package/skills/evomeme-tos-upload/agents/openai.yaml +4 -0
  24. package/skills/game-art/SKILL.md +121 -0
  25. package/skills/game-art/agents/openai.yaml +7 -0
  26. package/skills/game-asset-image-generator/SKILL.md +104 -0
  27. package/skills/game-asset-image-generator/agents/openai.yaml +7 -0
  28. package/skills/game-asset-image-generator/references/background.md +32 -0
  29. package/skills/game-asset-image-generator/references/static-game-assets.md +38 -0
  30. package/skills/game-audio/SKILL.md +82 -0
  31. package/skills/game-audio/agents/openai.yaml +4 -0
  32. package/skills/game-audio/references/bgm-cdn.md +127 -0
  33. package/skills/game-audio/references/sfx-cdn.md +77 -0
  34. package/skills/game-demo/SKILL.md +103 -0
  35. package/skills/game-demo/agents/openai.yaml +7 -0
  36. package/skills/game-maker/SKILL.md +111 -0
  37. package/skills/game-maker/agents/openai.yaml +4 -0
  38. package/skills/game-test/SKILL.md +58 -0
  39. package/skills/game-test/agents/openai.yaml +7 -0
  40. package/skills/game-test/references/checklists/playtest-qa.md +12 -0
  41. package/skills/game-ui/SKILL.md +169 -0
  42. package/skills/game-ui/agents/openai.yaml +4 -0
  43. package/skills/game-ui/references/checklists/game-ui-quality.md +14 -0
  44. package/skills/game-ui/references/checklists/hud-readability.md +12 -0
  45. package/skills/game-ui/references/checklists/mobile-input.md +12 -0
  46. package/skills/game-ui/references/checklists/responsive-ui-fit.md +12 -0
  47. package/skills/game-ui/references/ui-patterns.md +140 -0
  48. package/skills/game-ui/references/ui-prompt-templates.md +63 -0
  49. package/skills/phaser-2d-game/SKILL.md +127 -0
  50. package/skills/phaser-2d-game/agents/openai.yaml +7 -0
  51. package/skills/phaser-2d-game/references/engine-performance.md +64 -0
  52. package/skills/phaser-2d-game/references/engine-physics.md +139 -0
  53. package/skills/phaser-2d-game/references/engine-runtime.md +129 -0
  54. package/skills/phaser-2d-game/references/engine-spritesheets.md +99 -0
  55. package/skills/phaser-2d-game/references/engine-tilemaps.md +80 -0
  56. package/skills/phaser-2d-game/references/file-structure.md +94 -0
  57. package/skills/phaser-2d-graphics-builder/SKILL.md +68 -0
  58. package/skills/phaser-2d-graphics-builder/agents/openai.yaml +7 -0
  59. package/skills/phaser-2d-graphics-builder/assets/scorecard-anchors/scene-1.jpeg +0 -0
  60. package/skills/phaser-2d-graphics-builder/assets/scorecard-anchors/scene-2.jpeg +0 -0
  61. package/skills/phaser-2d-graphics-builder/assets/scorecard-anchors/scene-3.jpg +0 -0
  62. package/skills/phaser-2d-graphics-builder/references/checklists/compose-quality.md +10 -0
  63. package/skills/phaser-2d-graphics-builder/references/checklists/performance-safe-visual-detail.md +9 -0
  64. package/skills/phaser-2d-graphics-builder/references/checklists/premium-game-quality-gate.md +15 -0
  65. package/skills/phaser-2d-graphics-builder/references/checklists/sprite-quality.md +10 -0
  66. package/skills/phaser-2d-graphics-builder/references/checklists/technical-art-quality.md +9 -0
  67. package/skills/phaser-2d-graphics-builder/references/checklists/visual-scorecard.md +9 -0
  68. package/skills/phaser-2d-graphics-builder/references/compose-recipes.md +71 -0
  69. package/skills/phaser-2d-graphics-builder/references/graphics-prompt-templates.md +33 -0
  70. package/skills/phaser-2d-graphics-builder/references/implementation-blueprint.md +82 -0
  71. package/skills/phaser-2d-graphics-builder/references/sprite-recipes.md +90 -0
  72. package/skills/phaser-2d-graphics-builder/references/technical-art.md +67 -0
  73. package/skills/phaser-2d-graphics-builder/references/vfx-recipes.md +67 -0
  74. package/skills/phaser-2d-graphics-builder/references/visual-scorecard.md +129 -0
  75. package/skills/threejs-3d-game/SKILL.md +113 -0
  76. package/skills/threejs-3d-game/agents/openai.yaml +7 -0
  77. package/skills/threejs-3d-game/references/engine-asset-pipeline.md +116 -0
  78. package/skills/threejs-3d-game/references/engine-audio.md +70 -0
  79. package/skills/threejs-3d-game/references/engine-input-camera.md +84 -0
  80. package/skills/threejs-3d-game/references/engine-performance.md +96 -0
  81. package/skills/threejs-3d-game/references/engine-physics.md +142 -0
  82. package/skills/threejs-3d-game/references/engine-runtime.md +199 -0
  83. package/skills/threejs-3d-game/references/file-structure.md +353 -0
  84. package/skills/threejs-aaa-graphics-builder/SKILL.md +62 -0
  85. package/skills/threejs-aaa-graphics-builder/agents/openai.yaml +7 -0
  86. package/skills/threejs-aaa-graphics-builder/assets/scorecard-anchors/scene-1.jpg +0 -0
  87. package/skills/threejs-aaa-graphics-builder/assets/scorecard-anchors/scene-2.jpg +0 -0
  88. package/skills/threejs-aaa-graphics-builder/assets/scorecard-anchors/scene-3.jpg +0 -0
  89. package/skills/threejs-aaa-graphics-builder/references/checklists/aaa-game-quality-gate.md +23 -0
  90. package/skills/threejs-aaa-graphics-builder/references/checklists/aaa-visual-scorecard.md +19 -0
  91. package/skills/threejs-aaa-graphics-builder/references/checklists/material-lighting-quality.md +14 -0
  92. package/skills/threejs-aaa-graphics-builder/references/checklists/performance-safe-visual-detail.md +14 -0
  93. package/skills/threejs-aaa-graphics-builder/references/checklists/procedural-model-quality.md +15 -0
  94. package/skills/threejs-aaa-graphics-builder/references/checklists/technical-art-quality.md +17 -0
  95. package/skills/threejs-aaa-graphics-builder/references/graphics-prompt-templates.md +236 -0
  96. package/skills/threejs-aaa-graphics-builder/references/implementation-blueprint.md +161 -0
  97. package/skills/threejs-aaa-graphics-builder/references/model-recipes.md +146 -0
  98. package/skills/threejs-aaa-graphics-builder/references/render-recipes.md +90 -0
  99. package/skills/threejs-aaa-graphics-builder/references/shader-cookbook.md +292 -0
  100. package/skills/threejs-aaa-graphics-builder/references/technical-art.md +167 -0
  101. package/skills/threejs-aaa-graphics-builder/references/visual-scorecard.md +147 -0
@@ -0,0 +1,236 @@
1
+ # Three.js AAA Graphics Prompt Templates
2
+
3
+ Reusable prompt templates packaged with this skill. Use only templates relevant to the current request, and adapt placeholders to the game/project context.
4
+
5
+ ---
6
+
7
+ # AAA Graphics Production Pass Prompt
8
+
9
+ Use `threejs-aaa-graphics-builder` to upgrade this Three.js game from basic prototype visuals to premium browser-game graphics.
10
+
11
+ Current screenshot blockers:
12
+ -
13
+
14
+ Target art direction:
15
+ -
16
+
17
+ Required pass:
18
+ - Score current screenshots with `visual-scorecard.md`.
19
+ - Add or improve the graphics architecture from `implementation-blueprint.md`.
20
+ - Add the technical art brief from `technical-art.md`: material kit, shader/VFX purpose, instancing/LOD/culling, imported asset cleanup, renderer budget, mobile tradeoffs.
21
+ - Build material library, procedural texture/decal helpers, model factories, world prop kit, VFX system, lighting/render pipeline, and diagnostics.
22
+ - Prefer procedural model factories or user-provided GLB/FBX for high-value hero/player, character, creature, vehicle, building, weapon, pickup, or boss forms.
23
+ - For 2D concepts, texture references, decals, logos, icons, GUI art, skies, or backgrounds: prefer procedural/CSS/canvas; use user-supplied images or remote MCP `evomeme_generate_game_image` — local image generator skill removed.
24
+ - Upgrade hero/player, obstacles/enemies, rewards/interactables, world kit, HUD cohesion, lighting, effects, and renderer metrics.
25
+
26
+ Do not count as completion:
27
+ - Recolored boxes/cones/spheres.
28
+ - Glow, fog, or darkness hiding missing detail.
29
+ - One improved object while world/obstacles/UI remain placeholders.
30
+ - Idle/showroom screenshots only.
31
+ - Missing renderer diagnostics after visual density changes.
32
+
33
+ Verification:
34
+ - Capture active gameplay desktop and mobile screenshots.
35
+ - Report visual score before/after.
36
+ - Report draw calls, triangles, geometries, textures, material count, DPR cap, shadow/post settings, and instancing/LOD/culling decisions when available.
37
+ - Run build, browser, console/page error, nonblank canvas, interaction, and responsive checks.
38
+ - Continue until every scorecard category is at least 2, or report exactly why the target was not reached.
39
+
40
+ ---
41
+
42
+ # Before/After Visual Critique Prompt
43
+
44
+ Use `threejs-aaa-graphics-builder` to critique this Three.js game's current screenshots with the visual scorecard and produce a prioritized graphics plan.
45
+
46
+ Evidence to gather:
47
+ - Desktop screenshot.
48
+ - Mobile screenshot.
49
+ - Optional before/after screenshots if a pass was already completed.
50
+ - Renderer diagnostics if available.
51
+ - Notes on the game genre, core verb, and target mood.
52
+
53
+ Critique dimensions:
54
+ - Gameplay readability.
55
+ - UI hierarchy and text fit.
56
+ - Procedural model silhouette and fidelity.
57
+ - Material, lighting, shadows, color, and contrast.
58
+ - Camera composition and motion clarity.
59
+ - Mobile framing and touch/control readability.
60
+ - Performance risk from proposed upgrades.
61
+
62
+ Output:
63
+ - Pass/fail on whether the game looks polished enough for the current milestone.
64
+ - Top five blockers ordered by player impact.
65
+ - Recommended next skill/phase: `threejs-aaa-graphics-builder`, `game-ui`, `game-test`, or `game-test`.
66
+ - Concrete acceptance criteria for the next pass.
67
+
68
+ ---
69
+
70
+ # Material, Lighting, and Render Quality Pass Prompt
71
+
72
+ Use `threejs-aaa-graphics-builder` for scene-level render quality, material libraries, model materials, geometry factories, and visual scoring.
73
+
74
+ Current problem:
75
+ -
76
+
77
+ Target look:
78
+ -
79
+
80
+ Work areas:
81
+ - Renderer color space, tone mapping, exposure, shadow settings, DPR cap.
82
+ - Key/fill/rim/environment lighting.
83
+ - Material roughness, metalness, emissive accents, vertex colors, generated textures, and decals.
84
+ - Fog, background, post-processing, and feedback effects only where they improve readability.
85
+ - Camera composition and gameplay-distance readability.
86
+
87
+ Constraints:
88
+ - Improve lighting and materials before adding heavy post-processing.
89
+ - Keep threats, pickups, player, and objective readable during motion.
90
+ - Avoid excessive bloom, low-contrast fog, and particle clutter.
91
+ - Re-measure renderer info if visual complexity changes.
92
+
93
+ Verification:
94
+ - Capture desktop and mobile screenshots.
95
+ - Check console/page errors and nonblank canvas pixels.
96
+ - Compare renderer calls/triangles/textures before and after when practical.
97
+ - Play the core loop and confirm effects do not hide gameplay information.
98
+
99
+ ---
100
+
101
+ # Technical Art Pass Prompt
102
+
103
+ Use `threejs-aaa-graphics-builder` for a technical-art pass on this Three.js game.
104
+
105
+ Current visual/performance risk:
106
+ -
107
+
108
+ Target art direction:
109
+ -
110
+
111
+ Required pass:
112
+ - Load `technical-art.md`.
113
+ - Write a technical art brief: hero surfaces, support surfaces, material kit, VFX language, lighting stack, render budget, asset strategy, mobile constraint.
114
+ - Convert art direction into renderable systems: materials, decals/trim, shaders, VFX, LOD, instancing, culling, imported asset cleanup.
115
+ - Make threats, rewards, player state, and objectives readable by shape/motion/value, not color alone.
116
+ - Keep API/generated asset calls out of browser runtime.
117
+
118
+ Verification:
119
+ - Capture active desktop and mobile screenshots.
120
+ - Report renderer diagnostics: calls, triangles, geometries, textures, material count when available, DPR cap, shadow/post settings.
121
+ - Report imported/generated asset diagnostics when relevant: file size, bounds, scale, orientation, collision proxy, triangles/materials/textures/clips when available.
122
+ - Report VFX readability: trigger, duration, player-facing meaning, and reduced-motion concern if applicable.
123
+ - State what was optimized, what was intentionally left rich, and remaining performance risks.
124
+
125
+ ---
126
+
127
+ # Procedural Hero Asset Pass Prompt
128
+
129
+ Use `threejs-aaa-graphics-builder` to create or upgrade a high-fidelity scratch-built Three.js hero asset.
130
+
131
+ Asset brief:
132
+ - Role:
133
+ - Silhouette:
134
+ - Scale:
135
+ - Camera distance:
136
+ - Style references:
137
+ - Performance budget:
138
+
139
+ Requirements:
140
+ - Build a reusable model factory that returns a named `THREE.Group`.
141
+ - Establish a recognizable silhouette before adding small detail.
142
+ - Add secondary and tertiary detail through bevels, trims, panels, ridges, tubes, decals, emissive elements, and material contrast.
143
+ - Add visible subassemblies, not just a few primitives: shell/body, core/cockpit, trims/rails, engines/emitters, decals/surface marks, and state feedback when relevant.
144
+ - Use shared geometries/materials where possible.
145
+ - Use PBR-style materials, shadows, color management, and lighting intentionally.
146
+ - Keep collision or gameplay proxies simpler than the visual mesh.
147
+
148
+ Avoid:
149
+ - Placeholder stacks of primitives.
150
+ - Detail visible only from a showroom camera.
151
+ - Excessive segment counts, unique materials, or draw calls without gameplay value.
152
+ - Glow-only upgrades that leave the silhouette primitive.
153
+
154
+ Verification:
155
+ - Build and run locally.
156
+ - Capture gameplay-camera screenshot and one inspection screenshot if useful.
157
+ - Report renderer info before/after when available.
158
+ - Verify the asset reads clearly at desktop and mobile gameplay distances.
159
+
160
+ ---
161
+
162
+ # Visual Polish Prompt
163
+
164
+ Use `threejs-aaa-graphics-builder` to improve the game's visual clarity and identity.
165
+
166
+ Use focused prompts instead when the main problem is narrower:
167
+ - Use `../../game-ui/references/ui-prompt-templates.md` for HUD/menu/interface quality prompts.
168
+ - Use the procedural hero asset or world prop kit sections in this file for scratch-built model fidelity inside the AAA graphics phase.
169
+ - Use the before/after visual critique section in this file when priorities are unclear.
170
+
171
+ Target feel:
172
+ -
173
+
174
+ Constraints:
175
+ - Keep the game readable during motion.
176
+ - Avoid generic purple gradients, excessive bloom, particle clutter, and static showroom composition.
177
+ - Prefer purposeful lighting, color contrast, silhouettes, material variation, and procedural geometry that supports gameplay.
178
+ - Hand off substantial UI craft to `game-ui`; keep model/world/render construction under `threejs-aaa-graphics-builder`.
179
+ - Keep performance visible while polishing.
180
+
181
+ Verification:
182
+ - Capture before/after screenshots where possible.
183
+ - Check desktop and mobile framing.
184
+ - Confirm the game remains interactive and no console errors were introduced.
185
+
186
+ ---
187
+
188
+ # World Prop Detail Kit Pass Prompt
189
+
190
+ Use `threejs-aaa-graphics-builder` to create a reusable procedural prop/detail kit for this Three.js game's world.
191
+
192
+ World role:
193
+ -
194
+
195
+ Kit requirements:
196
+ - Define 4-8 reusable prop factories with shared materials.
197
+ - Include scale variants, color/material variants, and clear placement rules.
198
+ - Use instancing or shared geometry/materials for repeated details.
199
+ - Add visual detail that supports navigation, danger, reward, or atmosphere.
200
+ - Keep the kit coherent with the existing game UI and world lighting.
201
+ - For city/runner worlds, include skyline modules with setbacks/window bands/roof details, foreground speed props, track hardware, signage/cables/supports, and distant parallax layers.
202
+
203
+ Performance constraints:
204
+ - Avoid unique material explosions.
205
+ - Keep repeated props instanced or pooled when practical.
206
+ - Track draw calls, triangles, geometries, textures, and frame impact.
207
+
208
+ Verification:
209
+ - Capture before/after screenshots from gameplay camera.
210
+ - Check desktop and mobile readability.
211
+ - Report renderer diagnostics.
212
+ - Confirm no console/page errors and no obvious collision/occlusion issues.
213
+ - If the world is still dominated by stretched boxes, continue the prop-kit pass.
214
+
215
+ ---
216
+
217
+ # Fresh-Eyes Scorecard Review Prompt
218
+
219
+ Use for the independent review pass required by `visual-scorecard.md` for premium/AAA/showcase claims. Give the reviewer ONLY the inputs below — no build history, no prior scores, no description of the work performed.
220
+
221
+ Inputs:
222
+ - The COMPLETE screenshot capture set — every captured state, desktop and mobile, never a hand-picked subset: <paths>
223
+ - Scorecard rubric: `visual-scorecard.md`
224
+ - Calibration anchors: `threejs-aaa-graphics-builder/assets/scorecard-anchors/`
225
+ - Inspector metrics JSON: <paths>
226
+
227
+ Task:
228
+ - Score all ten scorecard categories from the screenshots alone, using the 0-3 anchors and calibration images.
229
+ - Cross-check scores against the metrics (colorEntropyBits, edgeDensity, luminance.contrast, dominantColorShare, renderBudget) and flag any score the numbers contradict.
230
+ - List every automatic failure you can see in the screenshots.
231
+ - Do not give benefit of the doubt: if a surface could be a 1 or a 2, score it 1 and say what visible change would earn the 2.
232
+
233
+ Report:
234
+ - Ten category scores with one-sentence visual evidence each.
235
+ - Automatic failures observed.
236
+ - The three highest-impact changes to raise the lowest scores.
@@ -0,0 +1,161 @@
1
+ # AAA Graphics Implementation Blueprint
2
+
3
+ Use this when a Three.js game reads as basic even after it is playable. The goal is a production graphics architecture that can be iterated, scored, profiled, and reused. For premium/AAA/showcase work, also load `technical-art.md` and treat the technical art brief and budget as part of the graphics architecture.
4
+
5
+ ## Recommended Ownership
6
+
7
+ Directory layout follows `../threejs-3d-game/references/file-structure.md`. Place graphics modules under `src/game/three` (pure Three, no React) and `src/game/assets` (manifest / import registry). Wire lighting, post, and VFX from `GameCanvas` `useFrame` / R3F scene tree — do not create a parallel imperative `src/systems` game loop.
8
+
9
+ ```text
10
+ src/game/assets/MaterialLibrary.ts
11
+ src/game/assets/ProceduralTextures.ts
12
+ src/game/assets/DecalShapes.ts
13
+ src/game/assets/ModelDiagnostics.ts
14
+ src/game/assets/ImportedAssetRegistry.ts
15
+ src/game/assets/manifest.ts
16
+ src/game/three/modelFactories/HeroFactory.ts
17
+ src/game/three/modelFactories/ObstacleFactory.ts
18
+ src/game/three/modelFactories/RewardFactory.ts
19
+ src/game/three/modelFactories/WorldPropKit.ts
20
+ src/game/three/LightingRig.ts
21
+ src/game/three/RenderPipeline.ts
22
+ src/game/three/VfxSystem.ts
23
+ src/game/three/WorldArtDirector.ts
24
+ src/game/three/QualityDiagnostics.ts
25
+ src/ui/components/GameCanvas.tsx # R3F mount + useFrame orchestration
26
+ ```
27
+
28
+ Keep these boundaries lightweight. In small projects, a single file can contain multiple factories, but the concepts must remain separate: materials, authored geometry, repeated props, effects, render settings, and diagnostics.
29
+
30
+ ## Hybrid Asset Pipeline
31
+
32
+ Choose the asset path per surface:
33
+
34
+ - Procedural Three.js: hero forms, repeated detail, simple props, rails, track parts, decals, collision proxies, VFX geometry, debug-friendly primitives.
35
+ - User-provided / remote MCP / procedural 2D: concept sheets, texture references, trim sheets, decals, icons, logos, skies, backgrounds, UI art; user-provided GLB/FBX for heroes when available.
36
+ - Hybrid: 2D reference (user/remote/procedural) -> procedural 3D factory or user GLB import -> procedural collision/VFX/prop kit -> visual scorecard.
37
+
38
+ Prefer procedural authorship or user-provided models.
39
+
40
+ Use user-provided GLB/FBX when fidelity will materially improve the active screenshot. Keep repeated small props as instancing/procedural kits.
41
+
42
+ Before finishing a premium graphics pass, note the chosen source per high-value surface (procedural / hybrid / user-provided / audio skill) and the outputs or real blocker for each surface.
43
+
44
+ ## Production Surfaces
45
+
46
+ A premium pass must touch every weak visible surface:
47
+
48
+ - Hero/player: authored silhouette, state feedback, decals/trim, readable front/up/side, collision proxy.
49
+ - Hazards/enemies: at least three distinct silhouettes with telegraphs and material cues.
50
+ - Rewards/interactables: at least two forms with collection states and motion/VFX hooks.
51
+ - World kit: foreground, playable lane/arena, midground, background/parallax, set dressing, scale cues.
52
+ - Materials/textures: shared PBR/stylized material library, procedural panel lines, noise, trim, wear, emissive masks.
53
+ - Lighting/render: color space, tone mapping, exposure, shadows/contact, fog/depth, post-processing discipline.
54
+ - VFX/motion: event-driven bursts, trails, impact rings, speed lines, shield/boost states, pickup/fail feedback.
55
+ - UI/world cohesion: UI colors, icons, alerts, and meters echo gameplay materials and status colors.
56
+ - Diagnostics: renderer counts, material/geometry/texture counts, screenshots, scorecard.
57
+
58
+ For imported generated 3D assets, also require downloaded GLB/PBR output, import wrappers with scale/pivot/bounds, simple collision proxies, animation clips when relevant, and triangle/material/texture/file-size diagnostics.
59
+
60
+ ## Technical Art Contract
61
+
62
+ Before broad implementation, write the technical art brief and render budget from `technical-art.md`: hero vs support surfaces, render budget target, material kit roles, shader/VFX purpose, instancing/LOD/culling plan, and imported asset cleanup. Treat that brief as part of this graphics architecture.
63
+
64
+ Do not add costly effects until this contract exists. A technical-art pass should make the scene more authored and more measurable at the same time.
65
+
66
+ ## Material Library
67
+
68
+ Implement the named material-role kit defined in `technical-art.md` (`bodyPrimary`, `bodySecondary`, `trim`, `hazard`, `reward`, `glass`, `emissiveSignal`, `groundContact`, `decalDark`/`decalLight`, plus shared UI/world signal colors) in `src/game/assets/MaterialLibrary.ts`. Create named roles instead of one-off colors and share materials across repeated meshes.
69
+
70
+ ## Procedural Texture And Decal Kit
71
+
72
+ Use canvas textures, shape geometry, or thin offset meshes for detail that would otherwise require external assets:
73
+
74
+ - Panel lines and access hatches.
75
+ - Trim sheets and edge bands.
76
+ - Window strips, city light grids, arena markings.
77
+ - Hazard stripes, arrows, target indicators, lane glyphs.
78
+ - Scratches, wear, noise, dirt, heat tint, scorch marks.
79
+ - UI/world icon motifs reused in HUD and diegetic markers.
80
+
81
+ Set texture filtering, mipmaps, repeat/wrap, color space, and anisotropy intentionally. Avoid unique full-size textures for tiny repeated marks.
82
+
83
+ Use procedural canvas textures, user-supplied art, or remote MCP for high-value 2D source art: terrain/rock/asphalt/snow/moss texture references, sci-fi trim sheets, signs, hazard stripes, cockpit decals, sky/background plates, menu/loading art, faction logos, pickup icons, ability icons, and GUI glyphs. Use the resulting images either as actual 2D assets or as image-to-3D inputs.
84
+
85
+ ## Model Factories
86
+
87
+ Factories should return a grouped object plus metadata:
88
+
89
+ ```ts
90
+ type ModelFactoryResult = {
91
+ root: THREE.Group;
92
+ collision?: THREE.Object3D;
93
+ lod?: THREE.LOD;
94
+ bounds?: THREE.Box3;
95
+ diagnostics?: {
96
+ meshes: number;
97
+ materials: number;
98
+ geometries: number;
99
+ triangles?: number;
100
+ };
101
+ };
102
+ ```
103
+
104
+ Use named child meshes for readable debugging. Separate visual detail from collision proxies. Keep repeated detail instanced where practical.
105
+
106
+ For imported generated 3D models, create an `ImportedAssetRegistry` or loader wrapper that returns similar metadata: root group, bounds, collision proxy, animation clips, and diagnostics. Never put 3D/image/audio generation API calls in browser runtime code.
107
+
108
+ ## World Art Director
109
+
110
+ Before building layers, load `../../game-art/references/scene-profiles.md` and pick a `scene_profile_id` (read 3D · Lighting rail only). That file owns the early spatial contract; this section owns production layering.
111
+
112
+ Build the world as layers (same names as `scene-profiles.md`):
113
+
114
+ - Play layer: ground, lanes, rails, objective path, hazards, pickups.
115
+ - Near layer: speed props, signs, arches, barriers, debris, foreground occluders used carefully.
116
+ - Mid layer: buildings, cliffs, hangars, pillars, platforms, arena machinery.
117
+ - Far layer: skyline, terrain silhouettes, nebula/cloud/fog cards, parallax planes.
118
+ - Motion layer: speed lines, particles, trail strips, dust, sparks, screen-space UI feedback.
119
+
120
+ Every layer should support gameplay readability. Do not obscure threats or the next decision. Reject sparse flat arenas and stretched-box skylines per `visual-scorecard.md` and the active paradigm's Reject if.
121
+
122
+ ## Render Pipeline
123
+
124
+ Own renderer / R3F `Canvas` gl setup in one place (`GameCanvas` + `game/three/RenderPipeline.ts`):
125
+
126
+ - `outputColorSpace = THREE.SRGBColorSpace`.
127
+ - Tone mapping and exposure selected for the art direction.
128
+ - DPR capped for mobile and high-density displays.
129
+ - Shadows enabled only for objects that benefit from grounding.
130
+ - Post-processing is limited and measured: bloom, vignette, chromatic aberration, film grain, or color grade only when they improve authored forms.
131
+ - Prefer R3F to present the frame. If an EffectComposer is required, drive `composer.render()` from `useFrame` and disable R3F's default render for that path — do not also call a separate outer `renderer.render` game loop.
132
+ - Resize updates canvas, renderer, camera, composer, and UI CSS variables.
133
+
134
+ ## VFX System
135
+
136
+ Implement the event-driven VFX language from `technical-art.md` in `src/game/three/VfxSystem.ts`. Effects should be pooled, readable, and tied to state; they must clarify state instead of adding permanent particle clutter. Prefer triggering from `gameBus` / simulation facts, not from HUD components.
137
+
138
+ ## Diagnostics
139
+
140
+ Own diagnostics in `src/game/three/QualityDiagnostics.ts` and expose snapshots on `window.__THREE_GAME_DIAGNOSTICS__` from `GameCanvas` or `game/bridge`. Report the renderer diagnostics defined in `technical-art.md` (calls, triangles, geometries, textures, material count, DPR/post/shadow settings), plus these architecture-specific counts:
141
+
142
+ - Scene mesh count, instanced mesh count, unique materials/geometries/textures.
143
+ - Approximate visible prop counts by layer.
144
+ - Screenshot paths and visual scorecard.
145
+ - Performance notes after post-processing, shadows, or many repeated props.
146
+
147
+ ## Browser Game Budgets
148
+
149
+ Use the render budget starting points and instancing/LOD/culling guidance in `technical-art.md`, then measure on the target game after every major graphics pass.
150
+
151
+ ## Implementation Order
152
+
153
+ 1. Score active screenshots and identify the weakest three categories.
154
+ 2. Add material and diagnostic foundations.
155
+ 3. Decide which weak surfaces need procedural, user-provided/remote 2D, imported user GLB, or hybrid treatment.
156
+ 4. Build/import hero/player and one complete obstacle/reward family.
157
+ 5. Add world prop kit and layered composition.
158
+ 6. Add lighting/render polish.
159
+ 7. Add event-driven VFX.
160
+ 8. Re-score desktop/mobile active screenshots.
161
+ 9. Optimize measured bottlenecks.
@@ -0,0 +1,146 @@
1
+ # Procedural Model Recipes
2
+
3
+ These recipes are for scratch-built Three.js models when external art assets are unavailable. The goal is not photorealism; it is authored, layered, readable, premium browser-game art.
4
+
5
+ ## Modeling Principles
6
+
7
+ - Start with silhouette. A model should be recognizable as a dark shape before materials or glow.
8
+ - Combine primitive bases with authored geometry: extrusions, bevels, curves, tubes, lathes, custom buffers, decals, trim, and instanced micro-detail.
9
+ - Use asymmetry and functional parts: hinges, fins, vents, handles, rails, brackets, sensors, cables, panels, bolts.
10
+ - Put detail where the camera sees it. Spend triangles on player-facing surfaces, not hidden undersides.
11
+ - Create state variants through material swaps, animated child parts, emissive strips, and VFX sockets.
12
+ - Keep a simple collision proxy separate from the detailed visual group.
13
+ - Use shared geometries/materials and instancing for repeated bolts, panels, lights, windows, spikes, rocks, or rail segments.
14
+ - Name important child meshes: `cockpitGlass`, `leftEngine`, `hazardTeeth`, `pickupCore`, `collisionProxy`.
15
+
16
+ ## Minimum Premium Asset Pass
17
+
18
+ For a game that asks for premium/AAA/showcase quality, build at least:
19
+
20
+ - One hero/player model with readable front/up/side and three state cues.
21
+ - Three obstacle/enemy variants with unique silhouettes and telegraphs.
22
+ - Two reward/interactable variants with idle and collect states.
23
+ - One world prop kit with at least eight reusable parts.
24
+ - One material kit with trim, decals, panel lines, and emissive masks.
25
+ - Collision proxies and renderer diagnostics for the above.
26
+
27
+ ## Hero Vehicle Recipe
28
+
29
+ Use for runners, racers, hovercraft, spaceships, drones, or arcade vehicles.
30
+
31
+ - Core hull: `ExtrudeGeometry` or custom tapered `BufferGeometry`, not just a box.
32
+ - Nose/front: wedge, intake, sensor strip, bumper, or blade shape.
33
+ - Cockpit/core: glass dome from sphere/lathe segments, beveled capsule, or faceted canopy.
34
+ - Engines: cylinders/cones/tubes with nozzle rings, inner emissive discs, heat fins, and trail sockets.
35
+ - Wings/fins: extruded triangular or curved plates with bevel/trim lines.
36
+ - Undercarriage: skids, landing pads, rail clamps, suspension arms, or thruster pods.
37
+ - Decals: panel lines, numeric marks, faction glyph, hazard ticks, small bolts.
38
+ - State cues: boost flares, shield shell, damage scorch, pickup glow, overheat red.
39
+ - Collision proxy: one capsule/box/sphere group matching gameplay footprint.
40
+
41
+ Reject if the hero is mostly a box with two cylinders and a glow.
42
+
43
+ ## Hero Character Recipe
44
+
45
+ Use for arena fighters, brawlers, platformers, or stylized third-person games.
46
+
47
+ - Body mass: torso, pelvis, head/helmet, limbs with tapered capsule/cylinder custom scales.
48
+ - Rig illusion: separate shoulders, elbows, knees, wrists, ankles, belt, backpack, armor plates.
49
+ - Face/identity: visor, mask, hair/helmet crest, color-blocked silhouette, weapon/tool.
50
+ - Animation-ready pivots: group limbs under named joints even if animation is procedural.
51
+ - Material zones: skin/fabric/armor/metal/glass/emissive accents.
52
+ - State cues: hit flash material, shield ring, attack trail socket, stamina/charge glow.
53
+ - Collision proxy: capsule or cylinder independent of mesh detail.
54
+
55
+ Reject if the character reads as stacked spheres/cylinders with no costume, joints, or silhouette.
56
+
57
+ ## Obstacle And Enemy Families
58
+
59
+ Build distinct gameplay reads:
60
+
61
+ - Low barrier: ground-hugging slab, spikes, rails, caution panels, animated warning light.
62
+ - Gate/arch: overhead frame, side posts, pulsing pass/avoid lane, moving shutters.
63
+ - Moving hazard: rotating arm, sweeper beam, drone, crusher, sliding block, orbiting mines.
64
+ - Trap/zone: laser grid, electric puddle, collapsing tile, gravity well, proximity mine.
65
+ - Enemy: body core, sensor/head, weapon, shield, locomotion/hover base, attack telegraph.
66
+
67
+ Each variant needs:
68
+
69
+ - Unique silhouette.
70
+ - Material cue for danger.
71
+ - Telegraph from distance.
72
+ - Animation or state change.
73
+ - Collision proxy.
74
+ - Low-cost repeated detail.
75
+
76
+ Reject if all hazards are recolored cubes/cones.
77
+
78
+ ## Reward And Interactable Recipes
79
+
80
+ Rewards should be readable and desirable during motion.
81
+
82
+ - Token: outer ring, inner core, value icon, shimmer cards, collect burst socket.
83
+ - Shard: faceted crystal, metal bracket, orbiting chips, emissive seam.
84
+ - Capsule: glass shell, suspended item, end caps, rotating label strip.
85
+ - Power-up: icon silhouette matched to effect, color and shape differ from score pickups.
86
+ - Objective item: larger scale, unique motion, UI echo, stronger lighting/VFX.
87
+
88
+ States:
89
+
90
+ - Idle: slow rotation, pulse, bob, or orbit.
91
+ - Attract: line/trail toward player.
92
+ - Collect: vanish, burst, score trail, HUD meter update.
93
+
94
+ Reject if rewards are plain spheres or torus rings without state feedback.
95
+
96
+ ## World Prop Kit
97
+
98
+ Build modular props that can be instanced and recombined:
99
+
100
+ - Track/road: lane plates, seams, arrows, side rails, guard segments, repair panels.
101
+ - Arena: boundary rings, floor tiles, spawn pads, cover blocks, goal markers.
102
+ - City/sci-fi: window strips, antennas, rooftop units, bridge trusses, pylons, billboards.
103
+ - Nature: rocks from custom faceted buffers, cliffs, roots, crystals, grasses as cards.
104
+ - Industrial: pipes, vents, cables, tanks, crates, gantries, lights, warning signs.
105
+ - Space/air: debris panels, satellites, buoys, asteroid chunks, parallax dust.
106
+
107
+ Layer the kit:
108
+
109
+ - Near props create speed and scale.
110
+ - Mid props define the playable corridor.
111
+ - Far props create depth without stealing draw calls.
112
+
113
+ Reject if the world is mostly stretched boxes or a flat plane.
114
+
115
+ ## Procedural Geometry Techniques
116
+
117
+ - `ExtrudeGeometry`: panels, fins, wings, badges, UI/world glyphs, signs.
118
+ - `LatheGeometry`: capsules, domes, engines, pipes, bottles, turret bases.
119
+ - `TubeGeometry`: cables, rails, trails, conduits, curved weapons.
120
+ - Custom `BufferGeometry`: tapered hulls, rocks, shards, wedges, low-poly terrain.
121
+ - `ShapeGeometry`: decals, flat icons, trim strips, hazard markers.
122
+ - `InstancedMesh`: windows, bolts, lane markers, debris, grass, lights, small props.
123
+ - `LOD`: hero/background variants and dense prop reductions.
124
+
125
+ Use bevel-like layering when real bevel geometry is too expensive: duplicate thin trim meshes, edge strips, or slightly offset darker panels.
126
+
127
+ ## Material And Detail Rules
128
+
129
+ - Use roughness/metalness contrast, not only hue contrast.
130
+ - Use emissive for authored signals, not entire objects.
131
+ - Use glass/clearcoat sparingly on hero details.
132
+ - Add darker contact material under important objects.
133
+ - Use decals to imply scale and function.
134
+ - Reuse UI icon shapes as world decals for cohesion.
135
+
136
+ ## Diagnostics Checklist
137
+
138
+ After a model pass, report:
139
+
140
+ - Mesh count.
141
+ - Instanced mesh count.
142
+ - Unique geometries/materials/textures.
143
+ - Approximate triangle count if available.
144
+ - Collision proxies included.
145
+ - LOD or culling strategy for repeated/background props.
146
+ - Active-play screenshots, not only showroom renders.
@@ -0,0 +1,90 @@
1
+ # Render, Lighting, And VFX Recipes
2
+
3
+ Use this after authored forms exist. Rendering polish cannot compensate for missing models, props, or readable gameplay silhouettes.
4
+
5
+ ## Renderer Setup
6
+
7
+ - Set `renderer.outputColorSpace = THREE.SRGBColorSpace`.
8
+ - Choose tone mapping deliberately. `ACESFilmicToneMapping` often works for cinematic stylized scenes; simpler tone mapping can be better for bright arcade readability.
9
+ - Tune exposure against active gameplay, not a static title view.
10
+ - Cap DPR, especially on mobile. Start around `Math.min(devicePixelRatio, 1.5 or 2)` and profile.
11
+ - Update renderer, camera, composer, and CSS UI dimensions on resize.
12
+ - Use a transparent or explicit background only when composition requires it.
13
+
14
+ ## Camera Composition
15
+
16
+ - Keep the next decision visible. The camera should show player, immediate threat/reward, and route.
17
+ - Add depth layers: foreground speed elements, playable midground, background scale cues.
18
+ - Use FOV and camera distance to communicate speed without hiding hazards.
19
+ - Use camera shake sparingly and clamp intensity.
20
+ - Add camera impulses for hits/near misses/boosts, then ease back quickly.
21
+ - Check mobile framing separately; vertical and narrow layouts often need different offsets.
22
+
23
+ ## Lighting Stack
24
+
25
+ Use a small readable stack:
26
+
27
+ - Key light: defines form and direction.
28
+ - Fill light: keeps gameplay objects legible.
29
+ - Rim/back light: separates player and hazards from background.
30
+ - Practical/emissive lights: authored beacons, engines, pickups, arena markers.
31
+ - Contact shadows or shadow blobs: ground important objects.
32
+
33
+ Avoid many unmeasured dynamic lights. Prefer baked-looking material/emissive cues, light cards, or small unlit decals for repeated signals.
34
+
35
+ ## Shadows And Contact
36
+
37
+ - Use shadows for hero/player, major hazards, and large world anchors.
38
+ - Use smaller shadow maps and limited shadow casters when profiling shows cost.
39
+ - Add cheap contact discs or transparent planes for pickups/hovering objects.
40
+ - Tune bias to avoid acne and peter-panning.
41
+ - Do not let shadows hide collision reads.
42
+
43
+ ## Materials
44
+
45
+ Define material roles with the material kit in `technical-art.md` (`MeshStandardMaterial` for most surfaces, `MeshPhysicalMaterial` only where the premium feature is visible). At render time:
46
+
47
+ - Prefer material contrast before post effects: matte vs glossy, metal vs plastic, transparent vs opaque, bright trim vs dark contact.
48
+ - Use emissive maps or small emissive parts for signals instead of making entire objects glow.
49
+ - Keep material roles matched across UI and world: danger, reward, shield, boost, objective.
50
+
51
+ ## Fog, Background, And Depth
52
+
53
+ - Fog should reveal depth and mood, not hide empty worlds.
54
+ - Layer background silhouettes at varied scales and heights.
55
+ - Add parallax or slow-moving far layers for motion-heavy games.
56
+ - Avoid single flat sky colors when the world needs scale; use gradients only as support, not the whole art direction.
57
+ - Keep hazards/rewards readable against fog and background values.
58
+
59
+ ## Post-Processing
60
+
61
+ Use post as a finishing pass:
62
+
63
+ - Bloom: only authored emissive elements, not all bright materials.
64
+ - Vignette: subtle focus, never heavy darkness.
65
+ - Film grain/noise: low opacity; avoid compression-like artifacts.
66
+ - Chromatic aberration: only brief event-driven impacts or very subtle style.
67
+ - Motion blur/trails: prefer geometry trails or particles that preserve gameplay clarity.
68
+
69
+ Always compare screenshots with post enabled/disabled and profile the cost.
70
+
71
+ ## Event-Driven VFX
72
+
73
+ Tie effects to state using the event-driven VFX language in `technical-art.md` (pickup, hit/fail, boost/speed, near miss/combo, shield/invulnerable, spawn/despawn). Pool effects, reuse geometries/materials, and keep permanent particle fields cheap and sparse.
74
+
75
+ ## Readability Checks
76
+
77
+ During active play, confirm:
78
+
79
+ - Player orientation is clear.
80
+ - Threats differ from rewards by both shape and material.
81
+ - Important pickups are visible before reaction time expires.
82
+ - UI feedback does not cover the play path.
83
+ - VFX clarifies state instead of obscuring collisions.
84
+ - Background contrast does not swallow dark objects.
85
+
86
+ ## Performance Checks
87
+
88
+ After render changes, report the renderer diagnostics from `technical-art.md` (calls, triangles, geometries, textures, materials, DPR/post/shadow settings), plus FPS/frame time and composer/post pass count when available.
89
+
90
+ If performance drops, reduce post/shadow cost first, then cull/LOD/instance, then reduce asset density only where it is least visible.