@zylem/game-lib 0.8.9 → 0.9.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.
Files changed (69) hide show
  1. package/README.md +7 -1
  2. package/dist/api/game-lib.api.json +37952 -19547
  3. package/dist/api/game-lib.api.md +1302 -7
  4. package/dist/api/game-lib.d.ts +1696 -3
  5. package/dist/api/game-lib.typedoc.json +174596 -76562
  6. package/dist/audio.d.ts +193 -1
  7. package/dist/audio.js +1 -1
  8. package/dist/bridge.d.ts +17 -2
  9. package/dist/bridge.js +1 -1
  10. package/dist/catalog.js +1 -1
  11. package/dist/chunk-2PFNNGTV.js +1 -0
  12. package/dist/chunk-2XMG3NJS.js +1 -0
  13. package/dist/chunk-4CZZZCFB.js +9 -0
  14. package/dist/chunk-7CBJKE42.js +1 -0
  15. package/dist/{chunk-CBUQBP2U.js → chunk-BQRMYLYD.js} +1 -1
  16. package/dist/chunk-FZNEWOC5.js +1 -0
  17. package/dist/chunk-GPCSX3M6.js +1 -0
  18. package/dist/chunk-K3NNXZIJ.js +1 -0
  19. package/dist/{chunk-JNFFTNMH.js → chunk-KSEP7AUF.js} +1 -1
  20. package/dist/{chunk-7JSZEEAE.js → chunk-LI43BZQN.js} +1 -1
  21. package/dist/chunk-NVVLLWIM.js +1 -0
  22. package/dist/chunk-QGIYILYI.js +1 -0
  23. package/dist/chunk-SHDHPDOV.js +24 -0
  24. package/dist/chunk-STVEILJJ.js +1 -0
  25. package/dist/chunk-SWDNK4GG.js +1 -0
  26. package/dist/chunk-UUOPT2N4.js +1 -0
  27. package/dist/chunk-VMXSE3EC.js +0 -0
  28. package/dist/{chunk-EYDC2PMO.js → chunk-VSFULLND.js} +1 -1
  29. package/dist/chunk-YNX3Q3CL.js +1 -0
  30. package/dist/chunk-ZZO4CKRU.js +1 -0
  31. package/dist/cinematics.d.ts +279 -0
  32. package/dist/cinematics.js +1 -0
  33. package/dist/core.d.ts +124 -10
  34. package/dist/core.js +1 -1
  35. package/dist/cutscene-definition-C479fkei.d.ts +509 -0
  36. package/dist/debug.d.ts +1 -0
  37. package/dist/debug.js +1 -1
  38. package/dist/{entity-type-map-D6BeAdvg.d.ts → entity-type-map-CrsrKT8c.d.ts} +12 -3
  39. package/dist/entity.d.ts +2 -1
  40. package/dist/entity.js +1 -1
  41. package/dist/game-D8KTP3fD.d.ts +652 -0
  42. package/dist/game-default-JV3Q6JAL.js +1 -0
  43. package/dist/graphics.d.ts +1 -1
  44. package/dist/graphics.js +1 -1
  45. package/dist/public.d.ts +12 -6
  46. package/dist/public.js +1 -1
  47. package/dist/schema/cutscene.schema.json +782 -0
  48. package/dist/schema/song.schema.json +430 -0
  49. package/dist/schema.d.ts +2 -0
  50. package/dist/schema.js +1 -1
  51. package/dist/selection-bounds-BKmSo9aG.d.ts +50 -0
  52. package/dist/song-definition-rEKksP0B.d.ts +263 -0
  53. package/dist/song-player-7QPLFLAS.js +1 -0
  54. package/dist/{game-DyKbOeck.d.ts → stage-CAPlk_cN.d.ts} +146 -647
  55. package/dist/web-components.d.ts +5 -3
  56. package/dist/web-components.js +1 -1
  57. package/dist/{zylem-camera-DZTpPOiD.d.ts → zylem-camera-CYDtrVgi.d.ts} +134 -102
  58. package/package.json +11 -4
  59. package/dist/chunk-34MYRTRP.js +0 -9
  60. package/dist/chunk-AXJTUVGC.js +0 -24
  61. package/dist/chunk-BWOZF5YK.js +0 -1
  62. package/dist/chunk-EVMLNMGU.js +0 -1
  63. package/dist/chunk-G3TBBZUI.js +0 -1
  64. package/dist/chunk-J6KD2G6F.js +0 -1
  65. package/dist/chunk-X7T7QRYP.js +0 -1
  66. package/dist/chunk-YVWDCZNT.js +0 -1
  67. package/dist/chunk-ZRT3ZQVH.js +0 -1
  68. package/dist/game-default-6YXFFZ2Q.js +0 -1
  69. /package/dist/{chunk-MSCVL5OK.js → chunk-ELQN62PQ.js} +0 -0
