@hytopia.com/server-protocol 1.3.37 → 1.3.38

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 (2) hide show
  1. package/package.json +1 -1
  2. package/schemas/Light.ts +3 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hytopia.com/server-protocol",
3
- "version": "1.3.37",
3
+ "version": "1.3.38",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"
package/schemas/Light.ts CHANGED
@@ -13,8 +13,9 @@ export type LightSchema = {
13
13
  n?: number; // light intensity
14
14
  o?: VectorSchema; // offset
15
15
  p?: VectorSchema; // spatial position of the light
16
+ pe?: number; // if spotlight, penumbra %, 0 to 1
16
17
  rm?: boolean; // remove/removed
17
- t?: number; // light type
18
+ t?: number; // light type, 0: point, 1: spotlight
18
19
  te?: number; // if spotlight, tracked entity id
19
20
  tp?: VectorSchema; // if spotlight, tracked position
20
21
  }
@@ -30,6 +31,7 @@ export const lightSchema: JSONSchemaType<LightSchema> = {
30
31
  n: { type: 'number', nullable: true },
31
32
  o: { ...vectorSchema, nullable: true },
32
33
  p: { ...vectorSchema, nullable: true },
34
+ pe: { type: 'number', minimum: 0, maximum: 1, nullable: true },
33
35
  rm: { type: 'boolean', nullable: true },
34
36
  t: { type: 'number', nullable: true },
35
37
  te: { type: 'number', nullable: true },