@genex-ai/cli-demo 1.30.0-dev.645 → 1.31.1

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 (47) hide show
  1. package/README.md +0 -18
  2. package/dist/index.js +2839 -4768
  3. package/package.json +3 -3
  4. package/templates/controllers/character/follow-camera.ts +1 -16
  5. package/templates/controllers/character/meshy/meshy-loader.ts +2 -3
  6. package/templates/controllers/quality/pick-asset.ts +16 -49
  7. package/templates/controllers/shared/physics-world.ts +4 -6
  8. package/templates/skills/genex-ai-character/SKILL.md +15 -77
  9. package/templates/skills/genex-ai-menu/SKILL.md +11 -15
  10. package/templates/skills/genex-ai-model/SKILL.md +7 -45
  11. package/templates/skills/genex-ai-texture/SKILL.md +1 -1
  12. package/templates/skills/genex-ai-video/SKILL.md +17 -75
  13. package/templates/skills/genex-game-director/SKILL.md +46 -112
  14. package/templates/skills/genex-game-director/references/design-contract.md +5 -13
  15. package/templates/skills/genex-game-director/references/routing-map.md +45 -30
  16. package/templates/skills/genex-getting-started/SKILL.md +2 -2
  17. package/templates/skills/genex-monetization/SKILL.md +177 -0
  18. package/templates/skills/genex-threejs-adaptive-quality/SKILL.md +0 -21
  19. package/templates/skills/genex-threejs-character-controller/SKILL.md +5 -17
  20. package/templates/skills/genex-threejs-creatures/SKILL.md +1 -8
  21. package/templates/skills/genex-threejs-embed-auth/SKILL.md +57 -8
  22. package/templates/skills/genex-threejs-game-ui/SKILL.md +6 -55
  23. package/templates/skills/genex-threejs-procedural-assets/SKILL.md +10 -17
  24. package/templates/skills/genex-threejs-visual-validation/SKILL.md +2 -12
  25. package/templates/skills/genex-tool-audio/SKILL.md +2 -3
  26. package/templates/skills/genex-tool-character/SKILL.md +5 -36
  27. package/templates/skills/genex-tool-image/SKILL.md +2 -4
  28. package/templates/skills/genex-tool-model/SKILL.md +6 -32
  29. package/templates/skills/genex-tool-texture/SKILL.md +1 -1
  30. package/templates/skills/genex-tool-video/SKILL.md +5 -28
  31. package/templates/skills/genex-tool-workflow/SKILL.md +1 -4
  32. package/templates/skills/genex-updates/SKILL.md +1 -1
  33. package/dist/blender-mcp-Q6PSFYSE.js +0 -241
  34. package/dist/blender-serve-BF4FZ55Z.js +0 -244
  35. package/dist/chunk-2COG4P3T.js +0 -968
  36. package/dist/chunk-HYCSNWYX.js +0 -126
  37. package/templates/blender-service/demo/castle.py +0 -117
  38. package/templates/blender-service/gpu_witness.py +0 -245
  39. package/templates/blender-service/ops.py +0 -225
  40. package/templates/blender-service/pool.py +0 -910
  41. package/templates/blender-service/server.py +0 -611
  42. package/templates/blender-service/supervisor.py +0 -221
  43. package/templates/blender-service/views.py +0 -281
  44. package/templates/controllers/quality/deadline.ts +0 -117
  45. package/templates/skills/genex-blender-scene/SKILL.md +0 -243
  46. package/templates/skills/genex-lane-card/SKILL.md +0 -78
  47. package/templates/skills/genex-tool-publish/SKILL.md +0 -100
@@ -85,8 +85,7 @@ npx genex controller character --character <character-id>
85
85
 
86
86
  Meshy Image-to-3D first produces an unremeshed high-detail model. Show its
87
87
  front, back, left, and right views and report its measured face count. Preserve
88
- that model in R2. The triangle remesh at the approved face budget (10,000
89
- by default; up to 100,000 for a hero)—not the high-detail
88
+ that model in R2. The 10,000-face triangle remesh—not the high-detail
90
89
  source—is rigged and animated. In the default lane proceed to it directly;
91
90
  for a player-requested custom character, ask for their explicit approval
