@hytopia.com/server-protocol 1.3.8 → 1.3.10

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,6 +1,6 @@
1
1
  {
2
2
  "name": "@hytopia.com/server-protocol",
3
- "version": "1.3.8",
3
+ "version": "1.3.10",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"
package/schemas/Camera.ts CHANGED
@@ -3,15 +3,16 @@ import { vectorSchema } from './Vector';
3
3
  import type { VectorSchema } from './Vector';
4
4
 
5
5
  export type CameraSchema = {
6
- f?: boolean // first person mode
7
- t?: boolean // third person mode
6
+ m?: number // camera mode - 0: first person, 1: third person
8
7
  e?: number // entity id to fix camera to
9
8
  et?: number // entity id to track
9
+ el?: number // entity id to look at
10
10
  fo?: number // film offset, + value shifts right, - shifts left
11
11
  ffo?: number // first person forward offset, moves camera in (+) or out (-) relative to camera position
12
12
  fv?: number // field of view
13
13
  p?: VectorSchema // position to fix camera at
14
14
  pt?: VectorSchema // position to track
15
+ pl?: VectorSchema // position to look at
15
16
  h?: string[] // player model parts to hide by partial case insensitive match of gltf node names
16
17
  o?: VectorSchema // offset - positional relative to target
17
18
  z?: number // zoom
@@ -20,15 +21,16 @@ export type CameraSchema = {
20
21
  export const cameraSchema: JSONSchemaType<CameraSchema> = {
21
22
  type: 'object',
22
23
  properties: {
23
- f: { type: 'boolean', nullable: true },
24
- t: { type: 'boolean', nullable: true },
24
+ m: { type: 'number', nullable: true },
25
25
  e: { type: 'number', nullable: true },
26
26
  et: { type: 'number', nullable: true },
27
+ el: { type: 'number', nullable: true },
27
28
  fo: { type: 'number', nullable: true },
28
29
  ffo: { type: 'number', nullable: true },
29
30
  fv: { type: 'number', nullable: true },
30
31
  p: { ...vectorSchema, nullable: true },
31
32
  pt: { ...vectorSchema, nullable: true },
33
+ pl: { ...vectorSchema, nullable: true },
32
34
  h: { type: 'array', items: { type: 'string' }, nullable: true },
33
35
  o: { ...vectorSchema, nullable: true },
34
36
  z: { type: 'number', nullable: true },