@@ -0,0 +1,782 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "$id": "CutsceneDefinition",
4
+ "title": "CutsceneDefinition",
5
+ "additionalProperties": false,
6
+ "type": "object",
7
+ "required": [
8
+ "id",
9
+ "name",
10
+ "duration",
11
+ "stage",
12
+ "skippable",
13
+ "scenes",
14
+ "cameras",
15
+ "dollies",
16
+ "tracks"
17
+ ],
18
+ "properties": {
19
+ "id": {
20
+ "type": "string"
21
+ },
22
+ "name": {
23
+ "type": "string"
24
+ },
25
+ "duration": {
26
+ "exclusiveMinimum": 0,
27
+ "type": "number"
28
+ },
29
+ "stage": {
30
+ "anyOf": [
31
+ {
32
+ "type": "string"
33
+ },
34
+ {
35
+ "type": "null"
36
+ }
37
+ ]
38
+ },
39
+ "skippable": {
40
+ "type": "boolean"
41
+ },
42
+ "scenes": {
43
+ "type": "array",
44
+ "items": {
45
+ "title": "CutsceneScene",
46
+ "additionalProperties": false,
47
+ "type": "object",
48
+ "required": [
49
+ "id",
50
+ "name",
51
+ "start",
52
+ "end",
53
+ "transitionIn"
54
+ ],
55
+ "properties": {
56
+ "id": {
57
+ "type": "string"
58
+ },
59
+ "name": {
60
+ "type": "string"
61
+ },
62
+ "start": {
63
+ "minimum": 0,
64
+ "type": "number"
65
+ },
66
+ "end": {
67
+ "minimum": 0,
68
+ "type": "number"
69
+ },
70
+ "transitionIn": {
71
+ "title": "SceneTransition",
72
+ "additionalProperties": false,
73
+ "type": "object",
74
+ "required": [
75
+ "type",
76
+ "duration",
77
+ "easing"
78
+ ],
79
+ "properties": {
80
+ "type": {
81
+ "title": "SceneTransitionType",
82
+ "anyOf": [
83
+ {
84
+ "const": "cut",
85
+ "type": "string"
86
+ },
87
+ {
88
+ "const": "fade",
89
+ "type": "string"
90
+ },
91
+ {
92
+ "const": "wipe",
93
+ "type": "string"
94
+ },
95
+ {
96
+ "const": "radial",
97
+ "type": "string"
98
+ },
99
+ {
100
+ "const": "noise",
101
+ "type": "string"
102
+ },
103
+ {
104
+ "const": "cells",
105
+ "type": "string"
106
+ }
107
+ ]
108
+ },
109
+ "duration": {
110
+ "minimum": 0,
111
+ "type": "number"
112
+ },
113
+ "easing": {
114
+ "title": "CutsceneEasing",
115
+ "anyOf": [
116
+ {
117
+ "const": "linear",
118
+ "type": "string"
119
+ },
120
+ {
121
+ "const": "easeIn",
122
+ "type": "string"
123
+ },
124
+ {
125
+ "const": "easeOut",
126
+ "type": "string"
127
+ },
128
+ {
129
+ "const": "easeInOut",
130
+ "type": "string"
131
+ }
132
+ ]
133
+ }
134
+ }
135
+ }
136
+ }
137
+ }
138
+ },
139
+ "cameras": {
140
+ "type": "array",
141
+ "items": {
142
+ "title": "CutsceneCamera",
143
+ "additionalProperties": false,
144
+ "type": "object",
145
+ "required": [
146
+ "id",
147
+ "name",
148
+ "kind",
149
+ "fov",
150
+ "pose",
151
+ "dollyEasing",
152
+ "damping",
153
+ "keyframes"
154
+ ],
155
+ "properties": {
156
+ "id": {
157
+ "type": "string"
158
+ },
159
+ "name": {
160
+ "type": "string"
161
+ },
162
+ "kind": {
163
+ "title": "CutsceneCameraKind",
164
+ "anyOf": [
165
+ {
166
+ "const": "static",
167
+ "type": "string"
168
+ },
169
+ {
170
+ "const": "dolly",
171
+ "type": "string"
172
+ },
173
+ {
174
+ "const": "follow",
175
+ "type": "string"
176
+ }
177
+ ]
178
+ },
179
+ "fov": {
180
+ "minimum": 1,
181
+ "maximum": 179,
182
+ "type": "number"
183
+ },
184
+ "pose": {
185
+ "title": "CameraPoseDef",
186
+ "additionalProperties": false,
187
+ "type": "object",
188
+ "required": [
189
+ "position",
190
+ "lookAt"
191
+ ],
192
+ "properties": {
193
+ "position": {
194
+ "title": "Vec3",
195
+ "additionalProperties": false,
196
+ "type": "object",
197
+ "required": [
198
+ "x",
199
+ "y",
200
+ "z"
201
+ ],
202
+ "properties": {
203
+ "x": {
204
+ "type": "number"
205
+ },
206
+ "y": {
207
+ "type": "number"
208
+ },
209
+ "z": {
210
+ "type": "number"
211
+ }
212
+ }
213
+ },
214
+ "lookAt": {
215
+ "title": "Vec3",
216
+ "additionalProperties": false,
217
+ "type": "object",
218
+ "required": [
219
+ "x",
220
+ "y",
221
+ "z"
222
+ ],
223
+ "properties": {
224
+ "x": {
225
+ "type": "number"
226
+ },
227
+ "y": {
228
+ "type": "number"
229
+ },
230
+ "z": {
231
+ "type": "number"
232
+ }
233
+ }
234
+ }
235
+ }
236
+ },
237
+ "dollyId": {
238
+ "type": "string"
239
+ },
240
+ "dollyEasing": {
241
+ "title": "CutsceneEasing",
242
+ "anyOf": [
243
+ {
244
+ "const": "linear",
245
+ "type": "string"
246
+ },
247
+ {
248
+ "const": "easeIn",
249
+ "type": "string"
250
+ },
251
+ {
252
+ "const": "easeOut",
253
+ "type": "string"
254
+ },
255
+ {
256
+ "const": "easeInOut",
257
+ "type": "string"
258
+ }
259
+ ]
260
+ },
261
+ "target": {
262
+ "type": "string"
263
+ },
264
+ "offset": {
265
+ "title": "Vec3",
266
+ "additionalProperties": false,
267
+ "type": "object",
268
+ "required": [
269
+ "x",
270
+ "y",
271
+ "z"
272
+ ],
273
+ "properties": {
274
+ "x": {
275
+ "type": "number"
276
+ },
277
+ "y": {
278
+ "type": "number"
279
+ },
280
+ "z": {
281
+ "type": "number"
282
+ }
283
+ }
284
+ },
285
+ "damping": {
286
+ "minimum": 0,
287
+ "maximum": 1,
288
+ "type": "number"
289
+ },
290
+ "keyframes": {
291
+ "type": "array",
292
+ "items": {
293
+ "title": "CameraKeyframe",
294
+ "additionalProperties": false,
295
+ "type": "object",
296
+ "required": [
297
+ "id",
298
+ "time",
299
+ "easing"
300
+ ],
301
+ "properties": {
302
+ "id": {
303
+ "type": "string"
304
+ },
305
+ "time": {
306
+ "minimum": 0,
307
+ "type": "number"
308
+ },
309
+ "position": {
310
+ "title": "Vec3",
311
+ "additionalProperties": false,
312
+ "type": "object",
313
+ "required": [
314
+ "x",
315
+ "y",
316
+ "z"
317
+ ],
318
+ "properties": {
319
+ "x": {
320
+ "type": "number"
321
+ },
322
+ "y": {
323
+ "type": "number"
324
+ },
325
+ "z": {
326
+ "type": "number"
327
+ }
328
+ }
329
+ },
330
+ "lookAt": {
331
+ "title": "Vec3",
332
+ "additionalProperties": false,
333
+ "type": "object",
334
+ "required": [
335
+ "x",
336
+ "y",
337
+ "z"
338
+ ],
339
+ "properties": {
340
+ "x": {
341
+ "type": "number"
342
+ },
343
+ "y": {
344
+ "type": "number"
345
+ },
346
+ "z": {
347
+ "type": "number"
348
+ }
349
+ }
350
+ },
351
+ "fov": {
352
+ "minimum": 1,
353
+ "maximum": 179,
354
+ "type": "number"
355
+ },
356
+ "easing": {
357
+ "title": "CutsceneEasing",
358
+ "anyOf": [
359
+ {
360
+ "const": "linear",
361
+ "type": "string"
362
+ },
363
+ {
364
+ "const": "easeIn",
365
+ "type": "string"
366
+ },
367
+ {
368
+ "const": "easeOut",
369
+ "type": "string"
370
+ },
371
+ {
372
+ "const": "easeInOut",
373
+ "type": "string"
374
+ }
375
+ ]
376
+ }
377
+ }
378
+ }
379
+ }
380
+ }
381
+ }
382
+ },
383
+ "dollies": {
384
+ "type": "array",
385
+ "items": {
386
+ "title": "DollyPath",
387
+ "additionalProperties": false,
388
+ "type": "object",
389
+ "required": [
390
+ "id",
391
+ "name",
392
+ "points",
393
+ "closed",
394
+ "tension"
395
+ ],
396
+ "properties": {
397
+ "id": {
398
+ "type": "string"
399
+ },
400
+ "name": {
401
+ "type": "string"
402
+ },
403
+ "points": {
404
+ "minItems": 2,
405
+ "type": "array",
406
+ "items": {
407
+ "title": "Vec3",
408
+ "additionalProperties": false,
409
+ "type": "object",
410
+ "required": [
411
+ "x",
412
+ "y",
413
+ "z"
414
+ ],
415
+ "properties": {
416
+ "x": {
417
+ "type": "number"
418
+ },
419
+ "y": {
420
+ "type": "number"
421
+ },
422
+ "z": {
423
+ "type": "number"
424
+ }
425
+ }
426
+ }
427
+ },
428
+ "closed": {
429
+ "type": "boolean"
430
+ },
431
+ "tension": {
432
+ "minimum": 0,
433
+ "maximum": 1,
434
+ "type": "number"
435
+ }
436
+ }
437
+ }
438
+ },
439
+ "tracks": {
440
+ "type": "array",
441
+ "items": {
442
+ "title": "CutsceneTrack",
443
+ "anyOf": [
444
+ {
445
+ "title": "CameraTrack",
446
+ "additionalProperties": false,
447
+ "type": "object",
448
+ "required": [
449
+ "kind",
450
+ "id",
451
+ "name",
452
+ "items"
453
+ ],
454
+ "properties": {
455
+ "kind": {
456
+ "const": "camera",
457
+ "type": "string"
458
+ },
459
+ "id": {
460
+ "type": "string"
461
+ },
462
+ "name": {
463
+ "type": "string"
464
+ },
465
+ "items": {
466
+ "type": "array",
467
+ "items": {
468
+ "title": "CameraShot",
469
+ "additionalProperties": false,
470
+ "type": "object",
471
+ "required": [
472
+ "id",
473
+ "cameraId",
474
+ "start",
475
+ "end",
476
+ "blend"
477
+ ],
478
+ "properties": {
479
+ "id": {
480
+ "type": "string"
481
+ },
482
+ "cameraId": {
483
+ "type": "string"
484
+ },
485
+ "start": {
486
+ "minimum": 0,
487
+ "type": "number"
488
+ },
489
+ "end": {
490
+ "minimum": 0,
491
+ "type": "number"
492
+ },
493
+ "blend": {
494
+ "title": "ShotBlend",
495
+ "additionalProperties": false,
496
+ "type": "object",
497
+ "required": [
498
+ "duration",
499
+ "easing"
500
+ ],
501
+ "properties": {
502
+ "duration": {
503
+ "minimum": 0,
504
+ "type": "number"
505
+ },
506
+ "easing": {
507
+ "title": "CutsceneEasing",
508
+ "anyOf": [
509
+ {
510
+ "const": "linear",
511
+ "type": "string"
512
+ },
513
+ {
514
+ "const": "easeIn",
515
+ "type": "string"
516
+ },
517
+ {
518
+ "const": "easeOut",
519
+ "type": "string"
520
+ },
521
+ {
522
+ "const": "easeInOut",
523
+ "type": "string"
524
+ }
525
+ ]
526
+ }
527
+ }
528
+ }
529
+ }
530
+ }
531
+ }
532
+ }
533
+ },
534
+ {
535
+ "title": "EventTrack",
536
+ "additionalProperties": false,
537
+ "type": "object",
538
+ "required": [
539
+ "kind",
540
+ "id",
541
+ "name",
542
+ "items"
543
+ ],
544
+ "properties": {
545
+ "kind": {
546
+ "const": "event",
547
+ "type": "string"
548
+ },
549
+ "id": {
550
+ "type": "string"
551
+ },
552
+ "name": {
553
+ "type": "string"
554
+ },
555
+ "items": {
556
+ "type": "array",
557
+ "items": {
558
+ "title": "EventItem",
559
+ "additionalProperties": false,
560
+ "type": "object",
561
+ "required": [
562
+ "id",
563
+ "time",
564
+ "event"
565
+ ],
566
+ "properties": {
567
+ "id": {
568
+ "type": "string"
569
+ },
570
+ "time": {
571
+ "minimum": 0,
572
+ "type": "number"
573
+ },
574
+ "event": {
575
+ "title": "CutsceneEvent",
576
+ "anyOf": [
577
+ {
578
+ "additionalProperties": false,
579
+ "type": "object",
580
+ "required": [
581
+ "type",
582
+ "name",
583
+ "payload"
584
+ ],
585
+ "properties": {
586
+ "type": {
587
+ "const": "emit",
588
+ "type": "string"
589
+ },
590
+ "name": {
591
+ "type": "string"
592
+ },
593
+ "payload": {
594
+ "type": "object",
595
+ "patternProperties": {
596
+ "^(.*)$": {
597
+ "anyOf": [
598
+ {
599
+ "type": "string"
600
+ },
601
+ {
602
+ "type": "number"
603
+ },
604
+ {
605
+ "type": "boolean"
606
+ }
607
+ ]
608
+ }
609
+ }
610
+ }
611
+ }
612
+ },
613
+ {
614
+ "additionalProperties": false,
615
+ "type": "object",
616
+ "required": [
617
+ "type",
618
+ "entity",
619
+ "key"
620
+ ],
621
+ "properties": {
622
+ "type": {
623
+ "const": "playAnimation",
624
+ "type": "string"
625
+ },
626
+ "entity": {
627
+ "type": "string"
628
+ },
629
+ "key": {
630
+ "type": "string"
631
+ }
632
+ }
633
+ },
634
+ {
635
+ "additionalProperties": false,
636
+ "type": "object",
637
+ "required": [
638
+ "type",
639
+ "song",
640
+ "loop"
641
+ ],
642
+ "properties": {
643
+ "type": {
644
+ "const": "playSong",
645
+ "type": "string"
646
+ },
647
+ "song": {
648
+ "type": "string"
649
+ },
650
+ "loop": {
651
+ "type": "boolean"
652
+ }
653
+ }
654
+ },
655
+ {
656
+ "additionalProperties": false,
657
+ "type": "object",
658
+ "required": [
659
+ "type"
660
+ ],
661
+ "properties": {
662
+ "type": {
663
+ "const": "stopSong",
664
+ "type": "string"
665
+ },
666
+ "song": {
667
+ "type": "string"
668
+ }
669
+ }
670
+ },
671
+ {
672
+ "additionalProperties": false,
673
+ "type": "object",
674
+ "required": [
675
+ "type",
676
+ "name",
677
+ "value"
678
+ ],
679
+ "properties": {
680
+ "type": {
681
+ "const": "setVariable",
682
+ "type": "string"
683
+ },
684
+ "name": {
685
+ "type": "string"
686
+ },
687
+ "value": {
688
+ "anyOf": [
689
+ {
690
+ "type": "string"
691
+ },
692
+ {
693
+ "type": "number"
694
+ },
695
+ {
696
+ "type": "boolean"
697
+ }
698
+ ]
699
+ }
700
+ }
701
+ }
702
+ ]
703
+ }
704
+ }
705
+ }
706
+ }
707
+ }
708
+ },
709
+ {
710
+ "title": "AudioTrack",
711
+ "additionalProperties": false,
712
+ "type": "object",
713
+ "required": [
714
+ "kind",
715
+ "id",
716
+ "name",
717
+ "items"
718
+ ],
719
+ "properties": {
720
+ "kind": {
721
+ "const": "audio",
722
+ "type": "string"
723
+ },
724
+ "id": {
725
+ "type": "string"
726
+ },
727
+ "name": {
728
+ "type": "string"
729
+ },
730
+ "items": {
731
+ "type": "array",
732
+ "items": {
733
+ "title": "AudioItem",
734
+ "additionalProperties": false,
735
+ "type": "object",
736
+ "required": [
737
+ "id",
738
+ "time",
739
+ "kind",
740
+ "ref",
741
+ "loop",
742
+ "volume"
743
+ ],
744
+ "properties": {
745
+ "id": {
746
+ "type": "string"
747
+ },
748
+ "time": {
749
+ "minimum": 0,
750
+ "type": "number"
751
+ },
752
+ "kind": {
753
+ "anyOf": [
754
+ {
755
+ "const": "song",
756
+ "type": "string"
757
+ },
758
+ {
759
+ "const": "sfx",
760
+ "type": "string"
761
+ }
762
+ ]
763
+ },
764
+ "ref": {
765
+ "type": "string"
766
+ },
767
+ "loop": {
768
+ "type": "boolean"
769
+ },
770
+ "volume": {
771
+ "type": "number"
772
+ }
773
+ }
774
+ }
775
+ }
776
+ }
777
+ }
778
+ ]
779
+ }
780
+ }
781
+ }
782
+ }