92
91
  first (question tool when you have one; a short numbered list in chat
@@ -136,9 +135,6 @@ fork as a migration strategy. Install a fresh copy elsewhere and port only the n
136
135
  ## Minimal wiring
137
136
 
138
137
  ```ts
139
- import { initEmbed, waitForPlayer } from "@genex-ai/embed-sdk";
140
- import { GENEX } from "./genex.config";
141
- import * as THREE from "three";
142
138
  import { PhysicsWorld } from "./controllers/shared/physics-world.ts";
143
139
  import { CharacterController } from "./controllers/character/character-controller.ts";
144
140
  import { CharacterAnimations } from "./controllers/character/character-animations.ts";
@@ -149,15 +145,7 @@ import { createAimCue } from "./controllers/character/aim-cue.ts";
149
145
  import { KeyboardInput } from "./controllers/character/keyboard-input.ts";
150
146
  import { loadPlayerCharacter } from "./controllers/character/player-character.ts";
151
147
  import { capsuleFromModel } from "./controllers/character/vrm/capsule-fit.ts";
152
-
153
- initEmbed({ slug: GENEX.slug, apiUrl: GENEX.apiUrl, dashboardOrigins: GENEX.dashboardOrigins }); // FIRST — before any await
154
-
155
- // draw first; identity takes seconds on a hosted page
156
- const renderer = new THREE.WebGLRenderer({ antialias: tier.antialias, ...depthRendererOptions() }); // tier + depthRendererOptions: the quality kit
157
- const scene = new THREE.Scene();
158
- const camera = new THREE.PerspectiveCamera(60, innerWidth / innerHeight, near, far);
159
- document.body.appendChild(renderer.domElement);
160
- renderer.render(scene, camera); // a frame is on screen before anything below is awaited
148
+ import { waitForPlayer } from "@genex-ai/embed-sdk";
161
149
 
162
150
  const physics = await PhysicsWorld.create(); // nothing RAPIER-related may run before this resolves
163
151
 
@@ -166,13 +154,13 @@ const physics = await PhysicsWorld.create(); // nothing RAPIER-related may run b
166
154
  // (with that character's exact-rig clips and locomotion profile), and falls
167
155
  // back to the visiting player's own profile avatar when it isn't — retargeting
168
156
  // the bundled core library plus any packs installed by `genex controller
169
- // anims`. `user.avatarUrl` comes from the embed identity (the `initEmbed`
170
- // call above — $genex-threejs-embed-auth owns it) and is used only in that
157
+ // anims`. `user.avatarUrl` comes from the embed identity
158
+ // ($genex-threejs-embed-auth boots before this) and is used only in that
171
159
  // fallback lane; the baked `./assets/avatar.vrm` covers local dev and load
172
160
  // failures. WRITE THIS ONCE: when the generated character lands mid-build,
173
161
  // `genex controller character --character <id>` drops the manifest in and the
174
162
  // next reload swaps the body. Nothing below changes.
175
- const { user } = await waitForPlayer(); // identity, awaited HERE — where the avatar is needed, never as the first line of the boot
163
+ const { user } = await waitForPlayer(); // from "@genex-ai/embed-sdk"
176
164
  const player = await loadPlayerCharacter({ avatarUrl: user.avatarUrl });
177
165
 
178
166
  const fit = capsuleFromModel(player.scene); // collider fits THIS body's bounds
@@ -29,10 +29,6 @@ the rig). Route by silhouette:
29
29
  locomotion clips for exactly the shapes Meshy refuses — see
30
30
  `$genex-ai-model` for the full flow, presets, and honest limits (avian rigs
31
31
  have no preset clips; drive those bones in code).
32
- - **A mesh the player already has** (their own creature file): `npx genex
33
- model import <file.glb>` first — free — then the same routing by
34
- silhouette: biped → `npx genex character import` (Uthana auto-rig),
35
- anything else → `npx genex model rig`. Never rebuild what they handed you.
36
32
  - **Everything outside both** (swarms, blobs, amorphous things — no body plan
37
33
  to rig): the **static + procedural lane** — `npx genex model` for the body,
38
34
  motion authored in code. Say it honestly in the Assets table:
@@ -57,10 +53,7 @@ npx genex creature "hulking bone seraph, tattered wing membranes, upright stance
57
53
  ```
58
54
 
59
55
  Each creature is one Assets-table row (visible spend — the usual budget
60
- rules). It runs Meshy 7 like the player body; the knobs are yours: a crowd
61
- enemy is `--polycount 10000 --no-ultra --texture 2k`, a boss seen in close-up
62
- `--polycount 30000` (`--texture 8k` if the camera lingers), `--pose t-pose`
63
- when a rig keeps failing structural QA in a-pose. The result is a rigged GLB whose clips play on a standard
56
+ rules). The result is a rigged GLB whose clips play on a standard
64
57
  `THREE.AnimationMixer`; Meshy limb rotations play unchanged — never apply
65
58
  post-mixer limb corrections. Prompt the body UPRIGHT and unpropped (held
66
59
  props fuse into bodies); prompt "facing the viewer" but never trust it —
@@ -54,14 +54,6 @@ initEmbed({
54
54
  });
55
55
  ```
56
56
 
57
- **Create the renderer and draw a frame BEFORE you await identity; `await
58
- waitForPlayer()` only where you need the name or the token.** On a hosted page
59
- identity takes seconds (the dashboard handshake, or the standalone bounce), so
60
- a `main.ts` whose first statement is `const { user } = await waitForPlayer()`
61
- shows black for all of them — and forever when `initEmbed()` was never called,
62
- because nothing else resolves that promise. Renderer, scene, camera, first
63
- frame, then the await, down where the name or the avatar is actually used.
64
-
65
57
  Also give `<body>` a dark background in `index.html` (e.g.
66
58
  `<body style="margin:0;background:#080a14">`) — it makes the pre-boot frame
67
59
  (before any JS runs) match the SDK's own loading overlay instead of flashing
@@ -156,6 +148,63 @@ Server write limits (per player, per minute): **60 player-saves, 120
156
148
  world-saves, 30 score submits**. A debounced ~1/sec checkpoint never gets near
157
149
  them — only a save-per-frame loop does (it surfaces as HTTP 429).
158
150
 
