@woosh/meep-engine 2.46.24 → 2.46.26
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/meep.cjs +17 -8
- package/build/meep.min.js +1 -1
- package/build/meep.module.js +17 -8
- package/package.json +1 -1
- package/src/core/model/node-graph/visual/NodeGraphVisualData.js +3 -3
- package/src/engine/graphics/ecs/light/shadow/LightShadow.js +4 -0
- package/src/engine/graphics/render/forward_plus/LightManager.js +1 -1
- package/src/engine/intelligence/behavior/primitive/ActionBehavior.js +16 -7
- package/src/engine/intelligence/behavior/util/BranchBehavior.js +97 -0
package/build/meep.cjs
CHANGED
|
@@ -99863,25 +99863,34 @@ class RepeatBehavior extends AbstractDecoratorBehavior {
|
|
|
99863
99863
|
|
|
99864
99864
|
RepeatBehavior.typeName = "RepeatBehavior";
|
|
99865
99865
|
|
|
99866
|
+
/**
|
|
99867
|
+
* @template CTX
|
|
99868
|
+
* @extends {Behavior<CTX>}
|
|
99869
|
+
*/
|
|
99866
99870
|
class ActionBehavior extends Behavior {
|
|
99867
99871
|
/**
|
|
99868
99872
|
*
|
|
99869
|
-
* @param {function(timeDelta:number)}
|
|
99870
|
-
* @param {*} [
|
|
99873
|
+
* @param {function(timeDelta:number, context:CTX)} func
|
|
99874
|
+
* @param {*} [thisArg] defaults to behavior itself if not specified
|
|
99871
99875
|
*/
|
|
99872
|
-
constructor(
|
|
99876
|
+
constructor(func, thisArg) {
|
|
99873
99877
|
super();
|
|
99874
99878
|
|
|
99875
|
-
assert.typeOf(
|
|
99879
|
+
assert.typeOf(func, 'function', "action");
|
|
99876
99880
|
|
|
99877
|
-
this.__action =
|
|
99878
|
-
|
|
99881
|
+
this.__action = func;
|
|
99882
|
+
|
|
99883
|
+
if (thisArg === undefined) {
|
|
99884
|
+
this.__context = this;
|
|
99885
|
+
} else {
|
|
99886
|
+
this.__context = thisArg;
|
|
99887
|
+
}
|
|
99879
99888
|
}
|
|
99880
99889
|
|
|
99881
99890
|
tick(timeDelta) {
|
|
99882
99891
|
|
|
99883
99892
|
try {
|
|
99884
|
-
this.__action.call(this.__context, timeDelta);
|
|
99893
|
+
this.__action.call(this.__context, timeDelta, this.context);
|
|
99885
99894
|
|
|
99886
99895
|
return BehaviorStatus.Succeeded;
|
|
99887
99896
|
|
|
@@ -120311,7 +120320,7 @@ class LightManager {
|
|
|
120311
120320
|
*/
|
|
120312
120321
|
this.__visible_bvh_needs_update = true;
|
|
120313
120322
|
|
|
120314
|
-
window.light_manager = this; // DEBUG
|
|
120323
|
+
// window.light_manager = this; // DEBUG
|
|
120315
120324
|
}
|
|
120316
120325
|
|
|
120317
120326
|
/**
|