@woosh/meep-engine 2.84.11 → 2.85.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.
- package/build/bundle-worker-terrain.js +1 -1
- package/build/meep.cjs +35 -26
- package/build/meep.min.js +1 -1
- package/build/meep.module.js +35 -26
- package/package.json +1 -1
- package/src/core/cache/LoadingCache.js +11 -10
- package/src/core/cache/LoadingCache.spec.js +37 -38
- package/src/core/collection/array/arraySetDiff.js +1 -0
- package/src/core/model/node-graph/json/deserializeNodeGraphFromJSON.js +91 -31
- package/src/core/primitives/array/computeIntegerArrayHash.js +3 -16
- package/src/core/primitives/array/computeStridedIntegerArrayHash.js +10 -4
- package/src/engine/Engine.d.ts +9 -8
- package/src/engine/Engine.js +24 -21
- package/src/engine/graphics/particles/node-based/editor/ParticleSpecificationEditorView.js +10 -10
- package/src/engine/knowledge/database/StaticKnowledgeDatabase.js +20 -6
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import View from "../../../../../view/View.js";
|
|
2
1
|
import { NodeGraphEditorView } from "../../../../../../editor/view/node-graph/NodeGraphEditorView.js";
|
|
3
2
|
import { NodeGraphCamera } from "../../../../../../editor/view/node-graph/NodeGraphView.js";
|
|
4
|
-
import
|
|
3
|
+
import { downloadAsFile } from "../../../../../core/binary/downloadAsFile.js";
|
|
5
4
|
import List from "../../../../../core/collection/list/List.js";
|
|
6
|
-
import LabelView from "../../../../../view/common/LabelView.js";
|
|
7
|
-
import { MouseEvents } from "../../../../input/devices/events/MouseEvents.js";
|
|
8
|
-
import InterfaceCommand from "../../../../../view/interaction/InterfaceCommand.js";
|
|
9
|
-
import { InteractionCommand } from "../../../../../view/interaction/InteractionCommand.js";
|
|
10
|
-
import { serializeNodeGraphToJSON } from "../../../../../core/model/node-graph/json/serializeNodeGraphToJSON.js";
|
|
11
5
|
import {
|
|
12
6
|
deserializeNodeGraphFromJSON
|
|
13
7
|
} from "../../../../../core/model/node-graph/json/deserializeNodeGraphFromJSON.js";
|
|
14
|
-
import {
|
|
8
|
+
import { serializeNodeGraphToJSON } from "../../../../../core/model/node-graph/json/serializeNodeGraphToJSON.js";
|
|
9
|
+
import LabelView from "../../../../../view/common/LabelView.js";
|
|
10
|
+
import ListView from "../../../../../view/common/ListView.js";
|
|
11
|
+
import { InteractionCommand } from "../../../../../view/interaction/InteractionCommand.js";
|
|
12
|
+
import InterfaceCommand from "../../../../../view/interaction/InterfaceCommand.js";
|
|
13
|
+
import View from "../../../../../view/View.js";
|
|
14
|
+
import { MouseEvents } from "../../../../input/devices/events/MouseEvents.js";
|
|
15
15
|
|
|
16
16
|
export class ParticleSpecificationEditorView extends View {
|
|
17
17
|
constructor() {
|
|
@@ -101,13 +101,13 @@ export class ParticleSpecificationEditorView extends View {
|
|
|
101
101
|
function processFile(file) {
|
|
102
102
|
const fr = new FileReader();
|
|
103
103
|
|
|
104
|
-
fr.onload = () => {
|
|
104
|
+
fr.onload = async () => {
|
|
105
105
|
|
|
106
106
|
visual.nodes.clear();
|
|
107
107
|
|
|
108
108
|
const json = JSON.parse(fr.result);
|
|
109
109
|
|
|
110
|
-
deserializeNodeGraphFromJSON({ graph: nodeGraph, json: json, node_registry: nodeRegistry });
|
|
110
|
+
await deserializeNodeGraphFromJSON({ graph: nodeGraph, json: json, node_registry: nodeRegistry });
|
|
111
111
|
|
|
112
112
|
visual.layout(nodeGraph);
|
|
113
113
|
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
+
import { IllegalStateException } from "../../../core/fsm/exceptions/IllegalStateException.js";
|
|
2
|
+
import { objectKeyByValue } from "../../../core/model/object/objectKeyByValue.js";
|
|
1
3
|
import ObservedEnum from "../../../core/model/ObservedEnum.js";
|
|
2
|
-
import { GameAssetType } from "../../asset/GameAssetType.js";
|
|
3
|
-
import TaskGroup from "../../../core/process/task/TaskGroup.js";
|
|
4
4
|
import Task from "../../../core/process/task/Task.js";
|
|
5
|
+
import TaskGroup from "../../../core/process/task/TaskGroup.js";
|
|
6
|
+
import { GameAssetType } from "../../asset/GameAssetType.js";
|
|
5
7
|
import { StaticKnowledgeDataTableDescriptor } from "./StaticKnowledgeDataTableDescriptor.js";
|
|
6
|
-
import { IllegalStateException } from "../../../core/fsm/exceptions/IllegalStateException.js";
|
|
7
|
-
import { objectKeyByValue } from "../../../core/model/object/objectKeyByValue.js";
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
10
|
* @readonly
|
|
@@ -32,7 +32,21 @@ export class StaticKnowledgeDatabase {
|
|
|
32
32
|
* @private
|
|
33
33
|
*/
|
|
34
34
|
__specs = [];
|
|
35
|
-
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {boolean}
|
|
39
|
+
*/
|
|
40
|
+
#validation_enabled = false;
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @param {boolean} v
|
|
45
|
+
*/
|
|
46
|
+
set validation_enabled(v) {
|
|
47
|
+
this.#validation_enabled = v;
|
|
48
|
+
}
|
|
49
|
+
|
|
36
50
|
|
|
37
51
|
/**
|
|
38
52
|
* Reset database, drop all table data
|
|
@@ -279,7 +293,7 @@ export class StaticKnowledgeDatabase {
|
|
|
279
293
|
return Promise.all(promises).then(() => {
|
|
280
294
|
let p = this.link(am, executor);
|
|
281
295
|
|
|
282
|
-
if (
|
|
296
|
+
if (this.#validation_enabled) {
|
|
283
297
|
p = p.then(() => this.validate(executor));
|
|
284
298
|
}
|
|
285
299
|
|