@woosh/meep-engine 2.127.0 → 2.128.0
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 +1 -1
- package/src/core/geom/packing/miniball/Miniball.d.ts +12 -10
- package/src/core/geom/packing/miniball/Miniball.d.ts.map +1 -1
- package/src/core/geom/packing/miniball/Miniball.js +76 -54
- package/src/engine/Clock.d.ts +2 -1
- package/src/engine/Clock.d.ts.map +1 -1
- package/src/engine/Clock.js +1 -0
- package/src/engine/ecs/EntityComponentDataset.d.ts.map +1 -1
- package/src/engine/ecs/EntityComponentDataset.js +2 -1
- package/src/engine/ecs/EntityManager.d.ts +5 -6
- package/src/engine/ecs/EntityManager.d.ts.map +1 -1
- package/src/engine/ecs/EntityManager.js +83 -37
- package/src/engine/ecs/System.d.ts +2 -2
- package/src/engine/ecs/System.d.ts.map +1 -1
- package/src/engine/ecs/System.js +41 -19
- package/src/engine/ecs/dynamic_actions/DynamicActorSystem.d.ts +1 -1
- package/src/engine/ecs/dynamic_actions/DynamicActorSystem.d.ts.map +1 -1
- package/src/engine/ecs/dynamic_actions/DynamicActorSystem.js +1 -4
- package/src/engine/ecs/fow/FogOfWarSystem.d.ts +2 -4
- package/src/engine/ecs/fow/FogOfWarSystem.d.ts.map +1 -1
- package/src/engine/ecs/fow/FogOfWarSystem.js +15 -21
- package/src/engine/ecs/gui/GUIElementSystem.d.ts.map +1 -1
- package/src/engine/ecs/gui/GUIElementSystem.js +7 -18
- package/src/engine/ecs/gui/hud/HeadsUpDisplaySystem.d.ts.map +1 -1
- package/src/engine/ecs/gui/hud/HeadsUpDisplaySystem.js +3 -10
- package/src/engine/ecs/gui/position/ViewportPositionSystem.d.ts +2 -2
- package/src/engine/ecs/gui/position/ViewportPositionSystem.d.ts.map +1 -1
- package/src/engine/ecs/gui/position/ViewportPositionSystem.js +2 -6
- package/src/engine/ecs/renderable/RenderSystem.d.ts.map +1 -1
- package/src/engine/ecs/renderable/RenderSystem.js +3 -7
- package/src/engine/ecs/speaker/VoiceSystem.d.ts +1 -1
- package/src/engine/ecs/speaker/VoiceSystem.d.ts.map +1 -1
- package/src/engine/ecs/speaker/VoiceSystem.js +2 -4
- package/src/engine/ecs/terrain/ecs/TerrainSystem.d.ts.map +1 -1
- package/src/engine/ecs/terrain/ecs/TerrainSystem.js +2 -5
- package/src/engine/ecs/tooltip/TooltipComponentSystem.d.ts +2 -2
- package/src/engine/ecs/tooltip/TooltipComponentSystem.d.ts.map +1 -1
- package/src/engine/ecs/tooltip/TooltipComponentSystem.js +10 -12
- package/src/engine/ecs/validateSystem.d.ts.map +1 -1
- package/src/engine/ecs/validateSystem.js +11 -2
- package/src/engine/graphics/ecs/camera/CameraSystem.d.ts.map +1 -1
- package/src/engine/graphics/ecs/camera/CameraSystem.js +5 -8
- package/src/engine/graphics/ecs/decal/v2/FPDecalSystem.d.ts.map +1 -1
- package/src/engine/graphics/ecs/decal/v2/FPDecalSystem.js +2 -6
- package/src/engine/graphics/ecs/highlight/system/MeshHighlightSystem.d.ts.map +1 -1
- package/src/engine/graphics/ecs/highlight/system/MeshHighlightSystem.js +14 -27
- package/src/engine/graphics/ecs/light/LightSystem.d.ts.map +1 -1
- package/src/engine/graphics/ecs/light/LightSystem.js +2 -6
- package/src/engine/graphics/ecs/mesh/MeshSystem.d.ts.map +1 -1
- package/src/engine/graphics/ecs/mesh/MeshSystem.js +2 -6
- package/src/engine/graphics/ecs/mesh-v2/ShadedGeometrySystem.d.ts.map +1 -1
- package/src/engine/graphics/ecs/mesh-v2/ShadedGeometrySystem.js +2 -5
- package/src/engine/graphics/ecs/mesh-v2/aggregate/SGMeshSystem.d.ts.map +1 -1
- package/src/engine/graphics/ecs/mesh-v2/aggregate/SGMeshSystem.js +1 -2
- package/src/engine/graphics/ecs/path/PathDisplaySystem.d.ts.map +1 -1
- package/src/engine/graphics/ecs/path/PathDisplaySystem.js +13 -17
- package/src/engine/graphics/ecs/trail2d/Trail2DSystem.d.ts.map +1 -1
- package/src/engine/graphics/ecs/trail2d/Trail2DSystem.js +2 -6
- package/src/engine/graphics/ecs/water/WaterSystem.d.ts +2 -2
- package/src/engine/graphics/ecs/water/WaterSystem.d.ts.map +1 -1
- package/src/engine/graphics/ecs/water/WaterSystem.js +5 -11
- package/src/engine/graphics/particles/ecs/ParticleEmitterSystem.d.ts.map +1 -1
- package/src/engine/graphics/particles/ecs/ParticleEmitterSystem.js +2 -6
- package/src/engine/graphics/render/frame_graph/RenderGraph.d.ts +51 -7
- package/src/engine/graphics/render/frame_graph/RenderGraph.d.ts.map +1 -1
- package/src/engine/graphics/render/frame_graph/RenderGraph.js +109 -8
- package/src/engine/graphics/render/frame_graph/RenderPassBuilder.d.ts +44 -0
- package/src/engine/graphics/render/frame_graph/RenderPassBuilder.d.ts.map +1 -0
- package/src/engine/graphics/render/frame_graph/{RenderGraphBuilder.js → RenderPassBuilder.js} +25 -6
- package/src/engine/graphics/render/frame_graph/RenderPassNode.d.ts +1 -0
- package/src/engine/graphics/render/frame_graph/RenderPassNode.d.ts.map +1 -1
- package/src/engine/graphics/render/frame_graph/RenderPassNode.js +1 -0
- package/src/engine/graphics/render/frame_graph/ResourceEntry.d.ts +8 -0
- package/src/engine/graphics/render/frame_graph/ResourceEntry.d.ts.map +1 -1
- package/src/engine/graphics/render/frame_graph/ResourceEntry.js +8 -0
- package/src/engine/graphics/render/frame_graph/resource/ResourceDescriptor.d.ts +1 -0
- package/src/engine/graphics/render/frame_graph/resource/ResourceDescriptor.d.ts.map +1 -1
- package/src/engine/graphics/render/frame_graph/resource/ResourceDescriptor.js +3 -0
- package/src/engine/input/ecs/systems/InputControllerSystem.d.ts.map +1 -1
- package/src/engine/input/ecs/systems/InputControllerSystem.js +1 -2
- package/src/engine/intelligence/behavior/ecs/BehaviorSystem.d.ts +2 -2
- package/src/engine/intelligence/behavior/ecs/BehaviorSystem.d.ts.map +1 -1
- package/src/engine/intelligence/behavior/ecs/BehaviorSystem.js +3 -5
- package/src/engine/sound/ecs/emitter/SoundEmitterSystem.d.ts +2 -2
- package/src/engine/sound/ecs/emitter/SoundEmitterSystem.d.ts.map +1 -1
- package/src/engine/sound/ecs/emitter/SoundEmitterSystem.js +2 -6
- package/src/engine/graphics/render/frame_graph/RenderGraphBuilder.d.ts +0 -33
- package/src/engine/graphics/render/frame_graph/RenderGraphBuilder.d.ts.map +0 -1
- package/src/engine/graphics/render/frame_graph/RenderPass.d.ts +0 -50
- package/src/engine/graphics/render/frame_graph/RenderPass.d.ts.map +0 -1
- package/src/engine/graphics/render/frame_graph/RenderPass.js +0 -74
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"System.d.ts","sourceRoot":"","sources":["../../../../src/engine/ecs/System.js"],"names":[],"mappings":"AAMA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH;IAEI;;;;;OAKG;IACH,uCAAqB;IAErB;;;;OAIG;IACH,oBAA+C;IAE/C
|
|
1
|
+
{"version":3,"file":"System.d.ts","sourceRoot":"","sources":["../../../../src/engine/ecs/System.js"],"names":[],"mappings":"AAMA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH;IAEI;;;;;OAKG;IACH,uCAAqB;IAErB;;;;OAIG;IACH,oBAA+C;IAE/C;;;;;;;OAOG;IACH,6BAAkB;IAElB;;;;;;;;;;OAUG;IACH,0BAFU,6BAA6B,CAElB;IAGrB;;OAEG;IACH,mCAcC;IAED;;;;;OAKG;IACH,oCAFY,MAAM,CA8BjB;IAED;;;;;;OAMG;IACH,uCAHa,QAAQ,IAAI,CAAC,CAKzB;IAED;;;;;;;OAOG;IACH,wCAHa,QAAQ,IAAI,CAAC,CAKzB;IAGD;;;;OAIG;IACH,wCAEC;IAED;;;;OAIG;IACH,0CAEC;IAED;;;;;;;;;;OAUG;IACH,6DAEC;IAED;;;;;;;;;;OAUG;IACH,6DAEC;IAIL;;;OAGG;IACH,mBAFU,OAAO,CAEQ;IAEzB;;;;OAIG;IACH,yBAA4B;IAG5B;;;;;;OAMG;IACH,oBAAuB;CAvBtB;;;;0BA8CS,MAAM;;;;;;;;qBAxPK,6BAA6B"}
|
package/src/engine/ecs/System.js
CHANGED
|
@@ -54,7 +54,9 @@ export class System {
|
|
|
54
54
|
/**
|
|
55
55
|
* Component classes which have to be present before the system links an entity.
|
|
56
56
|
* NOTE: do not modify this while the system is running.
|
|
57
|
-
* see
|
|
57
|
+
* @see link
|
|
58
|
+
* @see unlink
|
|
59
|
+
* @readonly
|
|
58
60
|
* @type {Array}
|
|
59
61
|
*/
|
|
60
62
|
dependencies = [];
|
|
@@ -67,6 +69,7 @@ export class System {
|
|
|
67
69
|
*
|
|
68
70
|
* NOTE: specifying this is optional. The engine will still work.
|
|
69
71
|
* NOTE: do not modify this while the system is running
|
|
72
|
+
* @readonly
|
|
70
73
|
* @type {ResourceAccessSpecification[]}
|
|
71
74
|
*/
|
|
72
75
|
components_used = [];
|
|
@@ -92,9 +95,10 @@ export class System {
|
|
|
92
95
|
}
|
|
93
96
|
|
|
94
97
|
/**
|
|
98
|
+
* Does not check if the component is present, will return 0 if not present.
|
|
95
99
|
* @template T
|
|
96
100
|
* @param {T} Klass
|
|
97
|
-
* @return {number}
|
|
101
|
+
* @return {number} bitmask of {@link ResourceAccessKind}
|
|
98
102
|
*/
|
|
99
103
|
getAccessForComponent(Klass) {
|
|
100
104
|
let result = 0;
|
|
@@ -127,27 +131,26 @@ export class System {
|
|
|
127
131
|
}
|
|
128
132
|
|
|
129
133
|
/**
|
|
130
|
-
* Invoked before
|
|
131
|
-
* Managed by {@EntityManager}'s lifecycle. Do not call this manually.
|
|
134
|
+
* Invoked before {@link System} is used for the first time.
|
|
135
|
+
* Managed by {@link EntityManager}'s lifecycle. Do not call this manually.
|
|
132
136
|
* @param {EntityManager} entityManager
|
|
133
|
-
* @
|
|
134
|
-
* @
|
|
137
|
+
* @returns {Promise<void>}
|
|
138
|
+
* @see shutdown
|
|
135
139
|
*/
|
|
136
|
-
startup(entityManager
|
|
137
|
-
|
|
138
|
-
readyCallback();
|
|
140
|
+
async startup(entityManager) {
|
|
141
|
+
// override as necessary
|
|
139
142
|
}
|
|
140
143
|
|
|
141
144
|
/**
|
|
142
|
-
* Invoked when
|
|
145
|
+
* Invoked when {@link System} is no longer needed.
|
|
143
146
|
* Good place to clean up any held resourced and terminate owned processes.
|
|
144
|
-
* Managed by {@EntityManager}'s lifecycle. Do not call this manually.
|
|
147
|
+
* Managed by {@link EntityManager}'s lifecycle. Do not call this manually.
|
|
145
148
|
* @param {EntityManager} entityManager
|
|
146
|
-
* @
|
|
147
|
-
* @
|
|
149
|
+
* @returns {Promise<void>}
|
|
150
|
+
* @see startup
|
|
148
151
|
*/
|
|
149
|
-
shutdown(entityManager
|
|
150
|
-
|
|
152
|
+
async shutdown(entityManager) {
|
|
153
|
+
// override as necessary
|
|
151
154
|
}
|
|
152
155
|
|
|
153
156
|
|
|
@@ -173,8 +176,10 @@ export class System {
|
|
|
173
176
|
* Invoked when a dataset is attached to the system, this happens before any entities are linked.
|
|
174
177
|
* Happens as a result of {@link EntityManager.attachDataSet}.
|
|
175
178
|
* It is generally advised *NOT* to modify the dataset here.
|
|
176
|
-
* Managed by {@EntityManager}'s lifecycle. Do not call this manually.
|
|
177
|
-
*
|
|
179
|
+
* Managed by {@link EntityManager}'s lifecycle. Do not call this manually.
|
|
180
|
+
*
|
|
181
|
+
* This method is entirely optional, it provides advanced functionality for situations where datasets are being switched on the fly.
|
|
182
|
+
*
|
|
178
183
|
* see {@link handleDatasetDetached} for the reverse.
|
|
179
184
|
* @param {EntityComponentDataset} dataset
|
|
180
185
|
*/
|
|
@@ -186,8 +191,10 @@ export class System {
|
|
|
186
191
|
* Invoked when dataset is about to be detached from the system, this happens after all entities have been unlinked.
|
|
187
192
|
* Happens as a result of {@link EntityManager.detachDataSet}.
|
|
188
193
|
* It is generally advised *NOT* to modify the dataset here.
|
|
189
|
-
* Managed by {@EntityManager}'s lifecycle. Do not call this manually.
|
|
190
|
-
*
|
|
194
|
+
* Managed by {@link EntityManager}'s lifecycle. Do not call this manually.
|
|
195
|
+
*
|
|
196
|
+
* This method is entirely optional, it provides advanced functionality for situations where datasets are being switched on the fly.
|
|
197
|
+
*
|
|
191
198
|
* see {@link handleDatasetAttached} for the reverse.
|
|
192
199
|
* @param {EntityComponentDataset} dataset
|
|
193
200
|
*/
|
|
@@ -245,9 +252,24 @@ Object.defineProperties(System.prototype, {
|
|
|
245
252
|
*/
|
|
246
253
|
export const SystemState = {
|
|
247
254
|
INITIAL: 0,
|
|
255
|
+
/**
|
|
256
|
+
* System is currently in the process of starting up.
|
|
257
|
+
* @see System.startup
|
|
258
|
+
*/
|
|
248
259
|
STARTING: 1,
|
|
260
|
+
/**
|
|
261
|
+
* System is in the main running state, after startup has successfully finished.
|
|
262
|
+
*/
|
|
249
263
|
RUNNING: 2,
|
|
264
|
+
/**
|
|
265
|
+
* System is currently in the process of shutting down.
|
|
266
|
+
* @see System.shutdown
|
|
267
|
+
*/
|
|
250
268
|
STOPPING: 3,
|
|
269
|
+
/**
|
|
270
|
+
* System has finished shutting down.
|
|
271
|
+
* @see System.shutdown
|
|
272
|
+
*/
|
|
251
273
|
STOPPED: 4
|
|
252
274
|
}
|
|
253
275
|
|
|
@@ -109,7 +109,7 @@ export class DynamicActorSystem extends AbstractContextSystem<any> {
|
|
|
109
109
|
* @returns {DynamicRuleDescription|undefined}
|
|
110
110
|
*/
|
|
111
111
|
match(entity: number, event: string, context: any): DynamicRuleDescription | undefined;
|
|
112
|
-
startup(entityManager: any
|
|
112
|
+
startup(entityManager: any): Promise<void>;
|
|
113
113
|
/**
|
|
114
114
|
*
|
|
115
115
|
* @param {DynamicActor} actor
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DynamicActorSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/dynamic_actions/DynamicActorSystem.js"],"names":[],"mappings":"AA6FA;IA4DI;;;OAGG;IACH,4BASC;IAxED,sCAA8B;IAE9B,kEAEE;IAEF;;;OAGG;IACH,sCAAgB;IAEhB;;;OAGG;IACH,OAFU,SAAS,CAEK;IAExB;;;;OAIG;IACH,iCAOG;IAEH;;;;OAIG;IACH,gCAAoC;IAEpC;;;OAGG;IACH,mCAAiB;IAEjB;;;;OAIG;IACH,uBAAmB;IAEnB;;;;OAIG;IACH,gBAAgB;IASZ;;;OAGG;IACH,eAAoB;IAIxB;;;OAGG;IACH,kBAFY,MAAM,CAIjB;IAED;;;;;OAKG;IACH,6BAJW,MAAM,uDAyBhB;IAED;;;OAGG;IACH,iCAFW,MAAM,QAehB;IAED;;;;;OAKG;IACH,oBAJW,MAAM,oDA4DhB;IAED;;;;OAIG;IACH,4BAHW,MAAM,SACN,SAAS,QAsDnB;IAED;;;;OAIG;IACH,yBAFY,yBAAuB,SAAS,CA6E3C;IAED;;;;;;;;;OASG;IACH,yFAHW,MAAM,GACJ;QAAC,MAAM,EAAC,MAAM,CAAC;QAAA,IAAI,yBAAwB;QAAC,KAAK,EAAE,SAAS,CAAA;KAAC,EAAE,CA4E3E;IAED;;;;;;OAMG;IACH,cALW,MAAM,SACN,MAAM,iBAEJ,yBAAuB,SAAS,CAiC5C;IAED,
|
|
1
|
+
{"version":3,"file":"DynamicActorSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/dynamic_actions/DynamicActorSystem.js"],"names":[],"mappings":"AA6FA;IA4DI;;;OAGG;IACH,4BASC;IAxED,sCAA8B;IAE9B,kEAEE;IAEF;;;OAGG;IACH,sCAAgB;IAEhB;;;OAGG;IACH,OAFU,SAAS,CAEK;IAExB;;;;OAIG;IACH,iCAOG;IAEH;;;;OAIG;IACH,gCAAoC;IAEpC;;;OAGG;IACH,mCAAiB;IAEjB;;;;OAIG;IACH,uBAAmB;IAEnB;;;;OAIG;IACH,gBAAgB;IASZ;;;OAGG;IACH,eAAoB;IAIxB;;;OAGG;IACH,kBAFY,MAAM,CAIjB;IAED;;;;;OAKG;IACH,6BAJW,MAAM,uDAyBhB;IAED;;;OAGG;IACH,iCAFW,MAAM,QAehB;IAED;;;;;OAKG;IACH,oBAJW,MAAM,oDA4DhB;IAED;;;;OAIG;IACH,4BAHW,MAAM,SACN,SAAS,QAsDnB;IAED;;;;OAIG;IACH,yBAFY,yBAAuB,SAAS,CA6E3C;IAED;;;;;;;;;OASG;IACH,yFAHW,MAAM,GACJ;QAAC,MAAM,EAAC,MAAM,CAAC;QAAA,IAAI,yBAAwB;QAAC,KAAK,EAAE,SAAS,CAAA;KAAC,EAAE,CA4E3E;IAED;;;;;;OAMG;IACH,cALW,MAAM,SACN,MAAM,iBAEJ,yBAAuB,SAAS,CAiC5C;IAED,2CAQC;IAED;;;;;OAKG;IACH,mCAiBC;IAED,6BAYC;CACJ;sCAtkBqC,oCAAoC;6BAG7C,mBAAmB;2BATrB,6CAA6C;4CAP5B,oDAAoD;0BAetE,gBAAgB;2BAnBf,sCAAsC"}
|
|
@@ -553,17 +553,14 @@ export class DynamicActorSystem extends AbstractContextSystem {
|
|
|
553
553
|
return description;
|
|
554
554
|
}
|
|
555
555
|
|
|
556
|
-
async startup(entityManager
|
|
556
|
+
async startup(entityManager) {
|
|
557
557
|
const staticKnowledge = this.engine.staticKnowledge;
|
|
558
558
|
|
|
559
|
-
|
|
560
559
|
await staticKnowledge.promise();
|
|
561
560
|
|
|
562
561
|
this.database = staticKnowledge.getTable('dynamic-actions');
|
|
563
562
|
|
|
564
563
|
this.evaluator = this.database.buildEvaluator();
|
|
565
|
-
|
|
566
|
-
super.startup(entityManager, readyCallback, errorCallback);
|
|
567
564
|
}
|
|
568
565
|
|
|
569
566
|
/**
|
|
@@ -26,12 +26,10 @@ export class FogOfWarSystem extends System<any, any, any, any, any> {
|
|
|
26
26
|
/**
|
|
27
27
|
*
|
|
28
28
|
* @param {EntityManager} entityManager
|
|
29
|
-
* @param readyCallback
|
|
30
|
-
* @param errorCallback
|
|
31
29
|
*/
|
|
32
|
-
startup(entityManager: EntityManager
|
|
30
|
+
startup(entityManager: EntityManager): Promise<void>;
|
|
33
31
|
renderTarget: any;
|
|
34
|
-
shutdown(entityManager: any
|
|
32
|
+
shutdown(entityManager: any): Promise<void>;
|
|
35
33
|
/**
|
|
36
34
|
*
|
|
37
35
|
* @param {FogOfWar} fow
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FogOfWarSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/fow/FogOfWarSystem.js"],"names":[],"mappings":"AAwBA;IACI;;;OAGG;IACH,sCA0BC;IAvBG;;;OAGG;IACH,yBAAwB;IAExB,mDAAuC;IAEvC,gEAEC;IAED,mCAAoD;IAIpD;;;OAGG;IACH,eAFU,aAAa,CAEE;IAEzB,uBAAuB;IAG3B;;;OAGG;IACH,yBAFa,gBAAgB,CAuE5B;IAED
|
|
1
|
+
{"version":3,"file":"FogOfWarSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/fow/FogOfWarSystem.js"],"names":[],"mappings":"AAwBA;IACI;;;OAGG;IACH,sCA0BC;IAvBG;;;OAGG;IACH,yBAAwB;IAExB,mDAAuC;IAEvC,gEAEC;IAED,mCAAoD;IAIpD;;;OAGG;IACH,eAFU,aAAa,CAEE;IAEzB,uBAAuB;IAG3B;;;OAGG;IACH,yBAFa,gBAAgB,CAuE5B;IAED;;;OAGG;IACH,qDA6EC;IA7DG,kBAAgC;IA+DpC,4CAEC;IAED;;;;;OAKG;IACH,UAJW,QAAQ,WACR,OAAO,UACP,MAAM,QAmBhB;IAED,kDAQC;IAED,6BAUC;CACJ;uBAzPsB,cAAc;oBACjB,2BAA2B;yBACtB,eAAe;4CAdI,oDAAoD;iCAS/D,sDAAsD;8BAPzD,0CAA0C"}
|
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import { System } from "../System.js";
|
|
2
|
-
import { FogOfWar } from "./FogOfWar.js";
|
|
3
|
-
import Terrain from "../terrain/ecs/Terrain.js";
|
|
4
1
|
import { Frustum } from "three";
|
|
5
|
-
import { VisibilityFilter } from "../../graphics/render/visibility/VisibilityFilter.js";
|
|
6
|
-
import Vector4 from "../../../core/geom/Vector4.js";
|
|
7
|
-
import { Camera } from "../../graphics/ecs/camera/Camera.js";
|
|
8
|
-
import WaterSystem from "../../graphics/ecs/water/WaterSystem.js";
|
|
9
2
|
import Vector3 from "../../../core/geom/Vector3.js";
|
|
10
|
-
import
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import { CompositLayer } from "../../graphics/composit/CompositLayer.js";
|
|
3
|
+
import Vector4 from "../../../core/geom/Vector4.js";
|
|
4
|
+
import { ResourceAccessKind } from "../../../core/model/ResourceAccessKind.js";
|
|
5
|
+
import { ResourceAccessSpecification } from "../../../core/model/ResourceAccessSpecification.js";
|
|
14
6
|
import { CompositingStages } from "../../graphics/composit/CompositingStages.js";
|
|
7
|
+
import { CompositLayer } from "../../graphics/composit/CompositLayer.js";
|
|
8
|
+
import { Camera } from "../../graphics/ecs/camera/Camera.js";
|
|
15
9
|
import {
|
|
16
10
|
compute_perspective_camera_focal_position
|
|
17
11
|
} from "../../graphics/ecs/camera/compute_perspective_camera_focal_position.js";
|
|
18
12
|
import { frustum_from_camera } from "../../graphics/ecs/camera/frustum_from_camera.js";
|
|
19
|
-
import
|
|
20
|
-
import {
|
|
13
|
+
import WaterSystem from "../../graphics/ecs/water/WaterSystem.js";
|
|
14
|
+
import { VisibilityFilter } from "../../graphics/render/visibility/VisibilityFilter.js";
|
|
15
|
+
import { StandardFrameBuffers } from "../../graphics/StandardFrameBuffers.js";
|
|
16
|
+
import { BlendingType } from "../../graphics/texture/sampler/BlendingType.js";
|
|
17
|
+
import { System } from "../System.js";
|
|
18
|
+
import Terrain from "../terrain/ecs/Terrain.js";
|
|
19
|
+
import { FogOfWar } from "./FogOfWar.js";
|
|
20
|
+
import { FogOfWarRenderer } from "./shader/FogOfWarRenderer.js";
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
const frustum = new Frustum();
|
|
@@ -133,10 +133,8 @@ export class FogOfWarSystem extends System {
|
|
|
133
133
|
/**
|
|
134
134
|
*
|
|
135
135
|
* @param {EntityManager} entityManager
|
|
136
|
-
* @param readyCallback
|
|
137
|
-
* @param errorCallback
|
|
138
136
|
*/
|
|
139
|
-
startup(entityManager
|
|
137
|
+
async startup(entityManager) {
|
|
140
138
|
this.entityManager = entityManager;
|
|
141
139
|
|
|
142
140
|
const graphics = this.graphics;
|
|
@@ -213,14 +211,10 @@ export class FogOfWarSystem extends System {
|
|
|
213
211
|
}
|
|
214
212
|
});
|
|
215
213
|
|
|
216
|
-
|
|
217
|
-
readyCallback();
|
|
218
214
|
}
|
|
219
215
|
|
|
220
|
-
shutdown(entityManager
|
|
216
|
+
async shutdown(entityManager) {
|
|
221
217
|
this.graphics.layerComposer.remove(this.compositLayer);
|
|
222
|
-
|
|
223
|
-
super.shutdown(entityManager, readyCallback, errorCallback);
|
|
224
218
|
}
|
|
225
219
|
|
|
226
220
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GUIElementSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/gui/GUIElementSystem.js"],"names":[],"mappings":"AAgCA,gFAAiF;;AAEjF;IAyBI;;;;;OAKG;IACH,2BAJW,IAAI,kBAqCd;IA9DD,gBAaG;IAEH,oCAA4B;IAE5B;;;OAGG;IACH,YAAY;IA2BR,iCAAkC;IAGlC;;OAEG;IACH,8BAA0C;IAE1C;;;OAGG;IACH,eAAoB;IAIxB,
|
|
1
|
+
{"version":3,"file":"GUIElementSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/gui/GUIElementSystem.js"],"names":[],"mappings":"AAgCA,gFAAiF;;AAEjF;IAyBI;;;;;OAKG;IACH,2BAJW,IAAI,kBAqCd;IA9DD,gBAaG;IAEH,oCAA4B;IAE5B;;;OAGG;IACH,YAAY;IA2BR,iCAAkC;IAGlC;;OAEG;IACH,8BAA0C;IAE1C;;;OAGG;IACH,eAAoB;IAIxB,gCAGC;IAED,iCAEC;IAED;;;;OAIG;IACH,2BAHW,UAAU,UACV,MAAM,QA6DhB;IAED;;;;OAIG;IACH,2BAHW,UAAU,UACV,MAAM,QAoBhB;IAED;;;;OAIG;IACH,gBAHW,UAAU,qBAiDpB;IAED;;;;OAIG;IACH,kBAHW,UAAU,qBAiBpB;CACJ;uBA/QsB,cAAc;sBAFf,qCAAqC;uBAGhB,iBAAiB;iBAF3C,uBAAuB"}
|
|
@@ -65,11 +65,11 @@ class GUIElementSystem extends System {
|
|
|
65
65
|
*/
|
|
66
66
|
constructor(containerView, engine) {
|
|
67
67
|
if (containerView === undefined) {
|
|
68
|
-
throw
|
|
68
|
+
throw new Error(`mandatory parameter containerView is undefined`);
|
|
69
69
|
}
|
|
70
70
|
|
|
71
71
|
if (containerView === null) {
|
|
72
|
-
throw
|
|
72
|
+
throw new Error(`mandatory parameter containerView is null`);
|
|
73
73
|
}
|
|
74
74
|
|
|
75
75
|
if (!(containerView instanceof View)) {
|
|
@@ -98,24 +98,13 @@ class GUIElementSystem extends System {
|
|
|
98
98
|
|
|
99
99
|
}
|
|
100
100
|
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
cmOk();
|
|
105
|
-
} catch (e) {
|
|
106
|
-
cbFailure(e);
|
|
107
|
-
}
|
|
108
|
-
|
|
101
|
+
async startup(em) {
|
|
102
|
+
this.entityManager = em;
|
|
103
|
+
this.containerView.addChild(this.view);
|
|
109
104
|
}
|
|
110
105
|
|
|
111
|
-
|
|
112
|
-
this.
|
|
113
|
-
try {
|
|
114
|
-
this.containerView.addChild(this.view);
|
|
115
|
-
cbOK();
|
|
116
|
-
} catch (e) {
|
|
117
|
-
cbFailure(e);
|
|
118
|
-
}
|
|
106
|
+
async shutdown(em) {
|
|
107
|
+
this.containerView.removeChild(this.view);
|
|
119
108
|
}
|
|
120
109
|
|
|
121
110
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HeadsUpDisplaySystem.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/ecs/gui/hud/HeadsUpDisplaySystem.js"],"names":[],"mappings":";AAeA;;;;;GAKG;AACH;IASI;;;OAGG;IACH,4BAFW,cAAc,EAqBxB;IA/BD,wCAAgC;IAGhC,2HAGE;IAaE,yBAA8B;IAM9B;;;;OAIG;IACH,+BAAiD;IAGrD,
|
|
1
|
+
{"version":3,"file":"HeadsUpDisplaySystem.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/ecs/gui/hud/HeadsUpDisplaySystem.js"],"names":[],"mappings":";AAeA;;;;;GAKG;AACH;IASI;;;OAGG;IACH,4BAFW,cAAc,EAqBxB;IA/BD,wCAAgC;IAGhC,2HAGE;IAaE,yBAA8B;IAM9B;;;;OAIG;IACH,+BAAiD;IAGrD,iCAGC;IAED,gCAIC;IAED;;;;;;;OAOG;IACH,sCAwGC;IAED,6BAsBC;CACJ;uBAtMsB,iBAAiB;2BAIb,qBAAqB;uBAFzB,kBAAkB;4CALG,uDAAuD;6BAMtE,iCAAiC;+BAL/B,qCAAqC"}
|
|
@@ -53,22 +53,15 @@ class HeadsUpDisplaySystem extends System {
|
|
|
53
53
|
this.__visibility_predicate = visibilityPredicate;
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
-
shutdown(em
|
|
57
|
-
|
|
58
|
-
this.graphics.on.preRender.remove(this.synchronizePositions, this);
|
|
56
|
+
async shutdown(em) {
|
|
57
|
+
this.graphics.on.preRender.remove(this.synchronizePositions, this);
|
|
59
58
|
|
|
60
|
-
cbOK();
|
|
61
|
-
} catch (e) {
|
|
62
|
-
cbFailure(e);
|
|
63
|
-
}
|
|
64
59
|
}
|
|
65
60
|
|
|
66
|
-
startup(em
|
|
61
|
+
async startup(em) {
|
|
67
62
|
this.entityManager = em;
|
|
68
63
|
|
|
69
64
|
this.graphics.on.preRender.add(this.synchronizePositions, this);
|
|
70
|
-
|
|
71
|
-
cbOK();
|
|
72
65
|
}
|
|
73
66
|
|
|
74
67
|
/**
|
|
@@ -6,8 +6,8 @@ declare class ViewportPositionSystem extends System<any, any, any, any, any> {
|
|
|
6
6
|
viewportSize: any;
|
|
7
7
|
viewportSizeChangeReactor: SignalBinding;
|
|
8
8
|
data: {};
|
|
9
|
-
startup(entityManager: any
|
|
10
|
-
shutdown(entityManager: any
|
|
9
|
+
startup(entityManager: any): Promise<void>;
|
|
10
|
+
shutdown(entityManager: any): Promise<void>;
|
|
11
11
|
/**
|
|
12
12
|
* @param {GUIElement} el
|
|
13
13
|
* @param {ViewportPosition} vp
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ViewportPositionSystem.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/ecs/gui/position/ViewportPositionSystem.js"],"names":[],"mappings":";AAsBA;IACI,+BAoBC;IAjBG,8DAAkD;IAElD,kEAEC;IAED,kBAAgC;IAEhC,yCAME;IAEF,SAAc;IAGlB,
|
|
1
|
+
{"version":3,"file":"ViewportPositionSystem.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/ecs/gui/position/ViewportPositionSystem.js"],"names":[],"mappings":";AAsBA;IACI,+BAoBC;IAjBG,8DAAkD;IAElD,kEAEC;IAED,kBAAgC;IAEhC,yCAME;IAEF,SAAc;IAGlB,2CAEC;IAED,4CAEC;IAED;;;OAGG;IACH,sBAHW,UAAU,MACV,gBAAgB,QAkE1B;IAED;;;;;OAKG;IACH,SAJW,gBAAgB,MAChB,UAAU,qBA8BpB;IAED;;;;;OAKG;IACH,WAJW,gBAAgB,MAChB,UAAU,qBAmBpB;IA4EL;;;OAGG;IACH,mCAFU,OAAO,CAEwC;CA7ExD;uBAjLsB,iBAAiB;uBACjB,kBAAkB;6BAEZ,uBAAuB;4CAJR,uDAAuD;8BAJrE,iDAAiD"}
|
|
@@ -43,15 +43,11 @@ class ViewportPositionSystem extends System {
|
|
|
43
43
|
this.data = {};
|
|
44
44
|
}
|
|
45
45
|
|
|
46
|
-
startup(entityManager
|
|
47
|
-
super.startup(entityManager, readyCallback, errorCallback);
|
|
48
|
-
|
|
46
|
+
async startup(entityManager) {
|
|
49
47
|
this.viewportSizeChangeReactor.link();
|
|
50
48
|
}
|
|
51
49
|
|
|
52
|
-
shutdown(entityManager
|
|
53
|
-
super.shutdown(entityManager, readyCallback, errorCallback);
|
|
54
|
-
|
|
50
|
+
async shutdown(entityManager) {
|
|
55
51
|
this.viewportSizeChangeReactor.unlink();
|
|
56
52
|
}
|
|
57
53
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RenderSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/renderable/RenderSystem.js"],"names":[],"mappings":";AAcA;;GAEG;AACH;IAqBI;;;;OAIG;IACH,4CAOC;IAhCD,uDAAuC;IAEvC,kEAEE;IAEF,kBAAgB;IAEhB;;;OAGG;IACH,aAFU,cAAY,IAAI,CAEP;IAEnB;;;OAGG;IACH,KAFU,GAAG,CAEG;IAUZ;;OAEG;IACH,yBAA8B;IAGlC,
|
|
1
|
+
{"version":3,"file":"RenderSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/renderable/RenderSystem.js"],"names":[],"mappings":";AAcA;;GAEG;AACH;IAqBI;;;;OAIG;IACH,4CAOC;IAhCD,uDAAuC;IAEvC,kEAEE;IAEF,kBAAgB;IAEhB;;;OAGG;IACH,aAFU,cAAY,IAAI,CAEP;IAEnB;;;OAGG;IACH,KAFU,GAAG,CAEG;IAUZ;;OAEG;IACH,yBAA8B;IAGlC,2CA8CC;IAED,4CAEC;IAED;;;;;OAKG;IACH,iBAJW,UAAU,aACV,SAAS,qBAwCnB;IAED;;;;;OAKG;IACH,mBAJW,UAAU,aACV,SAAS,qBAiBnB;IAED;;;;;;;;;;;;OAYG;IACH,gEAVW,MAAM,YACN,MAAM,YACN,MAAM,eACN,MAAM,eACN,MAAM,eACN,MAAM,kBACG,MAAM,QAAE,UAAU,mCAA0B,OAAO,wBAE1D,MAAM,CAelB;CACJ;uBA9LsB,cAAc;0BACX,2BAA2B;uBAC9B,iBAAiB;4CAPI,oDAAoD;oBAH5E,gCAAgC"}
|
|
@@ -50,7 +50,7 @@ class RenderSystem extends System {
|
|
|
50
50
|
this.graphics = graphicsEngine;
|
|
51
51
|
}
|
|
52
52
|
|
|
53
|
-
startup(entityManager
|
|
53
|
+
async startup(entityManager) {
|
|
54
54
|
this.entityManager = entityManager;
|
|
55
55
|
|
|
56
56
|
this.renderLayer = this.graphics.layers.create('render-system');
|
|
@@ -96,14 +96,10 @@ class RenderSystem extends System {
|
|
|
96
96
|
|
|
97
97
|
component.clearFlag(RenderableFlags.InView);
|
|
98
98
|
});
|
|
99
|
-
|
|
100
|
-
readyCallback();
|
|
101
99
|
}
|
|
102
100
|
|
|
103
|
-
shutdown(entityManager
|
|
101
|
+
async shutdown(entityManager) {
|
|
104
102
|
this.graphics.layers.remove(this.renderLayer);
|
|
105
|
-
|
|
106
|
-
readyCallback();
|
|
107
103
|
}
|
|
108
104
|
|
|
109
105
|
/**
|
|
@@ -148,7 +144,7 @@ class RenderSystem extends System {
|
|
|
148
144
|
|
|
149
145
|
handle_transform_change();
|
|
150
146
|
|
|
151
|
-
renderable.bvh.link(this.bvh,entity);
|
|
147
|
+
renderable.bvh.link(this.bvh, entity);
|
|
152
148
|
}
|
|
153
149
|
|
|
154
150
|
/**
|
|
@@ -75,7 +75,7 @@ export class VoiceSystem extends AbstractContextSystem<any> {
|
|
|
75
75
|
* @return {number}
|
|
76
76
|
*/
|
|
77
77
|
getCurrentTime(): number;
|
|
78
|
-
startup(entityManager: any
|
|
78
|
+
startup(entityManager: any): Promise<void>;
|
|
79
79
|
/**
|
|
80
80
|
*
|
|
81
81
|
* @param {number} entity
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"VoiceSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/speaker/VoiceSystem.js"],"names":[],"mappings":"AA2JA;IACI;;;;OAIG;IACH;;;OA2FC;IArFG,+BAA2B;IAE3B,qYAQC;IAGD;;;OAGG;IACH,0BAAuB;IAEvB;;;OAGG;IACH,eAAe;IAEf;;;OAGG;IACH,4BAAiB;IAEjB;;;OAGG;IACH,8BAAgB;IAEhB;;;OAGG;IACH,eAAoB;IAEpB;;;;OAIG;IACH,iCAAyC;IAEzC;;;;OAIG;IACH,kBAAkC;IAIlC;;;;OAIG;IACH,eAAkB;IAElB;;;;OAIG;IACH,oBAAgC;IAEhC;;;OAGG;IACH,oBAAqC;IAErC;;;;OAIG;IACH,gBAAoB;IAGxB;;;OAGG;IACH,kBAFY,MAAM,CAIjB;
|
|
1
|
+
{"version":3,"file":"VoiceSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/speaker/VoiceSystem.js"],"names":[],"mappings":"AA2JA;IACI;;;;OAIG;IACH;;;OA2FC;IArFG,+BAA2B;IAE3B,qYAQC;IAGD;;;OAGG;IACH,0BAAuB;IAEvB;;;OAGG;IACH,eAAe;IAEf;;;OAGG;IACH,4BAAiB;IAEjB;;;OAGG;IACH,8BAAgB;IAEhB;;;OAGG;IACH,eAAoB;IAEpB;;;;OAIG;IACH,iCAAyC;IAEzC;;;;OAIG;IACH,kBAAkC;IAIlC;;;;OAIG;IACH,eAAkB;IAElB;;;;OAIG;IACH,oBAAgC;IAEhC;;;OAGG;IACH,oBAAqC;IAErC;;;;OAIG;IACH,gBAAoB;IAGxB;;;OAGG;IACH,kBAFY,MAAM,CAIjB;IAEF,2CAqBE;IAED;;;;;OAKG;IACH,uBAJW,MAAM,UACN,MAAM,SACN,KAAK,QAsBf;IAED;;;;;OAKG;IACH,wBAoBC;IAED;;;;;OAKG;IACH,gBAJW,MAAM,WACN,MAAM,SACN,KAAK,QAuHf;CACJ;sCAtbqC,oCAAoC;sBAIpD,YAAY;uBAPX,sBAAsB;4CAnBD,oDAAoD;0BAwBtE,2BAA2B;6BAHxB,qCAAqC;2BADvC,8BAA8B;2BAL9B,6BAA6B;sCAClB,wCAAwC;kCAR5C,sDAAsD"}
|
|
@@ -260,7 +260,7 @@ export class VoiceSystem extends AbstractContextSystem {
|
|
|
260
260
|
return this.engine.ticker.clock.getElapsedTime();
|
|
261
261
|
}
|
|
262
262
|
|
|
263
|
-
|
|
263
|
+
async startup(entityManager) {
|
|
264
264
|
|
|
265
265
|
const engine = this.engine;
|
|
266
266
|
|
|
@@ -280,9 +280,7 @@ export class VoiceSystem extends AbstractContextSystem {
|
|
|
280
280
|
this.__font = font_asset.create();
|
|
281
281
|
});
|
|
282
282
|
|
|
283
|
-
p_font_setting
|
|
284
|
-
super.startup(entityManager, readyCallback, errorCallback);
|
|
285
|
-
}, errorCallback);
|
|
283
|
+
await p_font_setting;
|
|
286
284
|
}
|
|
287
285
|
|
|
288
286
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TerrainSystem.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/ecs/terrain/ecs/TerrainSystem.js"],"names":[],"mappings":";AA+BA;
|
|
1
|
+
{"version":3,"file":"TerrainSystem.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/ecs/terrain/ecs/TerrainSystem.js"],"names":[],"mappings":";AA+BA;IAwMI;;;;;OAKG;IACH,kEAHW,OAAO,uBAwCjB;IA1ND;;;;;OAKG;IACH,kEAeC;IA7CD,iCAAyB;IAEzB,mBAAe;IACf,mBAAe;IAEf;;;;OAIG;IACH,qBAAiB;IAEjB;;;OAGG;IACH,aAFU,cAAY,IAAI,CAEP;IAEnB;;;OAGG;IACH,KAFU,GAAG,CAEG;IAoBZ,yBAAwB;IAExB,2BAAgC;IAGpC,kDAMC;IAED,2CAwDC;IAED,4CAEC;IAED;;;;OAIG;IACH,gBAHW,OAAO,qBAqBjB;IAED;;;;OAIG;IACH,kBAHW,OAAO,qBAKjB;IAED,6BAaC;IAED;;;;;OAKG;IACH,gCAwBC;CA+CJ;uBAvQsB,iBAAiB;oBAEpB,cAAc;oBAbd,mCAAmC"}
|
|
@@ -85,7 +85,7 @@ class TerrainSystem extends System {
|
|
|
85
85
|
v3.set(wX, wY, wZ);
|
|
86
86
|
}
|
|
87
87
|
|
|
88
|
-
async startup(entityManager
|
|
88
|
+
async startup(entityManager) {
|
|
89
89
|
this.entityManager = entityManager;
|
|
90
90
|
|
|
91
91
|
this.renderLayer = this.graphics.layers.create('terrain-system');
|
|
@@ -141,13 +141,10 @@ class TerrainSystem extends System {
|
|
|
141
141
|
await am.tryRegisterLoader('image', new ImageRGBADataLoader());
|
|
142
142
|
await am.tryRegisterLoader('texture', new TextureAssetLoader());
|
|
143
143
|
|
|
144
|
-
readyCallback();
|
|
145
144
|
}
|
|
146
145
|
|
|
147
|
-
shutdown(entityManager
|
|
146
|
+
async shutdown(entityManager) {
|
|
148
147
|
this.graphics.layers.remove(this.renderLayer);
|
|
149
|
-
|
|
150
|
-
readyCallback();
|
|
151
148
|
}
|
|
152
149
|
|
|
153
150
|
/**
|
|
@@ -65,8 +65,8 @@ export class TooltipComponentSystem extends System<any, any, any, any, any> {
|
|
|
65
65
|
*/
|
|
66
66
|
private __isOnRenderCanvas;
|
|
67
67
|
__computeTooltipTarget(): number;
|
|
68
|
-
startup(entityManager: any
|
|
69
|
-
shutdown(entityManager: any
|
|
68
|
+
startup(entityManager: any): Promise<void>;
|
|
69
|
+
shutdown(entityManager: any): Promise<void>;
|
|
70
70
|
update(timeDelta: any): void;
|
|
71
71
|
}
|
|
72
72
|
import { System } from "../System.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TooltipComponentSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/tooltip/TooltipComponentSystem.js"],"names":[],"mappings":"AAiBA;IACI;;;;;;OAMG;IACH,2EAgEC;IA7DG,0CAAsC;IAEtC,4DAEC;IAED;;;OAGG;IACH,yBAAwB;IAExB;;;OAGG;IACH,yBAAwB;IAExB;;;OAGG;IACH,uBAAsB;IAEtB;;;OAGG;IACH,2BAAgC;IAEhC;;;OAGG;IACH,4BAFU,MAAM,CAEmB;IAEnC;;;OAGG;IACH,eAFU,MAAM,CAEQ;IAExB;;;OAGG;IACH,QAFU,SAAS,CAEU;IAE7B;;;OAGG;IACH,KAFU,SAAS,CAEJ;IAGf;;;;OAIG;IACH,6BAA8B;IAIlC,mBAQC;IAED,6BAYC;IAED,gCAKC;IAED;;;;OAIG;IACH,2BAEC;IAED,iCAsCC;IAED,
|
|
1
|
+
{"version":3,"file":"TooltipComponentSystem.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/tooltip/TooltipComponentSystem.js"],"names":[],"mappings":"AAiBA;IACI;;;;;;OAMG;IACH,2EAgEC;IA7DG,0CAAsC;IAEtC,4DAEC;IAED;;;OAGG;IACH,yBAAwB;IAExB;;;OAGG;IACH,yBAAwB;IAExB;;;OAGG;IACH,uBAAsB;IAEtB;;;OAGG;IACH,2BAAgC;IAEhC;;;OAGG;IACH,4BAFU,MAAM,CAEmB;IAEnC;;;OAGG;IACH,eAFU,MAAM,CAEQ;IAExB;;;OAGG;IACH,QAFU,SAAS,CAEU;IAE7B;;;OAGG;IACH,KAFU,SAAS,CAEJ;IAGf;;;;OAIG;IACH,6BAA8B;IAIlC,mBAQC;IAED,6BAYC;IAED,gCAKC;IAED;;;;OAIG;IACH,2BAEC;IAED,iCAsCC;IAED,2CAIC;IAED,4CAIC;IAED,6BAqDC;CACJ;uBArOsB,cAAc;iCACJ,uBAAuB;iBAJvC,iCAAiC;4CAFN,oDAAoD;sBAJ1E,oCAAoC;0BAKhC,oCAAoC"}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { System } from "../System.js";
|
|
2
|
-
import { TooltipComponent } from "./TooltipComponent.js";
|
|
3
|
-
import Vector3 from "../../../core/geom/Vector3.js";
|
|
4
|
-
import { MeshSystem } from "../../graphics/ecs/mesh/MeshSystem.js";
|
|
5
|
-
import { SurfacePoint3 } from "../../../core/geom/3d/SurfacePoint3.js";
|
|
6
|
-
import { VisualTip } from "../../../view/tooltip/VisualTip.js";
|
|
7
1
|
import Rectangle from "../../../core/geom/2d/Rectangle.js";
|
|
8
|
-
import {
|
|
9
|
-
import
|
|
2
|
+
import { SurfacePoint3 } from "../../../core/geom/3d/SurfacePoint3.js";
|
|
3
|
+
import Vector3 from "../../../core/geom/Vector3.js";
|
|
10
4
|
import { ResourceAccessKind } from "../../../core/model/ResourceAccessKind.js";
|
|
5
|
+
import { ResourceAccessSpecification } from "../../../core/model/ResourceAccessSpecification.js";
|
|
6
|
+
import { VisualTip } from "../../../view/tooltip/VisualTip.js";
|
|
11
7
|
import Mesh from "../../graphics/ecs/mesh/Mesh.js";
|
|
8
|
+
import { MeshSystem } from "../../graphics/ecs/mesh/MeshSystem.js";
|
|
9
|
+
import { modelHitTest } from "../../graphics/util/modelHitTest.js";
|
|
10
|
+
import { System } from "../System.js";
|
|
11
|
+
import { TooltipComponent } from "./TooltipComponent.js";
|
|
12
12
|
|
|
13
13
|
const ray_source = new Vector3();
|
|
14
14
|
const ray_direction = new Vector3();
|
|
@@ -170,18 +170,16 @@ export class TooltipComponentSystem extends System {
|
|
|
170
170
|
return hit_entity;
|
|
171
171
|
}
|
|
172
172
|
|
|
173
|
-
startup(entityManager
|
|
173
|
+
async startup(entityManager) {
|
|
174
174
|
|
|
175
175
|
this.pointer.position.onChanged.add(this.__updateActiveBounds, this);
|
|
176
176
|
|
|
177
|
-
super.startup(entityManager, readyCallback, errorCallback);
|
|
178
177
|
}
|
|
179
178
|
|
|
180
|
-
shutdown(entityManager
|
|
179
|
+
async shutdown(entityManager) {
|
|
181
180
|
|
|
182
181
|
this.pointer.position.onChanged.remove(this.__updateActiveBounds, this);
|
|
183
182
|
|
|
184
|
-
super.shutdown(entityManager, readyCallback, errorCallback);
|
|
185
183
|
}
|
|
186
184
|
|
|
187
185
|
update(timeDelta) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validateSystem.d.ts","sourceRoot":"","sources":["../../../../src/engine/ecs/validateSystem.js"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,
|
|
1
|
+
{"version":3,"file":"validateSystem.d.ts","sourceRoot":"","sources":["../../../../src/engine/ecs/validateSystem.js"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,8EA0FC;uBAjGsB,aAAa"}
|
|
@@ -11,7 +11,7 @@ export function validateSystem(system) {
|
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
if (system === null) {
|
|
14
|
-
throw
|
|
14
|
+
throw new Error("System is null");
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
if (!(system instanceof System)) {
|
|
@@ -61,7 +61,7 @@ export function validateSystem(system) {
|
|
|
61
61
|
const numDependencies = dependencies.length;
|
|
62
62
|
|
|
63
63
|
if (numDependencies < 1) {
|
|
64
|
-
throw
|
|
64
|
+
throw new Error(`A system must declare at least one dependency`);
|
|
65
65
|
}
|
|
66
66
|
|
|
67
67
|
if (numDependencies > 1) {
|
|
@@ -76,6 +76,15 @@ export function validateSystem(system) {
|
|
|
76
76
|
}
|
|
77
77
|
}
|
|
78
78
|
|
|
79
|
+
// deprecation check
|
|
80
|
+
if(system.startup !== System.prototype.startup && system.startup.length > 1) {
|
|
81
|
+
throw new Error(`'startup' method declares ${system.startup.length} arguments, callbacks have been deprecated in meep 2.128.0, use promises instead`);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
// deprecation check
|
|
85
|
+
if(system.shutdown !== System.prototype.shutdown && system.shutdown.length > 1) {
|
|
86
|
+
throw new Error(`'shutdown' method declares ${system.shutdown.length} arguments, callbacks have been deprecated in meep 2.128.0, use promises instead`);
|
|
87
|
+
}
|
|
79
88
|
|
|
80
89
|
const linkArgumentCount = numDependencies + 1;
|
|
81
90
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CameraSystem.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/graphics/ecs/camera/CameraSystem.js"],"names":[],"mappings":"AAoBA;;;;GAIG;AACH,4DAHW,YAAY,YACZ,UAAU,QAsBpB;AAED;
|
|
1
|
+
{"version":3,"file":"CameraSystem.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/graphics/ecs/camera/CameraSystem.js"],"names":[],"mappings":"AAoBA;;;;GAIG;AACH,4DAHW,YAAY,YACZ,UAAU,QAsBpB;AAED;IAgOI;;;;OAIG;IACH,8EAOC;IAED;;;;OAIG;IACH,0DAFa;QAAC,SAAS,EAAC,CAAC,MAAM,GAAC,SAAS,CAAC,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAC,CAc1D;IAED;;;;OAIG;IACH,uEAFoB,YAAY,EAAE,gBAqBjC;IAxRD;;;;OAIG;IACH,sCAuDC;IAhDG,WAA2B;IAE3B,mDAAuC;IAEvC,8DAEC;IAQD;;OAEG;IACH,yBAAwB;IAExB,kBAAoB;IAKpB;;;;;OAKG;IACH,+BAeC;IAED,sBAAwB;IAI5B;;;;;OAKG;IACH,aAHW,MAAM,aADN,SAAS,uBAyEnB;IAED;;;;;OAKG;IACH,eAHW,MAAM,aADN,SAAS,uBAiBnB;IAED,2CAoDC;IAED,4CAMC;CA4DJ;uBA9TsB,aAAa;uBARb,qCAAqC;uBAGrC,wBAAwB;0BACrB,qCAAqC;4CAFnB,uDAAuD;wCAL1D,OAAO"}
|
|
@@ -54,9 +54,9 @@ export class CameraSystem extends System {
|
|
|
54
54
|
constructor(graphics) {
|
|
55
55
|
super();
|
|
56
56
|
|
|
57
|
-
assert.defined(graphics,'graphics');
|
|
58
|
-
assert.notNull(graphics,'graphics');
|
|
59
|
-
assert.equal(graphics.isGraphicsEngine, true,'graphics.isGraphicsEngine !== true');
|
|
57
|
+
assert.defined(graphics, 'graphics');
|
|
58
|
+
assert.notNull(graphics, 'graphics');
|
|
59
|
+
assert.equal(graphics.isGraphicsEngine, true, 'graphics.isGraphicsEngine !== true');
|
|
60
60
|
|
|
61
61
|
this.scene = graphics.scene;
|
|
62
62
|
|
|
@@ -207,7 +207,7 @@ export class CameraSystem extends System {
|
|
|
207
207
|
this.scene.remove(camera.object);
|
|
208
208
|
}
|
|
209
209
|
|
|
210
|
-
startup(entityManager
|
|
210
|
+
async startup(entityManager) {
|
|
211
211
|
this.entityManager = entityManager;
|
|
212
212
|
|
|
213
213
|
const graphics = this.graphics;
|
|
@@ -259,17 +259,14 @@ export class CameraSystem extends System {
|
|
|
259
259
|
|
|
260
260
|
this.signalBindings.push(visibilityConstructionPreHook);
|
|
261
261
|
|
|
262
|
-
readyCallback();
|
|
263
262
|
}
|
|
264
263
|
|
|
265
|
-
shutdown(entityManager
|
|
264
|
+
async shutdown(entityManager) {
|
|
266
265
|
this.graphics.viewport.size.onChanged.remove(this.__handleViewportResize);
|
|
267
266
|
|
|
268
267
|
this.signalBindings.forEach(sb => sb.unlink());
|
|
269
268
|
|
|
270
269
|
this.signalBindings.splice(0, this.signalBindings.length);
|
|
271
|
-
|
|
272
|
-
readyCallback();
|
|
273
270
|
}
|
|
274
271
|
|
|
275
272
|
/**
|