lokiplay 0.3.8 → 0.4.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/dist/AGENTS.template.md +51 -5
- package/package.json +2 -2
package/dist/AGENTS.template.md
CHANGED
|
@@ -11,7 +11,15 @@
|
|
|
11
11
|
- Never trust or override the `projectId`, player identity, room membership, or
|
|
12
12
|
sequence returned by Loki.
|
|
13
13
|
- Create rooms with `createRoom()` and join with `joinRoom({ inviteCode })`.
|
|
14
|
-
Do not invent Loki room keys.
|
|
14
|
+
Do not invent Loki room keys. `create()` stays invite-only unless the
|
|
15
|
+
game explicitly passes `{ visibility: "public" }`. Do not make every room
|
|
16
|
+
public. Confirm for each mode whether entry is private invites, public
|
|
17
|
+
room browsing (`listPublicRooms` + `joinPublic`), automatic matchmaking,
|
|
18
|
+
or a combination. Loki’s SDK does not add a public lobby screen. If
|
|
19
|
+
public-room discovery is enabled, the game agent must build the room
|
|
20
|
+
browser and all loading, empty, joining, full-room, waiting, readiness,
|
|
21
|
+
and error states. The Loki overlay does not list, create, or join public
|
|
22
|
+
rooms.
|
|
15
23
|
- Installing the SDK does not add a create/join screen. If the game has no
|
|
16
24
|
usable room-entry flow, add one before shipping: a minimal lobby (create
|
|
17
25
|
room, join with invite, copy invite, start when ready) or an automatic
|
|
@@ -19,6 +27,21 @@
|
|
|
19
27
|
Loki overlay shows room status, players, invite copy, and chat only; it
|
|
20
28
|
does not create or join rooms. Players still need loading, waiting, and
|
|
21
29
|
error states.
|
|
30
|
+
- Installing the SDK also does not add Match or Leaderboard screens; both
|
|
31
|
+
are required alongside create/join, and the Loki overlay never draws
|
|
32
|
+
them. Add a Match control that calls the room wrapper's `matchmake()`
|
|
33
|
+
(`SynchronizedRoom.matchmake()` / `RealtimeRoom.matchmake()`) with
|
|
34
|
+
confirmed player/team settings, plus searching, cancel (abort the
|
|
35
|
+
in-flight search), timeout, waiting, and error states. Add a per-game
|
|
36
|
+
Leaderboard using `listLeaderboard()`/`submitLeaderboardScore()` (or the
|
|
37
|
+
in-room `submitScore()` for a mid-room board), with display-name
|
|
38
|
+
collection or a sensible fallback, plus loading, empty, pagination,
|
|
39
|
+
submission, and error states. Player count, teams, and scoring stay
|
|
40
|
+
creator decisions from the confirmed profile; if the game has no numeric
|
|
41
|
+
result to store, ask the creator once what to record instead of
|
|
42
|
+
inventing a scoring rule. Leaderboards are per-game/project and available
|
|
43
|
+
to guest sessions without a creator account; client-submitted scores are
|
|
44
|
+
not an anti-cheat boundary. Public room browsing stays optional.
|
|
22
45
|
- Before configuring Loki multiplayer, inspect the game's source, existing UI,
|
|
23
46
|
configuration, documentation, tests, and finished build. Locate its game
|
|
24
47
|
modes, seats, local-player handling, AI opponents, teams, start conditions,
|
|
@@ -36,7 +59,8 @@
|
|
|
36
59
|
matchmaking flow.
|
|
37
60
|
- Determine and confirm for each mode: minimum, recommended, and maximum
|
|
38
61
|
players; number of teams, team size, and whether players share control;
|
|
39
|
-
private invite,
|
|
62
|
+
private invite, public room browsing, automatic matchmaking, a
|
|
63
|
+
combination, or asynchronous entry; whether late
|
|
40
64
|
joining and spectators are allowed; turn-based, event-driven, continuous
|
|
41
65
|
realtime, or hybrid simulation; sequential or simultaneous input; required
|
|
42
66
|
authoritative update frequency and latency sensitivity; session duration
|
|
@@ -50,9 +74,31 @@
|
|
|
50
74
|
selection, readiness, player limits, invite and join behavior, waiting
|
|
51
75
|
states, and start conditions.
|
|
52
76
|
- Do not invent new `game.json` fields. Current manifests accept only
|
|
53
|
-
`enabled`, `authority`, `maxPlayers`,
|
|
54
|
-
|
|
55
|
-
creator-confirmed
|
|
77
|
+
`enabled`, `authority`, `maxPlayers`, `tickRate`, and — only when
|
|
78
|
+
`authority` is `"server"` — `step`. Report the richer profile in the
|
|
79
|
+
final report: values, supporting evidence, and creator-confirmed
|
|
80
|
+
decisions.
|
|
81
|
+
- `authority: "server"` is disabled in production until the sandbox gates
|
|
82
|
+
in the server-authority plan pass; do not offer it to a creator as a
|
|
83
|
+
working option today. If a mode still needs it, `step` must name a
|
|
84
|
+
compiled WebAssembly module (`modulePath`, `.wasm`) exporting exactly one
|
|
85
|
+
function, `step`, and importing nothing — no WASI, clocks, randomness, or
|
|
86
|
+
host functions. A seed, when the game needs one, is a supplied input
|
|
87
|
+
field, not something the module reads from the environment. Compile the
|
|
88
|
+
game's headless simulation to that ABI yourself; do not hand the creator
|
|
89
|
+
a module that imports anything, since the validator rejects it and the
|
|
90
|
+
worker never mounts it.
|
|
91
|
+
decisions.
|
|
92
|
+
- `authority: "server"` is disabled in production until the sandbox gates
|
|
93
|
+
in the server-authority plan pass; do not offer it to a creator as a
|
|
94
|
+
working option today. If a mode still needs it, `step` must name a
|
|
95
|
+
compiled WebAssembly module (`modulePath`, `.wasm`) exporting exactly one
|
|
96
|
+
function, `step`, and importing nothing — no WASI, clocks, randomness, or
|
|
97
|
+
host functions. A seed, when the game needs one, is a supplied input
|
|
98
|
+
field, not something the module reads from the environment. Compile the
|
|
99
|
+
game's headless simulation to that ABI yourself; do not hand the creator
|
|
100
|
+
a module that imports anything, since the validator rejects it and the
|
|
101
|
+
worker never mounts it.
|
|
56
102
|
- After inspecting and confirming each game mode's profile, choose
|
|
57
103
|
`createSynchronizedRoom()` for turn-based or event-driven state, or
|
|
58
104
|
`createRealtimeRoom()` for continuous host-authoritative simulation. Do not
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lokiplay",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.1",
|
|
4
4
|
"description": "Command-line tools for Loki game projects and deployments.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"access": "public"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"@lokiplay/protocol": "0.
|
|
42
|
+
"@lokiplay/protocol": "0.4.1",
|
|
43
43
|
"fflate": "^0.8.3"
|
|
44
44
|
}
|
|
45
45
|
}
|