151
+ Runtime generation (SDK 0.21.0+, signed-in production play, default-off service):
152
+
153
+ - `getGenerationModels()` returns configured models and personal providers.
154
+ A 404 means this environment has not enabled generation.
155
+ - `generate({ estimateCoins, modelId, prompt, outputFormat: 'text' | 'json',
156
+ schema?, allowExternal?, idempotencyKey?, timeoutMs? })` returns execution,
157
+ output/source on success, and charged/reserved coin plus authoritative USD.
158
+ Call directly from a click before any await to reserve its trusted popup.
159
+ - Required `estimateCoins` is the fixed price of a started attempt, despite its
160
+ name: fixed 5 charges 5 even if usage would cost 2. New `declared-v1` quotes
161
+ charge that full price on failure, cancellation or a budget limit after work
162
+ starts. No model work is zero; a usable result is not guaranteed. Zero is
163
+ accepted only when the server allows a free or personal-only option.
164
+ - `getGeneration(id)` reads the private player/game-scoped receipt;
165
+ `waitForGeneration(id)` waits for execution. A timeout does not cancel.
166
+ Keep reading while billing is pending; unknown expense retains the hold and
167
+ missing receipt fields never mean zero. Saved consumed/legacy policies remain.
168
+
169
+ Registered workflows require an existing trusted, operator-registered executor:
170
+
171
+ - `getWorkflowOfferings(workflowId)` supplies model, bundle, availability,
172
+ suggested prices and frozen operator tariff. Calibrate the game's fixed price
173
+ with development benchmarks, then show coin and USD beside the selected option.
174
+ Its public offerings contain API/model rows, including sponsored free models;
175
+ personal plan funding appears only in the trusted Genex approval modal.
176
+ - `requestWorkflow({ workflowId, offeringId, input, estimateCoins, allowExternal?,
177
+ idempotencyKey?, timeoutMs? })` returns **approval**, not completion. Call from
178
+ the click, then send its generation ID, exact input and fresh `getEmbedToken()`
179
+ to the game backend to claim/enqueue. Waiting for completion first deadlocks it.
180
+ - Persist input, declared price, offering, operation key and generation ID across
181
+ reloads. Never persist the token or auto-charge on boot. Use
182
+ `resumeWorkflow(generationId)` from a click to reopen saved approval through
183
+ GET only, preserving pre-0.21 quotes without a replacement price.
184
+ - The server derives the hard model budget from the fixed price after its tariff.
185
+ Only the selected model runs. The trusted executor validates staged artifacts;
186
+ the browser cannot submit costs, settle a bill or claim delivery.
187
+
188
+ Both APIs with `allowExternal: true` can offer a configured personal plan beside
189
+ coins: Claude for Claude models, ChatGPT for ChatGPT models, and neither for
190
+ other model families. Keep this choice in the trusted Genex approval modal; never
191
+ render a "Your Plan" entry in the game's model picker. Each costs zero, uses that
192
+ player's own plan limits and never falls back to paid work. Approved personal
193
+ requests retain their connector for recovery; historical personal-only offerings
194
+ cannot become free coin execution. Submitted results are `source: 'external'` and
195
+ `modelProvenance: 'unverified'`; never treat them as authority for rewards.
196
+ Genex handles connector setup; games never collect subscription credentials.
197
+
198
+ For calibration, server-only `@genex-ai/embed-sdk/development` uses your full
199
+ creator bearer credential, owned project and explicit `maxCoins` to benchmark
200
+ actual usage against your own wallet, with no production-play token. It uses
201
+ `consumed-v1`, including failed work, and returns charged coins, output and
202
+ actual/unknown provider cost. Public-sponsored API models are paid at the normal
203
+ tariff here; personal-only options are refused. Never bundle a creator credential
204
+ or expose it through Vite variables. Read `$genex-monetization` for generic and
205
+ registered-workflow examples. Native WebViews and local-test player identity
206
+ still cannot use public generation confirmation.
207
+
159
208
  ## Saving progress (per-player — every player has their own slot)
160
209
 
161
210
  Use the SDK helpers; never hand-roll fetch calls to the state API. Progression,
@@ -134,55 +134,14 @@ overlay — HTML/CSS on top of the canvas, not text sprites inside the scene:
134
134
 
