!function(){"use strict";class e extends Laya.Image{constructor(){super(),this.scaleTime=80,this.clickId=!1,this.on(Laya.Event.MOUSE_DOWN,this,this.scaleSmall),this.on(Laya.Event.MOUSE_OVER,this,this.overs),this.on(Laya.Event.MOUSE_UP,this,this.scaleBig),this.on(Laya.Event.MOUSE_OUT,this,this.mouseout)}scaleBig(e){this.clickId&&(this.clickId=!1,this.alpha=1,this.CZ&&this.CZ())}overs(){this.alpha=.7}mouseout(){this.alpha=1}scaleSmall(e){this.clickId=!0}onDestroy(){this.ClearRunTime()}ClearRunTime(){this.off(Laya.Event.MOUSE_DOWN,this,this.scaleSmall),this.off(Laya.Event.MOUSE_UP,this,this.scaleBig),this.off(Laya.Event.MOUSE_OUT,this,this.mouseout),this.off(Laya.Event.MOUSE_OVER,this,this.overs),this.CZ=null}}class t{static getM_Vector(e,t){let i=new Laya.Vector3;return Laya.Vector3.add(e,t,i),new Laya.Vector3(.5*i.x,.5*i.y,.5*i.z)}static SpliteString(e,t){var i=t||";";let a=e.split(i),n=[];for(let e=0;e.5?-1:1;return Math.random()*e}static get64Encode(e){for(var t,i,a,n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,o=e.length,r="";s>2),r+=n.charAt((3&t)<<4),r+="==";break}if(i=e.charCodeAt(s++),s==o){r+=n.charAt(t>>2),r+=n.charAt((3&t)<<4|(240&i)>>4),r+=n.charAt((15&i)<<2),r+="=";break}a=e.charCodeAt(s++),r+=n.charAt(t>>2),r+=n.charAt((3&t)<<4|(240&i)>>4),r+=n.charAt((15&i)<<2|(192&a)>>6),r+=n.charAt(63&a)}return r}static randomInt(e,t){return tt&&(i=t),i}}class i{constructor(){this._container={},this._length=0}get container(){return this._container}get size(){return this._length}set(e,t){this._container.hasOwnProperty(e)||this._length++,this._container[e]=t}delete(e){this._container.hasOwnProperty(e)&&(delete this._container[e],this._length--)}has(e){return!!this._container.hasOwnProperty(e)}get(e){return this._container.hasOwnProperty(e)?this._container[e]:void 0}clear(){this._container={},this._length=0}}class a{static get Disispatcher(){return a.disispatcher||(a.disispatcher=new Laya.EventDispatcher)}static on(e,t,i){this.Disispatcher.on(e,t,i)}static off(e,t,i){this.Disispatcher.off(e,t,i)}static event(e,t=null){this.Disispatcher.event(e,t)}}class n{loadUI(){Laya.loader.load(["res/threeDimen/ui/button.png"],Laya.Handler.create(this,function(){var e=Laya.stage.addChild(new Laya.Button("res/threeDimen/ui/button.png","正常模式"));e.size(160,40),e.labelBold=!0,e.labelSize=30,e.sizeGrid="4,4,4,4",e.scale(Laya.Browser.pixelRatio,Laya.Browser.pixelRatio),e.pos(Laya.stage.width/2-e.width*Laya.Browser.pixelRatio/2,Laya.stage.height-100*Laya.Browser.pixelRatio),e.on(Laya.Event.CLICK,this,function(){++this.curStateIndex%2==1?(this.sprite3D.active=!1,this.lineSprite3D.active=!0,e.label="网格模式"):(this.sprite3D.active=!0,this.lineSprite3D.active=!1,e.label="正常模式")})}))}}n.Event={CamFollowArg:"CamFollowArg",SetAimPos:"SetAimPos",RefreshBulletCount:"RefreshBulletCount",RefreshRemainEnemyCount:"RefreshRemainEnemyCount",GameShowTips:"GameShowTips",StartShot:"StartShot",StopShot:"StopShot",ShowMainUi:"ShowMainUi",SetMonery:"SetMonery",SetStage:"SetStage",SetStagePro:"SetStagePro"};class s{}s.VER="1.0.11",s.CFG="CFG",s.wxValue="",s.isX=!1,s.mSharePeopleScene=null;var o,r=Laya.Particle2D;!function(e){e[e.hit=0]="hit",e[e.click=1]="click",e[e.win=2]="win",e[e.defeat=3]="defeat"}(o||(o={}));class h{constructor(){this.vibrate=!0,this.sound=!0,this.SoundType={click:"subpackage1/sound/click.mp3",win:"subpackage1/sound/vector.mp3",defeat:"subpackage1/sound/defeat.mp3",car_crush_1:"subpackage1/sound/car_crush_1.mp3",car_crush_2:"subpackage1/sound/car_crush_2.mp3",car_crush_3:"subpackage1/sound/car_crush_3.mp3",explotion1:"subpackage1/sound/explotion1.mp3",explotion2:"subpackage1/sound/explotion2.mp3",gun_fire_1:"subpackage1/sound/gun_fire_1.mp3",gun_fire_2:"subpackage1/sound/gun_fire_2.mp3",gun_fire_3:"subpackage1/sound/gun_fire_3.mp3",reload_gun_1:"subpackage1/sound/reload_gun_1.mp3",reload_gun_2:"subpackage1/sound/reload_gun_2.mp3",hitcar:"subpackage1/sound/hitcar.mp3",hitrole:"subpackage1/sound/hitrole.mp3",hit:"subpackage1/sound/hit.mp3"},this.bgm="subpackage1/sound/bgm.mp3"}static get Instance(){return this.instasnce||(this.instasnce=new h)}onAssetsLoaded(e){this.sp=new r(e),this.sp.emitter.start(),this.sp.play(),Laya.stage.addChild(this.sp),this.sp.x=Laya.stage.width/2,this.sp.y=Laya.stage.height/2}SettingSound(e){}_playMusic(e){}SetSoundV(e){}PlaySound(e){}StopSound(e){}Init(){var e=Laya.LocalStorage.getItem("vibrate");this.vibrate=!Number(e)||"1"==e}}class l{static GoShare(e){l.ShareTime=(new Date).getTime(),console.log("分享点击时间="+l.ShareTime),l.IsSharing=!0,l.callback=e}static OnShowHandle(){Laya.Browser.window.wx&&Laya.Browser.window.wx.onShow(function(e){if(h.Instance.SetSoundV(1),console.log("onshow share start"),console.log("进入微信"),l.IsSharing){l.IsSharing=!1;let e=(new Date).getTime();console.log("分享回到游戏时间"+e);let t=(e-l.ShareTime)/1e3;if(console.log("分享停留时间为:"+t),t>=2)if(Math.random()<=1){if(!l.callback)return;l.callback(!0,1)}else{if(!l.callback)return;Math.random()<=.5?Mt.Instance.ShowTips("分享失败!"):Mt.Instance.ShowTips("请分享到不同的群!"),l.callback(!1,1)}else{if(!l.callback)return;Math.random()<=.5?Mt.Instance.ShowTips("分享失败!"):Mt.Instance.ShowTips("请分享到不同的群!"),l.callback(!1,1)}}})}}l.IsSharing=!1;class c{static Reg(){}}var d=Laya.Templet,p=Laya.Event;class g{constructor(){this.mStartX=200,this.mStartY=500,this.mActionIndex=0,this.mCurrIndex=0,this.mCurrSkinIndex=0}static get Instance(){return this.instance||(this.instance=new g)}GetThing(e){return this._thing?this._thing[e-1]:null}GetTheme(e){return this._theme?this._theme[e-1]:null}GetRoad(e){return this._road?this._road[e-1]:null}GetRate(e){return this._rate?this._rate[e-1]:null}GetStreet(e){return this._block?this._block[e-1]:null}GetGlobal(e){if(this._globe)for(let t=0;t=this.mArmature.getAnimNum()&&(this.mCurrIndex=0),this.mArmature.play(this.mCurrIndex,!1)}}class u{loadUI(){Laya.loader.load(["res/threeDimen/ui/button.png"],Laya.Handler.create(this,function(){var e=Laya.stage.addChild(new Laya.Button("res/threeDimen/ui/button.png","切换注视目标"));e.size(200,40),e.labelBold=!0,e.labelSize=30,e.sizeGrid="4,4,4,4",e.scale(Laya.Browser.pixelRatio,Laya.Browser.pixelRatio),e.pos(Laya.stage.width/2-e.width*Laya.Browser.pixelRatio/2,Laya.stage.height-100*Laya.Browser.pixelRatio),e.on(Laya.Event.CLICK,this,function(){this.index++,this.index%3==1?this.camera.transform.lookAt(this.box.transform.position,this.upVector):this.index%3==2?this.camera.transform.lookAt(this.cylinder.transform.position,this.upVector):this.camera.transform.lookAt(this.capsule.transform.position,this.upVector)})}))}}u.MainScene="subpackage/LayaScene_MainScene/Conventional/main.ls",u.Player=["subpackage/LayaScene_Character/Conventional/Character1.lh","subpackage/LayaScene_Character/Conventional/Character2.lh","subpackage/LayaScene_Character/Conventional/Character3.lh","subpackage/LayaScene_Character/Conventional/Character4.lh","subpackage/LayaScene_Character/Conventional/Character5.lh","subpackage/LayaScene_Character/Conventional/Character6.lh","subpackage/LayaScene_Character/Conventional/Character7.lh","subpackage/LayaScene_Character/Conventional/Character8.lh"],u.Enemy="subpackage/LayaScene_Character/Conventional/enemy.lh",u.PlayerShot="subpackage/LayaScene_Property/Conventional/PlayerShoot.lh",u.Mound="subpackage/LayaScene_Property/Conventional/Mound.lh",u.Barrier=["subpackage/LayaScene_barrier/Conventional/barrier_1.lh","subpackage/LayaScene_barrier/Conventional/barrier_2.lh","subpackage/LayaScene_barrier/Conventional/barrier_3.lh","subpackage/LayaScene_barrier/Conventional/barrier_4.lh","subpackage/LayaScene_barrier/Conventional/move_barrier.lh","subpackage/LayaScene_barrier/Conventional/stone_1.lh","subpackage/LayaScene_barrier/Conventional/stone_2.lh","subpackage/LayaScene_barrier/Conventional/stone_3.lh","subpackage/LayaScene_barrier/Conventional/stone_4.lh","subpackage/LayaScene_barrier/Conventional/Block1.lh"],u.Particle=["subpackage/LayaScene_Particle/Conventional/Explode.lh","subpackage/LayaScene_Particle/Conventional/Hit.lh","subpackage/LayaScene_Particle/Conventional/Blood.lh"],u.Config={level:"level",road:"road",block:"block",thing:"thing",atk:"atk",rate:"rate",global:"global",theme:"theme"};class y{constructor(){this._outHitResult=new Laya.HitResult,this.outs=new Array,this.posX=0,this.posY=0,this.point=new Laya.Vector2}addBoxXYZ(e,t,i){var a=new Laya.BlinnPhongMaterial;Laya.Texture2D.load("res/threeDimen/Physics/rocks.jpg",Laya.Handler.create(null,function(e){a.albedoTexture=e}));var n=.75*Math.random()+.25,s=.75*Math.random()+.25,o=.75*Math.random()+.25,r=new Laya.MeshSprite3D(Laya.PrimitiveMesh.createBox(n,s,o));this.scene.addChild(r),r.meshRenderer.material=a,this.tmpVector.setValue(e,t,i),r.transform.position=this.tmpVector,this.tmpVector.setValue(360*Math.random(),360*Math.random(),360*Math.random()),r.transform.rotationEuler=this.tmpVector;var h=r.addComponent(Laya.Rigidbody3D),l=new Laya.BoxColliderShape(n,s,o);h.colliderShape=l,h.mass=10}}y.moveTime=1;var m=Laya.TiledMap,w=Laya.Rectangle,f=Laya.Browser,I=Laya.Handler;class v{constructor(){this.stage=1,this.equipId=1,this.mLastMouseX=0,this.mLastMouseY=0,this.mX=0,this.mY=0}static get Instance(){return v.instance||(v.instance=new v)}static GlobalMessage(){v.tower_reward=Number(g.Instance.GetGlobal("tower_reward")),v.block_reward=Number(g.Instance.GetGlobal("block_reward")),v.enemy_reward=Number(g.Instance.GetGlobal("enemy_reward"))}InitPlayer(){var e=N.Instance.CurModel;v.instance.stage=Number(e.GetUserAttr(A.stage))+1,v.instance.equipId=Number(e.GetUserAttr(A.equip_themes)[1]),this.SetInfo()}SpeedUp(e,t,i,a){let n=[{t:N.Instance.CurModel.ServerTime},{attr:"rate"},{level:e},{channel:t},{amount:i}];T.Instance.HttpPostRequest(R.protocols.UpgradeAttr,n,e=>{a&&a(!0)},e=>{a&&a(!1)})}SetInfo(){let e=N.Instance.CurModel.GetUserAttr(A.attrs).power;this.powerLevel=e?Number(e):1;let t=g.Instance._atk.length,i=this.powerLevel>t?t:this.powerLevel;v.bulletAttack=g.Instance.GetAtk(i).atk;let a=N.Instance.CurModel.GetUserAttr(A.attrs).rate;this.rateLevel=a?Number(a):1;let n=g.Instance._rate.length,s=this.rateLevel>n?n:this.rateLevel;v.bulletTime=g.Instance.GetRate(s).rate}createMap(){this.tiledMap=new m,this.mX=this.mY=0,this.tiledMap.createMap("res/tiledMap/desert.json",new w(0,0,f.width,f.height),new I(this,this.completeHandler))}completeHandler(){console.log("地图创建完成"),console.log("ClientW:"+f.clientWidth+" ClientH:"+f.clientHeight),Laya.stage.on(Laya.Event.RESIZE,this,this.resize),this.resize()}mouseDown(){this.mLastMouseX=Laya.stage.mouseX,this.mLastMouseY=Laya.stage.mouseY,Laya.stage.on(Laya.Event.MOUSE_MOVE,this,this.mouseMove)}mouseMove(){this.tiledMap.moveViewPort(this.mX-(Laya.stage.mouseX-this.mLastMouseX),this.mY-(Laya.stage.mouseY-this.mLastMouseY))}mouseUp(){this.mX=this.mX-(Laya.stage.mouseX-this.mLastMouseX),this.mY=this.mY-(Laya.stage.mouseY-this.mLastMouseY),Laya.stage.off(Laya.Event.MOUSE_MOVE,this,this.mouseMove)}resize(){this.tiledMap.changeViewPort(this.mX,this.mY,f.width,f.height)}PowerUp(e,t,i,a){let n=[{t:N.Instance.CurModel.ServerTime},{attr:"power"},{level:e},{channel:t},{amount:i}];T.Instance.HttpPostRequest(R.protocols.UpgradeAttr,n,e=>{a&&a(!0)},e=>{a&&a(!1)})}}v.bulletAttack=1,v.bulletTime=.3;class x{}x.playerRayLengthF=1.3,x.playerRayLengthLR=.3,x.bulletRayLength=1,x.bulletMaxDis=40,x.barrierRoadLength=50,x.barrierRoadAverageNum=50,x.playerspeed=.1,x.matespeed=.2,x.hitmaxcount=2,x.boommaxcount=2,x.blockLRmoveMaxDis=5,x.arriveStandWidth=5,x.enemySpeed=.1,x.shootspeed=.8,x.sliderFactor=.02,x.playerMoveMaxX=4.5;var L=Laya.Sprite,S=Laya.Event,b=Laya.SoundManager,k=Laya.Handler;class C{static GameInfo(){v.Instance.InitPlayer()}static SetCfg(e){g.Instance._level=e[u.Config.level],g.Instance._road=e[u.Config.road],g.Instance._block=e[u.Config.block],g.Instance._thing=e[u.Config.thing],g.Instance._atk=e[u.Config.atk],g.Instance._rate=e[u.Config.rate],g.Instance._theme=e[u.Config.theme],g.Instance._globe=e[u.Config.global],v.GlobalMessage()}setup(){var e=this.createButton("播放音效");e.x=(Laya.stage.width-2*e.width+10)/2,e.y=(Laya.stage.height-e.height)/2,Laya.stage.addChild(e);var t=this.createButton("播放音乐");t.x=e.x+10+e.width,t.y=e.y,Laya.stage.addChild(t),e.on(S.CLICK,this,this.onPlaySound),t.on(S.CLICK,this,this.onPlayMusic)}createButton(e){var t=new L;return t.size(110,40),t.graphics.drawRect(0,0,110,40,"#FF7F50"),t.graphics.fillText(e,55,8,"25px SimHei","#FFFFFF","center"),Laya.stage.addChild(t),t}onPlayMusic(e){console.log("播放音乐"),b.playMusic("res/sounds/bgm.mp3",1,new k(this,this.onComplete))}onPlaySound(e){console.log("播放音效"),b.playSound("res/sounds/btn.mp3",1,new k(this,this.onComplete))}onComplete(){console.log("播放完成")}static Appseting(e){y.shareimage=e.shareimage,y.sharetitle=e.sharetitle,y.bannerCanMove=Number(e.bannerCanMove),y.moveTime=Number(e.moveTime),y.OpenSceneValue=Number(e.OpenSceneValue),y.freeUpdateVideotime=Number(e.freeUpdateVideotime),y.freecoinValue=Number(e.freecoinValue),y.freeGetcoinTime=Number(e.freeGetcoinTime),y.cheat=e.cheat,y.cheattime=e.cheattime,y.checkscene=e.checkscene,x.playerspeed=Number(e.playerspeed),x.matespeed=Number(e.friendspeed),x.shootspeed=Number(e.bulletspeed),x.sliderFactor=Number(e.sliderFactor),x.playerMoveMaxX=Number(e.playerMoveMaxX),x.playerRayLengthF=Number(e.playerRayLengthF),x.playerRayLengthLR=Number(e.playerRayLengthLR),x.bulletRayLength=Number(e.bulletRayLength),x.bulletMaxDis=Number(e.bulletMaxDis),x.barrierRoadLength=Number(e.barrierRoadLength),x.barrierRoadAverageNum=Number(e.barrierRoadAverageNum),x.hitmaxcount=Number(e.hitmaxcount),x.boommaxcount=Number(e.boommaxcount),x.blockLRmoveMaxDis=Number(e.blockLRmoveMaxDis),x.arriveStandWidth=Number(e.arriveStandWidth),x.enemySpeed=Number(e.enemySpeed)}static get Cheat(){return"1"==y.cheat}static get CheatTime(){return Number(y.cheattime)}static get CheckScene(){return"1"==y.checkscene}}var M=Laya.Event,_=Laya.HttpRequest;const B="https://gungangfengyunapi.xwxgame.com/";class R{}R.protocols={Login:"user/login",Userauth:"user/auth",BuyLand:"shop/land",UserSync:"user/sync",ShopBuild:"shop/build",ShopUpgrade:"shop/upgrade",ShopSale:"shop/sale",RoleUpgrade:"role/upgrade",Fissionvd:"fission/vd",DailyTaskrefresh:"dailytask/refresh",DailyTaskrewards:"dailytask/rewards",Rankingvmoney:"ranking/vmoney",Lotterylottery:"lottery/lottery",AchievementgetRewards:"achievement/getRewards",Fissiondeduct:"fission/deduct",Sign:"sign/sign",InvitegetRewards:"invite/getRewards",InvitetargetRewards:"invite/targetRewards",GameResult:"game/play",Easter:"game/revival",GetCfg:"config/table",DoubleAward:"fission/vd",KunDiscard:"kun/discard",KunEquip:"kun/equip",KunMove:"kun/move",KunBuy:"kun/buy",Opentreasure:"treasure/open",Entertreasure:"treasure/enter",Buy:"theme/buy",Equip:"theme/equip",themefission:"theme/fission",Start:"game/start",UpgradeAttr:"attr/upgrade"};class T{PostTokenRequest(e,t,i,a=!0){let n="",s=B+e;n=n=`token=${N.Instance.CurModel.m_token}`;let o=new _;o.once(M.COMPLETE,this,this.onHttpRequestComplete,[t,i,o,a]),o.once(M.ERROR,this,this.onHttpRequestError,[i,o]),o.send(s,n,"post","text"),a&&D.ShowLoading("")}onHttpRequestComplete(e,i,a,n){let s;(n&&D.HideLoading(),s=JSON.parse(a.data),console.log("请求成功:"+JSON.stringify(s)),0==s.code)?(N.Instance.RefreshModel(s),null!=e&&e(s)):null!=i&&i(t.SpliteString(s.message,",")[0])}onHttpRequestError(e,t,i){if(null!=e){var a=JSON.parse(t.data);e(a)}console.log("Error! Http request error, code: "+a),i&&D.HideLoading()}static get Instance(){return T.instance||(T.instance=new T)}login(e,t,i){console.log("发送登录请求");var a=N.Instance,n=s.VER;let o=`code=${a.m_code}&nickname=${a.m_nickname}&avatar=${a.m_avatar}&gender=${a.m_gender}&country=${a.m_country}&province=${a.m_province}&city=${a.m_city}&device=${a.m_device}&share_id=${a.m_share_id}&scene=${a.channel}&v=${n}`;console.log("登录 参数: "+o);let r=new _;r.once(M.PROGRESS,this,this.onHttpRequestProgress,[e,r]),r.once(M.COMPLETE,this,this.onLoginRequestComplete,[t,r]),r.once(M.ERROR,this,this.onHttpRequestError,[i,r]),r.send(B+R.protocols.Login,o,"post","text")}onHttpRequestProgress(){}onLoginRequestComplete(e,t){let i=JSON.parse(t.data);if(console.log(i),console.log("登录完成"),"0"!=i.code){var a=JSON.stringify(t.data);return console.log("登录异常错误!错误信息:",a),void e(i)}N.Instance.SetUserModel(new E(i.token,i.configs,i.app_setting,i.user,i.user_base,i.user_invite,i.user_lottery,i.user_treasure,i.t,i.user_achievement,i.user_sign,i.user_arena,i.is_new,i.user_shop,i.user_daily_task,i.user_video)),C.Appseting(i.app_setting);var n=i.table_version;N.Instance.CurModel.JundgCfg(n,t=>{t&&(C.GameInfo(),e(i))}),D.ShareMessage()}PostCfgRequest(e,t){let i="",a=B+R.protocols.GetCfg;i=`token=${N.Instance.CurModel.m_token}`;let n=new _;n.once(M.COMPLETE,this,()=>{var i=JSON.parse(n.data);0==i.code?null!=e&&i.configs&&e(i.configs):null!=t&&t(i)}),n.once(M.ERROR,this,()=>{var e=JSON.parse(n.data);null!=t&&t(e)}),n.send(a,i,"post","text")}HttpPostRequest(e,i,a,n,s=!0,o=!0){let r="",h=B+e;if(1==s&&(r=`token=${N.Instance.CurModel.m_token}&`),e==R.protocols.UserSync||e==R.protocols.Fissionvd||e==R.protocols.Lotterylottery||e==R.protocols.Fissiondeduct||e==R.protocols.KunBuy||e==R.protocols.KunDiscard||e==R.protocols.KunEquip||e==R.protocols.KunMove||e==R.protocols.Start||e==R.protocols.GameResult||e==R.protocols.themefission||e==R.protocols.Opentreasure||e==R.protocols.UpgradeAttr){let e="abcdefghijkimnopqrstuvwxyz0123456789",a="{",n="";for(let t=0;t<4;t++)n+=e[Math.floor(100*Math.random())%e.length];for(let e=0;e{t.progress&&t.progress(i)}),i.once(Laya.Event.ERROR,this,()=>{t.error&&t.error(i)}),i.once(Laya.Event.COMPLETE,this,()=>{t.complete&&t.complete(i)})),i.send("https://r.94xj.net/e",e,"post","json",["Content-Type","application/json"])}static ErrorReport(){this.errorRequest({code:1003,msg:"invalid code",user_id:0,game:"parkourrace",type:"backend",platform:"weixin"},{complete:e=>{},error:e=>{}})}}var V,A,P;!function(e){e[e.train=0]="train",e[e.sign=1]="sign",e[e.rewards=2]="rewards"}(V||(V={})),function(e){e[e.user_id=0]="user_id",e[e.diamond=1]="diamond",e[e.energy=2]="energy",e[e.list_kun=3]="list_kun",e[e.stage=4]="stage",e[e.vmoney=5]="vmoney",e[e.equip_kun=6]="equip_kun",e[e.unlock_kun=7]="unlock_kun",e[e.buyed_kun=8]="buyed_kun",e[e.money=9]="money",e[e.progress_themes=10]="progress_themes",e[e.equip_themes=11]="equip_themes",e[e.get_themes=12]="get_themes",e[e.attrs=13]="attrs"}(A||(A={}));class E{constructor(e,t,i,a,n,s,o,r,h,l,c,d,p,g,u,y){this.loginSeverTime=0,this.m_avatar="",this.localTime=Laya.timer.currTimer,this.loginSeverTime=h,this.m_token=e,this.m_user=a,this.m_base=n,this.m_invite=s,this.m_lottery=o,this.m_treasure=r,this.m_achievement=l,this.m_sign=c,this.m_arena=d,this.m_shop=g,this.user_video=y,this.user_daily_task=u,this.m_userid=this.m_user.user_id,this.m_openid=this.m_base.openid,this.m_nickname=this.m_base.nickname,this.is_new=Number(p)}GetUserAttr(e){var t=A[e];return this.m_user[t]}get ServerTime(){let e=Laya.timer.currTimer;return this.loginSeverTime+Math.ceil((e-this.localTime)/1e3)}HasTheme(e){for(var t=this.GetUserAttr(A.get_themes),i=0;i{i.VER=e,Laya.LocalStorage.setJSON(s.CFG,i),C.SetCfg(i),t(!0)},e=>{console.log("配置获取失败"+e),t(!1)})):(console.log("本地没有cfg"),T.Instance.PostCfgRequest(i=>{console.log("cfg"+i),i.VER=e,Laya.LocalStorage.setJSON(s.CFG,i),C.SetCfg(i),t(!0)},e=>{console.log("配置获取失败"+e)}))}}class N{get CurModel(){return this.curModel}constructor(e,t,i,a,n,s,o,r,h,l){N.instance=this,this.m_code=e,this.m_nickname=t||"",this.m_avatar=i||"",this.m_gender=a||0,this.m_city=o||"",this.m_device=r||"",this.m_share_id=h||"",this.channel=l||"",this.m_country=n||"",this.m_province=s||""}static get Instance(){return N.instance?N.instance:(N.instance=new N("11","","",0,"","","","","",""),N.instance)}SetUserModel(e){this.curModel=e}RefreshModel(e){e.user&&(this.curModel.m_user=e.user),e.user_invite&&(this.curModel.m_invite=e.user_invite),e.user_lottery&&(this.curModel.m_lottery=e.user_lottery),e.user_achievement&&(this.curModel.m_achievement=e.user_achievement),e.user_sign&&(this.curModel.m_sign=e.user_sign),e.user_shop&&(this.curModel.m_shop=e.user_shop),e.user_daily_task&&(this.curModel.user_daily_task=e.user_daily_task),e.user_video&&(this.curModel.user_video=e.user_video)}}!function(e){e[e["登录加载"]=0]="登录加载",e[e["界面开启"]=1]="界面开启"}(P||(P={}));class D{static get ShareId(){return this.shareId}static get Chanel(){return this._chanel}static init(e){this.EventStatistics(),Laya.Browser.window.wx.showShareMenu({withShareTicket:!0}),Laya.Browser.window.wx.onShow(this.InitWx)}static InitWx(e){var t=e.query.share_id;this.shareId=t||"",s.wxValue=e.scene;var i=Laya.LocalStorage.getItem("scene");i?(s.wxValue=i,console.log("读取配置场景值:"+i)):(console.log("第一次拉取场景值:"+s.wxValue),Laya.LocalStorage.setItem("scene",s.wxValue));var a=e.query.channel;this._chanel=a||"",Laya.Browser.window.wx.offShow(D.InitWx)}static ShareMessage(){if(s.isWx){var e,i,a=N.Instance.CurModel.ServerTime;if(e=y.sharetitle,i=y.shareimage,null==e)e="枪王之王...",i="res/share.png";else{let a=t.SpliteString(e),n=t.SpliteString(i);e=a[t.randomInt(0,a.length-1)],i=n[t.randomInt(0,n.length-1)]}console.log("_title:",e),console.log("_url:",i),Laya.Browser.window.wx.onShareAppMessage(()=>({title:e,imageUrl:i,query:"share_id="+N.Instance.CurModel.m_userid+"_other_"+a+"_"+Math.floor(9999*Math.random()).toString()}))}}static Login(e){D.Lodining||(D.Lodining=!0,Laya.Browser.window.wx.login({success:function(t){console.log("wx.login: success! res.code="+t.code),t.code?(D.Lodining=!1,console.log("将要传递的参数:"+t),e(t)):(console.log("获取用户登录态失败!"+t.errMsg),e("error"))},fail:function(t){console.log("wx.login: failed, res="+t),D.Lodining=!1,e("error")}}))}static ShowLoading(e="加载中...",t=!0){console.log(e),Laya.Browser.window&&Laya.Browser.window.wx?(t&&Laya.Browser.window.wx.showLoading({title:e,mask:!0}),Mt.Instance.OpenMask()):Mt.Instance.OpenMask()}static HideLoading(e=!0){Laya.Browser.window&&Laya.Browser.window.wx?(e&&Laya.Browser.window.wx.hideLoading(),Mt.Instance.CloseMask()):Mt.Instance.CloseMask()}static SystemInfo(){if(Laya.Browser.window.wx)return D.sysdata||(D.sysdata=Laya.Browser.window.wx.getSystemInfoSync()),D.sysdata}static ShowToast(e,t=!0){if(Laya.Browser.window.wx){var i=t?"success":"none";e=e||"暂未开放...",Laya.Browser.window.wx.showToast({title:e,icon:i})}else console.log(e)}static ShortVibrate(){if(Laya.Browser.window.wx&&h.Instance.vibrate){if(D.vibrating)return;D.vibrating=!0,Laya.Browser.window.wx.vibrateShort({complete:function(e){D.vibrating=!1}})}}static LongVibrate(){if(Laya.Browser.window.wx&&h.Instance.vibrate){if(D.vibrating)return;D.vibrating=!0,Laya.Browser.window.wx.vibrateLong({complete:function(e){D.vibrating=!1}})}}static Success(e){s.isWx&&Laya.Browser.window.wx.aldStage.onEnd({stageId:e,stageName:"第"+e+"关",event:"complete",params:{desc:"关卡完成"}})}static AldEvent(e,t){Laya.Browser.window&&Laya.Browser.window.wx&&Laya.Browser.window.wx.aldSendEvent(e,{key:""})}static EventStatistics(){let e=Laya.LocalStorage.getItem("uuidTimes");if(e){let t=new Date(Number(e)),i=new Date(Laya.timer.currTimer);i.setHours(0,0,0,0),t.valueOf(){console.log("授权结果.."),console.log(e),1==e.authSetting["scope.userInfo"]&&(D.isAuth=!0,Laya.Browser.window.wx.getUserInfo({lang:"zh_CN",success:e=>{N.Instance.CurModel.m_nickname=e.userInfo.nickName,N.Instance.CurModel.m_avatar=e.userInfo.avatarUrl,console.log("已经受过权")},fail:()=>{console.log("调用getUserInfo fail")}}))}})}static RequestAuth(e){if(D.isAuth)null!=e&&e(!0);else if(s.isWx){console.log("-----授权"),(()=>{let t=Laya.stage.width,i=Laya.stage.height;console.log("准备授权");let a=Laya.Browser.window.wx.createUserInfoButton({type:"text",text:"",style:{left:0,top:0,width:t,height:i,lineHeight:40,backgroundColor:"#00000000",textAlign:"center",fontSize:16,borderRadius:4}}),n=t=>{if(console.log("res:"+JSON.stringify(t)),t.userInfo){a.hide(),a.offTap(n),a.destroy(),console.log("userinfo",t),N.Instance.CurModel.m_nickname=t.userInfo.nickName,N.Instance.CurModel.m_avatar=t.userInfo.avatarUrl;let i=[{nickname:t.userInfo.nickName},{avatar:t.userInfo.avatarUrl},{gender:t.userInfo.gender},{city:t.userInfo.city},{country:t.userInfo.country},{province:t.userInfo.province}];T.Instance.HttpPostRequest(R.protocols.Userauth,i,()=>{D.isAuth=!0,null!=e&&e(!0)},null)}else a.hide(),a.offTap(n),a.destroy(),null!=e&&e(!1)};a.show(),a.onTap(n)})()}else D.isAuth=!0,null!=e&&e(!0)}static OnShow(e){Laya.Browser.onWeiXin&&Laya.Browser.window.wx.onShow(e)}static OffShow(e){Laya.Browser.onWeiXin&&Laya.Browser.window.wx.offShow(e)}static showbjWxGameQuan(e){if(s.isWx)if(e){if(null==this.button){let e=Laya.Browser.window.wx.getSystemInfoSync();if(!e)return;var t=.5*e.windowHeight,i=109*e.windowHeight/Laya.stage.height,a=80*i/109;Laya.stage.width,this.button=Laya.Browser.window.wx.createGameClubButton({type:"image",image:"res/talk.png",style:{left:.5*e.windowWidth+150*e.windowWidth/Laya.stage.width,top:t-240*e.windowHeight/Laya.stage.height,width:a,height:i}})}this.button.show()}else this.button&&this.button.hide()}}D.Lodining=!1,D.shareId="",D._chanel="",D.isAuth=!1,D.vibrating=!1,D.IsNew=0;var G,H,z=Laya.Sprite3D;!function(e){e[e.WarnTips=1]="WarnTips",e[e.HpText=2]="HpText"}(G||(G={}));class U{constructor(){this.poolDic=new i,this.prefabDic=new i,this.singleobjDic=new i}static get Instance(){return U.instance||(U.instance=new U)}InitSelf(e,t){null!=t&&(this.prefabDic.has(e)||this.prefabDic.set(e,t))}onComplete(e){Laya.Sprite3D.load("res/threeDimen/staticModel/lizard/lizard.lh",Laya.Handler.create(this,function(e){var t=this.scene.addChild(e);t.transform.position=new Laya.Vector3(-.6,0,0),t.transform.localScale=new Laya.Vector3(.075,.075,.075);var i=Laya.Sprite3D.instantiate(t,this.scene,!1,new Laya.Vector3(.6,0,0));i.transform.localScale=new Laya.Vector3(.075,.075,.075);for(var a=0;a0){var t=this.singleobjDic.get(e).shift();return t.visible=!0,t}return this.GetByType(e)}return this.GetByType(e)}RecoverUi(e,t){t.visible=!1,t.removeSelf(),this.singleobjDic.has(e)||this.singleobjDic.set(e,new Array),this.singleobjDic.get(e).push(t)}RecoverModel(e){if(e){e.active=!1,e.removeSelf();var t=e.name;this.poolDic.has(t)||this.poolDic.set(t,new Array),this.poolDic.get(t).push(e)}}GetModel(e){if("PlayerShoot"==e&&U.bulletCount++,this.poolDic.has(e)){if(this.poolDic.get(e).length>0){var t=this.poolDic.get(e).shift();return t.active=!0,t}return this.prefabDic.has(e)?((i=z.instantiate(this.prefabDic.get(e))).name=e,console.log("正在克隆中>>>>>"+e+"__id:"+i.id),i):null}var i;return this.prefabDic.has(e)?((i=z.instantiate(this.prefabDic.get(e))).name=e,console.log("正在克隆中>>>>>"+e+"__id:"+i.id),i):null}onStateEnter(){console.log("动画开始播放了")}onStateUpdate(){console.log("动画状态更新了")}onStateExit(){console.log("动画退出了")}GetByType(e){var t;return e==G.WarnTips?((t=new Laya.Text).width=720,t.height=60,t.align="center",t.valign="middle",t.fontSize=35,t.bold=!0,t.pivotX=360,t.pivotY=30,t.color="#ffffff",t.stroke=5,t.strokeColor="#000000",t):e==G.HpText?((t=new Laya.Text).font="Microsoft YaHei",t.width=260,t.height=50,t.align="center",t.valign="middle",t.fontSize=30,t.bold=!0,t.pivotX=130,t.pivotY=25,t.color="#ffffff",t):void 0}}U.modeltype={Mound:"Mound",PlayerShoot:"PlayerShoot",Player:"Character",Enemy:"enemy"},U.bulletCount=0;class O{constructor(e,t=0,i=0,a=0){this.m_t=0,this.target=0,this.follow=0,this.m_tiny=0,this.m_t=e,this.target=i,this.follow=t,this.m_tiny=a}ChangeT(e){this.m_t=e}get t(){return this.m_t}update(){this.follow=F.MixNumber(this.follow,this.target,this.m_t),0!=this.m_tiny&&this.target!=this.follow&&Math.abs(this.target-this.follow)<=this.m_tiny&&(this.follow=this.target)}}class F{static get VecZero(){return new Laya.Vector3}static RandomNumber(e,t){if(e>=t)return 0;var i=t-e;return Math.random()*i+e}static SpToCam(e){return e.x=-e.x,e.y=e.y-180,e.z=-e.z,e}static MixVector3(e,t,i,a=null){return null==a&&(a=this.m_mixVector),a.x=F.MixNumber(e.x,t.x,i),a.y=F.MixNumber(e.y,t.y,i),a.z=F.MixNumber(e.z,t.z,i),a}static MixNumber(e,t,i){return e=(t-e)*(i=F.Clamp(i,0,1))+e}static Clamp(e,t,i){return ei&&(e=i),e}}F.m_mixVector=new Laya.Vector3,function(e){e[e.mound=8]="mound",e[e.wall=9]="wall",e[e.opponent=10]="opponent",e[e.obstacle1=11]="obstacle1",e[e.obstacle2=12]="obstacle2",e[e.obstacle3=13]="obstacle3"}(H||(H={}));class W{onPreLoadFinish(){var e=this.scene.addChild(Laya.Loader.getRes("res/threeDimen/skinModel/LayaMonkey/LayaMonkey.lh")),t=Laya.Loader.getRes("res/threeDimen/skinModel/LayaMonkey2/LayaMonkey.lh");t.transform.translate(new Laya.Vector3(2.5,0,0));var i=new Laya.Vector3(.5,.5,.5);t.transform.localScale=i,e.addChild(t),this.addButton(100,120,160,30,"移动父级猴子",20,function(t){e.transform.translate(new Laya.Vector3(-.1,0,0))}),this.addButton(100,160,160,30,"放大父级猴子",20,function(t){var i=new Laya.Vector3(.2,.2,.2);e.transform.localScale=i}),this.addButton(100,200,160,30,"旋转父级猴子",20,function(t){e.transform.rotate(new Laya.Vector3(-15,0,0),!0,!1)}),this.addButton(100,250,160,30,"移动子级猴子",20,function(e){t.transform.translate(new Laya.Vector3(-.1,0,0))}),this.addButton(100,290,160,30,"放大子级猴子",20,function(e){var i=new Laya.Vector3(1,1,1);t.transform.localScale=i}),this.addButton(100,330,160,30,"旋转子级猴子",20,function(e){t.transform.rotate(new Laya.Vector3(-15,0,0),!0,!1)})}addButton(e,t,i,a,n,s,o){Laya.loader.load(["res/threeDimen/ui/button.png"],Laya.Handler.create(null,function(){var r=Laya.stage.addChild(new Laya.Button("res/threeDimen/ui/button.png",n));r.size(i,a),r.labelBold=!0,r.labelSize=s,r.sizeGrid="4,4,4,4",r.scale(Laya.Browser.pixelRatio,Laya.Browser.pixelRatio),r.pos(e,t),r.on(Laya.Event.CLICK,this,o)}))}}W.Idle="Idle",W.CrouchFiring="CrouchFiring",W.Dance="Dance",W.RunAndGun="RunAndGun",W.RunningHysteric="RunningHysteric";var j=Laya.Text;class q{static get Instance(){return this.instance||(this.instance=new q)}CameraFollow(e){this.Camera&&this.Camera.MoveGame(e)}Init(e,t){this.startPosTra=t.transform,e&&(this._maincamera=e,this.Camera=this._maincamera.addComponent(Qe),this.Camera.Init())}createSampleText(){var e=new j;return e.overflow=j.HIDDEN,e.color="#FFFFFF",e.font="Impact",e.fontSize=20,e.borderColor="#FFFF00",e.x=80,Laya.stage.addChild(e),e.text="A POWERFUL HTML5 ENGINE ON FLASH TECHNICAL\nA POWERFUL HTML5 ENGINE ON FLASH TECHNICAL\nA POWERFUL HTML5 ENGINE ON FLASH TECHNICAL",e}SetCameraAction(e,t){this.Camera&&this.Camera.CameraAction(e,t)}}var X=Laya.BitmapFont,Y=Laya.Text,Z=Laya.Handler;class J{constructor(){this.tarDis=30,this.constructArr=[],this.fontName="diyFont"}static get Instance(){return this.instance||(this.instance=new J)}Init(e){this.constructArr.push(e.getChildAt(2)),this.constructArr.push(e.getChildAt(1)),this.constructArr.push(e.getChildAt(0))}CheckMainRolePos(e){this.tarDis-e>0||this.SwitchRoad()}loadFont(){var e=new X;e.loadFont("res/bitmapFont/test.fnt",new Z(this,this.onFontLoaded,[e]))}onFontLoaded(e){e.setSpaceWidth(10),Y.registerBitmapFont(this.fontName,e),this.createText(this.fontName)}createText(e){var t=new Y;t.width=250,t.wordWrap=!0,t.text="Do one thing at a time, and do well.",t.font=e,t.leading=5,t.pos(Laya.stage.width-t.width>>1,Laya.stage.height-t.height>>1),Laya.stage.addChild(t)}SwitchRoad(){let e=this.constructArr.pop();e.transform.localPositionZ=this.tarDis+60,this.constructArr.unshift(e),this.tarDis=this.tarDis+30}SetConstruct(){for(let e=this.constructArr.length-1;e>=0;e--){this.constructArr[e].transform.localPositionZ=30*(2-e)}this.tarDis=30}}var K=Laya.Sprite,$=Laya.Handler;class Q{static get Instance(){return Q.instance||(Q.instance=new Q)}showApe(){var e=new K;Laya.stage.addChild(e),e.loadImage("res/apes/monkey3.png"),Laya.loader.load("res/apes/monkey2.png",$.create(this,function(){var e=Laya.loader.getRes("res/apes/monkey2.png"),t=new K;t.graphics.drawTexture(e,0,0),Laya.stage.addChild(t),t.pos(200,0)}))}SetLevel(e){let i=g.Instance._level.length,a=v.Instance.stage;v.Instance.stage>i&&(a=t.randomInt(1,i)),this.curLevelData=g.Instance.GetLevel(a),this._level||(this._level=new ee),this._level.SetLevel(this.curLevelData)}}class ee{constructor(){this.road_list=[],this.fail_gold=0}createApes(){var e=Math.PI/2;this.apesCtn=new K,Laya.stage.addChild(this.apesCtn);for(var t=0;t<4;t++){var i=new K;i.loadImage("res/apes/monkey"+t+".png"),i.pivot(55,72),i.pos(150*Math.cos(e*t),150*Math.sin(e*t)),this.apesCtn.addChild(i)}this.apesCtn.pos(Laya.stage.width/2,Laya.stage.height/2)}SetLevel(e){this.road_list=t.SpliteString(e.road_list),this.gold=Number(e.gold),this.fail_gold=Number(e.fail_gold),this.enemy=e.enemy,this.enemy_hp=e.enemy_hp,this.isgold=1==Number(e.isgold),this.enemy_cloth=e.enemy_cloth?Number(e.enemy_cloth):1}}class te{static get Instance(){return this.instance||(this.instance=new te)}constructor(){this.MoundrDic=new i}Init(e){this.moundContainer=e}MakeMound(e){let t=U.Instance.GetModel(U.modeltype.Mound);if(!t)return;this.moundContainer.addChild(t);let i=t.getComponent(_e);i||(i=t.addComponent(_e)),i.SetMound(e),this.MoundrDic.set(t.id,i)}Reset(){let e=[];for(const t in this.MoundrDic.container)e.push(t);if(e.length>0)for(let t=0;t1&&(i=1),180*Math.acos(i)/Math.PI}}var ae=Laya.Sprite;class ne{constructor(){this.attackmaxcount=0,this.explodemaxcount=0}static get Instance(){return ne.instance||(ne.instance=new ne)}AttackEffect(e){if(this.attackmaxcount>=x.hitmaxcount)return;let t=U.Instance.GetModel("Hit");t.transform.position=e,it.Instance.effectCon.addChild(t),this.attackmaxcount++,Laya.timer.once(800,this,this.RecoverEffect,[t],!1)}RecoverEffect(e){U.Instance.RecoverModel(e),this.attackmaxcount--}mapLoaded(){this.layer=this.tiledMap.getLayerByIndex(0);var e=32*Math.tan(180/Math.PI*30);this.sprite=new ae,this.sprite.graphics.drawLine(0,0,-32,e,"#FF7F50"),this.sprite.graphics.drawLine(0,0,32,e,"#FF7F50"),this.sprite.graphics.drawLine(-32,e,0,2*e,"#FF7F50"),this.sprite.graphics.drawLine(32,e,0,2*e,"#FF7F50"),Laya.stage.addChild(this.sprite)}ExplodeEffect(e){if(this.explodemaxcount>=x.boommaxcount)return;let t=U.Instance.GetModel("Explode");t.transform.position=e,it.Instance.effectCon.addChild(t),this.explodemaxcount++,Laya.timer.once(800,this,this.RecoverExpolde,[t],!1)}RecoverExpolde(e){U.Instance.RecoverModel(e),this.explodemaxcount--}BloodEffect(e){let t=U.Instance.GetModel("Blood");t.transform.position=e,it.Instance.effectCon.addChild(t),Laya.timer.once(800,this,this.RecoverBlood,[t],!1)}RecoverBlood(e){U.Instance.RecoverModel(e)}}var se=Laya.Event,oe=Laya.MouseManager,re=Laya.MovieClip,he=Laya.Animation;class le{constructor(){this.SWFPath="res/swf/dragon.swf",this.MCWidth=318,this.MCHeight=406,this._switch=!1,this._isCanClick=!0,this.clickD=!1,this._mousePos=F.VecZero,this.tempMouse=F.VecZero,this.clickCount=0,this.mStartX=400,this.mStartY=500,this.mActionIndex=0,this.mCurrIndex=0,this.mCurrSkinIndex=0}static get Instance(){return this.instance||(this.instance=new le)}InitMouseEvent(){Laya.stage.on(se.MOUSE_DOWN,this,this.OnClickDown),Laya.stage.on(se.MOUSE_OUT,this,this.OnClickUp)}createMovieClip(){var e=new re;e.load(this.SWFPath),e.x=(Laya.stage.width-this.MCWidth)/2,e.y=(Laya.stage.height-this.MCHeight)/2,Laya.stage.addChild(e)}OnClickDown(e){this._isCanClick&&this._switch&&(e.target instanceof Laya.UIComponent||(this.clickD=!0,Laya.stage.on(se.MOUSE_UP,this,this.OnClickUp),Laya.stage.on(se.MOUSE_MOVE,this,this.OnSlider),this._mousePos.x=oe.instance.mouseX,this._mousePos.y=oe.instance.mouseY,this.MouseD()))}StartGameClick(){this._switch=!0,this._isCanClick&&(this.clickD=!0,Laya.stage.on(se.MOUSE_UP,this,this.OnClickUp),Laya.stage.on(se.MOUSE_MOVE,this,this.OnSlider),this._mousePos.x=oe.instance.mouseX,this.MouseD())}MouseD(){Je.Instance.SetModelPos(this._mousePos.x),Je.Instance.CreateShoot()}OnClickUp(e){this._isCanClick&&this._switch&&this.clickD&&this.MouseU()}createAnimation(){var e=new he;e.interval=30,e.index=1,e.play();var t=e.getGraphicBounds();e.pivot(t.width/2,t.height/2),e.pos(Laya.stage.width/2,Laya.stage.height/2),Laya.stage.addChild(e)}OffMouseEvent(){Laya.stage.off(se.MOUSE_DOWN,this,this.OnClickDown),Laya.stage.off(se.MOUSE_UP,this,this.OnClickUp),Laya.stage.off(se.MOUSE_OUT,this,this.OnClickUp)}MouseU(){this.clickD=!1,Laya.stage.off(se.MOUSE_MOVE,this,this.OnSlider),Laya.stage.off(se.MOUSE_UP,this,this.OnClickUp)}OnSlider(e){this.tempMouse.x=oe.instance.mouseX;let t=this.tempMouse.x-this._mousePos.x;t>=0&&(t=t<20?t:20),t<0&&(t=t>-20?t:-20),Je.Instance.PlayerSlip(-t),this._mousePos.x=this.tempMouse.x,this._mousePos.y=this.tempMouse.y}OpenInput(){this.clickCount++,this.clickCount>1||(this._isCanClick=!0)}CloseInput(){this.clickCount--,this.clickCount>0||(this._isCanClick=!1,this.clickD=!1)}set _Switch(e){this._switch=e}play(){this.mCurrIndex++,this.mCurrIndex>=this.mArmature.getAnimNum()&&(this.mCurrIndex=0),this.mArmature.play(this.mCurrIndex,!1)}onEvent(e){var t=e;Laya.stage.addChild(this.mLabelSprite),this.mLabelSprite.x=this.mStartX,this.mLabelSprite.y=this.mStartY,this.mLabelSprite.graphics.clear(),this.mLabelSprite.graphics.fillText(t.name,0,0,"20px Arial","#ff0000","center")}}var ce=Laya.Sprite,de=Laya.ColorFilter;class pe extends Laya.Script3D{constructor(){super(...arguments),this.rotate=F.VecZero,this.speed=F.VecZero,this.ApePath="res/apes/monkey2.png"}onAwake(){this.selfobj=this.owner,this.tran=this.selfobj.transform}SetMoveType(){5==this.thing.type?this._transform=this.selfobj.getChildAt(0).transform:(this._transform=this.tran,4==this.thing.type&&Ie.Instance.StreetAddCube(this.selfobj)),1!=this.thing.moveType?2==this.thing.moveType?(this.rotate.x=0,this.rotate.y=-this.thing.moveSpeed,this.rotate.z=0,Laya.timer.frameLoop(2,this,this.MoveType2)):3==this.thing.moveType?(this.rotate.x=0,this.rotate.y=this.thing.moveSpeed,this.rotate.z=0,Laya.timer.frameLoop(2,this,this.MoveType2)):4==this.thing.moveType?(this.rotate.x=0,this.rotate.y=0,this.rotate.z=this.thing.moveSpeed,Laya.timer.frameLoop(1,this,this.MoveType3)):5==this.thing.moveType?(this.rotate.x=0,this.rotate.y=0,this.rotate.z=-this.thing.moveSpeed,Laya.timer.frameLoop(1,this,this.MoveType3)):6==this.thing.moveType?(this.speed.x=-this.thing.moveSpeed,this.speed.y=0,this.speed.z=0,Laya.timer.frameLoop(1,this,this.MoveType4)):7==this.thing.moveType?(this.speed.x=this.thing.moveSpeed,this.speed.y=0,this.speed.z=0,Laya.timer.frameLoop(1,this,this.MoveType4)):8==this.thing.moveType||this.thing.moveType:Laya.timer.frameLoop(3,this,this.CheckRecover)}setup(){this.normalizeApe(),this.makeRedApe(),this.grayingApe()}normalizeApe(){var e=this.createApe();this.apeTexture=Laya.loader.getRes(this.ApePath),e.x=(Laya.stage.width-3*this.apeTexture.width)/2,e.y=(Laya.stage.height-this.apeTexture.height)/2}makeRedApe(){var e=new de([1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0]),t=this.createApe();t.filters=[e];var i=Laya.stage.getChildAt(0);t.x=i.x+this.apeTexture.width,t.y=i.y}grayingApe(){var e=new de([.3086,.6094,.082,0,0,.3086,.6094,.082,0,0,.3086,.6094,.082,0,0,0,0,0,1,0]),t=this.createApe();t.filters=[e];var i=Laya.stage.getChildAt(1);t.x=i.x+this.apeTexture.width,t.y=i.y}createApe(){var e=new ce;return e.loadImage("res/apes/monkey2.png"),Laya.stage.addChild(e),e}MoveType4(){this._transform.translate(this.speed),Math.abs(this._transform.localPositionX)>=x.blockLRmoveMaxDis&&(this.speed.x=-this.speed.x),this.CheckRecover()}MoveType2(){this._transform.rotate(this.rotate),this.CheckRecover()}MoveType3(){this._transform.rotate(this.rotate),Math.abs(this._transform.localRotationEulerZ)>=50&&(this.rotate.z=-this.rotate.z),this.CheckRecover()}Recover(){this.thing.type&&Ie.Instance.StreetResetCube(this.selfobj.id),Laya.timer.clearAll(this),Ie.Instance.RecoverStreet(this.selfobj),U.Instance.RecoverModel(this.selfobj)}CheckRecover(){if(this.tarTran.localPositionZ-this.tran.localPositionZ>=10)return console.log("回收block",this.selfobj.name),void this.Recover()}SetStreet(e){this.tran.localPositionZ=Number(e.z),this.tran.localPositionX=Number(e.x),this.tran.rotationEuler=F.VecZero,this.thing=e,Je.Instance.player&&(this.tarTran=Je.Instance.player.transform,this.SetMoveType())}}var ge=Laya.Input;class ue{constructor(){this.guideonepos=new Laya.Vector3(2.5,0,59.4),this.guidetwoPos=new Laya.Vector3(-5,2,104.4),this.index=0,this._guide=!1}static get Instance(){return this.instance||(this.instance=new ue)}GuideOn(){this._guide&&Laya.timer.once(500,this,this.Guide)}Guide(){}GuideOff(){this._guide=!1,Mt.Instance.CloseGuideView()}GameOver(){this._guide&&Mt.Instance.CloseGuideView()}createInput(){var e=new ge;e.size(350,100),e.x=Laya.stage.width-e.width>>1,e.y=Laya.stage.height-e.height>>1,e.text="这段文本不可编辑,但可复制",e.editable=!1,e.bold=!0,e.bgColor="#666666",e.color="#ffffff",e.fontSize=20,Laya.stage.addChild(e)}InitGuide(e){0==this.index?(this.guideonepos.z=e,this.index++):1==this.index&&(this.guidetwoPos.z=e,this.index++)}RequireGuide(){Laya.LocalStorage.getItem("guide");return 1==v.Instance.stage?(Laya.LocalStorage.setItem("guide","1"),this._guide=!0,!0):(this._guide=!1,!1)}}var ye=Laya.Sprite;class me{constructor(e,t){this.blocks=e,this.blockPos=t}}class we{constructor(e,t,i){this.things=e,this.thingPos=t,this.blockHp=i}}class fe{constructor(e,t,i,a){this.type=e,this.prrfabName=t,this.moveType=i,this.moveSpeed=a}}class Ie{constructor(){this.isover=!1,this.curindex=1,this.texture1="res/apes/monkey2.png",this.texture2="res/apes/monkey3.png",this.flag=!1,this.blockDic=new i,this.cubeBlockDic=new i}static get Instance(){return Ie.instance||(Ie.instance=new Ie)}Init(e){this.BlockContainer=e}SetBlock(){this.isover=!1,this.curindex=1,this.CreateStreet()}onAssetsLoaded(){this.ape=new ye,Laya.stage.addChild(this.ape),this.ape.pivot(55,72),this.ape.pos(Laya.stage.width/2,Laya.stage.height/2),this.switchTexture(),this.ape.on("click",this,this.switchTexture)}switchTexture(){var e=(this.flag=!this.flag)?this.texture1:this.texture2;this.ape.graphics.clear();var t=Laya.loader.getRes(e);this.ape.graphics.drawTexture(t,0,0),this.ape.size(t.width,t.height)}CheckPlayerRoadPos(e){if(this.isover)return;this.tarDis-e>0||this.StreetSwitch()}StreetSwitch(){this.curindex++,this.CreateStreet()}CreateSprite(e){ue.Instance._guide&&ue.Instance.InitGuide(e.blockPos[0]);let t=e.blocks,i=e.blockPos,a=0;for(let e=0;e1;for(let e=0;e0)for(let i=0;ie.length-1)return this.isover=!0,void console.log("没有障碍物了");this.tarDis=this.curindex*x.barrierRoadLength;let i=e[this.curindex];if(0==i)return;let a=g.Instance.GetRoad(i);if(!a)return;let n=t.SpliteString(a.blocks),s=t.SpliteString(a.position),o=[],r=x.barrierRoadLength/x.barrierRoadAverageNum;s.forEach(e=>{o.push(this.tarDis+e*r)});let h=[];n.forEach(e=>{let i=g.Instance.GetStreet(e),a=t.SpliteString(i.block_things),n=t.SpliteString(i.thing_position),s=t.SpliteString(i.block_hp),o=[];a.forEach(e=>{let t=g.Instance.GetThing(e),i=new fe(t.type,t.prefabs,t.dynamic_type,t.dynamic_speed);o.push(i)});let r=new we(o,n,s);h.push(r)});let l=new me(h,o);this.CreateSprite(l)}}var ve=Laya.Vector3,xe=Laya.Quaternion,Le=Laya.Animation,Se=Laya.Tween;class be extends Laya.Script3D{constructor(){super(...arguments),this._up=new ve(0,1,0),this.isArrive1=!1,this.phoenixWidth=550,this.phoenixHeight=400,this.bgColorTweener=new Se,this.gradientInterval=2e3,this.bgColorChannels={r:99,g:0,b:255}}onAwake(){this.selfobj=this.owner,this.tran=this.selfobj.transform,this.forW=F.VecZero,this.speed=x.enemySpeed,this.quaternion1=new xe}Run(){if(this.isArrive1){if(null==this.tarSp)return;if(!this.tarSp.active){if(this.tarSp=Ce.Instance.GetTar(),null==this.tarSp)return;this.tarPos=this.tarSp.transform.position.clone()}if(ve.subtract(this.tarPos,this.tran.position,this.forW),ve.normalize(this.forW,this.forW),this.forW=new ve(this.forW.x*this.speed,this.forW.y*this.speed,this.forW.z*this.speed),this.tran.translate(this.forW,!1),ve.distance(this.tran.position,this.tarPos)<.1)return;xe.lookAt(this.tarPos,this.tran.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this.tran.rotation=this.quaternion1.clone()}else{if(ve.subtract(this.tarPos,this.tran.position,this.forW),ve.normalize(this.forW,this.forW),this.forW=new ve(this.forW.x*this.speed,this.forW.y*this.speed,this.forW.z*this.speed),this.tran.translate(this.forW,!1),ve.distance(this.tran.position,this.tarPos)<.1){if(this.tarSp=Ce.Instance.GetTar(),this.isArrive1=!0,null==this.tarSp)return;return void(this.tarPos=this.tarSp.transform.position.clone())}xe.lookAt(this.tarPos,this.tran.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this.tran.rotation=this.quaternion1.clone()}}createPhoenixes(){var e=Math.min(Laya.stage.width/(2*this.phoenixWidth),Laya.stage.height/this.phoenixHeight),t=this.createAnimation();t.blendMode="lighter",t.scale(e,e),t.y=(Laya.stage.height-this.phoenixHeight*e)/2;var i=this.createAnimation();i.scale(e,e),i.x=this.phoenixWidth*e,i.y=(Laya.stage.height-this.phoenixHeight*e)/2}createAnimation(){var e=new Le;e.loadImages([]),Laya.stage.addChild(e);var t=e.frames.concat();return t=t.reverse(),e.frames=e.frames.concat(t),e.play(),e}Recovery(){Laya.timer.clearAll(this),Ce.Instance.RecoverEnemy(this.selfobj),U.Instance.RecoverModel(this.selfobj)}InitModel(e,t,i){this.tarSp=e,this.isArrive1=!1,null!=this.tarSp&&(this.tarPos=this.tarSp.transform.position.clone(),this.tarPos.x>0?this.tarPos=Ue.Instance.toured1.clone():this.tarPos=Ue.Instance.toured2.clone(),this.hp=t,Laya.timer.frameLoop(1,this,this.Run))}Injured(e){this.hp-=v.bulletAttack,this.hp<=0?this.Dead():ne.Instance.AttackEffect(e)}Dead(){ne.Instance.BloodEffect(this.tran.position),this.Recovery(),Ce.Instance.CheckGameOver(),Me.Instance.roleCount++}}var ke=Laya.Sprite;class Ce{constructor(){this.frameCount=10,this.enemyDic=new i}static get Instance(){return this.instance||(this.instance=new Ce)}Create(e,t){let i=U.Instance.GetModel(U.modeltype.Enemy);if(!i)return;Je.Instance.playerContainer.addChild(i),i.transform.position=this.startPos.clone();let a=i.getComponent(be);a||(a=i.addComponent(be));let n=this.GetTar();a.InitModel(n,e,t),this.enemyDic.set(i.id,a)}CheckGameOver(){0==this.enemyDic.size&&(le.Instance.OnClickUp(),Je.Instance.CreateOver(),Me.Instance.Congratulate())}GetOpponent(){for(const e in this.enemyDic.container){return this.enemyDic.get(e).selfobj}return null}Reset(){let e=[];for(const t in this.enemyDic.container)e.push(t);if(e.length>0)for(let t=0;t.5)return Je.Instance.playerScript.body;{let e=Ge.Instance.GetSprite();return e||Je.Instance.playerScript.body}}RecoverEnemy(e){this.enemyDic.delete(e.id)}}class Me{constructor(){this.towerCount=0,this.roleCount=0,this.blockCount=0}static get Instance(){return Me.instance||(Me.instance=new Me)}Start(){this.towerCount=0,this.roleCount=0,this.blockCount=0}Win(){D.LongVibrate(),Me.WINORLOSE=!0,_t.iswhite&&1==Me.GameCount?Mt.Instance.AddView(mt.ExitView,!0):Mt.Instance.AddView(mt.CompleteView,!0),te.Instance.Reset(),Ie.Instance.Reset(),Ge.Instance.Reset(),Je.Instance.Reset(),Ce.Instance.Reset()}Congratulate(e=!1){Je.Instance.GoToTiaoWu(),e?Ge.Instance.TiaoWu1():Ge.Instance.TiaoWu(),q.Instance.SetCameraAction(Ke.jump,.03),Laya.timer.once(4e3,this,this.Win)}Over(){ue.Instance.GameOver(),le.Instance.OnClickUp(),Je.Instance.CreateOver(),le.Instance._Switch=!1,D.LongVibrate(),Me.WINORLOSE=!1,_t.iswhite&&1==Me.GameCount?Mt.Instance.AddView(mt.ExitView,!0):Mt.Instance.AddView(mt.CompleteView,!1),te.Instance.Reset(),Ie.Instance.Reset(),Ge.Instance.Reset(),Je.Instance.Reset(),Je.Instance.HidePlayer(),Ce.Instance.Reset()}loadUI(){Laya.loader.load(["res/threeDimen/ui/button.png"],Laya.Handler.create(this,function(){this.changeActionButton=Laya.stage.addChild(new Laya.Button("res/threeDimen/ui/button.png","切换Mesh")),this.changeActionButton.size(160,40),this.changeActionButton.labelBold=!0,this.changeActionButton.labelSize=30,this.changeActionButton.sizeGrid="4,4,4,4",this.changeActionButton.scale(Laya.Browser.pixelRatio,Laya.Browser.pixelRatio),this.changeActionButton.pos(Laya.stage.width/2-this.changeActionButton.width*Laya.Browser.pixelRatio/2,Laya.stage.height-100*Laya.Browser.pixelRatio),this.changeActionButton.on(Laya.Event.CLICK,this,function(){this.index++,this.index%5==1?this.sphere.meshFilter.sharedMesh=this.box:this.index%5==2?this.sphere.meshFilter.sharedMesh=this.capsule:this.index%5==3?this.sphere.meshFilter.sharedMesh=this.cylinder:this.index%5==3?this.sphere.meshFilter.sharedMesh=this.cone:this.sphere.meshFilter.sharedMesh=this.sphereMesh})}))}Near(){te.Instance.Reset(),Ie.Instance.Reset()}ReStart(){Ge.Instance.Reset(),it.Instance.InItScene(),a.event(n.Event.ShowMainUi),a.event(n.Event.SetStagePro,0)}LevelUp(){v.Instance.stage++,it.Instance.InItScene(),Mt.Instance.CloseView(mt.CompleteView),a.event(n.Event.ShowMainUi),a.event(n.Event.SetStage),a.event(n.Event.SetStagePro,0)}}Me.GameNum=0,Me.WINORLOSE=!1,Me.GameCount=0;class _e extends Laya.Script3D{constructor(){super(...arguments),this.guideSteps=[{x:151,y:575,radius:150,tip:"res/guide/help6.png",tipx:200,tipy:250},{x:883,y:620,radius:100,tip:"res/guide/help4.png",tipx:730,tipy:380},{x:1128,y:583,radius:110,tip:"res/guide/help3.png",tipx:900,tipy:300}],this.guideStep=0}onAwake(){this.selfobj=this.owner,this.tran=this.selfobj.transform,this.FriendSpawnPoint=this.selfobj.getChildByName("FriendSpawnPoint").transform,this.HealthText=this.selfobj.getChildByName("HealthText").transform;let e=this.selfobj.getChildByName("WallsEnd");this.WallsEnd=e.transform,this._reflect=e.getChildAt(0).meshRenderer.material}HpUi(){let e=ie.WorldToScreen2(this._camera,this.HealthText.position.clone());e.x<=0||e.x>=Laya.stage.width||e.y<=0||e.y>=Laya.stage.height?this.hpText.visible=!1:(this.hpText.visible||(this.hpText.visible=!0),this.hpText.x=e.x,this.hpText.y=e.y)}CheckHp(){this.tarTran.localPositionZ-this.tran.localPositionZ>=5?this.Recovery():this.HpUi()}nextStep(){if(this.guideStep==this.guideSteps.length)Laya.stage.removeChild(this.guideContainer),Laya.stage.removeChild(this.tipContainer);else{var e=this.guideSteps[this.guideStep++];this.hitArea.unHit.clear(),this.hitArea.unHit.drawCircle(e.x,e.y,e.radius,"#000000"),this.interactionArea.graphics.clear(),this.interactionArea.graphics.drawCircle(e.x,e.y,e.radius,"#000000"),this.tipContainer.graphics.clear(),this.tipContainer.loadImage(e.tip),this.tipContainer.pos(e.tipx,e.tipy)}}MakeMate(){this._mate=Ge.Instance.MadeMate(this.FriendSpawnPoint)}Rescue(){this._mate&&(this._mate.FallDown(),this._mate=null)}ReflectSet(){this._reflect.albedoIntensity=4,Laya.timer.once(100,this,()=>{this._reflect.albedoIntensity=1})}Recovery(){Laya.timer.clearAll(this),this.hpText&&(U.Instance.RecoverUi(G.HpText,this.hpText),this.hpText=null),this._reflect.albedoIntensity=1,te.Instance.RecoverMound(this.selfobj),U.Instance.RecoverModel(this.selfobj),this._mate&&(this._mate.Recover(),this._mate=null)}Injured(e){if(this._hp-=v.bulletAttack,this._hp<=0)return this.Rescue(),ne.Instance.ExplodeEffect(this.tran.position),this.Recovery(),void Me.Instance.towerCount++;ne.Instance.AttackEffect(e);let t=Math.ceil(this._hp);this.hpText.text=t.toString(),this.ReflectSet()}SetMound(e){this._mate=null,this.tarTran=Je.Instance.player.transform,this.tran.localPositionX=e.x,this.tran.localPositionY=0,this.tran.localPositionZ=e.z,e.towerR?this.WallsEnd.localRotationEulerY=30:this.WallsEnd.localRotationEulerY=0,1==e.type&&this.MakeMate(),this._hp=e.hp,this.hpText||(this.hpText=te.Instance.HpUi(),this.hpText.text=this._hp.toString(),this._camera||(this._camera=q.Instance._maincamera),Mt.Instance.popNode.addChild(this.hpText)),this.HpUi(),Laya.timer.frameLoop(1,this,this.CheckHp)}}var Be=Laya.Vector3,Re=Laya.Sprite;class Te extends Laya.Script3D{constructor(){super(...arguments),this.speed=F.VecZero,this._forward=new Be(0,0,1),this.over=!1}onAwake(){this.selfobj=this.owner,this.tran=this.selfobj.transform,this.rayPoint=this.selfobj.getChildByName("rayPoint").transform,this.speed.z=x.shootspeed}Run(){this.tran.translate(this.speed),Be.distance(this.tarTran.position,this.tran.position)>=x.bulletMaxDis?this.RecoverBullet():this.RayReset()}RecoverBullet(){Laya.timer.clearAll(this),U.Instance.RecoverModel(this.selfobj),U.bulletCount--}drawSomething(){this.sp=new Re,Laya.stage.addChild(this.sp),this.sp.graphics.drawLine(10,58,146,58,"#ff0000",3),this.sp.graphics.drawLines(176,58,[0,0,39,-50,78,0,117,50,156,0],"#ff0000",5),this.sp.graphics.drawCurves(352,58,[0,0,19,-100,39,0,58,100,78,0,97,-100,117,0,136,100,156,0],"#ff0000",5),this.sp.graphics.drawRect(10,166,166,90,"#ffff00"),this.sp.graphics.drawPoly(264,166,[0,0,60,0,78.48,57,30,93.48,-18.48,57],"#ffff00"),this.sp.graphics.drawPoly(400,166,[0,100,50,0,100,100],"#ffff00"),this.sp.graphics.drawCircle(98,332,50,"#00ffff"),this.sp.graphics.drawPie(240,290,100,10,60,"#00ffff"),this.sp.graphics.drawPath(400,310,[["moveTo",5,0],["lineTo",105,0],["arcTo",110,0,110,5,5],["lineTo",110,55],["arcTo",110,60,105,60,5],["lineTo",5,60],["arcTo",0,60,0,55,5],["lineTo",0,5],["arcTo",0,0,5,0,5],["closePath"]],{fillStyle:"#00ffff"})}RayReset(){let e=this.rayPoint.position.clone();if(this._scene||(this._scene=it.Instance.MainScene),this.ray||(this.forward||(this.forward=F.VecZero),this.ray=new Laya.Ray(F.VecZero,this._forward),this.outHit=new Laya.HitResult),this.ray.origin=e,this.over?(this.tran.getForward(this.forward),this.forward.x=-this.forward.x,this.forward.y=-this.forward.y,this.forward.z=-this.forward.z,this.ray.direction=this.forward):this.ray.direction=this._forward,this._scene.physicsSimulation.rayCast(this.ray,this.outHit,x.bulletRayLength)){let e=this.outHit.collider.owner;if(e.layer==H.mound){let t=e.getComponent(_e);t&&t.Injured(this.outHit.point)}else if(e.layer==H.opponent){let t=e.getComponent(be);t&&t.Injured(this.outHit.point)}else e.layer==H.obstacle1||e.layer==H.obstacle2||e.layer==H.obstacle3?(Ie.Instance.StreetAtkedCube(e),Me.Instance.blockCount++):ne.Instance.AttackEffect(this.outHit.point);this.RecoverBullet()}else;}Start(e,t=!1){this.tarTran=e,this.over=t,Laya.timer.frameLoop(1,this,this.Run)}}var Ve=Laya.Vector3,Ae=Laya.Quaternion,Pe=Laya.Sprite,Ee=Laya.Text;class Ne extends Laya.Script3D{constructor(){super(...arguments),this._up=new Ve(0,1,0),this.isreturn=!1,this.isover=!1,this.isClickCom=!0,this.isStop=!0,this.texture1="res/apes/monkey2.png",this.texture2="res/apes/monkey3.png",this.flag=!1,this.isFristShoot=!0,this.ts=new Ve(0,0,.01)}onAwake(){this.selfobj=this.owner,this.tran=this.selfobj.transform,this.animator=this.selfobj.getChildAt(0).getComponent(Laya.Animator),this.rayPoint=this.selfobj.getChildByName("rayPoint").transform,this.bulletPos=this.selfobj.getChildByName("bulletPos").transform,this.forW=F.VecZero,this.speed=x.matespeed,this.quaternion1=new Ae}setup(){for(var e,t=new Pe,i=0;i<1e3;i++)(e=new Ee).fontSize=20,e.text=(100*Math.random()).toFixed(0),e.rotation=360*Math.random(),e.color="#CCCCCC",e.x=Math.random()*Laya.stage.width,e.y=Math.random()*Laya.stage.height,t.addChild(e);t.cacheAs="bitmap",Laya.stage.addChild(t)}TrialAdd(e){this.AnimatorPlayByType(W.Idle,1),this.dataPar=e,this.dataPar.ishave=!0,this.isClickCom=!0,this.isStop=!0,this.isreturn=!0,this.isover=!1,Ge.Instance.AddModelToDic(this.selfobj.id,this),this.ShootFunc(),Je.Instance.IsShoot()&&this.CreateShoot(),Laya.timer.frameLoop(1,this,this.Move)}SetTar(){this.isreturn=!1,this.isClickCom=!0,this.isStop=!0,this.isover=!1,this.AnimatorPlayByType(W.Idle,1),a.off(n.Event.StopShot,this,this.StopCreate)}FallDown(){let e=Laya.Tween.to(this.tran,{localPositionY:0},400,Laya.Ease.quintIn,Laya.Handler.create(this,()=>{let t=Je.Instance.GetMatePos();t?(this.dataPar=t,this.dataPar.ishave=!0,this.tar=this.dataPar.sp,this.tarTra=this.tar.transform,e.clear(),this.Start()):console.warn("friendPar没有位置了")},null,!1))}Start(){this.AnimatorPlayByType(W.RunAndGun,2),this.isreturn=!1,this.isClickCom=!0,this.isStop=!0,this.isover=!1,Laya.timer.frameLoop(1,this,this.Move)}ArriveTarPos(){this.isClickCom=!0,this.isStop=!0,this.isreturn=!0,this.tar.addChild(this.selfobj),this.tran.localPosition=F.VecZero,this.AnimatorPlayByType(W.RunAndGun,2),Ge.Instance.AddModelToDic(this.selfobj.id,this);let e=Laya.Tween.to(this.tran,{localRotationEulerY:0},100,Laya.Ease.quintIn,Laya.Handler.create(this,()=>{e.clear(),this.tran.localRotationEuler=F.VecZero,this.ShootFunc(),this.CreateShoot()},null,!1))}RayReset(){let e=this.rayPoint.position;if(this._scene||(this._scene=it.Instance.MainScene),this.rayF||(this.rayF=new Laya.Ray(F.VecZero,new Ve(0,0,1)),this.outHitF=new Laya.HitResult),this.rayF.origin=e,this._scene.physicsSimulation.rayCast(this.rayF,this.outHitF,x.playerRayLengthF)){this.outHitF.collider.owner;this.Dead(this.outHitF.point)}else if(this.rayL||(this.rayL=new Laya.Ray(F.VecZero,new Ve(1,0,0)),this.outHitL=new Laya.HitResult),this.rayL.origin=e,this._scene.physicsSimulation.rayCast(this.rayL,this.outHitL,x.playerRayLengthLR)){this.outHitL.collider.owner;this.Dead(this.outHitL.point)}else if(this.rayR||(this.rayR=new Laya.Ray(F.VecZero,new Ve(-1,0,0)),this.outHitR=new Laya.HitResult),this.rayR.origin=e,this._scene.physicsSimulation.rayCast(this.rayR,this.outHitR,x.playerRayLengthLR)){this.outHitR.collider.owner;this.Dead(this.outHitR.point)}else;}createApes(){this.ape1=new Pe,this.ape2=new Pe,this.ape1.loadImage("res/apes/monkey2.png"),this.ape2.loadImage("res/apes/monkey2.png"),this.ape1.pivot(55,72),this.ape2.pivot(55,72),this.ape1.pos(Laya.stage.width/2,Laya.stage.height/2),this.ape2.pos(200,0),Laya.stage.addChild(this.ape1),this.ape1.addChild(this.ape2),Laya.timer.frameLoop(1,this,this.animate)}animate(e){this.ape1.rotation+=2,this.ape2.rotation-=4}Move(){if(this.isreturn)return void this.RayReset();let e=this.tarTra.position.clone();Ve.subtract(e,this.tran.position,this.forW),Ve.normalize(this.forW,this.forW),this.forW=new Ve(this.forW.x*this.speed,this.forW.y*this.speed,this.forW.z*this.speed),this.tran.translate(this.forW,!1),Ve.distance(this.tran.position,e)<.1?this.ArriveTarPos():(Ae.lookAt(e,this.tran.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),Ae.slerp(this.tran.rotation,this.quaternion1,.1,this.quaternion1),this.tran.rotation=this.quaternion1.clone())}AnimatorPlayByType(e,t,i){this.animator.play(e),t||(t=1),this.animator.speed=t}ShootFunc(){a.on(n.Event.StopShot,this,this.StopCreate)}LoopCreate(){if(this.isStop)return Laya.timer.clear(this,this.LoopCreate),void(this.isClickCom=!0);this._CreateShoot()}CreateShoot(){this.isStop=!1,this.isClickCom&&(this.isClickCom=!1,this._CreateShoot(),Laya.timer.loop(2*v.bulletTime*1e3,this,this.LoopCreate))}_CreateShoot(){let e=U.Instance.GetModel(U.modeltype.PlayerShoot);if(e){it.Instance.bulletCon.addChild(e),e.transform.position=this.bulletPos.position.clone(),e.transform.localRotationEuler=this.bulletPos.rotationEuler.clone();let t=e.getComponent(Te);t||(t=e.addComponent(Te)),t.Start(this.bulletPos,this.isover)}}StopCreate(){this.isStop=!0}Dead(e){this.dataPar&&(this.dataPar.ishave=!1),ne.Instance.BloodEffect(e),Ge.Instance.RemoveModelToDic(this.selfobj),this.Recover(),Je.Instance.CheckGameOver()}SetPar(){let e=this.tran.position.clone();Je.Instance.playerContainer.addChild(this.selfobj),this.tran.position=e.clone()}TiaoWu(e){this.AnimatorPlayByType(W.RunAndGun,2),this.danceP=e.position.clone(),this.r=e.rotationEuler.clone(),Laya.timer.frameLoop(1,this,this._TiaoWu)}_TiaoWu(){if(Ve.subtract(this.danceP,this.tran.position,this.forW),Ve.normalize(this.forW,this.forW),this.forW=new Ve(.15*this.forW.x,.15*this.forW.y,.15*this.forW.z),this.tran.translate(this.forW),Ve.distance(this.tran.position,this.danceP)<.15)return Laya.timer.clear(this,this._TiaoWu),this.tran.position=this.danceP.clone(),this.tran.rotationEuler=this.r.clone(),void this.AnimatorPlayByType(W.Dance,1);Ae.lookAt(this.danceP,this.tran.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this.tran.rotation=this.quaternion1.clone()}onAssetsLoaded(){this.ape=new Pe,Laya.stage.addChild(this.ape),this.ape.pivot(55,72),this.ape.pos(Laya.stage.width/2,Laya.stage.height/2)}Attack(){Laya.timer.clear(this,this._Defense),this.isover=!0,this.isFristShoot=!0,this.enemyTar=null,Laya.timer.frameLoop(1,this,this._attack)}_attack(){if(null==this.enemyTar)this.enemyTar=Ce.Instance.GetOpponent(),null!=this.enemyTar&&(this.ATKp=this.enemyTar.transform.position.clone(),Ae.lookAt(this.ATKp,this.tran.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this.tran.rotation=this.quaternion1.clone());else{if(this.enemyTar.active||(this.enemyTar=Ce.Instance.GetOpponent(),null!=this.enemyTar&&(this.ATKp=this.enemyTar.transform.position.clone(),Ae.lookAt(this.ATKp,this.tran.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this.tran.rotation=this.quaternion1.clone())),null==this.enemyTar)return this.StopCreate(),void(this.isFristShoot=!0);this.isFristShoot&&(this.isFristShoot=!1,this.CreateShoot()),this.ATKp=this.enemyTar.transform.position.clone(),Ae.lookAt(this.ATKp,this.tran.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this.tran.rotation=this.quaternion1.clone()}}_Defense(){if(Ve.subtract(this.tp,this.tran.position,this.forW),Ve.normalize(this.forW,this.forW),this.forW=new Ve(.15*this.forW.x,.15*this.forW.y,.15*this.forW.z),this.tran.translate(this.forW,!1),Ve.distance(this.tran.position,this.tp)<.1){Laya.timer.clear(this,this._Defense);let e=Laya.Tween.to(this.tran,{localRotationEulerY:0},100,Laya.Ease.quintIn,Laya.Handler.create(this,()=>{e.clear()},null,!1))}else Ae.lookAt(this.tp,this.tran.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this.tran.rotation=this.quaternion1.clone()}Defense(e){this.SetPar(),this.tp=e,Ae.lookAt(e,this.tran.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this.tran.rotation=this.quaternion1.clone(),this.AnimatorPlayByType(W.CrouchFiring,1),Laya.timer.frameLoop(1,this,this._Defense)}Recover(){this.dataPar&&(this.dataPar.ishave=!1,this.dataPar=null),Ge.Instance.RecoverMateModel(this.selfobj),Ge.Instance.RemoveModelToDic(this.selfobj),Laya.timer.clearAll(this),Laya.Tween.clearAll(this),a.off(n.Event.StopShot,this,this.StopCreate),U.Instance.RecoverModel(this.selfobj)}}var De=Laya.Rectangle;class Ge{constructor(){this.ApePath="res/apes/monkey2.png",this.v3=F.VecZero,this.friendDic=new i,this.getDic=new i}static get Instance(){return this.instance||(this.instance=new Ge)}Trial(){for(let e=0;e<3;e++)Laya.timer.frameOnce(e,this,this._createtrialmodel,null,!1)}TrialModelPlayAni(){for(const e in this.friendDic.container){const t=this.friendDic.get(e);t.CreateShoot(),t.AnimatorPlayByType(W.RunAndGun,2)}}RecoverMateModel(e){this.friendDic.delete(e.id)}AddModelToDic(e,t){this.getDic.set(e,t)}RemoveModelToDic(e){this.getDic.delete(e.id)}MadeMate(e){let t=U.Instance.GetModel(U.modeltype.Player+v.Instance.equipId);if(t){t.transform.position=e.position.clone(),t.transform.rotationEuler=e.rotationEuler.clone(),Je.Instance.playerContainer.addChild(t);let i=t.getComponent(Ne);return i||(i=t.addComponent(Ne)),i.SetTar(),this.friendDic.set(t.id,i),i}return null}showDragRegion(){this.dragRegion=new De(Laya.stage.width-350>>1,Laya.stage.height-200>>1,350,200),Laya.stage.graphics.drawRect(this.dragRegion.x,this.dragRegion.y,this.dragRegion.width,this.dragRegion.height,null,"#FFFFFF",2)}onStartDrag(e){this.ape.startDrag(this.dragRegion,!0,100)}NearDestination(){return this.getDic.size}Near(e,t){if(1==e){for(const e in this.getDic.container){const t=this.getDic.get(e);this.v3.x=0,t.Defense(this.v3.clone())}return}let i=2*x.arriveStandWidth/(e-1),a=0;this.v3.z=t;for(const e in this.getDic.container){const t=this.getDic.get(e);this.v3.x=x.arriveStandWidth-a*i,t.Defense(this.v3.clone()),a++}}Attack(){for(const e in this.getDic.container){this.getDic.get(e).Attack()}}GetSprite(){let e=this.getDic.size,i=t.randomInt(1,e),a=1;for(const e in this.getDic.container){if(a==i){return this.getDic.get(e).selfobj}a++}return null}TiaoWu(){for(const e in this.getDic.container){let t=Ue.Instance.GetWuDaoPosition();if(!t)return;this.getDic.get(e).TiaoWu(t)}}Reset(){let e=[];for(const t in this.friendDic.container)e.push(t);if(e.length>0)for(let t=0;tthis.PlayerDancePoint.numChildren-1)return null;let e=this.PlayerDancePoint.getChildAt(this.danceindex).transform;return this.danceindex++,e}}var Oe=Laya.Vector3,Fe=Laya.Quaternion,We=Laya.Sprite;class je extends Laya.Script3D{constructor(){super(...arguments),this.isarrive=!1,this.isdead=!1,this.isFristShoot=!0,this._up=new Oe(0,1,0),this.ts=new Oe(0,0,.01)}onAwake(){this.selfobj=this.owner,this._transform=this.selfobj.transform,this.body=this.selfobj.getChildAt(0),this.animator=this.body.getComponent(Laya.Animator),this.rayPoint=this.selfobj.getChildByName("rayPoint").transform,this.shootPos=this.selfobj.getChildByName("bulletPos").transform,this._speed=F.VecZero,this._speed.z=x.playerspeed,this.forW=F.VecZero,this.quaternion1=new Fe}Move(){if(this.isarrive){if(this.isdead)return;return void this.RayReset()}this._transform.translate(this._speed);let e=this._transform.localPositionZ;J.Instance.CheckMainRolePos(e),Ue.Instance.CheckPlayerRoadPos(e),Ie.Instance.CheckPlayerRoadPos(e),q.Instance.CameraFollow(e),this.isdead||this.RayReset()}Near(){this.isarrive=!0}Start(){this.isdead=!1,this.isarrive=!1,Laya.timer.frameLoop(1,this,this.Move)}drawPentagram(){var e=new We;Laya.stage.addChild(e);var t=[];t.push(0,-130),t.push(33,-33),t.push(137,-30),t.push(55,32),t.push(85,130),t.push(0,73),t.push(-85,130),t.push(-55,32),t.push(-137,-30),t.push(-33,-33),e.graphics.drawPoly(Laya.stage.width/2,Laya.stage.height/2,t,"#FF7F50")}PlayAni(e,t,i){this.animator.play(e),t||(t=1),this.animator.speed=t}Slider(e){this._transform.localPositionX+=e;let t=this._transform.localPositionX;Math.abs(t)>x.playerMoveMaxX&&(this._transform.localPositionX=t>0?x.playerMoveMaxX:-x.playerMoveMaxX)}CreateBullet(){return this.isdead?null:this.shootPos}Dead(e){this.isdead=!0,this.body.active=!1,ne.Instance.BloodEffect(e),Je.Instance.CheckGameOver(!0)}Reset(){this.body.active=!0,this.PlayAni(W.Idle,1),Laya.timer.clearAll(this)}RayReset(){let e=this.rayPoint.position;if(this._scene||(this._scene=it.Instance.MainScene),this.rayF||(this.rayF=new Laya.Ray(F.VecZero,new Oe(0,0,1)),this.outHitF=new Laya.HitResult),this.rayF.origin=e,this._scene.physicsSimulation.rayCast(this.rayF,this.outHitF,x.playerRayLengthF)){this.outHitF.collider.owner;this.Dead(this.outHitF.point)}else if(this.rayL||(this.rayL=new Laya.Ray(F.VecZero,new Oe(1,0,0)),this.outHitL=new Laya.HitResult),this.rayL.origin=e,this._scene.physicsSimulation.rayCast(this.rayL,this.outHitL,x.playerRayLengthLR)){this.outHitL.collider.owner;this.Dead(this.outHitL.point)}else if(this.rayR||(this.rayR=new Laya.Ray(F.VecZero,new Oe(-1,0,0)),this.outHitR=new Laya.HitResult),this.rayR.origin=e,this._scene.physicsSimulation.rayCast(this.rayR,this.outHitR,x.playerRayLengthLR)){this.outHitR.collider.owner;this.Dead(this.outHitR.point)}else;}setup(){var e=new We;e.loadImage("res/bg2.png"),Laya.stage.addChild(e),this.bg2=new We,this.bg2.loadImage("res/bg2.png"),Laya.stage.addChild(this.bg2),this.bg2.scale(3,3),this.maskSp=new We,this.maskSp.loadImage("res/mask.png"),this.maskSp.pivot(50,50),this.bg2.mask=this.maskSp}_attack(){if(!this.isdead)if(null==this.enemyTar)this.enemyTar=Ce.Instance.GetOpponent(),null!=this.enemyTar&&(this.tp=this.enemyTar.transform.position.clone(),Fe.lookAt(this.tp,this._transform.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this._transform.rotation=this.quaternion1.clone());else{if(this.enemyTar.active||(this.enemyTar=Ce.Instance.GetOpponent(),null!=this.enemyTar&&(this.tp=this.enemyTar.transform.position.clone(),Fe.lookAt(this.tp,this._transform.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this._transform.rotation=this.quaternion1.clone())),null==this.enemyTar)return Je.Instance.CreateOver(!0),void(this.isFristShoot=!0);this.isFristShoot&&(this.isFristShoot=!1,Je.Instance.CreateShoot(!0)),this.tp=this.enemyTar.transform.position.clone(),Fe.lookAt(this.tp,this._transform.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this._transform.rotation=this.quaternion1.clone()}}TiaoWu(e){this.PlayAni(W.RunAndGun,2),this.dancepos=e.position.clone(),this.r=e.rotationEuler.clone(),Laya.timer.frameLoop(1,this,this.PlayWuDao)}PlayWuDao(){if(Oe.subtract(this.dancepos,this._transform.position,this.forW),Oe.normalize(this.forW,this.forW),this.forW=new Oe(.15*this.forW.x,.15*this.forW.y,.15*this.forW.z),this._transform.translate(this.forW),Oe.distance(this._transform.position,this.dancepos)<.15)return Laya.timer.clear(this,this.PlayWuDao),this._transform.position=this.dancepos.clone(),this._transform.rotationEuler=this.r.clone(),void this.PlayAni(W.Dance,1);Fe.lookAt(this.dancepos,this._transform.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this._transform.rotation=this.quaternion1.clone()}Defense(e){this.isdead||(this.tp=e,Fe.lookAt(e,this._transform.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this._transform.rotation=this.quaternion1.clone(),this.PlayAni(W.CrouchFiring,1),Laya.timer.frameLoop(1,this,this._Defense))}_Defense(){Oe.subtract(this.tp,this._transform.position,this.forW),Oe.normalize(this.forW,this.forW),this.forW=new Oe(.15*this.forW.x,.15*this.forW.y,.15*this.forW.z),this._transform.translate(this.forW),Oe.distance(this._transform.position,this.tp)<.1?Laya.timer.clear(this,this._Defense):(Fe.lookAt(this.tp,this._transform.position,this._up,this.quaternion1),this.quaternion1.invert(this.quaternion1),this._transform.rotation=this.quaternion1.clone())}Attack(){Laya.timer.clear(this,this._Defense),this.isFristShoot=!0,this.enemyTar=null,Laya.timer.frameLoop(1,this,this._attack)}}var qe=Laya.Vector3,Xe=Laya.Text,Ye=Laya.HScrollBar,Ze=Laya.VScrollBar;class Je{constructor(){this.isover=!1,this.isClickCom=!0,this.isend=!0}static get Instance(){return this.instance||(this.instance=new Je)}Init(e,t){this.playerStartTra=e.transform,this.playerContainer=t}ChangeModel(){this.player&&U.Instance.RecoverModel(this.player);let e=U.Instance.GetModel(U.modeltype.Player+v.Instance.equipId);if(e){this.player=e,this.SetMatePos(e),this.playerTra=this.player.transform,this.playerTra.position=this.playerStartTra.position.clone(),this.playerTra.rotationEuler=this.playerStartTra.rotationEuler.clone(),this.playerContainer.addChild(this.player);let t=this.player.getComponent(je);this.playerScript=t||this.player.addComponent(je)}}SetMatePos(e){this.MateArrPosition=[];let t=e.getChildByName("FriendSpawPos");t||console.error("friend父物体不存在");for(let e=0;e{this.startShake=!1,this.selfObj.transform.position=this.camPOS}))}animate(){this._position.x=Math.sin(this.scaleDelta+=.01),this.layaMonkey3D.transform.position=this._position,this.layaMonkey3D.transform.scale=this.scale,this.camera.viewport.project(this.layaMonkey3D.transform.position,this.camera.projectionViewMatrix,this._outPos),this.layaMonkey2D.pos(this._outPos.x/Laya.stage.clientScaleX,this._outPos.y/Laya.stage.clientScaleY)}MoveGame(e){this.canmovegame&&(this.temp.z=e-this.dis.z,this._tran.localPositionZ=this.temp.z)}}var et=Laya.Sprite,tt=Laya.BlurFilter;class it{constructor(){this.apePath="res/apes/monkey2.png"}static get Instance(){return it.instance||(it.instance=new it)}InitGame(){Laya.timer.frameOnce(10,this,()=>{Je.Instance.MadePlayer(),this.InItScene()})}Init(e){if(!e)return void console.error("场景不存在");let t;if(this.MainScene=e,Laya.stage.addChild(e),!(t=this.MainScene.getChildByName("scene")))return void console.error("场景资源配置错误!");this.MainCamera=this.MainScene.getChildByName("Main Camera"),this.MainCamera.enableHDR=!1,this.bulletCon=t.getChildByName("bulletContainer"),this.effectCon=t.getChildByName("effectPos"),this.SetSceneMaterial();let i=t.getChildByName("buildings");J.Instance.Init(i);let a=t.getChildByName("playerstartPoint"),n=t.getChildByName("playerContainer");Je.Instance.Init(a,n);let o=t.getChildByName("BlockContainer");Ie.Instance.Init(o);let r=t.getChildByName("towerContainer");te.Instance.Init(r);let h,l=t.getChildByName("startCamPos"),c=t.getChildByName("startXCamPos");h=s.isX?c:l,q.Instance.Init(this.MainCamera,h);let d=t.getChildByName("finalPos");Ue.Instance.Init(d),this.InitGame()}createApe(){var e=new et;e.loadImage(this.apePath),e.x=(Laya.stage.width-e.width)/2,e.y=(Laya.stage.height-e.height)/2,Laya.stage.addChild(e),this.applayFilter(e)}applayFilter(e){var t=new tt;t.strength=5,e.filters=[t]}SetSceneMaterial(){this.MainCamera.clearFlag=Laya.BaseCamera.CLEARFLAG_SKY;let e=this.MainScene.skyRenderer;e.mesh=Laya.SkyDome.instance;let t=new Laya.SkyProceduralMaterial;e.material=t,t.sunDisk=Laya.SkyProceduralMaterial.SUN_NODE,t.skyTint=new Laya.Vector4(1,.74,.74,1)}InItScene(){Q.Instance.SetLevel(),Ue.Instance.SetAir(),J.Instance.SetConstruct(),q.Instance.SetCameraAction(Ke.game,1),Je.Instance.SetPlayerPosition()}}var at=Laya.Sprite,nt=Laya.GlowFilter;class st{constructor(){this.cloth=[],this.apePath="res/apes/monkey2.png"}static get Instance(){return this.instance||(this.instance=new st)}static LoadResource(e,t){Laya.loader.retryNum=2,Laya.loader.maxLoader=3,Laya.loader.retryDelay=100,Laya.loader.create(e,new Laya.Handler(this,t)),Laya.loader.on(Laya.Event.ERROR,this,e=>{console.log(e+" 资源加载失败")})}InitAsset(){u.Player.forEach(e=>{let t=Laya.loader.getRes(e);Laya.loader.clearRes(e),this.LoadPoolRes(t.name,t)}),u.Particle.forEach(e=>{let t=Laya.loader.getRes(e);Laya.loader.clearRes(e),this.LoadPoolRes(t.name,t)});let e=Laya.loader.getRes(u.Enemy);Laya.loader.clearRes(u.Enemy),this.LoadPoolRes(e.name,e);let t=Laya.loader.getRes(u.PlayerShot);Laya.loader.clearRes(u.PlayerShot),this.LoadPoolRes(t.name,t);let i=Laya.loader.getRes(u.Mound);Laya.loader.clearRes(u.Mound),this.LoadPoolRes(i.name,i);let a=Laya.loader.getRes(u.MainScene);Laya.loader.clearRes(u.MainScene),u.Barrier.forEach(e=>{let t=Laya.loader.getRes(e);Laya.loader.clearRes(e),this.LoadPoolRes(t.name,t)}),it.Instance.Init(a)}LoadPoolRes(e,t){U.Instance.InitSelf(e,t)}setup(){this.createApe(),this.applayFilter()}createApe(){this.ape=new at,this.ape.loadImage(this.apePath);var e=Laya.loader.getRes(this.apePath);this.ape.x=(Laya.stage.width-e.width)/2,this.ape.y=(Laya.stage.height-e.height)/2,Laya.stage.addChild(this.ape)}applayFilter(){var e=new nt("#ffff00",10,0,0);this.ape.filters=[e]}Load(e){let t=[u.MainScene,u.Enemy,u.PlayerShot,u.Mound].concat(u.Player).concat(u.Barrier).concat(u.Particle);st.LoadResource(t,()=>{this.InitAsset(),e&&e()})}}var ot,rt=Laya.ClassUtils.regClass;!function(e){class t extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(t.uiView)}}t.uiView={type:"Scene",props:{width:720,height:1280},compId:2,child:[{type:"Image",props:{top:0,skin:"Main/zhujiemian-1-20.png",sizeGrid:"14,14,13,15",right:0,left:0,bottom:0,alpha:1},compId:3},{type:"Box",props:{y:253,x:42,width:636,height:538},compId:4,child:[{type:"Image",props:{top:0,skin:"Main/webp.webp.png",right:0,left:0,bottom:0},compId:31,child:[{type:"Image",props:{y:40,x:-9,width:655,skin:"Main/shengji-biaoti.png",height:102},compId:32}]},{type:"Button",props:{y:556,x:350,var:"rateBtn",stateNum:1,skin:"Main/landi.png"},compId:34,child:[{type:"Image",props:{y:19,x:44,skin:"Main/gongjisudu-1.png"},compId:35},{type:"Image",props:{y:124,x:4,width:236,var:"_rate",stateNum:1,height:71},compId:36,child:[{type:"Image",props:{y:9,x:3,skin:"Main/shengji-tubiao-1.png"},compId:37},{type:"Image",props:{y:13,x:57,skin:"Main/jinbi-zhu.png"},compId:38,child:[{type:"Text",props:{y:2,x:38,width:133,var:"rateValue",valign:"middle",text:"800",height:41,fontSize:40,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:39}]}]},{type:"Text",props:{y:71,x:72,width:106,var:"rateLv",valign:"middle",text:"LV8",height:41,fontSize:42,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:40},{type:"Image",props:{y:124,x:5,width:235,visible:!1,var:"_rateVideo",stateNum:1,height:71},compId:41,child:[{type:"Image",props:{y:9,x:3,skin:"Main/shengji-tubiao-1.png"},compId:42},{type:"Image",props:{y:16.5,x:117.5,skin:"Main/shipin-biao.png"},compId:43}]},{type:"Image",props:{y:154,x:137,var:"click2",skin:"Main/shou.png",anchorX:.5},compId:49}]},{type:"Button",props:{y:558,x:54,var:"atkBtn",stateNum:1,skin:"Main/hong-di.png"},compId:5,child:[{type:"Image",props:{y:19,x:66,skin:"Main/gongjili-2.png"},compId:10},{type:"Image",props:{y:124,x:3,width:236,var:"_atk",stateNum:1,height:71},compId:13,child:[{type:"Image",props:{y:9,x:3,skin:"Main/shengji-tubiao-1.png"},compId:33},{type:"Image",props:{y:15,x:61,skin:"Main/jinbi-zhu.png"},compId:14,child:[{type:"Text",props:{y:2,x:38,width:133,var:"atkValue",valign:"middle",text:"800",height:41,fontSize:40,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:16}]}]},{type:"Text",props:{y:71,x:57,width:136,var:"atkLv",valign:"middle",text:"LV8",height:41,fontSize:42,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:12},{type:"Image",props:{y:124,x:2,width:238,visible:!1,var:"_atkVideo",stateNum:1,height:71},compId:45,child:[{type:"Image",props:{y:9,x:3,skin:"Main/shengji-tubiao-1.png"},compId:46},{type:"Image",props:{y:16.5,x:119,skin:"Main/shipin-biao.png"},compId:47}]},{type:"Image",props:{y:154.5,x:137,var:"click1",skin:"Main/shou.png",anchorX:.5},compId:48}]},{type:"Image",props:{x:201,var:"backBtn",skin:"Main/jixuyouxi-bt.png",runtime:"View/Com/ButtonRunTime.ts",centerY:620},compId:8}]},{type:"Box",props:{y:384,x:75,width:571,var:"PushBox",height:407},compId:72,child:[{type:"Box",props:{y:112,x:100,width:140,height:175,anchorY:.5,anchorX:.5},compId:68,child:[{type:"Image",props:{y:0,x:0,width:140,name:"icon",height:140},compId:70},{type:"Text",props:{y:140,x:0,width:140,valign:"middle",text:"冲冲冲冲冲冲",name:"name",height:35,fontSize:22,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:71},{type:"Button",props:{y:0,x:0,top:0,right:0,name:"btn",left:0,bottom:0},compId:69}]},{type:"Box",props:{y:112,x:283,width:140,height:175,anchorY:.5,anchorX:.5},compId:73,child:[{type:"Image",props:{y:0,x:0,width:140,name:"icon",height:140},compId:74},{type:"Text",props:{y:140,x:0,width:140,valign:"middle",text:"冲冲冲冲冲冲",name:"name",height:35,fontSize:22,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:75},{type:"Button",props:{y:0,x:0,top:0,right:0,name:"btn",left:0,bottom:0},compId:76}]},{type:"Box",props:{y:112,x:470,width:140,height:175,anchorY:.5,anchorX:.5},compId:77,child:[{type:"Image",props:{y:0,x:0,width:140,name:"icon",height:140},compId:78},{type:"Text",props:{y:140,x:0,width:140,valign:"middle",text:"冲冲冲冲冲冲",name:"name",height:35,fontSize:22,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:79},{type:"Button",props:{y:0,x:0,top:0,right:0,name:"btn",left:0,bottom:0},compId:80}]},{type:"Box",props:{y:306,x:100,width:140,height:175,anchorY:.5,anchorX:.5},compId:81,child:[{type:"Image",props:{y:0,x:0,width:140,name:"icon",height:140},compId:84},{type:"Text",props:{y:140,x:0,width:140,valign:"middle",text:"冲冲冲冲冲冲",name:"name",height:35,fontSize:22,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:85},{type:"Button",props:{y:0,x:0,top:0,right:0,name:"btn",left:0,bottom:0},compId:86}]},{type:"Box",props:{y:306,x:283,width:140,height:175,anchorY:.5,anchorX:.5},compId:82,child:[{type:"Image",props:{y:0,x:0,width:140,name:"icon",height:140},compId:87},{type:"Text",props:{y:140,x:0,width:140,valign:"middle",text:"冲冲冲冲冲冲",name:"name",height:35,fontSize:22,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:88},{type:"Button",props:{y:0,x:0,top:0,right:0,name:"btn",left:0,bottom:0},compId:89}]},{type:"Box",props:{y:306,x:470,width:140,height:175,anchorY:.5,anchorX:.5},compId:83,child:[{type:"Image",props:{y:0,x:0,width:140,name:"icon",height:140},compId:90},{type:"Text",props:{y:140,x:0,width:140,valign:"middle",text:"冲冲冲冲冲冲",name:"name",height:35,fontSize:22,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:91},{type:"Button",props:{y:0,x:0,top:0,right:0,name:"btn",left:0,bottom:0},compId:92}]}]},{type:"Button",props:{y:176,x:578,var:"ExitBtn",stateNum:1,skin:"Main/exit2.png"},compId:94}],animations:[{nodes:[{target:48,keyframes:{y:[{value:154.5,tweenMethod:"linearNone",tween:!0,target:48,key:"y",index:0},{value:207,tweenMethod:"linearNone",tween:!0,target:48,key:"y",index:5},{value:154.5,tweenMethod:"linearNone",tween:!0,target:48,key:"y",index:10}]}}],name:"ani1",id:1,frameRate:24,action:2},{nodes:[{target:49,keyframes:{y:[{value:154,tweenMethod:"linearNone",tween:!0,target:49,key:"y",index:0},{value:201,tweenMethod:"linearNone",tween:!0,target:49,key:"y",index:5},{value:154.5,tweenMethod:"linearNone",tween:!0,target:49,key:"y",index:10}]}}],name:"ani2",id:2,frameRate:24,action:2},{nodes:[{target:68,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:68,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:68,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:68,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:68,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:68,key:"rotation",index:20}]}},{target:73,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:73,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:73,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:73,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:73,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:73,key:"rotation",index:20}]}},{target:77,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:77,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:77,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:77,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:77,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:77,key:"rotation",index:20}]}},{target:81,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:81,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:81,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:81,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:81,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:81,key:"rotation",index:20}]}},{target:82,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:82,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:82,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:82,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:82,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:82,key:"rotation",index:20}]}},{target:83,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:83,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:83,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:83,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:83,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:83,key:"rotation",index:20}]}}],name:"shakeani",id:3,frameRate:24,action:0}],loadList:["Main/zhujiemian-1-20.png","Main/webp.webp.png","Main/shengji-biaoti.png","Main/landi.png","Main/gongjisudu-1.png","Main/shengji-tubiao-1.png","Main/jinbi-zhu.png","Main/shipin-biao.png","Main/shou.png","Main/hong-di.png","Main/gongjili-2.png","Main/jixuyouxi-bt.png","Main/exit2.png"],loadList3D:[]},e.AttributeUpViewUI=t,rt("ui.AttributeUpViewUI",t);class i extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(i.uiView)}}i.uiView={type:"Scene",props:{width:720,height:1280},compId:2,child:[{type:"Image",props:{top:0,skin:"Main/zhujiemian-1-20.png",sizeGrid:"10,10,12,11",right:0,left:0,bottom:0,alpha:1},compId:22},{type:"Image",props:{y:1196,x:298,var:"nextBtn",skin:"Main/no.png",runtime:"View/Com/ButtonRunTime.ts"},compId:46},{type:"Image",props:{x:214,var:"doublegetBtn",skin:"Main/sanbeilingqu.png",runtime:"View/Com/ButtonRunTime.ts",bottom:350},compId:28},{type:"Image",props:{x:41,var:"shibaiTop",skin:"Main/shibai-di bg.png",centerY:-182},compId:68,child:[{type:"Image",props:{y:136,x:76,skin:"Main/shibai-jiesuan-b.png"},compId:121}]},{type:"Image",props:{x:41.5,var:"winTop",skin:"Main/shengli-beidi.png",centerY:-182},compId:44,child:[{type:"Image",props:{y:132,x:76,skin:"Main/tonggun-biao.png"},compId:122}]},{type:"Image",props:{x:243,width:60,skin:"Main/jinbi-zhu.png",height:60,centerY:120},compId:69,child:[{type:"Text",props:{y:-8,x:77,width:165,var:"valueText",valign:"middle",text:"50(+100)",height:75,fontSize:40,color:"#ffffff",align:"center",runtime:"laya.display.Text"},compId:70}]},{type:"Box",props:{x:136,width:447,height:419,centerY:-138},compId:71,child:[{type:"Image",props:{y:58,x:0,width:448,skin:"Main/zhengchang-di.png",height:100},compId:76,child:[{type:"Image",props:{y:18,x:26,skin:"Main/biaozhi-di8.png"},compId:80,child:[{type:"Image",props:{y:15,x:17,skin:"Main/baolei.png"},compId:118}]},{type:"Image",props:{y:25,x:384,width:50,skin:"Main/jinbi-zhu.png",height:50},compId:83},{type:"Text",props:{y:18,x:300,width:78,var:"towerValue",valign:"middle",text:"X10",height:63,fontSize:36,color:"#48efcc",bold:!0,align:"right",runtime:"laya.display.Text"},compId:82},{type:"Text",props:{y:18,x:97,width:78,var:"towerCount",valign:"middle",text:"X10",height:63,fontSize:36,color:"#48efcc",bold:!0,align:"center",runtime:"laya.display.Text"},compId:81}]},{type:"Image",props:{y:179,x:0,width:448,skin:"Main/zhengchang-di.png",height:100},compId:84,child:[{type:"Image",props:{y:18,x:26,skin:"Main/biaozhi-di8.png"},compId:85,child:[{type:"Image",props:{y:15,x:13.5,skin:"Main/rentou.png"},compId:119}]},{type:"Image",props:{y:25,x:384,width:50,skin:"Main/jinbi-zhu.png",height:50},compId:88},{type:"Text",props:{y:18,x:97,width:78,var:"roleCount",valign:"middle",text:"X10",height:63,fontSize:36,color:"#99ff53",bold:!0,align:"center",runtime:"laya.display.Text"},compId:86},{type:"Text",props:{y:18,x:300,width:78,var:"roleValue",valign:"middle",text:"X10",height:63,fontSize:36,color:"#99ff53",bold:!0,align:"right",runtime:"laya.display.Text"},compId:87}]},{type:"Image",props:{y:301,x:0,width:448,skin:"Main/zhengchang-di.png",height:100},compId:89,child:[{type:"Image",props:{y:18,x:26,skin:"Main/biaozhi-di8.png"},compId:90,child:[{type:"Image",props:{y:13,x:16,skin:"Main/baohe.png"},compId:120}]},{type:"Image",props:{y:25,x:384,width:50,skin:"Main/jinbi-zhu.png",height:50},compId:93},{type:"Text",props:{y:18,x:97,width:78,var:"blockCount",valign:"middle",text:"X10",height:63,fontSize:36,color:"#ffe92e",bold:!0,align:"center",runtime:"laya.display.Text"},compId:91},{type:"Text",props:{y:18,x:300,width:78,var:"blockValue",valign:"middle",text:"X10",height:63,fontSize:36,color:"#ffe92e",bold:!0,align:"right",runtime:"laya.display.Text"},compId:92}]}]},{type:"Button",props:{y:423,width:109,var:"LeftTopPushIcon",skin:"Main/hutui-1-4.png",sizeGrid:"5,16,5,11",pivotY:64,pivotX:55,left:14,height:128},compId:96,child:[{type:"Image",props:{y:0,x:0,width:109,name:"icon",height:91},compId:98},{type:"Text",props:{y:110,x:69,width:110,valign:"middle",text:"冲冲冲冲冲冲",pivotY:19,pivotX:70,name:"name",height:37,fontSize:17,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:99}]},{type:"Button",props:{y:640,width:109,var:"LeftBottomPushIcon",skin:"Main/hutui-1-4.png",sizeGrid:"5,16,5,11",pivotY:64,pivotX:55,left:14,height:128},compId:102,child:[{type:"Image",props:{y:0,x:0,width:109,name:"icon",height:91},compId:103},{type:"Text",props:{y:110,x:69,width:110,valign:"middle",text:"冲冲冲冲冲冲",pivotY:19,pivotX:70,name:"name",height:37,fontSize:17,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:104}]},{type:"Button",props:{y:423,width:109,var:"RightTopPushIcon",skin:"Main/hutui-1-4.png",sizeGrid:"5,16,5,11",pivotY:64,pivotX:55,left:595,height:128},compId:105,child:[{type:"Image",props:{y:0,x:0,width:109,name:"icon",height:91},compId:107},{type:"Text",props:{y:110,x:69,width:110,valign:"middle",text:"冲冲冲冲冲冲",pivotY:19,pivotX:70,name:"name",height:37,fontSize:17,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:108}]},{type:"Button",props:{y:640,width:109,var:"RightBottomPushIcon",skin:"Main/hutui-1-4.png",sizeGrid:"5,16,5,11",pivotY:64,pivotX:55,left:595,height:128},compId:106,child:[{type:"Image",props:{y:0,x:0,width:109,name:"icon",height:91},compId:109},{type:"Text",props:{y:110,x:69,width:110,valign:"middle",text:"冲冲冲冲冲冲",pivotY:19,pivotX:70,name:"name",height:37,fontSize:17,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:110}]},{type:"Button",props:{y:175,x:568.5,var:"ExitBtn",stateNum:1,skin:"Main/exit2.png"},compId:123}],animations:[{nodes:[{target:18,keyframes:{scaleY:[{value:1,tweenMethod:"linearNone",tween:!0,target:18,key:"scaleY",index:0},{value:.5,tweenMethod:"linearNone",tween:!0,target:18,key:"scaleY",index:10},{value:1,tweenMethod:"linearNone",tween:!0,target:18,key:"scaleY",index:20},{value:.5,tweenMethod:"linearNone",tween:!0,target:18,key:"scaleY",index:30},{value:1,tweenMethod:"linearNone",tween:!0,target:18,key:"scaleY",index:40}],scaleX:[{value:1,tweenMethod:"linearNone",tween:!0,target:18,key:"scaleX",index:0},{value:.5,tweenMethod:"linearNone",tween:!0,target:18,key:"scaleX",index:10},{value:1,tweenMethod:"linearNone",tween:!0,target:18,key:"scaleX",index:20},{value:.5,tweenMethod:"linearNone",tween:!0,target:18,key:"scaleX",index:30},{value:1,tweenMethod:"linearNone",tween:!0,target:18,key:"scaleX",index:40}]}}],name:"aim",id:1,frameRate:24,action:0},{nodes:[{target:96,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:96,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:96,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:96,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:96,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:96,key:"rotation",index:20}]}},{target:102,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:102,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:102,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:102,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:102,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:102,key:"rotation",index:20}]}},{target:105,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:105,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:105,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:105,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:105,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:105,key:"rotation",index:20}]}},{target:106,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:106,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:106,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:106,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:106,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:106,key:"rotation",index:20}]}}],name:"pushshake",id:2,frameRate:24,action:0}],loadList:["Main/zhujiemian-1-20.png","Main/no.png","Main/sanbeilingqu.png","Main/shibai-di bg.png","Main/shibai-jiesuan-b.png","Main/shengli-beidi.png","Main/tonggun-biao.png","Main/jinbi-zhu.png","Main/zhengchang-di.png","Main/biaozhi-di8.png","Main/baolei.png","Main/rentou.png","Main/baohe.png","Main/hutui-1-4.png","Main/exit2.png"],loadList3D:[]},e.CompleteViewUI=i,rt("ui.CompleteViewUI",i);class a extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(a.uiView)}}a.uiView={type:"Scene",props:{width:720,height:1280},compId:2,child:[{type:"Image",props:{top:0,skin:"Main/hutui-1-4.png",sizeGrid:"16,16,14,14",right:0,name:"BG",left:0,bottom:0},compId:5},{type:"Image",props:{x:0,width:720,top:0,skin:"Main/hutui-1-3.png",height:131},compId:4,child:[{type:"Text",props:{y:84,x:360,width:135,valign:"middle",text:"小程序",pivotY:31,pivotX:68,height:61,fontSize:35,bold:!0,align:"center",runtime:"laya.display.Text"},compId:6},{type:"Text",props:{y:154,x:56,width:92,valign:"middle",text:"最近使用",pivotY:18,pivotX:46,height:36,fontSize:23,color:"#5d5353",align:"center",runtime:"laya.display.Text"},compId:8},{type:"Image",props:{y:174,width:753,skin:"Main/hutui_line.png",right:0,pivotY:2,pivotX:320,height:7},compId:19}]},{type:"Button",props:{y:66,x:37,width:66,var:"CloseBtn",pivotY:41,pivotX:33,height:81},compId:7},{type:"List",props:{x:360,width:656,var:"PushList",top:180,spaceY:15,bottom:0,anchorY:.5,anchorX:.5},compId:9,child:[{type:"Box",props:{y:0,width:630,right:26,renderType:"render",height:101},compId:10,child:[{type:"Image",props:{y:100,x:123,width:538,skin:"Main/hutui_line.png",name:"line",height:5},compId:18},{type:"Image",props:{y:0,x:0,width:100,name:"icon",height:100},compId:11},{type:"Image",props:{y:0,x:0,width:101,skin:"Main/zhezhao.png",name:"zhezhao",height:101},compId:17},{type:"Text",props:{y:0,x:150,width:473,valign:"middle",text:"冲冲冲冲",name:"name",height:100,fontSize:30,align:"left",runtime:"laya.display.Text"},compId:12},{type:"Image",props:{y:65,x:598.5,width:49,skin:"Main/hutui-1-1.png",pivotY:23,pivotX:25,name:"star",height:46},compId:13},{type:"Button",props:{top:0,right:0,name:"btn",left:0,bottom:0},compId:14},{type:"Script",props:{runtime:"View/Com/ListItem.ts"},compId:16}]}]}],loadList:["Main/hutui-1-4.png","Main/hutui-1-3.png","Main/hutui_line.png","Main/zhezhao.png","Main/hutui-1-1.png"],loadList3D:[]},e.ExitViewUI=a,rt("ui.ExitViewUI",a);class n extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(n.uiView)}}n.uiView={type:"Scene",props:{width:720,height:1280},compId:2,child:[{type:"Image",props:{y:0,x:0,var:"BG",top:0,skin:"Main/111111.png",sizeGrid:"10,12,14,10",right:0,left:0,bottom:0},compId:5},{type:"Image",props:{top:130,skin:"Main/haoyourwBg.png",right:10,left:10,height:200},compId:3,child:[{type:"List",props:{y:52,x:11.5,width:697,var:"TopList",spaceX:20,height:130},compId:8,child:[{type:"Box",props:{y:0,x:0,width:130,renderType:"render",height:130},compId:9,child:[{type:"Image",props:{width:131,name:"icon",height:131},compId:10},{type:"Button",props:{top:0,right:0,name:"btn",left:0,bottom:0},compId:11},{type:"Script",props:{runtime:"View/Com/ListItem.ts"},compId:23}]}]}]},{type:"Image",props:{top:360,skin:"Main/baokuanrwbg.png",right:10,left:10,height:36},compId:4},{type:"Image",props:{x:209.5,top:50,skin:"Main/hotGameTitle.png"},compId:6},{type:"Button",props:{x:8,width:172,var:"CloseBtn",top:50,stateNum:1,skin:"Main/backBtn.png",height:51},compId:7},{type:"List",props:{x:10,var:"BottomList",top:400,spaceY:15,spaceX:40,right:0,repeatX:3,left:0,bottom:150},compId:12,child:[{type:"Box",props:{y:0,x:32,width:190,renderType:"render",height:230},compId:13,child:[{type:"Image",props:{top:0,skin:"Main/bg-box.png",sizeGrid:"33,36,40,30",right:0,name:"bg",left:0,bottom:0},compId:18},{type:"Image",props:{y:40,x:0,width:190,name:"icon",height:150},compId:14},{type:"Text",props:{y:190,x:1,width:189,valign:"middle",text:"text",name:"tip",height:41,fontSize:23,align:"center",runtime:"laya.display.Text"},compId:15},{type:"Image",props:{y:0,x:0,width:190,name:"bottom",height:40},compId:16},{type:"Text",props:{y:0,x:0,width:189,valign:"middle",text:"冲冲冲冲冲冲",name:"name",height:40,fontSize:30,color:"#ffffff",align:"center",runtime:"laya.display.Text"},compId:17},{type:"Button",props:{top:0,right:0,name:"btn",left:0,bottom:0},compId:19},{type:"Script",props:{runtime:"View/Com/ListItem.ts"},compId:24}]}]},{type:"Button",props:{x:228,width:241,var:"ContinueBtn",stateNum:1,skin:"Main/zhengchang-di2.png",sizeGrid:"17,31,12,28",height:65,bottom:50},compId:20,child:[{type:"Image",props:{y:11,x:33.5,skin:"Main/jixuyouxi.png"},compId:21}]}],loadList:["Main/111111.png","Main/haoyourwBg.png","Main/baokuanrwbg.png","Main/hotGameTitle.png","Main/backBtn.png","Main/bg-box.png","Main/zhengchang-di2.png","Main/jixuyouxi.png"],loadList3D:[]},e.ExportViewUI=n,rt("ui.ExportViewUI",n);class s extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(s.uiView)}}s.uiView={type:"Scene",props:{width:720,height:1280},compId:2,child:[{type:"Image",props:{y:0,x:0,var:"BG",top:0,skin:"Main/chunhei.png",sizeGrid:"8,10,11,9",right:0,left:0,bottom:0},compId:6},{type:"Image",props:{y:504,x:360,width:467,skin:"Main/liwukuang.png",pivotY:234,pivotX:234,name:"kuang",height:467},compId:3,child:[{type:"Image",props:{y:233.5,x:233.5,width:183,skin:"Main/lihe.png",pivotY:102,pivotX:92,name:"gift",height:203},compId:4},{type:"Image",props:{y:233.5,x:233.5,width:85,skin:"Main/wenhao.png",pivotY:66,pivotX:43,name:"wenhao",height:132},compId:5}]},{type:"Button",props:{x:352,width:200,var:"HitBtn",stateNum:1,pivotY:67,pivotX:100,height:133,bottom:8},compId:9,child:[{type:"Image",props:{y:-51,x:108,width:89,var:"shou",skin:"Main/shou1.png",pivotY:59,pivotX:45,height:118},compId:12},{type:"Image",props:{y:34,x:0,skin:"Main/eee 1@2x.png"},compId:24},{type:"Image",props:{y:45,x:100,width:174,skin:"Main/anniu.png",pivotY:41,pivotX:87,height:82},compId:10}]},{type:"Text",props:{y:356,x:360,width:199,valign:"middle",text:"神秘礼盒",pivotY:34,pivotX:100,name:"name",height:67,fontSize:30,bold:!0,align:"center",runtime:"laya.display.Text"},compId:13},{type:"ProgressBar",props:{y:666,x:360,width:268,var:"jinduBar",value:0,skin:"Main/di.png",pivotY:11,pivotX:134,height:22},compId:14}],animations:[{nodes:[{target:12,keyframes:{y:[{value:-51,tweenMethod:"linearNone",tween:!0,target:12,key:"y",index:0},{value:-90,tweenMethod:"linearNone",tween:!0,target:12,key:"y",index:5},{value:-51,tweenMethod:"linearNone",tween:!0,target:12,key:"y",index:10},{value:-90,tweenMethod:"linearNone",tween:!0,target:12,key:"y",index:15},{value:-51,tweenMethod:"linearNone",tween:!0,target:12,key:"y",index:20}],x:[{value:108,tweenMethod:"linearNone",tween:!0,target:12,key:"x",index:0}]}}],name:"click",id:1,frameRate:24,action:0}],loadList:["Main/chunhei.png","Main/liwukuang.png","Main/lihe.png","Main/wenhao.png","Main/shou1.png","Main/eee 1@2x.png","Main/anniu.png","Main/di.png"],loadList3D:[]},e.GiftViewUI=s,rt("ui.GiftViewUI",s);class o extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(o.uiView)}}o.uiView={type:"Scene",props:{width:720,height:1280},compId:2,child:[{type:"Image",props:{var:"BG",top:0,skin:"Main/chunhei.png",sizeGrid:"8,11,10,8",right:0,left:0,bottom:0},compId:4},{type:"Image",props:{y:288,x:177.5,skin:"Main/zajindan_3.png"},compId:3,child:[{type:"Image",props:{y:284,x:456,width:137,skin:"Main/zajindan_5_3.png",pivotY:177,pivotX:77,height:177},compId:6}]},{type:"ProgressBar",props:{y:725.5,x:21,var:"jindu",value:0,skin:"Main/zadanjindu.png",rotation:-90},compId:5},{type:"Button",props:{y:1157,x:360,var:"HitBtn",stateNum:1,skin:"Main/zadan.png",scaleY:1.01,scaleX:1.01,anchorY:.5,anchorX:.5},compId:7},{type:"Image",props:{y:1007,x:506,var:"kuangdian",skin:"Main/kuangdian-2.png"},compId:9}],animations:[{nodes:[{target:6,keyframes:{y:[{value:107,tweenMethod:"linearNone",tween:!0,target:6,key:"y",index:0},{value:284,tweenMethod:"linearNone",tween:!0,target:6,key:"y",index:1}],x:[{value:379,tweenMethod:"linearNone",tween:!0,target:6,key:"x",index:0},{value:448,tweenMethod:"linearNone",tween:!0,target:6,key:"x",index:1}],rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:6,key:"rotation",index:0},{value:-6,tweenMethod:"linearNone",tween:!0,target:6,key:"rotation",index:1},{value:-17,tweenMethod:"linearNone",tween:!0,target:6,key:"rotation",index:2},{value:-46,tweenMethod:"linearNone",tween:!0,target:6,key:"rotation",index:3},{value:-19,tweenMethod:"linearNone",tween:!0,target:6,key:"rotation",index:4},{value:0,tweenMethod:"linearNone",tween:!0,target:6,key:"rotation",index:5}],pivotY:[{value:0,tweenMethod:"linearNone",tween:!0,target:6,key:"pivotY",index:0},{value:177,tweenMethod:"linearNone",tween:!0,target:6,key:"pivotY",index:1}],pivotX:[{value:0,tweenMethod:"linearNone",tween:!0,target:6,key:"pivotX",index:0},{value:69,tweenMethod:"linearNone",tween:!0,target:6,key:"pivotX",index:1}]}},{target:4,keyframes:{var:[{value:"BG",tweenMethod:"linearNone",tween:!1,target:4,key:"var",index:0},{value:"Black",tweenMethod:"linearNone",tween:!1,target:4,key:"var",index:5}],name:[{value:"BG",tweenMethod:"linearNone",tween:!1,target:4,key:"name",index:0},{value:"",tweenMethod:"linearNone",tween:!1,target:4,key:"name",index:5}]}}],name:"ani1",id:1,frameRate:24,action:0},{nodes:[{target:7,keyframes:{scaleY:[{value:1,tweenMethod:"linearNone",tween:!0,target:7,key:"scaleY",index:0},{value:.9,tweenMethod:"linearNone",tween:!0,target:7,key:"scaleY",index:10},{value:1,tweenMethod:"linearNone",tween:!0,target:7,key:"scaleY",index:20},{value:1.1,tweenMethod:"linearNone",tween:!0,target:7,key:"scaleY",index:30},{value:1,tweenMethod:"linearNone",tween:!0,target:7,key:"scaleY",index:40}],scaleX:[{value:1,tweenMethod:"linearNone",tween:!0,target:7,key:"scaleX",index:0},{value:.9,tweenMethod:"linearNone",tween:!0,target:7,key:"scaleX",index:10},{value:1,tweenMethod:"linearNone",tween:!0,target:7,key:"scaleX",index:20},{value:1.1,tweenMethod:"linearNone",tween:!0,target:7,key:"scaleX",index:30},{value:1,tweenMethod:"linearNone",tween:!0,target:7,key:"scaleX",index:40}]}}],name:"btnscale",id:2,frameRate:24,action:0}],loadList:["Main/chunhei.png","Main/zajindan_3.png","Main/zajindan_5_3.png","Main/zadanjindu.png","Main/zadan.png","Main/kuangdian-2.png"],loadList3D:[]},e.GoldEggViewUI=o,rt("ui.GoldEggViewUI",o);class r extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(r.uiView)}}r.uiView={type:"Scene",props:{width:720,mouseThrough:!0,height:1280},compId:2,child:[{type:"Box",props:{y:30,x:958,width:104,var:"guide1Box",scaleY:.8,scaleX:.8,height:44,anchorY:1,anchorX:.5},compId:7,child:[{type:"Image",props:{y:3,x:-3,skin:"Main/guangquan(1).png"},compId:8},{type:"Image",props:{y:-123,x:2,skin:"Main/jiantou(1).png"},compId:9}]},{type:"Box",props:{y:154,x:969,width:207,var:"guide2Box",scaleY:.8,scaleX:.8,height:56,anchorY:.5,anchorX:0},compId:10,child:[{type:"Image",props:{y:28,x:207,width:0,skin:"Main/zuoyou-jiantou(1).png",rotation:180,pivotY:48,height:96},compId:12},{type:"Image",props:{y:15,x:181,skin:"Main/shou.png"},compId:11}]},{type:"Box",props:{y:298,x:1790,width:207,var:"guide3Box",scaleY:.8,scaleX:.8,height:48,anchorY:.5,anchorX:1},compId:13,child:[{type:"Image",props:{y:22,x:0,width:0,skin:"Main/zuoyou-jiantou(1).png",pivotY:48,height:96},compId:14},{type:"Image",props:{y:6,x:-17,width:61,skin:"Main/shou.png"},compId:15}]},{type:"Box",props:{y:278,x:-163,width:104,var:"guide4Box",scaleY:.8,scaleX:.8,height:44,anchorY:1,anchorX:.5},compId:19,child:[{type:"Image",props:{y:-106,x:4,skin:"Main/jiantou(1).png"},compId:21}]},{type:"Image",props:{x:183,var:"guide1Image",skin:"Main/biaoyu.png",bottom:220},compId:16},{type:"Image",props:{x:164,var:"guide2Image",skin:"Main/biaoyu4.png",bottom:218},compId:17},{type:"Image",props:{x:136,var:"guide3Image",skin:"Main/biaoyu2.png",bottom:220},compId:18}],animations:[{nodes:[{target:9,keyframes:{y:[{value:-116,tweenMethod:"linearNone",tween:!0,target:9,key:"y",index:0},{value:-197,tweenMethod:"linearNone",tween:!0,target:9,key:"y",index:5},{value:-115,tweenMethod:"linearNone",tween:!0,target:9,key:"y",index:10}]}}],name:"guide1",id:1,frameRate:24,action:0},{nodes:[{target:11,keyframes:{x:[{value:181,tweenMethod:"linearNone",tween:!0,target:11,key:"x",index:0},{value:21,tweenMethod:"linearNone",tween:!0,target:11,key:"x",index:10}]}},{target:12,keyframes:{width:[{value:0,tweenMethod:"linearNone",tween:!0,target:12,key:"width",index:0},{value:188,tweenMethod:"linearNone",tween:!0,target:12,key:"width",index:10}]}}],name:"guide2",id:2,frameRate:24,action:0},{nodes:[{target:15,keyframes:{x:[{value:-17,tweenMethod:"linearNone",tween:!0,target:15,key:"x",index:0},{value:122,tweenMethod:"linearNone",tween:!0,target:15,key:"x",index:10}]}},{target:14,keyframes:{width:[{value:0,tweenMethod:"linearNone",tween:!0,target:14,key:"width",index:0},{value:149,tweenMethod:"linearNone",tween:!0,target:14,key:"width",index:10}]}}],name:"guide3",id:3,frameRate:24,action:0},{nodes:[{target:21,keyframes:{y:[{value:-212,tweenMethod:"linearNone",tween:!0,target:21,key:"y",index:0},{value:-106,tweenMethod:"linearNone",tween:!0,target:21,key:"y",index:10}]}}],name:"guide4",id:4,frameRate:24,action:0}],loadList:["Main/guangquan(1).png","Main/jiantou(1).png","Main/zuoyou-jiantou(1).png","Main/shou.png","Main/biaoyu.png","Main/biaoyu4.png","Main/biaoyu2.png"],loadList3D:[]},e.GuideViewUI=r,rt("ui.GuideViewUI",r);class h extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(h.uiView)}}h.uiView={type:"Scene",props:{width:720,height:1280},compId:2,loadList:[],loadList3D:[]},e.InGameViewUI=h,rt("ui.InGameViewUI",h);class l extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(l.uiView)}}l.uiView={type:"Scene",props:{width:720,sizeGrid:"0,0,0,0",height:1280},compId:2,child:[{type:"Image",props:{y:0,x:0,top:0,skin:"Main/zhujiemian-1-20.png",sizeGrid:"15,13,12,13",right:0,left:0,bottom:0},compId:64},{type:"Image",props:{top:0,skin:"Main/bg-sheng.png",right:0,left:0,bottom:0,alpha:.8},compId:3},{type:"Image",props:{y:139,x:63.5,skin:"Main/beijing-di.png"},compId:36},{type:"Box",props:{y:402,x:42,width:636,height:645},compId:4,child:[{type:"Image",props:{y:17,x:44.5,var:"atkBox",skin:"Main/wenzi-di5.png"},compId:37,child:[{type:"Image",props:{y:43,x:183,skin:"Main/gongji-2-3.png"},compId:38},{type:"Image",props:{y:48,x:26,skin:"Main/zhuangbei-tubiao-di.png"},compId:60},{type:"Image",props:{y:58.5,x:34,skin:"Main/gongji-icon.png"},compId:39},{type:"Image",props:{y:125,x:179,skin:"Main/gongji-1-3.png"},compId:40},{type:"Button",props:{y:95.5,x:358,var:"atkupBtn",stateNum:1,skin:"Main/zheng-qianbi-di.png"},compId:41,child:[{type:"Image",props:{y:7,x:15,width:45,skin:"Main/jinbi-zhu.png",height:45},compId:43,child:[{type:"Text",props:{y:2,x:47,width:134,var:"atkValue",valign:"middle",text:"800",height:41,fontSize:40,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:44}]}]},{type:"Text",props:{y:38,x:390,width:106,var:"atkLv",valign:"middle",text:"LV8",height:41,fontSize:50,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:42}]},{type:"Image",props:{y:226,x:44.5,var:"rateBox",skin:"Main/wenzi-di5.png"},compId:45,child:[{type:"Image",props:{y:43,x:170,skin:"Main/gongji-2-2.png"},compId:46},{type:"Image",props:{y:48,x:26,skin:"Main/zhuangbei-tubiao-di.png"},compId:62},{type:"Image",props:{y:63.5,x:35,skin:"Main/iconqiang.png"},compId:47},{type:"Image",props:{y:125,x:164,skin:"Main/gongji-1-2.png"},compId:48},{type:"Button",props:{y:94.5,x:360,var:"rateupBtn",stateNum:1,skin:"Main/zheng-qianbi-di.png"},compId:49,child:[{type:"Image",props:{y:7,x:12,width:45,skin:"Main/jinbi-zhu.png",height:45},compId:51,child:[{type:"Text",props:{y:2,x:47,width:134,var:"rateValue",valign:"middle",text:"800",height:41,fontSize:40,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:52}]}]},{type:"Text",props:{y:33,x:392,width:106,var:"rateLv",valign:"middle",text:"LV8",height:41,fontSize:50,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:50}]},{type:"Image",props:{y:445,x:44.5,var:"coinBox",skin:"Main/wenzi-di5.png"},compId:53,child:[{type:"Image",props:{y:43,x:161,skin:"Main/gongji-2.png"},compId:54},{type:"Image",props:{y:48,x:26,skin:"Main/zhuangbei-tubiao-di.png"},compId:63},{type:"Image",props:{y:63.5,x:30,skin:"Main/jinbi.png"},compId:55},{type:"Image",props:{y:124,x:161,skin:"Main/gongji-1.png"},compId:56},{type:"Button",props:{y:94,x:351,var:"getcoinBtn",stateNum:1,skin:"Main/zheng-qianbi-di.png"},compId:57,child:[{type:"Image",props:{y:7,x:12,width:45,skin:"Main/shipin-biao.png",height:45},compId:58,child:[{type:"Text",props:{y:2,x:47,width:134,var:"coinValue",valign:"middle",text:"800",height:41,fontSize:48,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:59}]}]}]}]},{type:"Button",props:{y:174.5,x:573,var:"ExitBtn",stateNum:1,skin:"Main/exit2.png"},compId:65},{type:"Button",props:{y:139,x:14,var:"backBtn",stateNum:1,skin:"Main/p__fanhui.png"},compId:66}],loadList:["Main/zhujiemian-1-20.png","Main/bg-sheng.png","Main/beijing-di.png","Main/wenzi-di5.png","Main/gongji-2-3.png","Main/zhuangbei-tubiao-di.png","Main/gongji-icon.png","Main/gongji-1-3.png","Main/zheng-qianbi-di.png","Main/jinbi-zhu.png","Main/gongji-2-2.png","Main/iconqiang.png","Main/gongji-1-2.png","Main/gongji-2.png","Main/jinbi.png","Main/gongji-1.png","Main/shipin-biao.png","Main/exit2.png","Main/p__fanhui.png"],loadList3D:[]},e.IntensifyViewUI=l,rt("ui.IntensifyViewUI",l);class c extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(c.uiView)}}c.uiView={type:"Scene",props:{width:720,height:1280},compId:2,child:[{type:"Image",props:{var:"bg",top:0,skin:"load/bg.png",right:0,name:"bg",left:0,bottom:0},compId:6},{type:"Image",props:{x:360,var:"prepan",centerY:-68},compId:14},{type:"Image",props:{x:86,skin:"load/title.png",centerY:-360},compId:17},{type:"Image",props:{y:932,x:137,var:"pro",skin:"load/jindu-di.png",centerY:309},compId:20,child:[{type:"Image",props:{y:4,x:4,width:438,var:"pro1",skin:"load/shang.png"},compId:21},{type:"Text",props:{y:0,x:2,width:442,var:"proTex",valign:"middle",text:"100%",height:38,fontSize:28,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:22},{type:"Text",props:{y:60,x:51,width:359,valign:"middle",text:"一款好玩的游戏正在加载...",height:37,fontSize:30,font:"SimSun",color:"#ff0000",align:"left",runtime:"laya.display.Text"},compId:23}]}],animations:[{nodes:[{target:9,keyframes:{alpha:[{value:0,tweenMethod:"linearNone",tween:!0,target:9,key:"alpha",index:0},{value:1,tweenMethod:"linearNone",tween:!0,target:9,key:"alpha",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:9,key:"alpha",index:20}]}},{target:10,keyframes:{alpha:[{value:0,tweenMethod:"linearNone",tween:!0,target:10,key:"alpha",index:0},{value:1,tweenMethod:"linearNone",tween:!0,target:10,key:"alpha",index:10},{value:0,tweenMethod:"linearNone",tween:!0,target:10,key:"alpha",index:20}]}},{target:11,keyframes:{alpha:[{value:0,tweenMethod:"linearNone",tween:!0,target:11,key:"alpha",index:0},{value:1,tweenMethod:"linearNone",tween:!0,target:11,key:"alpha",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:11,key:"alpha",index:20}]}}],name:"ani1",id:1,frameRate:24,action:2}],loadList:["load/bg.png","load/title.png","load/jindu-di.png","load/shang.png"],loadList3D:[]},e.LoadViewUI=c,rt("ui.LoadViewUI",c);class d extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(d.uiView)}}d.uiView={type:"Scene",props:{width:720,height:1280},compId:2,child:[{type:"Box",props:{x:0,top:82,right:0,left:0,height:70},compId:265,child:[{type:"Image",props:{y:21,x:282,width:157,var:"pro",skin:"Main/jindu-duan.png"},compId:302,child:[{type:"Image",props:{y:4,x:1,width:150,var:"pro1",skin:"Main/jindu-guan-do.png",height:20},compId:305},{type:"Image",props:{y:-11,x:-49,skin:"Main/guanshu.png"},compId:303,child:[{type:"Text",props:{y:-1,x:-3,width:54,var:"stageValue",valign:"middle",text:"10",height:51,fontSize:32,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:264}]},{type:"Image",props:{y:-11,x:155,skin:"Main/shadi.png"},compId:304}]},{type:"Image",props:{width:187,top:130,skin:"Main/jinbi-di.png",right:522},compId:261,child:[{type:"Image",props:{y:4.5,x:0,skin:"Main/jinbi-zhu.png"},compId:262},{type:"Text",props:{y:3.5,x:37,width:142,var:"countValue",valign:"middle",text:"100000",italic:!0,height:47,fontSize:36,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:263}]}]},{type:"Box",props:{var:"mainBox",top:0,right:0,name:"mainBox",left:0,bottom:0},compId:284,child:[{type:"Image",props:{x:30,var:"settingBtn",top:104,skin:"Main/shezhi.png",runtime:"View/Com/ButtonRunTime.ts"},compId:260},{type:"Box",props:{x:29,width:63,visible:!1,var:"settingBox",top:179,height:134},compId:291,child:[{type:"Button",props:{x:2,width:59,var:"shake_btn",stateNum:1,height:59},compId:285,child:[{type:"Image",props:{y:0,x:0,skin:"Main/ButtonVibrationOff.png",name:"kai"},compId:287},{type:"Image",props:{y:0,x:0,visible:!1,skin:"Main/ButtonVibrationOn.png",name:"guan"},compId:288}]},{type:"Button",props:{y:74,width:62,var:"sound_btn",stateNum:1,height:60},compId:286,child:[{type:"Image",props:{y:0,x:0,skin:"Main/Icon_SoundOn.png",name:"kai"},compId:289},{type:"Image",props:{y:0,x:0,visible:!1,skin:"Main/Icon_SoundOff.png",name:"guan"},compId:290}]}]},{type:"Box",props:{var:"startBox",right:0,left:0,height:5,bottom:208},compId:259,child:[{type:"Image",props:{var:"updateBtn",skin:"Main/shengji.png",runtime:"View/Com/ButtonRunTime.ts",left:0,bottom:0},compId:257},{type:"Image",props:{var:"skinBtn",skin:"Main/shangdain.png",runtime:"View/Com/ButtonRunTime.ts",right:0,bottom:0},compId:258}]},{type:"Text",props:{y:0,x:0,width:194,var:"user_id",valign:"middle",text:"user_id:12",height:25,fontSize:25,color:"#000000",runtime:"laya.display.Text"},compId:270},{type:"Button",props:{y:689,x:196,var:"MoreFunBtn2",stateNum:1,skin:"Main/gengduoyouxo-2.png"},compId:336}]},{type:"Image",props:{x:168.5,var:"sliderBox",skin:"Main/zhiyin-di.png",mouseEnabled:!1,gray:!1,bottom:325},compId:253,child:[{type:"Image",props:{y:-71,x:27,skin:"Main/pause1.png"},compId:334},{type:"Image",props:{y:18,x:191.5,skin:"Main/shouzhi.png",anchorX:.5},compId:293},{type:"Image",props:{y:13.5,x:18,skin:"Main/fangxiangzuo.png"},compId:331},{type:"Image",props:{y:13.5,x:283,skin:"Main/fangxiangyou.png"},compId:332}]},{type:"Sprite",props:{var:"duohuituiSp"},compId:312},{type:"Sprite",props:{y:0,x:0,var:"bannerHuiTuiSp"},compId:313},{type:"Box",props:{y:0,x:0,width:720,visible:!0,right:0,name:"BottomBox",left:0,height:177,bottom:0},compId:314,child:[{type:"Image",props:{width:720,top:0,skin:"Main/chunhei2.png",sizeGrid:"12,11,13,10",right:0,name:"BG",left:0,height:183,bottom:0},compId:317},{type:"List",props:{width:720,var:"BottomList",spaceX:30,right:0,repeatY:1,left:0,height:176,bottom:0},compId:318,child:[{type:"Box",props:{y:8,x:18,width:130,renderType:"render",height:160},compId:319,child:[{type:"Image",props:{y:0,x:0,width:129,skin:"Main/bg-box.png",sizeGrid:"27,27,37,20",name:"BG",height:159},compId:320},{type:"Image",props:{y:0,x:0,width:130,name:"icon",height:130},compId:321},{type:"Text",props:{y:130,x:0,width:126,valign:"middle",text:"冲冲冲冲冲冲",name:"name",height:29,fontSize:20,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:322},{type:"Button",props:{y:0,x:0,width:130,name:"btn",height:160},compId:323},{type:"Script",props:{runtime:"View/Com/ListItem.ts"},compId:335}]}]}]},{type:"Button",props:{y:561,width:140,var:"LeftPushIcon",skin:"Main/hutui-1-4.png",sizeGrid:"5,16,5,11",pivotY:88,pivotX:70,left:20,height:175},compId:315,child:[{type:"Image",props:{width:140,name:"icon",height:140},compId:325},{type:"Text",props:{y:159,x:70,width:140,valign:"middle",text:"冲冲冲冲冲冲",pivotY:19,pivotX:70,name:"name",height:37,fontSize:22,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:326}]},{type:"Button",props:{y:561,width:140,var:"RightPushIcon",skin:"Main/hutui-1-4.png",sizeGrid:"5,16,5,11",right:21,pivotY:88,pivotX:70,height:175},compId:316,child:[{type:"Image",props:{width:140,name:"icon",height:140},compId:327},{type:"Text",props:{y:159,x:70,width:140,valign:"middle",text:"冲冲冲冲冲冲",pivotY:19,pivotX:70,name:"name",height:37,fontSize:22,font:"Microsoft YaHei",bold:!0,align:"center",runtime:"laya.display.Text"},compId:328}]},{type:"Button",props:{y:211,x:561,var:"ExitBtn",stateNum:1,skin:"Main/exit2.png"},compId:330},{type:"Button",props:{y:726,x:0,var:"MoreGameBtn",stateNum:1,skin:"Main/gengduoyouxi.png"},compId:333},{type:"Image",props:{visible:!1,var:"BoxPanel",top:0,skin:"Main/chunhei.png",sizeGrid:"10,12,14,10",right:0,left:0,bottom:0},compId:337,child:[{type:"Image",props:{y:114,x:158.5,skin:"Main/baoxiang-1-1.png"},compId:339},{type:"Image",props:{y:272,x:165,skin:"Main/baoxiang-1-2.png"},compId:341},{type:"Image",props:{y:371,x:236,skin:"Main/baoxiang-1-3.png"},compId:340},{type:"Button",props:{y:756,x:205.5,var:"VideoGetCoinBtn",stateNum:1,skin:"Main/baoxiang-1-4.png"},compId:342},{type:"Button",props:{y:912,x:312,var:"CloseVideoBtn",stateNum:1,skin:"Main/baoxiang-1-5.png"},compId:344}]}],animations:[{nodes:[{target:293,keyframes:{x:[{value:164,tweenMethod:"linearNone",tween:!0,target:293,key:"x",index:0},{value:0,tweenMethod:"linearNone",tween:!0,target:293,key:"x",index:15},{value:164,tweenMethod:"linearNone",tween:!0,target:293,key:"x",index:30},{value:326,tweenMethod:"linearNone",tween:!0,target:293,key:"x",index:45},{value:164,tweenMethod:"linearNone",tween:!0,target:293,key:"x",index:60}]}}],name:"gameStart",id:1,frameRate:24,action:2},{nodes:[{target:315,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:315,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:315,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:315,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:315,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:315,key:"rotation",index:20}]}}],name:"lefticon",id:2,frameRate:24,action:0},{nodes:[{target:316,keyframes:{rotation:[{value:0,tweenMethod:"linearNone",tween:!0,target:316,key:"rotation",index:0},{value:-15,tweenMethod:"linearNone",tween:!0,target:316,key:"rotation",index:5},{value:0,tweenMethod:"linearNone",tween:!0,target:316,key:"rotation",index:10},{value:15,tweenMethod:"linearNone",tween:!0,target:316,key:"rotation",index:15},{value:0,tweenMethod:"linearNone",tween:!0,target:316,key:"rotation",index:20}]}}],name:"righticon",id:3,frameRate:24,action:0}],loadList:["Main/jindu-duan.png","Main/jindu-guan-do.png","Main/guanshu.png","Main/shadi.png","Main/jinbi-di.png","Main/jinbi-zhu.png","Main/shezhi.png","Main/ButtonVibrationOff.png","Main/ButtonVibrationOn.png","Main/Icon_SoundOn.png","Main/Icon_SoundOff.png","Main/shengji.png","Main/shangdain.png","Main/gengduoyouxo-2.png","Main/zhiyin-di.png","Main/pause1.png","Main/shouzhi.png","Main/fangxiangzuo.png","Main/fangxiangyou.png","Main/chunhei2.png","Main/bg-box.png","Main/hutui-1-4.png","Main/exit2.png","Main/gengduoyouxi.png","Main/chunhei.png","Main/baoxiang-1-1.png","Main/baoxiang-1-2.png","Main/baoxiang-1-3.png","Main/baoxiang-1-4.png","Main/baoxiang-1-5.png"],loadList3D:[]},e.MainViewUI=d,rt("ui.MainViewUI",d);class p extends Laya.View{constructor(){super()}createChildren(){super.createChildren(),this.createView(p.uiView)}}p.uiView={type:"View",props:{width:720,height:1280},compId:2,loadList:[],loadList3D:[]},e.ShadeViewUI=p,rt("ui.ShadeViewUI",p);class g extends Laya.View{constructor(){super()}createChildren(){super.createChildren(),this.createView(g.uiView)}}g.uiView={type:"View",props:{width:720,height:1280},compId:2,child:[{type:"Image",props:{top:0,skin:"Main/zhujiemian-1-20.png",sizeGrid:"13,14,14,13",right:0,left:0,bottom:0},compId:115},{type:"Image",props:{top:0,skin:"Main/bg-sheng1.png",right:0,left:0,bottom:0},compId:3},{type:"Image",props:{y:238,x:0,skin:"Main/pifu-biaoti.png"},compId:92},{type:"Box",props:{x:50,width:626,height:102,centerY:-70},compId:100,child:[{type:"Button",props:{y:0,x:0,width:83,var:"leftBtn",stateNum:1,height:88},compId:93,child:[{type:"Image",props:{y:3,x:3,skin:"Main/wu-you.png",name:"leftFalse"},compId:95},{type:"Image",props:{y:3,x:3,skin:"Main/you-zuo.png",name:"leftTrue"},compId:96}]},{type:"Button",props:{y:51,x:572,width:94,var:"rightBtn",stateNum:1,pivotY:51,pivotX:51,height:97},compId:97,child:[{type:"Image",props:{y:51,x:51,width:80,skin:"Main/wu-zuo.png",rotation:180,pivotY:42,pivotX:40,name:"rightFalse",height:84},compId:98},{type:"Image",props:{y:51,x:51,width:80,skin:"Main/you-you.png",pivotY:42,pivotX:40,name:"rightTrue",height:84},compId:99}]}]},{type:"Image",props:{x:163.5,skin:"Main/dizuo.png",centerY:199},compId:101},{type:"Image",props:{x:173.5,width:379,var:"viewPort",height:426,centerY:14},compId:102},{type:"Box",props:{x:196,width:331,var:"btnBox",height:127,centerY:396},compId:113,child:[{type:"Image",props:{y:9,x:0,var:"using",skin:"Main/bt.png"},compId:103,child:[{type:"Text",props:{y:22,x:54.5,width:202,valign:"middle",text:"使用中",height:65,fontSize:48,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:104}]},{type:"Image",props:{y:9,x:0,var:"use",skin:"Main/bt.png",runtime:"View/Com/ButtonRunTime.ts"},compId:105,child:[{type:"Text",props:{y:22,x:54.5,width:202,valign:"middle",text:"使用",height:65,fontSize:48,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:106}]},{type:"Image",props:{y:9,x:0,var:"coin",skin:"Main/bt.png",runtime:"View/Com/ButtonRunTime.ts"},compId:107,child:[{type:"Image",props:{y:26.5,x:40,width:53,skin:"Main/jinbi-zhu.png",height:56},compId:109,child:[{type:"Text",props:{y:-4.5,x:37,width:202,valign:"middle",text:"500",height:65,fontSize:48,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:108}]}]},{type:"Image",props:{y:9,x:0,var:"video",skin:"Main/bt.png",runtime:"View/Com/ButtonRunTime.ts"},compId:110,child:[{type:"Image",props:{y:24,x:46,width:65,skin:"Main/shipin-biao.png",height:61},compId:111,child:[{type:"Text",props:{y:-2,x:63,width:202,valign:"middle",text:"1/3",height:65,fontSize:48,color:"#ffffff",bold:!0,align:"center",runtime:"laya.display.Text"},compId:112}]}]}]},{type:"Button",props:{y:155,x:562.5,var:"ExitBtn",stateNum:1,skin:"Main/exit2.png"},compId:116},{type:"Button",props:{y:131,x:18,var:"CloseBtn",stateNum:1,skin:"Main/guanbi-bt.png"},compId:117}],loadList:["Main/zhujiemian-1-20.png","Main/bg-sheng1.png","Main/pifu-biaoti.png","Main/wu-you.png","Main/you-zuo.png","Main/wu-zuo.png","Main/you-you.png","Main/dizuo.png","Main/bt.png","Main/jinbi-zhu.png","Main/shipin-biao.png","Main/exit2.png","Main/guanbi-bt.png"],loadList3D:[]},e.SkinShopViewUI=g,rt("ui.SkinShopViewUI",g);class u extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(u.uiView)}}u.uiView={type:"Scene",props:{width:720,height:1280},compId:2,child:[{type:"Image",props:{var:"bg",top:0,skin:"Main/zhujiemian-1-20.png",right:0,left:0,bottom:0,alpha:0},compId:3},{type:"Image",props:{y:647,x:159,width:402,var:"sliderBox",skin:"Main/huadong-tiao.png",height:33,gray:!1,centerY:23},compId:4,child:[{type:"Image",props:{y:124,x:37,skin:"Main/pause1.png"},compId:5},{type:"Image",props:{y:0,x:201,skin:"Main/shou.png",anchorX:.5},compId:6}]}],animations:[{nodes:[{target:6,keyframes:{x:[{value:201,tweenMethod:"linearNone",tween:!0,target:6,key:"x",index:0},{value:13,tweenMethod:"linearNone",tween:!0,target:6,key:"x",index:15},{value:201,tweenMethod:"linearNone",tween:!0,target:6,key:"x",index:30},{value:402,tweenMethod:"linearNone",tween:!0,target:6,key:"x",index:45},{value:201,tweenMethod:"linearNone",tween:!0,target:6,key:"x",index:60}]}}],name:"ani1",id:1,frameRate:24,action:2}],loadList:["Main/zhujiemian-1-20.png","Main/huadong-tiao.png","Main/pause1.png","Main/shou.png"],loadList3D:[]},e.TopTipUiUI=u,rt("ui.TopTipUiUI",u);class y extends Laya.Scene{constructor(){super()}createChildren(){super.createChildren(),this.createView(y.uiView)}}y.uiView={type:"Scene",props:{width:720,height:1280},compId:2,child:[{type:"Image",props:{top:0,skin:"Main/zhujiemian-1-20.png",sizeGrid:"11,11,13,10",right:0,left:0,bottom:0},compId:3},{type:"Image",props:{y:97,x:125,skin:"Main/biaoti.png"},compId:4},{type:"Image",props:{y:221,x:98,visible:!1,skin:"Main/shiyong-bg.png"},compId:5},{type:"Image",props:{y:657,x:170,skin:"Main/dizuo.png"},compId:6},{type:"Image",props:{y:357,x:169,width:380,var:"viewPort",height:398},compId:8},{type:"Button",props:{y:203,x:570,var:"ExitBtn",stateNum:1,skin:"Main/exit2.png"},compId:13},{type:"Image",props:{y:1192,x:287,var:"backBtn",skin:"Main/no-bt.png",runtime:"View/Com/ButtonRunTime.ts"},compId:9},{type:"Image",props:{x:212,var:"videoBtn",skin:"Main/sanbeilingqu--s.png",runtime:"View/Com/ButtonRunTime.ts",bottom:350},compId:10}],loadList:["Main/zhujiemian-1-20.png","Main/biaoti.png","Main/shiyong-bg.png","Main/dizuo.png","Main/exit2.png","Main/no-bt.png","Main/sanbeilingqu--s.png"],loadList3D:[]},e.TrialViewUI=y,rt("ui.TrialViewUI",y)}(ot||(ot={}));class ht{constructor(){ht.ins=this}static get Instance(){return null==ht.ins?new ht:ht.ins}static InitVideo(){Laya.Browser.onWeiXin&&(this.fsaasfafssfa=Laya.Browser.window.wx.createRewardedVideoAd({adUnitId:this.videlAdUnitId}),this.fsaasfafssfa.onLoad(()=>{console.log("激励视频 广告加载成功"),this.asfasfsaffsa=!0}),this.fsaasfafssfa.onError(e=>{console.log("激励视屏加载失败:"+e),this.asfasfsaffsa=!1}),this.afsfsaafsfsa=!0)}static ShowVideo(e){this.asfasfsaffsa&&(console.log("showVideoAd:"+this.asfasfsaffsa),this.SetVideoCallBack(e),this.fsaasfafssfa.show().catch(t=>{this.fsaasfafssfa.load().then(()=>{this.SetVideoCallBack(e),this.fsaasfafssfa.show()})}))}static SetVideoCallBack(e){this.fsaasfafssfa.offClose(),this.fsaasfafssfa.onClose(t=>{console.log("激励视频关闭:"+t.isEnded),t&&t.isEnded||void 0===t?e&&e(!0):e&&e(!1),this.fsaasfafssfa.offClose()})}static OpenBanner(e=0,t=null,i=!1){if(!Laya.Browser.onWeiXin)return void(t&&t(null));this.canshowbanner=!0;var a=this.bannerAdUnitId;console.log("adUnitId:"+a);let n=Laya.Browser.window.wx.createBannerAd({adUnitId:a,style:{left:0,top:0,width:460}});n.onError(e=>{console.log(e),t&&t(null)}),n.onLoad(()=>{this.curbanner&&this.curbanner.destroy(),this.curbanner=n;var a=this.GetRealHight(e);null!=t&&t(a),this.canshowbanner&&!i?this.curbanner.show():this.curbanner.hide()})}static GetRealHight(e){if(this.curbanner){let t=Laya.Browser.window.wx.getSystemInfoSync();return this.curbanner.style.width=t.windowWidth,this.curbanner.style.top=t.windowHeight-this.curbanner.style.realHeight-e,Laya.stage.height/t.windowHeight*this.curbanner.style.realHeight}}static Clear(){Laya.timer.clearAll(this),Laya.Tween.clearAll(this),this.canshowbanner=!1,this.curbanner&&this.curbanner.hide()}static hidebanner(){Laya.Browser.onWeiXin&&this.curbanner&&this.curbanner.hide()}static showbanner(){Laya.Browser.onWeiXin&&this.curbanner&&this.curbanner.show()}static get cancheat(){return C.Cheat?0==C.CheckScene?(console.log("cheat:true-> "+s.wxValue),!0):"1037"==s.wxValue||"1058"==s.wxValue||"1067"==s.wxValue||"1095"==s.wxValue?(console.log("cheat:true-> "+s.wxValue),!0):(console.log("cheat:false-> "+s.wxValue),!1):(console.log("cheat:false-> CurAccountData.cheat != 1"),!1)}showBanner(e=null,t=null,i=0){if(!Laya.Browser.onWeiXin)return void(e&&e(null));let a=ht.bannerAdUnitId,n=Laya.Browser.window.wx.createBannerAd({adUnitId:a,style:{left:0,top:0,width:460}});n.onLoad(()=>{console.log("[LOG] Banner广告加载成功"),this.hideBanner(),this._bannerAd=n;let t=Laya.Browser.window.wx.getSystemInfoSync();this._bannerAd.style.width=t.windowWidth,this._bannerAd.style.top=t.windowHeight-this._bannerAd.style.realHeight-10,this._bannerAd.show();var a=ht.GetRealHight2(this._bannerAd,i);let s={};s.banner=this._bannerAd,s.gap=a,e&&e(s)}),n.onError(e=>{console.log("[LOG] Banner广告加载失败"),console.log(e),t&&t()})}hideBanner(){Laya.Browser.onWeiXin&&this._bannerAd&&(this._bannerAd.hide(),this._bannerAd.destroy(),this._bannerAd=null)}showBanner2(e=null,t=null,i=0){if(!Laya.Browser.onWeiXin)return void(e&&e(null));let a=ht.bannerAdUnitId2,n=Laya.Browser.window.wx.createBannerAd({adUnitId:a,style:{left:0,top:0,width:460}});n.onLoad(()=>{console.log("[LOG] Banner广告加载成功"),this.hideBanner2(),this._bannerAd2=n;let t=Laya.Browser.window.wx.getSystemInfoSync();this._bannerAd2.style.width=t.windowWidth,this._bannerAd2.style.top=t.windowHeight-this._bannerAd2.style.realHeight-10,this._bannerAd2.show();var a=ht.GetRealHight2(this._bannerAd2,i);let s={};s.banner=this._bannerAd2,s.gap=a,console.log("data>>>>>",s),e&&e(s)}),n.onError(e=>{console.log("[LOG] Banner广告加载失败"),console.log(e),t&&t()})}hideBanner2(){Laya.Browser.onWeiXin&&this._bannerAd2&&(this._bannerAd2.hide(),this._bannerAd2.destroy(),this._bannerAd2=null)}showBanner3(e=null,t=null,i=0){if(!Laya.Browser.onWeiXin)return void(e&&e(null));let a=ht.bannerAdUnitId3,n=Laya.Browser.window.wx.createBannerAd({adUnitId:a,style:{left:0,top:0,width:460}});n.onLoad(()=>{console.log("[LOG] Banner广告加载成功"),this.hideBanner3(),this._bannerAd3=n;let t=Laya.Browser.window.wx.getSystemInfoSync();this._bannerAd3.style.width=t.windowWidth,this._bannerAd3.style.top=t.windowHeight-this._bannerAd3.style.realHeight-10,this._bannerAd3.show();var a=ht.GetRealHight2(this._bannerAd3,i);let s={};s.banner=this._bannerAd2,s.gap=a,e&&e(s)}),n.onError(e=>{console.log("[LOG] Banner广告加载失败"),console.log(e),t&&t()})}hideBanner3(){Laya.Browser.onWeiXin&&this._bannerAd3&&(this._bannerAd3.hide(),this._bannerAd3.destroy(),this._bannerAd3=null)}static CheatBanner(e,t=null,i=0){e.mouseEnabled=!1,ht.Instance.showBanner(i=>{if(null==i)e.mouseEnabled=!0;else{let n=Number(i.gap);i.banner.hide(),console.log("cheatstart","bottom:100"),e.mouseEnabled=!1,console.log("——height--",n);var a=Laya.stage.height-n-e.height-50;console.log("y:"+a),Laya.timer.once(1e3*C.CheatTime,this,()=>{i.banner.show(),Laya.Tween.to(e,{y:a},500,null,Laya.Handler.create(this,()=>{e.mouseEnabled=!0,console.log("上移成功cheat1--"),null!=t&&t()}))})}})}static CheatBanner2(e,t=null,i=0){e.mouseEnabled=!1,ht.Instance.showBanner2(i=>{if(null==i)e.mouseEnabled=!0;else{let n=Number(i.gap);i.banner.hide(),console.log("cheatstart","bottom:100"),console.log("——height--",n);var a=Laya.stage.height-n-e.height-50;console.log("y:"+a),Laya.timer.once(1e3*C.CheatTime,this,()=>{i.banner.show(),Laya.Tween.to(e,{y:a},500,null,Laya.Handler.create(this,()=>{e.mouseEnabled=!0,console.log("上移成功cheat2---"),i.banner.hide(),ht.Instance.showBanner3(),null!=t&&t()}))})}})}static CheatBanner3(e,t=null,i=0){e.mouseEnabled=!1,ht.Instance.showBanner3(i=>{if(null==i)e.mouseEnabled=!0;else{let n=Number(i.gap);i.banner.hide(),console.log("cheatstart","bottom:100"),console.log("——height--",n);var a=Laya.stage.height-n-e.height-50;console.log("y:"+a),Laya.timer.once(1e3*C.CheatTime,this,()=>{i.banner.show(),Laya.Tween.to(e,{y:a},500,null,Laya.Handler.create(this,()=>{console.log("上移成功cheat3--"),e.mouseEnabled=!0,i.banner.hide(),ht.Instance.showBanner(),null!=t&&t()}))})}})}static GetRealHight2(e,t){if(e){let i=Laya.Browser.window.wx.getSystemInfoSync();return e.style.width=i.windowWidth,e.style.top=i.windowHeight-e.style.realHeight-t,console.log("banner真实高度为---",Laya.stage.height/i.windowHeight*e.style.realHeight),Laya.stage.height/i.windowHeight*e.style.realHeight}}}ht.videlAdUnitId="adunit-0fb53ab4969d46bb",ht.bannerAdUnitId="adunit-de3afc5da6054394",ht.bannerAdUnitId2="adunit-72492b628fc3dee9",ht.bannerAdUnitId3="adunit-a0e0b5dbf2b6c840",ht.afsfsaafsfsa=!1,ht.asfasfsaffsa=!1,ht.canshowbanner=!0,ht.bannerhigt=0;var lt=Laya.Tween;class ct extends ot.LoadViewUI{constructor(){super(),this.proCom=!1,this.a=new Laya.Vector3,this.loadResCom=!1,this.loginCom=!1,this.errorTime=0,this.timers=0,this.subLoadCom=!1,ct.instance=this,a.on(Laya.Event.RESIZE,this,this.Resize)}static get Instance(){return ct.instance}Resize(){this.height=Laya.stage.height}OnShow(e){this.proTex.text="0%",this.pro1.width=0,this.RefreshUI(),this.LoginGame(),this.LoadSubpackage(),Laya.timer.frameOnce(5,this,()=>{this.Resize()}),D.AldEvent("进入加载加载界面!"),Laya.LocalStorage.getItem("newuser")?this.newuser=!1:(this.newuser=!0,Laya.LocalStorage.setItem("newuser","1"))}RefreshData(){this.proLen=this.pro.width}RegButton(){}RefreshUI(){lt.to(this.a,{x:1,update:new Laya.Handler(this,()=>{var e=this.a.x;this.pro1.width=this.proLen*e,e*=100,this.proTex.text=Math.ceil(e)+"%"})},1500,Laya.Ease.quadInOut,new Laya.Handler(this,()=>{this.proTex.text="100%",this.pro1.width=this.proLen,this.proCom=!0,this.AllCom()}))}LoadRes(){this.subLoadCom&&this.loginCom&&st.Instance.Load(()=>{D.AldEvent("资源加载成功"),this.loadResCom=!0,this.AllCom()})}LoginGame(){s.isWx?D.Login(e=>{this.onWxLoginHandler(e)}):this.LocalLogin()}onWxLoginHandler(e){if(console.log("微信回调成功!"),console.log(e),"error"==e||null==e.code){if(0==this.errorTime&&D.AldEvent("微信登录失败"),this.errorTime++,this.errorTime>=3)return;D.Login(e=>{this.onWxLoginHandler(e)})}else{0==this.errorTime&&D.AldEvent("微信登录成功!");let i=D.SystemInfo(),a="ipx";if(null!=i){var t=i.model;a=`${i.brand}_${t}_${i.system}_wx${i.version}_SDKVer${i.SDKVersion}`,console.log("platformModel:"+a)}new N(e.code,e.nickName,e.avatarUrl,e.gender,e.country,e.province,e.city,a,D.ShareId,D.Chanel),this.LocalLogin()}}LocalLogin(){T.Instance.login(null,e=>{this.OnLoginComplete(e)},e=>{this.OnLoginError(e)})}OnLoginComplete(e){if("0"!=e.code){if(console.log("登录异常错误!"),D.AldEvent("本地登录成功!"),this.timers++,this.timers>=4)return;s.isWx?D.Login(e=>{this.onWxLoginHandler(e)}):this.LocalLogin()}else this.loginCom=!0,this.LoadRes(),_t.InitSdk(),this.AllCom()}OnLoginError(e){console.log("登录错误"),D.AldEvent("本地登陆失败")}LoadSubpackage(){D.LoadSubPackage("subpackage",e=>{e&&(console.log("subpackage com++++++++++++++++"),ct.instance.subLoadCom=!0,ct.instance.LoadRes())})}AllCom(){this.proCom&&this.loadResCom&&this.loginCom&&(ht.InitVideo(),Laya.timer.once(1e3,this,()=>{_t.ValueUser(),D.AldEvent("进入主界面"),Mt.Instance.OpenView(mt.MainView),!this.newuser&&_t.iswhite&&Mt.Instance.AddView(mt.GiftView),le.Instance.InitMouseEvent(),l.OnShowHandle(),h.Instance.Init(),c.Reg(),h.Instance._playMusic()}))}OnClose(){ct.instance=null,a.off(Laya.Event.RESIZE,this,this.Resize)}}class dt extends ot.MainViewUI{constructor(){super(),this.isTryed=!1,dt.instance=this,this.Resize(),a.on(Laya.Event.RESIZE,this,this.Resize)}static get Instance(){return dt.instance}OnShow(e){this.RefreshData(),this.RegButton(),this.RefreshUI(),this.SetData(),this.SetTopAd()}RefreshUI(){this.user_id.text="user_id:"+N.Instance.CurModel.m_userid,this.SetPlayerGrade(N.Instance.CurModel.GetUserAttr(A.money)),this.SetStage(),this.SetStagePro(0),this.SetSettingBox(!1),this.MoreFunBtn2.bottom=this.sliderBox.bottom+155}RefreshData(){this.GetImage(),this.coinFollow=new O(.1,0,0,.1),this.proWidth=this.pro.width,this.isTryed=!1}AdaptiveUI(){}moreFunc(e){e||console.log("mainui")}RegButton(){this.on(Laya.Event.MOUSE_DOWN,this,this.StartGame),this.settingBtn.CZ=(()=>{this.SetSettingBox()}),this.skinBtn.CZ=(()=>{Mt.Instance.AddView(mt.SKinShopView)}),this.updateBtn.CZ=(()=>{Mt.Instance.AddView(mt.IntensifyView)}),a.on(n.Event.ShowMainUi,this,this.ShowMainBox),a.on(n.Event.SetMonery,this,this.SetPlayerGrade),a.on(n.Event.SetStage,this,this.SetStage),a.on(n.Event.SetStagePro,this,this.SetStagePro),this.sound_btn.clickHandler=new Laya.Handler(this,()=>{this.ClickSound()}),this.shake_btn.clickHandler=new Laya.Handler(this,()=>{this.ClickShake()}),this.ExitBtn.clickHandler=new Laya.Handler(this,this.ClickExit),this.MoreGameBtn.clickHandler=new Laya.Handler(this,this.ClickExport),this.MoreFunBtn2.clickHandler=new Laya.Handler(this,this.ClickExport),this.ExitBtn.visible=_t.iswhite,this.VideoGetCoinBtn.clickHandler=new Laya.Handler(this,this.VideoGet),this.CloseVideoBtn.clickHandler=new Laya.Handler(this,this.CloseVideoGet)}ClickExit(){Mt.Instance.AddView(mt.ExitView)}ClickExport(){Mt.Instance.AddView(mt.ExportView)}SetStage(){this.stageValue.text=v.Instance.stage.toString()}SetStagePro(e){e=e>=1?1:e,this.pro1.width=this.proWidth*e}SetPlayerGrade(e){this.tempTarGrade=e,this.coinFollow.target=e,Laya.timer.frameLoop(1,this,this.T2)}T2(){this.coinFollow.update();let e=Math.ceil(this.coinFollow.follow);this.countValue.text=e.toString(),e>=this.tempTarGrade&&(this.countValue.text=this.tempTarGrade.toString(),Laya.timer.clear(this,this.T2))}StartGame(e){if(this.isTryed)return void this.TryStartGame();if(e.target instanceof Laya.UIComponent&&"mainBox"!=e.target.name)return;console.log("click");let t=[{t:N.Instance.CurModel.ServerTime}];T.Instance.HttpPostRequest(R.protocols.Start,t,e=>{e.play_id&&(v.Instance.Play_Id=e.play_id),D.Start(v.Instance.stage.toString()),1==Me.GameCount?Mt.Instance.AddView(mt.TrialView):this.MainStartGame()},e=>{})}MainStartGame(){Me.GameCount++,Me.GameNum++,this.mainBox.visible=!1,this.sliderBox.visible=!1,this.off(Laya.Event.MOUSE_DOWN,this,this.StartGame),this.gameStart.stop(),Me.Instance.Start(),le.Instance.StartGameClick(),Je.Instance.Start(),Ge.Instance.TrialModelPlayAni(),Ie.Instance.SetBlock()}TryStartGame(){Me.GameCount++,Me.GameNum++,this.sliderBox.visible=!1,this.gameStart.stop(),this.off(Laya.Event.MOUSE_DOWN,this,this.StartGame),Me.Instance.Start(),le.Instance.StartGameClick(),Je.Instance.Start(),Ge.Instance.TrialModelPlayAni(),Ie.Instance.SetBlock()}TryClick(){this.isTryed=!0,this.mainBox.visible=!1}ShowMainBox(){this.mainBox.visible=!0,this.sliderBox.visible=!0,this.gameStart.play(0,!0),this.SetPlayerGrade(N.Instance.CurModel.GetUserAttr(A.money)),this.isTryed=!1,this.on(Laya.Event.MOUSE_DOWN,this,this.StartGame)}SetSettingBox(e=!0){this.settingBox.visible=!!e&&!this.settingBox.visible}GetImage(){this.sound_open=this.sound_btn.getChildByName("kai"),this.sound_guan=this.sound_btn.getChildByName("guan"),this.shake_open=this.shake_btn.getChildByName("kai"),this.shake_guan=this.shake_btn.getChildByName("guan"),this.ShowSound(h.Instance.sound),this.ShowShake(h.Instance.vibrate)}ClickSound(){h.Instance.sound=!h.Instance.sound,this.ShowSound(h.Instance.sound)}ShowSound(e){e?(this.sound_open.visible=!0,this.sound_guan.visible=!1,h.Instance.SettingSound(1),Laya.LocalStorage.setItem("sound","1"),console.log("开启声音")):(this.sound_open.visible=!1,this.sound_guan.visible=!0,h.Instance.SettingSound(0),Laya.LocalStorage.setItem("sound","0"),console.log("关闭声音"))}ClickShake(){h.Instance.vibrate=!h.Instance.vibrate,this.ShowShake(h.Instance.vibrate)}ShowShake(e){e?(this.shake_open.visible=!0,this.shake_guan.visible=!1,Laya.LocalStorage.setItem("vibrate","1"),console.log("开启震动")):(this.shake_open.visible=!1,this.shake_guan.visible=!0,Laya.LocalStorage.setItem("vibrate","0"),console.log("关闭震动"))}OnClose(){this.off(Laya.Event.MOUSE_DOWN,this,this.StartGame),a.off(Laya.Event.RESIZE,this,this.Resize),a.off(n.Event.ShowMainUi,this,this.ShowMainBox),a.off(n.Event.SetMonery,this,this.SetPlayerGrade),a.off(n.Event.SetStage,this,this.SetStage),a.off(n.Event.SetStagePro,this,this.SetStagePro),dt.instance=null,Laya.timer.clearAll(this)}Resize(){this.height=Laya.stage.height}SetData(){_t.SetHuTuiList(this.BottomList,2,""),this.GunGun()}GunGun(){var e;try{this.BottomList.scrollBar.value=0,e=this.BottomList.scrollBar.max}catch(e){return void console.error(e)}var t=1;Laya.timer.frameLoop(1,this,()=>{this.BottomList.scrollBar.value+=t,(this.BottomList.scrollBar.value>=e||this.BottomList.scrollBar.value<=0)&&(t=-t)})}SetTopAd(){Laya.Browser.onPC||(this.topAdData=_t.pushData||[],this.LeftPushIcon.visible=this.RightPushIcon.visible=this.topAdData.length>=2,this.topAdData.length<2||(this.topLeftAdIndex={index:0},this.topRightAdIndex={index:1},this._setTopAd(this.LeftPushIcon,this.topLeftAdIndex),this._setTopAd(this.RightPushIcon,this.topRightAdIndex)))}_setTopAd(e,t){let i=e.getChildByName("icon"),a=e.getChildByName("name");e.clickHandler=new Laya.Handler(this,()=>{_t.ShowHuTuiJump(this.topAdData[t.index])}),this._setIcon(i,a,t),Laya.timer.loop(3e3,this,()=>{this._setIcon(i,a,t),this.lefticon.play(null,!1),this.righticon.play(null,!1)})}_setIcon(e,t,i){i.index=(i.index+2)%this.topAdData.length,e.skin=this.topAdData[i.index].icon,t.text=this.topAdData[i.index].togame_name}ShowBoxPanel(){this.BoxPanel.visible=!0,this.CloseVideoBtn.visible=!1,Laya.timer.once(2e3,this,()=>{this.CloseVideoBtn.visible=!0}),ht.Instance.showBanner2(e=>{e&&(this.banner=e.banner)})}HideBoxPanel(){this.BoxPanel.visible=!1,this.banner&&this.banner.hide()}VideoGet(){ht.ShowVideo(e=>{if(e){var t=[{t:N.Instance.CurModel.ServerTime.toString()},{reward_item:"1000"},{reward_num:"200"}];T.Instance.HttpPostRequest(R.protocols.Fissionvd,t,e=>{Mt.Instance.ShowTips("金币:X200"),this.HideBoxPanel()},e=>{})}})}CloseVideoGet(){this.HideBoxPanel()}}class pt extends ot.CompleteViewUI{constructor(){super(),this.isWin=!1,this.clicknum=0,pt.instance=this,this.Resize(),a.on(Laya.Event.RESIZE,this,this.Resize)}static get Instance(){return pt.instance}OnShow(e){this.isWin=e,this.RefreshData(),this.RegButton(),this.RefreshUI(),this.SetTopAd(),1==Me.GameCount||Me.GameCount>=4?(ht.Instance.showBanner(e=>{e&&(this.banner=e.banner,console.log("banner加载完毕---",this.banner))}),this.nextBtn.y=Laya.stage.height-this.nextBtn.height-300):_t.iswhite?this.nextBtn.y=Laya.stage.height-this.nextBtn.height-50:(ht.Instance.showBanner(e=>{e&&(this.banner=e.banner,console.log("banner加载完毕---",this.banner))}),this.nextBtn.y=Laya.stage.height-this.nextBtn.height-300)}Resize(){this.height=Laya.stage.height}RefreshData(){this.coinValue=1==this.isWin?Q.Instance._level.gold:Q.Instance._level.fail_gold,this.tes1=this.coinValue,this.coinValue+=v.tower_reward*Me.Instance.towerCount+v.enemy_reward*Me.Instance.roleCount+v.block_reward*Me.Instance.blockCount;let e=1==this.isWin?1:0,t=this.coinValue,i=[{t:N.Instance.CurModel.ServerTime},{play_id:v.Instance.Play_Id},{win:e},{money:t}];T.Instance.HttpPostRequest(R.protocols.GameResult,i,e=>{},e=>{Mt.Instance.ShowTips("结算失败")}),this.isWin?(h.Instance.PlaySound(o.win),D.Success(v.Instance.stage.toString())):(h.Instance.PlaySound(o.defeat),D.Fail(v.Instance.stage.toString()))}RegButton(){this.ExitBtn.visible=_t.iswhite,this.ExitBtn.clickHandler=new Laya.Handler(this,this.ClickExit),this.doublegetBtn.CZ=(()=>{this.DoubleGet()}),this.nextBtn.CZ=(()=>{this.clicknum++,Me.GameCount<=1||Me.GameCount>=4?this.isWin?this.Next():this.Resset():_t.iswhite&&this.clicknum<=1?ht.CheatBanner3(this.nextBtn,()=>{}):this.isWin?this.Next():this.Resset()})}ClickExit(){Mt.Instance.AddView(mt.ExitView)}Next(){Me.Instance.LevelUp()}Resset(){Mt.Instance.CloseView(mt.CompleteView),Me.Instance.ReStart()}OnClose(){a.off(Laya.Event.RESIZE,this,this.Resize),pt.instance=null,Laya.timer.clearAll(this),_t.iswhite&&(ht.Instance._bannerAd3&&ht.Instance._bannerAd3.hide(),ht.Instance._bannerAd&&ht.Instance._bannerAd.hide()),1==Me.GameNum?(Me.GameCount<=3&&_t.iswhite&&Mt.Instance.AddView(mt.GoldEggView),Mt.Instance.AddView(mt.ExportView)):(Me.GameCount<=3&&_t.iswhite&&Mt.Instance.AddView(mt.GoldEggView),Mt.Instance.AddView(mt.ExportView,!0))}RefreshUI(){this.winTop.visible=this.isWin,this.shibaiTop.visible=!this.isWin,this.valueText.text="+"+this.coinValue,this.towerCount.text="X"+Me.Instance.towerCount.toString(),this.towerValue.text=(v.tower_reward*Me.Instance.towerCount).toString(),this.roleCount.text="X"+Me.Instance.roleCount.toString(),this.roleValue.text=(v.enemy_reward*Me.Instance.roleCount).toString(),this.blockCount.text="X"+Me.Instance.blockCount.toString(),this.blockValue.text=(v.block_reward*Me.Instance.blockCount).toString()}DoubleGet(){ht.ShowVideo(e=>{if(e){D.AldEvent("结束界面看视屏获得钱");var t=[{t:N.Instance.CurModel.ServerTime.toString()},{reward_item:"1000"},{reward_num:(2*this.coinValue).toString()}];T.Instance.HttpPostRequest(R.protocols.Fissionvd,t,e=>{Mt.Instance.ShowTips("金币:X"+3*this.coinValue),this.Next()},e=>{})}})}SetTopAd(){Laya.Browser.onPC||(this.topAdData=_t.pushData||[],this.topAdData.length<4||(this.topLeftAdIndex={index:0},this.topRightAdIndex={index:1},this.bottomleftAdIndex={index:2},this.bottomRightAdIndex={index:3},this._setTopAd(this.LeftTopPushIcon,this.topLeftAdIndex),this._setTopAd(this.LeftBottomPushIcon,this.bottomleftAdIndex),this._setTopAd(this.RightTopPushIcon,this.topRightAdIndex),this._setTopAd(this.RightBottomPushIcon,this.bottomRightAdIndex)))}_setTopAd(e,t){let i=e.getChildByName("icon"),a=e.getChildByName("name");e.clickHandler=new Laya.Handler(this,()=>{_t.ShowHuTuiJump(this.topAdData[t.index])}),this._setIcon(i,a,t),Laya.timer.loop(3e3,this,()=>{this._setIcon(i,a,t),this.pushshake.play(null,!1)})}_setIcon(e,t,i){i.index=(i.index+4)%this.topAdData.length,e.skin=this.topAdData[i.index].icon,t.text=this.topAdData[i.index].togame_name}}class gt extends ot.InGameViewUI{static get Instance(){return gt.instance}constructor(){super(),gt.instance=this,this.Resize(),a.on(Laya.Event.RESIZE,this,this.Resize)}OnShow(e){this.RefreshData(),this.RegButton(),this.RefreshUI()}Resize(){this.height=Laya.stage.height}RefreshData(){}RegButton(){}RefreshUI(){}OnClose(){a.off(Laya.Event.RESIZE,this,this.Resize),gt.instance=null,Laya.timer.clearAll(this)}}class ut extends ot.IntensifyViewUI{constructor(){super(),this.iscoinShowfreecoinbtn=!1,this.Resize(),a.on(Laya.Event.RESIZE,this,this.Resize)}OnShow(e){this.RefreshData(),this.RegButton(),this.RefreshUI(),ht.Instance.showBanner2(e=>{e&&(this.banner=e.banner,console.log("banner加载成功--"))})}RefreshUI(){this.InitUi(),this.RefreshCoinShow();let e=this.cost1{this.backBtn.visible=!0,this.backBtn.clickHandler=new Laya.Handler(this,this.ClickClose)}),this.atkupBtn.clickHandler=new Laya.Handler(this,this.AtkUp),this.rateupBtn.clickHandler=new Laya.Handler(this,this.RateUp),this.getcoinBtn.clickHandler=new Laya.Handler(this,this.GetCoin)}ClickExit(){Mt.Instance.AddView(mt.ExitView)}ClickClose(){Mt.Instance.CloseView(mt.IntensifyView)}AtkUp(){N.Instance.CurModel.GetUserAttr(A.money){e&&(D.AldEvent("升级界面花钱升级攻击力"),this.tempPowerLevel++,this.InitUi(),a.event(n.Event.SetMonery,N.Instance.CurModel.GetUserAttr(A.money)))})}RateUp(){N.Instance.CurModel.GetUserAttr(A.money){e&&(D.AldEvent("升级界面花钱升级速度"),this.tempRateLevel++,this.InitUi(),a.event(n.Event.SetMonery,N.Instance.CurModel.GetUserAttr(A.money)))})}GetCoin(){ht.ShowVideo(e=>{if(e){var t=[{t:N.Instance.CurModel.ServerTime.toString()},{reward_item:"1000"},{reward_num:this.freecoinValue.toString()},{channel:"video:freecoin"}];T.Instance.HttpPostRequest(R.protocols.Fissionvd,t,e=>{D.AldEvent("升级界面看视屏获得钱"),a.event(n.Event.SetMonery,N.Instance.CurModel.GetUserAttr(A.money)),this.RefreshData(),this.RefreshCoinShow()},e=>{})}})}RefreshCoinShow(){this.iscoinShowfreecoinbtn?(this.getcoinBtn.gray=!1,this.getcoinBtn.mouseEnabled=!0):(this.getcoinBtn.gray=!0,this.getcoinBtn.mouseEnabled=!1)}InitUi(){this.atkLv.text="LV"+this.tempPowerLevel;let e=g.Instance._atk.length,t=this.tempPowerLevel>e?e:this.tempPowerLevel;this.cost1=g.Instance.GetAtk(t).cost,this.atkValue.text=this.cost1.toString(),this.rateLv.text="LV"+this.tempRateLevel;let i=g.Instance._rate.length,a=this.tempRateLevel>i?i:this.tempRateLevel;this.cost2=g.Instance.GetRate(a).cost,this.rateValue.text=this.cost2.toString(),N.Instance.CurModel.GetUserAttr(A.money)e?e:this.tempPowerLevel;this.cost1=g.Instance.GetAtk(t).cost,this.atkValue.text=this.cost1.toString(),this.rateLv.text="LV"+this.tempRateLevel;let i=g.Instance._rate.length,a=this.tempRateLevel>i?i:this.tempRateLevel;this.cost2=g.Instance.GetRate(a).cost,this.rateValue.text=this.cost2.toString(),N.Instance.CurModel.GetUserAttr(A.money){this.BackClickHandler()}),this.atkBtn.clickHandler=new Laya.Handler(this,this.AtkBtnHandler),this.rateBtn.clickHandler=new Laya.Handler(this,this.RateBtnHandler)}ClickExit(){Mt.Instance.AddView(mt.ExitView)}AtkBtnHandler(){this.isatkvideo?ht.ShowVideo(e=>{e&&v.Instance.PowerUp(this.tempPowerLevel+1,"video:free",this.cost1,e=>{e&&(D.AldEvent("失败界面看视屏升级攻击力"),this.tempPowerLevel++,this.isfirstatkvideo=!1,this.SetUi(),a.event(n.Event.SetMonery,N.Instance.CurModel.GetUserAttr(A.money)))})}):v.Instance.PowerUp(this.tempPowerLevel+1,"money",this.cost1,e=>{e&&(D.AldEvent("失败界面花钱升级攻击力"),this.tempPowerLevel++,this.SetUi(),a.event(n.Event.SetMonery,N.Instance.CurModel.GetUserAttr(A.money)))})}RateBtnHandler(){this.isratevideo?ht.ShowVideo(e=>{e&&v.Instance.SpeedUp(this.tempRateLevel+1,"video:free",this.cost2,e=>{e&&(D.AldEvent("失败界面看视屏升级速度"),this.tempRateLevel++,this.isfirstratevideo=!1,this.SetUi())})}):v.Instance.SpeedUp(this.tempRateLevel+1,"money",this.cost2,e=>{e&&(D.AldEvent("失败界面花钱升级速度"),this.tempRateLevel++,this.SetUi())})}BackClickHandler(){Mt.Instance.CloseView(mt.AttributeUpView),Me.Instance.ReStart()}OnClose(){a.off(Laya.Event.RESIZE,this,this.Resize),this.tempPowerLevel==v.Instance.powerLevel&&this.tempRateLevel==v.Instance.rateLevel||(v.Instance.SetInfo(),a.event(n.Event.SetMonery,N.Instance.CurModel.GetUserAttr(A.money)))}Resize(){this.height=Laya.stage.height}InitPushData(){for(let e=0;e<_t.pushData.length;e++)e<6&&this.PushDataArray.push(_t.pushData[e]);for(let e=0;e-1;i--)t<6&&e.push(_t.pushData[i]),t++;for(let t=0;t{e&&(D.AldEvent("商店中看视屏获得皮肤"),this.VideoGet())})}VideoGet(){var e=[{t:N.Instance.CurModel.ServerTime.toString()},{id:this.operateIndex},{channel:"video"}];T.Instance.HttpPostRequest(R.protocols.themefission,e,e=>{var t=N.Instance.CurModel;v.Instance.equipId=Number(t.GetUserAttr(A.equip_themes)[1]),this.RefreshBtnUi(this.operateIndex)},e=>{})}Buy(){var e=[{id:this.operateIndex}];T.Instance.HttpPostRequest(R.protocols.Buy,e,e=>{var t=N.Instance.CurModel;v.Instance.equipId=Number(t.GetUserAttr(A.equip_themes)[1]),a.event(n.Event.SetMonery,N.Instance.CurModel.GetUserAttr(A.money)),this.RefreshBtnUi(this.operateIndex)},e=>{})}Equip(){var e=[{id:this.operateIndex}];T.Instance.HttpPostRequest(R.protocols.Equip,e,e=>{var t=N.Instance.CurModel;v.Instance.equipId=Number(t.GetUserAttr(A.equip_themes)[1]),this.RefreshBtnUi(this.operateIndex)},e=>{})}RegButton(){this.ExitBtn.visible=_t.iswhite,this.ExitBtn.clickHandler=new Laya.Handler(this,this.ClickExit),this.CloseBtn.visible=!1,Laya.timer.once(3e3,this,()=>{this.CloseBtn.visible=!0,this.CloseBtn.clickHandler=new Laya.Handler(this,this.ClickClose)}),this.leftBtn.clickHandler=Laya.Handler.create(this,()=>{1!=this.operateIndex&&(this.operateIndex--,this.SetBtnUi(this.operateIndex),this.RefreshBtnUi(this.operateIndex),ft.Instance.CreatePlayer(this.operateIndex))},null,!1),this.rightBtn.clickHandler=Laya.Handler.create(this,()=>{8!=this.operateIndex&&(this.operateIndex++,this.SetBtnUi(this.operateIndex),this.RefreshBtnUi(this.operateIndex),ft.Instance.CreatePlayer(this.operateIndex))},null,!1),this.use.CZ=(()=>{this.Equip()}),this.coin.CZ=(()=>{N.Instance.CurModel.GetUserAttr(A.money){this.ClickVideo()})}ClickExit(){Mt.Instance.AddView(mt.ExitView)}OnClose(){a.off(Laya.Event.RESIZE,this,this.Resize),It.instance=null,D.AldEvent("关闭皮肤界面")}}class vt extends ot.TrialViewUI{constructor(){super(),this.clicknum=0,this.Resize(),a.on(Laya.Event.RESIZE,this,this.Resize)}OnShow(e){this.RegButton(),this.RefreshData(),this.RegButton(),this.RefreshUI(),Me.GameCount<1||Me.GameCount>=3?(console.log("第一局游戏》》》》"),ht.Instance.showBanner2(e=>{e&&(this.banner=e.banner)}),this.backBtn.y=Laya.stage.height-this.backBtn.height-300):(console.log("非第一局游戏1》》》》"),_t.iswhite?this.backBtn.y=Laya.stage.height-this.backBtn.height-50:(ht.Instance.showBanner2(),this.backBtn.y=Laya.stage.height-this.backBtn.height-300))}RefreshUI(){ft.Instance.InitDis(this.viewPort)}RefreshData(){}RegButton(){this.ExitBtn.visible=_t.iswhite,this.ExitBtn.clickHandler=new Laya.Handler(this,this.ClickExit),this.videoBtn.CZ=(()=>{this.VideoHandler()}),this.backBtn.CZ=(()=>{this.clicknum++,Me.GameCount<1||Me.GameCount>=3?(console.log("第一局游戏2》》》》"),ft.Instance.Reset(),this.BackUi()):(console.log("非第一局游戏2》》》》"),_t.iswhite&&this.clicknum<=1?ht.CheatBanner2(this.backBtn):(ft.Instance.Reset(),this.BackUi()))})}ClickExit(){Mt.Instance.AddView(mt.ExitView)}VideoHandler(){ht.ShowVideo(e=>{e&&(D.AldEvent("看视屏试用"),this.VideoCom())})}VideoCom(){ft.Instance.Reset(),this.BackUi(),Ge.Instance.Trial()}BackUi(){Mt.Instance.CloseView(mt.TrialView),dt.Instance&&dt.Instance.TryClick()}OnClose(){a.off(Laya.Event.RESIZE,this,this.Resize),_t.iswhite?(ht.Instance._bannerAd2&&ht.Instance._bannerAd2.hide(),ht.Instance._bannerAd3&&ht.Instance._bannerAd3.hide()):ht.Instance.hideBanner2()}Resize(){this.height=Laya.stage.height}}class xt extends ot.GuideViewUI{constructor(){super(),this.isguide2or3=!1,this.guide1pos=F.VecZero,this.guide1Com=!1,xt.instance=this,this.Resize(),a.on(Laya.Event.RESIZE,this,this.Resize)}static get Instance(){return xt.instance}OnShow(e){this.RegButton(),this.RefreshData(),this.RefreshUI()}RefreshUI(){}RefreshData(){}RegButton(){}TwoGuide(){this.guide3Box.visible=!0,this.guide4Box.visible=!0,this.guide2Image.visible=!0,this.guide3.play(0,!0),this.guide4.play(0,!0),Laya.timer.frameLoop(1,this,this._twoguide),this.guide1pos.x=-4.5,this.guide1pos.y=0}_twoguide(){let e=ie.WorldToScreen2(this._camera,ue.Instance.guidetwoPos.clone());this.guide4Box.pos(e.x,e.y),this.guide1pos.z=this.playerTran.localPositionZ+5;let t=ie.WorldToScreen2(this._camera,this.guide1pos);this.guide3Box.pos(t.x,t.y),this.playerTran.localPositionZ>=ue.Instance.guidetwoPos.z-10&&(this.guide3Box.visible=!1,this.guide4Box.visible=!1,this.guide2Image.visible=!1,this.guide3Image.visible=!0,this.guide3.stop(),this.guide4.stop(),Laya.timer.clear(this,this._twoguide),Laya.timer.once(5e3,this,()=>{ue.Instance.GuideOff()}))}SetGuide(e){this.playerTran||(this.playerTran=Je.Instance.playerTra),this._camera||(this._camera=q.Instance._maincamera),1==e&&(this.guide1Image.visible=!0,this.guide2Image.visible=!1,this.guide3Image.visible=!1,this.guide1Box.visible=!0,this.guide1.play(0,!0),this.guide4Box.visible=!1,this.playerTran.localPositionX<=ue.Instance.guideonepos.x?(this.guide2Box.visible=!0,this.guide3Box.visible=!1,this.isguide2or3=!0,this.guide2.play(0,!0)):(this.guide2Box.visible=!1,this.guide3Box.visible=!0,this.isguide2or3=!1,this.guide3.play(0,!0)),this.guide1pos=ue.Instance.guideonepos.clone(),Laya.timer.frameLoop(1,this,this.OneGuide),this.guide1Com=!1)}OnClose(){a.off(Laya.Event.RESIZE,this,this.Resize),xt.instance=null,Laya.timer.clearAll(this)}Resize(){this.height=Laya.stage.height}OneGuide(){if(this.guide1Com)this.playerTran.localPositionZ>=ue.Instance.guideonepos.z&&(console.log(111),Laya.timer.clear(this,this.OneGuide),this.TwoGuide());else{let e=ie.WorldToScreen2(this._camera,ue.Instance.guideonepos.clone());this.guide1Box.pos(e.x,e.y),this.guide1pos.z=this.playerTran.localPositionZ+10;let t=ie.WorldToScreen2(this._camera,this.guide1pos);this.isguide2or3?this.guide2Box.pos(t.x,t.y):this.guide3Box.pos(t.x,t.y),this.playerTran.localPositionZ>=ue.Instance.guideonepos.z-5&&(this.guide2.stop(),this.guide3.stop(),this.guide2Box.visible=!1,this.guide3Box.visible=!1,this.guide1Box.visible=!1,this.guide1Com=!0,this.guide1Image.visible=!1)}}}class Lt extends ot.ShadeViewUI{constructor(){super(),this.Resize(),a.on(Laya.Event.RESIZE,this,this.Resize)}OnShow(e){this.RegButton()}RefreshUI(){}RefreshData(){}RegButton(){this.on(Laya.Event.CLICK,this,this.Test)}Test(){}OnClose(){a.off(Laya.Event.RESIZE,this,this.Resize),this.off(Laya.Event.CLICK,this,this.Test)}Resize(){this.height=Laya.stage.height}}class St extends ot.ExportViewUI{constructor(){super(...arguments),this.jump=!1,this.clicknum=0}OnShow(e){this.CloseBtn.clickHandler=e?Laya.Handler.create(this,this.ClickClose,[e],!1):Laya.Handler.create(this,this.ClickClose,null,!1),this.ContinueBtn.clickHandler=Laya.Handler.create(this,this.ClickContinue,null,!1),this.SetData(),this.ContinueBtn.visible=_t.iswhite,this.CloseBtn.visible=!1,Laya.timer.once(3e3,this,()=>{this.CloseBtn.visible=!0}),Me.GameCount>1&&Me.GameCount<4&&_t.iswhite&&ht.Instance._bannerAd&&(this._banner=ht.Instance._bannerAd,this._banner.hide(),console.log("banner加载完毕--",this._banner)),this.height=Laya.stage.height,Laya.stage.on(Laya.Event.RESIZE,this,()=>{this.height=Laya.stage.height})}OnClose(){Laya.timer.clearAll(this)}ClickClose(e){Mt.Instance.CloseView(mt.ExportView),e&&Mt.Instance.AddView(mt.IntensifyView)}ClickContinue(){if(this.clicknum++,_t.iswhite)if(Me.GameCount<=1||Me.GameCount>=4){let e=t.randomInt(0,_t.pushData.length),i=_t.pushData[e];_t.ClickAd(_t.Ad_ClickType.PushClick),_t.ShowHuTuiJump(i)}else if(1==this.clicknum)this.ContinueBtn.mouseEnabled=!1,this._banner?(console.log("展示banner"),this._banner.show(),Laya.timer.once(1e3,this,()=>{this._banner.hide(),this.ContinueBtn.mouseEnabled=!0})):Laya.timer.once(1e3,this,()=>{this.ContinueBtn.mouseEnabled=!0});else{let e=t.randomInt(0,_t.pushData.length),i=_t.pushData[e];_t.ClickAd(_t.Ad_ClickType.PushClick),_t.ShowHuTuiJump(i)}else Mt.Instance.CloseView(mt.ExportView)}SetData(){_t.SetHuTuiList(this.TopList,2,""),_t.SetHuTuiList(this.BottomList,1,""),this.GunGun()}GunGun(){var e,t;try{this.TopList.scrollBar.value=0,this.BottomList.scrollBar.value=0,e=this.TopList.scrollBar.max,t=this.BottomList.scrollBar.max}catch(e){return void console.error(e)}var i=1,a=1;Laya.timer.frameLoop(1,this,()=>{this.TopList.scrollBar.value+=i,(this.TopList.scrollBar.value>=e||this.TopList.scrollBar.value<=0)&&(i=-i),this.BottomList.scrollBar.value+=a,(this.BottomList.scrollBar.value>=t||this.BottomList.scrollBar.value<=0)&&(a=-a)})}}class bt extends ot.ExitViewUI{constructor(){super(),this.jump=!1,bt.ins=this}static get Instance(){return bt.ins?bt.ins:new bt}OnShow(e){this.SetData(),this.Jump(),this.CloseBtn.clickHandler=e?new Laya.Handler(this,this.ClickClose,[e]):new Laya.Handler(this,this.ClickClose),this.CloseBtn.visible=!1,Laya.timer.once(2e3,this,()=>{this.CloseBtn.visible=!0}),this.height=Laya.stage.height,Laya.stage.on(Laya.Event.RESIZE,this,()=>{this.height=Laya.stage.height})}OnClose(){}ClickClose(e){Mt.Instance.CloseView(mt.ExitView),e&&Mt.Instance.AddView(mt.CompleteView,Me.WINORLOSE)}SetData(){_t.SetHuTuiList(this.PushList,1,"")}Jump(){let e=t.randomInt(0,_t.pushData.length),i=_t.pushData[e];_t.ClickAd(_t.Ad_ClickType.PushClick),_t.ShowHuTuiJump(i)}}class kt extends ot.GoldEggViewUI{constructor(){super(),this._isComplete=!1,this._isShowBanner=!1,this._bannerVal=.5,this._maxClickCnt=12,this._clickCnt=0,this._interval=500,this._decrement=.03,this.shownum=3,this.nowshownum=0,kt.ins=this}static get Instance(){return kt.ins?kt.ins:new kt}RefreshData(){}RegButton(){}Resize(){}RefreshUI(e){}OnShow(e=null){this.HitBtn.y=Laya.stage.height-this.HitBtn.height-50,this.kuangdian.y=Laya.stage.height-this.HitBtn.height-200,this.btnscale.play(null,!0),this.HitBtn.clickHandler=Laya.Handler.create(this,this.QiaoDa,null,!1),this._bannerVal=t.randRangefloat(.35,.75),this.jindu.value=0,Laya.timer.loop(this._interval,this,this.Daojishi),D.OnShow(this.onBannerHide),ht.Instance._bannerAd&&(this.banner=ht.Instance._bannerAd,this.banner.hide(),console.log("金蛋界面banner加载完毕--",this.banner)),this.height=Laya.stage.height,this.BG.height=Laya.stage.height,Laya.stage.on(Laya.Event.RESIZE,this,()=>{this.BG.height=Laya.stage.height,this.height=Laya.stage.height})}ClosePanel(){Mt.Instance.CloseView(mt.AttributeUpView)}OnClose(){console.log("设置界面关闭---")}QiaoDa(){if(this.ani1.play(null,!1),this.btnscale.stop(),this.kuangdian.visible=!1,!this._isComplete){this._clickCnt++,this._clickCnt>this._maxClickCnt&&(this._clickCnt=this._maxClickCnt);let e=this._clickCnt/this._maxClickCnt;e>=1&&(e=1),this.jindu.value=e,e>=this._bannerVal&&this.nowshownum{this.banner.hide(),this._bannerVal=t.randRangefloat(.35,.75)})),e>=1&&(this._isComplete=!0,this.onBannerHide())}}Daojishi(){let e=this.jindu.value;(e-=this._decrement)<=0&&(e=0),this.jindu.value=e,this._clickCnt>2&&(this._clickCnt-=2)}onBannerHide(){kt.Instance._isComplete=!0,Mt.Instance.CloseView(mt.GoldEggView),dt.Instance.ShowBoxPanel(),D.OffShow(this.onBannerHide);var e=[{t:N.Instance.CurModel.ServerTime.toString()},{reward_item:"1000"},{reward_num:"200"}];T.Instance.HttpPostRequest(R.protocols.Fissionvd,e,e=>{Mt.Instance.ShowTips("金币:X200")},e=>{}),ht.Instance._bannerAd&&ht.Instance._bannerAd.hide()}}class Ct extends ot.GiftViewUI{constructor(){super(),this.shownum=3,this.nowshownum=0,this._isComplete=!1,this._bannerVal=.5,this._maxClickCnt=12,this._clickCnt=0,this._interval=500,this._decrement=.03,Ct.ins=this}static get Instance(){return null==Ct.ins?new Ct:Ct.ins}RefreshData(){}RegButton(){}Resize(){}RefreshUI(e){}OnShow(){this.HitBtn.clickHandler=Laya.Handler.create(this,this.QiaoDa,null,!1),this._bannerVal=t.randRangefloat(.35,.75),this.click.play(0,!0),this.jinduBar.value=0,Laya.timer.loop(this._interval,this,this.Daojishi),D.OnShow(this.onBannerHide),ht.Instance.showBanner(e=>{console.log("礼盒界面出现banner---"),console.log("banner加载完毕--",e),this.banner=e.banner,e.banner.hide()},()=>{}),this.height=Laya.stage.height,this.BG.height=Laya.stage.height,Laya.stage.on(Laya.Event.RESIZE,this,()=>{this.BG.height=Laya.stage.height,this.height=Laya.stage.height})}OnClose(){}QiaoDa(){if(this.click.stop(),this.shou.visible=!1,!this._isComplete){this._clickCnt++,this._clickCnt>this._maxClickCnt&&(this._clickCnt=this._maxClickCnt);let e=this._clickCnt/this._maxClickCnt;e>=1&&(e=1),this.jinduBar.value=e,e>=this._bannerVal&&this.nowshownum{this.banner.hide(),this._bannerVal=t.randRangefloat(.35,.75)})),e>=1&&(this._isComplete=!0,this.onBannerHide())}}Daojishi(){let e=this.jinduBar.value;(e-=this._decrement)<=0&&(e=0),this.jinduBar.value=e,this._clickCnt>2&&(this._clickCnt-=2)}onBannerHide(){Ct.Instance.banner&&Ct.Instance.banner.hide(),D.OffShow(this.onBannerHide),Mt.Instance.CloseView(mt.GiftView);var e=[{t:N.Instance.CurModel.ServerTime.toString()},{reward_item:"1000"},{reward_num:"200"}];T.Instance.HttpPostRequest(R.protocols.Fissionvd,e,e=>{Mt.Instance.ShowTips("金币:X200")},e=>{})}}!function(e){e[e.InGameView=0]="InGameView",e[e.ShadeView=1]="ShadeView",e[e.CompleteView=2]="CompleteView",e[e.LoadView=3]="LoadView",e[e.MainView=4]="MainView",e[e.SettingUi=5]="SettingUi",e[e.SKinShopView=6]="SKinShopView",e[e.TrialView=7]="TrialView",e[e.IntensifyView=8]="IntensifyView",e[e.AttributeUpView=9]="AttributeUpView",e[e.ExportView=10]="ExportView",e[e.ExitView=11]="ExitView",e[e.GoldEggView=12]="GoldEggView",e[e.GiftView=13]="GiftView"}(mt||(mt={}));class Mt{constructor(){this.viewDic=[],this.addViewDic=new i,this.showpushview=0,this._maskCnt=0,this.init()}static get Instance(){return this.instance||(this.instance=new Mt)}init(){this._maskCnt=0,this.viewDic[mt.InGameView]=gt,this.viewDic[mt.LoadView]=ct,this.viewDic[mt.MainView]=dt,this.viewDic[mt.IntensifyView]=ut,this.viewDic[mt.CompleteView]=pt,this.viewDic[mt.SKinShopView]=It,this.viewDic[mt.TrialView]=vt,this.viewDic[mt.ShadeView]=Lt,this.viewDic[mt.ExportView]=St,this.viewDic[mt.ExitView]=bt,this.viewDic[mt.AttributeUpView]=yt,this.viewDic[mt.GoldEggView]=kt,this.viewDic[mt.GiftView]=Ct,this.uiNode=new Laya.Sprite,this.popNode=new Laya.Sprite,Laya.stage.addChild(this.uiNode),Laya.stage.addChild(this.popNode),this.uiNode.zOrder=3,this.popNode.zOrder=4}OpenView(e,t){null!=this.curView&&(this.curView.OnClose(),this.uiNode.removeChild(this.curView),this.curView.destroy(!0),this.curView=null),this.curView=new this.viewDic[e],this.uiNode.addChild(this.curView),this.curView.OnShow(t)}get getCurView(){return this.curView}AddView(e,t){if(this.addViewDic.has(e))return;let i=new this.viewDic[e];this.addViewDic.set(e,i),this.uiNode.addChild(i),i.OnShow(t),le.Instance.CloseInput()}RemoveView(){null!=this.curView&&(this.curView.OnClose(),this.uiNode.removeChild(this.curView),this.curView.destroy(!0),this.curView=null)}HaveView(e){return this.addViewDic.has(e)}CloseView(e){if(!this.addViewDic.has(e))return;let t=this.addViewDic.get(e);t.OnClose(),this.uiNode.removeChild(t),t.destroy(!0),this.addViewDic.delete(e),le.Instance.OpenInput()}OpenMask(){if(this._maskCnt++,!(this._maskCnt>1)){if(null!=this.curMask)return this.curMask.OnClose(),this.popNode.removeChild(this.curView),this.curMask.destroy(),void(this.curMask=null);this.curMask=new this.viewDic[mt.ShadeView],this.curMask&&(console.log("打开遮罩"),this.popNode.addChild(this.curMask),this.curMask.OnShow())}}CloseMask(){this._maskCnt--,this._maskCnt>0||null!=this.curMask&&(this.curMask.OnClose(),this.popNode.removeChild(this.curMask),this.curMask.destroy(!0),console.log("关闭遮罩"),this.curMask=null)}ShowTips(e,t=1){var i=U.Instance.GetUi(G.WarnTips);if(i)if(1==t){i.y=0,i.text=e,i.x=Laya.stage.width>>1,this.popNode.addChild(i);let t=(Laya.stage.height>>1)-300;var a=Laya.Tween.to(i,{y:t},1e3,Laya.Ease.bounceOut,new Laya.Handler(this,()=>{a.clear(),U.Instance.RecoverUi(G.WarnTips,i)}))}else if(2==t){i.y=Laya.stage.height-400,i.text=e,i.x=Laya.stage.width>>1,this.popNode.addChild(i);a=Laya.Tween.to(i,{alpha:0},1e3,Laya.Ease.bounceOut,new Laya.Handler(this,()=>{a.clear(),U.Instance.RecoverUi(G.WarnTips,i),i.alpha=1}))}}ShowGuideView(){this.GuideView||(this.GuideView=new xt,this.popNode.addChild(this.GuideView)),this.GuideView.OnShow()}CloseGuideView(){this.GuideView&&(this.GuideView.OnClose(),this.GuideView.removeSelf(),this.GuideView.destroy())}}class _t{static InitSdk(){Laya.Browser.window.sdk.getFyhd().startSdk(),_t.UserInfoAuth(),Laya.LocalStorage.getItem("is_white")?_t.iswhite=!0:_t.getWhiteConfig(),Laya.LocalStorage.getItem("is_newuser")?_t.isnewuser=!1:(_t.isnewuser=!0,Laya.LocalStorage.setItem("is_newuser","1")),_t.PushData()}static UserInfoAuth(){Laya.Browser.onWeiXin&&Laya.Browser.window.sdk.getFyhd().getFyhdUserInfo(null,!1,e=>{console.log("无授权回调:"+JSON.stringify(e)),e.result.user&&(_t.openid=e.result.user.openid,_t.AuthInfo())})}static AuthInfo(){var e={openid:_t.openid};Laya.Browser.window.sdk.getFyhd().loginData(e,e=>{console.log("授权上报回调:"+JSON.stringify(e))})}static ValueUser(){var e={openid:_t.openid};Laya.Browser.window.sdk.getFyhd().valueuser(e,e=>{console.log("有效用户上报:"+JSON.stringify(e))})}static getWhiteConfig(){Laya.Browser.window.sdk.getFyhd().whiteConfig(function(e){_t.iswhite=e.data.is_white,_t.iswhite&&Laya.LocalStorage.setItem("is_white","1"),console.log("白名单---",e)})}static SetHuTuiList(e,t=1,i=""){let a=this.pushData;a&&0!=a.length&&(e.selectEnable=!1,1==t?e.vScrollBarSkin="":e.hScrollBarSkin="",e.renderHandler=Laya.Handler.create(this,this.updateItem,[i],!1),e.array=a,e.refresh())}static updateItem(e,t,i){t.getComponent(Bt).Refresh(e)}static ClickAd(e){if(console.log("上报类型---",e),Laya.Browser.onWeiXin){var t={ad_type:e,openid:_t.openid};console.log("点击参数:"+t),Laya.Browser.window.sdk.getFyhd().advertisement(t,e=>{console.log("点击结果:"+JSON.stringify(e))})}}static PushData(){if(Laya.Browser.onWeiXin){Laya.Browser.window.sdk.getFyhd().shareRecommend({},e=>{console.log("热门游戏数据--",e),e.data&&(_t.pushData=e.data,_t.pushData.sort(_t.ListSort),_t.isHaveDate=!0),console.log("获取互推信息:"+JSON.stringify(_t.pushData))})}}static ShowHuTuiJump(e){Laya.Browser.onWeiXin&&(2==e.jump_type?Laya.Browser.window.wx.previewImage({current:e.qrcode,urls:[e.qrcode]}):1==e.jump_type?Laya.Browser.window.wx.navigateToMiniProgram({appId:e.to_appid,path:e.jump_path,success(t){console.log("上报成功:"+JSON.stringify(t)),_t.PushClick(e.to_appid)},fail(e){Mt.Instance.AddView(mt.ExportView)}}):0==e.jump_type&&Laya.Browser.window.wx.navigateToMiniProgram({appId:e.platform_appid,path:e.jump_path,success(t){console.log("上报成功:"+JSON.stringify(t)),_t.PushClick(e.to_appid)},fail(e){}}))}static PushClick(e){if(Laya.Browser.onWeiXin){var t={openid:_t.openid,to_appid:e};Laya.Browser.window.sdk.getFyhd().sharePlay(t,e=>{console.log("点击上报结果:"+JSON.stringify(e))})}}static ListSort(e,t){return Number(e.panel)Number(t.panel)?1:void 0}}_t.Ad_ClickType={Video:"video_click",Watch:"watch",Share:"share",Banner:"banner",Push:"push",PushClick:"icon_click"},_t.pushData=[],_t.isHaveDate=!1,_t.ShowAd="ShowAd";class Bt extends Laya.Script{constructor(){super()}onAwake(){this.self=this.owner,this.icon=this.self.getChildByName("icon"),this.btn=this.self.getChildByName("btn"),this.name=this.self.getChildByName("name"),this._tip=this.self.getChildByName("tip"),this.bottom=this.self.getChildByName("bottom"),this.remen=this.self.getChildByName("remen"),this.star=this.self.getChildByName("star"),this.diandian=this.icon.getChildAt(0),this.btn.clickHandler=new Laya.Handler(this,this.clickAd)}Refresh(e){if(this.data=this.self.dataSource,this.type=e,this.name&&(this.name.text=this.data.togame_name),this._tip){this._tip.visible=!0;let e=t.randomInt(1,2e5).toString()+"人在玩";this._tip.text=e}if(this.diandian&&(this.diandian.visible=!1),this.bottom){let e=t.randomInt(1,6);this.bottom.skin="subpackage/bottom/icontitle"+e+".png"}this.remen&&(this.remen.visible=Math.random()<.2),this.star&&(this.star.visible=Math.random()<.2),this.icon.skin=this.data.icon}clickAd(){_t.ClickAd(_t.Ad_ClickType.PushClick),_t.ShowHuTuiJump(this.data)}onDestroy(){this.btn.clickHandler=null}}class Rt{constructor(){}static init(){var t=Laya.ClassUtils.regClass;t("View/Com/ButtonRunTime.ts",e),t("View/Com/ListItem.ts",Bt)}}Rt.width=720,Rt.height=1280,Rt.scaleMode="fixedwidth",Rt.screenMode="vertical",Rt.alignV="middle",Rt.alignH="center",Rt.startScene="MainView.scene",Rt.sceneRoot="",Rt.debug=!1,Rt.stat=!1,Rt.physicsDebug=!1,Rt.exportSceneToJson=!0,Rt.init();new class{constructor(){window.Config3D&&(window.Config3D._config._defaultPhysicsMemory=128),window.Config3D&&(window.Config3D._config.isAntialias=!0),window.Laya3D?Laya3D.init(Rt.width,Rt.height):Laya.init(Rt.width,Rt.height,Laya.WebGL),Laya.Physics&&Laya.Physics.enable(),Laya.DebugPanel&&Laya.DebugPanel.enable(),Laya.stage.scaleMode=Rt.scaleMode,Laya.stage.screenMode=Rt.screenMode,Laya.stage.alignV=Rt.alignV,Laya.stage.alignH=Rt.alignH,Laya.URL.exportSceneToJson=Rt.exportSceneToJson,(Rt.debug||"true"==Laya.Utils.getQueryString("debug"))&&Laya.enableDebugPanel(),Rt.physicsDebug&&Laya.PhysicsDebugDraw&&Laya.PhysicsDebugDraw.enable(),Rt.stat&&Laya.Stat.show(),Laya.alertGlobalError=!0,s.isWx=Laya.Browser.onWeiXin,s.isWx&&D.init(),Laya.ResourceVersion.enable("version.json",Laya.Handler.create(this,this.onVersionLoaded),Laya.ResourceVersion.FILENAME_VERSION),D.IsNeedUpdate()}onVersionLoaded(){Laya.AtlasInfoManager.enable("fileconfig.json",Laya.Handler.create(this,this.onConfigLoaded)),Laya.MouseManager.multiTouchEnabled=!1}onConfigLoaded(){Mt.Instance.OpenView(mt.LoadView),s.isX=Laya.Browser.clientHeight/Laya.Browser.clientWidth>2}}}();