@woosh/meep-engine 2.47.28 → 2.47.29

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.
@@ -54198,9 +54198,8 @@ class Vector1 extends Number {
54198
54198
  constructor(x = 0) {
54199
54199
  super();
54200
54200
 
54201
- assert.equal(typeof x, "number", `X must be of type "number", instead was "${typeof x}"`);
54202
-
54203
- assert.ok(!Number.isNaN(x), `X must be a valid number, instead was NaN`);
54201
+ assert.isNumber( x, 'x');
54202
+ assert.notNaN(x, 'x');
54204
54203
 
54205
54204
  this.x = x;
54206
54205
 
@@ -99956,13 +99955,12 @@ const BehaviorStatus = {
99956
99955
  * @template CTX
99957
99956
  */
99958
99957
  class Behavior {
99959
- constructor() {
99960
- /**
99961
- * Any internal state used by the behavior
99962
- * @type {CTX|null}
99963
- */
99964
- this.context = null;
99965
- }
99958
+
99959
+ /**
99960
+ * Any internal state used by the behavior
99961
+ * @type {CTX|null}
99962
+ */
99963
+ context = null;
99966
99964
 
99967
99965
  /**
99968
99966
  * Main update function. Every behavior executes some logic, some behaviors are long-running and some are instantaneous
package/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "description": "Fully featured ECS game engine written in JavaScript",
6
6
  "type": "module",
7
7
  "author": "Alexander Goldring",
8
- "version": "2.47.28",
8
+ "version": "2.47.29",
9
9
  "main": "build/meep.module.js",
10
10
  "module": "build/meep.module.js",
11
11
  "exports": {
@@ -20,9 +20,8 @@ class Vector1 extends Number {
20
20
  constructor(x = 0) {
21
21
  super();
22
22
 
23
- assert.equal(typeof x, "number", `X must be of type "number", instead was "${typeof x}"`);
24
-
25
- assert.ok(!Number.isNaN(x), `X must be a valid number, instead was NaN`);
23
+ assert.isNumber( x, 'x');
24
+ assert.notNaN(x, 'x');
26
25
 
27
26
  this.x = x;
28
27
 
@@ -1,3 +1,5 @@
1
+ import {Color} from "../../../../../core/color/Color";
2
+
1
3
  export class Decal {
2
4
  /**
3
5
  * Path to image
@@ -8,4 +10,6 @@ export class Decal {
8
10
  * Draw order, higher values will be drawn on top of lower values when there's an overlap
9
11
  */
10
12
  priority: number
13
+
14
+ color: Color
11
15
  }
@@ -6,13 +6,12 @@ import { BehaviorStatus } from "./BehaviorStatus.js";
6
6
  * @template CTX
7
7
  */
8
8
  export class Behavior {
9
- constructor() {
10
- /**
11
- * Any internal state used by the behavior
12
- * @type {CTX|null}
13
- */
14
- this.context = null;
15
- }
9
+
10
+ /**
11
+ * Any internal state used by the behavior
12
+ * @type {CTX|null}
13
+ */
14
+ context = null;
16
15
 
17
16
  /**
18
17
  * Main update function. Every behavior executes some logic, some behaviors are long-running and some are instantaneous