135
135
  ```css
136
136
  #ui { position: fixed; inset: 0; pointer-events: none; font-variant-numeric: tabular-nums; }
137
- /* Layout belongs to the SHOWN screen only. Never `#ui .screen { display: }`:
138
- that overrides the browser's `[hidden] { display: none }`, and every hidden
139
- screen is laid out full-viewport, invisible, on top of the one that is up. */
140
- #ui .screen:not([hidden]) { display: flex; }
141
- /* Clickable only while shown (`.is-on` is the shown class — Motion, below). */
142
- #ui .screen.is-on, #ui #hud button { pointer-events: auto; }
137
+ #ui button, #ui .screen { pointer-events: auto; }
143
138
  ```
144
139
 
145
140
  `pointer-events: none` on the root keeps the canvas playable; re-enable it only
146
- on elements that are actually clickable and only while they are on screen.
147
- Keep ALL layout in CSS — never position UI by mutating inline pixel styles per
148
- frame. In-world (diegetic) UI — a health bar floating over an enemy, a
149
- scoreboard mesh in a stadium — is the exception for things that belong to the
150
- world, not the default.
151
-
152
- ### Inactive screens are gone, not see-through
153
-
154
- An invisible screen that is still laid out is a click trap nobody can see: the
155
- title's Start button renders, the pointer hovers it, and the click lands on a
156
- transparent pause card sitting last in DOM order. Three rules:
157
-
158
- 1. **An inactive screen is `display: none`** — via `hidden` or a class — never
159
- merely `opacity: 0`. And NEVER set `display` on the `.screen` selector
160
- itself: `.screen { display: flex }` beats the browser's `[hidden]` rule, so
161
- `hidden` stops hiding anything. Put `display: flex` on
162
- `.screen:not([hidden])` or on the shown class.
163
- 2. **`pointer-events: auto` belongs only to the screen that is currently
164
- shown.** An invisible screen with clickable descendants swallows every click
165
- meant for the screen under it, so scope `pointer-events` to `.screen.is-on`
166
- (and to HUD controls) — never to `#ui .screen` or `#ui button` at large.
167
- 3. **The smoke check for every boot/title/pause screen:** for each visible
168
- button, `document.elementFromPoint(cx, cy)` at its centre must return the
169
- button or one of its descendants. A top hit whose effective (inherited)
170
- opacity is 0 is a defect, not a styling choice — some screen is laid out
171
- over the one the player sees. One paste in the console:
172
-
173
- ```js
174
- [...document.querySelectorAll("#ui button")].filter((b) => b.getClientRects().length).map((b) => {
175
- const r = b.getBoundingClientRect(), top = document.elementFromPoint(r.x + r.width / 2, r.y + r.height / 2);
176
- let o = 1; for (let e = top; e; e = e.parentElement) o *= +getComputedStyle(e).opacity;
177
- const ok = !!top && b.contains(top);
178
- return { button: b.textContent.trim(), ok, coveredBy: ok ? null : top?.closest(".screen")?.id ?? top?.tagName ?? "offscreen", topOpacity: o };
179
- })
180
- ```
181
-
182
- Every row reads `ok: true`; a `coveredBy` naming a screen with
183
- `topOpacity: 0` is rule 1 or 2 broken. Run it on the title screen and again
184
- with the pause screen up — `$genex-threejs-visual-validation` carries the
185
- same check in its smoke pass.
141
+ on elements that are actually clickable. Keep ALL layout in CSS never
142
+ position UI by mutating inline pixel styles per frame. In-world (diegetic) UI —
143
+ a health bar floating over an enemy, a scoreboard mesh in a stadium — is the
144
+ exception for things that belong to the world, not the default.
186
145
 
187
146
  ## The states every game needs
188
147
 
@@ -320,8 +279,7 @@ black reads as a broken page. The branded version costs nothing:
320
279
  ## Motion — screens move or the game feels dead
321
280
 
322
281
  Phase changes animate. `hidden` alone hard-cuts; pair it with a class so
323
- opacity can transition — the class owns opacity and `pointer-events`, `hidden`
324
- keeps owning `display`:
282
+ opacity can transition:
325
283
 
326
284
  ```ts
327
285
  function setPhase(phase: "loading" | "playing" | "paused" | "over" | "won") {
@@ -340,8 +298,6 @@ function setPhase(phase: "loading" | "playing" | "paused" | "over" | "won") {
340
298
  ```
341
299
 
