@hytopia.com/server-protocol 1.0.66 → 1.0.67

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.0.66",
3
+ "version": "1.0.67",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"
@@ -7,21 +7,25 @@ import type { QuaternionSchema } from './Quaternion';
7
7
  import type { VectorSchema } from './Vector';
8
8
 
9
9
  export type ColliderDescSchema = {
10
- at?: number; // active collision types
11
- cg?: number; // collision groups
12
- cs?: number; // contact skin
13
- d?: number; // density
14
- f?: number; // friction
15
- fr?: number; // friction combine rule
16
- en?: boolean; // enabled
17
- m?: number; // mass
18
- re?: number; // restitution
19
- rer?: number; // restitution combine rule
20
- r?: QuaternionSchema; // rotation
21
- s?: ShapeSchema; // shape
22
- sg?: number; // solver groups
23
- sn?: boolean; // sensor
24
- t?: VectorSchema; // translation
10
+ at?: number; // active collision types
11
+ cg?: number; // collision groups
12
+ cm?: VectorSchema; // center of mass
13
+ cs?: number; // contact skin
14
+ d?: number; // density
15
+ f?: number; // friction
16
+ fr?: number; // friction combine rule
17
+ en?: boolean; // enabled
18
+ m?: number; // mass
19
+ mp?: number; // mass properties mode
20
+ pf?: QuaternionSchema; // principal angular inertia local frame
21
+ pi?: VectorSchema; // principal angular inertia
22
+ re?: number; // restitution
23
+ rer?: number; // restitution combine rule
24
+ r?: QuaternionSchema; // rotation
25
+ s?: ShapeSchema; // shape
26
+ sg?: number; // solver groups
27
+ sn?: boolean; // sensor
28
+ t?: VectorSchema; // translation
25
29
  }
26
30
 
27
31
  export const colliderDescSchema: JSONSchemaType<ColliderDescSchema> = {
@@ -29,12 +33,16 @@ export const colliderDescSchema: JSONSchemaType<ColliderDescSchema> = {
29
33
  properties: {
30
34
  at: { type: 'number', nullable: true },
31
35
  cg: { type: 'number', nullable: true },
36
+ cm: { ...vectorSchema, nullable: true },
32
37
  cs: { type: 'number', nullable: true },
33
38
  d: { type: 'number', nullable: true },
34
39
  f: { type: 'number', nullable: true },
35
40
  fr: { type: 'number', nullable: true },
36
41
  en: { type: 'boolean', nullable: true },
37
42
  m: { type: 'number', nullable: true },
43
+ mp: { type: 'number', nullable: true },
44
+ pf: { ...quaternionSchema, nullable: true },
45
+ pi: { ...vectorSchema, nullable: true },
38
46
  re: { type: 'number', nullable: true },
39
47
  rer: { type: 'number', nullable: true },
40
48
  r: { ...quaternionSchema, nullable: true },