System.register("chunks:///_virtual/Action.ts",["./rollupPluginModLoBabelHelpers.js","cc"],(function(t){var n,i;return{setters:[function(t){n=t.createClass},function(t){i=t.cclegacy}],execute:function(){t("default",(function(){return new r})),i._RF.push({},"24a1fbkvW9AQJ+cc5f2eMnl","Action",void 0);var r=function(){function t(){this._list=[],this._current=void 0}var i=t.prototype;return i.add=function(t){for(var n=arguments.length,i=new Array(n>1?n-1:0),r=1;r0;n--){var t=Math.floor(Math.random()*(n+1)),e=[r[t],r[n]];r[n]=e[0],r[t]=e[1]}return r},r.MergeAndRemoveDuplicates=function(r,n){var t=[].concat(r,n);return Array.from(new Set(t))},r.ExcludeElements=function(r,n){var t=new Set(n);return r.filter((function(r){return!t.has(r)}))},r.checkSequentialCombination=function(r){for(var n=r.slice().sort((function(r,n){return r-n})),t=0;t1&&n.push(t),t=[r[e]]);return t.length>1&&n.push(t),n},r.DeleteOneItem=function(r,n){for(var t=r.length,e=0;e0&&t.sortValue>(e=r[i-1]).sortValue;i--)r[i]=e;r[i]=t}},r.reorder=function(r,n){for(var t=r.length-1,e=0;e>1;this.MergeSort(r,n,e),this.MergeSort(r,e,t),this.merge(r,n,e,t)}},r.merge=function(r,n,t,e){for(var o=r.slice(n,e),i=t-n,u=new Array(i),f=0;f0){if(this._playing_sound.has(i))return;this._playing_sound.add(i);var o=t<=1?e.getDuration()*t*1e3:t;setTimeout((function(){s._playing_sound.delete(i)}),o),this.getNextEffectSource().playOneShot(e,this._volume_effect)}else this.getNextEffectSource().playOneShot(e,this._volume_effect)},s.getNextEffectSource=function(){var e=this._effect_source_pool[this._effect_index];return this._effect_index=(this._effect_index+1)%this._effect_max,e},s.play=function(e,t){var s=this;if(void 0===t&&(t=".mp3"),this._switch_music)if(e instanceof _)this._music_source.loop=!0,this._music_source.stop(),this._music_source.clip=e,this._music_source.play(),this._music_source.volume=this._volume_music;else if(this._load_type==f.none)n.warn("音频模块未初始化");else if(this._load_type==f.bundle){var i=o.getBundle(this._bundle_name);i?i.load(e,(function(e,t){e?n.error(e):(s._music_source.loop=!0,s._music_source.stop(),s._music_source.clip=t,s._music_source.play(),s._music_source.volume=s._volume_music)})):n.warn("请确保 bundle"+this._bundle_name+" 已加载")}else this._load_type==f.remote&&o.loadRemote(this._remote_url+e+t,(function(e,t){e?n.error(e):(s._music_source.loop=!0,s._music_source.stop(),s._music_source.clip=t,s._music_source.play(),s._music_source.volume=s._volume_music)}))},s.stop=function(){this._music_source.stop();for(var e=0;e6e4?null:this._cache_records},n.getRecords=function(){var e=t(r().mark((function e(t,n){var a,c,u,i,o,h;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(void 0===t&&(t=1),void 0===n&&(n=!0),!n){e.next=6;break}if(!(a=this.get_cache_records())){e.next=6;break}return e.abrupt("return",a);case 6:if(!chsdk.check_req_time("getRecords")){e.next=9;break}return e.abrupt("return",null);case 9:return e.next=11,chsdk.makePostTokenRequest(chsdk.getUrl(this._record_url),{typeId:t});case 11:if((c=e.sent).code==chsdk.code.success){e.next=17;break}return chsdk.log.warn(c),e.abrupt("return",null);case 17:for((u=c.data.data).own?((i=u.own).extends=s.parse(i.extends),i.own.uid=Number.parseInt(i.own.uid),i.own.hid=Number.parseInt(i.own.hid),i.own.province=chsdk.provinceCode2Name(i.own.hid)):u.own=null,u.list||(u.list=[]),o=0;o=n.length)return n;e=Math.min(e,n.length-1);for(var o=0;o=n.length?t.toString():""+o.toFixed(r)+n[i]},r.numberToThousand=function(t,e,n){void 0===e&&(e=2),void 0===n&&(n=!0);var r=n?this._k_sizes_en:this._k_sizes_cn;return this.convertNumber(t,this._k,r,e)},r.numberToTenThousand=function(t,e,n){void 0===e&&(e=2),void 0===n&&(n=!1);var r=n?this._w_sizes_en:this._w_sizes_cn;return this.convertNumber(t,this._w,r,e)},r.guid=function(){var t=Math.random().toString(36).substring(2);return t},r.obj_sort=function(t){for(var e=Object.keys(t).sort(),n={},r=0;r=20&&(this.is_move=!0)}},a.onTouchEnded=function(t,e){var n=this;t.preventSwallow=!0,this.has_began&&(this.move_began_end&&this.is_move||(this.on_touch_end.forEach((function(t,e){t.emit([n.comp_btn])})),this.has_began=!1,this.is_move=!1))},a.onTouchCancelled=function(t,e){t.preventSwallow=!0},e}(u)).prototype,"move_began_end",[_],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return!1}}),y=e(f.prototype,"on_touch_began",[d],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return[]}}),T=e(f.prototype,"on_touch_move",[b],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return[]}}),w=e(f.prototype,"on_touch_end",[v],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return[]}}),m=f))||m));a._RF.pop()}}})); System.register("chunks:///_virtual/Container.ts",["./rollupPluginModLoBabelHelpers.js","cc"],(function(t){var i,e;return{setters:[function(t){i=t.createClass},function(t){e=t.cclegacy}],execute:function(){e._RF.push({},"7b367Ns5DhICaZLmc2yobWd","Container",void 0);t("Container",function(){function t(){this._itemList=null,this._itemList=new Array}var e=t.prototype;return e.addCount=function(t,i){return this.addItem({type:t,count:i})},e.useCount=function(t,i){for(var e=0;e=i)return this._itemList[e].count-=i,this._itemList[e];return null},e.addItem=function(t){for(var i=0;i0?e>24?Math.floor(e/24)+"天前":e+"小时前":Math.floor(t/60)+"分钟前"},t.getFormatBySecond5=function(t){var e=3600,r=Math.floor(t/86400),n=Math.floor(t%86400/e),o=Math.floor((t-n*e)/60),a=Math.floor((t-n*e)%60);return t>0?0==r?("",0==n?("",0==o?("",0==a?"":a<10?"0"+a+"秒":a+"秒"):o+"分"+(0==a?"":a<10?"0"+a+"秒":a+"秒")):0==o?("",0==a?"":a<10?"0"+a+"秒":a+"秒"):n+"小时"+(o<10?"0"+o+"分":o+"分")):r+"天"+(0==n?"":n<10?"0"+n+"小时":n+"小时"):""},t.getFormatBySecond6=function(t){void 0===t&&(t=0);var e=Math.floor(t/3600),r=Math.floor((t-3600*e)/60);return(0==e?"00":e<10?"0"+e:""+e)+":"+(0==r?"00":r<10?"0"+r:""+r)},t.getDay=function(t){return new Date(t).getDay()},t.isSameDate=function(t,e){var r=new Date(t),n=new Date(e);return r.getFullYear()==n.getFullYear()&&r.getMonth()==n.getMonth()&&r.getDate()==n.getDate()},t.format=function(t,e){void 0===e&&(e="yyyy-MM-dd hh:mm:ss");var r={"M+":t.getMonth()+1,"d+":t.getDate(),"h+":t.getHours(),"m+":t.getMinutes(),"s+":t.getSeconds(),"q+":Math.floor((t.getMonth()+3)/3),S:t.getMilliseconds()};for(var n in/(y+)/.test(e)&&(e=e.replace(RegExp.$1,(t.getFullYear()+"").substr(4-RegExp.$1.length))),r)new RegExp("("+n+")").test(e)&&(e=e.replace(RegExp.$1,1==RegExp.$1.length?r[n]:("00"+r[n]).substr((""+r[n]).length)));return e},t.getDayCountSeconds=function(t,e){var r=Math.abs(e-t);return Math.floor(r/86400)},t.dateDifference=function(t,e){var r=Math.abs(e-t);return Math.ceil(r/864e5)},t}()).offset=0,e._RF.pop()}}})); System.register("chunks:///_virtual/Delay.ts",["cc"],(function(e){var t;return{setters:[function(e){t=e.cclegacy}],execute:function(){e("default",(function(){return new s})),t._RF.push({},"8e7b9WCurJPu4fjNX9PZbRY","Delay",void 0);var s=function(){function e(){this.delays=[],this.paused=!1}var t=e.prototype;return t.start=function(e){var t=this,s=e;return new Promise((function(e){t.delays.push({duration:s,elapsed:0,resolve:e})}))},t.pause=function(){this.paused=!0},t.resume=function(){this.paused=!1},t.update=function(e){if(!this.paused)for(var t=this.delays.length-1;t>=0;t--){var s=this.delays[t];s.elapsed+=e,s.elapsed>=s.duration&&(s.resolve&&(s.resolve(),s.resolve=null),this.delays.splice(t,1))}},t.cancelAll=function(){this.delays.forEach((function(e){e.resolve=null})),this.delays=[]},t.isActive=function(){return this.delays.length>0},e}();t._RF.pop()}}})); System.register("chunks:///_virtual/DirectorUtil.ts",["cc"],(function(e){var a,t,s,n,i,c,u,r;return{setters:[function(e){a=e.cclegacy,t=e.director,s=e.AnimationManager,n=e.sp,i=e.TweenSystem,c=e.PhysicsSystem2D,u=e.PhysicsSystem,r=e.Animation}],execute:function(){a._RF.push({},"0dd04xSWM1G07cwb9c87Tja","DirectorUtil",void 0),e("default",function(){function e(){}return e.pause=function(e){var a=this;if(!this.pause_data.state_b){this.pause_data.scheduler_as=t.getScheduler().pauseAllTargets();var r,_=t.getSystem(s.ID);if((r=this.pause_data.anim_as).splice.apply(r,[0,this.pause_data.anim_as.length].concat(_._anims.array)),this.pause_data.anim_as.forEach((function(e){e.pause()})),this.pause_data.spine_as=t.getScene().getComponentsInChildren(n.Skeleton),this.pause_data.spine_as.forEach((function(e){e.timeScale=0})),this.pause_data.tween_target_as=i.instance.ActionManager.pauseAllRunningActions(),c&&c.instance.enable&&(this.pause_data.physics_2d_b=c.instance.enable,c.instance.enable=!1),u&&u.instance.enable&&(this.pause_data.physics_3d_b=u.instance.enable,u.instance.enable=!1),e){var o,p=[];p.push.apply(p,e.exclude_as),null==(o=e.recu_exclude_as)||o.forEach((function(e){p.push.apply(p,a.recu_node_list(e))})),p.forEach((function(e){a.resume_node(e)}))}this.pause_data.state_b=!0}},e.recu_node_list=function(e,a){var t=this;return void 0===a&&(a=[]),e?(a.push(e),e.children.forEach((function(e){a.push(e),t.recu_node_list(e)})),a):a},e.resume=function(){t.getScheduler().resumeTargets(this.pause_data.scheduler_as),this.pause_data.anim_as.forEach((function(e){e.isPlaying&&e.isPaused&&e.play()})),this.pause_data.spine_as.forEach((function(e){e.timeScale=1})),i.instance.ActionManager.resumeTargets(this.pause_data.tween_target_as),this.pause_data.physics_2d_b&&(c.instance.enable=this.pause_data.physics_2d_b),this.pause_data.physics_3d_b&&(u.instance.enable=this.pause_data.physics_3d_b),this.pause_data.state_b=!1},e.pause_node=function(e){(Array.isArray(e)?e:[e]).forEach((function(e){var a;t.getScheduler().pauseTarget(e),null==(a=e.getComponent(r))||a.pause(),e.getComponent(n.Skeleton)&&(e.getComponent(n.Skeleton).timeScale=0),i.instance.ActionManager.pauseTarget(e)}))},e.resume_node=function(e){(Array.isArray(e)?e:[e]).forEach((function(e){var a;t.getScheduler().resumeTarget(e),null==(a=e.getComponent(r))||a.resume(),e.getComponent(n.Skeleton)&&(e.getComponent(n.Skeleton).timeScale=1),i.instance.ActionManager.resumeTarget(e)}))},e}()).pause_data={state_b:!1,physics_2d_b:!1,physics_3d_b:!1,scheduler_as:[],anim_as:[],tween_target_as:[],spine_as:[]},a._RF.pop()}}})); System.register("chunks:///_virtual/FMS.ts",["./rollupPluginModLoBabelHelpers.js","cc"],(function(t){var n,e;return{setters:[function(t){n=t.createClass},function(t){e=t.cclegacy}],execute:function(){t({FMSRegister:function(t){return function(n){var e=new n;e.type=t,r.IFMS.set(t,e)}},default:function(){return new r}}),e._RF.push({},"bbc25Bst09Pm7REKGq+Wn2J","FMS",void 0);var r=function(){function t(){this._current=void 0}var e=t.prototype;return e.Init=function(t){this.Change(t)},e.Change=function(n){this._current&&this._current.onExit(),this._current=t.IFMS.get(n),this._current&&this._current.onEntry()},n(t,[{key:"Current",get:function(){return this._current}},{key:"CurrentTaype",get:function(){return this._current?null:this._current.type}}]),t}();r.IFMS=new Map,e._RF.pop()}}})); System.register("chunks:///_virtual/Game.ts",["./rollupPluginModLoBabelHelpers.js","cc","./Delay.ts","./FMS.ts","./TimeJobCenter.ts","./Random.ts","./PrefabPool.ts","./DirectorUtil.ts"],(function(t){var e,n,u,a,o,s,i,c,r,f;return{setters:[function(t){e=t.inheritsLoose,n=t.createClass},function(t){u=t.cclegacy,a=t.Component},function(t){o=t.default},function(t){s=t.default},function(t){i=t.default},function(t){c=t.default},function(t){r=t.default},function(t){f=t.default}],execute:function(){u._RF.push({},"c8af7nfrdRHqaACOmm328nQ","Game",void 0),t("Game",function(t){function u(){for(var e,n=arguments.length,u=new Array(n),a=0;ao)return 1}return 0},r.loadGameDataWithRetry=function(){var t=a(n().mark((function t(e,a){var r,i;return n().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:void 0===e&&(e=3),void 0===a&&(a=1e3),r=0;case 3:if(!(r1?e-1:0),a=1;a=1}},{key:"percent",get:function(){return this._percent}}]),e}());n._RF.pop()}}})); System.register("chunks:///_virtual/List.ts",["./rollupPluginModLoBabelHelpers.js","cc","./env","./ListItem.ts"],(function(t){var e,i,s,o,n,a,l,r,c,h,_,d,u,m,p,g,f,v,I,y,T,S,w,z,D,N,b;return{setters:[function(t){e=t.applyDecoratedDescriptor,i=t.inheritsLoose,s=t.initializerDefineProperty,o=t.assertThisInitialized,n=t.createClass},function(t){a=t.cclegacy,l=t._decorator,r=t.ScrollView,c=t.Enum,h=t.Node,_=t.Prefab,d=t.CCFloat,u=t.EventHandler,m=t.CCBoolean,p=t.CCInteger,g=t.isValid,f=t.UITransform,v=t.Layout,I=t.instantiate,y=t.NodePool,T=t.Vec3,S=t.Size,w=t.Widget,z=t.tween,D=t.Component},function(t){N=t.DEV},function(t){b=t.default}],execute:function(){var E,P,L,G,C,O,R,U,A,B,k,M,x,V,H,F,X,Y,Z,W,j,q,J,K,Q,$,tt,et,it,st,ot,nt,at,lt,rt,ct,ht,_t,dt,ut,mt,pt,gt;a._RF.push({},"30e50g9bStDgYX3Y3vvH6ye","List",void 0);var ft=l.ccclass,vt=l.property,It=l.disallowMultiple,yt=l.menu,Tt=l.executionOrder,St=l.requireComponent,wt=function(t){return t[t.NODE=1]="NODE",t[t.PREFAB=2]="PREFAB",t}(wt||{}),zt=function(t){return t[t.NORMAL=1]="NORMAL",t[t.ADHERING=2]="ADHERING",t[t.PAGE=3]="PAGE",t}(zt||{}),Dt=function(t){return t[t.NONE=0]="NONE",t[t.SINGLE=1]="SINGLE",t[t.MULT=2]="MULT",t}(Dt||{});t("default",(E=It(),P=yt("List"),L=St(r),G=Tt(-5e3),C=vt({type:c(wt),tooltip:N}),O=vt({type:h,tooltip:N,visible:function(){return this.templateType==wt.NODE}}),R=vt({type:_,tooltip:N,visible:function(){return this.templateType==wt.PREFAB}}),U=vt({}),A=vt({type:c(zt),tooltip:N}),B=vt({type:d,range:[0,1,.1],tooltip:N,slide:!0,visible:function(){return this._slideMode==zt.PAGE}}),k=vt({type:u,tooltip:N,visible:function(){return this._slideMode==zt.PAGE}}),M=vt({}),x=vt({type:m,tooltip:N}),V=vt({tooltip:N,visible:function(){var t=this.slideMode==zt.NORMAL;return t||(this.cyclic=!1),t}}),H=vt({tooltip:N,visible:function(){return this.virtual}}),F=vt({tooltip:N,visible:function(){var t=this.virtual&&!this.lackCenter;return t||(this.lackSlide=!1),t}}),X=vt({type:p}),Y=vt({type:p,range:[0,6,1],tooltip:N,slide:!0}),Z=vt({type:p,range:[0,12,1],tooltip:N,slide:!0}),W=vt({type:u,tooltip:N}),j=vt({type:c(Dt),tooltip:N}),q=vt({type:u,tooltip:N,visible:function(){return this.selectedMode>Dt.NONE}}),J=vt({tooltip:N,visible:function(){return this.selectedMode==Dt.SINGLE}}),K=vt({serializable:!1}),ft(Q=E(Q=P(Q=L(Q=G((tt=e(($=function(t){function e(){for(var e,i=arguments.length,n=new Array(i),a=0;a0)this.frameCount--;else if(this.frameCount=this._updateRate,!this._aniDelRuning){if(this.cyclic){var e=this.content.getPosition();e=this._sizeType?e.y:e.x;var i=this._allItemSizeNoEdge+(this._sizeType?this._lineGap:this._columnGap),s=this._sizeType?new T(0,i,0):new T(i,0,0),o=this.content.getPosition();switch(this._alignCalcType){case 1:e>-this._cyclicPos1?(o.set(-this._cyclicPos2,o.y,o.z),this.content.setPosition(o),this._scrollView.isAutoScrolling()&&(this._scrollView._autoScrollStartPosition=this._scrollView._autoScrollStartPosition.subtract(s))):e<-this._cyclicPos2&&(o.set(-this._cyclicPos1,o.y,o.z),this.content.setPosition(o),this._scrollView.isAutoScrolling()&&(this._scrollView._autoScrollStartPosition=this._scrollView._autoScrollStartPosition.add(s)));break;case 2:ethis._cyclicPos2&&(o.set(this._cyclicPos1,o.y,o.z),this.content.setPosition(o),this._scrollView.isAutoScrolling()&&(this._scrollView._autoScrollStartPosition=this._scrollView._autoScrollStartPosition.subtract(s)));break;case 3:ethis._cyclicPos2&&(o.set(o.x,this._cyclicPos1,o.z),this.content.setPosition(o),this._scrollView.isAutoScrolling()&&(this._scrollView._autoScrollStartPosition=this._scrollView._autoScrollStartPosition.subtract(s)));break;case 4:e>-this._cyclicPos1?(o.set(o.x,-this._cyclicPos2,o.z),this.content.setPosition(o),this._scrollView.isAutoScrolling()&&(this._scrollView._autoScrollStartPosition=this._scrollView._autoScrollStartPosition.subtract(s))):e<-this._cyclicPos2&&(o.set(o.x,-this._cyclicPos1,o.z),this.content.setPosition(o),this._scrollView.isAutoScrolling()&&(this._scrollView._autoScrollStartPosition=this._scrollView._autoScrollStartPosition.add(s)))}}var n,a,l,r;if(this._calcViewPos(),this._sizeType?(n=this.viewTop,l=this.viewBottom):(a=this.viewRight,r=this.viewLeft),this._virtual){var c;this.displayData=[];var h=0,_=this._numItems-1;if(this._customSize)for(var d=!1;h<=_&&!d;h++)switch(c=this._calcItemPos(h),this._align){case v.Type.HORIZONTAL:c.right>=r&&c.left<=a?this.displayData.push(c):0!=h&&this.displayData.length>0&&(d=!0);break;case v.Type.VERTICAL:c.bottom<=n&&c.top>=l?this.displayData.push(c):0!=h&&this.displayData.length>0&&(d=!0);break;case v.Type.GRID:switch(this._startAxis){case v.AxisDirection.HORIZONTAL:c.bottom<=n&&c.top>=l?this.displayData.push(c):0!=h&&this.displayData.length>0&&(d=!0);break;case v.AxisDirection.VERTICAL:c.right>=r&&c.left<=a?this.displayData.push(c):0!=h&&this.displayData.length>0&&(d=!0)}}else{var u=this._itemSize.width+this._columnGap,m=this._itemSize.height+this._lineGap;switch(this._alignCalcType){case 1:h=(r-this._leftGap)/u,_=(a-this._leftGap)/u;break;case 2:h=(-a-this._rightGap)/u,_=(-r-this._rightGap)/u;break;case 3:h=(-n-this._topGap)/m,_=(-l-this._topGap)/m;break;case 4:h=(l-this._bottomGap)/m,_=(n-this._bottomGap)/m}for(h=Math.floor(h)*this._colLineNum,_=Math.ceil(_)*this._colLineNum,h<0&&(h=0),--_>=this._numItems&&(_=this._numItems-1);h<=_;h++)this.displayData.push(this._calcItemPos(h))}if(this._delRedundantItem(),this.displayData.length<=0||!this._numItems)return void(this._lastDisplayData=[]);this.firstListId=this.displayData[0].id,this.displayItemNum=this.displayData.length;var p=this._lastDisplayData.length,g=this.displayItemNum!=p;if(g&&(this.frameByFrameRenderNum>0&&this._lastDisplayData.sort((function(t,e){return t-e})),g=this.firstListId!=this._lastDisplayData[0]||this.displayData[this.displayItemNum-1].id!=this._lastDisplayData[p-1]),this._forceUpdate||g)if(this.frameByFrameRenderNum>0)this._numItems>0?(this._updateDone?this._updateCounter=0:this._doneAfterUpdate=!0,this._updateDone=!1):(this._updateCounter=0,this._updateDone=!0);else{this._lastDisplayData=[];for(var f=0;f0?t.x:0,this.viewLeft=(t.x<0?-t.x:0)-this.elasticLeft,this.viewRight=this.viewLeft+this._thisNodeUt.width,this.elasticRight=this.viewRight>this._contentUt.width?Math.abs(this.viewRight-this._contentUt.width):0,this.viewRight+=this.elasticRight;break;case 2:this.elasticRight=t.x<0?-t.x:0,this.viewRight=(t.x>0?-t.x:0)+this.elasticRight,this.viewLeft=this.viewRight-this._thisNodeUt.width,this.elasticLeft=this.viewLeft<-this._contentUt.width?Math.abs(this.viewLeft+this._contentUt.width):0,this.viewLeft-=this.elasticLeft;break;case 3:this.elasticTop=t.y<0?Math.abs(t.y):0,this.viewTop=(t.y>0?-t.y:0)+this.elasticTop,this.viewBottom=this.viewTop-this._thisNodeUt.height,this.elasticBottom=this.viewBottom<-this._contentUt.height?Math.abs(this.viewBottom+this._contentUt.height):0,this.viewBottom+=this.elasticBottom;break;case 4:this.elasticBottom=t.y>0?Math.abs(t.y):0,this.viewBottom=(t.y<0?-t.y:0)-this.elasticBottom,this.viewTop=this.viewBottom+this._thisNodeUt.height,this.elasticTop=this.viewTop>this._contentUt.height?Math.abs(this.viewTop-this._contentUt.height):0,this.viewTop-=this.elasticTop}},a._calcItemPos=function(t){var e,i,s,o,n,a,l,r;switch(this._align){case v.Type.HORIZONTAL:switch(this._horizontalDir){case v.HorizontalDirection.LEFT_TO_RIGHT:if(this._customSize){var c=this._getFixedSize(t);n=this._leftGap+(this._itemSize.width+this._columnGap)*(t-c.count)+(c.val+this._columnGap*c.count);var h=this._customSize[t];e=h>0?h:this._itemSize.width}else n=this._leftGap+(this._itemSize.width+this._columnGap)*t,e=this._itemSize.width;if(this.lackCenter)n-=this._leftGap,n+=this._contentUt.width/2-this._allItemSizeNoEdge/2;return{id:t,left:n,right:a=n+e,x:n+this._itemTmpUt.anchorX*e,y:this._itemTmp.y};case v.HorizontalDirection.RIGHT_TO_LEFT:if(this._customSize){var _=this._getFixedSize(t);a=-this._rightGap-(this._itemSize.width+this._columnGap)*(t-_.count)-(_.val+this._columnGap*_.count);var d=this._customSize[t];e=d>0?d:this._itemSize.width}else a=-this._rightGap-(this._itemSize.width+this._columnGap)*t,e=this._itemSize.width;if(this.lackCenter)a+=this._rightGap,a-=this._contentUt.width/2-this._allItemSizeNoEdge/2;return{id:t,right:a,left:n=a-e,x:n+this._itemTmpUt.anchorX*e,y:this._itemTmp.y}}break;case v.Type.VERTICAL:switch(this._verticalDir){case v.VerticalDirection.TOP_TO_BOTTOM:if(this._customSize){var u=this._getFixedSize(t);s=-this._topGap-(this._itemSize.height+this._lineGap)*(t-u.count)-(u.val+this._lineGap*u.count);var m=this._customSize[t];i=m>0?m:this._itemSize.height}else s=-this._topGap-(this._itemSize.height+this._lineGap)*t,i=this._itemSize.height;if(this.lackCenter)s+=this._topGap,s-=this._contentUt.height/2-this._allItemSizeNoEdge/2;return{id:t,top:s,bottom:o=s-i,x:this._itemTmp.x,y:o+this._itemTmpUt.anchorY*i};case v.VerticalDirection.BOTTOM_TO_TOP:if(this._customSize){var p=this._getFixedSize(t);o=this._bottomGap+(this._itemSize.height+this._lineGap)*(t-p.count)+(p.val+this._lineGap*p.count);var g=this._customSize[t];i=g>0?g:this._itemSize.height}else o=this._bottomGap+(this._itemSize.height+this._lineGap)*t,i=this._itemSize.height;if(this.lackCenter)o-=this._bottomGap,o+=this._contentUt.height/2-this._allItemSizeNoEdge/2;return{id:t,top:s=o+i,bottom:o,x:this._itemTmp.x,y:o+this._itemTmpUt.anchorY*i}}case v.Type.GRID:var f=Math.floor(t/this._colLineNum);switch(this._startAxis){case v.AxisDirection.HORIZONTAL:switch(this._verticalDir){case v.VerticalDirection.TOP_TO_BOTTOM:r=(o=(s=-this._topGap-(this._itemSize.height+this._lineGap)*f)-this._itemSize.height)+this._itemTmpUt.anchorY*this._itemSize.height;break;case v.VerticalDirection.BOTTOM_TO_TOP:s=(o=this._bottomGap+(this._itemSize.height+this._lineGap)*f)+this._itemSize.height,r=o+this._itemTmpUt.anchorY*this._itemSize.height}switch(l=this._leftGap+t%this._colLineNum*(this._itemSize.width+this._columnGap),this._horizontalDir){case v.HorizontalDirection.LEFT_TO_RIGHT:l+=this._itemTmpUt.anchorX*this._itemSize.width,l-=this._contentUt.anchorX*this._contentUt.width;break;case v.HorizontalDirection.RIGHT_TO_LEFT:l+=(1-this._itemTmpUt.anchorX)*this._itemSize.width,l-=(1-this._contentUt.anchorX)*this._contentUt.width,l*=-1}return{id:t,top:s,bottom:o,x:l,y:r};case v.AxisDirection.VERTICAL:switch(this._horizontalDir){case v.HorizontalDirection.LEFT_TO_RIGHT:a=(n=this._leftGap+(this._itemSize.width+this._columnGap)*f)+this._itemSize.width,l=n+this._itemTmpUt.anchorX*this._itemSize.width,l-=this._contentUt.anchorX*this._contentUt.width;break;case v.HorizontalDirection.RIGHT_TO_LEFT:l=(n=(a=-this._rightGap-(this._itemSize.width+this._columnGap)*f)-this._itemSize.width)+this._itemTmpUt.anchorX*this._itemSize.width,l+=(1-this._contentUt.anchorX)*this._contentUt.width}switch(r=-this._topGap-t%this._colLineNum*(this._itemSize.height+this._lineGap),this._verticalDir){case v.VerticalDirection.TOP_TO_BOTTOM:r-=(1-this._itemTmpUt.anchorY)*this._itemSize.height,r+=(1-this._contentUt.anchorY)*this._contentUt.height;break;case v.VerticalDirection.BOTTOM_TO_TOP:r-=this._itemTmpUt.anchorY*this._itemSize.height,r+=this._contentUt.anchorY*this._contentUt.height,r*=-1}return{id:t,left:n,right:a,x:l,y:r}}}},a._calcExistItemPos=function(t){var e=this.getItemByListId(t);if(!e)return null;var i=e.getComponent(f),s=e.getPosition(),o={id:t,x:s.x,y:s.y};return this._sizeType?(o.top=s.y+i.height*(1-i.anchorY),o.bottom=s.y-i.height*i.anchorY):(o.left=s.x-i.width*i.anchorX,o.right=s.x+i.width*(1-i.anchorX)),o},a.getItemPos=function(t){return this._virtual||this.frameByFrameRenderNum?this._calcItemPos(t):this._calcExistItemPos(t)},a._getFixedSize=function(t){if(!this._customSize)return null;null==t&&(t=this._numItems);var e=0,i=0;for(var s in this._customSize)parseInt(s)0||t.elasticRight>0||t.elasticBottom>0||t.elasticLeft>0)){var e=t._sizeType?t.viewTop:t.viewLeft,i=(t._sizeType?t._thisNodeUt.height:t._thisNodeUt.width)*t.pageDistance;if(Math.abs(t._beganPos-e)>i){var s=.5;switch(t._alignCalcType){case 1:case 4:t._beganPos>e?t.prePage(s):t.nextPage(s);break;case 2:case 3:t._beganPos0||t.elasticRight>0||t.elasticBottom>0||t.elasticLeft>0)){t.adhering=!0,t._calcNearestItem();var e=(t._sizeType?t._topGap:t._leftGap)/(t._sizeType?t._thisNodeUt.height:t._thisNodeUt.width);t.scrollTo(t.nearestListId,.7,e)}},a.update=function(){if(!(this.frameByFrameRenderNum<=0||this._updateDone))if(this._virtual){for(var t=this._updateCounter+this.frameByFrameRenderNum>this.displayItemNum?this.displayItemNum:this._updateCounter+this.frameByFrameRenderNum,e=this._updateCounter;e=this.displayItemNum-1?this._doneAfterUpdate?(this._updateCounter=0,this._updateDone=!1,this._doneAfterUpdate=!1):(this._updateDone=!0,this._delRedundantItem(),this._forceUpdate=!1,this._calcNearestItem(),this.slideMode==zt.PAGE&&(this.curPageNum=this.nearestListId)):this._updateCounter+=this.frameByFrameRenderNum}else if(this._updateCounterthis._numItems?this._numItems:this._updateCounter+this.frameByFrameRenderNum,o=this._updateCounter;o0;if(e=i?this._pool.get():I(this._itemTmp),i&&g(e)||(e=I(this._itemTmp),i=!1),e._listId!=t.id)e._listId=t.id,e.getComponent(f).setContentSize(this._itemSize);if(e.setPosition(new T(t.x,t.y,0)),this._resetItemSize(e),this.content.addChild(e),i&&this._needUpdateWidget){var s=e.getComponent(w);s&&s.updateAlignment()}e.setSiblingIndex(this.content.children.length-1);var o=e.getComponent(b);e.listItem=o,o&&(o.listId=t.id,o.list=this,o._registerEvent()),this.renderEvent&&u.emitEvents([this.renderEvent],e,t.id%this._actualNumItems)}this._resetItemSize(e),this._updateListItem(e.listItem),this._lastDisplayData.indexOf(t.id)<0&&this._lastDisplayData.push(t.id)},a._createOrUpdateItem2=function(t){var e,i=this.content.children[t];i?this._forceUpdate&&this.renderEvent&&(i._listId=t,e&&(e.listId=t),this.renderEvent&&u.emitEvents([this.renderEvent],i,t%this._actualNumItems)):((i=I(this._itemTmp))._listId=t,this.content.addChild(i),e=i.getComponent(b),i.listItem=e,e&&(e.listId=t,e.list=this,e._registerEvent()),this.renderEvent&&u.emitEvents([this.renderEvent],i,t%this._actualNumItems)),this._updateListItem(e),this._lastDisplayData.indexOf(t)<0&&this._lastDisplayData.push(t)},a._updateListItem=function(t){if(t&&this.selectedMode>Dt.NONE){var e=t.node;switch(this.selectedMode){case Dt.SINGLE:t.selected=this.selectedId==e._listId;break;case Dt.MULT:t.selected=this.multSelected.indexOf(e._listId)>=0}}},a._resetItemSize=function(t){},a._updateItemPos=function(t){var e=isNaN(t)?t:this.getItemByListId(t),i=this.getItemPos(e._listId);e.setPosition(i.x,i.y)},a.setMultSelected=function(t,e){var i=this;if(i.checkInited()){var s,o;if(Array.isArray(t)||(t=[t]),null==e)i.multSelected=t;else if(e)for(var n=t.length-1;n>=0;n--)s=t[n],(o=i.multSelected.indexOf(s))<0&&i.multSelected.push(s);else for(var a=t.length-1;a>=0;a--)s=t[a],(o=i.multSelected.indexOf(s))>=0&&i.multSelected.splice(o,1);i._forceUpdate=!0,i._onScrolling()}},a.getMultSelected=function(){return this.multSelected},a.hasMultSelected=function(t){return this.multSelected&&this.multSelected.indexOf(t)>=0},a.updateItem=function(t){if(this.checkInited()){Array.isArray(t)||(t=[t]);for(var e=0,i=t.length;e=0;e--){var i=this.content.children[e];if(i._listId==t)return i}},a._getOutsideItem=function(){for(var t,e=[],i=this.content.children.length-1;i>=0;i--)t=this.content.children[i],this.displayData.find((function(e){return e.id==t._listId}))||e.push(t);return e},a._delRedundantItem=function(){if(this._virtual)for(var t=this._getOutsideItem(),e=t.length-1;e>=0;e--){var i=t[e];if(!this._scrollItem||i._listId!=this._scrollItem._listId){i.isCached=!0,this._pool.put(i);for(var s=this._lastDisplayData.length-1;s>=0;s--)if(this._lastDisplayData[s]==i._listId){this._lastDisplayData.splice(s,1);break}}}else for(;this.content.children.length>this._numItems;)this._delSingleItem(this.content.children[this.content.children.length-1])},a._delSingleItem=function(t){t.removeFromParent(),t.destroy&&t.destroy(),t=null},a.aniDelItem=function(t,e,i){var s=this;if(!s.checkInited()||s.cyclic||!s._virtual)return console.error("This function is not allowed to be called!");if(!e)return console.error("CallFunc are not allowed to be NULL, You need to delete the corresponding index in the data array in the CallFunc!");if(s._aniDelRuning)return console.warn("Please wait for the current deletion to finish!");var o,n=s.getItemByListId(t);if(n){o=n.getComponent(b),s._aniDelRuning=!0,s._aniDelCB=e,s._aniDelItem=n,s._aniDelBeforePos=n.position,s._aniDelBeforeScale=n.scale;var a=s.displayData[s.displayData.length-1].id,l=o.selected;o.showAni(i,(function(){var i;if(a=0&&s._selectedId--;else if(s.selectedMode==Dt.MULT&&s.multSelected.length){var r=s.multSelected.indexOf(t);r>=0&&s.multSelected.splice(r,1);for(var c=s.multSelected.length-1;c>=0;c--){s.multSelected[c]>=t&&s.multSelected[c]--}}if(s._customSize){s._customSize[t]&&delete s._customSize[t];var h,_={};for(var d in s._customSize){h=s._customSize[d];var u=parseInt(d);_[u-(u>=t?1:0)]=h}s._customSize=_}for(var m,p,g=null!=i?i:a;g>=t+1;g--)if(n=s.getItemByListId(g)){var f=s._calcItemPos(g-1);m=z(n).to(.2333,{position:new T(f.x,f.y,0)}),g<=t+1&&(p=!0,m.call((function(){s._aniDelRuning=!1,e(t),delete s._aniDelCB}))),m.start()}p||(s._aniDelRuning=!1,e(t),s._aniDelCB=null)}),!0)}else e(t)},a.scrollTo=function(t,e,i,s){void 0===e&&(e=.5),void 0===i&&(i=null),void 0===s&&(s=!1);var o=this;if(o.checkInited(!1)){null==e?e=.5:e<0&&(e=0),t<0?t=0:t>=o._numItems&&(t=o._numItems-1),!o._virtual&&o._layout&&o._layout.enabled&&o._layout.updateLayout();var n,a,l=o.getItemPos(t);if(!l)return N;switch(o._alignCalcType){case 1:n=l.left,n-=null!=i?o._thisNodeUt.width*i:o._leftGap,l=new T(n,0,0);break;case 2:n=l.right-o._thisNodeUt.width,n+=null!=i?o._thisNodeUt.width*i:o._rightGap,l=new T(n+o._contentUt.width,0,0);break;case 3:a=l.top,a+=null!=i?o._thisNodeUt.height*i:o._topGap,l=new T(0,-a,0);break;case 4:a=l.bottom+o._thisNodeUt.height,a-=null!=i?o._thisNodeUt.height*i:o._bottomGap,l=new T(0,-a+o._contentUt.height,0)}var r=o.content.getPosition();r=Math.abs(o._sizeType?r.y:r.x);var c=o._sizeType?l.y:l.x;Math.abs((null!=o._scrollPos?o._scrollPos:r)-c)>.5&&(o._scrollView.scrollToOffset(l,e),o._scrollToListId=t,o._scrollToEndTime=(new Date).getTime()/1e3+e,o._scrollToSo=o.scheduleOnce((function(){if(o._adheringBarrier||(o.adhering=o._adheringBarrier=!1),o._scrollPos=o._scrollToListId=o._scrollToEndTime=o._scrollToSo=null,s){var e=o.getItemByListId(t);e&&z(e).to(.1,{scale:1.05}).to(.1,{scale:1}).start()}}),e+.1),e<=0&&o._onScrolling())}},a._calcNearestItem=function(){var t,e,i,s,o,n,a=this;a.nearestListId=null,a._virtual&&a._calcViewPos(),i=a.viewTop,s=a.viewRight,o=a.viewBottom,n=a.viewLeft;for(var l=!1,r=0;r=n&&(a.nearestListId=t.id,n>e&&(a.nearestListId+=a._colLineNum),l=!0);break;case 2:t.left<=s&&(a.nearestListId=t.id,s=o&&(a.nearestListId=t.id,o>e&&(a.nearestListId+=a._colLineNum),l=!0)}if((t=a._virtual?a.displayData[a.displayItemNum-1]:a._calcExistItemPos(a._numItems-1))&&t.id==a._numItems-1)switch(e=a._sizeType?(t.top+t.bottom)/2:e=(t.left+t.right)/2,a._alignCalcType){case 1:s>e&&(a.nearestListId=t.id);break;case 2:ne&&(a.nearestListId=t.id)}},a.prePage=function(t){void 0===t&&(t=.5),this.checkInited()&&this.skipPage(this.curPageNum-1,t)},a.nextPage=function(t){void 0===t&&(t=.5),this.checkInited()&&this.skipPage(this.curPageNum+1,t)},a.skipPage=function(t,e){var i=this;if(i.checkInited())return i._slideMode!=zt.PAGE?console.error("This function is not allowed to be called, Must SlideMode = PAGE!"):void(t<0||t>=i._numItems||i.curPageNum!=t&&(i.curPageNum=t,i.pageChangeEvent&&u.emitEvents([i.pageChangeEvent],t),i.scrollTo(t,e)))},a.calcCustomSize=function(t){var e=this;if(e.checkInited()){if(!e._itemTmp)return console.error("Unset template item!");if(!e.renderEvent)return console.error("Unset Render-Event!");e._customSize={};var i=I(e._itemTmp),s=i.getComponent(f);e.content.addChild(i);for(var o=0;o=0&&t<=6&&(this._updateRate=t)}},{key:"selectedId",get:function(){return this._selectedId},set:function(t){var e,i=this;switch(i.selectedMode){case Dt.SINGLE:if(!i.repeatEventSingle&&t==i._selectedId)return;if(e=i.getItemByListId(t),i._selectedId>=0?i._lastSelectedId=i._selectedId:i._lastSelectedId=null,i._selectedId=t,e&&(e.getComponent(b).selected=!0),i._lastSelectedId>=0&&i._lastSelectedId!=i._selectedId){var s=i.getItemByListId(i._lastSelectedId);s&&(s.getComponent(b).selected=!1)}i.selectedEvent&&u.emitEvents([i.selectedEvent],e,t%this._actualNumItems,null==i._lastSelectedId?null:i._lastSelectedId%this._actualNumItems);break;case Dt.MULT:if(!(e=i.getItemByListId(t)))return;var o=e.getComponent(b);i._selectedId>=0&&(i._lastSelectedId=i._selectedId),i._selectedId=t;var n=!o.selected;o.selected=n;var a=i.multSelected.indexOf(t);n&&a<0?i.multSelected.push(t):!n&&a>=0&&i.multSelected.splice(a,1),i.selectedEvent&&u.emitEvents([i.selectedEvent],e,t%this._actualNumItems,null==i._lastSelectedId?null:i._lastSelectedId%this._actualNumItems,n)}}},{key:"numItems",get:function(){return this._actualNumItems},set:function(t){var e=this;if(e.checkInited(!1))if(null==t||t<0)console.error("numItems set the wrong::",t);else if(e._actualNumItems=e._numItems=t,e._forceUpdate=!0,e._virtual)e._resizeContent(),e.cyclic&&(e._numItems=e._cyclicNum*e._numItems),e._onScrolling(),e.frameByFrameRenderNum||e.slideMode!=zt.PAGE||(e.curPageNum=e.nearestListId);else{e.cyclic&&(e._resizeContent(),e._numItems=e._cyclicNum*e._numItems);var i=e.content.getComponent(v);if(i&&(i.enabled=!0),e._delRedundantItem(),e.firstListId=0,e.frameByFrameRenderNum>0){for(var s=e.frameByFrameRenderNum>e._numItems?e._numItems:e.frameByFrameRenderNum,o=0;oV.NONE}}),F=A({type:u,tooltip:v,visible:function(){return this.selectedMode==V.SWITCH}}),z=A({tooltip:v}),O(N=y(N=C(N=w((k=t((T=function(e){function t(){for(var t,i=arguments.length,r=new Array(i),s=0;s0&&this.btnCom.clickEvents.unshift(this.createEvt(this,"onClickThis")),this.adaptiveSize&&this.node.on(c.EventType.SIZE_CHANGED,this._onSizeChange,this),this._eventReg=!0)},s._onSizeChange=function(){this.list._onItemAdaptive(this.node)},s.createEvt=function(e,t,i){if(void 0===i&&(i=null),e.isValid){e.comName=e.comName||e.name.match(/\<(.*?)\>/g).pop().replace(/\<|>/g,"");var n=new p;return n.target=i||e.node,n.component=e.comName,n.handler=t,n}},s.showAni=function(e,t,i){var n,o=this,r=o.node.getComponent(h);switch(e){case 0:n=f(o.node).to(.2,{scale:new m(.7,.7)}).by(.3,{position:new m(0,2*r.height)});break;case 1:n=f(o.node).to(.2,{scale:new m(.7,.7)}).by(.3,{position:new m(2*r.width,0)});break;case 2:n=f(o.node).to(.2,{scale:new m(.7,.7)}).by(.3,{position:new m(0,-2*r.height)});break;case 3:n=f(o.node).to(.2,{scale:new m(.7,.7)}).by(.3,{position:new m(-2*r.width,0)});break;default:n=f(o.node).to(.3,{scale:new m(.1,.1)})}(t||i)&&n.call((function(){if(i){o.list._delSingleItem(o.node);for(var e=o.list.displayData.length-1;e>=0;e--)if(o.list.displayData[e].id==o.listId){o.list.displayData.splice(e,1);break}}t()})),n.start()},s.onClickThis=function(){this.list.selectedId=this.listId},r(t,[{key:"selected",get:function(){return this._selected},set:function(e){if(this._selected=e,this.selectedFlag)switch(this.selectedMode){case V.TOGGLE:this.selectedFlag.active=e;break;case V.SWITCH:var t=this.selectedFlag.getComponent(a);t&&(t.spriteFrame=e?this.selectedSpriteFrame:this._unselectedSpriteFrame)}}},{key:"btnCom",get:function(){return this._btnCom||(this._btnCom=this.node.getComponent(b)),this._btnCom}}]),t}(g)).prototype,"icon",[_],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return null}}),D=t(T.prototype,"title",[S],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return null}}),H=t(T.prototype,"selectedMode",[E],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return V.NONE}}),L=t(T.prototype,"selectedFlag",[I],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return null}}),M=t(T.prototype,"selectedSpriteFrame",[F],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return null}}),G=t(T.prototype,"adaptiveSize",[z],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return!1}}),N=T))||N)||N)||N)||N));s._RF.pop()}}})); System.register("chunks:///_virtual/LocalStorageUtil.ts",["cc"],(function(t){var e,r;return{setters:[function(t){e=t.cclegacy,r=t.sys}],execute:function(){e._RF.push({},"d8e88J+Q9RPtY3fFaop4Z7i","LocalStorageUtil",void 0),t("LocalStorageUtil",function(){function t(){this.temporary=void 0,this._user_id=void 0,this.temporary=new Map}t.getInstance=function(){return this._inst||(this._inst=new t),this._inst};var e=t.prototype;return e.setUserId=function(t){this._user_id=t},e.set=function(t,e){if("object"==typeof e)try{e=JSON.stringify(e)}catch(t){return void console.error("解析失败,str = "+e)}else"number"==typeof e&&(e+="");return this._user_id?r.localStorage.setItem(this._user_id+"_"+t,e):r.localStorage.setItem(t,e),e},e.get=function(t){return null==t?(console.error("存储的key不能为空"),null):(e=this._user_id?r.localStorage.getItem(this._user_id+"_"+t):r.localStorage.getItem(t))?e:void 0;var e},e.getNumber=function(t,e){void 0===e&&(e=0);var r=this.get(t);return"0"==r?Number(r):Number(r)||e},e.getBoolean=function(t){var e=this.get(t);return Boolean(e)||!1},e.getJson=function(t,e){var r=this.get(t);return r&&JSON.parse(r)||e},e.getObject=function(t){var e=this.get(t);try{return JSON.parse(e)}catch(t){return e}},e.removeNormalObject=function(t){r.localStorage.removeItem(t)},e.setNormalObject=function(t,e){return r.localStorage.setItem(t,JSON.stringify(e)),e},e.getNormalObject=function(t){var e;if(e=r.localStorage.getItem(t))try{return JSON.parse(e)}catch(t){return e}},e.removeObject=function(t){r.localStorage.removeItem(t)},e.setTempObject=function(t,e){this.temporary.set(t,e)},e.getTempObject=function(t){return this.temporary.get(t)},e.removeTempObject=function(t){this.temporary.delete(t)},t}())._inst=void 0,e._RF.pop()}}})); System.register("chunks:///_virtual/main",["./ModuleDef.ts","./SceneDef.ts","./audio.ts","./ch.ts","./ch_util.ts","./NetBase.ts","./NetPlayer.ts","./NetRoom.ts","./NetTeam.ts","./WsClient.ts","./net.ts","./ch_pvp.ts","./sign.ts","./ch_sdk_comp.ts","./ch_start_pack.ts","./ui.ts","./ui_ResolutionAutoFit.ts","./ui_base.ts","./ArrayUtil.ts","./DataTimeUtil.ts","./DirectorUtil.ts","./Instance.ts","./LocalStorageUtil.ts","./MathUtil.ts","./PathUtil.ts","./ProjectileMathUtil.ts","./ResUtil.ts","./StringUtil.ts","./TableLoadUtil.ts","./UrlUtil.ts","./Utils.ts","./Action.ts","./Container.ts","./Delay.ts","./FMS.ts","./GameData.ts","./HeadIcon.ts","./Line2DMove.ts","./PeriodData.ts","./PrefabPool.ts","./Queue.ts","./Random.ts","./SafeNumber.ts","./Shake.ts","./State.ts","./TimeJobCenter.ts","./Timer.ts","./Toast.ts","./Wait.ts","./ClickPenetrate.ts","./Game.ts","./List.ts","./ListItem.ts","./MotionTrail.ts","./MovieClip.ts","./RewardFly.ts","./SpineView.ts","./UISpineMovie.ts","./Start.ts"],(function(){return{setters:[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null],execute:function(){}}})); System.register("chunks:///_virtual/MathUtil.ts",["./rollupPluginModLoBabelHelpers.js","cc"],(function(n){var t,e,r,i,a;return{setters:[function(n){t=n.createClass},function(n){e=n.cclegacy,r=n.Vec3,i=n.Vec2,a=n.misc}],execute:function(){e._RF.push({},"5df23qNkJ5Jco4b72bZLJJf","MathUtil",void 0);var o=new r,x=180/Math.PI,y=Math.PI/180;n("MathUtil",function(){function n(){}return n.radiansToDegrees=function(n){return n*x},n.degreesToRadians=function(n){return n*y},n.Clamp=function(n,t,e){return ne&&(n=e),n},n.Clamp01=function(n){return this.Clamp(n,0,1)},n.PingPong=function(n,t){return n=this.Repeat(n,2*t),t-Math.abs(n-t)},n.Repeat=function(n,t){return n-Math.floor(n/t)*t},n.Round=function(n){return Math.floor(n+.5)},n.Sign=function(n){return n=n>0?1:n<0?-1:0},n.InverseLerp=function(n,t,e){return nt?1:(e-=n,e/=t-n):n<=t?0:en?0:1-(e-t)/(n-t)},n.Lerp=function(n,t,e){return n+(t-n)*this.Clamp01(e)},n.LerpUnclamped=function(n,t,e){return n+(t-n)*e},n.DeltaAngle=function(n,t){var e=this.Repeat(t-n,360);return e>180&&(e-=360),e},n.LerpAngle=function(n,t,e){var r=this.Repeat(t-n,360);return r>180&&(r-=360),n+r*this.Clamp01(e)},n.smoothStep=function(n,t,e){return t*(e=-2*(e=this.Clamp01(e))*e*e+3*e*e)+n*(1-e)},n.smoothDamp=function(n,t,e,r,i,a){void 0===a&&(a=Number.POSITIVE_INFINITY);var o=2/(r=Math.max(1e-4,r)),x=o*i,y=1/(1+x+.47999998927116394*x*x+.23499999940395355*x*x*x),u=n-t,s=t,c=a*r,M=this.Clamp(u,-c,c),h=(e+o*M)*i,f=(e-o*h)*y,l=(t=n-M)+(M+h)*y;return s-n>0==l>s&&(f=((l=s)-s)/i),{value:l,velocity:f}},n.getPerpendicular=function(n){return new i(-n.y,n.x).normalize()},n.angleToVector=function(n){return this.zore.clone().rotate(-a.degreesToRadians(n))},n.vectorToAngle=function(n){return-a.radiansToDegrees(n.signAngle(this.zore))},n.angle_to_vector=function(n){var t=this.degreesToRadians(n),e=Math.cos(t),r=Math.sin(t);return new i(e,r).normalize()},n.vector_to_angle=function(n){var t=n.signAngle(this.zore);return-this.radiansToDegrees(t)},n.vector_to_radian=function(n){return n.signAngle(this.zore)},n.RotationMatrix=function(n,t,e){var r=this.degreesToRadians(e),a=Math.sin(r),o=Math.cos(r);return new i(n*o+t*a,n*-a+t*o)},n.RotationDir=function(n,t){var e=this.radiansToDegrees(t),r=Math.sin(e),i=Math.cos(e),a=n.x*i+n.y*r,o=n.x*-r+n.y*i;return n.x=a,n.y=o,n},n.CheckInView=function(n,t,e,r,a){if(i.distance(n,e)=360)return!0;var o=e.subtract(n).normalize();if(this.radiansToDegrees(i.angle(t,o))<=.5*a)return!0}return!1},n.InConvexQuad=function(n,t,e,r,i){var a,o;return a.x=e.x-t.x,a.y=e.y-t.y,o.x=n.x-t.x,o.y=n.y-t.y,!this.cross2DPoint(o.x,o.y,a.x,a.y)&&(a.x=r.x-e.x,a.y=r.y-e.y,o.x=n.x-e.x,o.y=n.y-e.y,!this.cross2DPoint(o.x,o.y,a.x,a.y)&&(a.x=i.x-r.x,a.y=i.y-r.y,o.x=n.x-r.x,o.y=n.y-r.y,!this.cross2DPoint(o.x,o.y,a.x,a.y)&&(a.x=t.x-i.x,a.y=t.y-i.y,o.x=n.x-i.x,o.y=n.y-i.y,!this.cross2DPoint(o.x,o.y,a.x,a.y))))},n.cross2DPoint=function(n,t,e,r){return n*r-e*t},n.AABBAABB2D=function(n,t,e,r,i,a,o,x){return!(Math.abs(n-i)>e+o)&&!(Math.abs(t-a)>r+x)},n.AABBAABB3D=function(n,t,e,r,i,a,o,x,y,u,s,c){return!(Math.abs(n-o)>r+u)&&(!(Math.abs(t-x)>i+s)&&!(Math.abs(e-y)>a+c))},n.pointPoint=function(n,t){return n.x==t.x&&n.y==t.y},n.onSegement=function(n,t,e){var r,i,a,o;return r=t.x>e.x?t.x:e.x,i=t.x>e.x?e.x:t.x,a=t.y>e.y?t.y:e.y,o=t.y>e.y?e.y:t.y,(n.x-t.x)*(e.y-t.y)==(e.x-t.x)*(n.y-t.y)&&n.x>=i&&n.x<=r&&n.y>=o&&n.y<=a},n.pointInCircle=function(n,t,e){return i.squaredDistance(n,t)<=e*e},n.pointInRect=function(n,t){return n.x>=t.x&&n.x<=t.x+t.width&&n.y>=t.y&&n.y<=t.y+t.height},n.lineInRect=function(n,t,e){var r=n.y-t.y,i=t.x-n.x,a=n.x*t.y-t.x-n.y;return(r*e.xMin+i*e.yMin+a>=0&&r*e.xMax+i*e.yMax+a<=0||r*e.xMin+i*e.yMin+a<=0&&r*e.xMax+i*e.yMax+a>=0||r*e.xMin+i*e.yMax+a>=0&&r*e.xMax+i*e.yMin+a<=0||r*e.xMin+i*e.yMax+a<=0&&r*e.xMax+i*e.yMin+a>=0)&&!(n.xe.xMax&&t.x>e.xMax||n.y>e.yMin&&t.y>e.yMin||n.yi||r>a)},n.collisionRectWithCircle=function(n,t,e){var r=n.xMin,a=n.yMin,o=n.xMax,x=n.yMax,y=i.distance(t,new i(r,a)),u=i.distance(t,new i(r,x)),s=i.distance(t,new i(o,a)),c=i.distance(t,new i(o,x));return yr-e&&t.xa&&t.yr&&t.xa-e&&t.y0)for(var r=0;r0;--r){var i=t[r],o=t[r-1];i.x=o.x,i.y=o.y,i.sin=o.sin,i.cos=o.cos}var a=null;a=e.isWorldXY?e.node.worldPosition:e.node.position;var n=t[0];n.x=e.offset.x+a.x,n.y=e.offset.y+a.y;var s=t[1],l=Math.atan2(s.y-n.y,s.x-n.x);n.sin=Math.sin(l),n.cos=Math.cos(l)}},updateOpacity:function(e,t){for(var r,i,o=e.renderData,a=o.chunk.vb,n=4+2*(e.length-2),s=e.length,l=-1,u=5,p=0;pe?e:t},i}(b)).prototype,"interval",[g],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return.1}}),S=i(L.prototype,"texture",[w],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return null}}),W=i(L.prototype,"playTimes",[x],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return 0}}),M=i(L.prototype,"row",[I],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return 4}}),B=i(L.prototype,"col",[T],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return 4}}),O=i(L.prototype,"rowIndex",[v],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return 0}}),R=i(L.prototype,"isAll",[z],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return!1}}),N=i(L.prototype,"autoPlayOnLoad",[A],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return!0}}),V=i(L.prototype,"autoDestroy",[F],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return!1}}),Y=i(L.prototype,"begin",[C],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return 0}}),j=i(L.prototype,"end",[D],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return 0}}),H=L))||H));s._RF.pop()}}})); System.register("chunks:///_virtual/net.ts",["./rollupPluginModLoBabelHelpers.js","cc","./NetRoom.ts","./NetTeam.ts","./WsClient.ts"],(function(t){var e,n,s,a,i,r,o;return{setters:[function(t){e=t.createClass,n=t.asyncToGenerator,s=t.regeneratorRuntime},function(t){a=t.cclegacy},function(t){i=t.NetRoom},function(t){r=t.NetTeam},function(t){o=t.WsClient}],execute:function(){a._RF.push({},"3f10au8XnFG2b0ZjXy1nl0i","net",void 0);var c="pong",h="c2s_update_user_gameData",u="c2s_message",_="c2s_talk";t("ch_net",function(){var t=a.prototype;function a(){this.state=chsdk.get_new_event(),this._ws=null,this._url=void 0,this._ca=void 0,this.reconnection=void 0,this.reconnectCount=void 0,this.reconnectInterval=void 0,this.timeoutInterval=void 0,this.gameDataInterval=void 0,this.gameEvtInterval=void 0,this.timeout=null,this.json=!1,this.heartbeatInterval=null,this.dirtyDataCheckInterval=null,this.evtCheckInterval=null,this._currentReconnectCount=0,this._pingTime=0,this._ping=0,this._callbacks={},this._waitSends=[],this._lv={LowerRank:0,Rank:0,Star:0},this._team=void 0,this._room=void 0,this._waitSends=[],this._callbacks={}}return t._new_resolve=function(t){var e=this;return new Promise((function(n){return e._callbacks[t]=n}))},t._do_resolve=function(t,e){var n=this._callbacks[t];return!!n&&(n(e),delete this._callbacks[t],!0)},t.init=function(t,e){var n,s,a,i,r,c,h,u;this._url=t,this._url=this._url+(null!=e&&null!=(n=e.query)&&n.length?"?"+e.query:""),this._ca=null==e?void 0:e.ca,this.reconnection=null==(s=null==e?void 0:e.reconnection)||s,this.reconnectCount=null!=(a=null==e?void 0:e.reconnectCount)?a:10,this.reconnectInterval=null!=(i=null==e?void 0:e.reconnectInterval)?i:2e3,this.timeoutInterval=null!=(r=null==e?void 0:e.timeoutInterval)?r:3e4,this.gameDataInterval=null!=(c=null==e?void 0:e.gameDataInterval)?c:200,this.gameEvtInterval=null!=(h=null==e?void 0:e.gameEvtInterval)?h:66,this.json=null!=(u=null==e?void 0:e.json)&&u,this._ws=new o(this._url,this._ca),this._ws.onConnected=this._onConnected.bind(this),this._ws.onError=this._onError.bind(this),this._ws.onClosing=this._onClosing.bind(this),this._ws.onClosed=this._onClosed.bind(this),this._ws.onMessage=this._onMessage.bind(this);var _="undefined"!=typeof ArrayBuffer;console.log("ch_net 初始化 ver:","0.1.8",_,this.json,this._url),chsdk.sdk_event.on("hide",this.on_hide,this),chsdk.sdk_event.on("show",this.on_show,this)},t.dispose=function(){this.state.clearAll(),this._clear_team(),this._clear_room(),this._callbacks={},this._waitSends.length=0,this._ws.close(5e3,"client disconnect"),chsdk.sdk_event.off("hide",this.on_hide,this),chsdk.sdk_event.off("show",this.on_show,this)},t.on_hide=function(){this.inRoom&&this.send_data("c2s_to_backed")},t.on_show=function(){this.inRoom&&this.send_data("c2s_backed_return")},t.encode=function(t){return this.json?JSON.stringify(t):msgpack.encode(t)},t.decode=function(t){return function(t){try{return t instanceof ArrayBuffer}catch(t){return!1}}(t)?msgpack.decode(new Uint8Array(t)):JSON.parse(t)},t.send_data=function(t,e){this._send(this.encode(e?{type:t,data:e}:{type:t}))},t.connect=function(){var t=n(s().mark((function t(){return s().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(this._ws){t.next=3;break}return chsdk.log.error("not init"),t.abrupt("return","not init");case 3:if(this._ws.connect()){t.next=5;break}return t.abrupt("return","no netconnect");case 5:return this.state.emit(this.state.key.Connecting),t.abrupt("return",this._new_resolve("connect"));case 7:case"end":return t.stop()}}),t,this)})));return function(){return t.apply(this,arguments)}}(),t.reconnect=function(){if(!this._ws)return chsdk.log.error("not init"),"not init";this._currentReconnectCount=1,this.do_reconnect()},t.do_reconnect=function(){this._ws.connect()&&this.state.emit(this.state.key.Reconnecting,this._currentReconnectCount)},t.creat_team=function(){var t=n(s().mark((function t(e){return s().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(void 0===e&&(e=4),this._ws){t.next=3;break}return t.abrupt("return","no netconnect");case 3:if(!this.inTeam){t.next=5;break}return t.abrupt("return",null);case 5:return this.send_data("c2s_set_team",e),t.abrupt("return",this._new_resolve("creat_team"));case 7:case"end":return t.stop()}}),t,this)})));return function(e){return t.apply(this,arguments)}}(),t.join_team=function(){var t=n(s().mark((function t(e){return s().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(this._ws){t.next=2;break}return t.abrupt("return","no netconnect");case 2:if(!this.inTeam){t.next=4;break}return t.abrupt("return",null);case 4:return this.send_data("c2s_join_team",{password:e}),t.abrupt("return",this._new_resolve("join_team"));case 6:case"end":return t.stop()}}),t,this)})));return function(e){return t.apply(this,arguments)}}(),t.exit_team=function(){var t=n(s().mark((function t(){return s().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(this._ws){t.next=2;break}return t.abrupt("return","no netconnect");case 2:if(this.inTeam){t.next=4;break}return t.abrupt("return","not in team");case 4:if(!this.inRoom){t.next=6;break}return t.abrupt("return","in game");case 6:return this.send_data("c2s_exit_team"),t.abrupt("return",this._new_resolve("exit_team"));case 8:case"end":return t.stop()}}),t,this)})));return function(){return t.apply(this,arguments)}}(),t.close_room=function(){this._ws&&this.inRoom&&this.room.isHost&&this.send_data("c2s_close_room")},t.exit_room=function(){var t=n(s().mark((function t(){return s().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(this._ws){t.next=2;break}return t.abrupt("return","no netconnect");case 2:if(this.inRoom){t.next=4;break}return t.abrupt("return","not in room");case 4:return this.send_data("c2s_room_exit"),t.abrupt("return",this._new_resolve("exit_room"));case 6:case"end":return t.stop()}}),t,this)})));return function(){return t.apply(this,arguments)}}(),t._clear_team=function(){var t;null==(t=this._team)||t.dispose(),this._team=null},t._clear_room=function(){var t;this._room&&(null==(t=this._room)||t.dispose(),this._room=null)},t._send=function(t){this._ws&&(this._ws.isActive?this._ws.send(t):this._waitSends.push(t))},t._updatePlayerStatus=function(t,e){this.inTeam&&this._team.updatePlayerStatus(t,e),this.inRoom&&this._room.updatePlayerStatus(t,e)},t._onMessage=function(t){this.resetHeartbeat();try{var e=t.data,n=this.decode(e);switch(n.type!==c&&chsdk.log.log("receive",JSON.stringify(n)),n.type){case c:this._ping=chsdk.date.now()-this._pingTime,chsdk.date.updateServerTime(n.data);break;case"s2c_login_success":for(this._lv=n.data,this._do_resolve("connect",null)?this.state.emit(this.state.key.Connected):this.state.emit(this.state.key.Reconnected),this._callbacks={},this.startHeartbeat();this._waitSends.length&&this._ws;){var s=this._waitSends.shift();s&&this._ws.send(s)}break;case"s2c_team_success":this._team&&this._clear_team(),this._team=new r(n.data,this.send_data.bind(this)),this._do_resolve("creat_team",null)||this._do_resolve("join_team",null);break;case"s2c_join_team_fail":this._do_resolve("join_team",n.data);break;case"s2c_team_user_join":var a=n.data;a.status=!0,this._team.addPlayer({key:a.userKey,data:a},!0);break;case"s2c_team_user_exit":var o=n.data;o===this._team.own.Id?(this._team.closed(),this._clear_team(),this._do_resolve("exit_team",null)):this._team.removePlayer(o);break;case"s2c_team_change_host":this._team.changeHost(n.data);break;case"s2c_room_change_host":this._room.changeHost(n.data);break;case"s2c_user_reconnect":this._updatePlayerStatus(n.data,!0);break;case"s2c_user_disconnect":this._updatePlayerStatus(n.data,!1);break;case"s2c_match":this._team.match_start();break;case"s2c_match_cancel":this._team.match_cancel();break;case"s2c_not_ready":this._team.not_ready();break;case"s2c_ready":this._team.updatePlayerReady(n.data,!0);break;case"s2c_match_success":this._clear_room();var h=n.data.roomData,_=n.data.playerData;this._room=new i(h,_),this._team&&this._team.match_success();break;case"s2c_room_gameData_change":this._room.server_change(n.data);break;case"s2c_user_gameData_change":var l=this._room.getPlayer(n.data.userKey);if(!l)break;l.server_change(n.data.data);break;case"s2c_room_closed":if(this._room.closed(n.data),this.inTeam)for(var d=this.room.all,m=0;m4e3)return this.state.emit(this.state.key.Closed,t),this._do_resolve("connect",t),void chsdk.log.log("WebSocket connection closed",t);this._currentReconnectCount0&&t.send_data(u,e),n.length>0&&t.send_data("c2s_message_to_host",n),s.length>0&&t.send_data("c2s_message_without_self",s)}));for(var e=this.room.all,n=function(){var n=e[s];n.doFinishGame((function(){t.send_data("c2s_finish",n.Id)}))},s=0;s=0&&i.location1&&this._results.sort((function(t,e){return 0===t.Rank&&0===e.Rank?0:0===t.Rank?1:0===e.Rank?-1:t.Rank-e.Rank})),this.evt._emit("r_closed")},n.finish=function(t,e){var i=this.getPlayer(t);i&&(i.setFinish(e),this.evt._emit("r_finish",t,e))},n.sendEvt=function(t){if(this._status){for(var e=arguments.length,i=new Array(e>1?e-1:0),s=1;s1?e-1:0),s=1;s1?e-1:0),s=1;s=0&&i.location0&&(e=e.substring(0,n));var r=/(\/|\\)([^\/\\]+)$/g.exec(e.replace(/(\/|\\)$/,""));if(!r)return e;var u=r[2];return t&&e.substring(e.length-t.length).toLowerCase()===t.toLowerCase()?u.substring(0,u.length-t.length):u},e.dirname=function(e){var t=/((.*)(\/|\\|\\\\))?(.*?\..*$)?/.exec(e);return t?t[2]:""},e}());t._RF.pop()}}})); System.register("chunks:///_virtual/PeriodData.ts",["./rollupPluginModLoBabelHelpers.js","cc"],(function(t){var e,a;return{setters:[function(t){e=t.createForOfIteratorHelperLoose},function(t){a=t.cclegacy}],execute:function(){a._RF.push({},"6e040Hgcc1C2r4oXdDQnwvy","PeriodData",void 0);var n=t("PeriodDataUpdate",function(t){return t[t.none=0]="none",t[t.day=1]="day",t[t.week=2]="week",t[t.month=3]="month",t}({}));t("default",function(){function t(t,e){var a=this;this._data=new Map,this._data_Array=new Map,this._last=0,this._update=void 0,this._update=t,e&&e.forEach((function(t,e){var n;a._data.set(e,{v:null!=(n=t.min)?n:0,min:t.min,max:t.max})}),this)}var a=t.prototype;return a.serialize=function(){var t={};this._data.forEach((function(e,a){t[String(a)]=e.v}));var e={};return this._data_Array.forEach((function(t,a){e[String(a)]=t})),{last:this._last,data:t,data_Array:e}},a.unserialize=function(t){var e;if(t){this._last=null!=(e=t.last)?e:0;var a=t.data;if(a)for(var n in a){var r=a[n];this._get(n).v=r}var i=t.data_Array;if(i)for(var s in i){var u=i[s];this.set_Array(s,u)}}},a._get=function(t){var e=this._data.get(t);return e||(e={v:0,min:0,max:null},this._data.set(t,e)),e},a._get_Array=function(t){var e=this._data_Array.get(t);return console.log("_get_Array called with key: "+String(t)+"data:",e),e||(e=new Array(5).fill(!1),this._data_Array.set(t,e)),e},a.set=function(t,e,a,n){var r=this._get(t);r.v=e,r.min=a,r.max=n},a.get=function(t){return this._get(t).v},a.set_Array=function(t,e){this._data_Array.set(t,e)},a.get_Array=function(t){return this._get_Array(t)},a.get_available=function(t){var e=this._get(t);return e.max?e.max-e.v:e.v},a.isEnble=function(t){return this._get(t).v>0},a.enble=function(t){this._get(t).v=1},a.disEnble=function(t){this._get(t).v=0},a.add=function(t,e){return void 0===e&&(e=1),this.change(t,e)},a.sub=function(t,e){return void 0===e&&(e=1),this.change(t,-e)},a.change=function(t,e){var a=this._get(t);return a?(a.v+=e,a.min&&a.va.max&&(a.v=a.max),a.v):null},a.change_big=function(t,e){var a=this._get(t);return a&&e>a.v?(a.v=e,a.min&&a.va.max&&(a.v=a.max),a.v):null},a.change_sm=function(t,e){var a=this._get(t);return a&&ea.max&&(a.v=a.max),a.v):null},a.check=function(t){return this._update!=n.none&&(this._update!=n.day||this.isSameDate(t,this._last)?this._update!=n.week||this.areDatesInSameWeek(t,this._last)?this._update==n.month&&!this.areDatesInSameMonth(t,this._last)&&(this._last=t,this.reset(),!0):(this._last=t,this.reset(),this._data_Array=new Map,!0):(this._last=t,this.reset(),!0))},a.reset=function(){for(var t,a=e(this._data.keys());!(t=a()).done;){var n,r=t.value,i=this._get(r);i.v=null!=(n=i.min)?n:0}for(var s,u=e(this._data_Array.keys());!(s=u()).done;){var o=s.value;this._data_Array.set(o,new Array(5).fill(!1))}},a.isSameDate=function(t,e){var a=new Date(t),n=new Date(e);return a.getFullYear()==n.getFullYear()&&a.getMonth()==n.getMonth()&&a.getDate()==n.getDate()},a.areDatesInSameWeek=function(t,e){var a=this.getStartOfWeek(new Date(t)),n=this.getStartOfWeek(new Date(e));return a.getTime()===n.getTime()},a.getStartOfWeek=function(t){var e=new Date(t),a=e.getDay(),n=e.getDate()-a;return e.setDate(n),e.setHours(0,0,0,0),e},a.areDatesInSameMonth=function(t,e){var a=new Date(t),n=new Date(e);return a.getFullYear()===n.getFullYear()&&a.getMonth()===n.getMonth()},t}());a._RF.pop()}}})); System.register("chunks:///_virtual/PrefabPool.ts",["cc"],(function(e){var t,o,n,i;return{setters:[function(e){t=e.cclegacy,o=e.Node,n=e.NodePool,i=e.instantiate}],execute:function(){e("default",(function(){return new r})),t._RF.push({},"12f30kX+ltO4JZlGRue34gE","PrefabPool",void 0);var r=function(){function e(){this._pools=new Map,this._node=void 0,null==this._node&&(this._node=new o,this._node.active=!1)}var t=e.prototype;return t.getPool=function(e){var t=this._pools.get(e);return null==t&&(t=new n,this._pools.set(e,t)),t},t.GetNode=function(e){var t=this.getPool(e.name).get();return t||((t=i(e)).name=e.name),t},t.RecNode=function(e){e.parent=this._node,this.getPool(e.name).put(e)},t.InitPool=function(e,t){void 0===t&&(t=10);for(var o=this.getPool(e.name),n=0;n0)this.items[--this.lowestCount]=t;else{for(var i=this.count;i>this.lowestCount;i--)this.items[i]=this.items[i-1];this.count++,this.items[0]=t}return this.size()},i.getTail=function(){if(!this.isEmpty()){this.count--;var t=this.items[this.count];return delete this.items[this.count],t}},i.getHead=function(){if(!this.isEmpty()){var t=this.items[this.lowestCount];return delete this.items[this.lowestCount],this.lowestCount++,t}},i.peekHead=function(){if(!this.isEmpty())return this.items[this.lowestCount]},i.peekTail=function(){if(!this.isEmpty())return this.items[this.count-1]},i.size=function(){return this.count-this.lowestCount},i.isEmpty=function(){return 0===this.size()},i.clear=function(){this.items={},this.count=this.lowestCount=0},i.toString=function(){if(this.isEmpty())return"";for(var t=this.items[this.lowestCount].toString(),i=this.lowestCount+1;i=n.length)return n;e=Math.min(e,n.length-1);for(var s=0;s1e-6&&(this.map[this.idx]=this.cache/this.scale),this.map[this.idx]},set:function(t){delete this.map[this.idx],this.idx=Math.floor(256*Math.random()),this.map[this.idx]=t,this.scale=Math.floor(2*Math.random())+2,this.cache=t*this.scale}}]),t}(),a=function(){function t(t){void 0===t&&(t=0),this.cache=0,this.scale=2,this.map={},this.idx=0,this.idx=Math.floor(256*Math.random()),this.map[this.idx]=t,this.scale=Math.floor(2*Math.random())+2,this.cache=t*this.scale}var e=t.prototype;return e.valueOf=function(){return this.value},e.toString=function(){return this.value.toString()},e.clone=function(){return new t(this.value)},i(t,[{key:"value",get:function(){var t=this.map[this.idx];return Math.abs(t*this.scale-this.cache)>1e-6&&(t=this.cache/this.scale),delete this.map[this.idx],this.idx=Math.floor(256*Math.random()),this.map[this.idx]=t,this.map[this.idx]}}]),t}();e._RF.pop()}}})); System.register("chunks:///_virtual/SceneDef.ts",["cc"],(function(e){var c;return{setters:[function(e){c=e.cclegacy}],execute:function(){c._RF.push({},"01aa7QePwpMF4PE+VsC8QVh","SceneDef",void 0);var t=e("SceneDef",(function(){}));t.START="start",t.GAME="game",t.Hall="hall",c._RF.pop()}}})); System.register("chunks:///_virtual/Shake.ts",["cc"],(function(t){var s,i;return{setters:[function(t){s=t.Vec3,i=t.cclegacy}],execute:function(){t("default",(function(t){void 0===t&&(t=new s(0,0,0));return new n(t)})),i._RF.push({},"88adahxArtIPKhtXnEB29+o","Shake",void 0);var n=function(){function t(t){void 0===t&&(t=new s(0,0,0)),this.intensity=void 0,this.duration=void 0,this.shakePos=new s(0,0,0),this.startPos=t,this.duration=0,this.intensity=0}var i=t.prototype;return i.setStartPos=function(t,s){this.startPos.x=t,this.startPos.y=s},i.start=function(t,s){void 0===t&&(t=.3),void 0===s&&(s=3.8),this.duration=t,this.intensity=s},i.stop=function(){return this.shakePos.x=this.startPos.x,this.shakePos.y=this.startPos.y,this.duration=0,this.shakePos},i.getShakePos=function(){return this.shakePos},i.action=function(t){if(this.duration>0){if(this.duration-=t,this.duration<=0)return this.stop();var s=Math.random()*this.intensity-.5*this.intensity,i=Math.random()*this.intensity-.5*this.intensity;return this.shakePos.x=this.startPos.x+s,this.shakePos.y=this.startPos.y+i,this.shakePos}return null},t}();i._RF.pop()}}})); System.register("chunks:///_virtual/sign.ts",["./rollupPluginModLoBabelHelpers.js","cc"],(function(t){var i,n;return{setters:[function(t){i=t.createClass},function(t){n=t.cclegacy}],execute:function(){n._RF.push({},"6d031yryKRLYaiOHaXKh4Av","sign",void 0),t("default",function(){function t(){this._sign_data=new Set,this._max=7,this._creat_date=0,this._sign_count=0,this._mode=1}t.getInstance=function(){return this._instance||(this._instance=new t),this._instance};var n=t.prototype;return n.getCreatDayCount=function(){return 0==this._creat_date?(chsdk.log.warn("签到模块没有初始化"),0):chsdk.date.getDiffDayNum(this._creat_date,chsdk.date.now())+1},n.init=function(t,i,n){var s,e;if(void 0===n&&(n=7),this._mode=t,1==this._mode)if(i){for(var a,_,r=null!=(a=(i=i).sign_list)?a:[],h=null!=(_=i.creat_date)?_:chsdk.date.now(),c=0;cthis._max)return 0;if(this._sign_data.has(t))return 1;var i=this.getCreatDayCount();if(i<=0)return 0;if(tthis._max)&&!this._sign_data.has(t)}return 2==this._mode&&(!(this._sign_count>=this._max)&&!chsdk.date.isSameDate(this._creat_date,chsdk.date.now()))},n.checkSiginComplete=function(){return this._sign_count>=this._max},n.checkReSigin=function(){if(1!=this._mode)return 0;var t=this.getCreatDayCount()-1;if(t<=0)return 0;t>this._max&&(t=this._max);for(var i=1;i<=t;i++)if(!this._sign_data.has(i))return i;return 0},n.signIn=function(){if(!this.checkSigin())return 0;if(1==this._mode){var t=this.getCreatDayCount();return this._sign_data.add(t),this._sign_count=this._sign_data.size,t}return 2==this._mode?(this._sign_count++,this._creat_date=chsdk.date.now(),this._sign_count):0},n.reSignIn=function(){if(1!=this._mode)return 0;var t=this.checkReSigin();return t<=0||t>this._max?0:(this._sign_data.add(t),this._sign_count=this._sign_data.size,t)},i(t,[{key:"max_day",get:function(){return this._max}}]),t}())._instance=void 0,n._RF.pop()}}})); System.register("chunks:///_virtual/SpineView.ts",["./rollupPluginModLoBabelHelpers.js","cc"],(function(e){var n,t,i,o,s,r,a,l,h,c;return{setters:[function(e){n=e.applyDecoratedDescriptor,t=e.inheritsLoose,i=e.initializerDefineProperty,o=e.assertThisInitialized},function(e){s=e.cclegacy,r=e._decorator,a=e.sp,l=e.Color,h=e.sys,c=e.Component}],execute:function(){var u,p,C,f,d,g,m;s._RF.push({},"ce889T62SpI8ot39/O0nFrT","SpineView",void 0);var v=r.ccclass,A=r.property;e("default",(u=v("SpineView"),p=A({displayName:"待机"}),C=A({type:a.Skeleton,tooltip:"角色动画"}),u((g=n((d=function(e){function n(){for(var n,t=arguments.length,s=new Array(t),r=0;r0&&(this.spine.timeScale=e)},s.getBone=function(e){return this.spine.findBone(e)},s.changeEquipment=function(e,n){void 0===n&&(n=null);var t=this.spine.findSlot(e);if(t)if(n){var i=this.spine.getAttachment(e,n);t.setAttachment(i)}else t.setAttachment(null)},s.changeSlot=function(e,n,t){var i=this.spine.skeletonData.getRuntimeData(),o=i.findSkin(e),s=i.findSlotIndex(n),r=o.getAttachment(s,t),a=this.spine.findSlot(n);a&&a.setAttachment(r)},n}(c)).prototype,"idle",[p],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return""}}),m=n(d.prototype,"spine",[C],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return null}}),f=d))||f));s._RF.pop()}}})); System.register("chunks:///_virtual/Start.ts",["./rollupPluginModLoBabelHelpers.js","cc","./ch.ts","./ui.ts","./ch_start_pack.ts","./ResUtil.ts","./ModuleDef.ts","./SceneDef.ts","./Hall.ts"],(function(e){var t,n,r,i,a,o,u,s,c,l,d,p,f,h,g,_,m,y;return{setters:[function(e){t=e.applyDecoratedDescriptor,n=e.inheritsLoose,r=e.initializerDefineProperty,i=e.assertThisInitialized,a=e.asyncToGenerator,o=e.regeneratorRuntime},function(e){u=e.cclegacy,s=e._decorator,c=e.ProgressBar,l=e.Prefab,d=e.game},function(e){p=e.ch},function(e){f=e.gui},function(e){h=e.ch_start_pack},function(e){g=e.ResUtil},function(e){_=e.ModuleDef},function(e){m=e.SceneDef},function(e){y=e.Hall}],execute:function(){var v,b,R,B,S,w,x,I;u._RF.push({},"66e163GxmdDp7kaguqDvTVl","Start",void 0);var L=s.ccclass,k=s.property,C=[_.BASIC,_.EXTRA,_.GAME],A=[{bundle:_.BASIC,url:"ui_alert/UI_Alert"},{bundle:_.BASIC,url:"ui_waiting/UI_Waiting"},{bundle:_.BASIC,url:"ui_notify/UI_Notify"}],D=C.length+A.length+1;e("Start",(v=L("Start"),b=k(c),R=k({type:l,displayName:"ui初始预制体"}),v(((I=function(e){function t(){for(var t,n=arguments.length,a=new Array(n),o=0;oloaded."),t++,this.onResLoaded(),t=1?t:this._numCurrentLoaded/D}},t}(h)).packId=void 0,w=t((S=I).prototype,"loadingBar",[b],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),x=t(S.prototype,"ui_prefab",[R],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),B=S))||B));u._RF.pop()}}})); System.register("chunks:///_virtual/State.ts",["cc"],(function(t){var e;return{setters:[function(t){e=t.cclegacy}],execute:function(){t("default",(function(){return new n})),e._RF.push({},"d9db0FDjAhNuLA9MVTSVAgv","State",void 0);var n=function(){function t(){this._state=0}var e=t.prototype;return e.Init=function(){this._state=0},e.Meet=function(e){return t.Has(this._state,e)},e.MeetAny=function(e){var n=this._state&e;return n===e||0!=n&&t.Has(e,n)},e.MeetAll=function(){for(var e=0,n=0;n1e6){var n=Math.floor(1e-6*t);return(t-=1e6*n)>1e3?n+"M"+Math.floor(.001*t)+"K":n+"M"}if(t>1e3){var r=Math.floor(.001*t);return(t-=1e3*r)>100?r+"K"+(t=Math.floor(.01*t)):r+"K"}return t.toString()},t.MS2S=function(t){return(.001*t).toFixed(1)};var n=t.prototype;return n.trimSpace=function(t){return t.replace(/^\s*(.*?)[\s\n]*$/g,"$1")},n.getStringLength=function(t){for(var n=t.split(""),r=0,e=0;e0){for(this._index=0;this._index0)for(this._index=0;this._index0?(this._tt.count--,this._tt.destTime+=this._tt.delay):this._tt.destTime+=this._tt.delay);this.taskList=this.taskList.filter((function(t){return!t.doDelete}))},t}();i._RF.pop()}}})); System.register("chunks:///_virtual/Timer.ts",["./rollupPluginModLoBabelHelpers.js","cc"],(function(e){var t,s;return{setters:[function(e){t=e.createClass},function(e){s=e.cclegacy}],execute:function(){e("default",(function(e){return new i(e)})),s._RF.push({},"890248SdzRIsa6dPHIO+Qxy","Timer",void 0);var i=function(){function e(e){void 0===e&&(e=0),this._elapsedTime=0,this._step=-1,this.step=e}var s=e.prototype;return s.serialize=function(){return{step:this._step,elapsed:this._elapsedTime}},s.unserialize=function(e){e&&(this._step=e.step,this._elapsedTime=e.elapsed)},s.update=function(e){return!(this.step<=0)&&(this._elapsedTime+=e,this._elapsedTime>=this._step&&(this._elapsedTime-=this._step,!0))},s.reset=function(){this._elapsedTime=0},s.stop=function(){this._elapsedTime=0,this.step=-1},t(e,[{key:"elapsedTime",get:function(){return this._elapsedTime}},{key:"step",get:function(){return this._step},set:function(e){this._step=e,this._elapsedTime=0}},{key:"coundown",get:function(){return this._step-this._elapsedTime}},{key:"progress",get:function(){return this._elapsedTime/this._step}}]),e}();s._RF.pop()}}})); System.register("chunks:///_virtual/Toast.ts",["cc"],(function(t){var e,i,o,n,s,h,r,d,a,g,_,N,l,p,u;return{setters:[function(t){e=t.cclegacy,i=t.ImageAsset,o=t.UIOpacity,n=t.tween,s=t.Label,h=t.UITransform,r=t.v3,d=t.Node,a=t.Layers,g=t.view,_=t.BlockInputEvents,N=t.Sprite,l=t.Texture2D,p=t.SpriteFrame,u=t.color}],execute:function(){e._RF.push({},"0cfc340yupKhKm9JAtrMkIE","Toast",void 0);var A=t("Gravity",function(t){return t[t.BOTTOM=0]="BOTTOM",t}({})),c=new Image;c.src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACAQMAAABIeJ9nAAAAA1BMVEX///+nxBvIAAAACklEQVQI12MAAgAABAABINItbwAAAABJRU5ErkJggg==";var v=new i(c),m=t("Toast",function(){function t(t){this._bgNode=null,this._textNode=null,this._node=null,this._text="",this._time=0,this._textSize=26,this._gravity=A.BOTTOM,this._node=this.getPNode(t),this._bgNode=new d,this._bgNode.layer=a.Enum.UI_2D,this._bgNode.addComponent(_);var e=this._bgNode.addComponent(N);e.type=N.Type.SLICED;var i=new l;i.image=v;var n=new p;n.texture=i,e.spriteFrame=n,e.color=u(128,128,128,255),this._bgNode.addComponent(o),this._bgNode.active=!1,this._textNode=new d("Text"),this._textNode.layer=a.Enum.UI_2D,this._textNode.addComponent(h).width=this._node.getComponent(h).width;var r=this._textNode.addComponent(s);r.horizontalAlign=s.HorizontalAlign.CENTER,r.verticalAlign=s.VerticalAlign.CENTER,this._textSize=26,this._textNode.parent=this._bgNode,this._bgNode.parent=this._node}t.makeText=function(e,i,o){void 0===o&&(o=t.LENGTH_SHORT);var n=new t(e);return n.setText(i),n.setTime(o),n};var e=t.prototype;return e.show=function(){var t=this;this.setFontSize(this._textSize),this.setOverFlow(),this._bgNode.active=!0;var e=this._bgNode.getComponent(o);n(e).delay(this._time).to(.3,{opacity:0}).call((function(){t._bgNode.destroy()})).start()},e.setText=function(t){return this._text=t,this._textNode.getComponent(s).string=this._text,this},e.setFontSize=function(t){return this._textSize=t,this._textNode.getComponent(s).fontSize=this._textSize,this},e.setTime=function(t){return this._time=t,this},e.setGravity=function(t){return this._gravity=t,this},e.setPosition=function(){this._node.getComponent(h);var t=this._bgNode.getComponent(h);if(A.BOTTOM===this._gravity){var e=t.height/2;this._bgNode.position=r(0,e,0)}},e.setOverFlow=function(){var t=this._node.getComponent(h).width/2,e=this._textNode.getComponent(s),i=this._text.length*e.fontSize,o=this._textNode.getComponent(h);i>t?(o.width=t,e.overflow=s.Overflow.RESIZE_HEIGHT):(o.width=i,e.overflow=s.Overflow.NONE);var n=this._bgNode.getComponent(h);n.width=o.width+4*e.fontSize,n.height=o.height,this.setPosition()},e.getPNode=function(e){if(null==t.pNode||!t.pNode.isValid){t.pNode=new d("Toast");var i=t.pNode.addComponent(h);t.pNode.layer=a.Enum.UI_2D,e.addChild(t.pNode),t.pNode.setSiblingIndex(e.children.length);var o=g.getVisibleSize();i.contentSize=o,i.width=o.width,i.height=o.height}return t.pNode},t}());m.LENGTH_SHORT=1,m.LENGTH_LONG=3.5,m.pNode=null,e._RF.pop()}}})); System.register("chunks:///_virtual/ui_base.ts",["./rollupPluginModLoBabelHelpers.js","cc"],(function(t){var e,n,o,s,i,l,r,a,c,u,h,d,f;return{setters:[function(t){e=t.inheritsLoose,n=t.createClass},function(t){o=t.cclegacy,s=t._decorator,i=t.Button,l=t.assetManager,r=t.Node,a=t.find,c=t.EventHandler,u=t.Toggle,h=t.ToggleContainer,d=t.Component,f=t.isValid}],execute:function(){var v;o._RF.push({},"a34ebvwnv5E2LG2J8RHwXU2","ui_base",void 0);var _=s.ccclass,g=(s.property,_("tgxNodeEventAgent")(v=function(t){function n(){return t.apply(this,arguments)||this}e(n,t);var o=n.prototype;return o.onButtonClicked=function(t,e){for(var n=t.target.getComponent(i),o=n.clickEvents,s=0;s2?o-2:0),i=2;io.width/o.height?n.setResolutionPolicy(u.FIXED_HEIGHT):n.setResolutionPolicy(u.FIXED_WIDTH),this._oldSize.set(t)}},o}(c))||r);o._RF.pop()}}})); System.register("chunks:///_virtual/ui.ts",["./rollupPluginModLoBabelHelpers.js","cc","./ui_base.ts","./ui_ResolutionAutoFit.ts"],(function(n){var t,e,i,o,r,a,s,u,c,l,d,f,v,h,p,_,g,m,y,w;return{setters:[function(n){t=n.inheritsLoose,e=n.asyncToGenerator,i=n.regeneratorRuntime},function(n){o=n.cclegacy,r=n._decorator,a=n.Component,s=n.tween,u=n.v3,c=n.UIOpacity,l=n.Tween,d=n.Vec3,f=n.UITransform,v=n.Node,h=n.Widget,p=n.error,_=n.instantiate,g=n.director,m=n.assetManager},function(t){y=t.default,n("ui_base",t.default)},function(n){w=n.ResolutionAutoFit}],execute:function(){var C;o._RF.push({},"81e48wxjGBMPp2rQOJDljTG","ui",void 0);var b=r.ccclass,P=(r.property,b("ui_updater")(C=function(n){function e(){return n.apply(this,arguments)||this}return t(e,n),e.prototype.update=function(n){y.updateAll(n)},e}(a))||C),A=n("GameUILayers",function(n){return n[n.GAME=0]="GAME",n[n.JOY_STICK=1]="JOY_STICK",n[n.HUD=2]="HUD",n[n.POPUP=3]="POPUP",n[n.ALERT=4]="ALERT",n[n.NOTICE=5]="NOTICE",n[n.LOADING=6]="LOADING",n[n.OVERLAY=7]="OVERLAY",n}({})),R=function(){function n(){this._uiCanvas=void 0,this._uiRoot=void 0,this._clss_loading=new Set}n.getInstance=function(){return this._instance||(this._instance=new n),this._instance};var t=n.prototype;return t.delay=function(n){return new Promise((function(t){return setTimeout(t,n)}))},t.delay_second=function(n){return new Promise((function(t){return setTimeout(t,1e3*n)}))},t.progressBar_anim=function(n,t,e){return void 0===e&&(e=.2),n.progress>=t?void(n.progress=t):new Promise((function(i){return s(n).to(e,{progress:t}).call((function(){i()})).start()}))},t.fillRange_anim=function(n,t,e,i){return void 0===e&&(e=.2),void 0===i&&(i=0),i>0&&n.fillRange>=t&&i<0&&n.fillRange<=t?void(n.fillRange=t):new Promise((function(i){return s(n).to(e,{fillRange:t}).call((function(){i()})).start()}))},t.scale_anim=function(n,t,e,i){return void 0===t&&(t=.2),void 0===e&&(e=.5),void 0===i&&(i=1),n.setScale(e,e,1),new Promise((function(e){return s(n).to(t,{scale:u(i,i,1)}).call((function(){e()})).start()}))},t.scale_elasticOut_anim=function(n,t,e,i){return void 0===t&&(t=.2),void 0===e&&(e=.5),void 0===i&&(i=1),n.setScale(e,e,1),new Promise((function(e){return s(n).to(t,{scale:u(i,i,1)},{easing:"elasticOut"}).call((function(){e()})).start()}))},t.fade_anim=function(n,t,e,i){var o;void 0===t&&(t=.2),void 0===e&&(e=0),void 0===i&&(i=255);var r=null!=(o=n.getComponent(c))?o:n.addComponent(c);return r.opacity=e,new Promise((function(n){s(r).to(t,{opacity:i}).call((function(){n()})).start()}))},t.shake_anim=function(n,t,e,i){return void 0===t&&(t=.2),void 0===e&&(e=5),void 0===i&&(i=7),new Promise((function(o){for(var r=n.position.clone(),a=t/(2*i),c=s(n),l=0;l0},t.show=function(){var n=e(i().mark((function n(t){var e,o,r,a,s,u,c,l=arguments;return i().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(!this.isLoading(t)){n.next=2;break}return n.abrupt("return",null);case 2:if(!this.isShowing(t)){n.next=4;break}return n.abrupt("return",null);case 4:if(e=new t,this._clss_loading.add(t),!(o=e.bundle)){n.next=31;break}for(r=m.getBundle(o),a=l.length,s=new Array(a>1?a-1:0),u=1;u3?u-3:0),l=3;l0&&(this.index=0,this.index==this.animat_names.length-1?this.DoAnimation(this.animat_names[this.index],!0):this.DoAnimation(this.animat_names[this.index],!1),this.spine.setCompleteListener(function(){this.index++,this.index0&&(this.spine.timeScale=i)},a.getBone=function(i){return this.spine.findBone(i)},n}(c)).prototype,"animat_names",[p],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return[]}}),_=n(f.prototype,"spine",[m],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return null}}),d=f))||d));a._RF.pop()}}})); System.register("chunks:///_virtual/UrlUtil.ts",["cc"],(function(t){var n;return{setters:[function(t){n=t.cclegacy}],execute:function(){n._RF.push({},"27d07mMayFBBZrBncxUySIT","UrlUtil",void 0);t("default",function(){function t(){}return t.getParamString=function(t){var n;if(null!=(t=t||(null==(n=window.location)?void 0:n.href))){var r=t.indexOf("?");if(-1!=r)return t.substring(r+1)}return null},t.getParam=function(t){var n={},r=this.getParamString(t);return r&&r.split("&").forEach((function(t){var r=t.split("=");2==r.length&&(n[r[0]]=r[1])})),n},t.getParamValue=function(t,n){var r=this.getParamString(n);if(r){var i=r.match("(^|&)"+t+"=([^&]*)(&|$)");if(i)return i[2]}return null},t}());n._RF.pop()}}})); System.register("chunks:///_virtual/Utils.ts",["cc"],(function(t){var e;return{setters:[function(t){e=t.cclegacy}],execute:function(){e._RF.push({},"7ea66r0AApIFbjuTFjXJIWh","Utils",void 0);t("Utils",function(){function t(){}return t.getRandom=function(t,e,r){if(void 0===t&&(t=0),void 0===e&&(e=1),void 0===r&&(r=!1),null==t&&(t=0),null==e&&(e=1),null==r&&(r=!1),t===e)return t;var n=t+Math.random()*(e-t);return r&&(n=Math.floor(n)),n},t.getRandomIntInclusive=function(t,e){return(t=Math.ceil(t))==(e=Math.floor(e))?t:Math.floor(Math.random()*(e-t+1))+t},t.getRandomInt=function(t,e){return t=Math.ceil(t),e=Math.ceil(e),Math.floor(Math.random()*(e-t))+t},t.getRandomNumberInRange=function(t,e){return Math.random()*(e-t)+t},t.getRandomDir=function(){return 0===Math.floor(2*Math.random())?-1:1},t.getRandomDiffValueFromArr=function(e,r){var n=new Array,a=new Array;if(!e||e.length<=0||r<=0)return a;for(var o=0;o=n.length)return n;r=Math.min(r,n.length-1);for(var u=0;u9?n:"0"+n)+":"+(a>9?a:"0"+a)+":"+(o>9?o:"0"+o)},t.second2time=function(t,e){void 0===e&&(e=2);var r=Math.floor(t/864e5);t%=864e5;var n=Math.floor(t/36e5);t%=36e5;var a=Math.floor(t/6e4);t%=6e4;var o=Math.floor(t/1e3),u="";return r>0&&e>0&&(u+=(r>9?r:"0"+r)+":",e--),n>0&&e>0&&(u+=(n>9?n:"0"+n)+":",e--),a>0&&e>0&&(u+=(a>9?a:"0"+a)+":",e--),e>0&&(u+=o>9?o:"0"+o,e--),(t%=1e3)>0&&e>0&&e--,u},t.formatMilliseconds=function(t){var e=Math.floor(t/1e3%60),r=Math.floor(t/6e4%60);return Math.floor(t/36e5%24).toString().padStart(2,"0")+":"+r.toString().padStart(2,"0")+":"+e.toString().padStart(2,"0")},t.getDecimal=function(t,e){var r=Math.pow(10,e);return Math.round(t*r)/r},t.getYearWeek=function(t){var e=new Date(t),r=new Date(e.getFullYear(),0,1),n=Math.floor((e.valueOf()-r.valueOf())/864e5);return Math.ceil((e.getDay()+1+n)/7)},t.isSameDay=function(t,e){var r=new Date(t);r.setHours(0,0,0,0);var n=new Date(e);return n.setHours(0,0,0,0),r.getTime()==n.getTime()},t.checkAndAdd=function(t,e,r){t.has(e)?t.set(e,t.get(e)+r):t.set(e,r)},t.randomWeights=function(t){for(var e=t.reduce((function(t,e){return t+e}),0),r=this.getRandom(0,e),n=0,a=0;n=r)return n;return-1},t.randomArray=function(t,e){return e?this.randomWeights(e.slice(0,t.length)):this.getRandom(0,t.length,!0)},t}());e._RF.pop()}}})); System.register("chunks:///_virtual/Wait.ts",["cc"],(function(e){var t;return{setters:[function(e){t=e.cclegacy}],execute:function(){e("default",(function(){return new n})),t._RF.push({},"5f7efxwnidOU6yhMrPMB9m6","Wait",void 0);var n=function(){function e(){this._resolve=null}var t=e.prototype;return t.wait=function(){var e=this;return new Promise((function(t){return e._resolve=t}))},t.resolve=function(e){this._resolve&&(this._resolve(e),this.dispose())},t.dispose=function(){this._resolve=null},e}();t._RF.pop()}}})); System.register("chunks:///_virtual/WsClient.ts",["./rollupPluginModLoBabelHelpers.js","cc"],(function(n){var t,e;return{setters:[function(n){t=n.createClass},function(n){e=n.cclegacy}],execute:function(){e._RF.push({},"d14186TLCpDIa2nmf/PWkp9","WsClient",void 0);n("WsClient",function(){var n=e.prototype;function e(n,t,e){this._ws=null,this._url=null,this._ca=void 0,this._ca=t,this._url=n,e&&this.connect()}return n.onConnected=function(n){},n.onError=function(n){},n.onClosing=function(){},n.onClosed=function(n){},n.onMessage=function(n){},n._onConnected=function(n){this.onConnected(n)},n._onMessage=function(n){this.onMessage(n)},n._onError=function(n){this.onError(n)},n._onClosed=function(n){this.onClosed(n)},n.connect=function(){if(this.isConnecting)return!1;if(this.isActive)return!1;var n=this._url;if(!n)return!1;try{var t=this._ca&&n.startsWith("wss://")?new WebSocket(n,{},this._ca):new WebSocket(n);t.binaryType="arraybuffer",t.onmessage=this._onMessage.bind(this),t.onopen=this._onConnected.bind(this),t.onerror=this._onError.bind(this),t.onclose=this._onClosed.bind(this),this._ws=t}catch(n){this._onError(n instanceof Error?n.message:"Unknown error")}return!0},n.close=function(n,t){this.isClosed||this.isClosing||(this.onClosing(),this._ws.close(n,t))},n.send=function(n){this._ws.send(n)},t(e,[{key:"ws",get:function(){return this._ws}},{key:"isActive",get:function(){var n;return(null==(n=this._ws)?void 0:n.readyState)===WebSocket.OPEN}},{key:"isConnecting",get:function(){var n;return(null==(n=this._ws)?void 0:n.readyState)===WebSocket.CONNECTING}},{key:"isClosing",get:function(){var n;return(null==(n=this._ws)?void 0:n.readyState)===WebSocket.CLOSING}},{key:"isClosed",get:function(){var n;return(null==(n=this._ws)?void 0:n.readyState)===WebSocket.CLOSED}}]),e}());e._RF.pop()}}})); (function(r) { r('virtual:///prerequisite-imports/main', 'chunks:///_virtual/main'); })(function(mid, cid) { System.register(mid, [cid], function (_export, _context) { return { setters: [function(_m) { var _exportObj = {}; for (var _key in _m) { if (_key !== "default" && _key !== "__esModule") _exportObj[_key] = _m[_key]; } _export(_exportObj); }], execute: function () { } }; }); });