342
300
  ```css
343
- /* Opacity only — `display` stays with `hidden` (Architecture, above). Setting
344
- `display` here would lay every hidden screen out over the shown one. */
345
301
  #ui .screen { opacity: 0; transition: opacity 280ms ease; }
346
302
  #ui .screen.is-on { opacity: 1; }
347
303
 
@@ -475,11 +431,6 @@ widget gets its numbers.
475
431
  HUD — pick the 2–3 numbers that matter and style them by hierarchy.
476
432
  - Hard-cut phase swaps, a menu whose elements just appear, numbers that
477
433
  teleport.
478
- - An invisible screen still laid out over the one the player sees — `display`
479
- set on `.screen` (defeating `hidden`), or an `opacity: 0` screen that kept
480
- `pointer-events: auto` — so the title's Start button never receives its
481
- click; the hit-test in "Inactive screens are gone, not see-through" catches
482
- it.
483
434
  - A silent menu; a bare "Loading…" over black.
484
435
  - Generated UI art enqueued and then left on the shelf — a landed sprite sheet
485
436
  that never got extracted, masked, and wired is worse than never running the
@@ -1,34 +1,30 @@
1
1
  ---
2
2
  name: genex-threejs-procedural-assets
3
- description: Build editable, parameterized Three.js objects in code — modular kits, structural pieces, repeated or varied props, and any object code will honestly make read as the thing it is — or whenever the user asks for procedural/parametric work. A first-class lane alongside generated GLBs, held to the same bar; mix both freely.
3
+ description: Build editable, parameterized Three.js objects in code — structures, buildings, modular kits, repeated or varied props whenever code is the more efficient engine for them, or the user asks for procedural/parametric work. A first-class lane alongside generated GLBs; mix both freely.
4
4
  ---
5
5
 
6
6
  # Genex Three.js Procedural Assets
7
7
 
8
8
  Build a recognizable asset as local, editable Three.js code. This lane is a
9
- first-class engine, not a fallback and it is held to the same bar as a
10
- generated GLB: the result must read as the thing it is when the player looks at
11
- it, in the game's own style. A coloured box or a flat grey block is a blockout,
12
- never a landed asset. Mixing procedural pieces with generated pieces in the
13
- same scene is the normal way to build a detailed, lively world.
9
+ first-class engine, not a fallback: for structures, buildings, modular kits,
10
+ and anything placed many times with variation, code is often more efficient
11
+ than a generated GLB and mixing procedural pieces with generated hero
12
+ pieces in the same scene is the normal way to build a detailed, lively world.
14
13
 
15
14
  ## Choose the route
16
15
 
17
16
  - Start directly when the user says procedural, parametric, code-built,
18
17
  customizable, seeded, or asks for controlled variations.
19
- - Also start directly for what is structural, repeated, distant, or
20
- parametric: terrain, modular environment kits, fences, pipes, rails, walls,
21
- paving, and anything placed many times with variation.
22
- - For anything the player looks at up close, walks into, or interacts with — a
23
- named building, a signature prop, a vehicle — code is a choice, not a
24
- default: take it only when you will honestly reach the bar above, and confirm
25
- it in a capture at gameplay distance before the row reads `landed`. Otherwise
26
- `$genex-ai-model` owns it.
18
+ - Also start directly when code is plainly the efficient route: buildings and
19
+ structures, modular environment kits, fences, pipes, rails, and anything
20
+ placed many times with variation.
27
21
  - An attached or available image does not activate this skill by itself.
28
22
  - If “make this image 3D” could honestly mean either route, ask exactly one
29
23
  question: **“Do you want a generated textured GLB, or editable procedural
30
24
  Three.js code?”**
31
25
  - Use `$genex-ai-model` when the user chooses a generated textured GLB.
26
+ - Use this skill for props, hard-surface objects, modular decorations, and
27
+ simple structures or environment pieces.
32
28
  - Do not use it for characters, creatures, rigging, skeletal animation, or
33
29
  character likeness. Keep those in their existing specialist lanes.
34
30
 
@@ -64,9 +60,6 @@ proposed → planned → building (blockout | detail | material | runtime)
64
60
  → landed (<local TypeScript path>) → wired
65
61
  ```
66
62
 
67
- `landed` means a capture at gameplay distance showed it reads as the thing it
68
- is — not that the file exists.
69
-
70
63
  A Genex-generated reference keeps its separate image row and normal paid
71
64
  generation status. Note that the procedural-code row is derived from that
72
65
  image. A private user reference is not a paid generation row.
@@ -37,8 +37,7 @@ overlapping props or straps can fuse into the character or hide a limb.
37
37
 
38
38
  Meshy Image-to-3D first produces an unremeshed high-detail model. Show its
39
39
  front, back, left, and right views and report its measured face count. Preserve
40
- that model in R2. The triangle remesh at the approved face budget (10,000
41
- by default; up to 100,000 for a hero)—not the high-detail
40
+ that model in R2. The 10,000-face triangle remesh—not the high-detail
42
41
  source—is rigged and animated. In the default lane the remesh proceeds
43
42
  directly; for a player-requested custom character, wait for their explicit
44
43
  approval first (question tool when you have one; a short numbered list in
@@ -73,13 +72,7 @@ everything twice.
73
72
  console errors). For an unpublished draft, open the dev server in local
