@onceworlds/cli 0.9.1 → 0.9.3
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/README.md +16 -6
- package/dist/cli.js +927 -61
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -83,10 +83,14 @@ from the running game and commit them under `store/`. `onceworlds doctor` says w
|
|
|
83
83
|
|
|
84
84
|
## Commands
|
|
85
85
|
|
|
86
|
-
- `onceworlds new [folder]
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
86
|
+
- `onceworlds new [folder]` starts a game: a blank engine project (`--space 3d` for 3D) with nothing that decides the game, only
|
|
87
|
+
the wiring: a `game.config.js` with a camera and an empty action map, a test that plays it through a reloaded host and a dropped
|
|
88
|
+
player, an `onceworlds.json` for your game (`--name`, `--slug`, `--description`; the folder's name by default), the engine guide
|
|
89
|
+
as `AGENTS.md` and `CLAUDE.md`, and a `DESIGN.md` to fill in first (the hook and signature mechanic, an originality pass, the first
|
|
90
|
+
minute, the art direction, the feel, the UI and a pre-build check). `--kit <name>` starts from a kit instead: a complete game of
|
|
91
|
+
one kind (`--list` shows them), a reference for its plumbing (rooms, netcode, Flow, bots, tests) whose idea, look and screens are
|
|
92
|
+
never yours. A kit adds its own notes as `KIT.md` and its fingerprints as `.onceworlds/kit.json`, so `check` can note what is
|
|
93
|
+
still the kit's. `--template party` or `starter` starts a small game on the SDK alone.
|
|
90
94
|
- `onceworlds check [dir]` is what to run before a deploy: doctor's findings and, for an engine game, the game's own tests
|
|
91
95
|
(`npm test`) and simulated matches played with no browser, with a reloaded host, a dropped player, the host changing (also while
|
|
92
96
|
paused), a late joiner and garbage messages. A failing test or a match with errors exits with an error. The game's config is
|
|
@@ -120,7 +124,11 @@ from the running game and commit them under `store/`. `onceworlds doctor` says w
|
|
|
120
124
|
game the list is the engine's own (`controlsFromActions` on the `actions` that `game.config.js` exports); otherwise it is read
|
|
121
125
|
from the source text (`Input.axis2d`, `Input.button`) and may differ. It checks `onceworlds.json` by every rule a deploy applies
|
|
122
126
|
(lengths, genres, badges, How to play, the pictures it names), in the deploy's words and with the fix, and fails as the deploy
|
|
123
|
-
would; the rest only suggests (`--strict` exits with an error on likely bugs, for CI). `check` does the same.
|
|
127
|
+
would; the rest only suggests (`--strict` exits with an error on likely bugs, for CI). `check` does the same. For an engine
|
|
128
|
+
game it also says when `DESIGN.md` is missing or has parts left empty (the originality pass included), and notes a game still
|
|
129
|
+
close to the kit it started from (scripts unchanged, the kit's numbers, its screens). For a game on Flow it says what still
|
|
130
|
+
looks like a kit (Flow's placeholder screens, the default theme), a 3-2-1 of the game's own beside Flow's, and a first round
|
|
131
|
+
no different from the rest. Taste is the game's: these are warnings and notes, never a failure.
|
|
124
132
|
|
|
125
133
|
- `onceworlds api <name or words>` looks the engine up in a few lines instead of the whole reference: a signature, what it
|
|
126
134
|
does, a component's fields or an options object's keys, and an example (`api Shape2D`, `api feel.shake`, `api "camera follow"`;
|
|
@@ -132,7 +140,9 @@ from the running game and commit them under `store/`. `onceworlds doctor` says w
|
|
|
132
140
|
with bots (`--at 20`), the title screen (`--phase title`) or the lobby (`--phase lobby`), or a poster (`--poster cover`), at
|
|
133
141
|
`--size 1280x720` by default. A 2D game is drawn with no browser, from
|
|
134
142
|
the frame the engine draws, in the engine's font; a 3D game (or `--browser`) is drawn by Chrome, Chromium or Edge from a local
|
|
135
|
-
copy of the game. `--out` picks the file (default `store/shot.png`).
|
|
143
|
+
copy of the game. `--out` picks the file (default `store/shot.png`). `--story` plays the first minute as a new player lives it
|
|
144
|
+
(the title, the lobby, the countdown, the round's goal, play at +1, +5 and +12 s, the first result), saves each frame into
|
|
145
|
+
`store/story/` and lays them out on one contact sheet, `store/story.png`, with the questions to ask of it.
|
|
136
146
|
|
|
137
147
|
Running `onceworlds mcp` gives an AI tool the same as tools: `api_lookup`, `recipe`, `read_guide`, `search_assets` (the engine's
|
|
138
148
|
asset library), `check`, `screenshot` (the picture comes back to the model), `new_game`, `deploy_preview`, `playtest` and
|