pixelkiln 0.62.0 → 0.63.0
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/dist/cli.js +132 -12
- package/dist/cli.js.map +1 -1
- package/dist/index.cjs +130 -12
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +115 -46
- package/dist/index.d.ts +115 -46
- package/dist/index.js +130 -12
- package/dist/index.js.map +1 -1
- package/docs/CHARACTERS.md +39 -0
- package/docs/MANIFEST.md +1 -1
- package/package.json +1 -1
- package/schema/manifest.schema.json +17 -0
- package/skills/pixelkiln/SKILL.md +3 -1
package/docs/CHARACTERS.md
CHANGED
|
@@ -296,6 +296,45 @@ who holds a sword in the right hand holds it in the left when facing the
|
|
|
296
296
|
mirrored way. Most games accept that; if yours does not, generate both
|
|
297
297
|
sides. `adopt` skips mirrors, since there is nothing upstream to adopt.
|
|
298
298
|
|
|
299
|
+
### One loop, several directions
|
|
300
|
+
|
|
301
|
+
Writing each direction out is five near-identical loops and three mirrors
|
|
302
|
+
for a full walk. `directions` on an animation says the same thing once:
|
|
303
|
+
|
|
304
|
+
```json
|
|
305
|
+
"bot.walk": {
|
|
306
|
+
"prompt": "walking forward in place, short legs stepping, body bobbing slightly",
|
|
307
|
+
"animation": { "of": "bot", "frames": 12, "fps": 12, "directions": ["south", "west", "north", "south-west", "north-west"] }
|
|
308
|
+
}
|
|
309
|
+
```
|
|
310
|
+
|
|
311
|
+
When the manifest loads, this becomes exactly the assets it stands for: one
|
|
312
|
+
loop per named direction (`bot.walk.south`, `bot.walk.west`, ...), each with
|
|
313
|
+
every field of the shorthand and its own `direction`, plus a mirror for each
|
|
314
|
+
direction whose flip is not named (`bot.walk.east` mirrors `bot.walk.west`,
|
|
315
|
+
`bot.walk.south-east` mirrors `bot.walk.south-west`, `bot.walk.north-east`
|
|
316
|
+
mirrors `bot.walk.north-west`). Eight directions for five generations. Name
|
|
317
|
+
both sides of a pair (`["west", "east"]`) to generate both instead of
|
|
318
|
+
mirroring, which is the fix for a character whose handedness matters. The
|
|
319
|
+
mirrors carry the shorthand's `category`, `tags`, and `styles`.
|
|
320
|
+
|
|
321
|
+
- The expanded ids are ordinary assets: `plan`, the gallery, the lockfile,
|
|
322
|
+
and `pack` all see `bot.walk.west` and `bot.walk.east`, never `bot.walk`.
|
|
323
|
+
Rewriting the shorthand into explicit assets by hand changes no identity
|
|
324
|
+
and regenerates nothing.
|
|
325
|
+
- `--only bot.walk` selects the whole family; `--only bot.walk.west` one
|
|
326
|
+
member of it.
|
|
327
|
+
- `direction` and `directions` are mutually exclusive, and fields that name
|
|
328
|
+
one output (`file`, `cell`, `remoteId`, `source`, `sourceByStyle`,
|
|
329
|
+
`outputRole`) are refused on a shorthand, since every direction would
|
|
330
|
+
claim them. An expanded id that is already declared is an error, not an
|
|
331
|
+
override.
|
|
332
|
+
- The gallery's `--edit` changes the shorthand, not one direction: editing
|
|
333
|
+
`bot.walk.west` there is refused with a pointer to `bot.walk`. A revision,
|
|
334
|
+
state, or new loop can still name an expanded asset as its parent. To
|
|
335
|
+
change one direction alone, write it out as its own asset and drop it
|
|
336
|
+
from `directions`.
|
|
337
|
+
|
|
299
338
|
Engines that flip sprites at draw time (Godot's `flip_h`, Unity's
|
|
300
339
|
`flipX`) do not need mirrored files at all. Declare only the directions
|
|
301
340
|
you generate and flip in the engine; mirrors are for pipelines that want
|
package/docs/MANIFEST.md
CHANGED
|
@@ -66,7 +66,7 @@ not merely a label edit.
|
|
|
66
66
|
| `remoteId` | string | The provider's own id for art that already exists on the account, so `adopt` maps it without matching bytes: an object id, a character id, or `<character id>#<animation group id>`. Not part of the spec's identity. |
|
|
67
67
|
| `revision` | object | Controlled image-to-image or inpaint dependency. See [controlled revisions](REVISIONS.md). |
|
|
68
68
|
| `state` | object | `character` styles: a pose or outfit of another character asset. See [Characters](./CHARACTERS.md). |
|
|
69
|
-
| `animation` | object | `character` styles: a loop of another character asset in one direction.
|
|
69
|
+
| `animation` | object | `character` styles: a loop of another character asset in one direction. `directions` (a list, instead of `direction`) declares the loop for several directions at once and fills the unnamed flips with mirrors; see [One loop, several directions](./CHARACTERS.md#one-loop-several-directions). |
|
|
70
70
|
| `mirror` | string | Another asset of the same style flipped left to right, made locally at no cost. See [Mirrors](./CHARACTERS.md#mirrors). |
|
|
71
71
|
| `batch` | object | `1dir` styles: rides along on another `1dir` asset's `item_descriptions` submission instead of generating on its own — `{ "of": "<leader asset id>", "index": <1-based slot> }`. See [`1dir`](./GENERATORS.md#1dir). |
|
|
72
72
|
| `pieces` | array | `uiAsset` styles: exact shape regions (`rounded_rect`/`circle`/`polygon`) the panel is composited from, each with a unique `id`. See [`uiAsset`](./GENERATORS.md#uiasset). |
|
package/package.json
CHANGED
|
@@ -1153,6 +1153,23 @@
|
|
|
1153
1153
|
],
|
|
1154
1154
|
"default": "south"
|
|
1155
1155
|
},
|
|
1156
|
+
"directions": {
|
|
1157
|
+
"type": "array",
|
|
1158
|
+
"items": {
|
|
1159
|
+
"type": "string",
|
|
1160
|
+
"enum": [
|
|
1161
|
+
"south",
|
|
1162
|
+
"south-east",
|
|
1163
|
+
"east",
|
|
1164
|
+
"north-east",
|
|
1165
|
+
"north",
|
|
1166
|
+
"north-west",
|
|
1167
|
+
"west",
|
|
1168
|
+
"south-west"
|
|
1169
|
+
]
|
|
1170
|
+
},
|
|
1171
|
+
"minItems": 1
|
|
1172
|
+
},
|
|
1156
1173
|
"frames": {
|
|
1157
1174
|
"type": "integer",
|
|
1158
1175
|
"minimum": 4,
|
|
@@ -48,7 +48,9 @@ hashes.
|
|
|
48
48
|
dependent asset the same way: one `pixelkiln gen` runs the waves in order
|
|
49
49
|
and stops when the budget cannot cover the next one. Before declaring the
|
|
50
50
|
east-facing loop of a character, check whether a `mirror` of the west one
|
|
51
|
-
does the job for nothing
|
|
51
|
+
does the job for nothing (an animation's `directions` list declares the
|
|
52
|
+
generated sides once and mirrors the rest; `--only <shorthand id>`
|
|
53
|
+
selects the whole family); before drawing a base from text, ask whether the
|
|
52
54
|
user has a south-facing sprite to `reference` instead (1 generation on
|
|
53
55
|
`pro-flash` at 64px). Mirrors swap handedness.
|
|
54
56
|
- Treat every ComfyUI output as source material until it passes the native-grid,
|