74
73
  test mode — `http://localhost:5173/?genex_local_test=1` (the embed-auth
75
74
  skill's "Self-testing a draft" section) — so you see the game, not the
76
- sign-in gate. Then hit-test the screen that is up (title now, pause later):
77
- for every visible button, `document.elementFromPoint(cx, cy)` at its centre
78
- must return the button or one of its descendants — a top hit whose
79
- effective (inherited) opacity is 0 is an invisible screen still laid out
80
- over this one (a `display` rule on `.screen` defeating `hidden`, or an
81
- `opacity: 0` screen keeping `pointer-events: auto`), and nobody can enter
82
- the game. `$genex-threejs-game-ui` has the one-paste check and the fix.
75
+ sign-in gate.
83
76
  2. Press each documented control once (keys, pointer); assert a **visible
84
77
  response in its labeled direction** — this is the input-direction pass, and
85
78
  it is part of THIS check, not an extra testing loop. Hold `KeyD`/ArrowRight
@@ -366,9 +359,6 @@ visual-system work — the sequence above.
366
359
  - a non-cursor-core game that leaves the OS cursor visible during play;
367
360
  - a menu or settings click locks the pointer (or the cursor vanishes) while a
368
361
  menu screen is still up;
369
- - a title, boot, or pause button whose centre hit-test returns an element of a
370
- screen that is not visibly up (effective opacity 0) — an invisible overlay is
371
- swallowing the click;
372
362
  - approval relies on a single frame;
373
363
  - post-processing cannot be disabled per pass;
374
364
  - random seeds are not reproducible;
@@ -53,9 +53,8 @@ and let the player skip.
53
53
 
54
54
  ## Cost
55
55
 
56
- From **2 credits** an sfx · **27** a 90 s music track · **2** a short voice line
57
- (voice bills per character, up to 12 at the 1000-character cap; 1 credit = $0.01).
58
- Longer `--duration`s cost more. Live prices and your balance: `npx genex doctor`.
56
+ Typical: **5 credits** an sfx · **40** a music track · **10** a voice line.
57
+ Live prices and your balance: `npx genex doctor`.
59
58
 
60
59
  ## Waiting
61
60
 
@@ -24,28 +24,13 @@ npx genex character preview <concept-id> --candidate 2 --user-approved
24
24
  # → a 3D preview of that one, four views. Show it; wait for approval.
25
25
 
26
26
  npx genex character finalize <preview-id> --user-approved --approve-remesh 10000
27
- # → the rigged, game-ready character at that face budget.
27
+ # → the rigged, game-ready character.
28
28
  ```
29
29
 
30
30
  Each step needs the previous step's generation id. The approval flags are not
31
31
  ceremony: they record that a person actually looked and chose, and each step
32
32
  costs credits.
33
33
 
34
- ## The knobs (Meshy 7 on every lane)
35
-
36
- Ultra and 4k textures are the defaults; every knob is priced in the quote.
37
- Pick per role and say so in one line:
38
-
39
- - `--approve-remesh <faces>` (finalize) / `--polycount <faces>` (one shot):
40
- the rigging copy's face budget, 10000-100000 — 10000 for crowds and
41
- distance, 20000-30000 for a third-person player body, 50000+ only for a
42
- close-up hero. Moves no cost.
43
- - `--texture 2k|4k|8k` (preview / one shot): 8k is +5 credits, for close-ups.
44
- - `--no-ultra` (preview / one shot): −5 credits, less surface detail — stand-ins
45
- and crowd enemies.
46
- - `--pose a-pose|t-pose` (one shot): the preferred rest pose.
47
- - `--height <metres>`: 0.5-3, default 1.7.
48
-
49
34
  ## One shot
50
35
 
51
36
  When nobody is choosing — a background NPC, a quick test:
@@ -56,21 +41,7 @@ npx genex creature "hulking bone seraph, upright stance"
56
41
  ```
57
42
 
58
43
  `creature` is the same lane with enemy defaults: no approval steps, no player
59
- controller pack (and priced without one). Biped-shaped bodies only. The knobs
60
- above apply: a crowd enemy is `--polycount 10000 --no-ultra --texture 2k`.
61
-
62
- ## Import a character the user already has
63
-
64
- ```bash
65
- npx genex character import ./knight.glb --height 1.8 # free upload + Uthana auto-rig (finger joints; --no-fingers skips them)
66
- npx genex character animate <id> --locomotion # then the walk/run set — an import has no clips yet
67
- ```
68
-
69
- Biped humanoid, T- or A-pose, feet on the ground, facing +Z, `.glb` ≤ 30 MB.
70
- **Never rebuild a mesh the user gives you** — import it. The result is a
71
- Uthana-rigged body: verbs, `--locomotion` and `--video` work; the Meshy
72
- catalog and controller pack do not. Non-biped bodies: `npx genex model
73
- import` + `npx genex model rig`.
44
+ controller pack. Biped-shaped bodies only.
74
45
 
75
46
  ## Animating it
76
47
 
@@ -104,11 +75,9 @@ look here first — a library clip costs nothing to generate.
104
75
 
105
76
  ## Cost
106
77
 
107
- Typical: **32** concept · **41** preview · **29** finalize · **64** one-shot
108
- character · **46** creature · **18** import (Uthana auto-rig; the upload is
109
- free) · **46 per clip** for a generated move · **free** for a library search
110
- (1 credit = $0.01). `--texture 8k` adds 6, `--no-ultra`
111
- takes 6 off. Live prices and your balance: `npx genex doctor`.
78
+ Typical: **15** concept · **20** preview · **30** finalize · **50** one-shot
79
+ character · **26 per clip** for a generated move · **free** for a library
80
+ search. Live prices and your balance: `npx genex doctor`.
112
81
 
113
82
  ## Waiting
114
83
 
@@ -43,10 +43,8 @@ Wire the **local path**. The URL is provenance — never fetch it at runtime.
43
43
 
44
44
  ## Cost
45
45
 
46
- From **4 credits** per image at default quality (1 credit = $0.01);
47
- `--transparent`, `--quality high`, `--edit` and 4K canvases cost more, and
48
- `--candidates` bills per variant - the command prints the exact quote. Live
49
- prices and your balance: `npx genex doctor`.
46
+ Typical: **8 credits** per image (`--candidates` bills per variant). Live prices
47
+ and your balance: `npx genex doctor`.
50
48
 
51
49
  ## Waiting
52
50
 
@@ -21,17 +21,6 @@ npx genex model --image ./reference-photo.jpg # build it FROM an image; pr
21
21
  Blocks until ready, saves the GLB into `./assets`, and prints the path. Wire the
22
22
  local path; the URL printed beside it is provenance, not hosting.
23
23
 
24
- ## Bring your own mesh
25
-
26
- ```bash
27
- npx genex model import ./hero-cart.glb # free — a file you already have becomes a model of yours
28
- ```
29
-
30
- `.glb` only, ≤ 64 MB (export a `.gltf`/FBX as one binary `.glb` first). The
31
- import is free and checked before it completes; after it, `segment`, `rig`,
32
- `animate` and `character import` all take its id. **Never rebuild a mesh the
33
- user hands you** — import it.
34
-
35
24
  ## Mesh lanes
36
25
 
37
26
  Each takes the **generation id** of a previous model — never a URL.
@@ -42,44 +31,29 @@ npx genex model rig <model-id> --type quadruped
42
31
  npx genex model animate <rig-id> --preset walk,run
43
32
  ```
44
33
 
45
- - **`segment`** — one GLB split into addressable parts: doors, turrets, magazines, destructibles. `--granularity simple|balanced|detailed`. The parts are named by index (`tripo_part_0`, `tripo_part_1`, …), not by what they are — find the one you want by its bounds (the sails are the part with the widest extent, the door the lowest thin one), then keep that index in your manifest.
34
+ - **`segment`** — one GLB whose parts carry NAMES, so you can address them: doors, turrets, magazines, destructibles. `--granularity simple|balanced|detailed`.
46
35
  - **`rig`** — a skeleton for any mesh, across 7 body plans: `biped`, `quadruped`, `hexapod`, `octopod`, `avian`, `serpentine`, `aquatic`. The plan is auto-detected; `--type` picks it. A mesh that cannot be rigged is refused and refunded before the paid step.
47
36
  - **`animate`** — retarget ready-made clips onto a rig, billed per clip. biped: `idle|walk|run|dive|climb|jump|slash|shoot|hurt|fall|turn`; quadruped/hexapod/octopod: `walk`; serpentine/aquatic: `march`.
48
37
 
49
38
  ## Options
50
39
 
51
40
  - `--image <path|url>` — build the model from a reference image (local file ≤ 4 MB, or a previous generation's URL). The prompt becomes optional.
52
- - **Quality knobs** (Tripo H3.1, each priced in the quote — pick per asset, say it in one line): `--texture standard|detailed|none` (detailed default, +10 over standard; none = geometry only), `--geometry detailed` (+20, hero pieces only), `--quad` (+5, for meshes you will edit; face limit ≤150000), `--low-poly` (+10, game-ready topology for props in numbers — it holds `--face-limit` to 1000-20000, 500-10000 with `--quad`; omit the flag to take 20000; it runs a post-process after the mesh, so allow up to 30 minutes), `--parts` (+20, named parts at generation), `--face-limit <n>` (1000-2000000, default 150000; see `--low-poly` for its band), `--auto-size` (real-world metres).
53
41
  - `--out-dir <dir>` — where the file lands (default `./assets`).
54
42
  - `--no-download` — print the URL only.
55
43
  - `--no-wait` — enqueue and return; pick it up with `npx genex wait <id>`.
56
44
 
57
45
  ## Cost
58
46
 
59
- From **35 credits** a model (**46** from a reference image; `--texture standard`
60
- **23**, `--geometry detailed` **58**, `--low-poly` **46**, `--parts` **58**) ·
61
- **46** segment · **29** rig · **12 per clip** for animate (1 credit = $0.01).
62
- Live prices and your balance: `npx genex doctor`.
47
+ Typical: **25 credits** a model · **30** segment · **20** rig · **8 per clip**
48
+ for animate. Live prices and your balance: `npx genex doctor`.
63
49
 
64
50
  ## Waiting
65
51
 
66
52
  Models take the longest of any lane. `--no-wait` is the normal way to run
67
53
  several at once: enqueue them all, keep building, then `npx genex wait --all`
68
- for one status line each in a tools workspace it also downloads every
69
- finished model that is not in `./assets` yet, so one call after a break (or a
70
- restarted session) delivers the whole batch. `npx genex wait <id>` picks one
71
- up. **Re-running the model command bills a NEW model** — never use it as a
72
- status check. Five or so in flight at a time is the provider's comfortable
73
- concurrency; a burst beyond that waits on the server side rather than failing.
74
-
75
- ## Placing a model
76
-
77
- A generated GLB has no shared "front": one building's door faces −x, the next
78
- one's +z. Do not guess and do not spend a render per side — read the mesh once
79
- on load (bounding box, and where the detail is: the door, the counter, the
80
- opening) or check it in a viewer, then record a per-model `front` (a yaw in
81
- your manifest) beside its path and apply it when you place it. Ask for a facing
82
- in the prompt too (`"…front toward +Z"`) — it helps, it does not guarantee.
54
+ for one status line each, and `npx genex wait <id>` to pick one up.
55
+ **Re-running the model command bills a NEW model** never use it as a status
56
+ check.
83
57
 
84
58
  ## Troubleshooting
85
59
 
@@ -39,7 +39,7 @@ repeat — the file names carry the role, so the mapping is unambiguous.
39
39
 
40
40
  ## Cost
41
41
 
42
- From **5 credits** for the whole set (1 credit = $0.01). Live prices and
42
+ Typical: **3 credits** for the whole set the cheapest lane. Live prices and
43
43
  your balance: `npx genex doctor`.
44
44
 
45
45
  ## Waiting
@@ -18,10 +18,6 @@ npx genex video "candle flame flickering in the dark" --loop
18
18
  Blocks until ready, saves the mp4 into `./assets`, and prints the path. Wire the
19
19
  local path — a shipped build must never fetch the URL at runtime.
20
20
 
21
- Every clip carries a **native stereo audio track** (score, foley, ambience).
22
- Browsers only autoplay muted video, so keep the `<video>` element muted unless
23
- the sound is the point — and route it through your game's volume control.
24
-
25
21
  ## Animating a still
26
22
 
27
23
  The strongest results come from conditioning on an image you already approved,
@@ -33,30 +29,13 @@ npx genex video "camera drifts slowly forward, banners stirring" --frame ./asset
33
29
  ```
34
30
 
35
31
  - `--frame <path|url>` — animate FROM this frame back to itself, i.e. a seamless loop. Local file (≤ 4 MB) or a previous generation's URL.
36
- - `--start-frame <path|url>` continue from this frame, no end anchor the clip-chaining primitive.
37
- - `--first-frame <path|url>` / `--last-frame <path|url>` — a two-frame motion between them. All frame anchors take local files.
38
-
39
- Frame anchors are **compositional guidance, not pixel-pinning** — the model
40
- repaints the frame (same scene and composition, not the same pixels), and
41
- regenerating doesn't change that. Chained clips (a cutscene sequence, a
42
- branching video story) stay coherent when each clip starts from the previous
43
- clip's REAL last frame, so drift never accumulates:
44
-
45
- ```bash
46
- ffmpeg -sseof -0.2 -i ./assets/prev.mp4 -update 1 -q:v 1 last.png
47
- npx genex video "she turns and walks toward the far door" --start-frame last.png
48
- ```
49
-
50
- Write chained prompts as CHANGE ONLY — the start frame already says everything
51
- else. Cut clip-to-clip, or crossfade ~200 ms to hide the residual repaint.
32
+ - `--first-frame <url>` / `--last-frame <url>`a two-frame motion between them.
52
33
 
