@opengamehq/cli 0.12.0 → 0.13.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.
- package/AGENTS.md +8 -6
- package/CHANGELOG.md +44 -0
- package/README.md +8 -0
- package/dist/cli.mjs +368 -159
- package/dist/opengame-global.js +3 -3
- package/dist/preflight-worker.mjs +14 -14
- package/dist/runtime-builder.mjs +15 -7
- package/dist/skills/manifest.json +11 -11
- package/dist/skills/opengame-all-in-one/SKILL.md +1 -1
- package/dist/skills/opengame-all-in-one/references/opengame-deploy/README.md +9 -7
- package/dist/skills/opengame-all-in-one/references/opengame-jam/README.md +4 -3
- package/dist/skills/opengame-deploy/SKILL.md +9 -7
- package/dist/skills/opengame-jam/SKILL.md +4 -3
- package/package.json +1 -1
|
@@ -141,11 +141,11 @@
|
|
|
141
141
|
"family": "platform",
|
|
142
142
|
"default": true,
|
|
143
143
|
"description": "Put a browser game online with OpenGame, the marketplace and game jam for browser games. Packages the game, checks it locally, uploads it to a private preview only the owner can play, reads and fixes findings, then hands the creator the page where they confirm the details after review. Use when the person says deploy my game, put it online, host it, share it, upload it, publish it, get me a link, make it playable for friends, or asks where to put a browser game or a Three.js game.",
|
|
144
|
-
"version": "1.1.
|
|
144
|
+
"version": "1.1.13",
|
|
145
145
|
"files": [
|
|
146
146
|
{
|
|
147
147
|
"path": "SKILL.md",
|
|
148
|
-
"sha256": "
|
|
148
|
+
"sha256": "4f00094017c64776c8428adba117047ddae7bd02e2495734f4f3aa84796e0db6"
|
|
149
149
|
},
|
|
150
150
|
{
|
|
151
151
|
"path": "references/json-events.md",
|
|
@@ -160,7 +160,7 @@
|
|
|
160
160
|
"sha256": "20fb37b9a8d1bb2ae72e96c233d3df8cd4338e3d32c8ba8d923caf1280738431"
|
|
161
161
|
}
|
|
162
162
|
],
|
|
163
|
-
"digest": "
|
|
163
|
+
"digest": "897d0335a6e184e08ac5e093d1b552a95890a39bee37994883fd8ca051733821"
|
|
164
164
|
},
|
|
165
165
|
{
|
|
166
166
|
"name": "opengame-depth",
|
|
@@ -251,14 +251,14 @@
|
|
|
251
251
|
"family": "platform",
|
|
252
252
|
"default": false,
|
|
253
253
|
"description": "Enter a game in an OpenGame jam. Finds the open jams, their tracks and rules, checks the game against them, deploys one exact release, and enters it with the person's own answers, with opengame publish or on the deploy's page. Use when the person says enter the jam, submit to the jam, which track should I pick, am I eligible, what are the jam rules, or mentions the OpenGame Global AI Game Jam.",
|
|
254
|
-
"version": "1.1.
|
|
254
|
+
"version": "1.1.2",
|
|
255
255
|
"files": [
|
|
256
256
|
{
|
|
257
257
|
"path": "SKILL.md",
|
|
258
|
-
"sha256": "
|
|
258
|
+
"sha256": "e14ab0412352359e0a78ba287a48e6ecaf999ff029fc35c10d8b250a251add77"
|
|
259
259
|
}
|
|
260
260
|
],
|
|
261
|
-
"digest": "
|
|
261
|
+
"digest": "d5b6636102089ac54bbeff00c62bc1ebbfba6583ac8ec559d53de8e1d9e0a963"
|
|
262
262
|
},
|
|
263
263
|
{
|
|
264
264
|
"name": "opengame-lighting",
|
|
@@ -1067,11 +1067,11 @@
|
|
|
1067
1067
|
"family": "bundle",
|
|
1068
1068
|
"default": false,
|
|
1069
1069
|
"description": "Every OpenGame skill in one install, with the order to use them in, for taking a browser game from an idea to a AAA-feeling release, a trailer and a montage. Carries the platform, craft and video skills whole. Use when someone wants one skill that covers everything, says make it AAA or make it game of the year, starts a big game with agents, or does not know which OpenGame skill to load.",
|
|
1070
|
-
"version": "1.0.
|
|
1070
|
+
"version": "1.0.12",
|
|
1071
1071
|
"files": [
|
|
1072
1072
|
{
|
|
1073
1073
|
"path": "SKILL.md",
|
|
1074
|
-
"sha256": "
|
|
1074
|
+
"sha256": "40d57c19ad45af4cca0549f561ec9ab4ed8ab381c88dfc78661aa548139bdce6"
|
|
1075
1075
|
},
|
|
1076
1076
|
{
|
|
1077
1077
|
"path": "references/opengame-accessibility/README.md",
|
|
@@ -1139,7 +1139,7 @@
|
|
|
1139
1139
|
},
|
|
1140
1140
|
{
|
|
1141
1141
|
"path": "references/opengame-deploy/README.md",
|
|
1142
|
-
"sha256": "
|
|
1142
|
+
"sha256": "8133f8c18c6e197f1929d596b85b71ce19d2d6793df0ad56f81ffab4031fd25b"
|
|
1143
1143
|
},
|
|
1144
1144
|
{
|
|
1145
1145
|
"path": "references/opengame-deploy/references/json-events.md",
|
|
@@ -1199,7 +1199,7 @@
|
|
|
1199
1199
|
},
|
|
1200
1200
|
{
|
|
1201
1201
|
"path": "references/opengame-jam/README.md",
|
|
1202
|
-
"sha256": "
|
|
1202
|
+
"sha256": "016102c37021304acd7e23a50c79140157e21f25070c19596e883b7327168d89"
|
|
1203
1203
|
},
|
|
1204
1204
|
{
|
|
1205
1205
|
"path": "references/opengame-lighting/README.md",
|
|
@@ -1774,7 +1774,7 @@
|
|
|
1774
1774
|
"sha256": "e3cbba13f31a92ae73bc33ccef413276b4c2d98039285d67e393223dc7d2b8e5"
|
|
1775
1775
|
}
|
|
1776
1776
|
],
|
|
1777
|
-
"digest": "
|
|
1777
|
+
"digest": "6f7106036bbf6845d41706edfc3e89bae896892ee5f34fd229884ffd3965e057"
|
|
1778
1778
|
}
|
|
1779
1779
|
]
|
|
1780
1780
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: opengame-all-in-one
|
|
3
3
|
description: Every OpenGame skill in one install, with the order to use them in, for taking a browser game from an idea to a AAA-feeling release, a trailer and a montage. Carries the platform, craft and video skills whole. Use when someone wants one skill that covers everything, says make it AAA or make it game of the year, starts a big game with agents, or does not know which OpenGame skill to load.
|
|
4
4
|
metadata:
|
|
5
|
-
version: "1.0.
|
|
5
|
+
version: "1.0.12"
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
# Make a browser game that feels AAA
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
> Carried from `opengame-deploy` 1.1.
|
|
1
|
+
> Carried from `opengame-deploy` 1.1.13. Read it when: Put a browser game online with OpenGame, the marketplace and game jam for browser games. Packages the game, checks it locally, uploads it to a private preview only the owner can play, reads and fixes findings, then hands the creator the page where they confirm the details after review. Use when the person says deploy my game, put it online, host it, share it, upload it, publish it, get me a link, make it playable for friends, or asks where to put a browser game or a Three.js game.
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
# Deploy a browser game to OpenGame
|
|
@@ -108,7 +108,7 @@ opengame init . --title "My game" --json
|
|
|
108
108
|
opengame init . --title "Doom but blue" --kind mod --based-on "Doom" --json
|
|
109
109
|
```
|
|
110
110
|
|
|
111
|
-
Do not ask the creator for a description or a genre before deploying. When you know them, pass `--description` (40 characters or more) and `--
|
|
111
|
+
Do not ask the creator for a description or a genre before deploying. When you know them, pass `--description` (40 characters or more), `--genre` and `--players`; when you do not, leave them out. Every field defaults to Auto: review writes the description and the genre from the game, and the creator accepts or changes them on the deploy's page, where they also enter the jam. A title or description you pass is offered back with its casing and grammar tidied, and `opengame publish --keep-words` keeps it as written. After the deploy you can set the description yourself with `opengame details --description "..." --json`. If the file already exists, `init` fills in only the fields it leaves blank; edit the file to change the rest.
|
|
112
112
|
|
|
113
113
|
For a game that already exists on OpenGame, in a new checkout, link the folder first so the deploy does not create a second game:
|
|
114
114
|
|
|
@@ -210,19 +210,21 @@ OpenGame hosts static browser exports. The build needs `index.html` at the root
|
|
|
210
210
|
|
|
211
211
|
At runtime the game may call its own origin, `https://api.opengame.gg`, and any other `https:` or `wss:` host. Each call comes from the player's browser, so that host sees the player's IP address. Keep API keys on the creator's server, never in the bundle: players can read every file in it. The review sandbox has no internet, so the game must draw its first frame without its server.
|
|
212
212
|
|
|
213
|
+
A game may keep a service worker on the game's address; a takedown removes it and a new version replaces it.
|
|
214
|
+
|
|
213
215
|
The published game runs at `https://<label>.opengame.gg`, one origin per game, and `opengame deploy` returns it as `data.gameOrigin`. While an experiment runs, players load each version taking part from a `v-` origin instead. If the creator's servers check `Origin` (WebSocket) or send CORS headers (HTTP), they reject the game's requests until that exact origin is on their list, and online play fails with a closed socket, a 401 or 403 on the upgrade, or a CORS error in the console. Tell the creator to add it, and to add a version's `v-` origin before starting an experiment with it. Never suggest allowing `*.opengame.gg`, `null` or any pattern on `opengame.gg`, because other people's games are served there too and a pattern lets them call the creator's server. Use a token in a header or the first socket message, not a cookie. A private preview runs on a temporary `p-` origin, not the game's. That address is a private link, so keep it out of committed config and logs. [Games that talk to your own servers](https://docs.opengame.io/guides/packaging#games-that-talk-to-your-own-servers) has server examples.
|
|
214
216
|
|
|
215
217
|
A game may not take payments, use crypto, make players create an account or give an email address, show ads, or carry ad pixels or session recording. [Packaging](https://docs.opengame.io/guides/packaging) has every rule and every check.
|
|
216
218
|
|
|
217
219
|
## Multiplayer
|
|
218
220
|
|
|
219
|
-
OpenGame runs no game server or rooms. A
|
|
221
|
+
OpenGame runs no game server or rooms. A game in any engine can reach the creator's servers (Colyseus, Nakama, Photon or their own) over `wss:`, WebTransport or `https:`, or links browsers over WebRTC. A browser has no raw UDP or TCP, so use the engine's WebSocket or WebRTC transport. OpenGame supplies the invite link:
|
|
220
222
|
|
|
221
|
-
- **Invites.** Share `og.invite.link(code)`, the game's page on opengame.io with `?join=CODE`, never the game's `opengame.gg` address. After `await og.init()`, a player with `og.invite.code` set opened an invite: join them to that lobby with no menu in between.
|
|
222
|
-
- **
|
|
223
|
-
- **
|
|
223
|
+
- **Invites.** Share `og.invite.link(code)`, the game's page on opengame.io with `?join=CODE`, never the game's `opengame.gg` address. After `await og.init()`, a player with `og.invite.code` set opened an invite: join them to that lobby with no menu in between. `link` is `null` outside OpenGame and for a code the page would change, so show the code too.
|
|
224
|
+
- **Game servers.** Allow only the game's exact origin. Send a token in a header or the first socket message, not a cookie. A server cannot verify `og.player.id`, so it issues that token without a sign-in and decides results.
|
|
225
|
+
- **Peer to peer.** Run a signalling server, such as PeerServer for PeerJS, over `wss:` instead of `0.peerjs.com`, check `Origin` in front of it, and prefix peer ids with the game's name. Use STUN plus TURN, with TURN credentials from the creator's server, not the bundle. The next host keeps the lobby id.
|
|
224
226
|
|
|
225
|
-
[Multiplayer](https://docs.opengame.io/guides/multiplayer)
|
|
227
|
+
[Multiplayer](https://docs.opengame.io/guides/multiplayer) covers each engine, server settings and testing.
|
|
226
228
|
|
|
227
229
|
## Engines
|
|
228
230
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
> Carried from `opengame-jam` 1.1.
|
|
1
|
+
> Carried from `opengame-jam` 1.1.2. Read it when: Enter a game in an OpenGame jam. Finds the open jams, their tracks and rules, checks the game against them, deploys one exact release, and enters it with the person's own answers, with opengame publish or on the deploy's page. Use when the person says enter the jam, submit to the jam, which track should I pick, am I eligible, what are the jam rules, or mentions the OpenGame Global AI Game Jam.
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
# Enter an OpenGame jam
|
|
@@ -117,5 +117,6 @@ deploy's. Fix them and deploy again; the new release goes to review by itself. W
|
|
|
117
117
|
takes entries, a redeploy of a game whose entry is live is entered again with the same
|
|
118
118
|
answers, so it keeps its place.
|
|
119
119
|
|
|
120
|
-
The jam's judging criteria are published on its rules page
|
|
121
|
-
|
|
120
|
+
The jam's judging criteria are published on its rules page, which is the authority: creativity
|
|
121
|
+
and originality, depth, fun, performance and visual fidelity, none weighted above another. The
|
|
122
|
+
craft skills (`opengame-quality-bar` first) are how to raise them.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: opengame-deploy
|
|
3
3
|
description: Put a browser game online with OpenGame, the marketplace and game jam for browser games. Packages the game, checks it locally, uploads it to a private preview only the owner can play, reads and fixes findings, then hands the creator the page where they confirm the details after review. Use when the person says deploy my game, put it online, host it, share it, upload it, publish it, get me a link, make it playable for friends, or asks where to put a browser game or a Three.js game.
|
|
4
4
|
metadata:
|
|
5
|
-
version: "1.1.
|
|
5
|
+
version: "1.1.13"
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
# Deploy a browser game to OpenGame
|
|
@@ -112,7 +112,7 @@ opengame init . --title "My game" --json
|
|
|
112
112
|
opengame init . --title "Doom but blue" --kind mod --based-on "Doom" --json
|
|
113
113
|
```
|
|
114
114
|
|
|
115
|
-
Do not ask the creator for a description or a genre before deploying. When you know them, pass `--description` (40 characters or more) and `--
|
|
115
|
+
Do not ask the creator for a description or a genre before deploying. When you know them, pass `--description` (40 characters or more), `--genre` and `--players`; when you do not, leave them out. Every field defaults to Auto: review writes the description and the genre from the game, and the creator accepts or changes them on the deploy's page, where they also enter the jam. A title or description you pass is offered back with its casing and grammar tidied, and `opengame publish --keep-words` keeps it as written. After the deploy you can set the description yourself with `opengame details --description "..." --json`. If the file already exists, `init` fills in only the fields it leaves blank; edit the file to change the rest.
|
|
116
116
|
|
|
117
117
|
For a game that already exists on OpenGame, in a new checkout, link the folder first so the deploy does not create a second game:
|
|
118
118
|
|
|
@@ -214,19 +214,21 @@ OpenGame hosts static browser exports. The build needs `index.html` at the root
|
|
|
214
214
|
|
|
215
215
|
At runtime the game may call its own origin, `https://api.opengame.gg`, and any other `https:` or `wss:` host. Each call comes from the player's browser, so that host sees the player's IP address. Keep API keys on the creator's server, never in the bundle: players can read every file in it. The review sandbox has no internet, so the game must draw its first frame without its server.
|
|
216
216
|
|
|
217
|
+
A game may keep a service worker on the game's address; a takedown removes it and a new version replaces it.
|
|
218
|
+
|
|
217
219
|
The published game runs at `https://<label>.opengame.gg`, one origin per game, and `opengame deploy` returns it as `data.gameOrigin`. While an experiment runs, players load each version taking part from a `v-` origin instead. If the creator's servers check `Origin` (WebSocket) or send CORS headers (HTTP), they reject the game's requests until that exact origin is on their list, and online play fails with a closed socket, a 401 or 403 on the upgrade, or a CORS error in the console. Tell the creator to add it, and to add a version's `v-` origin before starting an experiment with it. Never suggest allowing `*.opengame.gg`, `null` or any pattern on `opengame.gg`, because other people's games are served there too and a pattern lets them call the creator's server. Use a token in a header or the first socket message, not a cookie. A private preview runs on a temporary `p-` origin, not the game's. That address is a private link, so keep it out of committed config and logs. [Games that talk to your own servers](https://docs.opengame.io/guides/packaging#games-that-talk-to-your-own-servers) has server examples.
|
|
218
220
|
|
|
219
221
|
A game may not take payments, use crypto, make players create an account or give an email address, show ads, or carry ad pixels or session recording. [Packaging](https://docs.opengame.io/guides/packaging) has every rule and every check.
|
|
220
222
|
|
|
221
223
|
## Multiplayer
|
|
222
224
|
|
|
223
|
-
OpenGame runs no game server or rooms. A
|
|
225
|
+
OpenGame runs no game server or rooms. A game in any engine can reach the creator's servers (Colyseus, Nakama, Photon or their own) over `wss:`, WebTransport or `https:`, or links browsers over WebRTC. A browser has no raw UDP or TCP, so use the engine's WebSocket or WebRTC transport. OpenGame supplies the invite link:
|
|
224
226
|
|
|
225
|
-
- **Invites.** Share `og.invite.link(code)`, the game's page on opengame.io with `?join=CODE`, never the game's `opengame.gg` address. After `await og.init()`, a player with `og.invite.code` set opened an invite: join them to that lobby with no menu in between.
|
|
226
|
-
- **
|
|
227
|
-
- **
|
|
227
|
+
- **Invites.** Share `og.invite.link(code)`, the game's page on opengame.io with `?join=CODE`, never the game's `opengame.gg` address. After `await og.init()`, a player with `og.invite.code` set opened an invite: join them to that lobby with no menu in between. `link` is `null` outside OpenGame and for a code the page would change, so show the code too.
|
|
228
|
+
- **Game servers.** Allow only the game's exact origin. Send a token in a header or the first socket message, not a cookie. A server cannot verify `og.player.id`, so it issues that token without a sign-in and decides results.
|
|
229
|
+
- **Peer to peer.** Run a signalling server, such as PeerServer for PeerJS, over `wss:` instead of `0.peerjs.com`, check `Origin` in front of it, and prefix peer ids with the game's name. Use STUN plus TURN, with TURN credentials from the creator's server, not the bundle. The next host keeps the lobby id.
|
|
228
230
|
|
|
229
|
-
[Multiplayer](https://docs.opengame.io/guides/multiplayer)
|
|
231
|
+
[Multiplayer](https://docs.opengame.io/guides/multiplayer) covers each engine, server settings and testing.
|
|
230
232
|
|
|
231
233
|
## Engines
|
|
232
234
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: opengame-jam
|
|
3
3
|
description: Enter a game in an OpenGame jam. Finds the open jams, their tracks and rules, checks the game against them, deploys one exact release, and enters it with the person's own answers, with opengame publish or on the deploy's page. Use when the person says enter the jam, submit to the jam, which track should I pick, am I eligible, what are the jam rules, or mentions the OpenGame Global AI Game Jam.
|
|
4
4
|
metadata:
|
|
5
|
-
version: "1.1.
|
|
5
|
+
version: "1.1.2"
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
# Enter an OpenGame jam
|
|
@@ -121,5 +121,6 @@ deploy's. Fix them and deploy again; the new release goes to review by itself. W
|
|
|
121
121
|
takes entries, a redeploy of a game whose entry is live is entered again with the same
|
|
122
122
|
answers, so it keeps its place.
|
|
123
123
|
|
|
124
|
-
The jam's judging criteria are published on its rules page
|
|
125
|
-
|
|
124
|
+
The jam's judging criteria are published on its rules page, which is the authority: creativity
|
|
125
|
+
and originality, depth, fun, performance and visual fidelity, none weighted above another. The
|
|
126
|
+
craft skills (`opengame-quality-bar` first) are how to raise them.
|