SuperAPI AI Directory

threejs-spine-generative-reskin

General & other

View repository

Updated 10-16 09:27

About this skill

three.js Spine generative reskinning

This Skill is only used within an authorized three.js Work Item, and its deliverables are limited to optional 2D HUD or billboard assets; it does not handle 3D character primary animation. It preserves the original Skeleton, Attachment, anchor points, Atlas Region geometry, and Mesh UV semantics; candidate assets are always validated in an independent diagnostic directory. three.js itself does not have a built-in Spine Runtime; runtime validation and any project integration must use the Spine adapter specifically implemented by the target project, and candidate assets must not be described directly as three.js native Spine objects.

Entry

node <skill-dir>/scripts/spine_reskin_progress.mjs --help

The official original directory can use inspect --asset-dir <原版资源目录> or init --asset-dir <原版资源目录>; independent Skeleton/Atlas/Page will be audited directly, Cocos sp.SkeletonData 's _atlasText/_skeletonJson will first be exported to an independent normalized candidate directory, and the source directory will never be rewritten.init The control-plane manifest must also be passed in, binding the Work Item, production contract, and applicable V2 plan evidence.

The progress manifest must be schema v3. All commands that modify the manifest use cross-process locks and atomic writes; manually editing states to fake completion is prohibited. For detailed rules, see:

Fixed workflow

  1. inspect Reads the Skeleton JSON and Atlas, and outputs version, Bone, Slot, Skin, Attachment, Mesh, Animation, Page, Region statistics, attachment path mapping, and stable hashes of Mesh vertices/triangles/UVs.
  2. init Creates a schema v3 manifest, recording the SHA-256 of all source files. When lower than the target Runtime, only candidates generated by external official tools are accepted, using upgrade-check to compare structural projections; before target Runtime parsing evidence is passed, any batch command will be blocked.
  3. freeze-contract Freezes the character name, target Runtime, dark visual direction, six-item palette, material language, light direction, and default strict_alpha=true. Temporary palettes must not be used before the first batch.
  4. plan-batches Imports the exact Region order, mode, alpha lock, and optional continuous effect sequences, and machine-validates full-set coverage, no duplicates/omissions, Mesh using mesh-safe and locked Alpha.
  5. Execute according to batch prepare → mark generated → batch review → 停止 → batch accept .batch accept Must bind the current review image SHA, candidate SHA/fingerprint, and current batch revision; in the review context just displayed and precisely bound by --batch and --review-sha , a brief "confirm" is sufficient to pass, or the full confirmation sentence corresponding to the current batch may be used (for the initial batch, "confirm batch N"; for rework, "confirm restarted batch N"). Blank, irrelevant, or negative text is still rejected. The receipt is the V4 local spine_batch_acceptance, not a second global visual approval. Rework uses batch reopen to increase the revision, affecting only the current batch.
  6. After all batches are ACCEPTED+locked , execute pack. By default and as formally fixed, padding=0、extrusion=0; Page names must remain original and actually be PNG; the blank-line format between Atlas Pages/Regions is fixed by the serializer.
  7. Use runtime-validate to submit the spine-runtime-validation/2.0 structured report, specifying integration_adapter.mode=project-specific and purpose optional-2d-hud or optional-2d-billboard, and provide the real parsing evidence of the target project adapter, the full set of dynamic animations, the Idle loop, texture/anchor/Mesh/flicker/clipping checks, a summary, URL, desktop and approximately 390px mobile screenshots, and SHA. Only after passing may it finalize, and finally use report to generate the final delivery report. This validation only covers 2D HUD/billboard assets; it does not represent three.js's built-in Spine support, nor does it grant 3D character animation or main-game integration capabilities.

State hard gate

The Cell state is fixed as:

pending → generating → generated → validating → packing → packed → runtime_validating → completed

A formal Cell must be an actual PNG, contain Alpha, and have dimensions equal to the forward Atlas Region;alpha_lock=true the Alpha mask must be pixel-level consistent, and the Mesh must always lock to Alpha.constrained-redraw Only explicit alpha_lock=false is allowed to be used.

Global visual and batch confirmation boundaries

The global visual stage, state, and confirmation rules are subject to the threejs-game-workflow-control 'scontrol model、states and gatesand Schema. Proposal, review or examination, and batch locking in Spine reskinning must all be completed within the existing Work Item scope of the current user task; this Skill only modifies its own candidate artifacts and does not expand the task scope on its own or create global approvals. Changes to scope, proposal, or path within the task must synchronously update the plan and revalidate the affected parts; when the product direction, visual direction needs to change, or integration into the main game is required, return to the control plane for re-review. Spine batch confirmation belongs to the V4 local production lock receipt, does not enter the Approval Ledger, and does not change the Scene V2 decomposition and layout confirmation.