53
34
  ## Options
54
35
 
55
- - `--duration <sec>` — target clip length, 5–15 seconds (default 5; clips bill
56
- per second).
36
+ - `--duration <sec>` — target clip length.
57
37
  - `--loop` — a seamless loop.
58
- - `--resolution <480p|768p|2k|4k>` — default 768p (the top native mode). `2k`/`4k` upscale the same base at ~2–3× the cost; `480p` is the opt-down for clips where fidelity genuinely does not matter. Loop clips ignore it.
59
- - `--ref <path|url>` — repeatable, up to 9 subject/style reference images, cited in the prompt as "Image 1"…"Image N" — the way one character or art style holds across many clips. Cannot combine with `--frame`/`--loop`.
38
+ - `--resolution <720p|1080p>` — default 1080p. `720p` halves the cost, for clips where fidelity genuinely does not matter. Loop clips ignore it.
60
39
  - `--open` — also open it in a browser, for something the user must approve.
61
40
  - `--out-dir <dir>` — where the file lands (default `./assets`).
62
41
  - `--no-download` — print the URL only.
@@ -64,9 +43,8 @@ else. Cut clip-to-clip, or crossfade ~200 ms to hide the residual repaint.
64
43
 
65
44
  ## Cost
66
45
 
67
- From **23 credits** for a 5 s 768p clip (1 credit = $0.01); longer clips, 2K/4K
68
- and `--frame` menu loops cost more, and the command prints the exact quote
69
- before it waits. Live prices and your balance: `npx genex doctor`.
46
+ Typical: **20 credits** per video. Live prices and your balance:
47
+ `npx genex doctor`.
70
48
 
