@volter/play 0.5.211 → 0.5.212

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/package.json CHANGED
@@ -1,10 +1,14 @@
1
1
  {
2
2
  "name": "@volter/play",
3
- "version": "0.5.211",
3
+ "publisher": "volter",
4
+ "version": "0.5.212",
5
+ "engines": {
6
+ "vscode": "^1.104.0"
7
+ },
4
8
  "author": "Volter AI, Inc.",
5
9
  "license": "Apache-2.0",
6
10
  "type": "module",
7
- "description": "Play scripts on detached model documents.",
11
+ "description": "Play for a volter-ai/std game in Cyclotron: the game's own dev pages as std devices in the level's stage, the Game panel, a level's export on save and its Scene view.",
8
12
  "repository": {
9
13
  "type": "git",
10
14
  "url": "git+https://github.com/volter-ai/editor.git",
@@ -12,30 +16,271 @@
12
16
  },
13
17
  "files": [
14
18
  "src",
19
+ "serving",
15
20
  "contributions",
21
+ "dist-node",
16
22
  "LICENSE",
17
23
  "NOTICE"
18
24
  ],
19
25
  "exports": {
20
26
  "./contributions/*": "./contributions/*",
21
27
  "./package.json": "./package.json",
22
- "./play-script": "./src/play-script.ts"
23
- },
24
- "volter": {
25
- "contributions": [
26
- "./contributions/model-play.command.ts",
27
- "./contributions/model-play.service.tsx"
28
- ]
28
+ "./play-log": "./src/play-log.ts"
29
29
  },
30
- "dependencies": {
31
- "@volter/sdk": "0.5.211"
30
+ "extensionDependencies": [
31
+ "volter.@volter/editor-blender",
32
+ "volter.@volter/editor-threejs"
33
+ ],
34
+ "contributes": {
35
+ "volter": {
36
+ "activationEvents": [
37
+ "onCustomEditor:volter.blender.model"
38
+ ],
39
+ "serving": [
40
+ "./dist-node/serving.mjs"
41
+ ],
42
+ "page": [
43
+ "./contributions/play.page.tsx"
44
+ ],
45
+ "editors": [
46
+ {
47
+ "document": "./contributions/std-scene.document.tsx"
48
+ }
49
+ ],
50
+ "projectAdapters": [
51
+ {
52
+ "when": "std.json",
53
+ "module": "./src/std-game-adapter.ts"
54
+ }
55
+ ]
56
+ },
57
+ "languageModelTools": [
58
+ {
59
+ "name": "model-play-log",
60
+ "tags": [
61
+ "volter"
62
+ ],
63
+ "displayName": "Play log",
64
+ "modelDescription": "What the running std game's pages traced, each entry tagged with its player's slot, and Play's own lifecycle entries.",
65
+ "inputSchema": {
66
+ "type": "object",
67
+ "properties": {
68
+ "documentId": {
69
+ "type": "string",
70
+ "description": "The model document; the active Play's when omitted."
71
+ },
72
+ "since": {
73
+ "type": "number",
74
+ "description": "Keep entries at or after this many game seconds."
75
+ },
76
+ "kind": {
77
+ "type": "string",
78
+ "description": "Keep one kind of entry."
79
+ }
80
+ },
81
+ "required": [],
82
+ "additionalProperties": false
83
+ }
84
+ },
85
+ {
86
+ "name": "model-play",
87
+ "tags": [
88
+ "volter"
89
+ ],
90
+ "displayName": "Play control",
91
+ "modelDescription": "Control Play for the open level's std game: state, play, stop, pause, resume or restart. Answers the game's state.",
92
+ "inputSchema": {
93
+ "type": "object",
94
+ "properties": {
95
+ "action": {
96
+ "type": "string",
97
+ "enum": [
98
+ "state",
99
+ "play",
100
+ "stop",
101
+ "pause",
102
+ "resume",
103
+ "restart"
104
+ ]
105
+ }
106
+ },
107
+ "required": [
108
+ "action"
109
+ ],
110
+ "additionalProperties": false
111
+ }
112
+ }
113
+ ],
114
+ "commands": [
115
+ {
116
+ "command": "volter.model-play",
117
+ "title": "model-play",
118
+ "category": "Play",
119
+ "volter": {
120
+ "derivedRefresh": "none"
121
+ }
122
+ },
123
+ {
124
+ "command": "volter.model-play-log",
125
+ "title": "model-play-log",
126
+ "category": "Play",
127
+ "volter": {
128
+ "derivedRefresh": "none"
129
+ }
130
+ },
131
+ {
132
+ "command": "volter.std-scene",
133
+ "title": "Open Scene View",
134
+ "category": "Play",
135
+ "volter": {
136
+ "derivedRefresh": "none"
137
+ }
138
+ },
139
+ {
140
+ "command": "volter.model-play.state",
141
+ "title": "state",
142
+ "category": "Game"
143
+ },
144
+ {
145
+ "command": "volter.model-play.mode",
146
+ "title": "mode",
147
+ "category": "Game"
148
+ },
149
+ {
150
+ "command": "volter.model-play.game-mode",
151
+ "title": "Switch to Game Mode",
152
+ "category": "Game"
153
+ },
154
+ {
155
+ "command": "volter.model-play.animation-mode",
156
+ "title": "Switch to Animation Mode",
157
+ "category": "Game"
158
+ },
159
+ {
160
+ "command": "volter.model-play.play",
161
+ "title": "Play",
162
+ "category": "Game"
163
+ },
164
+ {
165
+ "command": "volter.model-play.stop",
166
+ "title": "Stop",
167
+ "category": "Game"
168
+ },
169
+ {
170
+ "command": "volter.model-play.pause",
171
+ "title": "Pause",
172
+ "category": "Game"
173
+ },
174
+ {
175
+ "command": "volter.model-play.resume",
176
+ "title": "Resume",
177
+ "category": "Game"
178
+ },
179
+ {
180
+ "command": "volter.model-play.step",
181
+ "title": "Step One Tick",
182
+ "category": "Game"
183
+ },
184
+ {
185
+ "command": "volter.model-play.speed",
186
+ "title": "speed",
187
+ "category": "Game"
188
+ },
189
+ {
190
+ "command": "volter.model-play.autoplay",
191
+ "title": "autoplay",
192
+ "category": "Game"
193
+ },
194
+ {
195
+ "command": "volter.model-play.restart",
196
+ "title": "Restart",
197
+ "category": "Game"
198
+ },
199
+ {
200
+ "command": "volter.model-play.export",
201
+ "title": "export",
202
+ "category": "Game"
203
+ }
204
+ ],
205
+ "menus": {
206
+ "commandPalette": [
207
+ {
208
+ "command": "volter.model-play",
209
+ "when": "false"
210
+ },
211
+ {
212
+ "command": "volter.model-play-log",
213
+ "when": "false"
214
+ },
215
+ {
216
+ "command": "volter.model-play.state",
217
+ "when": "false"
218
+ },
219
+ {
220
+ "command": "volter.model-play.mode",
221
+ "when": "false"
222
+ },
223
+ {
224
+ "command": "volter.model-play.speed",
225
+ "when": "false"
226
+ },
227
+ {
228
+ "command": "volter.model-play.autoplay",
229
+ "when": "false"
230
+ },
231
+ {
232
+ "command": "volter.model-play.export",
233
+ "when": "false"
234
+ }
235
+ ]
236
+ }
32
237
  },
33
238
  "peerDependencies": {
34
239
  "react": "^19.0.0",
35
240
  "react-dom": "^19.0.0",
36
- "three": "^0.180.0"
241
+ "three": ">=0.186.0 <0.187.0",
242
+ "@volter/sdk": "0.5.212",
243
+ "@volter/project": "0.5.212",
244
+ "vite": "^6.4.3 || ^7.0.0 || ^8.0.0",
245
+ "@volter/live": "0.5.212",
246
+ "@volter/editor-blender": "0.1.151",
247
+ "@volter/editor-threejs": "0.5.212",
248
+ "@react-three/fiber": "^9.8.2",
249
+ "@react-three/rapier": "^2.2.0",
250
+ "postprocessing": "^6.39.5",
251
+ "@volter-ai/std": "^0.8.0"
252
+ },
253
+ "scripts": {
254
+ "typecheck": "tsc -p tsconfig.json",
255
+ "prepack": "npm run build",
256
+ "build": "node scripts/build-serving.mjs"
37
257
  },
38
258
  "publishConfig": {
39
259
  "access": "public"
260
+ },
261
+ "devDependencies": {
262
+ "@volter/editor-blender": "0.1.151",
263
+ "@volter/editor-threejs": "0.5.212",
264
+ "@volter/live": "0.5.212",
265
+ "@volter/sdk": "0.5.212",
266
+ "esbuild": "0.25.12",
267
+ "typescript": "5.9.3"
268
+ },
269
+ "peerDependenciesMeta": {
270
+ "@volter/sdk": {
271
+ "optional": true
272
+ },
273
+ "@react-three/fiber": {
274
+ "optional": true
275
+ },
276
+ "@react-three/rapier": {
277
+ "optional": true
278
+ },
279
+ "postprocessing": {
280
+ "optional": true
281
+ },
282
+ "@volter-ai/std": {
283
+ "optional": true
284
+ }
40
285
  }
41
286
  }
@@ -0,0 +1,13 @@
1
+ /**
2
+ * `@volter/play`'s server half (`package.json#contributes.volter.serving`): a std game's dev server as Play reaches it,
3
+ * and its level export's Node half (`std-dev.ts`); a std level's scene as a module of the game's own graph, which the
4
+ * Scene view draws (`std-scene.ts`).
5
+ */
6
+ import type { ProjectServingServices } from '@volter/sdk/session/project-serving';
7
+ import { stdDevPlugin } from './std-dev';
8
+ import { stdScenePlugin } from './std-scene';
9
+
10
+ export const servingPlugins = (services: ProjectServingServices): readonly unknown[] => [
11
+ stdDevPlugin(services),
12
+ stdScenePlugin(services),
13
+ ];