@call-me-sensei/toonlab 0.4.21 → 0.4.23
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.
- package/NPM-LIBRARY.md +87 -27
- package/README.md +11 -10
- package/agents/PROMPTS.md +17 -3
- package/agents/README.md +13 -3
- package/agents/claude/CLAUDE.md +3 -0
- package/agents/codex/AGENTS.md +112 -159
- package/agents/cursor/toonlab.mdc +7 -3
- package/agents/examples/game-foundation.mjs +104 -0
- package/agents/references/game-lifecycle.md +57 -0
- package/agents/references/runtime-entry-points.md +26 -0
- package/agents/references/style-bundles.md +4 -1
- package/agents/skills/claude/asset-sourcing/SKILL.md +7 -4
- package/agents/skills/claude/environment/SKILL.md +4 -0
- package/agents/skills/claude/game-dev/SKILL.md +63 -87
- package/agents/skills/claude/lighting/SKILL.md +36 -0
- package/agents/skills/claude/post-processing/SKILL.md +8 -3
- package/agents/skills/claude/rock-ground-shaders/SKILL.md +10 -15
- package/agents/skills/claude/rockgen/SKILL.md +52 -21
- package/agents/skills/claude/scene-style-application/SKILL.md +4 -0
- package/agents/skills/claude/style-presets/SKILL.md +11 -8
- package/agents/skills/claude/toon-shading/SKILL.md +4 -0
- package/agents/skills/claude/vegetation-sky/SKILL.md +13 -7
- package/agents/skills/claude/visual-verification/SKILL.md +45 -119
- package/agents/skills/claude/water/SKILL.md +6 -2
- package/agents/skills/codex/asset-sourcing/SKILL.md +7 -4
- package/agents/skills/codex/environment/SKILL.md +4 -0
- package/agents/skills/codex/game-dev/SKILL.md +63 -87
- package/agents/skills/codex/lighting/SKILL.md +36 -0
- package/agents/skills/codex/post-processing/SKILL.md +8 -3
- package/agents/skills/codex/rock-ground-shaders/SKILL.md +10 -15
- package/agents/skills/codex/rockgen/SKILL.md +52 -21
- package/agents/skills/codex/scene-style-application/SKILL.md +4 -0
- package/agents/skills/codex/style-presets/SKILL.md +11 -8
- package/agents/skills/codex/toon-shading/SKILL.md +4 -0
- package/agents/skills/codex/vegetation-sky/SKILL.md +13 -7
- package/agents/skills/codex/visual-verification/SKILL.md +45 -119
- package/agents/skills/codex/water/SKILL.md +6 -2
- package/database/apply-one-catalog-seed.mjs +63 -0
- package/database/providers.mjs +1 -0
- package/database/seeds/catalog/0005_2026-08-c8-first12.sql +1101 -0
- package/database/seeds/catalog/0006_2026-09-c8-first100.sql +14245 -0
- package/database/seeds/catalog/0007_2026-09-c8-first100-primary-model.sql +14845 -0
- package/mcp/lab-management.mjs +11 -8
- package/mcp/public-catalog.mjs +0 -16
- package/mcp/tree-lab-contract.mjs +2381 -0
- package/mcp/vite-plugin.mjs +5 -1
- package/package.json +29 -18
- package/src/catalog/officialCatalog.js +1 -0
- package/src/catalog/officialCatalogAssetRuntime.js +98 -1
- package/src/catalog/officialCatalogLod.js +160 -16
- package/src/catalog/officialCatalogPlacement.js +52 -12
- package/src/catalog/officialCatalogProvider.js +79 -8
- package/src/catalog/officialCatalogRockPackage.js +172 -0
- package/src/cloud/cloudReprojection.js +40 -7
- package/src/cloud/cloudVolume.js +44 -7
- package/src/cloud/noise/baseShapeVolume.js +8 -6
- package/src/cloud/noise/cirrusMap.js +2 -1
- package/src/cloud/noise/curlNoise.js +2 -1
- package/src/cloud/noise/erosionVolume.js +2 -1
- package/src/cloud/noise/textureCache.js +77 -0
- package/src/cloud/noise/weatherMap.js +2 -1
- package/src/core/sha256.js +83 -0
- package/src/ground-shader/groundShaderMaterial.js +12 -3
- package/src/rock-shader/rockMaterial.js +205 -28
- package/src/rock-shader/rockShaderRuntime.js +17 -1
- package/src/rock-shader/rockShaderSettings.js +16 -0
- package/src/rockgen/index.js +9 -0
- package/src/rockgen/lod/index.js +1 -0
- package/src/rockgen/lod/rockDenseFieldPolicy.js +143 -0
- package/src/rockgen/rockDocument.js +899 -35
- package/src/rockgen/surface/c7GeologySurface.js +39 -9
- package/src/rockgen/surface/naturalRockSurface.js +1948 -0
- package/src/shaders-tsl/chunks/projected-water-caustics.js +14 -2
- package/src/shaders-tsl/chunks/water-foam.js +6 -6
- package/src/shaders-tsl/chunks/water-lighting.js +28 -5
- package/src/shaders-tsl/chunks/water-shore-state.js +5 -2
- package/src/shaders-tsl/chunks/water-waves.js +10 -5
- package/src/shaders-tsl/flower.js +7 -4
- package/src/shaders-tsl/grass.js +4 -3
- package/src/shaders-tsl/water-shore-state-simulation.js +3 -2
- package/src/shaders-tsl/water.js +209 -41
- package/src/sky/skySystem.js +30 -7
- package/src/toon/settings/perspectiveRemovalSettings.js +1 -1
- package/src/toon/toonSettings.js +74 -0
- package/src/vegetation/stylizedFlower.js +6 -0
- package/src/version.js +1 -1
- package/src/water/waterDetailSpectrum.js +91 -0
- package/src/water/waterDynamics.js +422 -0
- package/src/water/waterFoamParticles.js +196 -0
- package/src/water/waterFoamTexture.js +57 -0
- package/src/water/waterHydrodynamics.js +209 -0
- package/src/water/waterMaterial.js +1 -0
- package/src/water/waterRenderExtension.js +107 -0
- package/src/water/waterScenePasses.js +14 -6
- package/src/water/waterSettings.js +53 -26
- package/src/water/waterShoreMaterial.js +38 -14
- package/src/water/waterSpectralOcean.js +137 -0
- package/src/water/waterStageSettings.js +19 -1
- package/src/water/waterSurface.js +62 -18
- package/src/water/waterUnderwaterAtmosphere.js +30 -3
- package/types/catalog/officialCatalog.d.ts +1 -0
- package/types/catalog/officialCatalogPlacement.d.ts +4 -0
- package/types/catalog/officialCatalogRockPackage.d.ts +68 -0
- package/types/cloud/noise/baseShapeVolume.d.ts +1 -1
- package/types/cloud/noise/textureCache.d.ts +12 -0
- package/types/core/sha256.d.ts +2 -0
- package/types/index.d.ts +30 -0
- package/types/rock-shader/rockMaterial.d.ts +3 -0
- package/types/rock-shader/rockShaderSettings.d.ts +2 -0
- package/types/rockgen/index.d.ts +1 -0
- package/types/rockgen/lod/index.d.ts +1 -0
- package/types/rockgen/lod/rockDenseFieldPolicy.d.ts +181 -0
- package/types/rockgen/rockDocument.d.ts +654 -71
- package/types/rockgen/surface/naturalRockSurface.d.ts +100 -0
- package/types/shaders-tsl/chunks/projected-water-caustics.d.ts +7 -1
- package/types/shaders-tsl/chunks/water-lighting.d.ts +4 -3
- package/types/shaders-tsl/water.d.ts +2 -1
- package/types/version.d.ts +1 -1
- package/types/water/waterDetailSpectrum.d.ts +13 -0
- package/types/water/waterDynamics.d.ts +89 -0
- package/types/water/waterFoamParticles.d.ts +32 -0
- package/types/water/waterFoamTexture.d.ts +1 -0
- package/types/water/waterHydrodynamics.d.ts +49 -0
- package/types/water/waterRenderExtension.d.ts +16 -0
- package/types/water/waterScenePasses.d.ts +1 -1
- package/types/water/waterSettings.d.ts +1 -0
- package/types/water/waterSpectralOcean.d.ts +17 -0
- package/types/water/waterStageSettings.d.ts +1 -1
- package/types/water/waterUnderwaterAtmosphere.d.ts +19 -4
package/NPM-LIBRARY.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# ToonLab npm library guide
|
|
2
2
|
|
|
3
3
|
This guide is included in `@call-me-sensei/toonlab`. It is the package-first
|
|
4
|
-
reference for version 0.4.
|
|
4
|
+
reference for version 0.4.23 and does not require access to the source
|
|
5
5
|
repository.
|
|
6
6
|
|
|
7
7
|
## Install
|
|
@@ -67,13 +67,13 @@ release. A one-asset Node rock annotation compiler is also repository-only.
|
|
|
67
67
|
The npm artifact contains four supported layers:
|
|
68
68
|
|
|
69
69
|
1. The JavaScript runtime and TypeScript declarations for the public imports.
|
|
70
|
-
2. Text-only agent guides, prompts, references, and paired Codex/Claude skills
|
|
70
|
+
2. Text-only agent guides, prompts, references, a copyable game example, and paired Codex/Claude skills
|
|
71
71
|
under `agents/`.
|
|
72
72
|
3. The `toonlab` manifest audit CLI and `toonlab-mcp` local stdio MCP server.
|
|
73
73
|
4. The local MCP database/catalog support required for Library and asset
|
|
74
74
|
discovery workflows.
|
|
75
75
|
|
|
76
|
-
It does not contain the ToonLab website, Lab application UIs,
|
|
76
|
+
It does not contain the ToonLab website, Lab application UIs, repository demo applications,
|
|
77
77
|
screenshots, models, textures, or other binary media. Optional public fixtures
|
|
78
78
|
are identified by immutable `https://assets.toonlab.io` metadata rather than
|
|
79
79
|
being bundled. Authored tree recipes are assets too: the reviewed public tree
|
|
@@ -115,8 +115,12 @@ await look.apply(CALL_ME_SENSEI_STYLE_BUNDLE, {
|
|
|
115
115
|
|
|
116
116
|
renderer.setAnimationLoop(() => {
|
|
117
117
|
const delta = clock.getDelta();
|
|
118
|
+
sky?.update(delta);
|
|
118
119
|
look.update(delta, camera);
|
|
119
|
-
|
|
120
|
+
// Update host-owned grass/characters here if this scene uses them.
|
|
121
|
+
water?.update(delta, camera);
|
|
122
|
+
if (post) post.render(delta);
|
|
123
|
+
else renderer.render(scene, camera);
|
|
120
124
|
});
|
|
121
125
|
```
|
|
122
126
|
|
|
@@ -124,36 +128,91 @@ The host application still owns renderer creation, geometry and XZ layout,
|
|
|
124
128
|
cameras, controls, gameplay, dynamic physics, navigation, persistence, and the
|
|
125
129
|
frame loop. ToonLab does not turn a prompt into a finished world.
|
|
126
130
|
|
|
127
|
-
##
|
|
131
|
+
## Realistic rock surface generation
|
|
128
132
|
|
|
129
|
-
|
|
133
|
+
The public `rockgen` entry includes `createNaturalRockMapData`,
|
|
134
|
+
`createNaturalRockSurfaceSpecification`, `resolveNaturalRockProjection`,
|
|
135
|
+
`NATURAL_ROCK_SURFACE_PROFILES`, and `NATURAL_ROCK_MAP_ROLES`.
|
|
136
|
+
These are the same deterministic realistic material profiles used by the Rock
|
|
137
|
+
Lab. They produce typed RGBA map data; the host creates textures and assigns
|
|
138
|
+
material/projection settings. Saved library rocks retain their surface recipe.
|
|
139
|
+
The published realistic GLB is also available through raw catalog acquisition.
|
|
140
|
+
Composite lithologies require authored semantic regions; micro-height maps are
|
|
141
|
+
surface detail, not displacement that replaces a geometric high-to-low bake.
|
|
130
142
|
|
|
131
|
-
|
|
143
|
+
## Load Nature Reference Rocks
|
|
132
144
|
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
145
|
+
Version 0.4.23 understands both the original `rock-0001`–`rock-0480`
|
|
146
|
+
identities and the Nature Reference Rocks catalog. Acquiring an asset
|
|
147
|
+
directly returns its realistic PBR GLB. The one-call placement path additionally
|
|
148
|
+
loads that asset's reviewed geology maps and `call_me_sensei` material settings
|
|
149
|
+
before applying the selected style bundle.
|
|
138
150
|
|
|
139
|
-
|
|
151
|
+
```js
|
|
152
|
+
import {
|
|
153
|
+
createOfficialCatalogAssetRuntime,
|
|
154
|
+
createOfficialCatalogProvider,
|
|
155
|
+
createOfficialCatalogRockEditorDescriptor,
|
|
156
|
+
loadOfficialCatalogAsset,
|
|
157
|
+
} from '@call-me-sensei/toonlab/official-catalog';
|
|
158
|
+
import { CALL_ME_SENSEI_STYLE_BUNDLE } from '@call-me-sensei/toonlab/styles';
|
|
159
|
+
|
|
160
|
+
const provider = createOfficialCatalogProvider({
|
|
161
|
+
baseUrl: 'https://toonlab.io/',
|
|
162
|
+
transport: 'public-rock',
|
|
163
|
+
});
|
|
164
|
+
const assets = createOfficialCatalogAssetRuntime({ provider, renderer });
|
|
165
|
+
const catalog = await provider.listAssets();
|
|
166
|
+
const selectedRock = catalog.assets.find((asset) => asset.label.toLowerCase().includes('sandstone'));
|
|
167
|
+
if (!selectedRock) throw new Error('Select an available sandstone rock from the catalog.');
|
|
168
|
+
|
|
169
|
+
// Raw acquisition keeps the realistic PBR model.
|
|
170
|
+
const realistic = await assets.acquireAsset(selectedRock.id);
|
|
171
|
+
scene.add(realistic.root);
|
|
172
|
+
|
|
173
|
+
// Placement loads the same rock's geology maps and applies Call Me Sensei.
|
|
174
|
+
const stylized = await loadOfficialCatalogAsset({
|
|
175
|
+
assetId: selectedRock.id,
|
|
176
|
+
assetRuntime: assets,
|
|
177
|
+
parent: scene,
|
|
178
|
+
styleBundle: CALL_ME_SENSEI_STYLE_BUNDLE,
|
|
179
|
+
});
|
|
140
180
|
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
181
|
+
// Rock Lab/editor integrations receive the non-destructive authoring contract.
|
|
182
|
+
const rockPackage = await assets.getRockPackage(selectedRock.id);
|
|
183
|
+
const editorSource = createOfficialCatalogRockEditorDescriptor(
|
|
184
|
+
rockPackage.asset,
|
|
185
|
+
rockPackage,
|
|
186
|
+
);
|
|
145
187
|
```
|
|
146
188
|
|
|
147
|
-
|
|
189
|
+
`editorSource` exposes `control.glb`, retained high detail, LOD0–LOD4,
|
|
190
|
+
collision, recipe, material configuration, and the required post-sculpt
|
|
191
|
+
reprojection/rebake/rebuild flags. These are immutable R2 URLs; the package
|
|
192
|
+
does not embed any rock media. Release acquired handles and dispose the runtime
|
|
193
|
+
when their scene lifetime ends.
|
|
148
194
|
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
195
|
+
## Install the agent guidance
|
|
196
|
+
|
|
197
|
+
Everything in this section is present in the installed npm package.
|
|
198
|
+
|
|
199
|
+
### Use the installed guide
|
|
200
|
+
|
|
201
|
+
Add a reference to `node_modules/@call-me-sensei/toonlab/agents/codex/AGENTS.md`
|
|
202
|
+
in the project's existing instructions, or read it directly. Merge relevant
|
|
203
|
+
guidance; do not replace an existing `AGENTS.md` or `CLAUDE.md`. Claude's optional
|
|
204
|
+
wrapper is `agents/claude/CLAUDE.md`; Cursor's is `agents/cursor/toonlab.mdc`.
|
|
205
|
+
|
|
206
|
+
Copy only the feature skills you need into the client's skill directory, while
|
|
207
|
+
preserving any existing skills with the same names. Shared `agents/...`
|
|
208
|
+
references remain relative to the installed package root. Keep the package
|
|
209
|
+
installed; copying a single skill does not copy its reference library.
|
|
153
210
|
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
211
|
+
Start with `game-dev` for a new game or existing-scene integration, then add
|
|
212
|
+
`asset-sourcing` for Library/Gallery work and the focused rendering skills as
|
|
213
|
+
needed. `agents/PROMPTS.md` contains the prompt cookbook.
|
|
214
|
+
`agents/examples/game-foundation.mjs` is a copyable, playable blockout example;
|
|
215
|
+
it is application code, not an exported ToonLab game engine.
|
|
157
216
|
|
|
158
217
|
## Connect MCP
|
|
159
218
|
|
|
@@ -169,7 +228,8 @@ it uses the disk workspace passed through `--workspace`; no account is needed.
|
|
|
169
228
|
"command": "npx",
|
|
170
229
|
"args": [
|
|
171
230
|
"-y",
|
|
172
|
-
"
|
|
231
|
+
"--package=@call-me-sensei/toonlab@0.4.23",
|
|
232
|
+
"toonlab-mcp",
|
|
173
233
|
"--workspace",
|
|
174
234
|
"/absolute/path/to/your-game/.toonlab"
|
|
175
235
|
],
|
|
@@ -181,7 +241,7 @@ it uses the disk workspace passed through `--workspace`; no account is needed.
|
|
|
181
241
|
}
|
|
182
242
|
```
|
|
183
243
|
|
|
184
|
-
This server provides the anime-game profile,
|
|
244
|
+
This server provides the anime-game profile, live-Lab
|
|
185
245
|
contracts, deterministic document creation and mutation, policy validation,
|
|
186
246
|
public Gallery search/retrieval, local Library operations, and optional
|
|
187
247
|
provider-backed generation when the developer supplies server-side provider
|
package/README.md
CHANGED
|
@@ -19,7 +19,7 @@ Use ToonLab as a focused runtime library (`@call-me-sensei/toonlab` on npm), as
|
|
|
19
19
|
an asset/preset authoring workspace, or as an asset-discovery service—not as a
|
|
20
20
|
one-shot world generator.
|
|
21
21
|
|
|
22
|
-
## Versioned expectation: 0.4.
|
|
22
|
+
## Versioned expectation: 0.4.23
|
|
23
23
|
|
|
24
24
|
For a correctly constructed and semantically labeled scene, one strict Call Me
|
|
25
25
|
Sensei bundle application is expected to establish the supported visual
|
|
@@ -277,8 +277,9 @@ Catalog data therefore does **not** use a separate downloadable “current
|
|
|
277
277
|
seed,” and new datasets are **not** schema migrations. Keeping every released
|
|
278
278
|
batch in the repository gives fresh and upgraded installations the same final
|
|
279
279
|
catalog while preserving a simple, auditable upgrade path. The checked-in
|
|
280
|
-
catalog
|
|
281
|
-
|
|
280
|
+
catalog includes the original 480 first-party Stylized rocks, the 100-item
|
|
281
|
+
Nature Reference Rocks by ToonLab collection, and the verified open-asset
|
|
282
|
+
release. The two ToonLab rock collections keep distinct searchable identities.
|
|
282
283
|
|
|
283
284
|
Applied filenames and SHA-256 digests are recorded in `schema_migrations` and
|
|
284
285
|
`catalog_seed_batches`. Never edit, rename, or replace a released migration or
|
|
@@ -378,7 +379,7 @@ camera behavior, and game feel remain host-owned or pre-beta.
|
|
|
378
379
|
| Toon character shading | `@call-me-sensei/toonlab/toon` | Modern anime character shader: cel bands with art-directed face lighting, skin-tone shadow management, shadow-color HSV control, scene/self/contact shadows, average-shadow smoothing, rim light (fresnel or screen-space depth), stylized + anisotropic hair highlights, eye catchlights, role-aware specular, source map routing (normal/AO/emissive/MatCap/ramp/detail), inverted-hull outlines, glitter, stickers, perspective removal, shell fur, dither fades — 23 settings groups, all preset-serializable. [Docs](https://github.com/call-me-sensei/toonlab/blob/main/docs/toon-shading.md) |
|
|
379
380
|
| Environment shading | `@call-me-sensei/toonlab/environment` | Modern anime-style scene shader for texture packs, standard glTF, and untextured scenes: material-role classification, wrapped lighting, packed-map hints, window cutouts, sun/lamp rigs, time-of-day, six-direction ambient probe, planar floor reflections, BVH vertex-AO baking, height fog, cloud shadows. [Docs](https://github.com/call-me-sensei/toonlab/blob/main/docs/environment.md) |
|
|
380
381
|
| Water | `@call-me-sensei/toonlab/water` | Focused water treatment for a host-authored water footprint, continuous shore, and closed seabed: Gerstner waves, absorption color, refraction/caustics/foam, ripples, splashes, wakes, kelp, underwater treatment, and CPU buoyancy sampling. It does not design the coast or underwater habitat. [Docs](https://github.com/call-me-sensei/toonlab/blob/main/docs/water.md) |
|
|
381
|
-
| Vegetation | `@call-me-sensei/toonlab/vegetation` | Tree/grass/flower construction and shader runtimes, including the focused procedural broadleaf `BranchTree` with deterministic branching,
|
|
382
|
+
| Vegetation | `@call-me-sensei/toonlab/vegetation` | Tree/grass/flower construction and shader runtimes, including the focused procedural broadleaf `BranchTree` with deterministic branching, eight leaf silhouettes, caller-supplied leaf/bark textures, and a portable recipe. No authored tree asset collection is bundled or exported: reviewed tree recipes remain searchable Gallery assets delivered through MCP with their CC0 metadata. Package-generated trees preserve authored bark first and otherwise select a registered deterministic bark surface instead of a bare trunk. The experimental species roster remains repository-only. [Docs](https://github.com/call-me-sensei/toonlab/blob/main/docs/vegetation-sky.md) |
|
|
382
383
|
| Rock shader | `@call-me-sensei/toonlab/rock-shader` | Detailed, versioned rock-material profiles with projected detail, distance tint, normal fading, striping, moss and optional top layers, plus explicit source-albedo and vertex-color/AO integration. Call Me Sensei is the default. Geometry generation remains separate in `rockgen`. [Docs](https://github.com/call-me-sensei/toonlab/blob/main/docs/rock-shader.md) |
|
|
383
384
|
| Ground shader | `@call-me-sensei/toonlab/ground-shader` | Splat-weighted anime terrain with slope/cliff detail, shoreline and weather response, HDR sun/shade controls, safe shadow defaults, and flat-albedo ground-field output for vegetation adoption. [Docs](https://github.com/call-me-sensei/toonlab/blob/main/docs/ground-shader.md) |
|
|
384
385
|
| Sky | `@call-me-sensei/toonlab/sky` | Reusable atmosphere, palette, sun, moon, stars, and god-ray settings authored by Sky Lab and Sky & Cloud Lab. Your application coordinates final lighting and scene state. [Docs](https://github.com/call-me-sensei/toonlab/blob/main/docs/sky.md) |
|
|
@@ -628,7 +629,7 @@ stack, with WebGL2 fallback through the same TSL path.
|
|
|
628
629
|
shared 24-hour controls, four-state regression matrix, and required cool/blue
|
|
629
630
|
daylight-shadow verification.
|
|
630
631
|
- [Rock shader](https://github.com/call-me-sensei/toonlab/blob/main/docs/rock-shader.md) — the separate generator/material
|
|
631
|
-
architecture,
|
|
632
|
+
architecture, schema-defined public configuration, import policy, and bundle use.
|
|
632
633
|
- [Styles, style bundles, and asset routing](https://github.com/call-me-sensei/toonlab/blob/main/docs/styles-and-bundles.md) —
|
|
633
634
|
rendering domains, required asset labels, fallback policy, bundle ownership,
|
|
634
635
|
OSS application boundaries, and the shader/lab migration contract.
|
|
@@ -654,7 +655,7 @@ stack, with WebGL2 fallback through the same TSL path.
|
|
|
654
655
|
- [Post-processing](https://github.com/call-me-sensei/toonlab/blob/main/docs/post-processing.md)
|
|
655
656
|
- [Texture Lab and texgen](https://github.com/call-me-sensei/toonlab/blob/main/docs/texture-lab.md)
|
|
656
657
|
- [Characters and animation](https://github.com/call-me-sensei/toonlab/blob/main/docs/characters.md)
|
|
657
|
-
- [Settings reference](https://github.com/call-me-sensei/toonlab/blob/main/docs/settings-reference.md) —
|
|
658
|
+
- [Settings reference](https://github.com/call-me-sensei/toonlab/blob/main/docs/settings-reference.md) — selected runtime and repository settings,
|
|
658
659
|
generated from the schemas (`node scripts/generate-settings-reference.mjs`).
|
|
659
660
|
- [Shader constants](https://github.com/call-me-sensei/toonlab/blob/main/docs/shader-constants.md) — the deliberately unexposed
|
|
660
661
|
constants and where they live.
|
|
@@ -666,14 +667,14 @@ Cursor, …). The recommended setup has three parts: give the agent the ToonLab
|
|
|
666
667
|
skills, connect whichever ToonLab OSS local or ToonLab Pro remote MCP surface
|
|
667
668
|
the developer has, then start from a goal prompt and iterate. The npm package
|
|
668
669
|
ships runtime source and the small text-only `agents/` guidance bundle. It
|
|
669
|
-
|
|
670
|
-
|
|
670
|
+
includes a copyable playable blockout in `agents/examples/game-foundation.mjs`;
|
|
671
|
+
models, textures, Lab apps, repository demos and review media are not bundled.
|
|
671
672
|
|
|
672
673
|
### 1. Install the ToonLab skills in your game project
|
|
673
674
|
|
|
674
675
|
The skills teach the agent the runtime boundary, asset-discovery order,
|
|
675
676
|
frame-loop contract, and each focused subsystem API. Start with `game-dev` for
|
|
676
|
-
|
|
677
|
+
new-game development or integration, and `asset-sourcing` for Gallery/MCP work.
|
|
677
678
|
Experimental whole-world, natural-cliff, Weather/Climate, camera, game-feel,
|
|
678
679
|
and gameplay-VFX skills are intentionally not included in the npm artifact.
|
|
679
680
|
|
|
@@ -713,7 +714,7 @@ the public tree collection—those recipes are not npm built-ins:
|
|
|
713
714
|
"mcpServers": {
|
|
714
715
|
"toonlab-local": {
|
|
715
716
|
"command": "npx",
|
|
716
|
-
"args": ["-y", "
|
|
717
|
+
"args": ["-y", "--package=@call-me-sensei/toonlab@latest", "toonlab-mcp", "--workspace", "/absolute/path/to/your-game/.toonlab"],
|
|
717
718
|
"env": { "TOONLAB_LEGACY_WORKSPACE": "1" }
|
|
718
719
|
}
|
|
719
720
|
}
|
package/agents/PROMPTS.md
CHANGED
|
@@ -1,7 +1,21 @@
|
|
|
1
1
|
# ToonLab agent prompts
|
|
2
2
|
|
|
3
3
|
These prompts are included with the npm package. They use only the supported
|
|
4
|
-
0.4.
|
|
4
|
+
0.4.23 runtime, agent skills, and MCP workflows.
|
|
5
|
+
|
|
6
|
+
## New playable game
|
|
7
|
+
|
|
8
|
+
```text
|
|
9
|
+
Use the installed ToonLab game-dev skill to build the game described in my
|
|
10
|
+
request. Implement the host gameplay, input, camera, UI and level structure;
|
|
11
|
+
use ToonLab's public APIs for the supported visual and runtime systems. Start
|
|
12
|
+
with a playable slice that has movement, collision, one objective and restart,
|
|
13
|
+
then replace placeholders and apply the selected style. Use the installed
|
|
14
|
+
version's export map, preserve asset/material identities, assign one update
|
|
15
|
+
owner per system, and verify actual keyboard/pointer input, resize and teardown.
|
|
16
|
+
Do not invent package APIs or describe the result as polished before inspecting
|
|
17
|
+
it at the gameplay camera. Report remaining limitations concretely.
|
|
18
|
+
```
|
|
5
19
|
|
|
6
20
|
## Existing-scene integration
|
|
7
21
|
|
|
@@ -71,8 +85,8 @@ species engine.
|
|
|
71
85
|
```text
|
|
72
86
|
Using the ToonLab rockgen and rock-ground-shaders skills, create or edit the
|
|
73
87
|
requested rock asset with @call-me-sensei/toonlab/rockgen and style it with
|
|
74
|
-
@call-me-sensei/toonlab/rock-shader.
|
|
75
|
-
collision, and
|
|
88
|
+
@call-me-sensei/toonlab/rock-shader. Preserve geometry identity, seed, surface recipe, authored masks, LOD,
|
|
89
|
+
collision, and bake provenance; keep reusable appearance in
|
|
76
90
|
the rock shader profile. Validate the portable documents and verify the result
|
|
77
91
|
from multiple useful views. Do not deep-import repository compilers or test
|
|
78
92
|
fixtures.
|
package/agents/README.md
CHANGED
|
@@ -4,7 +4,8 @@ These are downloadable AI coding agent resources for developers using ToonLab
|
|
|
4
4
|
runtime features in their own apps. They are not maintenance instructions for
|
|
5
5
|
this repository.
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
For a new game, implement a playable host-game slice and then apply ToonLab.
|
|
8
|
+
For an existing scene, preserve its authorized layout and systems: apply the
|
|
8
9
|
focused character, manufactured, ground, rock, vegetation, water, sky, cloud,
|
|
9
10
|
lighting, and post runtimes; find assets through Gallery or MCP; and author
|
|
10
11
|
bounded portable outputs. The package does not promise reliable one-shot scene
|
|
@@ -22,12 +23,14 @@ Layout:
|
|
|
22
23
|
runtime-boundary, sourcing-policy, and custom-gap contracts used by every
|
|
23
24
|
agent integration.
|
|
24
25
|
|
|
25
|
-
Recommended feature skills (start with `game-dev` for existing-scene
|
|
26
|
+
Recommended feature skills (start with `game-dev` for new-game development or existing-scene
|
|
26
27
|
integration and `asset-sourcing` for Gallery/MCP work):
|
|
27
28
|
|
|
28
29
|
- `asset-sourcing`
|
|
29
30
|
- `environment`
|
|
30
31
|
- `game-dev`
|
|
32
|
+
- `lighting`
|
|
33
|
+
- `scene-style-application`
|
|
31
34
|
- `post-processing`
|
|
32
35
|
- `rock-ground-shaders`
|
|
33
36
|
- `rockgen`
|
|
@@ -42,7 +45,7 @@ artifact. This includes whole-world construction, natural cliff formation,
|
|
|
42
45
|
Weather/Climate composition, camera behavior, game feel, and gameplay VFX.
|
|
43
46
|
|
|
44
47
|
These text-only resources ship with the npm package beside the runtime source.
|
|
45
|
-
The package does not include ToonLab lab applications,
|
|
48
|
+
The package does not include ToonLab lab applications, repository demo applications, review
|
|
46
49
|
fixtures, models, textures, or other redistributed visual/media assets.
|
|
47
50
|
First-party grass geometry and materials are generated by runtime code; the
|
|
48
51
|
optional CC0 mannequin resolves from immutable public R2 rather than npm.
|
|
@@ -52,3 +55,10 @@ root needs a stable target ID/domain, and every material slot needs a stable
|
|
|
52
55
|
material ID plus semantic role in the versioned ToonLab material contract.
|
|
53
56
|
Root-only labels do not make multi-material assets bundle-ready. Strict mode
|
|
54
57
|
blocks incomplete assets; advisory mode must report them as incomplete.
|
|
58
|
+
|
|
59
|
+
References beginning `agents/` resolve under the installed package root. Do not
|
|
60
|
+
copy the shared guide over an existing game instruction file: add a reference
|
|
61
|
+
to it, or merge only relevant guidance. Individual skills copied to an agent's
|
|
62
|
+
skill directory still read shared references from the installed package.
|
|
63
|
+
See `references/game-lifecycle.md` for update ownership and
|
|
64
|
+
`examples/game-foundation.mjs` for a copyable, verified playable blockout.
|
package/agents/claude/CLAUDE.md
CHANGED
|
@@ -2,6 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
## Claude Code
|
|
4
4
|
|
|
5
|
+
- Resolve `agents/` references from the installed package root.
|
|
6
|
+
- Use the `game-dev` skill for new games and integration; host-owned input,
|
|
7
|
+
gameplay and layout are part of requested game development.
|
|
5
8
|
- Use `agents/skills/claude/` as the user-facing usage guides for ToonLab
|
|
6
9
|
runtime features.
|
|
7
10
|
- Keep this file short; shared guidance belongs in `agents/codex/AGENTS.md`.
|