!function(){"use strict";var t=ht.Default,R=(t.clone,t.isArray,t.isObject);t.isFunction,t.stringify,t.getShape3dModelFromMemory,new ht.Notifier;function m(t){return/\.json$/i.test(t)}function B(t){return"string"==typeof t}function e(t,e,i){for(var a,l,g,o,r,n="",m=i||0;m>4,l=(15&g)<<4|(o=e.indexOf(t.charAt(m++)))>>2,g=(3&o)<<6|(r=e.indexOf(t.charAt(m++))),n+=String.fromCharCode(a),64!=o&&(n+=String.fromCharCode(l)),64!=r&&(n+=String.fromCharCode(g));return n=decodeURIComponent(escape(n))}i=document.createElement("canvas"),a=document.createElement("canvas"),l=void 0;var i,a,l,j="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},s=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")},g=function(t,e,i){return e&&o(t.prototype,e),i&&o(t,i),t};function o(t,e){for(var i=0;i=33306690738754716e-32*r?n:-h(t,e,i,a,l,g,r)}g(u,null,[{key:"from",value:function(t,e,i){for(var a=1>1,o=1/0,r=1/0,n=-1/0,m=-1/0,s=0;s>1;if(0o;)t[r+1]=t[r--];t[r+1]=g}else{var n=i+1,m=a;P(t,i+a>>1,n),e[t[i]]>e[t[a]]&&P(t,i,a),e[t[n]]>e[t[a]]&&P(t,n,a),e[t[i]]>e[t[n]]&&P(t,i,n);for(var s=t[n],X=e[s];;){for(;e[t[++n]]X;);if(m "+x+". 简化掉点数: "+(h-x),this._simplifyStartSegments=o.s}}},{key:"_updateMatTransparent",value:function(t){this._anchorMat1.transparent=t,this._anchorMat2.transparent=t,this._anchorMat10.transparent=t,this._anchorMat20.transparent=t,this._anchorMat3.transparent=t,this._anchorMat4.transparent=t}},{key:"_updateNodeDrivenData",value:function(){function t(t,e){var i,a=!1;return e&&(i=g.getDataByTag(e))?(a=l[t]!==i,l[t]=i):(a=!!l[t],delete l[t]),a}var l=this,e=this.data,g=this.gv.dm();t("_drivenNode1",e.a("pathAnchorNode1"))&&!e.a("pathDrivenOffset1")&&(Qt(this._drivenNode1,"pathDrivenOffset1",e),delete this._anchorPoints1),t("_drivenNode2",e.a("pathAnchorNode2"))&&!e.a("pathDrivenOffset2")&&(Qt(this._drivenNode2,"pathDrivenOffset2",e),delete this._anchorPoints2)}},{key:"_initOffsetRatio",value:function(){for(var t=this.data,e=t.a("pathAnchorControlStart")||.3,i=t.a("pathAnchorControlWidth")||.3,a=this._pathDrivenRatio=[],l=t.getPoints().length,g=Math.floor(l*e),o=Math.floor(l*(i+e)),r=o-g,n=void 0,m=0;m=Math.PI&&(T=-T),r=M*o-f*T,n=f*o+M*T,v.push({x:a*r+u[0],e:u[1],y:a*n+u[2]})),0==V?p.push(1):p.push(2)}},{key:"getRopeLength",value:function(){var t=this.a("pathRopeLength");return t||this.getRopeDistance()+10}},{key:"getRopeDistance",value:function(){var t=this.getPoints();if(!t||t.length<2)return 0;var e=t.get(0),i=t.get(t.length-1),a=e.x-i.x,l=e.e-i.e,g=e.y-i.y;return Math.sqrt(a*a+l*l+g*g)}}]),ai);function ai(){s(this,ai);var t=n(this,(ai.__proto__||Object.getPrototypeOf(ai)).call(this));return t._myInit(),t}ii.getSplinePointsSegments=pe;var li=new ht.Math.Quaternion,gi=new ht.Math.Vector3,oi=new ht.Math.Vector3;var ri=(gl=ht.graph3d.Node3dUI,r(ni,gl),g(ni,[{key:"_updateLine",value:function(t,e,i){t.data.s("shape3d.side",e),t.data.s("shape3d.smooth",i),t.validate()}},{key:"_updateLineH",value:function(){var t=this.data.a("polylineSide")||4,e=this.data.a("polylineSmooth");void 0===e&&(e=!0),this._updateLine(this._polylineUi,t,e),this._meshH=this._updateModelMesh(this._polylineUi)}},{key:"_createLine",value:function(){var t=new ht.Polyline;return t.setPoints([{x:-.5,y:0,e:0},{x:.5,y:0,e:0}]),t.s({shape3d:"cylinder"}),t.setThickness(1),new ht.graph3d.Polyline3dUI(this.gv,t)}},{key:"_initMesh",value:function(){this._polylineUi=this._createLine(),this._polylineUiM=this._createLine(),this._polylineUiL=this._createLine(),this._updateLineH(),this._createLodModel()}},{key:"validate",value:function(t,e){ft(ni.prototype.__proto__||Object.getPrototypeOf(ni.prototype),"validate",this).call(this,t,e);var i=this.data,a=!!i.a("polylineUseBlend"),l=!!i.a("polylineUseUvOffset"),g=!!i.a("polylineUseSizes"),o=!!i.a("polylineDynamicScale"),r=!1;if(i._polylineExtDirty){if(delete this.polylineExtModel,!i.a("polylinePoints")&&!i._batchedPolyline)return void(i._polylineExtDirty=!1);i._batchedPolyline&&(group=i._batchedPolyline[0].a("batchPolylineGroup"));t=i.a("polylinePoints")||[];this._vsTranslation=this._polylineMatrix=this._polylineDummyData=null,this.labelPickColorMap=[],this._labelMaps=[],this._labelDirty=[],this._polylinePositions=[];var n=void 0,m=void 0,s=void 0,e=i.getCompCount();a&&(m=function(t,e){var i=[],a=void 0,l=void 0;{if(!t){for(var g=0;gthis._lodCullingDistance)continue}-1==g&&(g=(o=a[0]-l[u][0])*o+(r=a[1]-l[u][1])*r+(n=a[2]-l[u][2])*n),this._lodInvisibleDistance&&g>this._lodInvisibleDistance||(g>this._lodDistance2&&this._lodModel2?(D.push(u),d+=this._lodInstances[u].length):g>this._lodDistance1&&this._lodModel1?(X.push(u),x+=this._lodInstances[u].length):(s.push(u),h+=this._lodInstances[u].length))}for(var P=new Float32Array(h),v=new Float32Array(x),p=new Float32Array(d),t=s.length,c=0,y=0;ythis._lodCullingDistance)continue}-1==o&&(o=(r=l[0]-g[D][0])*r+(n=l[1]-g[D][1])*n+(m=l[2]-g[D][2])*m),this._lodInvisibleDistance&&o>this._lodInvisibleDistance||(this._lodDistance2&&o>this._lodDistance2?X.mesh=this._meshL:this._lodDistance1&&o>this._lodDistance1?X.mesh=this._meshM:X.mesh=this._meshH,X.instances=this._lodInstances[D],this.gv._prefabRenderer.render(t,X,this.data))}}}},{key:"_updateVsDirty",value:function(t){var e,i=this.data,a=this._polylineModel,l=i.a("polylinePoints"),g=i.a("polylineDynamicScale"),o=a.instances.aMatrixInstanced,r=a.instances.aDynamicScale;for(e in t){var n=parseInt(e);this._getLineMatrix(l,n,o,r,g)}}},{key:"_updateSizeDirty",value:function(t){var e,i=this.data,a=this._polylineModel,l=i.a("polylineThicknesses"),g=a.instances.aThickness;for(e in t){var o=parseInt(e);g.set([l[o]],o)}}},{key:"_updateBlendDirty",value:function(t){var e,i=this.data,a=this._polylineModel,l=i.a("polylineBlendColors"),g=a.instances.aPolylineColor;for(e in t){var o=parseInt(e),r=mi(l[o]);g.set(r,4*o)}}},{key:"_updateUvOffsetDirty",value:function(t){var e,i=this.data,a=this._polylineModel,l=i.a("polylineUvOffset"),g=a.instances.aUvOffset;for(e in t){var o=parseInt(e);g.set([l[o]],o)}}},{key:"_buildFromBatch",value:function(t,e,i,a){var l=this.data;if(l._batchedPolyline){var g=l._batchedPolyline.length;t.length=0;for(var o=e.length=0;or[m]&&(r[m]=e[m])}for(var s=[],X=[0,0,0],D=0;D<3;D++)X[D]=(r[D]-o[D])/l[D],0===X[D]&&(X[D]=1);for(var h=l[0]*l[1]*l[2],x=[],d=0;dT[M]&&(c[M]=T[M]),y[M]=n[0]&&o=r[0]&&g=n[0]&&o=n[0]&&o=m[0]&&r=o){if(h.push({type:"text",text:P,font:e,rect:[0,c*i.height,p.width,i.height]}),p.width>f&&(f=p.width),P="",(++c+1)*i.height>=r){y++;break}y!==v-1&&x.push(0,c*i.height)}else y!==v-1&&(P+=" ",p=ht.Default.getTextSize(e,P),x.push(p.width,c*i.height),P+=" ");g=y,P&&(c++,p.width>f&&(f=p.width),h.push({type:"text",text:P,font:e,rect:[0,(c-1)*i.height,p.width,i.height]})),X.width=f,X.height=c*i.height,v=x.length/2;for(var V=0;V=e&&t[l-1]<=e)return l;t[l]=this._totalTicks)&&(n=1,this._currentLoopTimes++,a?(this._currentPercent=1,this._currentTicks=this._totalTicks,this._animForward=!1):(this._currentPercent=-this._animStep,this._currentTicks=-1,this._animForward=!0)),this._moveNode(n,l&&!this._animForward,this._currentTicks*ca),0=i&&(this._currentLoopTimes=0,this._stopAnimation(),(i=e.getHistoryManager())&&e.disableHistoryManager(),t.a("animStart",!1),this._handleOnOp("Stop"),i&&e.enableHistoryManager())}},{key:"_updatePath",value:function(t,e,i){var a=this.data,l=void 0;i||(l=t+"Cache");i=this.gv;if(!this[t]||a._updatedProperty["a:"+e]){e=a.a(e);if(R(e)?this[t]=this._polylineAux:e?this[t]=i.dm().getDataByTag(e):delete this[t],l&&this[t]){var a=a.a("animPathResolution")||32,g=this[l]=this._getLineCache(this[t],a),a=this[t];if(!a.p3)return;var o=a.getScale3d(),r=new ht.Math.Matrix4,n=a.getQuaternion();r.composeFromArray([0,0,0],n.toArray(),o);var m=g.length,t=a.getRotation3d(),s=a.p3(),a=!1,X=!1,D=!1;if(1e-4y[1]&&(y[1]=h[Y]),h[Y]=(P=this._getHeadingTimeInfo())[x]-P[x-1]&&(u=P[x]-P[x-1]-.5),P[x]>M&&P[x]-u<=M?(n=v[x-1])!==(m=v[x])?(c=(M-P[x]+u)/u,r=y[x],c=c<.5?c*c*2:1-2*(h=1-c)*h):o=n:o=v[x-1]):o=v[x-1]):o=a.a("animLookAt")||wt,(s=g.getHistoryManager())&&g.disableHistoryManager(),X=a.a("animIsGis"),(D=this._getLineOffset("_pathNode",Y,T,X))&&(t=void 0,e=this._animNode,i=a.a("animNoise"),d=D.pos,M=void 0,P=this._quaternion2,u=this._quaternion3,y=a.a("animNStrength")||0,h=[0,0,0],this._randomR3Flag&&(M=this._euler),i&&y&&this._randomFlag&&this._getRandom(d,h,M),e.p3(d),i=x=v=void 0,o?v=this._getLookAtPos(o):(x=this._getLookAtPos(n),i=this._getLookAtPos(m),x&&i&&(v=[x[0]+(i[0]-x[0])*c,x[1]+(i[1]-x[1])*c,x[2]+(i[2]-x[2])*c])),d=y=void 0,y=a.a("animUpControl"),"fixedUp"===Ya(a,"animUpControlMode","dynamicUp")?this._setFixedUp(e,X,D.tangent):(y&&a.a("animUpRotate")&&(d=this._getPercentAngle(Y),T&&(d=-d),P.setFromAxisAngle(D.tangent,d),D.quaternion.premultiply(P),p&&(t=t||this._getLineOffset("_pathNode",r,T,X),d=this._getPercentAngle(r),T&&(d=-d),u.setFromAxisAngle(t.tangent,d),t.quaternion.premultiply(u))),M&&(P.setFromEuler(M),D.quaternion.multiply(P)),e.setQuaternion(D.quaternion)),p&&(y=!1,d=Y=void 0,o?"lookAtTangent"!==o&&"lookAtDir"!==o&&(y=!0):("lookAtTangent"!==n&&"lookAtDir"!==n&&(Y=D.normal),"lookAtTangent"!==m&&"lookAtDir"!==m&&(d=(t=t||this._getLineOffset("_pathNode",r,T,X)).normal)),u=a.a("animEyePos")||[0,0,0],M=e.getAnchor3d(),u=function(t,e){var i=2p._switchResolutionDis?p._renderFullResolution=!0:(T=v.getStyleMap(),t._45Q=!!T["shape3d.transparent"],delete p._renderFullResolution,p.needValidate(a)&&(p.validate(),p._iv=!1),p.drawBody(a),t._gParticleDataReady=!0)))}l.unbind(a),D&&t.setViewport(a,D[0],D[1],D[2],D[3]);t._45Q=!1,Mg(t),t._45Q=e,h.blend.enabled=m,h.depth.mask=d,h.depth.enabled=x,u&&(h.color.clear=u);t._gParticlePathRendering=!1}(e,t)),e.isRenderSceneForBloom()&&e._gParticleDepth&&Mg(e))},e.addRenderLayerListener(t,e,e._depthGrabber.renderLayerPriority-100))}function Tg(t,e,i){var a=t.dm().getAttrObject();a[gg]||(a[gg]={});t=void 0,a=a[gg];return a&&(t=a[e]),null==t&&(t=i),t}function Mg(t){var e,i,a,l,g,o=pg(t);o&&0!==o.length&&(g=o[0].data,t.isRenderSceneForBloom()&&!g.s("bloom")||t._gParticleDataReady&&(i=Tg(e=t,"brightnessRatio",1),a=Tg(e,"adjustThreshold",0),l=Tg(e,"brightBlend",void 0),o=Tg(e,"blendRatio",1),g=e._gParticlePathMat,t=yg(e),g.type=jl,g.uImage=t.getUUID(),g.defines={PARTICLE_ADJUST_BRIGHTNESS:1!==i,PARTICLE_ADJUST_BRIGHTNESS_THRESHOLD:1!==i&&0i&&(e[0][0]=i),e[0][1]a&&(e[1][0]=a),e[1][1]c[1]&&(c[1]=Y),Y=a._animTicks&&(a._currentAnimTicks=a._currentAnimTicks-a._animTicks,a._playAnim(t,e))):a._playAnim(t,e))},ht.Default.registerHeartbeat(this._loop,20))}},{key:"_stopAnimation",value:function(){this._loopTimer&&(this._handleOnOp("Stop"),this._loopTimer=!1,ht.Default.unregisterHeartbeat(this._loop))}},{key:"_playAnim",value:function(t,e){e/=1e3;var i=this.data,a=i.a("particleSpaceMode"),l=(i.a("particleRenderMode"),i.a("particleSequenceFrame")),g=i.a("particleEventSequenceFrame"),o=i.a("particleEventTrigger")&&"OPEN_SPACE"===a,r=!0===i.a("particleMoveEmitOpt"),n=i.a("particleEmitterShape");if(this.data.a("particleTrail")&&"OPEN_SPACE"!==a)this._updateParticlePosCpu();else{this.gv.getGL().colorMask(!0,!0,!0,!0);var m=0,s=void 0,X=void 0,D=void 0,a=void 0,h=void 0;r&&"model3D"!==n&&(s=i.p3(),!this._lastEmitPos||(n=(X=s[0]-this._lastEmitPos[0])*X+(D=s[1]-this._lastEmitPos[1])*D+(a=s[2]-this._lastEmitPos[2])*a)>this._minCheckEmitDistance2&&(i=ig(i,"particleMinCheckEmitDistance",1),m=Math.floor(Math.sqrt(n/i))),h=this._lastEmitPos,this._lastEmitPos=s);s=this._fieldMat;if(1=this._sequenceFrameTicks2&&(this._sequenceCurrentTicks2=this._sequenceCurrentTicks2-this._sequenceFrameTicks2,this._sequenceFrameUv2=(this._sequenceFrameUv2+1)%this._sequenceFrameTotal2),t.uSequenceCurrentUv2=this._sequenceFrameUv2}},{key:"_updateSequenceFrame",value:function(){var t=this._particleMat;t.uSequenceCount=this._sequenceFrameCount,this._sequenceCurrentTicks++,this._sequenceCurrentTicks>=this._sequenceFrameTicks&&(this._sequenceCurrentTicks=this._sequenceCurrentTicks-this._sequenceFrameTicks,this._sequenceFrameUv=(this._sequenceFrameUv+1)%this._sequenceFrameTotal),t.uSequenceCurrentUv=this._sequenceFrameUv}},{key:"_updatePathData",value:function(){delete this._lineScaleRadius;var t=this.data,e=t.a("particleInterpolateTangent"),i=this.gv,a=i.dm(),l=t.a("particlePath");if(!l)return!1;var g=a.getDataByTag(l);if(g&&(g instanceof ht.Polyline||g instanceof ht.Edge)){this._lineNode=g;var o=void 0,r=!1;ht.plugin&&ht.plugin.Path&&g instanceof ht.plugin.Path&&(r=!0),r&&(o=g._isPathInvalidating,g._isPathInvalidating=!0);var n=void 0,m=void 0,s=void 0;if(this._lineP3=this.data.p3(),g instanceof ht.Edge){a=g.getSource(),l=g.getTarget();if(!a||!l)return;i=i.getData3dUI(g);if(g.s("3d.visible")&&i.info&&i.info._lastPointsSegments||i.validate(),!i.info||!i.info._lastPointsSegments)return;n=ht.Default.clone(i.info._lastPointsSegments.points),m=i.info._lastPointsSegments.segments,s=g.s("edge.width");a=a.p3(),l=l.p3();this._lineP3=[(a[0]+l[0])/2,(a[1]+l[1])/2,(a[2]+l[2])/2]}else n=ht.Default.clone(g.getPoints()),m=g.getSegments(),s=g.getThickness(),this._lineP3=g.p3();if(ht.Default.extractVerticesTranslation)for(var X=n.length,D=0;Dl[m][0]&&nl[g-1][0]&&(a=l[g-1][1])}return a}},{key:"_updateWaterInfo",value:function(t,e,i){var a=t.a("particleMoveOnWater"),l=t.a("particleWaterTag");if(i.defines.PARTICLE_MOVE_ON_WATER=!1,a&&l){a=e.dm(),e=a.getDataByTag(l);if(e){l=e.a("waterWave");if(!l)return!1;a=a.getDataByTag(l);a&&a._displaceRenderTarget&&(i.uWave=a._displaceRenderTarget.getUUID(),l=[0,0,0],ht.Default.extractVerticesTranslation&&(l="OPEN_SPACE"!==t.a("particleSpaceMode")&&this._lineNode?this._lineP3:t._particleRefP3),i.uParticleTranslation=l,i.uWaterPos=e.p3(),i.uWaterQuaternionInverse=e.getQuaternion().inverse().toArray(),(a=this._v3).fromArray([0,1,0]),a.applyQuaternion(e.getQuaternion()),i.uWaterNormal=a.toArray(),t=[1,1],e.a("waterLod")&&(t=e.a("waterSplitMatrix")||Sl),l=e.getFinalScale3d(),l=[(a=1/e._waveSize)*l[0]/t[0],e.a("waterWaveScale")*a*l[1]/t[0],a*l[2]/t[0]],i.uWaterScale=l,i.uWaterTranslate=e.a("waterTranslate")||[0,0],i.uWaterRepeat=t,i.uWaterS3=e.getFinalScale3d(),i.defines.PARTICLE_MOVE_ON_WATER=!0)}}}},{key:"_updateParticlePos",value:function(t,e){var i=this.data,a=this.gv,l=i.a("particleSpaceMode"),g=this._fieldMat;if("OPEN_SPACE"!==l)g.uSpeed=[this._particleSpeedStrength/(this._lineLength||1),this._particleRotateSpeed,this._particleRadiusSpeed],g.uLineInfo=this._lineInfoTexture,g.uParticlePos=this._rd0.texture,g.uParticlePosOld=this._rd1.texture,g.defines.USE_SEG_INFO=!!this._segCache&&1=m&&(this._isDelaying||this._currentLoopTime++,s=!0,this._currentTicks=0),0==r?0=n&&(this._delayTicks=0,o=!(this._isDelaying=!1))):s?(this._isDelaying=!0,this._delayTicks=0):o=!0:o=!0:this._currentLoopTime<=r&&(0=n&&(this._delayTicks=0,o=!(this._isDelaying=!1))):s?(this._isDelaying=!0,this._delayTicks=0):o=!0:o=!0);var X=[0,0,0];ht.Default.extractVerticesTranslation&&(X=i._particleRefP3);var D,h="model3D"===i.a("particleEmitterShape");if(g.uEmitFlag=0,o)if(this._model3dEmitterDataVersion++,g.uEmitFlag=1,h){this._emitterNode&&this._emitterNodeModel3d&&(this._refreshEmitterModel3d&&(this._updateEmitterNode(),this._refreshEmitterModel3d=!1),this._emitterUvRangeInvalid&&this._updateEmitterNodeUvRange(),l=ig(i,"particleEmitterUvSelect","UV2"),m=!0===i.a("particleEmitterGray"),r=void 0,r="UV2"===l?this._emitterUv2Range:this._emitterUvRange,c=this._emitterNodeModel3d.matDef,v=!1,t=i.a("particleEmitterDissolve"),n=i.a("particleEmitterMap"),s=ig(i,"particleEmitThreshold",.5),y=void(p=o=0),t&&(t=this._emitterNode.a("dissolveMap"),o=this._emitterNode.a("dissolveThreshold")||0,p=this._emitterNode.a("dissolveEdge")||0,D=!!this._emitterNode.a("dissolveGray"),y=this._emitterNode.a("dissolveMode")||"dir",t&&(n=t),s=o,v=!0,m=D),o="surface"===i.a("particleSpeedDir"),this._emitterNodeModel3d.mat&&(this._emitterNodeModel3d.mat.uParticleTranslation=X,this._emitterNodeModel3d.mat.uEmitThreshold=s,n&&(this._emitterNodeModel3d.mat.uEmitMap=n),this._emitterNodeModel3d.mat.defines={PARTICLE_EMIT_MAP_UV2:"UV2"===l,PARTICLE_DIR_NORMAL:o,PARTICLE_PATH_EMITTER_GRAY:m,PARTICLE_PATH_DISSOLVE:v},this._emitterNodeModel3d.mat.defines.PARTICLE_PATH_DISSOLVE_DIR=v&&"dir"===y,this._emitterNodeModel3d.mat.defines.PARTICLE_PATH_DISSOLVE_TEXTURE=!v||"texture"===y,this._emitterNodeModel3d.mat.defines.PARTICLE_PATH_DISSOLVE_SPHERE=v&&"sphereRadial"===y,this._emitterNodeModel3d.mat.defines.PARTICLE_PATH_DISSOLVE_CYLINDER=v&&"cylinderRadial"===y,v&&(this._emitterNodeModel3d.mat.uDissolveThreshold=p),D=void 0,"texture"!==y&&(D=a.getData3dUI(this._emitterNode)),D&&D._dissolveRange&&(this._emitterNodeModel3d.mat.uDissolveRadialDir=D._dissolveRadialDir,this._emitterNodeModel3d.mat.uDissolveDir=D._dissolveDir,this._emitterNodeModel3d.mat.uDissolveCenter=D._dissolveRange[0],this._emitterNodeModel3d.mat.uDissolveRange=D._dissolveRange[1]),this._emitterNodeModel3d.mat.uvMin=[r[0][0],r[1][0]],this._emitterNodeModel3d.mat.uvMax=[r[0][1],r[1][1]]),c&&(u=[X,s,!(d=["uParticleTranslation","uEmitThreshold","transparent"])],P=["UV2"===l,o,m,v,v&&"dir"===y,!v||"texture"===y,v&&"sphereRadial"===y,v&&"cylinderRadial"===y],n&&(d.push("uEmitMap"),u.push(n)),d.push("uvMin"),u.push([r[0][0],r[1][0]]),d.push("uvMax"),u.push([r[0][1],r[1][1]]),d.push("myFlag"),u.push(!0),v&&(d.push("uDissolveThreshold"),u.push(p),Y=void 0,"texture"!==y&&(Y=a.getData3dUI(this._emitterNode)),Y&&Y._dissolveRange&&(d.push("uDissolveDir"),u.push(Y._dissolveDir),d.push("uDissolveCenter"),u.push(Y._dissolveRange[0]),d.push("uDissolveRange"),u.push(Y._dissolveRange[1]),d.push("uDissolveRadialDir"),u.push(Y._dissolveRadialDir))),Zg(c,d,u),_g(c,["PARTICLE_EMIT_MAP_UV2","PARTICLE_DIR_NORMAL","PARTICLE_PATH_EMITTER_GRAY","PARTICLE_PATH_DISSOLVE","PARTICLE_PATH_DISSOLVE_DIR","PARTICLE_PATH_DISSOLVE_TEXTURE","PARTICLE_PATH_DISSOLVE_SPHERE","PARTICLE_PATH_DISSOLVE_CYLINDER"],P)),p={x:.5-(v=this._emitterNode.getAnchor3d()).x,y:.5-v.y,z:.5-v.z},Y=y=void 0,c&&(Y=(y=this._emitterNode.getStyleMap()).matDef,y.matDef=c),this.gv.renderModel(this._emitterModelRd,this._emitterNodeModel3d,{clear:!0,data:this._emitterNode,matrix:this._emitterNode.getMatrix4().translate(p).toArray()}),c&&(y.matDef=Y),g.uEmitModelPos=this._emitterModelRd.getTexture(0),g.uModel3dNormalDir=this._emitterModelRd.getTexture(1))}else{if(!this._birthModel)return;var x=this._birthModel.mat;x.uParticleRes=this._particleRes,x.uParticlePos=this._rd0.getTexture(0),x.uBirthRate=this._getBirthRate(),this.gv.renderModel(this._birthRd,this._birthModel,{clear:!0})}else this._lastModel3dEmitterDataVersion!==this._model3dEmitterDataVersion&&(this._lastModel3dEmitterDataVersion=this._model3dEmitterDataVersion,h?this._emitterModelRd&&this._emitterModelRd.updateTextureData(this._model3dEmitterData):this._birthRd&&this._birthRd.updateTextureData(this._particleBirthState));var d=i.a("particleSwirl")||0,u=i.a("particleSwirlRandom"),P=i.a("particleSwirlMin")||0,v=i.a("particleSwirlKeep"),p=ig(i,"particleSwirlMode","swirlSpread"),c=i.a("particleSwirlAxisFixed"),y=i.a("particleSwirlRadiusSpeed")||0,Y="randomSelect"===i.a("particleMonitorTarget"),x=i.a("particleEmitterShape")||Hl,h=i.a("particleEmitterClipMap");this._updateWaterInfo(i,a,g),g.defines.PARTICLE_SWIRL=0!==d,0!==d&&(u||(P=0),g.uSwirlStrength=d,g.uSwirlStrengthMin=P),g.defines.PARTICLE_SWIRL_KEEP=!0===v,g.defines.PARTICLE_SWIRL_KEEP_MODE0="swirlSpread"===p,g.defines.PARTICLE_SWIRL_AXIS_MOVE=!0!==c,g.defines.PARTICLE_SWIRL_KEEP&&(d=ig(i,"particleSwirlLSpeed",0),P=ig(i,"particleSwirlASpeed",1),v=ig(i,"particleSwirlKeepRandom",!1),p=ig(i,"particleSwirlLSpeedMin",0),c=ig(i,"particleSwirlASpeedMin",0),g.uSwirlSpeed=[d*this._deltaTime,.017453292519943295*P*this._deltaTime],g.uSwirlSpeedMin=[p*this._deltaTime,.017453292519943295*c*this._deltaTime],g.uParticleInitSpeed=this._rd0.getTexture(3),g.uSwirlRadiusSpeed=y,g.defines.PARTICLE_SWIRL_INWARD=0!==y,g.defines.PARTICLE_SWIRL_RANDOM=v),g.defines.PARTICLE_EMITTER_CLIP_NODE=!!this._clipNode,g.defines.PARTICLE_EMITTER_CLIP_NODE&&(g.uClipReverseMatrix=this._clipNodeRevertMatrix,T=this._clipNode.s("shape3d"),M=i.a("particleEmitterClipMode"),g.defines.PARTICLE_EMITTER_CLIP_BOX="box"===T,g.defines.PARTICLE_EMITTER_CLIP_IN="keepOutside"!==M);var T="surface"===i.a("particleSpeedDir"),M="nodeUp"===i.a("particleSpeedDir");g.defines.BIRTH_SPHERE="sphere"===x,g.defines.BIRTH_PLANE="plane"===x,g.defines.BIRTH_PLANEV="vPlane"===x,g.defines.BIRTH_TORUS="torus"===x,g.defines.BIRTH_CONE="cone"===x,g.defines.BIRTH_CYLINDER="cylinder"===x,g.defines.BIRTH_MODEL3D="model3D"===x,g.defines.PARTICLE_DIR_NORMAL=g.defines.BIRTH_MODEL3D&&T,g.defines.SURFACE_DIR=g.defines.BIRTH_SPHERE&&T&&!M,g.defines.SURFACE_DIR2=g.defines.BIRTH_TORUS&&T&&!M,g.defines.SURFACE_CYLINDER=g.defines.BIRTH_CYLINDER&&T&&!M,g.defines.SURFACE_CONE=g.defines.BIRTH_CONE&&T&&!M,g.defines.PARTICLE_CLIP_MAP=!!h,h&&(g.uEmitterClipMap=h),g.defines.PARTICLE_EVENT_RANDOM=Y,g.uParticleRes=this._particleRes,g.uCollideThreshold=i.a("particleCollideThreshold")||50,g.uParticlePos=this._rd0.getTexture(0),g.uParticleBirthMap=this._birthRd.getTexture(),g.uParticleSpeed=this._rd0.getTexture(1),g.uParticleAlignment=this._rd0.getTexture(2),g.uParticleInitPos=this._rd0.getTexture(4),g.defines.BIRTH_TORUS&&(g.uTorusRadius=ig(i,"particleEmitterTorusRadius",.17));var f,V,U,z,Y=this._particleEmitMatrix;g.uP3=[Y[12]-X[0],Y[13]-X[1],Y[14]-X[2]],g.defines.PARTICLE_COLLIDER=!!this._colliderNode,g.defines.PARTICLE_COLLIDER&&(f=this._getForceShape3d(this._colliderNode),X=this._colliderNode.s("shape3d.side"),g.defines.PARTICLE_COLLIDER_ONE_SIDE=!0===i.a("particleCollideOneSide"),g.defines.PARTICLE_COLLIDER_PLANE="sphere"!==f&&"cylinder"!==f,g.defines.PARTICLE_COLLIDER_CYLINDER="cylinder"===f&&4!==X&&3!==X&&5!==X&&6!==X,g.defines.PARTICLE_COLLIDER_CYLINDER_QUAD="cylinder"===f&&4==X,g.defines.PARTICLE_COLLIDER_CYLINDER_TRIANGLE="cylinder"===f&&3==X,g.defines.PARTICLE_COLLIDER_CYLINDER_HEXA="cylinder"===f&&6==X,g.defines.PARTICLE_COLLIDER_CYLINDER_PENTA="cylinder"===f&&5==X,g.defines.PARTICLE_COLLIDER_SPHERE="sphere"===f,g.defines.PARTICLE_COLLIDER_PLANE||(g.uColliderNormalMatrix=this._colliderNormalMatrix),g.uReverseMatrix=this._colliderRevertMatrix,this._colliderRevertMatrixOld?g.uReverseMatrixOld=this._colliderRevertMatrixOld:g.uReverseMatrixOld=this._colliderRevertMatrix,this._colliderRevertMatrixOld=null,g.uColliderMatrix=this._colliderMatrix,g.uColliderNormal=this._colliderNormal,g.uCollideOffset=this._colliderOffset,xg.fromArray(g.uP3).applyMatrix4(this._cdMatrix),g.uColliderSign=Math.sign(xg.y),g.defines.PARTICLE_COLLIDER_IN_RADIUS=xg.length()<=.5,g.defines.PARTICLE_COLLIDER_MAP=!!this._colliderNode.s("shape3d.image")&&!0===i.a("particleCollideMap")&&!g.defines.PARTICLE_COLLIDER_ONE_SIDE,g.defines.PARTICLE_COLLIDER_MAP&&(g.uCollideMap=this._colliderNode.s("shape3d.image"),g.uCollideMapAlphaTest=this._colliderNode.s("alphaTest")),g.uCollideSpring=i.a("particleCollideSpring")||0,g.uCollideFriction=20*(i.a("particleCollideFriction")||0),g.uFrictionConst=this._deltaTime*g.uCollideFriction),this._finalMat&&(g.uNormalMatrix=ht.Default.getInternal().createNormalMatrix(this._finalMat)),g.defines.PARTICLE_COLLIDER2=g.defines.PARTICLE_COLLIDER&&!!this._colliderNode2,g.defines.PARTICLE_COLLIDER2&&(V=this._getForceShape3d(this._colliderNode2),f=this._colliderNode2.s("shape3d.side"),g.defines.PARTICLE_COLLIDER_ONE_SIDE2=!0===i.a("particleCollideOneSide2"),g.defines.PARTICLE_COLLIDER_PLANE2="sphere"!==V&&"cylinder"!==V,g.defines.PARTICLE_COLLIDER_CYLINDER2="cylinder"===V&&4!==f&&3!==f&&5!==f&&6!==f,g.defines.PARTICLE_COLLIDER_CYLINDER_QUAD2="cylinder"===V&&4==f,g.defines.PARTICLE_COLLIDER_CYLINDER_TRIANGLE2="cylinder"===V&&3==f,g.defines.PARTICLE_COLLIDER_CYLINDER_HEXA2="cylinder"===V&&6==f,g.defines.PARTICLE_COLLIDER_CYLINDER_PENTA2="cylinder"===V&&5==f,g.defines.PARTICLE_COLLIDER_SPHERE2="sphere"===V,g.defines.PARTICLE_COLLIDER_PLANE2||(g.uColliderNormalMatrix2=this._colliderNormalMatrix2),g.uReverseMatrix2=this._colliderRevertMatrix2,this._colliderRevertMatrix2Old?g.uReverseMatrix2Old=this._colliderRevertMatrix2Old:g.uReverseMatrix2Old=this._colliderRevertMatrix2,this._colliderRevertMatrix2Old=null,g.uColliderMatrix2=this._colliderMatrix2,g.uColliderNormal2=this._colliderNormal2,g.uCollideOffset2=this._colliderOffset2,xg.fromArray(g.uP3).applyMatrix4(this._cdMatrix2),g.uColliderSign2=Math.sign(xg.y),g.defines.PARTICLE_COLLIDER_IN_RADIUS2=xg.length()<=.5,g.defines.PARTICLE_COLLIDER_MAP2=!!this._colliderNode2.s("shape3d.image")&&!0===i.a("particleCollideMap2")&&!g.defines.PARTICLE_COLLIDER_ONE_SIDE2,g.defines.PARTICLE_COLLIDER_MAP2&&(g.uCollideMap2=this._colliderNode2.s("shape3d.image"),g.uCollideMapAlphaTest2=this._colliderNode2.s("alphaTest")),g.uCollideSpring2=i.a("particleCollideSpring2")||0,g.uCollideFriction2=20*(i.a("particleCollideFriction2")||0),g.uFrictionConst2=this._deltaTime*g.uCollideFriction2),g.defines.PARTICLE_COLLIDER3=g.defines.PARTICLE_COLLIDER2&&!!this._colliderNode3,g.defines.PARTICLE_COLLIDER3&&(z=this._getForceShape3d(this._colliderNode3),V=this._colliderNode3.s("shape3d.side"),g.defines.PARTICLE_COLLIDER_ONE_SIDE3=!0===i.a("particleCollideOneSide3"),g.defines.PARTICLE_COLLIDER_PLANE3="sphere"!==z&&"cylinder"!==z,g.defines.PARTICLE_COLLIDER_CYLINDER3="cylinder"===z&&4!==V&&3!==V&&5!==V&&6!==V,g.defines.PARTICLE_COLLIDER_CYLINDER_QUAD3="cylinder"===z&&4==V,g.defines.PARTICLE_COLLIDER_CYLINDER_TRIANGLE3="cylinder"===z&&3==V,g.defines.PARTICLE_COLLIDER_CYLINDER_HEXA3="cylinder"===z&&6==V,g.defines.PARTICLE_COLLIDER_CYLINDER_PENTA3="cylinder"===z&&5==V,g.defines.PARTICLE_COLLIDER_SPHERE3="sphere"===z,g.defines.PARTICLE_COLLIDER_PLANE3||(g.uColliderNormalMatrix3=this._colliderNormalMatrix3),g.uReverseMatrix3=this._colliderRevertMatrix3,this._colliderRevertMatrix3Old?g.uReverseMatrix3Old=this._colliderRevertMatrix3Old:g.uReverseMatrix3Old=this._colliderRevertMatrix3,this._colliderRevertMatrix3Old=null,g.uColliderMatrix3=this._colliderMatrix3,g.uColliderNormal3=this._colliderNormal3,g.uCollideOffset3=this._colliderOffset3,xg.fromArray(g.uP3).applyMatrix4(this._cdMatrix3),g.uColliderSign3=Math.sign(xg.y),g.defines.PARTICLE_COLLIDER_IN_RADIUS3=xg.length()<=.5,g.defines.PARTICLE_COLLIDER_MAP3=!!this._colliderNode3.s("shape3d.image")&&!0===i.a("particleCollideMap3")&&!g.defines.PARTICLE_COLLIDER_ONE_SIDE3,g.defines.PARTICLE_COLLIDER_MAP3&&(g.uCollideMap3=this._colliderNode3.s("shape3d.image"),g.uCollideMapAlphaTest3=this._colliderNode3.s("alphaTest")),g.uCollideSpring3=i.a("particleCollideSpring3")||0,g.uCollideFriction3=20*(i.a("particleCollideFriction3")||0),g.uFrictionConst3=this._deltaTime*g.uCollideFriction3),g.defines.PARTICLE_ATTRACTOR=!!this._attractorNode,g.defines.PARTICLE_ATTRACTOR&&(ht.Default.extractVerticesTranslation?(U=this._attractorNode.p3(),g.uAttractorPos=[U[0]-i._particleRefP3[0],U[1]-i._particleRefP3[1],U[2]-i._particleRefP3[2]]):g.uAttractorPos=this._attractorNode.p3(),z=this._getForceShape3d(this._attractorNode),g.uAttractStrength=20*(i.a("particleAttractStrength")||0),g.defines.PARTICLE_ATTRACT_DAMPING=!!i.a("particleAttractDamping"),g.defines.PARTICLE_ATTRACTOR_SPHERE="sphere"===z||"plane"!==z&&"cylinder"!==z,g.defines.PARTICLE_ATTRACTOR_CYLINDER="cylinder"===z,U="plane"===z,g.defines.PARTICLE_ATTRACTOR_PLANE=U,g.uAttractorReverseMatrix=this._attractorRevertMatrix,g.uAttractorMatrix=this._attractorMatrix,z="enclosed"===i.a("particleAttractScope"),g.defines.PARTICLE_ATTRACT_INFINITE=!z||U,g.defines.PARTICLE_ATTRACT_SCOPE=z&&!U,g.defines.PARTICLE_ATTRACTOR_CYLINDER&&(this._v30.fromArray([0,1,0]).applyQuaternion(this._attractorNode.getQuaternion()),g.uAttractorUp=this._v30.toArray())),g.uResistance=i.a("particleResistance")||0,g.uResistanceSpeed=i.a("particleResistanceSpeed")||0,g.defines.PARTICLE_RESISTANCE=0!==g.uResistance||0!==g.uResistanceSpeed;i=i._particleRefP3;ht.Default.extractVerticesTranslation&&this._finalMat?(g.uEmitterMatrix=this._finalMat.slice(0),e&&(g.uEmitterMatrix[12]=e[0],g.uEmitterMatrix[13]=e[1],g.uEmitterMatrix[14]=e[2]),g.uEmitterMatrix[12]=g.uEmitterMatrix[12]-i[0],g.uEmitterMatrix[13]=g.uEmitterMatrix[13]-i[1],g.uEmitterMatrix[14]=g.uEmitterMatrix[14]-i[2]):e?(g.uEmitterMatrix=this._finalMat.slice(0),g.uEmitterMatrix[12]=e[0],g.uEmitterMatrix[13]=e[1],g.uEmitterMatrix[14]=e[2]):g.uEmitterMatrix=this._finalMat,g.uInitSpeed="vPlane"===x?this._emitInitSpeedV:this._emitInitSpeed,g.defines.PARTICLE_EXTRACT_TRANSLATION=ht.Default.extractVerticesTranslation}g.uRandom=[Math.random(),Math.random()],this.gv.renderModel(this._rd1,this._fieldModel3d,{clear:!0});g=this._rd0;this._rd0=this._rd1,this._rd1=g}},{key:"_updateParticlePosCpu",value:function(){var t,e,i=this.data,a=[this._particleSpeedStrength/(this._lineLength||1),this._particleRotateSpeed,this._particleRadiusSpeed],l=(this.particleState,i.a("particleInterpolateTangent")),g=this.particleState,o=this._particleRes,r=o[0]*o[1],n=i.a("particleLifeTime")||0,m=i.a("particleMinLifeTime")||0,s=n,X=i.a("particleLifeRandomTime"),D=!!i.a("particleRandom"),h=0=o[0]&&(F=0,G++),q=g[R=4*Q],B=g[1+R],E=g[2+R],k=g[3+R],x&&(P=(O=d?(S=(q*v+c+t)/p,(57.3*B+E*y+c+t)/p):(S=(F*w+c)/p,(G*b+c)/p),this._noise.noise(S,O))),D&&(W=[P*z[0],P*z[1],P*z[2]]);var L,K,I,H=Math.sign(k),N=h?1+(s-m)*P:1;if(u){var J=Math.abs(k)+1/60;if(1+s<=J){q=0,B=B+a[1]+W[1];E+=(a[2]+W[2])*H,k=H*N,Z=Y?T*(.5-ht.Default.getLineOffset(f,q,l).point.x)-M:T-M,B=B+a[1]+W[1],U?E=E*Z+(a[1]+W[2])*H:E+=(a[2]+W[2])*H,Math.abs(E)>Z&&(k*=-1,E=Math.sign(E)*(Z-E%1)),Z<0&&(E=0),U&&(E/=Z),g[R]=q,g[1+R]=B,g[2+R]=E,g[3+R]=k,this._updateTrailPos(Q,q,B,E*Z);continue}k=H*J}q=(j=q+(V?(K=C[(L=Cg(_,q))-1],I=C[L],K+(q-(J=_[L-1]))/(_[L]-J)*(I-K)*A):a[0])+W[0]/v)%1,Z=Y?T*(.5-ht.Default.getLineOffset(f,q,l).point.x)-M:T-M,(j<0||1<=j)&&(k=H*N),B=B+a[1]+W[1],U?E=E*Z+(a[2]+W[2])*H:E+=(a[2]+W[2])*H,Math.abs(E)>Z&&(k*=-1,(H=E%1)<0&&(H+=1),E=Math.sign(E)*(Z-H)),Z<0&&(E=0),U&&(E/=Z),g[R]=q,g[1+R]=B,g[2+R]=E,g[3+R]=k,this._updateTrailPos(Q,q,B,E*Z)}this._rd1.updateTextureData(g),this._trail3dUI&&this._trail3dUI.validate();i=this._rd0;this._rd0=this._rd1,this._rd1=i}},{key:"_updateTrailPos",value:function(t,e,i,a){var l,g=this._lineCache;g&&(this._trail||this._initTrailBatch(),l=this.data.a("particleInterpolateTangent"),l=ht.Default.getLineOffset(g,e*this._lineLength,l),dg.setFromToVectors(hg,l.tangent),xg.fromArray([a*Math.cos(i),0,a*Math.sin(i)]),xg.applyQuaternion(dg).add(l.point),i=xg.toArray(),ht.Default.extractVerticesTranslation&&(l=this._lineP3,i[0]=i[0]+l[0],i[1]=i[1]+l[1],i[2]=i[2]+l[2]),this._trail.setCompPosition(t,i))}},{key:"_initFieldModel3d",value:function(){var t=this.data.a("particleSpaceMode"),e=this._fieldMat={type:vl,uLineInfo:this._lineInfoTexture,uDeltaTime:1/60,uDeltaTime2:1/120,defines:{}};"OPEN_SPACE"===t&&(e.type=yl);this._fieldModel3d={model3d:!0,mesh:{aPos:new Float32Array([0,0,1,0,0,1,0,1,1,0,1,1])},mat:e}}},{key:"_initParticleModel3d",value:function(){var t=this.data.a("particleSpaceMode"),e=this._particleMat={type:pl,renderMode:"points",internalType:"litePhong",renderPickMap:!0,uLineInfo:this._lineInfoTexture,defines:{}};"OPEN_SPACE"===t&&(e.type=Yl);this._particleModel3d={model3d:!0,mesh:{aIndex:this._particleIndices},mat:e}}},{key:"_initInstancedModel3d",value:function(){var t=this.data.a("particleSpaceMode"),e=this._particleMat={type:cl,internalType:"litePhong",renderPickMap:!0,defines:{}};"OPEN_SPACE"===t&&(e.type=Tl);this._particleModel3d={model3d:!0,mesh:{type:"sphere"},instances:{aIndex:this._particleIndices},mat:e};this._updateInstancedModel()}},{key:"_syncMatDef",value:function(){var t=this.data.s("matDef");if(t){var e=this._particleModel3d.matDef;if(e&&!B(e))for(var i,a=Object.keys(e),l=a.length,g=0;g=e&&t[l-1]<=e)return l;t[l]=g-1)return e}else if(0===e[0]||e[0]>=g-1)return;i.beginTransaction();var o=this.getEditTarget(),r=void 0,n=void 0,m=void 0,s=void 0,X=void 0,g=void 0;"rotate"===o?(s=this._pathUi._getControlLenInfo(),r="animCurveControlLenInfo",n="animCurveControlNum",g="animCurveControlRotateInfo",m=10,X=this._pathUi._getControlRotateInfo()):"speed"===o?(s=this._pathUi._getSpeedControlLenInfo(),r=this._prefix+"SpeedControlLenInfo",n=this._prefix+"SpeedControlNum",g=this._prefix+"SpeedControlInfo",m=10,X=this._pathUi._getControlSpeedInfo()):"scale"===o?(s=this._pathUi._getScaleControlLenInfo(),r=this._prefix+"ScaleControlLenInfo",n=this._prefix+"ScaleControlNum",g=this._prefix+"ScaleControlInfo",m=10,X=this._pathUi._getControlScaleInfo()):"heading"===o&&(s=this._pathUi._getHeadingControlLenInfo(),r="animHeadingControlLenInfo",n="animHeadingControlNum",g="animHeadingControlInfo",m=10,X=this._pathUi._getControlHeadingInfo()),t?(l=s[e[0]],s.splice(e[0],1,l,l+.001)):s.splice(e[0],1),a.a(r,s.slice(0)),t?(l=X[e[0]],X.splice(e[0],1,l,l)):X.splice(e[0],1),a.a(g,X.slice(0));a=this._getControlPosInfo(o);t?(g=a[3*e[0]],X=a[3*e[0]+1],o=a[3*e[0]+2],a.splice(3*e[0],3,g,X,o,g,X,o)):a.splice(3*e[0],3);a=void 0,a=t?(this._data.a(n)||m)+1:(this._data.a(n)||m)-1;return this._data.a(n,a),i.endTransaction(),[e[0]+1]}},{key:"addCopyComps",value:function(t){return this.addDeleteImpl(!0,t)}},{key:"deleteComps",value:function(t){return this.addDeleteImpl(!1,t)}}]),io);function io(t,e){s(this,io);var i=n(this,(io.__proto__||Object.getPrototypeOf(io)).call(this));return i._gv=t,i._data=e,i._ui=new ht.graph3d.Polyline3dUI(t,i),Hg(e)?(i._mode="Point",i._pathUi=t.getData3dUI(e),i._updateColorMap(i),e instanceof Ra&&(i._mi=function(t){i._startAngle=i._pathUi._getControlRotateInfo().slice(0),"heading"===i._data.a("animEditTarget")&&(!("beginRotateDetail"===t.kind||ht.Default.isRightButton(t.event)&&"betweenEditDetail"==t.kind)||(t=i._gv.getDataInfoAt(t.event))&&i._switchHeadingMode(t.part))},i._gv.mi(i._mi)),i.s3([1,1,1])):(i._mode="Curve",i._myInit()),e instanceof Ra?i._prefix="anim":e instanceof Qg&&(i._prefix="particle"),i}function ao(){return eo}function lo(){var t=this.a("animPath");return Hg(this)?"Point":R(t)?"Curve":void 0}function go(){var t=this.a("animEditTarget")||Gt,e=this.a("animShowCurveControl")&&"rotate"===t,t=(this.a("animShowHeadingControl"),this._editCapability);if(t?this._editCapability.rotatable=e:t=this._editCapability={movable:!0,rotatable:e,resizable:!1,deletable:!0,addCopy:!0,editDraw:!0},Hg(this))return t}qa=Ra.prototype;qa.getEditHelperClass=ao,qa.getSupportInteractor=lo,qa.getEditCapability=go;ka=Qg.prototype;ka.getEditHelperClass=ao,ka.getSupportInteractor=lo,ka.getEditCapability=go;Fa=ht.graph3d.Graph3dView.prototype;Fa.setAutomationValue=function(t,e,i){this._globalAutomationVars||(this._globalAutomationVars={});var a=e.value||e;this._globalAutomationConditions||(this._globalAutomationConditions={});var l=this._globalAutomationVars,g=void 0,g=l[t]&&l[t].value||l[t];if(!i||g!==a){l[t]=e;var o=this._globalAutomationConditions[t];if(o)for(var r,n=o.length,m=void 0,s=void 0,X=void 0,D=0;Dt[l]&&(e[0]=t[l]),e[1]t[l+1]&&(i[0]=t[l+1]),i[1]