71
49
  ## Waiting
72
50
 
@@ -77,6 +55,5 @@ command bills a NEW clip** — it is never a way to check on one already running
77
55
  ## Troubleshooting
78
56
 
79
57
  - **It failed** — video fails server-side more often than any other lane, and every attempt is minutes. The CLI counts failures in this folder and tells you when to stop: after the second, use a still image instead and say so in one plain line. A third attempt bills the same and returns the same.
80
- - **"Prompt rejected"** — the content-safety filter; never retryable with the same wording. The measured false-positive class is anatomy being pierced or entered (cables/wires/needles into a body — biomech vocabulary trips it). Describe the object or machine instead: "a statue-like figure threaded into the wall" passes where "cables entering her spine" fails.
81
58
  - **Out of credits** — the error prints balance, price and refill date. Relay it; don't retry.
82
59
  - **Anything else** — `npx genex doctor` reports sign-in, credits, and whether the video lane is live.
@@ -92,7 +92,4 @@ tiling floor and three paid assets nobody loaded.
92
92
  Hosting, publishing, multiplayer, remixing and custom domains are the Genex
93
93
  platform, not this toolkit — those commands are refused in this folder by
94
94
  design, and the refusal says where they live. This workspace generates assets
95
- for a game you build and ship yourself. When the user wants that game live on
96
- Genex with its own URL, the AGENTS.md rules say how to offer it; on a yes the
97
- folder is connected to a hosted game in place — same cards, same rules — and
98
- the `$genex-tool-publish` card arrives with the publishing commands.
95
+ for a game you build and ship yourself.
@@ -38,7 +38,7 @@ update, so update immediately.)
38
38
  Run exactly the command the nudge printed, from the game project root:
39
39
 
40
40
  ```bash
41
- npm i -D @genex-ai/cli-demo@dev # the genex CLI (a dev dependency)
41
+ npm i -D @genex-ai/cli-demo@latest # the genex CLI (a dev dependency)
42
42
  npm i @genex-ai/embed-sdk@latest # identity/saves SDK (ships inside the game)
43
43
  npm i @genex-ai/multiplayer@latest # multiplayer SDK (only if the game uses it)
44
44
  ```