@galacean/effects-core 2.1.4 → 2.1.5-alpha.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/dist/index.js +11 -4
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +11 -4
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Description: Galacean Effects runtime core for the web
|
|
4
4
|
* Author: Ant Group CO., Ltd.
|
|
5
5
|
* Contributors: 燃然,飂兮,十弦,云垣,茂安,意绮
|
|
6
|
-
* Version: v2.1.
|
|
6
|
+
* Version: v2.1.5-alpha.0
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
'use strict';
|
|
@@ -16582,10 +16582,17 @@ exports.InteractComponent = /*#__PURE__*/ function(RendererComponent) {
|
|
|
16582
16582
|
];
|
|
16583
16583
|
};
|
|
16584
16584
|
_proto.onStart = function onStart() {
|
|
16585
|
+
var _this = this;
|
|
16586
|
+
var _this_item_composition;
|
|
16585
16587
|
var options = this.item.props.content.options;
|
|
16586
16588
|
var env = this.item.engine.renderer.env;
|
|
16587
16589
|
var composition = this.item.composition;
|
|
16588
16590
|
var _this_interactData_options = this.interactData.options, type = _this_interactData_options.type, showPreview = _this_interactData_options.showPreview;
|
|
16591
|
+
(_this_item_composition = this.item.composition) == null ? void 0 : _this_item_composition.on("goto", function() {
|
|
16592
|
+
if (_this.item.time > 0) {
|
|
16593
|
+
_this.duringPlay = true;
|
|
16594
|
+
}
|
|
16595
|
+
});
|
|
16589
16596
|
if (type === InteractType.CLICK) {
|
|
16590
16597
|
this.clickable = true;
|
|
16591
16598
|
if (showPreview && env === PLAYER_OPTIONS_ENV_EDITOR) {
|
|
@@ -16626,12 +16633,12 @@ exports.InteractComponent = /*#__PURE__*/ function(RendererComponent) {
|
|
|
16626
16633
|
};
|
|
16627
16634
|
_proto.onUpdate = function onUpdate(dt) {
|
|
16628
16635
|
var _this_previewContent;
|
|
16629
|
-
this.duringPlay = true;
|
|
16630
16636
|
// trigger messageBegin when item enter
|
|
16631
|
-
if (this.item.time > 0 && this.
|
|
16637
|
+
if (this.item.time > 0 && !this.duringPlay) {
|
|
16632
16638
|
var _this_item_composition;
|
|
16633
16639
|
var options = this.item.props.content.options;
|
|
16634
16640
|
(_this_item_composition = this.item.composition) == null ? void 0 : _this_item_composition.addInteractiveItem(this.item, options.type);
|
|
16641
|
+
this.duringPlay = true;
|
|
16635
16642
|
}
|
|
16636
16643
|
(_this_previewContent = this.previewContent) == null ? void 0 : _this_previewContent.updateMesh();
|
|
16637
16644
|
if (!this.dragEvent || !this.bouncingArg) {
|
|
@@ -31385,7 +31392,7 @@ registerPlugin("sprite", SpriteLoader, exports.VFXItem, true);
|
|
|
31385
31392
|
registerPlugin("particle", ParticleLoader, exports.VFXItem, true);
|
|
31386
31393
|
registerPlugin("cal", CalculateLoader, exports.VFXItem, true);
|
|
31387
31394
|
registerPlugin("interact", InteractLoader, exports.VFXItem, true);
|
|
31388
|
-
var version = "2.1.
|
|
31395
|
+
var version = "2.1.5-alpha.0";
|
|
31389
31396
|
logger.info("Core version: " + version + ".");
|
|
31390
31397
|
|
|
31391
31398
|
exports.AbstractPlugin = AbstractPlugin;
|