bundle.js 300 KB

1
  1. var __extends=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)t.hasOwnProperty(a)&&(e[a]=t[a])};return function(t,a){function __(){this.constructor=t}e(t,a),t.prototype=null===a?Object.create(a):(__.prototype=a.prototype,new __)}}();!function(){return function r(e,t,a){function o(i,s){if(!t[i]){if(!e[i]){var l="function"==typeof require&&require;if(!s&&l)return l(i,!0);if(n)return n(i,!0);var c=new Error("Cannot find module '"+i+"'");throw c.code="MODULE_NOT_FOUND",c}var h=t[i]={exports:{}};e[i][0].call(h.exports,function(t){return o(e[i][1][t]||t)},h,h.exports,r,e,t,a)}return t[i].exports}for(var n="function"==typeof require&&require,i=0;i<a.length;i++)o(a[i]);return o}}()({1:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../PrefabControl/PanelResDic"),i=e("../utils/DispatcherManager"),o=e("../utils/Singleton"),r=e("../WXSDK/ServerSocket"),s=e("../Data/RoleData"),l=function(e){function AgencyBaseControl(){var t=e.call(this)||this;return t._objectPool=n.PanelResDic.Instance,t.initSelf(),t}return __extends(AgencyBaseControl,e),AgencyBaseControl.prototype.initSelf=function(){},AgencyBaseControl.prototype.drawSomething=function(){this.sp=new Laya.Sprite,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"})},AgencyBaseControl.prototype.DisOn=function(e,t,a){i.DispatcherManager.addEventListener(e,t,a)},AgencyBaseControl.prototype.DisTrigger=function(e,t){void 0===t&&(t=null),i.DispatcherManager.dispatchEvent(e,t)},AgencyBaseControl.prototype.DisOff=function(e,t,a){i.DispatcherManager.removeEventListener(e,t,a)},AgencyBaseControl.prototype.setup=function(){for(var e,t=new Laya.Sprite,a=0;a<1e3;a++)(e=new Laya.Text).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)},AgencyBaseControl.prototype.getSingleTon=function(e){return this._objectPool.getSingleTon(e)},AgencyBaseControl.prototype.sendMessage=function(e,t,a){void 0===t&&(t=null),void 0===a&&(a=!0),r.ServerSocket.Instance.sendMessage(e,t,a)},Object.defineProperty(AgencyBaseControl.prototype,"RoleData",{get:function(){return this.roleData||(this.roleData=s.RoleData.Instance),this.roleData},enumerable:!0,configurable:!0}),AgencyBaseControl}(o.Singleton);a.AgencyBaseControl=l},{"../Data/RoleData":33,"../PrefabControl/PanelResDic":48,"../WXSDK/ServerSocket":78,"../utils/DispatcherManager":85,"../utils/Singleton":91}],2:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./AgencyBaseControl"),i=e("../utils/GameState"),o=e("../View/ViewManager"),r=e("../View/CompletePanel"),s=e("../Control/GameStateControl"),l=e("../utils/GameUtils"),c=e("../Control/SceneControl"),h=e("../PrefabControl/PropManager"),u=e("../WXSDK/PlayerAccount"),p=e("../WXSDK/Sdk"),d=e("./AgencyTrial"),m=e("../View/GiftView"),f=e("../WXSDK/RecordManager"),g=e("../View/MainPanel"),y=function(e){function AgencyInGame(){return e.call(this)||this}return __extends(AgencyInGame,e),AgencyInGame.prototype.initSelf=function(){this.DisOn(i.GameState.end,this,this.endgameHandler),this.DisOn(i.GameState.revive,this,this.RevivegameHandler),this.DisOn(i.GameState.lose,this,this.LosegameHandler)},AgencyInGame.prototype.RevivegameHandler=function(){Laya.timer.once(1e3,this,this.reviveView)},AgencyInGame.prototype.LosegameHandler=function(){Laya.timer.once(1e3,this,this.loseView)},AgencyInGame.prototype.reviveView=function(){f.RecordManager.Instance.RecordStop();s.GameStateControl.Instance.nowMingCi;p.WxApi.recordAldEvent("打开结算界面(复活)"),o.ViewManager.Instance.add(r.CompletePanel,0)},AgencyInGame.prototype.loseView=function(){f.RecordManager.Instance.RecordStop();s.GameStateControl.Instance.nowMingCi;p.WxApi.recordAldEvent("打开结算界面(失败)"),this.RecropLevelEnd(!1),o.ViewManager.Instance.add(r.CompletePanel,0)},AgencyInGame.prototype.endgameHandler=function(){f.RecordManager.Instance.RecordStop(),Laya.timer.once(1e3,this,this.startEndView)},AgencyInGame.prototype.startEndView=function(){s.GameStateControl.Instance.nowMingCi;var e=0;if(0==s.GameStateControl.Instance.endGamePlayerArr.length)e=this.RoleData.levelcfg.winGold,p.WxApi.recordAldEvent("打开结算界面(游戏胜利)"),this.RecropLevelEnd(!0);else{var t=l.GameUtils.cutstrtoArr(this.RoleData.levelcfg.failGod);e=l.GameUtils.randRangeint(Number(t[0]),Number(t[1])),p.WxApi.recordAldEvent("打开结算界面(游戏失败)"),this.RecropLevelEnd(!1)}o.ViewManager.Instance.add(r.CompletePanel,e)},AgencyInGame.prototype.RecropLevelEnd=function(e){},AgencyInGame.prototype.returnmainview=function(e){if(e&&u.PlayerAccount.CurrentAccount.CurAccountData.WhiteUser){var t=Math.random();console.log("误触几率为---",t),t<=u.PlayerAccount.CurrentAccount.CurAccountData.EndCheat&&o.ViewManager.Instance.add(m.default),i.GameState.fuhuocishu=1,i.GameState.recordscree=!1,i.GameState.isdie=!1,h.PropManager.Instance.CloseGameOverEffect(),o.ViewManager.Instance.close(r.CompletePanel),this.DisTrigger(i.GameState.returnMainView),c.SceneControl.Instance.ShowTheGameScene(),(a=this.getSingleTon(d.AgencyTrial)).isshiyonging&&(c.SceneControl.Instance.CreatePlayer(this.RoleData.roleCfg),a.isshiyonging=!1)}else{var a;i.GameState.fuhuocishu=1,i.GameState.recordscree=!1,i.GameState.isdie=!1,h.PropManager.Instance.CloseGameOverEffect(),o.ViewManager.Instance.close(r.CompletePanel),this.DisTrigger(i.GameState.returnMainView),c.SceneControl.Instance.ShowTheGameScene(),(a=this.getSingleTon(d.AgencyTrial)).isshiyonging&&(c.SceneControl.Instance.CreatePlayer(this.RoleData.roleCfg),a.isshiyonging=!1)}i.GameState.GameNum%3==0&&g.MainPanel.instance.skinclick()},AgencyInGame.prototype.startGame=function(){AgencyInGame.gamenum++;var e=this.RoleData.getNowServerLevel().toString().toString(),t="第"+e+"关",a=u.PlayerAccount.CurrentAccount.CurAccountData.UseId;p.WxApi.levelStart(e,t,a),s.GameStateControl.Instance.startGame()},AgencyInGame.key="AgencyInGame",AgencyInGame.gamenum=0,AgencyInGame}(n.AgencyBaseControl);a.AgencyInGame=y},{"../Control/GameStateControl":21,"../Control/SceneControl":29,"../PrefabControl/PropManager":49,"../View/CompletePanel":61,"../View/GiftView":63,"../View/MainPanel":67,"../View/ViewManager":70,"../WXSDK/PlayerAccount":75,"../WXSDK/RecordManager":76,"../WXSDK/Sdk":77,"../utils/GameState":86,"../utils/GameUtils":87,"./AgencyBaseControl":1,"./AgencyTrial":7}],3:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../View/ViewManager"),i=e("../View/LoadingPanel"),o=e("./AgencyUserMessage"),r=e("../WXSDK/WECHATEVENT"),s=e("./AgencyBaseControl"),l=e("./AgencyMain"),c=e("../CFG/RoleCFG"),h=e("../CFG/LevelCFG"),u=e("../CFG/BuildCFG"),p=e("../CFG/NpcCFG"),d=e("../CFG/GameCFG"),m=e("./AgencySkin"),f=e("../WXSDK/Sdk"),g=e("../WXSDK/PlayerAccount"),y=e("../WXSDK/NetworkManager"),C=e("../Global"),_=e("../CFG/LotteryCFG"),v=e("./AgencyLottery"),w=e("../WXSDK/ttad"),S=function(e){function AgencyLogin(){return e.call(this)||this}return __extends(AgencyLogin,e),AgencyLogin.prototype.initSelf=function(){this.DisOn(r.WECHATEVENT.WECHATEVENT_loginSucceed,this,this.Success)},AgencyLogin.prototype.Login=function(){n.ViewManager.Instance.add(i.LoadingPanel),this.loginprogress(0),this.LoginLocal()},AgencyLogin.prototype.LoginWX=function(){var e=this;f.WxApi.recordAldEvent("开始微信登录"),f.WxApi.WXLogin(function(t){"error"!=t?(f.WxApi.recordAldEvent("微信登录成功"),console.log("hplogin:querychannel->"+f.WxApi.querychannel+" referrerInfoappId->"+f.WxApi.referrerInfoappId),e.LoginLocal()):(f.WxApi.recordAldEvent("微信登录失败"),e.LoginWX())})},AgencyLogin.prototype.LoginLocal=function(e){void 0===e&&(e=null),f.WxApi.recordAldEvent("开始本地登录"),e&&new g.PlayerAccount(e.code,"","",0,"","","","",f.WxApi.shareOpenId,f.WxApi.shareOpenId,C.Global.gameVersion),y.NetworkManager.Instance.login(null,Laya.Handler.create(this,this.LoginComplete),null)},AgencyLogin.prototype.LoginComplete=function(){f.WxApi.recordAldEvent("本地服务器登录完成..."),f.WxApi.aldSendOpenid(g.PlayerAccount.CurrentAccount.CurAccountData.openid),this.Success()},AgencyLogin.prototype.loginprogress=function(e){var t=n.ViewManager.Instance.getView(i.LoadingPanel);t&&t.showWord(e)},AgencyLogin.prototype.Success=function(){this.ResolveData(),this.initData(),this.StartMain(),w.ttad.InitAD()},AgencyLogin.prototype.StartMain=function(){console.log("当前配置表总关卡:",h.default.vec.length),this.getSingleTon(l.AgencyMain).StartMain()},AgencyLogin.prototype.ResolveData=function(){var e=g.PlayerAccount.CurrentAccount.nowConfig.gameConfig[0].config;if(e&&""!=e){var t,a=e.split("%file%"),n=a.length;for(t=0;t<n;t++){var i=a[t].split("%cfg%"),o=AgencyLogin.configClass[i[0]];o&&o.initCfg(i[1])}return!0}return!1},AgencyLogin.prototype.initData=function(){this.getSingleTon(o.AgencyUserMessage).init(),this.getSingleTon(m.AgencySkin).init(),this.getSingleTon(v.AgencyLottery).init()},AgencyLogin.key="AgencyLogin",AgencyLogin.configClass={RoleCFG:c.default,LevelCFG:h.default,BuildCFG:u.default,NpcCFG:p.default,GameCFG:d.default,LotteryCFG:_.default},AgencyLogin}(s.AgencyBaseControl);a.AgencyLogin=S},{"../CFG/BuildCFG":9,"../CFG/GameCFG":10,"../CFG/LevelCFG":11,"../CFG/LotteryCFG":12,"../CFG/NpcCFG":13,"../CFG/RoleCFG":14,"../Global":41,"../View/LoadingPanel":65,"../View/ViewManager":70,"../WXSDK/NetworkManager":73,"../WXSDK/PlayerAccount":75,"../WXSDK/Sdk":77,"../WXSDK/WECHATEVENT":80,"../WXSDK/ttad":83,"./AgencyBaseControl":1,"./AgencyLottery":4,"./AgencyMain":5,"./AgencySkin":6,"./AgencyUserMessage":8}],4:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./AgencyBaseControl"),i=e("../View/ViewManager"),o=e("../View/LotteryPanel"),r=e("../CFG/LotteryCFG"),s=e("../utils/GameUtils"),l=e("../utils/GlobalTip"),c=e("../CFG/RoleCFG"),h=e("./AgencySkin"),u=function(e){function AgencyLottery(){var t=e.call(this)||this;return t.mStartX=400,t.mStartY=500,t.mActionIndex=0,t.mCurrIndex=0,t.mCurrSkinIndex=0,t}return __extends(AgencyLottery,e),AgencyLottery.prototype.init=function(){},AgencyLottery.prototype.openView=function(){i.ViewManager.Instance.add(o.LotteryPanel)},AgencyLottery.prototype.createAnimation=function(){var e=new Laya.Animation;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)},AgencyLottery.prototype.getreward=function(e){if(e)switch(e.type){case 1:this.RoleData.Money+=Number(e.value),l.GlobalTip.Instance.showWordTips("恭喜获得"+e.value+"金币!");break;case 2:var t=c.default.dict[e.value];this.getSingleTon(h.AgencySkin).setRoleState(t,1),l.GlobalTip.Instance.showWordTips("恭喜获得角色"+t.rolename)}},AgencyLottery.prototype.GetReward=function(){var e=0,t=r.default.vec,a=0,n=0;for(n=0;n<t.length;n++)a+=t[n].weight;var i=s.GameUtils.randRangeint(1,a),o=0;for(n=0;n<t.length;n++)if((o+=t[n].weight)>=i){e=n;break}return e},AgencyLottery.prototype.startFun=function(){this.mAniPath="res/spine/spineRes1/dragon.sk"},AgencyLottery.prototype.onError=function(){console.log("error")},AgencyLottery.prototype.parseComplete=function(){this.mArmature=this.mFactory.buildArmature(1),this.mArmature.x=this.mStartX,this.mArmature.y=this.mStartY,this.mArmature.scale(.5,.5),Laya.stage.addChild(this.mArmature),this.play()},AgencyLottery.prototype.completeHandler=function(){this.play()},AgencyLottery.prototype.play=function(){this.mCurrIndex++,this.mCurrIndex>=this.mArmature.getAnimNum()&&(this.mCurrIndex=0),this.mArmature.play(this.mCurrIndex,!1)},AgencyLottery.key="AgencyLottery",AgencyLottery}(n.AgencyBaseControl);a.AgencyLottery=u},{"../CFG/LotteryCFG":12,"../CFG/RoleCFG":14,"../View/LotteryPanel":66,"../View/ViewManager":70,"../utils/GameUtils":87,"../utils/GlobalTip":88,"./AgencyBaseControl":1,"./AgencySkin":6}],5:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./AgencyBaseControl"),i=e("../Control/ResourceControl"),o=e("../View/LoadingPanel"),r=e("../View/ViewManager"),s=e("../Control/ResDataControl"),l=e("../View/MainPanel"),c=e("../Control/SceneControl"),h=e("../Config/AssetPath"),u=e("../Control/GameStateControl"),p=e("../WXSDK/WXGamePlatform"),d=e("../CFG/NpcCFG"),m=e("../WXSDK/PlayerAccount"),f=e("../PrefabControl/PropManager"),g=e("../WXSDK/FYHD_Sdk"),y=e("../View/GiftView"),C=e("../Control/AssetManager"),_=function(e){function AgencyMain(){var t=e.call(this)||this;return t._loadjd=0,t._alljd=0,t}return __extends(AgencyMain,e),AgencyMain.prototype.initSelf=function(){},AgencyMain.prototype.StartMain=function(){this._loadjd=0,this._alljd=20,p.WXGamePlatform.Instance.loadSubpackage("subpackage",this,this.sub1complete,this.loadprogress,null)},AgencyMain.prototype.sub1complete=function(){this._loadjd=20,this._alljd=30,p.WXGamePlatform.Instance.loadSubpackage("subpackage1",this,this.SubpackageOver,this.loadprogress,null)},AgencyMain.prototype.onComplete=function(){var e=this.scene.addChild(Laya.Loader.getRes("res/threeDimen/skinModel/dude/dude.lh")),t=new Laya.Vector3(.1,.1,.1);e.transform.localScale=t,e.transform.rotate(new Laya.Vector3(0,3.14,0))},AgencyMain.prototype.SubpackageOver=function(){var e=this;C.AssetManager.LoadAssetFun(function(){e._loadjd=50,e._alljd=40;var t=[],a=[];a.push(h.AssetPath.get3DModel("startpanel")),a.push(h.AssetPath.get3DModel("endpanel")),a.push(h.AssetPath.get3DModel("speedupeffect")),a.push(h.AssetPath.get3DModel("color_white")),a.push(h.AssetPath.get3DModel("color_yellow")),a.push(h.AssetPath.get3DModel("winline")),a.push(h.AssetPath.get3DModel("fireworks")),a.push(h.AssetPath.get3DModel("DirectionalLight")),a.push(h.AssetPath.get3DRoleModel(e.RoleData.roleCfg.name)),a.push(h.AssetPath.get3DRoleModel("Arrow"));var n=e.RoleData.levelmapArr,o=0;for(o=0;o<n.length;o++)-1==a.indexOf(h.AssetPath.get3DModel(n[o]))&&a.push(h.AssetPath.get3DModel(n[o]));var r=e.RoleData.levelcfg.npc;for(o=0;o<r.length;o++)-1==a.indexOf(h.AssetPath.get3DRoleModel(d.default.dict[r[o].id].name))&&a.push(h.AssetPath.get3DRoleModel(d.default.dict[r[o].id].name));for(o=0;o<a.length;o++)t.push({url:a[o]});i.ResourceControl.Instance.loader3DArr(t,e,e.load3Dcomplete,e.loadprogress)})},AgencyMain.prototype.load3Dcomplete=function(){this._loadjd=90,this._alljd=10,i.ResourceControl.Instance.loadGroup("main",this,this.loadcomplete,this.loadprogress,!1)},AgencyMain.prototype.loadprogress=function(e){var t=r.ViewManager.Instance.getView(o.LoadingPanel);t&&(e=this._loadjd+Math.ceil(e/100*this._alljd),t.showWord(e))},AgencyMain.prototype.loadcomplete=function(){fairygui.UIConfig.buttonSound="ui://lecxynh2iz9y26",u.GameStateControl.Instance.init(),s.ResDataControl.Instance.AddViewPackByName("main"),r.ViewManager.Instance.close(o.LoadingPanel),r.ViewManager.Instance.add(l.MainPanel),console.log("新用户FYHD_Sdk.isnewuser---",g.FYHD_Sdk.isnewuser);Laya.LocalStorage.getItem("is_newuser");g.FYHD_Sdk.isnewuser?Laya.timer.once(500,this,function(){m.PlayerAccount.CurrentAccount.CurAccountData.WhiteUser&&r.ViewManager.Instance.add(y.default)}):Laya.LocalStorage.setItem("is_newuser","1"),c.SceneControl.Instance.SetScene(),f.PropManager.Instance.InitEffect()},AgencyMain.key="AgencyMain",AgencyMain}(n.AgencyBaseControl);a.AgencyMain=_},{"../CFG/NpcCFG":13,"../Config/AssetPath":15,"../Control/AssetManager":17,"../Control/GameStateControl":21,"../Control/ResDataControl":27,"../Control/ResourceControl":28,"../Control/SceneControl":29,"../PrefabControl/PropManager":49,"../View/GiftView":63,"../View/LoadingPanel":65,"../View/MainPanel":67,"../View/ViewManager":70,"../WXSDK/FYHD_Sdk":71,"../WXSDK/PlayerAccount":75,"../WXSDK/WXGamePlatform":81,"./AgencyBaseControl":1}],6:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./AgencyBaseControl"),i=e("../Control/LocalDataControl"),o=e("../Data/UserDataInfo"),r=e("../Data/SkinData"),s=e("../CFG/RoleCFG"),l=e("../View/ViewManager"),c=e("../View/SkinPanel"),h=e("../utils/GlobalTip"),u=e("../utils/GameState"),p=function(e){function AgencySkin(){var t=e.call(this)||this;return AgencySkin.instance=t,t}return __extends(AgencySkin,e),AgencySkin.prototype.initSelf=function(){},AgencySkin.prototype.init=function(){var e;this.localdata=i.LocalDataControl.Instance.GetLocalCaCheData(o.UserDataInfo.skin),this.localdata.hasOwnProperty("pifu")||(this.localdata.pifu={}),e=this.localdata.pifu,this.pifuArr=[],this.pifuDict={};var t=0,a=s.default.vec.length;for(t=0;t<a;t++){var n=new r.SkinData,l=s.default.vec[t];n.roleCFG=l;var c=e[l.id];c?(n.state=Number(c.state),n.hasnum=Number(c.hasnum)):(n.state=0,n.hasnum=0),0==l.getState&&(n.state=1),this.pifuArr.push(n),this.pifuDict[n.roleCFG.id]=n}},AgencySkin.prototype.openview=function(){l.ViewManager.Instance.add(c.SkinPanel)},AgencySkin.prototype.setRoleState=function(e,t){var a=this.pifuDict[e.id];a&&(a.state=1,this.AddLocalSkinData(a.roleCFG.id,a.state,a.hasnum))},AgencySkin.prototype.AddLocalSkinData=function(e,t,a){this.localdata.pifu[e]={},this.localdata.pifu[e].state=t,this.localdata.pifu[e].hasnum=a,i.LocalDataControl.Instance.AddData(o.UserDataInfo.skin,this.localdata)},AgencySkin.prototype.createCantralRect=function(){this.rect=new Laya.Sprite,this.rect.graphics.drawRect(-100,-100,200,200,"gray"),Laya.stage.addChild(this.rect),this.updateRectPos()},AgencySkin.prototype.updateRectPos=function(){this.rect.x=Laya.stage.width/2,this.rect.y=Laya.stage.height/2},AgencySkin.prototype.GainPifu=function(e){if(1==e.state)this.RoleData.CharacterID=e.roleCFG.id,this.DisTrigger(u.GameState.updateSKinView);else switch(e.roleCFG.getState){case 1:e.hasnum++,e.roleCFG.need<=e.hasnum&&(e.state=1),this.AddLocalSkinData(e.roleCFG.id,e.state,e.hasnum),this.DisTrigger(u.GameState.updateSKinView);break;case 2:this.RoleData.Money>=e.roleCFG.need?(this.RoleData.Money-=e.roleCFG.need,e.state=1,this.AddLocalSkinData(e.roleCFG.id,e.state,e.hasnum),this.DisTrigger(u.GameState.updateSKinView),h.GlobalTip.Instance.showWordTips("购买成功")):h.GlobalTip.Instance.showWordTips("金币不足")}},AgencySkin.prototype.GainNoHaveSkin=function(){var e=[];for(var t in this.pifuDict)0==this.pifuDict[t].state&&e.push(this.pifuDict[t]);return e},AgencySkin.key="AgencySkin",AgencySkin}(n.AgencyBaseControl);a.AgencySkin=p},{"../CFG/RoleCFG":14,"../Control/LocalDataControl":23,"../Data/SkinData":34,"../Data/UserDataInfo":35,"../View/SkinPanel":68,"../View/ViewManager":70,"../utils/GameState":86,"../utils/GlobalTip":88,"./AgencyBaseControl":1}],7:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./AgencyBaseControl"),i=e("../View/ViewManager"),o=e("../View/TrialPanel"),r=e("../Control/GameStateControl"),s=e("../Config/AssetPath"),l=e("../Control/ResourceControl"),c=e("../Control/SceneControl"),h=e("./AgencyInGame"),u=e("../View/EggPanel"),p=e("../WXSDK/PlayerAccount"),d=function(e){function AgencyTrial(){var t=e.call(this)||this;return t.isshiyonging=!1,t}return __extends(AgencyTrial,e),AgencyTrial.prototype.openview=function(e){i.ViewManager.Instance.add(o.TrialPanel,e)},AgencyTrial.prototype.ExitPanel=function(e){if(this.isshiyonging=!!e,this._selectvo=e,e){var t=[];t.push({url:s.AssetPath.get3DRoleModel(e.roleCFG.name)}),l.ResourceControl.Instance.loader3DArr(t,this,this.SceneCreateComplete,null,!0)}else{var a=Math.random();p.PlayerAccount.CurrentAccount.CurAccountData.WhiteUser&&a<=p.PlayerAccount.CurrentAccount.CurAccountData.HitEgg?i.ViewManager.Instance.add(u.default):r.GameStateControl.Instance.entergame()}i.ViewManager.Instance.close(o.TrialPanel)},AgencyTrial.prototype.createSprite=function(){this.sprit=new Laya.Sprite,this.sprit.graphics.drawRect(0,0,200,200,"#D2691E"),this.sprit.pivot(100,100),this.sprit.x=Laya.stage.width/2,this.sprit.y=Laya.stage.height/2,this.sprit.size(200,200),Laya.stage.addChild(this.sprit)},AgencyTrial.prototype.onSpriteClick=function(e){Math.random()},AgencyTrial.prototype.onRotate=function(e){},AgencyTrial.prototype.SceneCreateComplete=function(){c.SceneControl.Instance.CreatePlayer(this._selectvo.roleCFG),h.AgencyInGame.gamenum>1&&p.PlayerAccount.CurrentAccount.CurAccountData.WhiteUser?i.ViewManager.Instance.add(u.default):r.GameStateControl.Instance.entergame()},AgencyTrial.prototype.createText=function(){var e=new Laya.Text;e.text="Layabox是性能最强的HTML5引擎技术提供商与优秀的游戏发行商,面向Flash开发者提供HTML5开发技术方案!",e.width=400,e.wordWrap=!0,e.align="center",e.fontSize=40,e.font="Microsoft YaHei",e.color="#ff0000",e.bold=!0,e.leading=5,e.stroke=2,e.strokeColor="#ffffff",e.borderColor="#00ff00",e.x=(Laya.stage.width-e.textWidth)/2,e.y=(Laya.stage.height-e.textHeight)/2,Laya.stage.addChild(e)},AgencyTrial.prototype.createInput=function(){var e=new Laya.Input;e.prompt="Type some word...",e.multiline=!0,e.wordWrap=!0,e.size(350,100),e.x=Laya.stage.width-e.width>>1,e.y=Laya.stage.height-e.height>>1,e.padding=[2,2,2,2],e.bgColor="#666666",e.color="#ffffff",e.fontSize=20,Laya.stage.addChild(e)},AgencyTrial.key="AgencyTrial",AgencyTrial}(n.AgencyBaseControl);a.AgencyTrial=d},{"../Config/AssetPath":15,"../Control/GameStateControl":21,"../Control/ResourceControl":28,"../Control/SceneControl":29,"../View/EggPanel":62,"../View/TrialPanel":69,"../View/ViewManager":70,"../WXSDK/PlayerAccount":75,"./AgencyBaseControl":1,"./AgencyInGame":2}],8:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(e){function AgencyUserMessage(){var t=e.call(this)||this;return t.roleisinit=!1,t}return __extends(AgencyUserMessage,e),AgencyUserMessage.prototype.initSelf=function(){},AgencyUserMessage.prototype.GoldUp=function(e){this.RoleData.Money+=e},AgencyUserMessage.prototype.createInput=function(){var e=new Laya.Input;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)},AgencyUserMessage.prototype.init=function(){this.RoleData.init(),this.roleisinit=!0},AgencyUserMessage.prototype.createText=function(){var e=new Laya.Text;return e.text="Layabox是HTML5引擎技术提供商与优秀的游戏发行商,面向AS/JS/TS开发者提供HTML5开发技术方案!\nLayabox是HTML5引擎技术提供商与优秀的游戏发行商,面向AS/JS/TS开发者提供HTML5开发技术方案!\nLayabox是HTML5引擎技术提供商与优秀的游戏发行商,面向AS/JS/TS开发者提供HTML5开发技术方案!",e.borderColor="#FFFF00",e.size(300,50),e.fontSize=20,e.color="#ffffff",Laya.stage.addChild(e),e},AgencyUserMessage.prototype.LevelUp=function(){this.RoleData.LevelUp()},AgencyUserMessage.key="AgencyUserMessage",AgencyUserMessage}(e("./AgencyBaseControl").AgencyBaseControl);a.AgencyUserMessage=n},{"./AgencyBaseControl":1}],9:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function BuildCFG(){}return BuildCFG.initCfg=function(e){var t=0,a=e.split("\n");t=0;for(t=0;t<a.length;t++){var n=a[t].split("&");if(!BuildCFG.dict[n[0]]){var i=new BuildCFG;i.name=n[0],i.buffx=Number(n[1]),i.buffy=Number(n[2]),i.buffz=Number(n[3]),i.time=Number(n[4]),BuildCFG.dict[i.name]=i,BuildCFG.vec.push(i)}}},BuildCFG.dict={},BuildCFG.vec=[],BuildCFG}();a.default=n},{}],10:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function GameCFG(){}return GameCFG.initCfg=function(e){var t=0,a=e.split("\n");t=0;for(t=0;t<a.length;t++){var n=a[t].split("&");if(!GameCFG.dict[n[0]]){var i=new GameCFG;i.id=Number(n[0]),i.value=n[1],GameCFG.dict[i.id]=i,GameCFG.vec.push(i)}}},GameCFG.dict={},GameCFG.vec=[],GameCFG}();a.default=n},{}],11:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function LevelCFG(){}return LevelCFG.initCfg=function(e){var t=0,a=e.split("\n");t=0;for(t=0;t<a.length;t++){var n=a[t].split("&");if(!LevelCFG.dict[n[0]]){var i=new LevelCFG;i.id=Number(n[0]),i.road=n[1],i.roleinitpos=JSON.parse(n[2]),i.npc=JSON.parse(n[3]),i.firstScenepos=n[4],i.winGold=Number(n[5]),i.failGod=n[6],LevelCFG.dict[i.id]=i,LevelCFG.vec.push(i)}}},LevelCFG.dict={},LevelCFG.vec=[],LevelCFG}();a.default=n},{}],12:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function LotteryCFG(){}return LotteryCFG.initCfg=function(e){var t=0,a=e.split("\n");t=0;for(t=0;t<a.length;t++){var n=a[t].split("&");if(!LotteryCFG.dict[n[0]]){var i=new LotteryCFG;i.id=Number(n[0]),i.type=Number(n[1]),i.value=n[2],i.weight=Number(n[3]),LotteryCFG.dict[i.id]=i,LotteryCFG.vec.push(i)}}},LotteryCFG.dict={},LotteryCFG.vec=[],LotteryCFG}();a.default=n},{}],13:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function NpcCFG(){}return NpcCFG.initCfg=function(e){var t=0,a=e.split("\n");t=0;for(t=0;t<a.length;t++){var n=a[t].split("&");if(!NpcCFG.dict[n[0]]){var i=new NpcCFG;i.id=Number(n[0]),i.name=n[1],i.speed=Number(n[2]),i.frontjump=JSON.parse(n[3]),i.leftjump=JSON.parse(n[4]),i.rightjump=JSON.parse(n[5]),i.upclimb=Number(n[6]),i.slideclimb=JSON.parse(n[7]),i.jump_left=Number(n[8]),i.jump_right=Number(n[9]),i.start_ahead=Number(n[10]),i.distance=Number(n[11]),i.gravity=Number(n[12]),NpcCFG.dict[i.id]=i,NpcCFG.vec.push(i)}}},NpcCFG.dict={},NpcCFG.vec=[],NpcCFG}();a.default=n},{}],14:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function RoleCFG(){}return RoleCFG.initCfg=function(e){var t=0,a=e.split("\n");t=0;for(t=0;t<a.length;t++){var n=a[t].split("&");if(!RoleCFG.dict[n[0]]){var i=new RoleCFG;i.id=Number(n[0]),i.name=n[1],i.speed=Number(n[2]),i.frontjump=JSON.parse(n[3]),i.leftjump=JSON.parse(n[4]),i.rightjump=JSON.parse(n[5]),i.upclimb=Number(n[6]),i.slideclimb=JSON.parse(n[7]),i.getState=Number(n[8]),i.need=Number(n[9]),i.icon=n[10],i.gravity=Number(n[11]),i.rolename=n[12],RoleCFG.dict[i.id]=i,RoleCFG.vec.push(i)}}},RoleCFG.dict={},RoleCFG.vec=[],RoleCFG}();a.default=n},{}],15:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Global"),i=function(){function AssetPath(){}return AssetPath.init=function(){AssetPath.versionrandom="?v="+Math.random()},AssetPath.getsound=function(e){return n.Global.getUrl(AssetPath.resources+AssetPath.music+e+".mp3")},AssetPath.getResConfig=function(){return n.Global.getUrl(AssetPath.resources+"resConfig.json")},AssetPath.getConfig=function(e){return n.Global.getUrl(AssetPath.resources+e+".bin")},AssetPath.get3Dscene=function(e){return n.Global.getUrl(AssetPath.res+AssetPath.prop+"Conventional/"+e+".ls")},AssetPath.get3DModel=function(e){return n.Global.getUrl(AssetPath.res+AssetPath.prop+"Conventional/"+e+".lh")},AssetPath.get3DRoleModel=function(e){return n.Global.getUrl(AssetPath.res+"character/Conventional/"+e+".lh")},AssetPath.getroleicon=function(e){return n.Global.getUrl(AssetPath.res+"skinicon/"+e+".png")},AssetPath.getVerisonurl=function(){return n.Global.isdebug?n.Global.getUrl(AssetPath.res+"version.json")+AssetPath.versionrandom:n.Global.getUrl(AssetPath.res+"version"+n.Global.resconfigVersion+".json")},AssetPath.getGameVersion=function(){return n.Global.getUrl("gameversion.json")},AssetPath.pipeiicon=function(e){return n.Global.getUrl(AssetPath.res+"icon/"+e+".png")},AssetPath.res="res/",AssetPath.resources="resources/",AssetPath.ui="ui/",AssetPath.subpacksgeui="character/ui/",AssetPath.music="music/",AssetPath.versionrandom="",AssetPath.prop="prop/",AssetPath.skinicon="skinicon/",AssetPath}();a.AssetPath=i},{"../Global":41}],16:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./AssetPath"),i=e("../Global"),o=function(e){function RecConfigs(){var t=e.call(this)||this;return RecConfigs.ins=t,t}return __extends(RecConfigs,e),Object.defineProperty(RecConfigs,"Instance",{get:function(){return null==RecConfigs.ins?new RecConfigs:RecConfigs.ins},enumerable:!0,configurable:!0}),RecConfigs.prototype.init=function(){this.ResDic={}},RecConfigs.prototype.loadUI=function(){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="正常模式")})}))},RecConfigs.prototype.initRec=function(e){if(null!=e&&!RecConfigs.inited){RecConfigs.inited=!0;var t=e.groups,a=e.resources,o={};for(var r in a){var s=a[r];switch(s.type){case"bin":s.type=Laya.Loader.BUFFER;break;case"ls":s.type=Laya.Scene;break;case"lh":s.type=Laya.Sprite3D;break;case"lm":s.type=Laya.MeshSprite3D}o[s.name]=s}for(var l in t){var c,h=t[l],u=h.keys.split(","),p=[];for(c in u){var d=u[c];if(""!=d){var m=o[d].url;m=m.replace("res/",n.AssetPath.res),p.push({url:i.Global.getUrl(m),type:o[d].type})}}this.ResDic[h.name]=p}Laya.loader.clearRes(n.AssetPath.getResConfig())}},RecConfigs.inited=!1,RecConfigs}(Laya.EventDispatcher);a.RecConfigs=o},{"../Global":41,"./AssetPath":15}],17:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function AssetPath(){}return AssetPath.FxPrefabsPath="res/character/FX/Conventional/FX.lh",AssetPath}();a.AssetPath=n;var i=function(){function AssetManager(){}return AssetManager.LoadAssetFun=function(e){var t=this,a=[];a=a.concat(n.FxPrefabsPath),Laya.loader.create(a,Laya.Handler.create(this,function(){var a=Laya.loader.getRes(n.FxPrefabsPath);if(a){for(var i=0;i<a.numChildren;i++){var o=a.getChildAt(i);o.active=!1,t.AllMapDic.push(o)}Laya.loader.clearRes(n.FxPrefabsPath)}else console.log("PolicePrefabs为空");e?e():console.log("fun为空")}))},AssetManager.AllMapDic=new Array,AssetManager}();a.AssetManager=i},{}],18:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Config/AssetPath"),i=function(e){function AudioControl(){var t=e.call(this)||this;return t._isbgOpen=!0,t.open=!0,t._isAllOpen=!0,t._nowBgName="",t._isPlaybging=!1,t._soundIndex=0,AudioControl.ins=t,t}return __extends(AudioControl,e),Object.defineProperty(AudioControl,"Instance",{get:function(){return null==AudioControl.ins?new AudioControl:AudioControl.ins},enumerable:!0,configurable:!0}),AudioControl.prototype.init=function(){Laya.SoundManager.autoReleaseSound=!1,Laya.SoundManager.autoStopMusic=!0},Object.defineProperty(AudioControl.prototype,"gamesoundOpen",{set:function(e){this.open=e,Laya.SoundManager.soundMuted=!e,fairygui.UIConfig.buttonSoundVolumeScale=1==e?1:0},enumerable:!0,configurable:!0}),Object.defineProperty(AudioControl.prototype,"GetSoundSwitch",{get:function(){return this.open},enumerable:!0,configurable:!0}),Object.defineProperty(AudioControl.prototype,"isbgOpen",{get:function(){return this._isbgOpen},set:function(e){this._isbgOpen=e,Laya.SoundManager.musicMuted=!e},enumerable:!0,configurable:!0}),Object.defineProperty(AudioControl.prototype,"isAllOpen",{get:function(){return this._isAllOpen},set:function(e){e?(this._soundIndex--,this._soundIndex<0&&(this._soundIndex=0),this._isPlaybging||0!=this._soundIndex?this._isAllOpen=!1:(this._isAllOpen=!0,this.setGameVolume(1),this.playbgSound(this._nowBgName),fairygui.UIConfig.buttonSoundVolumeScale=1)):(this._isAllOpen=!1,this._soundIndex<0&&(this._soundIndex=0),this._soundIndex++,this._isPlaybging&&this.stopbgSound(),this.setGameVolume(0),fairygui.UIConfig.buttonSoundVolumeScale=0)},enumerable:!0,configurable:!0}),AudioControl.prototype.stopGameSound=function(){Laya.SoundManager.stopAllSound()},AudioControl.prototype.ClearAllSOUND=function(){this.stopGameSound(),this.stopbgSound()},AudioControl.prototype.playbgSound=function(e){this._nowBgName=e,this._isAllOpen&&""!=this._nowBgName&&this._soundIndex<=0&&!this._isPlaybging&&(this._isPlaybging=!0,Laya.SoundManager.playMusic(n.AssetPath.getsound(this._nowBgName)),this.bgSoundVolume=.4)},AudioControl.prototype.stopbgSound=function(){this._isPlaybging=!1,Laya.SoundManager.stopMusic()},Object.defineProperty(AudioControl.prototype,"bgSoundVolume",{get:function(){return Laya.SoundManager.musicVolume},set:function(e){Laya.SoundManager.setMusicVolume(e)},enumerable:!0,configurable:!0}),Object.defineProperty(AudioControl.prototype,"soundVolume",{get:function(){return Laya.SoundManager.soundVolume},set:function(e){Laya.SoundManager.setSoundVolume(e)},enumerable:!0,configurable:!0}),AudioControl.prototype.setGameVolume=function(e){this.bgSoundVolume=e,this.soundVolume=e},AudioControl.prototype.playGameSound=function(e,t){void 0===t&&(t=1),this._isAllOpen&&""!=e&&0!=Laya.SoundManager.soundVolume&&Laya.SoundManager.playSound(n.AssetPath.getsound(e),t)},AudioControl}(Laya.EventDispatcher);a.AudioControl=i},{"../Config/AssetPath":15}],19:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./ResourceControl"),i=e("../utils/SkinItem"),o=e("../Push/CpaDownsView"),r=e("../Push/CpaItem"),s=e("../Push/BaoKuanGameView"),l=e("../Push/ShiwantuijianView"),c=function(e){function ConnectControl(){var t=e.call(this)||this;return t.motionCross=!1,t.blendType=0,t.motionIndex=0,t.motions=["run","run_2","attack","attack_1","attack_2","dead","idle_2","idle_3","idle_4","idle4","reload","replace","replace_2","stop"],t}return __extends(ConnectControl,e),ConnectControl.ConnectComponent=function(){fairygui.UIObjectFactory.setPackageItemExtension("ui://lecxynh2pwlk1a",i.SkinItem),fairygui.UIObjectFactory.setPackageItemExtension("ui://lecxynh2k8c527",o.default),fairygui.UIObjectFactory.setPackageItemExtension("ui://lecxynh2k8c528",r.default),fairygui.UIObjectFactory.setPackageItemExtension("ui://lecxynh2k8c529",s.default),fairygui.UIObjectFactory.setPackageItemExtension("ui://lecxynh2k8c52a",r.default),fairygui.UIObjectFactory.setPackageItemExtension("ui://lecxynh2k8c52b",l.default),fairygui.UIObjectFactory.setPackageItemExtension("ui://lecxynh2k8c52c",r.default),fairygui.UIObjectFactory.setPackageItemExtension("ui://lecxynh2eksc21",r.default),fairygui.UIObjectFactory.setPackageItemExtension("ui://lecxynh2eksc22",r.default),fairygui.UIObjectFactory.setPackageItemExtension("ui://lecxynh2k8c52e",r.default),fairygui.UIObjectFactory.setPackageItemExtension("ui://lecxynh2uotu6h",r.default)},ConnectControl.prototype.sceneLoaded=function(e){Laya.stage.addChild(e);var t=e.getChildAt(2).getComponent(Laya.Animator);this.addButton(100,100,160,30,"动画过渡:否",20,function(e){this.motionCross=!this.motionCross,this.motionCross?e.target.label="动画过渡:是":e.target.label="动画过渡:否"}),this.addButton(100,160,160,30,"混合模式:全身",20,function(e){switch(this.blendType++,3===this.blendType&&(this.blendType=0),this.blendType){case 0:e.target.label="混合模式:全身";break;case 1:e.target.label="混合模式:上身";break;case 2:e.target.label="混合模式:下身"}}),this.addButton(100,220,260,40,"切换动作:attack_2",28,function(e){switch(this.blendType){case 0:this.motionCross?(t.crossFade(this.motions[this.motionIndex],.2,0),t.crossFade(this.motions[this.motionIndex],.2,1)):(t.play(this.motions[this.motionIndex],0),t.play(this.motions[this.motionIndex],1));break;case 1:this.motionCross?t.crossFade(this.motions[this.motionIndex],.2,0):t.play(this.motions[this.motionIndex],0);break;case 2:this.motionCross?t.crossFade(this.motions[this.motionIndex],.2,1):t.play(this.motions[this.motionIndex],1)}e.target.label="切换动作:"+this.motions[this.motionIndex],this.motionIndex++,this.motionIndex===this.motions.length&&(this.motionIndex=0)})},ConnectControl.prototype.addButton=function(e,t,a,n,i,o,r){var s=this;Laya.loader.load(["res/threeDimen/ui/button.png"],Laya.Handler.create(null,function(){var l=Laya.stage.addChild(new Laya.Button("res/threeDimen/ui/button.png",i));l.size(a,n),l.labelBold=!0,l.labelSize=o,l.sizeGrid="4,4,4,4",l.scale(Laya.Browser.pixelRatio,Laya.Browser.pixelRatio),l.pos(e,t),l.on(Laya.Event.CLICK,s,r)}))},ConnectControl.Connnect=function(){this.ConnectFairygui(),this.ConnectComponent()},ConnectControl.ConnectFairygui=function(){fairygui.UIConfig.gameLoaderManager=n.ResourceControl.Instance,fairygui.UIConfig.gameEffectDict={}},ConnectControl}(Laya.EventDispatcher);a.ConnectControl=c},{"../Push/BaoKuanGameView":50,"../Push/CpaDownsView":52,"../Push/CpaItem":54,"../Push/ShiwantuijianView":56,"../utils/SkinItem":92,"./ResourceControl":28}],20:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./LocalDataControl"),i=e("../Time/TimeUtils"),o=e("../Data/UserDataInfo"),r=e("../Time/TimesTamper"),s=function(){function DateControl(){DateControl.ins=this}return Object.defineProperty(DateControl,"Instance",{get:function(){return null==DateControl.ins?new DateControl:DateControl.ins},enumerable:!0,configurable:!0}),DateControl.prototype.loadUI=function(){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","关闭HDR"));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-60*Laya.Browser.pixelRatio),e.on(Laya.Event.CLICK,this,function(){var t=this.camera.enableHDR;e.label=t?"开启HDR":"关闭HDR",this.camera.enableHDR=!t})}))},DateControl.prototype.SetSelf=function(){var e=n.LocalDataControl.Instance.getstr(o.UserDataInfo.lastDay),t=i.TimeUtils.formatYearMonthDate1(r.TimesTamper.Instance.serverTime);e!=t?(n.LocalDataControl.Instance.addstr(o.UserDataInfo.lastDay,t),DateControl.Fresh=!0):DateControl.Fresh=!1},DateControl}();a.DateControl=s},{"../Data/UserDataInfo":35,"../Time/TimeUtils":58,"../Time/TimesTamper":60,"./LocalDataControl":23}],21:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../JoystickModule"),i=e("../utils/DispatcherManager"),o=e("../utils/GameState"),r=e("../Control/SceneControl"),s=e("../PrefabControl/PropManager"),l=e("../Time/TimerService"),c=e("../CFG/GameCFG"),h=e("../Control/AudioControl"),u=e("../WXSDK/Sdk"),p=e("../PrefabControl/PanelResDic"),d=e("../Agency/AgencyUserMessage"),m=e("../Agency/AgencyTrial"),f=e("../Agency/AgencySkin"),g=e("../WXSDK/RecordManager"),y=function(){function GameStateControl(){this.nowGameState=0,this._zhuanxiangbeishu=0,this._huadongSpeedX=0,this._huadongClimbSpeedX=0,this.endGamePlayerArr=[],this._isneedShunyiX=!1,this._nowTime=0,this._lastAngle=0,this._time=0,this.nowMingCi=0,this._nums=0,this._all=0,GameStateControl.ins=this}return Object.defineProperty(GameStateControl,"Instance",{get:function(){return null==GameStateControl.ins?new GameStateControl:GameStateControl.ins},enumerable:!0,configurable:!0}),GameStateControl.prototype.init=function(){this._huadongSpeedX=Number(c.default.dict[4].value),this._huadongClimbSpeedX=Number(c.default.dict[5].value),c.default.dict[7]?this._zhuanxiangbeishu=Number(c.default.dict[7].value):this._zhuanxiangbeishu=2,this.initEvent()},GameStateControl.prototype.initEvent=function(){i.DispatcherManager.addEventListener(o.GameState.lose,this,this.endGame),i.DispatcherManager.addEventListener(o.GameState.end,this,this.endGame),i.DispatcherManager.addEventListener(o.GameState.npcend,this,this.npcendGameHandler)},GameStateControl.prototype.npcendGameHandler=function(e){this.endGamePlayerArr.push(e)},GameStateControl.prototype.setClickPanel=function(e){this._joystickModule=new n.JoystickModule(e),this._joystickModule.setEventCallback(this,this.ondownfun,this.onmovefun,this.onupfun)},GameStateControl.prototype.ondownfun=function(){this._lastAngle=0,this._nowTime=Laya.Browser.now()/1e3},GameStateControl.prototype.onmovefun=function(e){if(1==this.nowGameState){var t=this._joystickModule.angle-this._lastAngle;this._lastAngle=this._joystickModule.angle,s.PropManager.iscarmanpc?s.PropManager.npcscriptDict.npc_0.Joy(e>0?this._huadongSpeedX:-this._huadongSpeedX,t*this._zhuanxiangbeishu):r.SceneControl.Instance.PlayerScript.Joy(e>0?this._huadongSpeedX:-this._huadongSpeedX,e>0?this._huadongClimbSpeedX:-this._huadongClimbSpeedX,t*this._zhuanxiangbeishu)}},GameStateControl.prototype.onupfun=function(){s.PropManager.iscarmanpc?s.PropManager.npcscriptDict.npc_0.Joy(0,0):1==this.nowGameState&&r.SceneControl.Instance.PlayerScript.Joy(0,0,0)},GameStateControl.prototype.update=function(e){if(1==this.nowGameState){this._time=0;var t,a,n=s.PropManager.npcscriptDict;for(t in this._nums=0,this._all=0,n)1==(a=n[t]).getAction()&&(s.PropManager.mainRole.transform.position.z<a.getPostion().z&&this._nums++,this._all++);this.nowMingCi=this.endGamePlayerArr.length+(this._all+1-this._nums),s.PropManager.txt_mingci.text="第"+this.nowMingCi+"名"}},GameStateControl.prototype.startGame=function(){p.PanelResDic.Instance.getSingleTon(d.AgencyUserMessage).RoleData;var e=p.PanelResDic.Instance.getSingleTon(f.AgencySkin).GainNoHaveSkin();0==e.length?this.entergame():p.PanelResDic.Instance.getSingleTon(m.AgencyTrial).openview(e)},GameStateControl.prototype.entergame=function(e){g.RecordManager.Instance.RecordStart(),this.nowMingCi=0,this.endGamePlayerArr.length=0,this.nowGameState=1,l.TimerService.Instance.addUpdateTarget(this),this.update(500),e?i.DispatcherManager.dispatchEvent(o.GameState.start,e):i.DispatcherManager.dispatchEvent(o.GameState.start),h.AudioControl.Instance.playbgSound("bgm"),u.WxApi.recordAldEvent("主界面点击开始游戏...")},GameStateControl.prototype.stopGame=function(){this.nowGameState=2,this.onupfun()},GameStateControl.prototype.endGame=function(){if(s.PropManager.jiantouArr&&s.PropManager.jiantouArr.length>0)for(var e=s.PropManager.jiantouArr,t=e.length-1;t>=0;t--)e[t].destroy(),e.splice(t,1);s.PropManager.jiantouArr.length=0,this.nowGameState=0,l.TimerService.Instance.removeUpdateTarget(this);var a=s.PropManager.npcscriptDict;if(a)for(var n in a)a[n].stop();this.onupfun(),h.AudioControl.Instance.stopbgSound()},GameStateControl}();a.GameStateControl=y},{"../Agency/AgencySkin":6,"../Agency/AgencyTrial":7,"../Agency/AgencyUserMessage":8,"../CFG/GameCFG":10,"../Control/AudioControl":18,"../Control/SceneControl":29,"../JoystickModule":43,"../PrefabControl/PanelResDic":48,"../PrefabControl/PropManager":49,"../Time/TimerService":59,"../WXSDK/RecordManager":76,"../WXSDK/Sdk":77,"../utils/DispatcherManager":85,"../utils/GameState":86}],22:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Global"),i=e("../utils/LayOUT"),o=function(e){function LayoutControl(){var t=e.call(this)||this;return t._uilayerZorder=0,t._upuilayerZorder=200,t._tipslayerZorder=1e3,t._guidelayerZorder=600,t.uiLayer=new fairygui.GComponent,t.topLayer=new fairygui.GComponent,t.background=new fairygui.GComponent,t._position=new Laya.Vector3,t._outPos=new Laya.Vector3,t.scaleDelta=0,LayoutControl.ins=t,t}return __extends(LayoutControl,e),Object.defineProperty(LayoutControl,"Instance",{get:function(){return null==LayoutControl.ins?new LayoutControl:LayoutControl.ins},enumerable:!0,configurable:!0}),LayoutControl.prototype.AddLayerByName=function(e,t){t==i.LayOUT.BG?LayoutControl.Instance.background.addChild(e):t==i.LayOUT.UI?(this._uilayerZorder++,LayoutControl.Instance.uiLayer.addChild(e),e.sortingOrder=this._uilayerZorder):t==i.LayOUT.UITop?(this._upuilayerZorder++,LayoutControl.Instance.uiLayer.addChild(e),e.sortingOrder=this._upuilayerZorder):t==i.LayOUT.TIP?(this._tipslayerZorder++,LayoutControl.Instance.uiLayer.addChild(e),e.sortingOrder=this._tipslayerZorder):t==i.LayOUT.GUIDE&&(this._guidelayerZorder++,LayoutControl.Instance.uiLayer.addChild(e),e.sortingOrder=this._guidelayerZorder)},LayoutControl.prototype.initlayer=function(){n.Global.stage.addChild(fairygui.GRoot.inst.displayObject),fairygui.GRoot.inst.addChild(this.background),fairygui.GRoot.inst.addChild(this.uiLayer),fairygui.GRoot.inst.addChild(this.topLayer)},LayoutControl.prototype.addHorizontalBox=function(e,t,a){var n=this.scene.addChild(new Laya.MeshSprite3D(this.mesh2));n.meshRenderer.material=this.mat1,n.meshRenderer.castShadow=!0,n.meshRenderer.receiveShadow=!0,this.tmpVector.setValue(e,t,a),n.transform.position=this.tmpVector;var i=n.addComponent(Laya.Rigidbody3D);i.mass=10,i.friction=1,i.restitution=.2;var o=new Laya.BoxColliderShape(2,.33,.5);i.colliderShape=o},LayoutControl.prototype.ClearLayerByName=function(e){switch(e){case i.LayOUT.UI:this._uilayerZorder--,this._uilayerZorder<0&&(this._uilayerZorder=0);break;case i.LayOUT.UITop:this._upuilayerZorder--,this._upuilayerZorder<200&&(this._upuilayerZorder=200);break;case i.LayOUT.TIP:this._tipslayerZorder--,this._tipslayerZorder<1e3&&(this._tipslayerZorder=1e3);break;case i.LayOUT.GUIDE:this._tipslayerZorder--,this._tipslayerZorder<600&&(this._tipslayerZorder=600)}},LayoutControl.prototype.onComplete=function(){this.scene.addChild(Laya.Loader.getRes("res/threeDimen/staticModel/grid/plane.lh"));this.layaMonkey2D=Laya.stage.addChild(new Laya.Image("res/threeDimen/monkey.png")),Laya.timer.frameLoop(1,this,this.animate)},LayoutControl.prototype.animate=function(){this._position.x=Math.sin(this.scaleDelta+=.01),this.camera.viewport.project(this._position,this.camera.projectionViewMatrix,this._outPos),this.layaMonkey2D.pos(this._outPos.x/Laya.stage.clientScaleX,this._outPos.y/Laya.stage.clientScaleY)},LayoutControl}(Laya.EventDispatcher);a.LayoutControl=o},{"../Global":41,"../utils/LayOUT":90}],23:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Global"),i=e("../WXSDK/PlatfromType"),o=function(e){function LocalDataControl(){var t=e.call(this)||this;return LocalDataControl.ins=t,t}return __extends(LocalDataControl,e),Object.defineProperty(LocalDataControl,"Instance",{get:function(){return null==LocalDataControl.ins?new LocalDataControl:LocalDataControl.ins},enumerable:!0,configurable:!0}),LocalDataControl.prototype.init=function(){},LocalDataControl.prototype.AddData=function(e,t){this.AddLocalData(e,t)},LocalDataControl.prototype.getObj=function(e){return this.GetLocalCaCheData(e)},LocalDataControl.prototype.addstr=function(e,t){this.addCacheStr(e,t)},LocalDataControl.prototype.addnum=function(e,t){this.addCacheStr(e,t.toString())},LocalDataControl.prototype.getstr=function(e){return this.getCachestr(e)},LocalDataControl.prototype.getnum=function(e){return Number(this.getCachestr(e))},LocalDataControl.prototype.removeCache=function(e){this.removeselectCache(e)},LocalDataControl.prototype.clearAll=function(){this.clearAllCache()},LocalDataControl.prototype.AddLocalData=function(e,t){switch(n.Global.nowplatfrom){case i.PlatfromType.wx:this.setStorageSyncWX(e,t);break;default:Laya.LocalStorage.setJSON(e,t)}},LocalDataControl.prototype.GetLocalCaCheData=function(e){var t;switch(n.Global.nowplatfrom){case i.PlatfromType.wx:t=this.getStorageSyncWX(e);break;default:t=Laya.LocalStorage.getJSON(e)}return t||(t={}),t},LocalDataControl.prototype.addCacheStr=function(e,t){switch(n.Global.nowplatfrom){case i.PlatfromType.wx:this.setStorageSyncWX(e,t);break;default:Laya.LocalStorage.setItem(e,t)}},LocalDataControl.prototype.getCachestr=function(e){var t="0";switch(n.Global.nowplatfrom){case i.PlatfromType.wx:t=this.getStorageSyncWX(e);break;default:t=Laya.LocalStorage.getItem(e)}return null!=t&&""!=t||(t="0"),t},LocalDataControl.prototype.removeselectCache=function(e){switch(n.Global.nowplatfrom){case i.PlatfromType.wx:this.removeStorageWX(e);break;default:Laya.LocalStorage.removeItem(e)}},LocalDataControl.prototype.clearAllCache=function(){switch(n.Global.nowplatfrom){case i.PlatfromType.wx:this.clearStorageWX();break;default:Laya.LocalStorage.clear()}},LocalDataControl.prototype.setStorageSyncWX=function(e,t){var a=Laya.Browser.window.wx;a&&a.setStorageSync(e,t)},LocalDataControl.prototype.getStorageSyncWX=function(e){var t=Laya.Browser.window.wx;return t?t.getStorageSync(e):null},LocalDataControl.prototype.removeStorageWX=function(e){Laya.Browser.window.wx&&Laya.Browser.window.wx.removeStorage(e)},LocalDataControl.prototype.clearStorageWX=function(){Laya.Browser.window.wx&&Laya.Browser.window.wx.clearStorageSync()},LocalDataControl}(Laya.EventDispatcher);a.LocalDataControl=o},{"../Global":41,"../WXSDK/PlatfromType":74}],24:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/ResDataControl"),i=e("../Control/ResourceControl"),o=e("../utils/DispatcherManager"),r=e("../PrefabControl/PanelResDic"),s=e("../utils/ViewAction"),l=e("../View/ViewManager"),c=e("../Data/ComponentEventData"),h=e("../PrefabControl/GamePool"),u=function(e){function PanelBaseControl(t,a,n,i,o,r){void 0===t&&(t=""),void 0===a&&(a=""),void 0===n&&(n=!1),void 0===i&&(i=s.ViewAction.ActionType_none),void 0===o&&(o=0),void 0===r&&(r=!0);var l=e.call(this)||this;return l.isguideing=!1,l.PackageName="",l.ResourcesName="",l._iscache=!0,l._ActionType=s.ViewAction.ActionType_none,l._clickBgIsColse=0,l.EventResDic={},l.EventGlobal={},l._iscache=r,l.PackageName=t,l.ResourcesName=a,l._isAddpackage=n,l._ActionType=i,l._clickBgIsColse=o,l.showModalWait(),l}return __extends(PanelBaseControl,e),PanelBaseControl.prototype.ResolveUI=function(e,t,a,i,o,r){for(var l in void 0===i&&(i=s.ViewAction.ActionType_none),void 0===o&&(o=0),void 0===r&&(r=!0),this.PackageName=e,this.ResourcesName=t,this._ActionType=i,this._clickBgIsColse=o,n.ResDataControl.Instance.AddViewPackByName(e,a,r),this.contentPane=fairygui.UIPackage.createObject(e,t).asCom,this.contentPane._children){var c=this.contentPane._children[l];if("item_panel"==c.name){var h=c;if(h)for(var u in h._children){var p=h._children[u];this[p.name]=p}this.item_panel=c}else this[c.name]=c}this.setSize(fairygui.GRoot.inst.width,fairygui.GRoot.inst.height),this.contentPane.setPivot(.5,.5),this.setPivot(.5,.5),this.setclickBgIsColse(),this.initView(),this.initEvent(),this.ShowViewACTION()},PanelBaseControl.prototype.LoadViewUI=function(e,t,a){this._loadTarget=t,this._onLoadedHandler=a,i.ResourceControl.Instance.loadGroup(e,this,this.LoadComplete)},PanelBaseControl.prototype.createLabel=function(e,t){var a=new Laya.Label;return a.font="Microsoft YaHei",a.text="SAMPLE DEMO",a.fontSize=30,a.color=e,t&&(a.stroke=4,a.strokeColor=t),Laya.stage.addChild(a),a},PanelBaseControl.prototype.loadUibyArr=function(e,t,a){this._loadTarget=t,this._onLoadedHandler=a,i.ResourceControl.Instance.Loaders(e,this,this.LoadComplete)},PanelBaseControl.prototype.createRadioGroup=function(e){var t=new Laya.RadioGroup;return t.skin=e,t.space=70,t.direction="v",t.labels="Item1, Item2, Item3",t.labelColors="#787878,#d3d3d3,#FFFFFF",t.labelSize=20,t.labelBold=!0,t.labelPadding="5,0,0,5",t.selectHandler=new Laya.Handler(this,this.onSelectChange),Laya.stage.addChild(t),t},PanelBaseControl.prototype.onSelectChange=function(e){console.log("你选择了第 "+(e+1)+" 项")},PanelBaseControl.prototype.LoadComplete=function(){this._loadTarget&&this._onLoadedHandler&&this._onLoadedHandler.call(this._loadTarget)},PanelBaseControl.prototype.removeEffectPackage=function(e){n.ResDataControl.Instance.ClearPackByName(e,!0)},PanelBaseControl.prototype.getpanelController=function(e){return this.item_panel?this.item_panel.getController(e):null},PanelBaseControl.prototype.setup=function(){this.createLabel("#FFFFFF",null).pos(30,50),this.createLabel("#00FFFF",null).pos(290,50),this.createLabel("#FFFF00","#FFFFFF").pos(30,100),this.createLabel("#000000","#FFFFFF").pos(290,100),this.createLabel("#FFFFFF","#00FFFF").pos(30,150),this.createLabel("#0080FF","#00FFFF").pos(290,150)},PanelBaseControl.prototype.getpanelTransition=function(e){return this.item_panel?this.item_panel.getTransition(e):null},PanelBaseControl.prototype.getChildformContentPanel=function(e){return this.contentPane?this.contentPane.getChild(e):null},PanelBaseControl.prototype.onInit=function(){e.prototype.onInit.call(this),""!=this.PackageName&&""!=this.ResourcesName&&this.ResolveUI(this.PackageName,this.ResourcesName,this._isAddpackage,this._ActionType,this._clickBgIsColse,this._iscache)},PanelBaseControl.prototype.initView=function(){},PanelBaseControl.prototype.initEvent=function(){},PanelBaseControl.prototype.ShowViewACTION=function(){switch(this._ActionType){case s.ViewAction.ActionType_none:this.windowanmoend();break;case s.ViewAction.ActionType_addmoveToMiddle:this.contentPane.x=fairygui.GRoot.inst.width,Laya.Tween.to(this.contentPane,{x:0},300,laya.utils.Ease.quadInOut,Laya.Handler.create(this,this.windowanmoend));break;case s.ViewAction.ActionType_addmoveFromBottom:this.contentPane.y=fairygui.GRoot.inst.height,Laya.Tween.to(this.contentPane,{y:0},300,laya.utils.Ease.quadInOut,Laya.Handler.create(this,this.windowanmoend));break;case s.ViewAction.ActionType_addscaleMinToMax:this.contentPane.scaleX=this.contentPane.scaleY=.01,Laya.Tween.to(this.contentPane,{scaleX:1,scaleY:1},300,laya.utils.Ease.quadInOut,Laya.Handler.create(this,this.windowanmoend))}},PanelBaseControl.prototype.createCheckBox=function(e){var t=new Laya.CheckBox(e);return Laya.stage.addChild(t),t.labelColors="white",t.labelSize=20,t.labelFont="Microsoft YaHei",t.labelPadding="3,0,0,5",t},PanelBaseControl.prototype.updateLabel=function(e){e.label=e.selected?"已选中":"未选中"},PanelBaseControl.prototype.windowanmoend=function(){Laya.timer.callLater(this,this.onShowView)},PanelBaseControl.prototype.onShowView=function(){this.closeModalWait(),this.showClickBg()},PanelBaseControl.prototype.showClickBg=function(){this._clickBg&&(this._clickBg.alpha=.55,2!=this._clickBgIsColse||this.hasClickListener()||this._clickBg.onClick(this,this.ClickExitView))},PanelBaseControl.prototype.ClickExitView=function(){l.ViewManager.Instance.close(this.viewKey,!0)},PanelBaseControl.prototype.getProxy=function(e){return r.PanelResDic.Instance.getSingleTon(e)},PanelBaseControl.prototype.ExitView=function(e){if(void 0===e&&(e=""),this._clickBg&&(this._clickBg.visible=!1),""==e)switch(this._ActionType){case s.ViewAction.ActionType_none:this.destory();break;case s.ViewAction.ActionType_addmoveToMiddle:Laya.Tween.to(this,{x:fairygui.GRoot.inst.width},300,laya.utils.Ease.quadInOut,Laya.Handler.create(this,this.destory));break;case s.ViewAction.ActionType_addmoveFromBottom:Laya.Tween.to(this,{y:fairygui.GRoot.inst.height},300,laya.utils.Ease.quadInOut,Laya.Handler.create(this,this.destory));break;case s.ViewAction.ActionType_addscaleMinToMax:Laya.Tween.to(this,{scaleX:.01,scaleY:.01},300,laya.utils.Ease.quadInOut,Laya.Handler.create(this,this.destory))}else switch(e){case s.ViewAction.ActionType_none:this.destory();break;case s.ViewAction.ActionType_removescaleMaxToMin:Laya.Tween.to(this,{scaleX:.01,scaleY:.01},300,laya.utils.Ease.quadInOut,Laya.Handler.create(this,this.destory));break;case s.ViewAction.ActionType_removemoveToRight:Laya.Tween.to(this,{x:fairygui.GRoot.inst.width},300,laya.utils.Ease.quadInOut,Laya.Handler.create(this,this.destory))}},PanelBaseControl.prototype.getTransitionByName=function(e){return this.contentPane.getTransition(e)},PanelBaseControl.prototype.dispacheDatatrigger=function(e,t){void 0===t&&(t=null),o.DispatcherManager.dispatchEvent(e,t)},PanelBaseControl.prototype.addDataEvent=function(e,t,a){if(!this.EventGlobal.hasOwnProperty(e)){var n=h.GamePool.GetItem(c.ComponentEventData.ResDicValue);this.EventGlobal[e]=n,n.type=e,n.thisObject=t,n.listener=a,o.DispatcherManager.addEventListener(e,t,a)}},PanelBaseControl.prototype.ClearEventData=function(e,t,a){if(this.EventGlobal[e]){var n=this.EventGlobal[e];o.DispatcherManager.removeEventListener(e,t,a),n.clear(),delete this.EventGlobal[e]}},PanelBaseControl.prototype.ClearEventByType=function(e,t,a,n){if(e&&this.EventResDic[e.name])for(var i,o=this.EventResDic[e.name],r=0,s=o.length;r<s;r++)if((i=o[r])&&i.type==t&&i.thisObject==a&&i.listener==n){e.off(t,a,n),i.clear(),o.splice(r,1);break}},PanelBaseControl.prototype.AddEventByType=function(e,t,a,n,i){if(void 0===i&&(i=null),e){if(null==e.name||""==e.name)throw"baseview addListener target.name is null";var o=h.GamePool.GetItem(c.ComponentEventData.ResDicValue);o.target=e,o.type=t,o.thisObject=a,o.listener=n,this.EventResDic.hasOwnProperty(e.name)||(this.EventResDic[e.name]=[]),this.JudgeIsHaveEvent(e,t)||(e.on(t,a,n,i),this.EventResDic[e.name].push(o))}},PanelBaseControl.prototype.JudgeIsHaveEvent=function(e,t){var a,n;for(var i in a=this.EventResDic[e.name])if((n=a[i])&&n.type==t)return!0;return!1},PanelBaseControl.prototype.getComById=function(e){return this.contentPane.getChild(e).asCom},PanelBaseControl.prototype.getControllerByBame=function(e){return this.contentPane.getController(e)},PanelBaseControl.prototype.ClearEvent=function(){if(this.EventResDic){var e,t,a,n,i=this.EventResDic;for(e in i){if((t=i[e])&&t.length>0)for(a=0,a=t.length-1;a>=0;a--)(n=t[a])&&(n.target&&n.target.off(n.type,n.thisObject,n.listener),n.clear()),t.splice(a,1);delete this.EventResDic[e]}}this.EventResDic={}},PanelBaseControl.prototype.clearEvent=function(){},PanelBaseControl.prototype.destory=function(){this.clearEvent(),this.closeModalWait(),this.ClearGlobalEvent(),this.ClearEvent(),this._loadTarget=null,this._onLoadedHandler=null,Laya.Tween.clearTween(this),n.ResDataControl.Instance.ClearPackByName(this.PackageName,!1),this.PackageName=null,this.ResourcesName=null,this._clickBg&&(this._clickBg.offClick(this,this.ClickExitView),this._clickBg.dispose(),this._clickBg=null),this.viewKey=null,this.dispose()},PanelBaseControl.prototype.setclickBgIsColse=function(){this.isShowing&&this._clickBgIsColse>0&&this.contentPane&&(this._clickBg||""==PanelBaseControl.viewbgUrl||(this._clickBg=new fairygui.GLoader,this._clickBg.touchable=!0,this._clickBg.setSize(fairygui.GRoot.inst.width,fairygui.GRoot.inst.height),this._clickBg.url=PanelBaseControl.viewbgUrl,this._clickBg.fill=fairygui.LoaderFillType.ScaleFree,this._clickBg.alpha=0,this.contentPane.addChildAt(this._clickBg,0)))},PanelBaseControl.prototype.ClearGlobalEvent=function(){if(this.EventGlobal){var e,t=this.EventGlobal;for(e in t){var a=t[e];a&&this.ClearEventData(a.type,a.thisObject,a.listener)}}this.EventGlobal={}},PanelBaseControl.viewbgUrl="",PanelBaseControl}(fairygui.Window);a.PanelBaseControl=u},{"../Control/ResDataControl":27,"../Control/ResourceControl":28,"../Data/ComponentEventData":30,"../PrefabControl/GamePool":47,"../PrefabControl/PanelResDic":48,"../View/ViewManager":70,"../utils/DispatcherManager":85,"../utils/ViewAction":93}],25:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../utils/DispatcherManager"),i=e("../PrefabControl/PanelResDic"),o=e("../Data/ComponentEventData"),r=e("../PrefabControl/GamePool"),s=function(e){function PanelChildControl(){var t=e.call(this)||this;return t.EventResDic={},t.EventGlobal={},t.DIALOG_WIDTH=220,t.DIALOG_HEIGHT=275,t.CLOSE_BTN_WIDTH=43,t.CLOSE_BTN_PADDING=5,t}return __extends(PanelChildControl,e),PanelChildControl.prototype.ClearEvent=function(){if(this.EventResDic){var e,t,a,n,i=this.EventResDic;for(e in i){if((t=i[e])&&t.length>0)for(a=0,a=t.length-1;a>=0;a--)(n=t[a])&&(n.target&&n.target.off(n.type,n.thisObject,n.listener),n.clear()),t.splice(a,1);delete this.EventResDic[e]}}this.EventResDic={}},PanelChildControl.prototype.dispose=function(){this.ClearGlobalEvent(),this.ClearEvent(),e.prototype.dispose.call(this)},PanelChildControl.prototype.constructFromXML=function(t){for(var a in e.prototype.constructFromXML.call(this,t),this._children){var n=this._children[a];this[n.name]=n}this.onInit()},PanelChildControl.prototype.onInit=function(){},PanelChildControl.prototype.getProxy=function(e){return i.PanelResDic.Instance.getSingleTon(e)},PanelChildControl.prototype.dispacheDatatrigger=function(e,t){void 0===t&&(t=null),n.DispatcherManager.dispatchEvent(e,t)},PanelChildControl.prototype.hasDataEvent=function(e){return n.DispatcherManager.hasEventListener(e)},PanelChildControl.prototype.AddEventData=function(e,t,a){if(!this.EventGlobal.hasOwnProperty(e)){var i=r.GamePool.GetItem(o.ComponentEventData.ResDicValue);this.EventGlobal[e]=i,i.type=e,i.thisObject=t,i.listener=a,n.DispatcherManager.addEventListener(e,t,a)}},PanelChildControl.prototype.onSkinLoadComplete=function(){var e=new Laya.Dialog,t=new Laya.Image(this.assets[0]);e.addChild(t);var a=new Laya.Button(this.assets[1]);a.pos(this.DIALOG_WIDTH-this.CLOSE_BTN_WIDTH-this.CLOSE_BTN_PADDING,this.CLOSE_BTN_PADDING),e.addChild(a),e.dragArea="0,0,"+this.DIALOG_WIDTH+","+this.DIALOG_HEIGHT,e.show()},PanelChildControl.prototype.removeDataEvent=function(e,t,a){if(this.EventGlobal[e]){var i=this.EventGlobal[e];n.DispatcherManager.removeEventListener(e,t,a),i.clear(),delete this.EventGlobal[e]}},PanelChildControl.prototype.AddEventByType=function(e,t,a,n,i){if(void 0===i&&(i=null),e){if(null==e.name||""==e.name)throw"childbaseview addListener target.name is null";var s=r.GamePool.GetItem(o.ComponentEventData.ResDicValue);s.target=e,s.type=t,s.thisObject=a,s.listener=n,this.EventResDic.hasOwnProperty(e.name)||(this.EventResDic[e.name]=[]),this.JudgeIsHaveEvent(e,t)||(e.on(t,a,n,i),this.EventResDic[e.name].push(s))}},PanelChildControl.prototype.JudgeIsHaveEvent=function(e,t){var a,n;for(var i in a=this.EventResDic[e.name])if((n=a[i])&&n.type==t)return!0;return!1},PanelChildControl.prototype.ClearEventByType=function(e,t,a,n){if(e&&this.EventResDic[e.name])for(var i,o=this.EventResDic[e.name],r=0,s=o.length;r<s;r++)if((i=o[r])&&i.type==t&&i.thisObject==a&&i.listener==n){e.off(t,a,n),i.clear(),o.splice(r,1);break}},PanelChildControl.prototype.ClearGlobalEvent=function(){if(this.EventGlobal){var e,t=this.EventGlobal;for(e in t){var a=t[e];a&&this.removeDataEvent(a.type,a.thisObject,a.listener)}}this.EventGlobal={}},PanelChildControl.prototype.placeHScroller=function(){var e=new Laya.HScrollBar;e.skin="res/ui/hscroll.png",e.width=300,e.pos(50,170),e.min=0,e.max=100,e.changeHandler=new Laya.Handler(this,this.onChange),Laya.stage.addChild(e)},PanelChildControl.prototype.placeVScroller=function(){var e=new Laya.VScrollBar;e.skin="res/ui/vscroll.png",e.height=300,e.pos(400,50),e.min=0,e.max=100,e.changeHandler=new Laya.Handler(this,this.onChange),Laya.stage.addChild(e)},PanelChildControl.prototype.onChange=function(e){console.log("滚动条的位置: value="+e)},PanelChildControl}(fairygui.GComponent);a.PanelChildControl=s},{"../Data/ComponentEventData":30,"../PrefabControl/GamePool":47,"../PrefabControl/PanelResDic":48,"../utils/DispatcherManager":85}],26:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function PoolManager(){PoolManager.PoolManagerInstance=this}return Object.defineProperty(PoolManager,"Instance",{get:function(){return PoolManager.PoolManagerInstance?PoolManager.PoolManagerInstance:new PoolManager},enumerable:!0,configurable:!0}),PoolManager.GetSprite3D=function(e){var t=e.name;if(null!=this.Sprite3DDic[t]&&null!=this.Sprite3DDic[t]){if(this.Sprite3DDic[t].length>0){var a=this.Sprite3DDic[t][0];return a&&!a.destroyed||(a=Laya.Sprite3D.instantiate(e)),this.Sprite3DDic[t].splice(0,1),a.transform.scale=e.transform.scale.clone(),a.active=!0,a}var n;return(n=Laya.Sprite3D.instantiate(e)).active=!0,n}return(n=Laya.Sprite3D.instantiate(e)).active=!0,n},PoolManager.RecoverSprite3D=function(e,t){if(void 0===t&&(t=!1),e)if(e.destroyed)console.warn("PoolManager Recover Error!","destroyed");else if(t||0!=e.active){var a=e.name;if(null!=this.Sprite3DDic[a]&&null!=this.Sprite3DDic[a]){var n=this.Sprite3DDic[a];if(n.length>this.PoolSize)return void e.destroy();n.push(e)}else(n=[]).push(e),this.Sprite3DDic[a]=n;e.transform.position=new Laya.Vector3(0,0,-100),e.removeSelf(),e.active=!1}else console.warn("PoolManager Recover Error!",e.name);else console.warn("PoolManager Recover Error!",null)},PoolManager.ClearPool=function(){for(var e in this.Sprite3DDic)for(var t=this.Sprite3DDic[e],a=0;a<t.length;a++)t[a].destroy();this.Sprite3DDic={}},PoolManager.PoolSize=80,PoolManager.Sprite3DDic={},PoolManager}();a.default=n},{}],27:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./ResourceControl"),i=e("../Data/LocalData"),o=e("../PrefabControl/GamePool"),r=e("../Config/AssetPath"),s=e("../Time/TimerService"),l=Laya.Tab,c=function(){function ResDataControl(){this._time=0,this.ClearInterval=5e4,this.CheckInterval=2e4,this.skins=["res/ui/tab1.png","res/ui/tab2.png"],ResDataControl.ins=this}return Object.defineProperty(ResDataControl,"Instance",{get:function(){return null==ResDataControl.ins?new ResDataControl:ResDataControl.ins},enumerable:!0,configurable:!0}),ResDataControl.prototype.AddPackByName=function(e,t,a,n){void 0===a&&(a=!0),void 0===n&&(n=!0),a&&fairygui.UIPackage.addPackage(e+t,t),this.AddLocalLiveData(t,n)},ResDataControl.prototype.init=function(){o.GamePool.Mark(i.LocalData.ResDicValue,i.LocalData),this.urlRes={},this.packageRes={},this.NoLiveData={loading:!0,main:!0,uicomponent:!0},s.TimerService.Instance.addUpdateTarget(this)},ResDataControl.prototype.RemoveResources=function(e,t){for(var a in void 0===t&&(t=""),""!=t&&fairygui.UIPackage.removePackage(t),e)this.RemoveResourcesByurl(e[a].url,!0)},ResDataControl.prototype.placeHSlider=function(){var e=new Laya.HSlider;e.skin="res/ui/hslider.png",e.width=300,e.pos(50,170),e.min=0,e.max=100,e.value=50,e.tick=1,Laya.stage.addChild(e)},ResDataControl.prototype.placeVSlider=function(){var e=new Laya.VSlider;e.skin="res/ui/vslider.png",e.height=300,e.pos(400,50),e.min=0,e.max=100,e.value=50,e.tick=1,Laya.stage.addChild(e)},ResDataControl.prototype.update=function(e){if(this._time+=e,this._time>this.CheckInterval){if(n.ResourceControl.Instance.running)return void(this._time-=1e3);this.RefreshGroupRes(),this._time=0}},ResDataControl.prototype.RemoveResourcesByurl=function(e,t){void 0===t&&(t=!1),this.urlRes.hasOwnProperty(e)?t?(Laya.loader.clearRes(e),delete this.urlRes[e]):this.urlRes[e]--:Laya.loader.clearRes(e)},ResDataControl.prototype.ClearLiveDataByPackName=function(e){this.packageRes[e]&&(this.packageRes[e].clear(),delete this.packageRes[e])},ResDataControl.prototype.AddViewPackByName=function(e,t,a){void 0===t&&(t=!0),void 0===a&&(a=!0),t&&("main"==e?fairygui.UIPackage.addPackage(r.AssetPath.res+r.AssetPath.subpacksgeui+e,e):fairygui.UIPackage.addPackage(r.AssetPath.resources+r.AssetPath.ui+e,e)),this.AddLocalLiveData(e,a)},ResDataControl.prototype.ClearPackByName=function(e,t){if(void 0===t&&(t=!1),""!=e&&null!=e)if(t)fairygui.UIPackage.removePackage(e),this.packageRes.hasOwnProperty(e)&&delete this.packageRes[e];else if(this.packageRes.hasOwnProperty(e)){var a=this.packageRes[e];a&&a.ref--}},ResDataControl.prototype.RefreshGroupRes=function(){var e,t,a=Laya.Browser.now();if(this.packageRes)for(e in this.packageRes)(t=this.packageRes[e]).ref<=0&&a-t.time>this.ClearInterval&&(this.ClearPackByName(t.packageName,!0),this.ClearLiveDataByPackName(t.packageName));if(this.urlRes){var n=this.urlRes;for(e in n)n[e]<=0&&this.RemoveResourcesByurl(e,!0)}},ResDataControl.prototype.onSkinLoaded=function(){var e=this.createTab(this.skins[0]);e.pos(40,120),e.labelColors="#000000,#d3d3d3,#333333";var t=this.createTab(this.skins[1]);t.pos(40,220),t.labelColors="#FFFFFF,#8FB299,#FFFFFF"},ResDataControl.prototype.createTab=function(e){var t=new l;return t.skin=e,t.labelBold=!0,t.labelSize=20,t.labelStrokeColor="#000000",t.labels="Tab Control 1,Tab Control 2,Tab Control 3",t.labelPadding="0,0,0,0",t.selectedIndex=1,Laya.stage.addChild(t),t},ResDataControl.prototype.GainResources=function(e,t){return void 0===t&&(t=!0),t&&(null==this.urlRes[e]&&(this.urlRes[e]=0),this.urlRes[e]++),Laya.loader.getRes(e)},ResDataControl.prototype.AddLocalLiveData=function(e,t){var a;t&&!this.NoLiveData.hasOwnProperty(e)&&(this.packageRes.hasOwnProperty(e)?a=this.packageRes[e]:((a=o.GamePool.GetItem(i.LocalData.ResDicValue)).packageName=e,this.packageRes[e]=a),a.ref++,a.time=Laya.Browser.now())},ResDataControl}();a.ResDataControl=c},{"../Config/AssetPath":15,"../Data/LocalData":32,"../PrefabControl/GamePool":47,"../Time/TimerService":59,"./ResourceControl":28}],28:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=Laya.Handler,i=e("../utils/DispatcherManager"),o=e("../Config/RecConfigs"),r=function(e){function ResourceControl(){var t=e.call(this)||this;return t._groupIndex=0,t.running=!1,t._loadNum=0,t._loadedNum=0,t._preloadNum=0,t._cut=0,t._nowLoadArr=null,ResourceControl.ins=t,t}return __extends(ResourceControl,e),Object.defineProperty(ResourceControl,"Instance",{get:function(){return null==ResourceControl.ins?new ResourceControl:ResourceControl.ins},enumerable:!0,configurable:!0}),ResourceControl.prototype.init=function(){this._configs=new Array,this._groups={},Laya.loader.retryNum=4,Laya.loader.on(Laya.Event.ERROR,this,this.onError),Laya.loader.on("errorsMsg",this,this.errorsMsghandler),Laya.loader.on("gameerrorsMsg",this,this.gameerrorsMsghandler)},ResourceControl.prototype.onLoadConfigComplete=function(){null!=this._onConfigCompleteTarget&&null!=this._onConfigComplete&&this._onConfigComplete.call(this._onConfigCompleteTarget)},ResourceControl.prototype.errorsMsghandler=function(e){i.DispatcherManager.dispatchEvent("loadfailEvent",e)},ResourceControl.prototype.gameerrorsMsghandler=function(e){i.DispatcherManager.dispatchEvent("gameserrosEvent",e)},ResourceControl.prototype.loadGroup=function(e,t,a,n,i,r){void 0===n&&(n=null),void 0===i&&(i=!0),void 0===r&&(r=null);var s={};s.complete=a,s.completeTarget=t,s.progress=n,s.urls=o.RecConfigs.Instance.ResDic[e],s.isShow=i,s.args=r,s.type="group",s.resouseType="2D",this._configs.push(s),this.loadStart()},ResourceControl.prototype.Loader=function(e,t,a,n,i,o,r){void 0===i&&(i=null),void 0===o&&(o=!0),void 0===r&&(r=null);var s={};s.complete=n,s.completeTarget=a,s.progress=i,s.urls=[{url:e,type:t}],s.isShow=o,s.args=r,s.type="single",s.resouseType="2D",this._configs.push(s),this.loadStart()},ResourceControl.prototype.Loaders=function(e,t,a,n,i,o){void 0===n&&(n=null),void 0===i&&(i=!0),void 0===o&&(o=null);var r={};r.complete=a,r.completeTarget=t,r.progress=n,r.urls=e,r.isShow=i,r.type="arr",r.args=o,r.resouseType="2D",this._configs.push(r),this.loadStart()},ResourceControl.prototype.loaderArr=function(e,t,a,n,i){void 0===n&&(n=null),void 0===i&&(i=3);var o={};o.complete=a,o.completeTarget=t,o.progress=n,o.urls=e,o.isShow=!1,o.type="loaderArr",o.cut=i,o.resouseType="2D",this._configs.push(o),this.startLoad1()},ResourceControl.prototype.startLoad1=function(){!this.running&&this._configs.length>0&&(this._nowLoadData=this._configs.shift(),this._nowLoadArr=this._nowLoadData.urls.concat().reverse(),this._loadNum=this._nowLoadArr.length,this._loadedNum=0,this._preloadNum=this._loadedNum,this._cut=Number(this._nowLoadData.cut),this.loadStart1())},ResourceControl.prototype.loadStart1=function(){if(!this.running)if(this._nowLoadArr&&this._nowLoadArr.length>0){var e;this.running=!0,e=this._nowLoadArr.length>this._cut?this._nowLoadArr.splice(0,this._cut):this._nowLoadArr.splice(0),this._cut=e.length,this._preloadNum=this._loadedNum,this.onLoadingArr(0);var t=this._nowLoadData.resouseType;"2D"==t||null==t?Laya.loader.load(e,n.create(this,this.onLoadCompleteArr),n.create(this,this.onLoadingArr,null,!1)):Laya.loader.create(e,n.create(this,this.onLoadCompleteArr),n.create(this,this.onLoadingArr,null,!1))}else this._nowLoadData=null,this.startLoad1()},ResourceControl.prototype.onLoadingArr=function(e){if(this._loadedNum=this._preloadNum+e*this._cut,this._nowLoadData){var t=Math.ceil(this._loadedNum/this._loadNum*100);null!=this._nowLoadData.progress&&this._nowLoadData.progress.call(this._nowLoadData.completeTarget,t,Math.floor(100*e))}},ResourceControl.prototype.onLoadCompleteArr=function(){this.onLoadingArr(1),this._loadedNum=this._preloadNum+this._cut,this.running=!1,this._loadedNum==this._loadNum&&this._nowLoadData&&this._nowLoadData.complete&&this._nowLoadData.complete.call(this._nowLoadData.completeTarget),Laya.timer.callLater(this,this.loadStart1)},ResourceControl.prototype.loadStart=function(){if(!this.running&&0!=this._configs.length){this.running=!0,this._nowLoadData=this._configs[0];var e=this._nowLoadData.urls;this._nowLoadData.isShow&&fairygui.GRoot.inst.showModalWait();var t=this._nowLoadData.resouseType;null!=e&&("2D"==t||null==t?Laya.loader.load(e,n.create(this,this.onLoadComplete),n.create(this,this.onLoading,null,!1)):Laya.loader.create(e,n.create(this,this.onLoadComplete),n.create(this,this.onLoading,null,!1)))}},ResourceControl.prototype.onLoading=function(e){this._nowLoadData&&(e=Math.ceil(Number(100*e)),null!=this._nowLoadData.progress&&this._nowLoadData.progress.call(this._nowLoadData.completeTarget,e))},ResourceControl.prototype.onLoadComplete=function(e){void 0===e&&(e=null),fairygui.GRoot.inst.closeModalWait(),this._nowLoadData&&this._nowLoadData.complete&&(this._nowLoadData.args?this._nowLoadData.complete.call(this._nowLoadData.completeTarget,this._nowLoadData.args):this._nowLoadData.complete.call(this._nowLoadData.completeTarget)),this.running=!1,this._nowLoadData=null,this._configs.shift(),this.loadStart()},ResourceControl.prototype.onError=function(e){fairygui.GRoot.inst.closeModalWait()},ResourceControl.prototype.Loader3D=function(e,t,a,n,i,o){void 0===i&&(i=null),void 0===o&&(o=!0);var r={};r.complete=n,r.completeTarget=a,r.progress=i,r.urls=[{url:e,type:t}],r.isShow=o,r.type="single",r.resouseType="3D",this._configs.push(r),this.loadStart()},ResourceControl.prototype.loadGroup3D=function(e,t,a,n,i,r){void 0===n&&(n=null),void 0===i&&(i=!0),void 0===r&&(r=null);var s={};s.complete=a,s.completeTarget=t,s.progress=n,s.urls=o.RecConfigs.Instance.ResDic[e],s.isShow=i,s.args=r,s.type="group",s.resouseType="3D",this._configs.push(s),this.loadStart()},ResourceControl.prototype.loader3DArr=function(e,t,a,n,i,o){void 0===n&&(n=null),void 0===i&&(i=!1),void 0===o&&(o=null);var r={};r.complete=a,r.completeTarget=t,r.progress=n,r.urls=e,r.isShow=i,r.args=o,r.type="loaderArr",r.resouseType="3D",this._configs.push(r),this.loadStart()},ResourceControl.prototype.loadEffect=function(e,t,a,i){void 0===i&&(i=null);var r=o.RecConfigs.Instance.ResDic[e];r&&r.length>0&&Laya.loader.load(r,n.create(t,a,[i]))},ResourceControl}(Laya.EventDispatcher);a.ResourceControl=r},{"../Config/RecConfigs":16,"../utils/DispatcherManager":85}],29:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./LayoutControl"),i=e("../Config/AssetPath"),o=e("../Game/CameraManager"),r=e("../PrefabControl/PropManager"),s=e("../Game/Player"),l=e("../utils/DispatcherManager"),c=e("../utils/GameState"),h=e("../Agency/AgencyUserMessage"),u=e("../PrefabControl/PanelResDic"),p=e("../utils/GameUtils"),d=e("../CFG/NpcCFG"),m=e("../Game/NpcScript"),f=e("./ResourceControl"),g=e("../CFG/GameCFG"),y=e("../PrefabControl/CharacterState"),C=e("../Data/UserInfoEvent"),_=e("../PrefabControl/CharacterPool"),v=Laya.Sprite,w=Laya.Event,S=function(){function SceneControl(){this._initPosY=1,this.index=0,this.preRadian=0,SceneControl.ins=this}return Object.defineProperty(SceneControl,"Instance",{get:function(){return null==SceneControl.ins?new SceneControl:SceneControl.ins},enumerable:!0,configurable:!0}),SceneControl.prototype.CreatePlayer=function(e){var t=!1;r.PropManager.mainRole?r.PropManager.mainRole.name!="Character"+e.name&&(t=!0,this.ClearMomentCharacter()):t=!0,t&&(r.PropManager.mainRole=_.CharacterPool.AddCharacter(e.name,s.Player,r.PropManager.scene3D),r.PropManager.mainRole.name="Character"+e.name,this.PlayerScript=r.PropManager.mainRole.getComponent(s.Player));var a,n=u.PanelResDic.Instance.getSingleTon(h.AgencyUserMessage).RoleData,i=n.levelcfg.roleinitpos,o=p.GameUtils.cutstrtoArr(i.offsetPos),l=new Laya.Vector3(Number(o[0]),Number(o[1]),Number(o[2])),c=new Laya.Vector3;if("startpanel"==i.initbuild)c.x=r.PropManager.startPlane.transform.position.x+l.x,c.y=r.PropManager.startPlane.transform.position.y+l.y,c.z=r.PropManager.startPlane.transform.position.z+l.z,a=r.PropManager.startPlane.getChildByName("child_pos").transform.position;else{var d=r.PropManager.getPosVecbyScene(n.levelmapArr[0],i.initbuild);c.x=d.x+l.x,c.y=d.y+l.y,c.z=d.z+l.z,a=d}r.PropManager.mainRole.transform.position=c,this.cameraScript.SetCameraPosition(r.PropManager.mainRole.transform.position),this.PlayerScript.setnowSelectVec(a),this.PlayerScript.nowAction=y.CharacterState.stand,this.PlayerScript.PlayAnimator(y.CharacterState.stand)},SceneControl.prototype.createNpc=function(){console.log("CreatNpc---"),this.ClearNpc();var e,t=u.PanelResDic.Instance.getSingleTon(h.AgencyUserMessage).RoleData.levelcfg.npc,a=0;for(var n in r.PropManager.npcnum=t.length,t){e=t[n];var o=null,s=d.default.dict[e.id],l=(Laya.Loader.getRes(i.AssetPath.get3DRoleModel(s.name)),p.GameUtils.cutstrtoArr(e.offsetPos)),c=new Laya.Vector3(Number(l[0]),Number(l[1]),Number(l[2])),f=new Laya.Vector3;if("startpanel"==e.scene)f.x=r.PropManager.startPlane.transform.position.x+c.x,f.y=r.PropManager.startPlane.transform.position.y+1+c.y,f.z=r.PropManager.startPlane.transform.position.z+c.z,o=r.PropManager.startPlane.getChildByName("child_pos").transform.position;else{var g=r.PropManager.getPosVecbyScene(e.scene,e.initbuild);f.x=g.x+c.x,f.y=g.y+c.y,f.z=g.z+c.z,o=g}var C=_.CharacterPool.AddCharacter(s.name,m.NpcScript,r.PropManager.scene3D);C.name="npc_"+a,C.transform.position=f;var v=C.getComponent(m.NpcScript);v.setnowSelectVec(o),v.npcinfo(s),r.PropManager.npcDict[C.name]=C,r.PropManager.npcscriptDict[C.name]=v,v.PlayAnimator(y.CharacterState.stand),a++}console.log("CreatNpc2---")},SceneControl.prototype.ShowUI=function(e){var t=e.transform.position,a=new Laya.Text;p.GameUtils.randRangeint(1,30);a.text="npc_"+this.index,a.fontSize=60,a.color="#ffffff",a.scaleX=.5,a.scaleY=.5,a.align="center",a.valign="middle",Laya.stage.addChild(a),Laya.timer.frameLoop(1,this,function(){var e=new Laya.Vector3;r.PropManager.carma.worldToViewportPoint(t,e),a.pos(e.x,e.y+20)}),this.index++},SceneControl.prototype.ShowTheGameScene=function(){var e=[],t=[];this.cameraScript.iscanfollow=!0;var a=u.PanelResDic.Instance.getSingleTon(h.AgencyUserMessage).RoleData,n=a.levelmapArr,o=0;for(o=0;o<n.length;o++)-1==t.indexOf(i.AssetPath.get3DModel(n[o]))&&t.push(i.AssetPath.get3DModel(n[o]));var r=a.levelcfg.npc;for(o=0;o<r.length;o++)-1==t.indexOf(i.AssetPath.get3DRoleModel(d.default.dict[r[o].id].name))&&t.push(i.AssetPath.get3DRoleModel(d.default.dict[r[o].id].name));for(o=0;o<t.length;o++)e.push({url:t[o]});f.ResourceControl.Instance.loader3DArr(e,this,this.SceneCreatComplete,null,!0)},SceneControl.prototype.SceneCreatComplete=function(){this.RefreshTerrain();var e=u.PanelResDic.Instance.getSingleTon(h.AgencyUserMessage).RoleData;this.CreatePlayer(e.roleCfg),this.createNpc()},SceneControl.prototype.ListenOnEvent=function(){l.DispatcherManager.addEventListener(c.GameState.start,this,this.EnterGame),l.DispatcherManager.addEventListener(c.GameState.jump,this,this.Jump),l.DispatcherManager.addEventListener(C.UserInfoEvent.userinfoEvent_updateroleid,this,this.RefreshCharacterModel)},SceneControl.prototype.CharacterLoadEnd=function(e){var t=u.PanelResDic.Instance.getSingleTon(h.AgencyUserMessage).RoleData;i.AssetPath.get3DModel(t.roleCfg.name)==e&&this.CreatePlayer(t.roleCfg)},SceneControl.prototype.Jump=function(){this.PlayerScript.TestJump()},SceneControl.prototype.setup=function(){this.createSprite(),Laya.stage.on(w.MOUSE_UP,this,this.onMouseUp),Laya.stage.on(w.MOUSE_OUT,this,this.onMouseUp)},SceneControl.prototype.createSprite=function(){this.sp=new v;this.sp.graphics.drawRect(0,0,200,300,"#FF7F50"),this.sp.size(200,300),this.sp.pivot(100,150),this.sp.pos(Laya.stage.width/2,Laya.stage.height/2),Laya.stage.addChild(this.sp),this.sp.on(w.MOUSE_DOWN,this,this.onMouseDown)},SceneControl.prototype.onMouseDown=function(e){var t=e.touches;t&&2==t.length&&(this.preRadian=Math.atan2(t[0].stageY-t[1].stageY,t[0].stageX-t[1].stageX),Laya.stage.on(w.MOUSE_MOVE,this,this.onMouseMove))},SceneControl.prototype.onMouseMove=function(e){var t=e.touches;if(t&&2==t.length){var a=Math.atan2(t[0].stageY-t[1].stageY,t[0].stageX-t[1].stageX);this.sp.rotation+=180/Math.PI*(a-this.preRadian),this.preRadian=a}},SceneControl.prototype.onMouseUp=function(e){Laya.stage.off(w.MOUSE_MOVE,this,this.onMouseMove)},SceneControl.prototype.EnterGame=function(e){this.PlayerScript.startRun(e);var t=r.PropManager.npcscriptDict;for(var a in t){t[a].startRun()}},SceneControl.prototype.ClearMomentCharacter=function(){r.PropManager.mainRole&&this.PlayerScript&&(_.CharacterPool.ClearCharacter(r.PropManager.mainRole,this.PlayerScript.resouseName,this.PlayerScript),this.PlayerScript=null,r.PropManager.mainRole=null)},SceneControl.prototype.SetScene=function(){var e=n.LayoutControl.Instance.background.displayObject,t=fairygui.UIPackage.createObject("main","gambg");t.setSize(fairygui.GRoot.inst.width,fairygui.GRoot.inst.height),n.LayoutControl.Instance.background.addChild(t),r.PropManager.scene3D=e.addChild(new Laya.Scene3D),r.PropManager.scene3D.physicsSimulation.continuousCollisionDetection=!0,r.PropManager.carma=r.PropManager.scene3D.addChild(new Laya.Camera(0,.1,70)),this.cameraScript=r.PropManager.carma.addComponent(o.CameraManager),r.PropManager.carma.clearFlag=Laya.BaseCamera.CLEARFLAG_DEPTHONLY;var a=Laya.Loader.getRes(i.AssetPath.get3DModel("DirectionalLight"));r.PropManager.scene3D.addChild(a),r.PropManager.startPlane=Laya.Loader.getRes(i.AssetPath.get3DModel("startpanel")),r.PropManager.scene3D.addChild(r.PropManager.startPlane),r.PropManager.endPlane=Laya.Loader.getRes(i.AssetPath.get3DModel("endpanel")),r.PropManager.scene3D.addChild(r.PropManager.endPlane),r.PropManager.scene3D.enableFog=!0;p.GameUtils.cutstrtoArr(g.default.dict[2].value);if(g.default.dict[8]){var s=p.GameUtils.cutstrtoArr(g.default.dict[8].value);r.PropManager.scene3D.fogColor=new Laya.Vector3(Number(s[0]),Number(s[1]),Number(s[2]))}else r.PropManager.scene3D.fogColor=new Laya.Vector3(0,0,.6);var l=p.GameUtils.cutstrtoArr(g.default.dict[3].value);r.PropManager.scene3D.fogStart=Number(l[0]),r.PropManager.scene3D.fogRange=Number(l[1]),this.ShowTheGameScene(),this.ListenOnEvent()},SceneControl.prototype.ClearNpc=function(){var e,t=r.PropManager.npcDict;for(e in t){var a=t[e],n=r.PropManager.npcscriptDict[e],i=n.resouseName;_.CharacterPool.ClearCharacter(a,i,n),delete r.PropManager.npcscriptDict[e],delete t[e]}},SceneControl.prototype.Pattern=function(e){console.log("Pattern1----"),r.PropManager.patternDict[e.name]&&delete r.PropManager.patternDict[e.name];for(var t,a,n=e.getChildByName("Blocks"),o={},s=0;n.getChildByName("build_all_"+s);)t=(a=n.getChildByName("build_all_"+s)).getChildByName("child_pos"),o["build_all_"+s]=t.transform.position,r.PropManager.diePosY>a.transform.position.y&&(r.PropManager.diePosY=a.transform.position.y),s++;for(s=0;n.getChildByName("build_front_"+s);)t=(a=n.getChildByName("build_front_"+s)).getChildByName("child_pos"),o["build_front_"+s]=t.transform.position,r.PropManager.diePosY>a.transform.position.y&&(r.PropManager.diePosY=a.transform.position.y),s++;for(s=0;n.getChildByName("build_left_"+s);)t=(a=n.getChildByName("build_left_"+s)).getChildByName("child_pos"),o["build_left_"+s]=t.transform.position,r.PropManager.diePosY>a.transform.position.y&&(r.PropManager.diePosY=a.transform.position.y),s++;for(s=0;n.getChildByName("build_right_"+s);)t=(a=n.getChildByName("build_right_"+s)).getChildByName("child_pos"),o["build_right_"+s]=t.transform.position,r.PropManager.diePosY>a.transform.position.y&&(r.PropManager.diePosY=a.transform.position.y),s++;for(s=0;n.getChildByName("build_frontleft_"+s);)t=(a=n.getChildByName("build_frontleft_"+s)).getChildByName("child_pos"),o["build_frontleft_"+s]=t.transform.position,r.PropManager.diePosY>a.transform.position.y&&(r.PropManager.diePosY=a.transform.position.y),s++;for(s=0;n.getChildByName("build_frontright_"+s);)t=(a=n.getChildByName("build_frontright_"+s)).getChildByName("child_pos"),o["build_frontright_"+s]=t.transform.position,r.PropManager.diePosY>a.transform.position.y&&(r.PropManager.diePosY=a.transform.position.y),s++;for(s=0;n.getChildByName("build_leftright_"+s);)t=(a=n.getChildByName("build_leftright_"+s)).getChildByName("child_pos"),o["build_leftright_"+s]=t.transform.position,r.PropManager.diePosY>a.transform.position.y&&(r.PropManager.diePosY=a.transform.position.y),s++;s=0;for(var l,c=e.getChildByName("Props");c.getChildByName("Scaffolding_"+s);)t=c.getChildByName("Scaffolding_"+s).getChildByName("child_pos"),o["Scaffolding_"+s]=t.transform.position,s++;for(s=0;c.getChildByName("grilling_"+s);)t=c.getChildByName("grilling_"+s).getChildByName("child_pos"),o["grilling_"+s]=t.transform.position,s++;s=0;for(var p=u.PanelResDic.Instance.getSingleTon(h.AgencyUserMessage).RoleData.LevelID<3;c.getChildByName("JumpBoost_"+s);){if(l=c.getChildByName("JumpBoost_"+s),p){var d=l.transform.position.clone();d.y+=3;var m=Laya.Sprite3D.instantiate(Laya.loader.getRes(i.AssetPath.get3DRoleModel("Arrow")),r.PropManager.scene3D,!1,d);r.PropManager.jiantouArr.push(m)}s++}r.PropManager.patternDict[e.name]=o,console.log("Pattern2----")},SceneControl.prototype.onSpriteClick=function(e){Math.random()},SceneControl.prototype.onRotate=function(e){Laya.Tween.to(this.sp,{rotation:e},1e3,Laya.Ease.elasticOut)},SceneControl.prototype.RefreshCharacterModel=function(){var e=u.PanelResDic.Instance.getSingleTon(h.AgencyUserMessage).RoleData,t=[];t.push({url:i.AssetPath.get3DRoleModel(e.roleCfg.name)}),f.ResourceControl.Instance.loader3DArr(t,this,this.CharacterLoadEnd,null,!0,i.AssetPath.get3DModel(e.roleCfg.name))},SceneControl.prototype.RefreshTerrain=function(){var e,t,a,n=u.PanelResDic.Instance.getSingleTon(h.AgencyUserMessage).RoleData,o=n.levelcfg,s=n.levelmapArr;for(var l in r.PropManager.nowmapDict)r.PropManager.nowmapDict[l].active=!1;for(var c=0;c<s.length;c++){if(t=s[c],console.log("mapname1----",t),r.PropManager.nowmapDict[t])(e=r.PropManager.nowmapDict[t]).active=!0;else{console.log("mapname2----",t);var d=Laya.Loader.getRes(i.AssetPath.get3DModel(t));console.log("mapname3----",t),e=Laya.Sprite3D.instantiate(d,r.PropManager.scene3D,!1,null),console.log("mapname4----",t),r.PropManager.nowmapDict[t]=e,console.log("mapname5----",t)}if(0==c){var m=p.GameUtils.cutstrtoArr(o.firstScenepos);e.transform.position=new Laya.Vector3(Number(m[0]),Number(m[1]),Number(m[2]))}else{var f=a.getChildByName("END").transform.position.clone();f.x=0,f.y=0,e.transform.position=f}this.Pattern(e),a=e;var y=e.getChildByName("END").transform.position.clone();y.z+=Number(g.default.dict[6].value),r.PropManager.endPlane.transform.position=y,r.PropManager.gamewinPosZ=y.z,r.PropManager.gamewinPosZ-=2}},SceneControl.EggGGroup=0,SceneControl.IsShowSign=!1,SceneControl}();a.SceneControl=S},{"../Agency/AgencyUserMessage":8,"../CFG/GameCFG":10,"../CFG/NpcCFG":13,"../Config/AssetPath":15,"../Data/UserInfoEvent":36,"../Game/CameraManager":38,"../Game/NpcScript":39,"../Game/Player":40,"../PrefabControl/CharacterPool":45,"../PrefabControl/CharacterState":46,"../PrefabControl/PanelResDic":48,"../PrefabControl/PropManager":49,"../utils/DispatcherManager":85,"../utils/GameState":86,"../utils/GameUtils":87,"./LayoutControl":22,"./ResourceControl":28}],30:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../PrefabControl/GamePool"),i=function(){function ComponentEventData(){}return ComponentEventData.prototype.listenKeyboard=function(){this.keyDownList=[],Laya.stage.on(Laya.Event.KEY_DOWN,this,this.onKeyDown),Laya.stage.on(Laya.Event.KEY_UP,this,this.onKeyUp)},ComponentEventData.prototype.onKeyDown=function(e){var t=e.keyCode;this.keyDownList[t]=!0},ComponentEventData.prototype.clear=function(){this.target=null,this.type=null,this.thisObject=null,this.listener=null,n.GamePool.RemoveItem(ComponentEventData.ResDicValue,this)},ComponentEventData.prototype.onKeyUp=function(e){delete this.keyDownList[e.keyCode]},ComponentEventData.ResDicValue="ComponentEventData",ComponentEventData}();a.ComponentEventData=i},{"../PrefabControl/GamePool":47}],31:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(e){function DataInfoBase(){return e.call(this)||this}return __extends(DataInfoBase,e),DataInfoBase.prototype.showApe=function(){var e=new Laya.Sprite;Laya.stage.addChild(e),e.loadImage("./res/apes/monkey1.png"),Laya.loader.load("./res/apes/monkey2.png",Laya.Handler.create(this,function(){var e=Laya.loader.getRes("./res/apes/monkey2.png"),t=new Laya.Sprite;Laya.stage.addChild(t),t.graphics.drawTexture(e,100,0)}))},DataInfoBase.prototype.DataInfo=function(e){if(e)for(var t in e){null!=this[t]&&(this[t]=e[t])}},DataInfoBase.prototype.createButton=function(e,t,a,n){var i=new Laya.Button(e,t);return Laya.stage.addChild(i),i.on(Laya.Event.CLICK,this,a),i.size(147,55),i.name=t,i.right=10,i.top=n*(i.height+10),i},DataInfoBase.prototype.dispatchEvent=function(e,t){this.event(e,t)},DataInfoBase}(Laya.EventDispatcher);a.DataInfoBase=n},{}],32:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../PrefabControl/GamePool"),i=Laya.Sprite,o=Laya.Event,r=function(e){function LocalData(){var t=null!==e&&e.apply(this,arguments)||this;return t.ref=0,t.time=0,t.packageName="",t}return __extends(LocalData,e),LocalData.prototype.createCoralRect=function(){var e=new i;e.graphics.drawRect(0,0,Laya.stage.width,Laya.stage.height/2,"#FF7F50"),e.name="珊瑚色容器",e.size(Laya.stage.width,Laya.stage.height/2),Laya.stage.addChild(e),e.on(o.MOUSE_DOWN,this,this.onDown)},LocalData.prototype.createDeepSkyblueRect=function(){var e=new i;e.graphics.drawRect(0,0,100,100,"#00BFFF"),e.name="天蓝色矩形",e.size(100,100),e.pos(10,10),Laya.stage.addChild(e),e.on(o.MOUSE_DOWN,this,this.onDown)},LocalData.prototype.clear=function(){this.ref=0,this.time=0,this.packageName="",n.GamePool.RemoveItem(LocalData.ResDicValue,this)},LocalData.prototype.onDown=function(e){this.logger.text+="点击 - "+e.target.name+"\n"},LocalData.ResDicValue="LocalData",LocalData}(Laya.EventDispatcher);a.LocalData=r},{"../PrefabControl/GamePool":47}],33:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../utils/DispatcherManager"),i=e("../Data/UserInfoEvent"),o=e("../Control/LocalDataControl"),r=e("../Data/UserDataInfo"),s=e("../CFG/RoleCFG"),l=e("../CFG/LevelCFG"),c=e("../utils/GameUtils"),h=e("./DataInfoBase"),u=Laya.Templet,p=Laya.Event,d=function(e){function RoleData(){var t=e.call(this)||this;return t._Gold=0,t._roleid=0,t._leveid=0,t.mStartX=400,t.mStartY=500,t.mActionIndex=0,t.mCurrIndex=0,t.mCurrSkinIndex=0,t.movespeed=0,t.frontjump=new Laya.Vector3,t.leftjump=new Laya.Vector3,t.rightjump=new Laya.Vector3,t.upclimb=0,t.slideclimb=new Laya.Vector3,RoleData.ins=t,t}return __extends(RoleData,e),Object.defineProperty(RoleData,"Instance",{get:function(){return null==RoleData.ins?new RoleData:RoleData.ins},enumerable:!0,configurable:!0}),RoleData.prototype.init=function(){var e=o.LocalDataControl.Instance;this.Money=e.getnum(r.UserDataInfo.gold),this._roleid=e.getnum(r.UserDataInfo.roleid),0==this.CharacterID?this.CharacterID=1:this.InitCharacterInfo(),this._leveid=e.getnum(r.UserDataInfo.levelid),0==this._leveid&&(this._leveid=1),this.RefreshLevel()},Object.defineProperty(RoleData.prototype,"nowlevel",{get:function(){return this._leveid},enumerable:!0,configurable:!0}),RoleData.prototype.getNowServerLevel=function(){return this._leveid},RoleData.prototype.LevelUp=function(){this._leveid++,o.LocalDataControl.Instance.addstr(r.UserDataInfo.levelid,this._leveid.toString()),this.RefreshLevel()},RoleData.prototype.startFun=function(){this.mAniPath="res/spine/spineRes6/alien.sk",this.mFactory=new u,this.mFactory.on(p.COMPLETE,this,this.parseComplete),this.mFactory.on(p.ERROR,this,this.onError),this.mFactory.loadAni(this.mAniPath)},RoleData.prototype.onError=function(){console.log("error")},RoleData.prototype.parseComplete=function(){this.mArmature=this.mFactory.buildArmature(1),this.mArmature.x=this.mStartX,this.mArmature.y=this.mStartY,this.mArmature.scale(.5,.5),Laya.stage.addChild(this.mArmature),this.mArmature.on(p.LABEL,this,this.onEvent),this.play()},RoleData.prototype.RefreshLevel=function(){var e=this._leveid,t=0,a=l.default.vec.length;if(e>a){var o=(e-a)%(a-2);t=0==o?a:o+2}else t=e;this.levelcfg=l.default.dict[t],this.levelmapArr=c.GameUtils.cutstrtoArr(this.levelcfg.road),n.DispatcherManager.dispatchEvent(i.UserInfoEvent.userinfoEvent_levelid)},RoleData.prototype.play=function(){this.mCurrIndex++,this.mCurrIndex>=this.mArmature.getAnimNum()&&(this.mCurrIndex=0),this.mArmature.play(this.mCurrIndex,!1)},RoleData.prototype.onEvent=function(e){Laya.stage.addChild(this.mLabelSprite),this.mLabelSprite.x=this.mStartX,this.mLabelSprite.y=this.mStartY,this.mLabelSprite.graphics.clear()},RoleData.prototype.InitCharacterInfo=function(){this.roleCfg=s.default.dict[this._roleid],this.movespeed=this.roleCfg.speed,this.frontjump=this.roleCfg.frontjump,this.leftjump=this.roleCfg.leftjump,this.rightjump=this.roleCfg.rightjump,this.upclimb=Number(this.roleCfg.upclimb),this.slideclimb=this.roleCfg.slideclimb},Object.defineProperty(RoleData.prototype,"LevelID",{get:function(){return this._leveid},enumerable:!0,configurable:!0}),Object.defineProperty(RoleData.prototype,"CharacterID",{get:function(){return this._roleid},set:function(e){this._roleid!=e&&(this._roleid=e,this.InitCharacterInfo(),o.LocalDataControl.Instance.addstr(r.UserDataInfo.roleid,this._roleid.toString()),n.DispatcherManager.dispatchEvent(i.UserInfoEvent.userinfoEvent_updateroleid))},enumerable:!0,configurable:!0}),Object.defineProperty(RoleData.prototype,"Money",{get:function(){return this._Gold},set:function(e){this._Gold!=e&&(this._Gold=e,o.LocalDataControl.Instance.addstr(r.UserDataInfo.gold,this._Gold.toString()),n.DispatcherManager.dispatchEvent(i.UserInfoEvent.UserInfoEvent_updateUserData))},enumerable:!0,configurable:!0}),RoleData}(h.DataInfoBase);a.RoleData=d},{"../CFG/LevelCFG":11,"../CFG/RoleCFG":14,"../Control/LocalDataControl":23,"../Data/UserDataInfo":35,"../Data/UserInfoEvent":36,"../utils/DispatcherManager":85,"../utils/GameUtils":87,"./DataInfoBase":31}],34:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function SkinData(){this.state=0,this.hasnum=0}return SkinData.prototype.createText=function(){var e=new Laya.Text;e.text="Layabox是HTML5引擎技术提供商与优秀的游戏发行商,面向AS/JS/TS开发者提供HTML5开发技术方案!",e.width=300,e.fontSize=40,e.color="#ffffff",e.wordWrap=!0,e.x=Laya.stage.width-e.textWidth>>1,e.y=Laya.stage.height-e.textHeight>>1,Laya.stage.addChild(e)},SkinData}();a.SkinData=n},{}],35:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=Laya.Event,i=function(){function UserDataInfo(){}return UserDataInfo.prototype.onCallLater=function(){console.log("onCallLater triggered");var e=new Laya.Text;e.font="SimHei",e.fontSize=30,e.color="#FFFFFF",e.text="打开控制台可见该函数仅触发了一次",e.size(Laya.stage.width,Laya.stage.height),e.wordWrap=!0,e.valign="middle",e.align="center",Laya.stage.addChild(e)},UserDataInfo.prototype.onDecreaseAlpha1=function(e){this.button1.off(n.CLICK,this,this.onDecreaseAlpha1),Laya.timer.once(3e3,this,this.onComplete1)},UserDataInfo.prototype.onDecreaseAlpha2=function(e){this.button2.off(n.CLICK,this,this.onDecreaseAlpha2),Laya.timer.frameOnce(60,this,this.onComplete2)},UserDataInfo.prototype.onComplete1=function(){this.button1.alpha-=.5},UserDataInfo.prototype.onComplete2=function(){this.button2.alpha-=.5},UserDataInfo.lasttime="lasttime",UserDataInfo.caplastflushtime="captime",UserDataInfo.capstorageappids="capappids",UserDataInfo.hasgetappids="hasgetappids",UserDataInfo.roleData="roleData",UserDataInfo.gold="gold",UserDataInfo.roleid="roleid",UserDataInfo.levelid="levelid",UserDataInfo.skin="skin",UserDataInfo.lastDay="lastDay",UserDataInfo.nowdayShare="dayshare",UserDataInfo.nowdayVideo="dayvideo",UserDataInfo}();a.UserDataInfo=i},{}],36:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function UserInfoEvent(){}return UserInfoEvent.UserInfoEvent_updateUserData="UserInfoEvent_updateUserData",UserInfoEvent.userinfoEvent_updateroleid="userinfoEvent_updateroleid",UserInfoEvent.userinfoEvent_levelid="userinfoEvent_levelid",UserInfoEvent.updatePlayerInfo="UserInfoEvent_updatePlayerInfo",UserInfoEvent}();a.UserInfoEvent=n},{}],37:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./Global"),i=e("./PrefabControl/PanelResDic"),o=e("./utils/DispatcherManager"),r=e("./Data/ComponentEventData"),s=e("./Config/RecConfigs"),l=e("./Time/TimesTamper"),c=e("./Config/AssetPath"),h=e("./Time/TimerService"),u=e("./GlobalWaiting"),p=e("./Control/PanelBaseControl"),d=e("./PrefabControl/GamePool"),m=e("./Control/LayoutControl"),f=e("./View/ViewManager"),g=e("./Control/ResourceControl"),y=e("./Control/ResDataControl"),C=e("./Control/AudioControl"),_=e("./Control/ConnectControl"),v=e("./WXSDK/pingtaiutils"),w=e("./Agency/AgencyLogin"),S=e("./Agency/AgencyUserMessage"),P=e("./Agency/AgencyMain"),b=e("./Agency/AgencyInGame"),A=e("./Agency/AgencySkin"),L=e("./Agency/AgencyTrial"),D=e("./Agency/AgencyLottery"),G=function(e){function GameContents(){return e.call(this)||this}return __extends(GameContents,e),GameContents.prototype.initGame=function(){s.RecConfigs.Instance.init(),o.DispatcherManager.init(),h.TimerService.Instance.init(),m.LayoutControl.Instance.initlayer(),f.ViewManager.Instance.init(),g.ResourceControl.Instance.init(),y.ResDataControl.Instance.init(),C.AudioControl.Instance.init(),_.ConnectControl.Connnect(),l.TimesTamper.Instance.init(),v.pingtaiutils.Instance.init(),this.initPoolObject(),this.initProxy(),this.initmapView(),this.beginLoadHandler()},GameContents.prototype.initPoolObject=function(){d.GamePool.Mark(r.ComponentEventData.ResDicValue,r.ComponentEventData)},GameContents.prototype.initProxy=function(){var e=i.PanelResDic.Instance;e.AgencyAdd(w.AgencyLogin),e.AgencyAdd(S.AgencyUserMessage),e.AgencyAdd(P.AgencyMain),e.AgencyAdd(b.AgencyInGame),e.AgencyAdd(A.AgencySkin),e.AgencyAdd(L.AgencyTrial),e.AgencyAdd(D.AgencyLottery)},GameContents.prototype.initmapView=function(){i.PanelResDic.Instance},GameContents.prototype.beginLoadHandler=function(){var e=[];e.push({url:c.AssetPath.getResConfig(),type:Laya.Loader.JSON}),e.push({url:c.AssetPath.getGameVersion(),type:Laya.Loader.JSON}),g.ResourceControl.Instance.Loaders(e,this,this.recloadComplete)},GameContents.prototype.recloadComplete=function(){var e=y.ResDataControl.Instance.GainResources(c.AssetPath.getGameVersion(),!1);n.Global.gameVersion=e?e.version:"1.0.0";var t=y.ResDataControl.Instance.GainResources(c.AssetPath.getResConfig(),!1);s.RecConfigs.Instance.initRec(t),g.ResourceControl.Instance.loadGroup("loading",this,this.onPreLoaded,this.onPreprogress)},GameContents.prototype.onPreprogress=function(e){},GameContents.prototype.onPreLoaded=function(){y.ResDataControl.Instance.AddViewPackByName("loading",!0,!1);var e=fairygui.UIPackage.getItemURL("loading","globalWaiting");p.PanelBaseControl.viewbgUrl=fairygui.UIPackage.getItemURL("loading","img_black"),fairygui.UIObjectFactory.setPackageItemExtension(e,u.GlobalWaiting),fairygui.UIConfig.globalModalWaiting=e,fairygui.UIConfig.windowModalWaiting=e,this.Login()},GameContents.prototype.Login=function(){i.PanelResDic.Instance.getSingleTon(w.AgencyLogin).Login()},GameContents}(Laya.EventDispatcher);a.GameContents=G},{"./Agency/AgencyInGame":2,"./Agency/AgencyLogin":3,"./Agency/AgencyLottery":4,"./Agency/AgencyMain":5,"./Agency/AgencySkin":6,"./Agency/AgencyTrial":7,"./Agency/AgencyUserMessage":8,"./Config/AssetPath":15,"./Config/RecConfigs":16,"./Control/AudioControl":18,"./Control/ConnectControl":19,"./Control/LayoutControl":22,"./Control/PanelBaseControl":24,"./Control/ResDataControl":27,"./Control/ResourceControl":28,"./Data/ComponentEventData":30,"./Global":41,"./GlobalWaiting":42,"./PrefabControl/GamePool":47,"./PrefabControl/PanelResDic":48,"./Time/TimerService":59,"./Time/TimesTamper":60,"./View/ViewManager":70,"./WXSDK/pingtaiutils":82,"./utils/DispatcherManager":85}],38:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../PrefabControl/PropManager"),i=e("../utils/GameUtils"),o=e("../CFG/GameCFG"),r=Laya.Sprite,s=Laya.TiledMap,l=Laya.Point,c=Laya.Rectangle,h=Laya.Handler,u=function(e){function CameraManager(){var t=e.call(this)||this;return t.iscanfollow=!1,t._upvec=new Laya.Vector3(0,1,0),t._index=0,t._slerpValue=8,t._lookatVec=new Laya.Vector3,t}return __extends(CameraManager,e),CameraManager.prototype.onAwake=function(){this.camera=this.owner,this._toVec=new Laya.Vector3,this.camera.fieldOfView=90},CameraManager.prototype.onStart=function(){this._transform=this.camera.transform,this._transform.rotate(new Laya.Vector3(0,0,0),!0,!1)},CameraManager.prototype.createMap=function(){this.tiledMap=new s,this.tiledMap.createMap("res/tiledMap/isometric_grass_and_water.json",new c(0,0,Laya.stage.width,Laya.stage.height),h.create(this,this.mapLoaded),null,new l(1600,800))},CameraManager.prototype.onStageClick=function(){var e=new l(0,0);this.layer.getTilePositionByScreenPos(Laya.stage.mouseX,Laya.stage.mouseY,e),this.layer.getScreenPositionByTilePos(Math.floor(e.x),Math.floor(e.y),e),this.sprite.pos(e.x,e.y)},CameraManager.prototype.mapLoaded=function(){this.layer=this.tiledMap.getLayerByIndex(0);var e=32*Math.tan(180/Math.PI*30);this.sprite=new r,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)},CameraManager.prototype.onUpdate=function(){this.iscanfollow&&(n.PropManager.iscarmanpc?n.PropManager.npcDict.npc_0&&(Laya.Vector3.add(n.PropManager.npcDict.npc_0.transform.position,this._disVector,this._toVec),this._transform.position=this._toVec,this._transform.position.x=n.PropManager.npcDict.npc_0.transform.position.x,this._transform.lookAt(n.PropManager.npcDict.npc_0.transform.position,this._upvec)):n.PropManager.mainRole&&(Laya.Vector3.add(n.PropManager.mainRole.transform.position,this._disVector,this._toVec),Laya.Vector3.lerp(this._transform.position,this._toVec,.016*this._slerpValue,this._toVec),this._transform.position=this._toVec,this._lookatVec.x=this._toVec.x,this._lookatVec.y=n.PropManager.mainRole.transform.position.y,this._lookatVec.z=n.PropManager.mainRole.transform.position.z,this._transform.lookAt(this._lookatVec,this._upvec)))},CameraManager.prototype.GameEndRotate=function(e,t){this.iscanfollow=!1,this._transform.translate(t,!1),this._transform.lookAt(e,this._upvec)},CameraManager.prototype.SetCameraPosition=function(e){var t=i.GameUtils.cutstrtoArr(o.default.dict[1].value);this._disVector=new Laya.Vector3(Number(t[0]),Number(t[1]),Number(t[2])),Laya.Vector3.add(e,this._disVector,this._toVec),this.camera.transform.position=this._toVec,this.camera.transform.position.x=e.x},CameraManager}(Laya.Script3D);a.CameraManager=u},{"../CFG/GameCFG":10,"../PrefabControl/PropManager":49,"../utils/GameUtils":87}],39:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Time/TimerService"),i=e("../PrefabControl/PropManager"),o=e("../PrefabControl/CharacterState"),r=e("../CFG/BuildCFG"),s=e("./CameraManager"),l=e("../utils/DispatcherManager"),c=e("../utils/GameState"),h=e("../utils/GameUtils"),u=e("../Control/AssetManager"),p=e("../Control/PoolManager"),d=function(e){function NpcScript(){var t=e.call(this)||this;return t._nowAction="",t.resouseName="",t._shangpaVec=new Laya.Vector3,t.haveCollision=!1,t._TargetCollision="",t._normalizeVec=new Laya.Vector3,t.staybuild="",t.stayscene="",t._lockxstate=0,t._nowRoleState=0,t.movespeed=0,t.frontjumpspeed=new Laya.Vector3,t.leftjumpspeed=new Laya.Vector3,t.rightjumpspeed=new Laya.Vector3,t.climbspeed=0,t.sideclimbspeed=new Laya.Vector3,t._lockbyBuildname="",t._lockstate=0,t.LastAction="",t._moveTime=0,t._chixuTime=0,t._isActionNums=!1,t._isneedactionnum=0,t._needactiontime=0,t.NowLastActionState="",t._moveVec=new Laya.Vector3,t.jumpSpeed=new Laya.Vector3,t.jumpHight=0,t._disy=0,t.Gravity_g=10,t._checktime=0,t._ending=!1,t._endAnmoSpeed=new Laya.Vector3,t._endanmotime=1,t._endAnmoSpeed1=new Laya.Vector3,t._changeMoveX=0,t.HaveForceJump=!1,t.quaternion=new Laya.Quaternion,t}return __extends(NpcScript,e),NpcScript.prototype.onAwake=function(){this._animator=this.owner.getComponent(Laya.Animator),i.PropManager.setAnimator(this._animator)},NpcScript.prototype.onStart=function(){this._speedMoveV3=new Laya.Vector3(0,0,0),this._transform=this.owner.transform;var e=this.owner,t=e.getChildByName("lefttrail"),a=e.getChildByName("righttrail");console.log();var n=h.GameUtils.randRangeint(0,u.AssetManager.AllMapDic.length-1);n%=u.AssetManager.AllMapDic.length;var i=u.AssetManager.AllMapDic[n];this.LeftTrial=p.default.GetSprite3D(i),t.parent.addChild(this.LeftTrial),this.LeftTrial.transform.localPosition=t.transform.localPosition.clone(),this.LeftTrial.transform.localRotationEuler=t.transform.localRotationEuler.clone(),this.LeftTrial.transform.localScale=new Laya.Vector3(.001,.001,.001),this.RightTrial=p.default.GetSprite3D(i),a.parent.addChild(this.RightTrial),this.RightTrial.transform.localPosition=a.transform.localPosition.clone(),this.RightTrial.transform.localRotationEuler=a.transform.localRotationEuler.clone(),this.RightTrial.transform.localScale=new Laya.Vector3(.001,.001,.001),a.active=!1,t.active=!1,console.log(e.name)},NpcScript.prototype.startRun=function(){this._nowNpcinfo.gravity?this.Gravity_g=this._nowNpcinfo.gravity:this.Gravity_g=10,this._checktime=500,this._nowRoleState=1,this._ending=!1,this._changeMoveX=0,this._initPosVec=this._transform.position.clone(),this.staybuild="",this.stayscene="",this._nowAction=o.CharacterState.stand,this.nowAction=o.CharacterState.run,this._speedMoveV3.x=0,this._speedMoveV3.y=0,this._speedMoveV3.z=-this.movespeed,this._iscanMove=!0,n.TimerService.Instance.addUpdateTarget(this)},NpcScript.prototype.npcinfo=function(e){this._nowNpcinfo=e,this.movespeed=this._nowNpcinfo.speed,this.climbspeed=Number(this._nowNpcinfo.upclimb),this.frontjumpspeed=new Laya.Vector3(Number(this._nowNpcinfo.frontjump.x),Number(this._nowNpcinfo.frontjump.y),Number(this._nowNpcinfo.frontjump.z)),this.leftjumpspeed=new Laya.Vector3(Number(this._nowNpcinfo.leftjump.x),Number(this._nowNpcinfo.leftjump.y),Number(this._nowNpcinfo.leftjump.z)),this.rightjumpspeed=new Laya.Vector3(Number(this._nowNpcinfo.rightjump.x),Number(this._nowNpcinfo.rightjump.y),Number(this._nowNpcinfo.rightjump.z)),this.sideclimbspeed=new Laya.Vector3(Number(this._nowNpcinfo.slideclimb.x),Number(this._nowNpcinfo.slideclimb.y),Number(this._nowNpcinfo.slideclimb.z))},NpcScript.prototype.onCollisionEnter=function(e){if(e&&e.contacts&&e.contacts.length>0&&e.other){var t=e.contacts[0];this.Calculate(t.normal,e.other.owner)}},NpcScript.prototype.setnowSelectVec=function(e){this._nowselectVec=e},NpcScript.prototype.Calculate=function(e,t){if("SliderBoost"!=t.name&&-1==t.name.indexOf("npc")&&-1==t.name.indexOf("role")){this._TargetCollision=t.name;new Laya.Vector3;Laya.Vector3.normalize(e,this._normalizeVec),-1!=this._TargetCollision.indexOf("build")||-1!=this._TargetCollision.indexOf("Scaffolding")||-1!=this._TargetCollision.indexOf("irongauze")?(-1!=this._TargetCollision.indexOf("build")&&(this.staybuild=this._TargetCollision,this.stayscene=t.parent.parent.name),-1!=this._TargetCollision.indexOf("irongauze")?this._nowselectVec=i.PropManager.getPosVecbyScene(t.parent.parent.parent.name,t.parent.name):this._nowselectVec=i.PropManager.getPosVecbyScene(t.parent.parent.name,this._TargetCollision),-1==this._normalizeVec.z?this._nowselectVec&&this._transform.position.y>this._nowselectVec.y-.1?(this._transform.position=new Laya.Vector3(this._transform.position.x,this._nowselectVec.y,this._transform.position.z),this.nowAction=o.CharacterState.run):(this.nowAction=o.CharacterState.climbup,this._shangpaVec=this._nowselectVec.clone()):1==this._normalizeVec.y||-1==this._normalizeVec.y?this.nowAction=o.CharacterState.run:-1==this._normalizeVec.x?this.nowAction==o.CharacterState.run?this._lockxstate=1:this.nowAction==o.CharacterState.climbup?this._lockxstate=1:this.nowAction=o.CharacterState.climbleft:1==this._normalizeVec.x?this.nowAction==o.CharacterState.run?this._lockxstate=2:this.nowAction==o.CharacterState.climbup?this._lockxstate=2:this.nowAction=o.CharacterState.climbright:1!=this._normalizeVec.z&&(this.nowAction=o.CharacterState.climbupblock,this._shangpaVec=this._nowselectVec.clone())):-1!=this._TargetCollision.indexOf("panel_jump")?this.nowAction=o.CharacterState.speedupjump:-1!=this._TargetCollision.indexOf("panel_downslip")?this.nowAction=o.CharacterState.downmove:-1!=this._TargetCollision.indexOf("box_Board")&&this.nowAction!=o.CharacterState.downmove?-1==this._normalizeVec.z&&(this.nowAction=o.CharacterState.climbup,this._shangpaVec=this._nowselectVec.clone()):-1!=this._TargetCollision.indexOf("box_sidejump")?this.nowAction=o.CharacterState.sidespeedup:-1!=this._TargetCollision.indexOf("box_Surmount")?this.nowAction=o.CharacterState.cross:-1!=this._TargetCollision.indexOf("irongauze")&&(this.nowAction=o.CharacterState.climbup,this._shangpaVec=this._nowselectVec.clone())}},NpcScript.prototype.onCollisionStay=function(e){if(e&&e.contacts&&e.contacts.length>0&&e.other){this.haveCollision=!0;e.contacts[0];var t=e.other.owner,a=t.name;"SliderBoost"!=a&&-1==a.indexOf("npc")&&-1==a.indexOf("role")&&(this._TargetCollision=a),-1==this._TargetCollision.indexOf("build")&&-1==this._TargetCollision.indexOf("Scaffolding")&&-1==this._TargetCollision.indexOf("irongauze")||(-1!=this._TargetCollision.indexOf("build")&&(this.staybuild=this._TargetCollision,this.stayscene=t.parent.parent.name),-1!=this._TargetCollision.indexOf("irongauze")?this._nowselectVec=i.PropManager.getPosVecbyScene(t.parent.parent.parent.name,t.parent.name):this._nowselectVec=i.PropManager.getPosVecbyScene(t.parent.parent.name,this._TargetCollision))}},NpcScript.prototype.onCollisionExit=function(e){if(this.haveCollision=!1,e&&e.contacts&&e.contacts.length>0&&e.other){var t=e.contacts[0];this.CheckEnd(t.normal,e.other.owner)}},NpcScript.prototype.CheckEnd=function(e,t){if("SliderBoost"!=t.name&&-1==t.name.indexOf("npc")&&-1==t.name.indexOf("role"))if(this.HaveForceJump)this.HaveForceJump=!1;else if(this._lockxstate)this._lockxstate=0;else if(this._TargetCollision==t.name&&-1==t.name.indexOf("panel_jump"))switch(this.nowAction){case o.CharacterState.climbup:case o.CharacterState.climbupblock:-1!=this._TargetCollision.indexOf("box_Board")?this.JumpAction(this._changeMoveX):this._changeMoveX>0?this.nowAction=o.CharacterState.jumpright:this._changeMoveX<0&&(this.nowAction=o.CharacterState.jumpleft);break;case o.CharacterState.climbright:case o.CharacterState.climbleft:case o.CharacterState.run:this.JumpAction(this._changeMoveX);break;case o.CharacterState.MoveX:this.JumpAction(this._speedMoveV3.x)}},NpcScript.prototype.JumpAction=function(e,t){if(void 0===t&&(t=!1),e>0)this.nowAction=o.CharacterState.jumpright;else if(e<0)this.nowAction=o.CharacterState.jumpleft;else if(t)if(-1!=this._TargetCollision.indexOf("build")){var a=h.GameUtils.randRangeint(0,100),n=0,i="";switch(-1!=this._TargetCollision.indexOf("leftright")?(n=this._nowNpcinfo.jump_left+this._nowNpcinfo.jump_right,i=(a=h.GameUtils.randRangeint(0,n))<=this._nowNpcinfo.jump_left?"left":"right"):-1!=this._TargetCollision.indexOf("frontright")?(n=this._nowNpcinfo.start_ahead+this._nowNpcinfo.jump_right,i=(a=h.GameUtils.randRangeint(0,n))<=this._nowNpcinfo.start_ahead?"front":"right"):-1!=this._TargetCollision.indexOf("frontleft")?(n=this._nowNpcinfo.start_ahead+this._nowNpcinfo.jump_left,i=(a=h.GameUtils.randRangeint(0,n))<=this._nowNpcinfo.start_ahead?"front":"left"):-1!=this._TargetCollision.indexOf("right")?i="right":-1!=this._TargetCollision.indexOf("left")?i="left":-1!=this._TargetCollision.indexOf("front")?i="front":(n=this._nowNpcinfo.start_ahead+this._nowNpcinfo.jump_left+this._nowNpcinfo.jump_right,i=(a=h.GameUtils.randRangeint(0,n))<=this._nowNpcinfo.start_ahead?"front":a<=this._nowNpcinfo.start_ahead+this._nowNpcinfo.jump_left?"left":"right"),i){case"left":this.nowAction=o.CharacterState.jumpleft;break;case"right":this.nowAction=o.CharacterState.jumpright;break;case"front":default:this.nowAction=o.CharacterState.jump}}else this.nowAction=o.CharacterState.jump;else this.nowAction=o.CharacterState.jump},Object.defineProperty(NpcScript.prototype,"nowAction",{get:function(){return this._nowAction},set:function(e){if(1==this._nowRoleState&&(this._nowAction!=e||this.LastAction==o.CharacterState.speedupjump||this.LastAction==o.CharacterState.jumpright)){switch(this.LastAction=this._nowAction,this._nowAction=e,this._moveTime=0,this._nowAction){case o.CharacterState.stand:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.stand);break;case o.CharacterState.run:if(this.LastAction==o.CharacterState.jump||this.LastAction==o.CharacterState.jumpleft||this.LastAction==o.CharacterState.jumpright)this._isActionNums=!0,this._isneedactionnum=1,h.GameUtils.randRangeint(0,100)<50?this.PlayAnimator(o.CharacterState.land1):this.PlayAnimator(o.CharacterState.land2);else this._isActionNums=!1,this.PlayAnimator(o.CharacterState.run);break;case o.CharacterState.jump:this.PlayAnimator(o.CharacterState.jump),this._isActionNums=!0,this._isneedactionnum=1,this.jumpSpeed.x=this.frontjumpspeed.x,this.jumpSpeed.y=this.frontjumpspeed.y,this.jumpSpeed.z=this.frontjumpspeed.z;break;case o.CharacterState.jumpleft:this.jumpSpeed=this.leftjumpspeed,this._isActionNums=!0,this._isneedactionnum=1,this.PlayAnimator(o.CharacterState.leftjump);break;case o.CharacterState.jumpright:this.jumpSpeed=this.rightjumpspeed,this._isActionNums=!0,this._isneedactionnum=1,this.PlayAnimator(o.CharacterState.rightjump);break;case o.CharacterState.speedupjump:var t=r.default.dict.panel_jump;this.jumpSpeed.x=t.buffx,this.jumpSpeed.y=t.buffy,this.LastAction==o.CharacterState.speedupjump?this.jumpSpeed.z=this.jumpSpeed.z*t.buffz:this.jumpSpeed.z=this._speedMoveV3.z*t.buffz,this.NowLastActionState==e?this.jumpSpeed.y=2*t.buffy:this.jumpSpeed.y=t.buffy,this._isActionNums=!0,this._isneedactionnum=1,h.GameUtils.randRangeint(0,100)<50?this.PlayAnimator(o.CharacterState.highjump1):this.PlayAnimator(o.CharacterState.highjump2);break;case o.CharacterState.downmove:t=r.default.dict.panel_downslip;this.jumpSpeed.x=t.buffx,this.jumpSpeed.y=t.buffy,this.jumpSpeed.z=this._speedMoveV3.z*t.buffz,this._chixuTime=t.time,this._isActionNums=!0,this._isneedactionnum=1,this.PlayAnimator(o.CharacterState.huachan);break;case o.CharacterState.cross:t=r.default.dict.box_Surmount;this.jumpSpeed.x=t.buffx,this.jumpSpeed.y=t.buffy+.5,this.jumpSpeed.z=this._speedMoveV3.z*t.buffz,this._chixuTime=t.time,this._isActionNums=!0,this._isneedactionnum=1,this.PlayAnimator(o.CharacterState.hurdle);break;case o.CharacterState.climbup:case o.CharacterState.climbupblock:this.jumpSpeed.x=0,this.jumpSpeed.y=this.climbspeed,this.jumpSpeed.z=0,this._isActionNums=!1,this.PlayAnimator(o.CharacterState.climbwall);break;case o.CharacterState.climbleft:this.jumpSpeed=new Laya.Vector3(0,this.sideclimbspeed.y,this.sideclimbspeed.z),this._isActionNums=!1,this.PlayAnimator(o.CharacterState.runwallleft);break;case o.CharacterState.climbright:this.jumpSpeed=new Laya.Vector3(0,this.sideclimbspeed.y,this.sideclimbspeed.z),this._isActionNums=!1,this.PlayAnimator(o.CharacterState.runwallright);break;case o.CharacterState.ClimbMotion:this._isActionNums=!0,this._isneedactionnum=0,this._needactiontime=.3,this._moveTime=0,this.PlayAnimator(o.CharacterState.climbend)}this.NowLastActionState=e}},enumerable:!0,configurable:!0}),NpcScript.prototype.update=function(e){if(1==this._nowRoleState)if(16,this._checktime+=16,i.PropManager.iscarmanpc||this._checktime>=500&&(this._checktime=0,this._nowNpcinfo&&i.PropManager.mainRole&&(this._transform.position.z+this._nowNpcinfo.distance<i.PropManager.mainRole.transform.position.z?this._iscanMove=!1:this._iscanMove=!0)),this._iscanMove){var t=.016;switch(this._moveTime+=t,this.nowAction){case o.CharacterState.run:this._moveVec.y=0,this._moveVec.z=t*this._speedMoveV3.z,0==this._lockxstate?this._moveVec.x=this._changeMoveX*t:1==this._lockxstate?this._changeMoveX<0?this._moveVec.x=0:this._moveVec.x=this._changeMoveX*t:2==this._lockxstate&&(this._changeMoveX>0?this._moveVec.x=0:this._moveVec.x=this._changeMoveX*t),this._transform.translate(this._moveVec,!1);break;case o.CharacterState.climbup:this._moveVec.z=0,this._moveVec.y=t*this.jumpSpeed.y,1==this._lockxstate?this._changeMoveX<0?this._moveVec.x=0:this._moveVec.x=this._changeMoveX*t:2==this._lockstate&&this._changeMoveX>0?this._moveVec.x=0:this._moveVec.x=this._changeMoveX*t,this._transform.translate(this._moveVec,!1),this._shangpaVec?this._transform.position.y+1>this._shangpaVec.y&&(this.nowAction=o.CharacterState.ClimbMotion):this._nowselectVec&&this._transform.position.y+1>this._nowselectVec.y&&(this.nowAction=o.CharacterState.ClimbMotion);break;case o.CharacterState.climbupblock:this._moveVec.z=0,this._moveVec.y=t*this.jumpSpeed.y,this._moveVec.x=0,this._transform.translate(this._moveVec,!1),this._shangpaVec?this._transform.position.y+1>this._shangpaVec.y&&(this.nowAction=o.CharacterState.ClimbMotion):this._transform.position.y+1>this._nowselectVec.y&&(this.nowAction=o.CharacterState.ClimbMotion);break;case o.CharacterState.jump:case o.CharacterState.jumpleft:case o.CharacterState.jumpright:case o.CharacterState.speedupjump:this._disy=this.jumpSpeed.y-this.Gravity_g*t,this.jumpSpeed.y=this._disy,this._moveVec.x=this.jumpSpeed.x*t,this._moveVec.y=this._disy*t,this._moveVec.z=this.jumpSpeed.z*t,this._transform.translate(this._moveVec,!1);break;case o.CharacterState.climbleft:case o.CharacterState.climbright:this._moveVec.z=t*this.jumpSpeed.y,this._moveVec.y=this.jumpSpeed.y*t,this._moveVec.x=0,this._transform.translate(this._moveVec,!1);break;case o.CharacterState.MoveX:this._moveVec.z=t*this._speedMoveV3.z,this._moveVec.x=this._speedMoveV3.x*t,this._transform.translate(this._moveVec,!1),this._moveTime>.1&&(this.nowAction=o.CharacterState.run);break;case o.CharacterState.downmove:this._moveVec.y=this.jumpSpeed.x,this._moveVec.x=this.jumpSpeed.y,this._moveVec.z=this.jumpSpeed.z*t,this._transform.translate(this._moveVec,!1),this._moveTime>this._chixuTime&&(this.nowAction=o.CharacterState.run);break;case o.CharacterState.sidespeedup:this._moveVec.y=0,this._moveVec.x=0,this._moveVec.z=this.jumpSpeed.z*t,this._transform.translate(this._moveVec,!1),this._moveTime>this._chixuTime&&this.LastAction==o.CharacterState.climbleft||this.LastAction==o.CharacterState.climbright?this.nowAction=this.LastAction:this.nowAction=o.CharacterState.jump;break;case o.CharacterState.cross:this._disy=this.jumpSpeed.y-this.Gravity_g*t,this.jumpSpeed.y=this._disy,this._moveVec.x=this.jumpSpeed.x*t,this._moveVec.y=this._disy*t,this._moveVec.z=this.jumpSpeed.z*t,this._transform.translate(this._moveVec,!1);break;case o.CharacterState.ClimbMotion:this._nowselectVec&&this._transform.position.y<this._nowselectVec.y&&(this._moveVec.x=0,this._moveVec.y=1/.3*t,this._moveVec.z=0,this._transform.translate(this._moveVec,!1))}if(!this._nowselectVec||this.nowAction!=o.CharacterState.run&&this.nowAction!=o.CharacterState.downmove||this.haveCollision||this._transform.position.z<=this._nowselectVec.z&&(this._changeMoveX>0?this.nowAction=o.CharacterState.jumpright:this._changeMoveX<0?this.nowAction=o.CharacterState.jumpleft:this.nowAction=o.CharacterState.jump),this._transform.position.y<i.PropManager.diePosY&&(""==this.stayscene||""==this.staybuild?this._transform.position=this._initPosVec.clone():this._transform.position=i.PropManager.getPosVecbyScene(this.stayscene,this.staybuild).clone(),this.nowAction=o.CharacterState.run),this._transform.position.z<i.PropManager.gamewinPosZ&&this.Win(),this._isActionNums)if(this._isneedactionnum>0){if(this._animator.getCurrentAnimatorPlayState().normalizedTime>=this._isneedactionnum)switch(this._nowActionName){case o.CharacterState.jump:case o.CharacterState.leftjump:case o.CharacterState.rightjump:case o.CharacterState.highjump1:case o.CharacterState.highjump2:case o.CharacterState.hurdle:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.sky);break;case o.CharacterState.huachan:case o.CharacterState.climbend:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.run),this.nowAction=o.CharacterState.run,this._transform.position=new Laya.Vector3(this._transform.position.x,this._nowselectVec.y,this._transform.position.z);break;case o.CharacterState.land1:case o.CharacterState.land2:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.run)}}else if(0!=this._needactiontime&&this._moveTime>this._needactiontime)switch(this._nowActionName){case o.CharacterState.jump:case o.CharacterState.leftjump:case o.CharacterState.rightjump:case o.CharacterState.highjump1:case o.CharacterState.highjump2:case o.CharacterState.hurdle:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.sky);break;case o.CharacterState.huachan:case o.CharacterState.climbend:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.run),this.nowAction=o.CharacterState.run,this._transform.position=new Laya.Vector3(this._transform.position.x,this._nowselectVec.y,this._transform.position.z)}}else if(this._ending){t=.016;this._moveTime+=t,this._moveTime>=this._endanmotime?this.GameOver():(this._endAnmoSpeed1.x=this._endAnmoSpeed.x*t,this._endAnmoSpeed1.y=this._endAnmoSpeed.y*t,this._endAnmoSpeed1.z=this._endAnmoSpeed.z*t,i.PropManager.carma.getComponent(s.CameraManager).GameEndRotate(this._transform.position,this._endAnmoSpeed1))}},NpcScript.prototype.GameOver=function(){this._ending=!1,n.TimerService.Instance.removeUpdateTarget(this),l.DispatcherManager.dispatchEvent(c.GameState.end)},NpcScript.prototype.Win=function(){n.TimerService.Instance.removeUpdateTarget(this),this._nowRoleState=2,this.PlayAnimator(o.CharacterState.sky),l.DispatcherManager.dispatchEvent(c.GameState.npcend,this.owner.name)},NpcScript.prototype.stop=function(){n.TimerService.Instance.removeUpdateTarget(this)},NpcScript.prototype.destroy=function(){n.TimerService.Instance.removeUpdateTarget(this),e.prototype.destroy.call(this)},NpcScript.prototype.Joy=function(e,t){(this.nowAction==o.CharacterState.run||this.nowAction==o.CharacterState.climbup||o.CharacterState.climbleft||o.CharacterState.climbright)&&(this._changeMoveX=e),this.nowAction==o.CharacterState.climbleft&&this._changeMoveX>0?(this.HaveForceJump=!0,this.nowAction=o.CharacterState.jumpright):this.nowAction==o.CharacterState.climbright&&this._changeMoveX<0&&(this.HaveForceJump=!0,this.nowAction=o.CharacterState.jumpleft),this.nowAction!=o.CharacterState.jump&&this.nowAction!=o.CharacterState.jumpleft&&this.nowAction!=o.CharacterState.jumpright&&this.nowAction!=o.CharacterState.speedupjump||(t=-t*Math.PI/180),Laya.Quaternion.createFromAxisAngle(new Laya.Vector3(0,1,0),t,this.quaternion),Laya.Vector3.transformQuat(this.jumpSpeed,this.quaternion,this.jumpSpeed)},NpcScript.prototype.PlayAnimator=function(e){var t=this.TransitionActionName(e);this._nowActionName=e,this._animator&&(this._nowActionName==o.CharacterState.climbend?this._animator.speed=1.5:this._animator.speed=1,this._animator.play(t,0,0))},NpcScript.prototype.TransitionActionName=function(e){switch(e){case"rollover1":return"cefan1";case"rollover2":return"cefan2";case"runwallleft":return"paoqiangleft";case"rightjump":return"rightjump";case"runwallright":return"paoqiangright";case"leftjump":return"leftjump";case"climbwall":return"paqiang";case"climbend":return"climbend";case"stand":return"stand";case"sky":return"kongzhong";case"land1":return"luodi1";case"land2":return"luodi2";case"highjump1":return"datiao1";case"highjump2":return"datiao2";case"run":return"run";case"jump":return"jump";case"climbup":return"Climb";case"falldown":return"Freefalling";case"climbleft":return"left_climb";case"climbright":return"right_climb";case"jumpright":return"right_jump";case"jumpleft":return"left_jump";case"ClimbMotion":return"PlayPalouAction";case"huachan":return"huachan";case"hurdle":return"kualan";case"speedupjump":return"jiasuJump";case"MoveX":return"xshunyi";case"downmove":return"downSlide";case"sidespeedup":return"slidejiasu";case"cross":return"surmount";case"climbupblock":return"lockclimb"}},NpcScript.prototype.TestJump=function(){this.nowAction=o.CharacterState.jump},NpcScript.prototype.getPostion=function(){return this._transform.position},NpcScript.prototype.getAction=function(){return this._nowRoleState},NpcScript.prototype.onDestroy=function(){console.log("拖尾回收成功----"),p.default.RecoverSprite3D(this.LeftTrial),p.default.RecoverSprite3D(this.RightTrial)},NpcScript}(Laya.Script3D);a.NpcScript=d},{"../CFG/BuildCFG":9,"../Control/AssetManager":17,"../Control/PoolManager":26,"../PrefabControl/CharacterState":46,"../PrefabControl/PropManager":49,"../Time/TimerService":59,"../utils/DispatcherManager":85,"../utils/GameState":86,"../utils/GameUtils":87,"./CameraManager":38}],40:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Time/TimerService"),i=e("../PrefabControl/PropManager"),o=e("../PrefabControl/CharacterState"),r=e("../PrefabControl/PanelResDic"),s=e("../Agency/AgencyUserMessage"),l=e("../CFG/BuildCFG"),c=e("./CameraManager"),h=e("../utils/DispatcherManager"),u=e("../utils/GameState"),p=e("../utils/GameUtils"),d=e("../Control/GameStateControl"),m=e("../Control/AudioControl"),f=e("../WXSDK/WXGamePlatform"),g=e("../WXSDK/PlayerAccount"),y=e("../Control/AssetManager"),C=e("../Control/PoolManager"),_=function(e){function Player(){var t=e.call(this)||this;return t._isActionNums=!1,t._isneedactionnum=0,t._needactiontime=0,t._nowActionState="",t._multiple=new Laya.Vector3(1,1,1),t.LastActionState="",t._moveTime=0,t._lastjiasuState="",t.buff_speeduptime=0,t.canshake=!1,t.shaketime=0,t.doublespeedup=!1,t.resouseName="",t._isColling=!1,t._nowCollTargetName="",t._normalizeVec=new Laya.Vector3,t._nowbuildname="",t._nowscenename="",t._lockxstate=0,t._lockbyBuildname="",t._lockstate=0,t._shangpaVec=new Laya.Vector3,t.NowLastActionState="",t._moveVec=new Laya.Vector3,t.jumpSpeed=new Laya.Vector3,t.jumpHight=0,t._disy=0,t.g=10,t._ending=!1,t._endAnmoSpeed=new Laya.Vector3,t._endanmotime=1,t._endAnmoSpeed1=new Laya.Vector3,t._changeMoveX=0,t.isforceJump=!1,t.quaternion=new Laya.Quaternion,Player.ins=t,t}return __extends(Player,e),Object.defineProperty(Player,"Instance",{get:function(){return null==Player.ins?new Player:Player.ins},enumerable:!0,configurable:!0}),Player.prototype.onAwake=function(){this._animator=this.owner.getComponent(Laya.Animator),i.PropManager.setAnimator(this._animator),this._speedMoveV3=new Laya.Vector3(0,0,0);var e=this.owner;this._transform=e.transform,this._RoleData=r.PanelResDic.Instance.getSingleTon(s.AgencyUserMessage).RoleData,e.getComponent(Laya.Rigidbody3D).ccdMotionThreshold=.001;var t=e.getChildByName("lefttrail"),a=e.getChildByName("righttrail"),n=p.GameUtils.randRangeint(0,y.AssetManager.AllMapDic.length-1);n%=y.AssetManager.AllMapDic.length;var o=y.AssetManager.AllMapDic[n];this.LeftTrial=C.default.GetSprite3D(o),t.parent.addChild(this.LeftTrial),this.LeftTrial.transform.localPosition=t.transform.localPosition.clone(),this.LeftTrial.transform.localRotationEuler=t.transform.localRotationEuler.clone(),this.LeftTrial.transform.localScale=t.transform.localScale.clone(),this.LeftTrial.transform.localScale=new Laya.Vector3(.001,.001,.001),this.RightTrial=C.default.GetSprite3D(o),a.parent.addChild(this.RightTrial),this.RightTrial.transform.localPosition=a.transform.localPosition.clone(),this.RightTrial.transform.localRotationEuler=a.transform.localRotationEuler.clone(),this.RightTrial.transform.localScale=new Laya.Vector3(.001,.001,.001),a.active=!1,t.active=!1},Player.prototype.startRun=function(e){var t=this;this._RoleData.roleCfg.gravity?this.g=this._RoleData.roleCfg.gravity:this.g=10,this._multiple.x=1,this._multiple.y=1,this._multiple.z=1,this.buff_speeduptime=0,this.doublespeedup=!1,this._lastjiasuState="",this._ending=!1,this._changeMoveX=0,this._initPosVec=this._transform.position.clone(),console.log("玩家的初始位置----",this._initPosVec),this._nowbuildname="",this._nowscenename="",this.nowAction=o.CharacterState.run,this._speedMoveV3.x=0,this._speedMoveV3.y=0,e?(this._speedMoveV3.z=2*-this._RoleData.movespeed,Laya.timer.once(3e3,this,function(){t._speedMoveV3.z=-t._RoleData.movespeed})):this._speedMoveV3.z=-this._RoleData.movespeed,this._iscanMove=!0,n.TimerService.Instance.addUpdateTarget(this)},Player.prototype.onCollisionEnter=function(e){if(e&&e.contacts&&e.contacts.length>0&&e.other){var t=e.contacts[0];this.Calculate(t.normal,e.other.owner,t.positionOnB)}},Player.prototype.onCollisionStay=function(e){if(e&&e.contacts&&e.contacts.length>0&&e.other){this._isColling=!0;e.contacts[0];var t=e.other.owner,a=t.name;"SliderBoost"!=a&&-1==a.indexOf("npc")&&(this._nowCollTargetName=a),-1==this._nowCollTargetName.indexOf("build")&&-1==this._nowCollTargetName.indexOf("Scaffolding")&&-1==this._nowCollTargetName.indexOf("irongauze")||(-1!=this._nowCollTargetName.indexOf("build")&&(this._nowbuildname=this._nowCollTargetName,this._nowscenename=t.parent.parent.name),-1!=this._nowCollTargetName.indexOf("irongauze")?this._nowselectVec=i.PropManager.getPosVecbyScene(t.parent.parent.parent.name,t.parent.name):this._nowselectVec=i.PropManager.getPosVecbyScene(t.parent.parent.name,this._nowCollTargetName))}},Player.prototype.onCollisionExit=function(e){if(this._isColling=!1,e&&e.contacts&&e.contacts.length>0&&e.other){var t=e.contacts[0];this.CheckEnd(t.normal,e.other.owner)}},Player.prototype.CheckEnd=function(e,t){if("SliderBoost"!=t.name&&-1==t.name.indexOf("npc"))if(this.isforceJump)this.isforceJump=!1;else if(this._lockxstate)this._lockxstate=0;else if(this._nowCollTargetName==t.name&&-1==t.name.indexOf("panel_jump"))switch(this.nowAction){case o.CharacterState.climbup:case o.CharacterState.climbupblock:-1!=this._nowCollTargetName.indexOf("box_Board")?this.JumpAction(this._changeMoveX):this._changeMoveX>0?this.nowAction=o.CharacterState.jumpright:this._changeMoveX<0&&(this.nowAction=o.CharacterState.jumpleft);break;case o.CharacterState.climbright:case o.CharacterState.climbleft:case o.CharacterState.run:this.JumpAction(this._changeMoveX);break;case o.CharacterState.MoveX:this.JumpAction(this._speedMoveV3.x)}},Player.prototype.setnowSelectVec=function(e){this._nowselectVec=e},Player.prototype.Calculate=function(e,t,a){if("SliderBoost"!=t.name&&-1==t.name.indexOf("npc")){this._nowCollTargetName=t.name;new Laya.Vector3;Laya.Vector3.normalize(e,this._normalizeVec),-1!=this._nowCollTargetName.indexOf("build")||-1!=this._nowCollTargetName.indexOf("Scaffolding")||-1!=this._nowCollTargetName.indexOf("irongauze")?(-1!=this._nowCollTargetName.indexOf("build")&&(this._nowbuildname=this._nowCollTargetName,this._nowscenename=t.parent.parent.name),-1!=this._nowCollTargetName.indexOf("irongauze")?this._nowselectVec=i.PropManager.getPosVecbyScene(t.parent.parent.parent.name,t.parent.name):this._nowselectVec=i.PropManager.getPosVecbyScene(t.parent.parent.name,this._nowCollTargetName),-1==this._normalizeVec.z?this._nowselectVec&&this._transform.position.y>this._nowselectVec.y-.2?(this._transform.position=new Laya.Vector3(this._transform.position.x,this._nowselectVec.y,this._transform.position.z),this.nowAction=o.CharacterState.run):(this.nowAction=o.CharacterState.climbup,this._shangpaVec=this._nowselectVec.clone()):1==this._normalizeVec.y||-1==this._normalizeVec.y?this.nowAction=o.CharacterState.run:-1==this._normalizeVec.x?this.nowAction==o.CharacterState.run?this._lockxstate=1:this.nowAction==o.CharacterState.climbup?this._lockxstate=1:this.nowAction=o.CharacterState.climbleft:1==this._normalizeVec.x?this.nowAction==o.CharacterState.run?this._lockxstate=2:this.nowAction==o.CharacterState.climbup?this._lockxstate=2:this.nowAction=o.CharacterState.climbright:1!=this._normalizeVec.z&&(this.nowAction=o.CharacterState.climbupblock,this._shangpaVec=this._nowselectVec.clone())):-1!=this._nowCollTargetName.indexOf("panel_jump")?this.nowAction=o.CharacterState.speedupjump:-1!=this._nowCollTargetName.indexOf("panel_downslip")?this.nowAction=o.CharacterState.downmove:-1!=this._nowCollTargetName.indexOf("box_Board")&&this.nowAction!=o.CharacterState.downmove?-1==this._normalizeVec.z&&(this.nowAction=o.CharacterState.climbup,this._shangpaVec=this._nowselectVec.clone()):-1!=this._nowCollTargetName.indexOf("box_sidejump")?this.nowAction=o.CharacterState.sidespeedup:-1!=this._nowCollTargetName.indexOf("box_Surmount")?this.nowAction=o.CharacterState.cross:-1!=this._nowCollTargetName.indexOf("irongauze")&&(this.nowAction=o.CharacterState.climbup,this._shangpaVec=this._nowselectVec.clone())}},Player.prototype.JumpAction=function(e){this.nowAction=e>0?o.CharacterState.jumpright:e<0?o.CharacterState.jumpleft:o.CharacterState.jump},Player.prototype.PlayAnimator=function(e){var t=this.TransitionActionName(e);this._StateName=e,this._animator&&(this._StateName==o.CharacterState.climbend||this._StateName==o.CharacterState.land1||this._StateName==o.CharacterState.land2?this._animator.speed=1.5:this._animator.speed=1,this._animator.play(t,0,0))},Player.prototype.TransitionActionName=function(e){switch(e){case"rollover1":return"cefan1";case"rollover2":return"cefan2";case"runwallleft":return"paoqiangleft";case"rightjump":return"rightjump";case"runwallright":return"paoqiangright";case"leftjump":return"leftjump";case"climbwall":return"paqiang";case"climbend":return"climbend";case"stand":return"stand";case"sky":return"kongzhong";case"land1":return"luodi1";case"land2":return"luodi2";case"highjump1":return"datiao1";case"highjump2":return"datiao2";case"run":return"run";case"jump":return"jump";case"climbup":return"Climb";case"falldown":return"Freefalling";case"climbleft":return"left_climb";case"climbright":return"right_climb";case"jumpright":return"right_jump";case"jumpleft":return"left_jump";case"ClimbMotion":return"PlayPalouAction";case"huachan":return"huachan";case"hurdle":return"kualan";case"speedupjump":return"jiasuJump";case"MoveX":return"xshunyi";case"downmove":return"downSlide";case"sidespeedup":return"slidejiasu";case"cross":return"surmount";case"climbupblock":return"lockclimb"}},Object.defineProperty(Player.prototype,"nowAction",{get:function(){return this._nowActionState},set:function(e){if(this._nowActionState!=e||this.LastActionState==o.CharacterState.speedupjump||this._nowActionState==o.CharacterState.speedupjump){switch(this.LastActionState=this._nowActionState,this._nowActionState=e,this._moveTime=0,this.canshake=!1,this.ChangeTrial(!0),this._nowActionState){case o.CharacterState.stand:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.stand);break;case o.CharacterState.run:if(this.LastActionState==o.CharacterState.jump||this.LastActionState==o.CharacterState.jumpleft||this.LastActionState==o.CharacterState.jumpright)this._isActionNums=!0,this._isneedactionnum=1,p.GameUtils.randRangeint(0,100)<50?this.PlayAnimator(o.CharacterState.land1):this.PlayAnimator(o.CharacterState.land2);else this._isActionNums=!1,this.PlayAnimator(o.CharacterState.run);break;case o.CharacterState.jump:this.PlayAnimator(o.CharacterState.jump),i.PropManager.Instance.SetEffectColor("color_white",this._transform.position),this._isActionNums=!0,this._isneedactionnum=1,this.jumpSpeed.x=this._RoleData.frontjump.x,this.jumpSpeed.y=this._RoleData.frontjump.y,this.jumpSpeed.z=this._RoleData.frontjump.z,m.AudioControl.Instance.playGameSound("tiao"),f.WXGamePlatform.Instance.vibrateShort();break;case o.CharacterState.jumpleft:i.PropManager.Instance.SetEffectColor("color_white",this._transform.position),this.jumpSpeed.x=this._RoleData.leftjump.x,this.jumpSpeed.y=this._RoleData.leftjump.y,this.jumpSpeed.z=this._RoleData.leftjump.z,this._isActionNums=!0,this._isneedactionnum=1,this.PlayAnimator(o.CharacterState.leftjump),m.AudioControl.Instance.playGameSound("tiao"),f.WXGamePlatform.Instance.vibrateShort();break;case o.CharacterState.jumpright:i.PropManager.Instance.SetEffectColor("color_white",this._transform.position),this.jumpSpeed.x=this._RoleData.rightjump.x,this.jumpSpeed.y=this._RoleData.rightjump.y,this.jumpSpeed.z=this._RoleData.rightjump.z,this._isActionNums=!0,this._isneedactionnum=1,this.PlayAnimator(o.CharacterState.rightjump),m.AudioControl.Instance.playGameSound("tiao"),f.WXGamePlatform.Instance.vibrateShort();break;case o.CharacterState.speedupjump:var t=l.default.dict.panel_jump;this.buff_speeduptime>0?(this._multiple.x=1,this._multiple.y=1,this._multiple.z=t.buffz*t.buffz,this.doublespeedup=!0):(this._multiple.x=1,this._multiple.y=1,this._multiple.z=t.buffz),this.buff_speeduptime=t.time,this.jumpSpeed.x=t.buffx*this._multiple.x,this.NowLastActionState==e?this.jumpSpeed.y=2*t.buffy:this.jumpSpeed.y=t.buffy,this.jumpSpeed.y=t.buffy,this.jumpSpeed.z=this._speedMoveV3.z*t.buffz*this._multiple.z,this._isActionNums=!0,this._isneedactionnum=1,p.GameUtils.randRangeint(0,100)<50?this.PlayAnimator(o.CharacterState.highjump1):this.PlayAnimator(o.CharacterState.highjump2),m.AudioControl.Instance.playGameSound("tiao"),Laya.timer.clear(this,this.playspeedSound),Laya.timer.once(200,this,this.playspeedSound),f.WXGamePlatform.Instance.vibrateShort();break;case o.CharacterState.downmove:t=l.default.dict.panel_downslip;this.buff_speeduptime>0?(this._multiple.x=1,this._multiple.y=1,this._multiple.z=t.buffz*t.buffz,this.doublespeedup=!0):(this._multiple.x=1,this._multiple.y=1,this._multiple.z=t.buffz),this.buff_speeduptime=t.time,this.jumpSpeed.x=t.buffx*this._multiple.x,this.jumpSpeed.y=t.buffy*this._multiple.y,this.jumpSpeed.z=this._speedMoveV3.z*t.buffz*this._multiple.z,this._isActionNums=!0,this._isneedactionnum=1,this.PlayAnimator(o.CharacterState.huachan),this.playspeedSound(),f.WXGamePlatform.Instance.vibrateShort();break;case o.CharacterState.sidespeedup:t=l.default.dict.box_sidejump;this.buff_speeduptime>0?(this._multiple.x=1,this._multiple.y=1,this._multiple.z=t.buffz*t.buffz,this.doublespeedup=!0):(this._multiple.x=1,this._multiple.y=1,this._multiple.z=t.buffz),this.buff_speeduptime=t.time,this.jumpSpeed.x=t.buffx*this._multiple.x,this.jumpSpeed.y=t.buffy*this._multiple.y,this.jumpSpeed.z=this._speedMoveV3.z*t.buffz*this._multiple.z,this._isActionNums=!1,this.playspeedSound(),f.WXGamePlatform.Instance.vibrateShort();break;case o.CharacterState.cross:t=l.default.dict.box_Surmount;this.buff_speeduptime>0?(this._multiple.x=1,this._multiple.y=1,this._multiple.z=t.buffz*t.buffz,this.doublespeedup=!0):(this._multiple.x=1,this._multiple.y=1,this._multiple.z=t.buffz),this.buff_speeduptime=t.time,this.jumpSpeed.x=t.buffx*this._multiple.x,this.jumpSpeed.y=(t.buffy+.5)*this._multiple.y,this.jumpSpeed.z=this._speedMoveV3.z*t.buffz*this._multiple.z,this._isActionNums=!0,this._isneedactionnum=1,this.PlayAnimator(o.CharacterState.hurdle);break;case o.CharacterState.climbup:case o.CharacterState.climbupblock:this.jumpSpeed.x=0,this.jumpSpeed.y=this._RoleData.upclimb,this.jumpSpeed.z=0,this._isActionNums=!1,this.PlayAnimator(o.CharacterState.climbwall),f.WXGamePlatform.Instance.vibrateShort(),this.canshake=!0,this.shaketime=0,this.ChangeTrial(!1);break;case o.CharacterState.climbleft:this.jumpSpeed.x=0,this.jumpSpeed.y=this._RoleData.slideclimb.y,this.jumpSpeed.z=this._RoleData.slideclimb.z,this._isActionNums=!1,this.PlayAnimator(o.CharacterState.runwallleft),this.ChangeTrial(!1);break;case o.CharacterState.climbright:this.jumpSpeed.x=0,this.jumpSpeed.y=this._RoleData.slideclimb.y,this.jumpSpeed.z=this._RoleData.slideclimb.z,this._isActionNums=!1,this.PlayAnimator(o.CharacterState.runwallright),this.ChangeTrial(!1);break;case o.CharacterState.ClimbMotion:this._isActionNums=!0,this._isneedactionnum=0,this._needactiontime=.3,this._moveTime=0,this.PlayAnimator(o.CharacterState.climbend)}this.NowLastActionState=e}},enumerable:!0,configurable:!0}),Player.prototype.playspeedSound=function(){m.AudioControl.Instance.playGameSound("speedup")},Player.prototype.ChangeTrial=function(e){this.LeftTrial&&this.RightTrial&&this.LeftTrial.active!=e&&(this.LeftTrial.active=e,this.RightTrial.active=e)},Player.prototype.Joy=function(e,t,a){if(this.nowAction==o.CharacterState.run?this._changeMoveX=e:(this.nowAction==o.CharacterState.climbup||o.CharacterState.climbleft||o.CharacterState.climbright)&&(this._changeMoveX=t),this.nowAction==o.CharacterState.climbleft&&this._changeMoveX>0?(this.isforceJump=!0,this.nowAction=o.CharacterState.jumpright):this.nowAction==o.CharacterState.climbright&&this._changeMoveX<0&&(this.isforceJump=!0,this.nowAction=o.CharacterState.jumpleft),this.nowAction==o.CharacterState.jump||this.nowAction==o.CharacterState.jumpleft||this.nowAction==o.CharacterState.jumpright||this.nowAction==o.CharacterState.speedupjump){a=-a*Math.PI/180,Laya.Quaternion.createFromAxisAngle(new Laya.Vector3(0,1,0),a,this.quaternion);var n=this.jumpSpeed.z;Laya.Vector3.transformQuat(this.jumpSpeed,this.quaternion,this.jumpSpeed),this.jumpSpeed.z=n}},Player.prototype.update=function(e){if(16,this._iscanMove){var t=.016;switch(this._moveTime+=t,this.nowAction){case o.CharacterState.run:this._moveVec.y=0,this._moveVec.z=t*(this._speedMoveV3.z*this._multiple.z),0==this._lockxstate?this._moveVec.x=this._changeMoveX*t:1==this._lockxstate?this._changeMoveX<0?this._moveVec.x=0:this._moveVec.x=this._changeMoveX*t:2==this._lockxstate&&(this._changeMoveX>0?this._moveVec.x=0:this._moveVec.x=this._changeMoveX*t),this._transform.translate(this._moveVec,!1);break;case o.CharacterState.climbup:this._moveVec.z=0,this._moveVec.y=t*this.jumpSpeed.y,1==this._lockxstate?this._changeMoveX<0?this._moveVec.x=0:this._moveVec.x=this._changeMoveX*t:2==this._lockstate&&this._changeMoveX>0?this._moveVec.x=0:this._moveVec.x=this._changeMoveX*t,this._transform.translate(this._moveVec,!1),this._shangpaVec?this._transform.position.y+1>this._shangpaVec.y&&(this.nowAction=o.CharacterState.ClimbMotion):this._nowselectVec&&this._transform.position.y+1>this._nowselectVec.y&&(this.nowAction=o.CharacterState.ClimbMotion);break;case o.CharacterState.climbupblock:this._moveVec.z=0,this._moveVec.y=t*this.jumpSpeed.y,this._moveVec.x=0,this._transform.translate(this._moveVec,!1),this._shangpaVec?this._transform.position.y+1>this._shangpaVec.y&&(this.nowAction=o.CharacterState.ClimbMotion):this._transform.position.y+1>this._nowselectVec.y&&(this.nowAction=o.CharacterState.ClimbMotion);break;case o.CharacterState.jump:case o.CharacterState.jumpleft:case o.CharacterState.jumpright:case o.CharacterState.speedupjump:this._disy=this.jumpSpeed.y-this.g*t,this.jumpSpeed.y=this._disy,this._moveVec.x=this.jumpSpeed.x*t,this._moveVec.y=this._disy*t,this._moveVec.z=this.jumpSpeed.z*t,this._transform.translate(this._moveVec,!1);break;case o.CharacterState.climbleft:case o.CharacterState.climbright:this._moveVec.z=t*this.jumpSpeed.y,this._moveVec.y=this.jumpSpeed.y*t,this._moveVec.x=0,this._transform.translate(this._moveVec,!1);break;case o.CharacterState.MoveX:this._moveVec.z=t*this._speedMoveV3.z,this._moveVec.x=this._speedMoveV3.x*t,this._transform.translate(this._moveVec,!1),this._moveTime>.1&&(this.nowAction=o.CharacterState.run);break;case o.CharacterState.downmove:this._moveVec.y=this.jumpSpeed.x,this._moveVec.x=this.jumpSpeed.y,this._moveVec.z=this.jumpSpeed.z*t,this._transform.translate(this._moveVec,!1);break;case o.CharacterState.sidespeedup:this._moveVec.y=0,this._moveVec.x=0,this._moveVec.z=this.jumpSpeed.z*t,this._transform.translate(this._moveVec,!1),this.buff_speeduptime<=0&&this.LastActionState==o.CharacterState.climbleft||this.LastActionState==o.CharacterState.climbright?this.nowAction=this.LastActionState:this.nowAction=o.CharacterState.jump;break;case o.CharacterState.cross:this._disy=this.jumpSpeed.y-this.g*t,this.jumpSpeed.y=this._disy,this._moveVec.x=this.jumpSpeed.x*t,this._moveVec.y=this._disy*t,this._moveVec.z=this.jumpSpeed.z*t,this._transform.translate(this._moveVec,!1);break;case o.CharacterState.ClimbMotion:this._nowselectVec&&this._transform.position.y<this._nowselectVec.y&&(this._moveVec.x=0,this._moveVec.y=1/.3*t,this._moveVec.z=0,this._transform.translate(this._moveVec,!1))}if(!this._nowselectVec||this.nowAction!=o.CharacterState.run&&this.nowAction!=o.CharacterState.downmove||this._isColling||this._transform.position.z<=this._nowselectVec.z&&(this._changeMoveX>0?this.nowAction=o.CharacterState.jumpright:this._changeMoveX<0?this.nowAction=o.CharacterState.jumpleft:this.nowAction=o.CharacterState.jump),this._transform.position.y<i.PropManager.diePosY-g.PlayerAccount.CurrentAccount.CurAccountData.DieDistance&&(""==this._nowscenename||this._nowbuildname,u.GameState.fuhuocishu>0?this.Revive():this.Lose(),this.nowAction=o.CharacterState.stand),this._transform.position.z<i.PropManager.gamewinPosZ?this.Win():i.PropManager.pro_jindu.value=this._transform.position.z/i.PropManager.gamewinPosZ*100,this._isActionNums)if(this._isneedactionnum>0){if(this._animator.getCurrentAnimatorPlayState().normalizedTime>=this._isneedactionnum)switch(this._StateName){case o.CharacterState.jump:case o.CharacterState.leftjump:case o.CharacterState.rightjump:case o.CharacterState.highjump1:case o.CharacterState.highjump2:case o.CharacterState.hurdle:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.sky);break;case o.CharacterState.huachan:case o.CharacterState.climbend:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.run),this.nowAction=o.CharacterState.run,this._transform.position=new Laya.Vector3(this._transform.position.x,this._nowselectVec.y,this._transform.position.z);break;case o.CharacterState.land1:case o.CharacterState.land2:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.run);break;case o.CharacterState.huachan:this.nowAction=o.CharacterState.run}}else if(0!=this._needactiontime&&this._moveTime>this._needactiontime)switch(this._StateName){case o.CharacterState.jump:case o.CharacterState.leftjump:case o.CharacterState.rightjump:case o.CharacterState.highjump1:case o.CharacterState.highjump2:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.sky),this._changeMoveX=0;break;case o.CharacterState.hurdle:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.sky);break;case o.CharacterState.huachan:case o.CharacterState.climbend:this._isActionNums=!1,this.PlayAnimator(o.CharacterState.run),this.nowAction=o.CharacterState.run,this._transform.position=new Laya.Vector3(this._transform.position.x,this._nowselectVec.y,this._transform.position.z)}this.buff_speeduptime>0?(this.buff_speeduptime-=t,i.PropManager.Instance.SpeedUpEffect("jiasulizi",this._transform.position),this.doublespeedup&&i.PropManager.Instance.SpeedUpEffect1("jiasulizi",this._transform.position)):(this._multiple.x=1,this._multiple.y=1,this._multiple.z=1,this.doublespeedup=!1,i.PropManager.Instance.CloseSpeedUpEffect(),i.PropManager.Instance.CloseSpeedUpEffect1()),this.canshake&&(this.shaketime+=t,this.shaketime>=.5&&(this.shaketime=0,f.WXGamePlatform.Instance.vibrateShort()))}else if(this._ending){t=.016;this._moveTime+=t,this._moveTime>=this._endanmotime?this.GameOver():(this._endAnmoSpeed1.x=this._endAnmoSpeed.x*t,this._endAnmoSpeed1.y=this._endAnmoSpeed.y*t,this._endAnmoSpeed1.z=this._endAnmoSpeed.z*t,i.PropManager.carma.getComponent(c.CameraManager).GameEndRotate(this._transform.position,this._endAnmoSpeed1))}},Player.prototype.Win=function(){m.AudioControl.Instance.playGameSound("over"),h.DispatcherManager.dispatchEvent(u.GameState.end);var e=i.PropManager.carma.transform;this._endAnmoSpeed.z=(this._transform.position.z-2-e.position.z)/this._endanmotime,this._endAnmoSpeed.y=(this._transform.position.y-e.position.y)/this._endanmotime,this._endAnmoSpeed.x=(this._transform.position.x+3-e.position.x)/this._endanmotime,this._moveTime=0,this._iscanMove=!1,this._ending=!0,this.PlayAnimator(o.CharacterState.sky),i.PropManager.Instance.GameOverEffecf("yanhua",this._transform.position,0==d.GameStateControl.Instance.endGamePlayerArr.length)},Player.prototype.Revive=function(){m.AudioControl.Instance.playGameSound("over"),u.GameState.isdie=!0,h.DispatcherManager.dispatchEvent(u.GameState.revive),this._iscanMove=!1,this.PlayAnimator(o.CharacterState.stand)},Player.prototype.Lose=function(){m.AudioControl.Instance.playGameSound("over"),u.GameState.isdie=!0,h.DispatcherManager.dispatchEvent(u.GameState.lose),this._iscanMove=!1,this.PlayAnimator(o.CharacterState.stand),this._ending=!0},Player.prototype.GameOver=function(){this._ending=!1,n.TimerService.Instance.removeUpdateTarget(this)},Player.prototype.TestJump=function(){this.nowAction=o.CharacterState.jump},Player.prototype.destroy=function(){n.TimerService.Instance.removeUpdateTarget(this),e.prototype.destroy.call(this)},Player.prototype.XMove=function(e){this.nowAction==o.CharacterState.run&&(this._moveTime=0,this._speedMoveV3.x=20*e,this.nowAction=o.CharacterState.MoveX)},Player.prototype.dispose=function(){n.TimerService.Instance.removeUpdateTarget(this)},Player.prototype.onDestroy=function(){console.log("拖尾回收成功2222222----"),C.default.RecoverSprite3D(this.LeftTrial),C.default.RecoverSprite3D(this.RightTrial)},Player}(Laya.Script3D);a.Player=_},{"../Agency/AgencyUserMessage":8,"../CFG/BuildCFG":9,"../Control/AssetManager":17,"../Control/AudioControl":18,"../Control/GameStateControl":21,"../Control/PoolManager":26,"../PrefabControl/CharacterState":46,"../PrefabControl/PanelResDic":48,"../PrefabControl/PropManager":49,"../Time/TimerService":59,"../WXSDK/PlayerAccount":75,"../WXSDK/WXGamePlatform":81,"../utils/DispatcherManager":85,"../utils/GameState":86,"../utils/GameUtils":87,"./CameraManager":38}],41:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function Global(){}return Global.curHeight=function(){return Laya.stage.height},Global.curWidth=function(){return Laya.stage.width},Global.setVars=function(){Global.stage=Laya.stage,Global.sethttpurl()},Global.getUrl=function(e){return-1==e.indexOf("wxlocal")?Global.resourcehtttp+e+Global.versions:e},Global.sethttpurl=function(){Global.isdebug?Global.httpurl="https://wxgamedev.51yoyoyo.com/":Global.httpurl="https://minport.51yoyoyo.com/"},Global.httpurl="",Global.resourcehtttp="",Global.cdnurl="https://wxgame.51yoyoyo.com/",Global.versions="",Global.initWidth=720,Global.initHeight=1280,Global.resconfigVersion="",Global.nowplatfrom="",Global.appid="wx46f4626932e5f48b",Global.gameVersion="1.0.1",Global.isdebug=!1,Global.AppKeyID=0,Global.MemberID=0,Global}();a.Global=n},{}],42:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(e){function GlobalWaiting(){var t=e.call(this)||this;return t._isforcehide=!1,t._lastTime=0,t}return __extends(GlobalWaiting,e),GlobalWaiting.prototype.constructFromXML=function(t){this.setSize(fairygui.GRoot.inst.width,fairygui.GRoot.inst.height),e.prototype.constructFromXML.call(this,t),this.img_0=this.getChild("img_0").asImage,this.img_0.visible=!1,this.on(Laya.Event.DISPLAY,this,this.onAddedToStage),this.on(Laya.Event.UNDISPLAY,this,this.onRemoveFromStage)},GlobalWaiting.prototype.onAddedToStage=function(){this._lastTime=Laya.Browser.now(),Laya.timer.frameLoop(1,this,this.onTimer)},GlobalWaiting.prototype.onTimer=function(){if(this.img_0)if((Laya.Browser.now()-this._lastTime)/1e3>=0){this._isforcehide||(this.img_0.visible=!0);var e=this.img_0.rotation;(e+=10)>360&&(e%=360),this.img_0.rotation=e}else this.img_0.visible=!1},GlobalWaiting.prototype.hideimg=function(){this._isforcehide=!0,this.img_0&&(this.img_0.visible=!1)},GlobalWaiting.prototype.onRemoveFromStage=function(){Laya.timer.clear(this,this.onTimer)},GlobalWaiting}(fairygui.GComponent);a.GlobalWaiting=n},{}],43:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(e){function JoystickModule(t){var a=e.call(this)||this;return a.dis=0,a.degree=0,a.angle=0,a.offx=0,a._iscanCBack=!1,a.mLastMouseX=0,a.mLastMouseY=0,a.mX=0,a.mY=0,a._iacanCallback=!1,a._clickpanel=t,a._button=new Laya.Point,a.touchId=-1,a.radius=400,a._curPos=new Laya.Point,a._clickpanel.on(Laya.Event.MOUSE_DOWN,a,a.onTouchDown),a}return __extends(JoystickModule,e),JoystickModule.prototype.onTouchDown=function(e){if(-1==this.touchId){this.touchId=e.touchId,this.offx=0,this._iscanCBack=!1,fairygui.GRoot.inst.globalToLocal(Laya.stage.mouseX,Laya.stage.mouseY,this._curPos);var t=this._curPos.x,a=this._curPos.y;this._lastStageX=t,this._lastStageY=a,this._startStageX=t,this._startStageY=a,this._button.x=t,this._button.y=a,this._callobj&&this._downCallback&&this._downCallback.call(this._callobj),this._clickpanel.on(Laya.Event.MOUSE_MOVE,this,this.OnTouchMove),this._clickpanel.on(Laya.Event.MOUSE_UP,this,this.OnTouchUp),this._clickpanel.on(Laya.Event.MOUSE_OUT,this,this.OnTouchUp)}},JoystickModule.prototype.setEventCallback=function(e,t,a,n){this._callobj=e,this._downCallback=t,this._movecallback=a,this._updatecallback=n},JoystickModule.prototype.Trigger=function(e){this.onTouchDown(e)},JoystickModule.prototype.createMap=function(){this.tiledMap=new Laya.TiledMap,this.mX=this.mY=0,this.tiledMap.createMap("res/tiledMap/desert.json",new Laya.Rectangle(0,0,Laya.Browser.width,Laya.Browser.height),new Laya.Handler(this,this.completeHandler))},JoystickModule.prototype.completeHandler=function(){console.log("地图创建完成"),console.log("ClientW:"+Laya.Browser.clientWidth+" ClientH:"+Laya.Browser.clientHeight)},JoystickModule.prototype.OnTouchUp=function(e){void 0===e&&(e=null),-1!=this.touchId&&e.touchId==this.touchId&&(this.touchup(),this._callobj&&this._updatecallback&&this._updatecallback.call(this._callobj))},JoystickModule.prototype.touchup=function(){this._iscanCBack=!1,this.touchId=-1,this._clickpanel.off(Laya.Event.MOUSE_MOVE,this,this.OnTouchMove),this._clickpanel.off(Laya.Event.MOUSE_UP,this,this.OnTouchUp),this._clickpanel.off(Laya.Event.MOUSE_OUT,this,this.OnTouchUp),this._iacanCallback=!1,this.degree=0},JoystickModule.prototype.OnTouchMove=function(e){if(-1!=this.touchId&&e.touchId==this.touchId){var t=Laya.stage.mouseX,a=Laya.stage.mouseY,n=t-this._lastStageX,i=a-this._lastStageY;this._lastStageX=t,this._lastStageY=a;var o=this._button.x+n,r=this._button.y+i,s=o-this._startStageX,l=r-this._startStageY,c=0;if(this._iscanCBack=n>=2||n<=-2,this.offx=n,0==s&&0==l)return;s>0?s>this.radius?(c=this.radius,this.angle=90):(c=this.radius-s,this.angle=90-c/this.radius*90):0==s?this.angle=0:-s>this.radius?(c=this.radius,this.angle=-90):(c=this.radius+s,this.angle=-(90-c/this.radius*90));var h=Math.atan2(l,s);this.degree=h;var u=this.radius*Math.cos(h),p=this.radius*Math.sin(h);Math.abs(s)>Math.abs(u)&&(s=u),Math.abs(l)>Math.abs(p)&&(l=p),(o=this._startStageX+s)<0&&(o=0),(r=this._startStageY+l)>fairygui.GRoot.inst.height&&(r=fairygui.GRoot.inst.height),this._button.x=o,this._button.y=r,this.dis=Math.sqrt(s*s+l*l),this._iacanCallback=!0,this._iscanCBack&&this._callobj&&this._movecallback&&this._iacanCallback&&this._movecallback.call(this._callobj,this.offx)}},JoystickModule.prototype.dispose=function(){this._clickpanel.off(Laya.Event.MOUSE_DOWN,this,this.onTouchDown)},JoystickModule.JoystickMoving="JoystickMoving",JoystickModule.JoystickUp="JoystickUp",JoystickModule}(Laya.EventDispatcher);a.JoystickModule=n},{}],44:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./Global"),i=Laya.Stage,o=e("./Config/AssetPath"),r=e("./GameContents"),s=e("./WXSDK/Sdk");new(function(){function Main(){Laya3D.init(n.Global.initWidth,n.Global.initHeight),Laya.stage.scaleMode=i.SCALE_FIXED_WIDTH,Laya.stage.alignH=i.ALIGN_CENTER,Laya.stage.alignV=i.ALIGN_TOP,Laya.stage.screenMode=i.SCREEN_VERTICAL,Laya.stage.bgColor="#54B9F6",Laya.alertGlobalError=!0,window.Config3D&&(window.Config3D._default._defaultPhysicsMemory=128),Laya.Browser.window.tt&&s.WxApi.CheckWXUpdate(),Laya.stage.on("resize",this,this.onResize)}return Main.prototype.onResize=function(){Laya.stage.off("resize",this,this.onResize),n.Global.setVars(),o.AssetPath.init(),fairygui.UIConfig.packageFileExtension="bin",fairygui.UIConfig.textureLinearSampling=!0,fairygui.UIConfig.defaultFont="黑体",fairygui.UIConfig.versions=n.Global.versions,(new r.GameContents).initGame()},Main}())},{"./Config/AssetPath":15,"./GameContents":37,"./Global":41,"./WXSDK/Sdk":77}],45:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Config/AssetPath"),i=function(){function CharacterPool(){}return CharacterPool.AddCharacter=function(e,t,a){var i,o=CharacterPool.roledict[e];if(o&&o.length>0)(i=o.shift()).active=!0,a.addChild(i);else{var r=Laya.Loader.getRes(n.AssetPath.get3DRoleModel(e));i=Laya.Sprite3D.instantiate(r,a,!1,new Laya.Vector3(0,0,0))}t&&(i.addComponent(t).resouseName=e);var s=new Laya.Quaternion;return Laya.Quaternion.createFromAxisAngle(new Laya.Vector3(0,1,0),180*Math.PI/180,s),i.transform.rotation=s,i},CharacterPool.ClearCharacter=function(e,t,a){CharacterPool.roledict[t]||(CharacterPool.roledict[t]=[]),a&&a.destroy(),e.active=!1,e.removeSelf(),CharacterPool.roledict[t].push(e)},CharacterPool.roledict={},CharacterPool}();a.CharacterPool=i},{"../Config/AssetPath":15}],46:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function CharacterState(){}return CharacterState.rollover1="rollover1",CharacterState.rollover2="rollover2",CharacterState.runwallleft="runwallleft",CharacterState.rightjump="rightjump",CharacterState.runwallright="runwallright",CharacterState.leftjump="leftjump",CharacterState.climbwall="climbwall",CharacterState.climbend="climbend",CharacterState.stand="stand",CharacterState.sky="sky",CharacterState.land1="land1",CharacterState.land2="land2",CharacterState.highjump1="highjump1",CharacterState.highjump2="highjump2",CharacterState.run="run",CharacterState.jump="jump",CharacterState.climbup="climbup",CharacterState.falldown="falldown",CharacterState.climbleft="climbleft",CharacterState.climbright="climbright",CharacterState.jumpright="jumpright",CharacterState.jumpleft="jumpleft",CharacterState.ClimbMotion="ClimbMotion",CharacterState.huachan="huachan",CharacterState.hurdle="hurdle",CharacterState.speedupjump="speedupjump",CharacterState.MoveX="MoveX",CharacterState.downmove="downmove",CharacterState.sidespeedup="sidespeedup",CharacterState.cross="cross",CharacterState.climbupblock="climbupblock",CharacterState}();a.CharacterState=n},{}],47:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=Laya.Animation,i=function(e){function GamePool(){var t=e.call(this)||this;return t.AniConfPath="res/fighter/fighter.json",t}return __extends(GamePool,e),GamePool.RemoveItem=function(e,t){GamePool.contain[e]&&(-1==GamePool.contain[e].indexOf(t)&&GamePool.contain[e].push(t))},GamePool.GetItem=function(e){for(var t=[],a=1;a<arguments.length;a++)t[a-1]=arguments[a];return GamePool.contain[e]?0==GamePool.contain[e].length?new(0,GamePool.sprite3DArray[e]):GamePool.contain[e].shift():(console.log("此key值对应的类未被注册"),null)},GamePool.prototype.createAnimation=function(){var e=new n;e.loadAtlas(this.AniConfPath),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)},GamePool.GetItemFairyGUI=function(e){return GamePool.contain[e]||(GamePool.contain[e]=[]),0==GamePool.contain[e].length?fairygui.UIPackage.createObjectFromURL(e):GamePool.contain[e].shift()},GamePool.Mark=function(e,t){GamePool.sprite3DArray[e]=t,GamePool.contain[e]=[]},GamePool.sprite3DArray={},GamePool.contain={},GamePool}(Laya.EventDispatcher);a.GamePool=i},{}],48:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../utils/Singleton"),i=function(e){function PanelResDic(){var t=e.call(this)||this;return PanelResDic.ins=t,t}return __extends(PanelResDic,e),Object.defineProperty(PanelResDic,"Instance",{get:function(){return null==PanelResDic.ins?new PanelResDic:PanelResDic.ins},enumerable:!0,configurable:!0}),PanelResDic.getView=function(e){if(!PanelResDic._mapviewDict[e])throw"err0 未绑定的viewkey:"+e;return PanelResDic._mapviewDict[e]},PanelResDic.prototype.getSingleTon=function(e){return n.Singleton.Instance(e)},PanelResDic.prototype.mapView=function(e,t){PanelResDic._mapviewDict[e]||(PanelResDic._mapviewDict[e]=t,t.key=e)},PanelResDic.prototype.AgencyAdd=function(e){n.Singleton.create(e)},PanelResDic.prototype.AgencyClear=function(e){n.Singleton.remove(e)},PanelResDic._mapviewDict={},PanelResDic}(Laya.EventDispatcher);a.PanelResDic=i},{"../utils/Singleton":91}],49:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Config/AssetPath"),i=e("../utils/GameUtils"),o=function(){function PropManager(){this._outQUaternion4=new Laya.Quaternion,this._outQUaternion=new Laya.Quaternion,PropManager.ins=this}return Object.defineProperty(PropManager,"Instance",{get:function(){return null==PropManager.ins?new PropManager:PropManager.ins},enumerable:!0,configurable:!0}),PropManager.getPosVecbyScene=function(e,t){return PropManager.patternDict[e]?PropManager.patternDict[e][t]:null},PropManager.setAnimator=function(e){var t;for(var a in PropManager.actionDict)if(!e.getControllerLayer().getAnimatorState(a)){t=PropManager.actionDict[a];var n=new Laya.AnimatorState;n.name=a,n.clipStart=t.s/PropManager.actionnums,n.clipEnd=t.e/PropManager.actionnums,n.clip=e.getDefaultState().clip,n.clip.islooping=t.islooping,e.addState(n)}},PropManager.prototype.InitEffect=function(){var e;(e=PropManager.getlizibyName("speedupeffect")).particleSystem.play(),e.active=!1,(e=PropManager.getlizibyName("color_white")).particleSystem.play(),e.active=!1,(e=PropManager.getlizibyName("color_yellow")).particleSystem.play(),e.active=!1},PropManager.prototype.SetEffectColor=function(e,t){(Laya.timer.clear(this,this.EffectEnd),this.EffectEndColor(),"color_white"==e)&&(i.GameUtils.randRangeint(0,100)>50&&(e="color_yellow"));this._tanselizi=PropManager.getlizibyName(e),this._tanselizi.transform.position=t,this._tanselizi.particleSystem.play(),Laya.timer.once(500,this,this.EffectEndColor)},PropManager.prototype.EffectEndColor=function(){this._tanselizi&&(this._tanselizi.particleSystem.stop(),this._tanselizi.active=!1)},PropManager.prototype.SpeedUpEffect1=function(e,t){(!this._engamelizi4||this._engamelizi4&&!this._engamelizi4.active)&&(this._engamelizi4=PropManager.getlizibyName("speedupeffect"),this._engamelizi4.particleSystem.looping=!0,this._engamelizi4.transform.scale=new Laya.Vector3(20,20,20),Laya.Quaternion.createFromAxisAngle(new Laya.Vector3(1,0,0),-50,this._outQUaternion4),this._engamelizi4.transform.rotation=this._outQUaternion4,this._engamelizi4.particleSystem.play());var a=t.clone();a.y+=5,a.z-=10,this._engamelizi4.transform.position=a},PropManager.prototype.CloseSpeedUpEffect1=function(){this._engamelizi4&&this._engamelizi4.active&&(this._engamelizi4.active=!1)},PropManager.prototype.SpeedUpEffect=function(e,t){(!this._engamelizi3||this._engamelizi3&&!this._engamelizi3.active)&&(this._engamelizi3=PropManager.getlizibyName("speedupeffect"),this._engamelizi3.particleSystem.looping=!0,this._engamelizi3.transform.scale=new Laya.Vector3(20,20,20),Laya.Quaternion.createFromAxisAngle(new Laya.Vector3(1,0,0),-50,this._outQUaternion),this._engamelizi3.transform.rotation=this._outQUaternion,this._engamelizi3.particleSystem.play());var a=t.clone();a.y+=5,this._engamelizi3.transform.position=a},PropManager.prototype.CloseSpeedUpEffect=function(){this._engamelizi3&&this._engamelizi3.active&&(this._engamelizi3.active=!1)},PropManager.prototype.GameOverEffecf=function(e,t,a){this._engamelizi1=PropManager.getlizibyName("fireworks"),this._engamelizi1.transform.position=t,this._engamelizi1.particleSystem.play(),a&&(this._engamelizi2=PropManager.getlizibyName("winline"),this._engamelizi2.transform.position=t,this._engamelizi2.particleSystem.play())},PropManager.prototype.CloseGameOverEffect=function(){this._engamelizi1&&(this._engamelizi1.particleSystem.stop(),this._engamelizi1.active=!1),this._engamelizi2&&(this._engamelizi2.particleSystem.stop(),this._engamelizi2.active=!1)},PropManager.prototype.EffectEnd=function(e){e&&(e.particleSystem.stop(),e.active=!1)},PropManager.getlizibyName=function(e){var t;return PropManager.liziDict[e]?t=PropManager.liziDict[e]:(t=Laya.Sprite3D.instantiate(Laya.Loader.getRes(n.AssetPath.get3DModel(e))),PropManager.liziDict[e]=t,PropManager.scene3D.addChild(t)),t.active=!0,t},PropManager.nowmapDict={},PropManager.diePosY=0,PropManager.gamewinPosZ=0,PropManager.patternDict={},PropManager.npcDict={},PropManager.npcscriptDict={},PropManager.npcnum=0,PropManager.iscarmanpc=!1,PropManager.liziDict={},PropManager.jiantouArr=[],PropManager.actionnums=575,PropManager.actionDict={climbend:{s:550,e:575,islooping:!1},stand:{s:0,e:80,islooping:!0},run:{s:90,e:106,islooping:!0},jump:{s:110,e:132,islooping:!0},kongzhong:{s:132,e:145,islooping:!0},luodi1:{s:145,e:160,islooping:!0},luodi2:{s:170,e:202,islooping:!0},datiao1:{s:210,e:235,islooping:!0},datiao2:{s:240,e:273,islooping:!0},huachan:{s:280,e:310,islooping:!0},kualan:{s:310,e:346,islooping:!0},cefan1:{s:350,e:391,islooping:!0},cefan2:{s:400,e:434,islooping:!0},paoqiangleft:{s:440,islooping:!0,e:456},rightjump:{s:460,e:477,islooping:!0},paoqiangright:{s:480,e:496,islooping:!0},leftjump:{s:500,e:517,islooping:!0},paqiang:{s:520,e:542,islooping:!0}},PropManager}();a.PropManager=o},{"../Config/AssetPath":15,"../utils/GameUtils":87}],50:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelChildControl"),i=e("./CpaEvent"),o=e("../WXSDK/PlayerAccount"),r=e("./RecommendView"),s=e("../Time/TimerService"),l=function(e){function BaoKuanGameView(){var t=e.call(this)||this;return t._time=0,t.key=0,t._istart=!1,t}return __extends(BaoKuanGameView,e),BaoKuanGameView.prototype.onInit=function(){this.initView(),this.initEvent()},BaoKuanGameView.prototype.initView=function(){this.c_state=this.getController("c_state"),this.t0=this.getTransition("t0"),this.c_state.selectedIndex=0},BaoKuanGameView.prototype.initEvent=function(){console.log("监听互推事件---BaokuanGame0"),this.AddEventData(i.default.YQHomeData,this,this.yqhomedataHandler)},BaoKuanGameView.prototype.yqhomedataHandler=function(){console.log("监听互推事件---BaokuanGame1"),this.RefreshBKYX(),s.TimerService.Instance.addUpdateTarget(this)},BaoKuanGameView.prototype.update=function(e){this._istart&&(this._time+=e,this._time>=5e3&&(this._time=0,this.RefreshBKYX(!0)))},BaoKuanGameView.prototype.RefreshBKYX=function(e){if(void 0===e&&(e=!1),o.PlayerAccount.CurrentAccount.CurAccountData.recommend){console.log("监听互推事件---BaokuanGame2"),this.c_state.selectedIndex=1;for(var t=r.Recommend.cainixihuanData,a=0;a<4;a++){this.key+a>=t.length-1&&(this.key=0);var n=t[this.key+a];this["item_"+a].showData(n,!0)}this.key+=4,this.key>=t.length-1&&(this.key=0),this._istart=!0,e&&this.t0.play(null,1)}},BaoKuanGameView}(n.PanelChildControl);a.default=l},{"../Control/PanelChildControl":25,"../Time/TimerService":59,"../WXSDK/PlayerAccount":75,"./CpaEvent":53,"./RecommendView":55}],51:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelBaseControl"),i=e("./RecommendView"),o=e("../View/ViewManager"),r=e("../Time/TimerService"),s=e("../utils/DispatcherManager"),l=e("../utils/GameState"),c=e("../View/CompletePanel"),h=e("../Data/RoleData"),u=function(e){function ChoutiPanView(t){var a=e.call(this,"main","choutipanView")||this;return a._iscanmove=!1,a.isend=0,a._movetime=0,a._flushtime=0,a.dir=!0,a._nowvalue=0,a.isend=t,a}return __extends(ChoutiPanView,e),ChoutiPanView.prototype.initView=function(){this.list_0.setVirtual(),this.list_0.itemRenderer=Laya.Handler.create(this,this.itemrenderlist,null,!1),this.list_1.setVirtual(),this.list_1.itemRenderer=Laya.Handler.create(this,this.itemrenderlist1,null,!1),this._nowList0=i.Recommend.gdyxData,this._nowList1=i.Recommend.gdyxData,this.list_0.numItems=this._nowList0.length,this.list_1.numItems=this._nowList1.length,this._isStart=!0,this._iscanmove=!0,r.TimerService.Instance.addUpdateTarget(this)},ChoutiPanView.prototype.initEvent=function(){this.AddEventByType(this.btn_return,Laya.Event.CLICK,this,this.onclosefun),this.AddEventByType(this.btn_jixugame,Laya.Event.CLICK,this,this.onclosefun),this.AddEventByType(this.list_1,Laya.Event.MOUSE_DOWN,this,this.downclick),this.AddEventByType(this.list_1,Laya.Event.MOUSE_UP,this,this.upclick),this.AddEventByType(this.list_1,Laya.Event.MOUSE_OUT,this,this.upclick)},ChoutiPanView.prototype.itemrenderlist=function(e,t){e<this._nowList0.length&&t.showData(this._nowList0[e])},ChoutiPanView.prototype.itemrenderlist1=function(e,t){e<this._nowList1.length&&t.showData(this._nowList1[e])},ChoutiPanView.prototype.downclick=function(){this._isdown=!0,this._iscanmove=!1,Laya.timer.clear(this,this.timeoutCallback)},ChoutiPanView.prototype.timeoutCallback=function(){this._iscanmove=!0},ChoutiPanView.prototype.upclick=function(){this._isdown&&(this._isdown=!1,this._nowvalue=this.list_1.scrollPane.percY,Laya.timer.once(2e3,this,this.timeoutCallback))},ChoutiPanView.prototype.update=function(e){this._isStart&&this.list_1.scrollPane&&this._nowList1&&this._iscanmove&&(this.dir?(this._nowvalue+=.001,this._nowvalue>=1&&(this._nowvalue=1,this.dir=!1)):(this._nowvalue-=.001,this._nowvalue<=0&&(this._nowvalue=0,this.dir=!0)),this.list_1.scrollPane.setPercY(this._nowvalue))},ChoutiPanView.prototype.onclosefun=function(){if(1==this.isend)o.ViewManager.Instance.close(ChoutiPanView),s.DispatcherManager.dispatchEvent(l.GameState.lose);else if(2==this.isend){var e=h.RoleData.Instance.levelcfg.winGold;o.ViewManager.Instance.close(ChoutiPanView),o.ViewManager.Instance.add(c.CompletePanel,e)}else o.ViewManager.Instance.close(ChoutiPanView)},ChoutiPanView.prototype.destory=function(){r.TimerService.Instance.removeUpdateTarget(this),e.prototype.destory.call(this)},ChoutiPanView.key="ChoutiPanView",ChoutiPanView}(n.PanelBaseControl);a.default=u},{"../Control/PanelBaseControl":24,"../Data/RoleData":33,"../Time/TimerService":59,"../View/CompletePanel":61,"../View/ViewManager":70,"../utils/DispatcherManager":85,"../utils/GameState":86,"./RecommendView":55}],52:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelChildControl"),i=e("./CpaEvent"),o=e("./RecommendView"),r=e("../Time/TimerService"),s=e("../Control/SceneControl"),l=function(e){function CpaDownsView(){var t=e.call(this)||this;return t._iscanmove=!1,t._movetime=0,t._flushtime=0,t.dir=!0,t._nowvalue=0,t}return __extends(CpaDownsView,e),CpaDownsView.prototype.onInit=function(){this.c_state=this.getController("c_state"),this.c_state.selectedIndex=0,this.initView(),this.initEvent()},CpaDownsView.prototype.initView=function(){this.list_0.setVirtual(),this.list_0.itemRenderer=Laya.Handler.create(this,this.itemrenderlist,null,!1),this._isStart=!1},CpaDownsView.prototype.initEvent=function(){this.AddEventData(i.default.YQHomeData,this,this.yqhomedataHandler),this.AddEventByType(this.list_0,Laya.Event.MOUSE_DOWN,this,this.downclick),this.AddEventByType(this.list_0,Laya.Event.MOUSE_UP,this,this.upclick),this.AddEventByType(this.list_0,Laya.Event.MOUSE_OUT,this,this.upclick)},CpaDownsView.prototype.downclick=function(){s.SceneControl.IsShowSign||(this._isdown=!0,this._iscanmove=!1,Laya.timer.clear(this,this.timeoutCallback))},CpaDownsView.prototype.timeoutCallback=function(){s.SceneControl.IsShowSign||(this._iscanmove=!0)},CpaDownsView.prototype.upclick=function(){s.SceneControl.IsShowSign||this._isdown&&(this._isdown=!1,this._nowvalue=this.list_0.scrollPane.percX,Laya.timer.once(2e3,this,this.timeoutCallback))},CpaDownsView.prototype.update=function(e){this._isStart&&this.list_0.scrollPane&&this._nowList&&this._iscanmove&&(this.dir?(this._nowvalue+=.001,this._nowvalue>=1&&(this._nowvalue=1,this.dir=!1)):(this._nowvalue-=.001,this._nowvalue<=0&&(this._nowvalue=0,this.dir=!0)),this.list_0.scrollPane.setPercX(this._nowvalue))},CpaDownsView.prototype.itemrenderlist=function(e,t){e<this._nowList.length&&t.showData(this._nowList[e],!0)},CpaDownsView.prototype.yqhomedataHandler=function(){this.c_state.selectedIndex=1,this._nowList=o.Recommend.cainixihuanData,this.list_0.numItems=this._nowList.length;for(var e=0;e<this._nowList.length;e++);this._isStart=!0,this._iscanmove=!0,r.TimerService.Instance.addUpdateTarget(this)},CpaDownsView.prototype.dispose=function(){r.TimerService.Instance.removeUpdateTarget(this),e.prototype.dispose.call(this)},CpaDownsView}(n.PanelChildControl);a.default=l},{"../Control/PanelChildControl":25,"../Control/SceneControl":29,"../Time/TimerService":59,"./CpaEvent":53,"./RecommendView":55}],53:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function CpaEvent(){}return CpaEvent.YQHomeData="CpaEvent_YQHomeData",CpaEvent}();a.default=n},{}],54:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelChildControl"),i=e("../utils/GameUtils"),o=e("../WXSDK/FYHD_Sdk"),r=function(e){function CpaItem(){var t=e.call(this)||this;return t.ispenchoutipan=!1,t}return __extends(CpaItem,e),CpaItem.prototype.onInit=function(){this.name="capItem",this.AddEventByType(this,Laya.Event.CLICK,this,this.onbtnclick)},CpaItem.prototype.onbtnclick=function(){if(this._vo){var e=this._vo;o.FYHD_Sdk.ShowHuTuiJump(e,this.ispenchoutipan)}},CpaItem.prototype.showData=function(e,t){void 0===t&&(t=!1),this.ispenchoutipan=t,this._vo=e,e&&(this.load_icon.url=e.icon,this.txt_word&&(this.txt_word.text=e.togame_name),this.img_tip&&(this.img_tip.visible=Math.random()>.5),this.txt_word1&&(this.txt_word1.text=i.GameUtils.randRangeint(235470,1561430).toString()+"人玩"))},CpaItem}(n.PanelChildControl);a.default=r},{"../Control/PanelChildControl":25,"../WXSDK/FYHD_Sdk":71,"../utils/GameUtils":87}],55:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../utils/DispatcherManager"),i=e("./CpaEvent"),o=e("../WXSDK/FYHD_Sdk"),r=function(){return function(e){this.game_flg=e.game_flg,this.game_id=e.game_id,this.game_name=e.game_name,this.id=e.id,this.location_flg=e.location_flg,this.location_id=e.location_id,this.location_name=e.location_name,this.matter_type=e.matter_type}}();a.recommendPan=r;var s=function(){function Recommend(){Recommend.InitData()}return Recommend.InitData=function(){for(var e in Recommend.cainixihuanData=Recommend.GetCaiNiXiaHuanDatas(),Recommend.jiesuanData=Recommend.GetJIeSuanDatas(),Recommend.gdyxData=Recommend.GetGDYXDatas(),Recommend.baokuanyouxiData=Recommend.GetBaoKuanYouXiDatas(),Recommend.moreData=Recommend.GetMoreDatas(),o.FYHD_Sdk.pushData)Recommend.recommendDic[o.FYHD_Sdk.pushData[e].location_flg]=new r(o.FYHD_Sdk.pushData[e]);Recommend.getdata=!0,n.DispatcherManager.dispatchEvent(i.default.YQHomeData),console.log("互推数据初始化recommend--------------")},Recommend.GetSSDatas=function(){var e=[];if(!o.FYHD_Sdk.pushData)return e;for(var t=0;t<o.FYHD_Sdk.pushData.length;t++)e.push(new l(o.FYHD_Sdk.pushData[t]));return e},Recommend.GetCaiNiXiaHuanDatas=function(){var e=[];if(!o.FYHD_Sdk.pushData)return e;for(var t=0;t<o.FYHD_Sdk.pushData.length;t++)e.push(new l(o.FYHD_Sdk.pushData[t]));return e},Recommend.GetMoreDatas=function(){var e=[];if(!o.FYHD_Sdk.pushData)return e;for(var t=0;t<o.FYHD_Sdk.pushData.length;t++)e.push(new l(o.FYHD_Sdk.pushData[t]));return e},Recommend.GetBaoKuanYouXiDatas=function(){var e=[];if(!o.FYHD_Sdk.pushData)return e;for(var t=0;t<o.FYHD_Sdk.pushData.length;t++)e.push(new l(o.FYHD_Sdk.pushData[t]));return e},Recommend.GetJIeSuanDatas=function(){var e=[];if(!o.FYHD_Sdk.pushData)return e;for(var t=0;t<o.FYHD_Sdk.pushData.length;t++)e.push(new l(o.FYHD_Sdk.pushData[t]));return e},Recommend.GetGDYXDatas=function(){var e=[];if(!o.FYHD_Sdk.pushData)return e;for(var t=0;t<o.FYHD_Sdk.pushData.length;t++)e.push(new l(o.FYHD_Sdk.pushData[t]));return e},Recommend.getdata=!1,Recommend.recommendDic={},Recommend.cainixihuanData=[],Recommend.baokuanyouxiData=[],Recommend.gdyxData=[],Recommend.jiesuanData=[],Recommend.moreData=[],Recommend}();a.Recommend=s;var l=function(){return function(e){this.icon=e.icon,this.to_appid=e.to_appid,this.togame_name=e.togame_name,this.jump_path=e.jump_path,this.jump_type=e.jump_type,this.panel=e.panel,this.qrcode=e.qrcode}}();a.RecommendItem=l;var c=function(){return function(){}}();a.default=c},{"../WXSDK/FYHD_Sdk":71,"../utils/DispatcherManager":85,"./CpaEvent":53}],56:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelChildControl"),i=e("./RecommendView"),o=e("../Time/TimerService"),r=function(e){function ShiwantuijianView(){var t=e.call(this)||this;return t._iscanmove=!1,t._movetime=0,t._flushtime=0,t.dir=!0,t._nowvalue=0,t}return __extends(ShiwantuijianView,e),ShiwantuijianView.prototype.onInit=function(){this.initView(),this.initEvent()},ShiwantuijianView.prototype.initView=function(){if(this.list_0.setVirtual(),this.list_0.itemRenderer=Laya.Handler.create(this,this.itemrenderlist,null,!1),this._nowlist=i.Recommend.jiesuanData,this._nowlist.length>0){this.list_0.numItems=this._nowlist.length,this.visible=!0;for(var e=0;e<this._nowlist.length;e++);this._isStart=!0,this._iscanmove=!0,o.TimerService.Instance.addUpdateTarget(this)}else this.visible=!1},ShiwantuijianView.prototype.initEvent=function(){this.AddEventByType(this.list_0,Laya.Event.MOUSE_DOWN,this,this.downclick),this.AddEventByType(this.list_0,Laya.Event.MOUSE_UP,this,this.upclick),this.AddEventByType(this.list_0,Laya.Event.MOUSE_OUT,this,this.upclick)},ShiwantuijianView.prototype.downclick=function(){this._isdown=!0,this._iscanmove=!1,Laya.timer.clear(this,this.timeoutCallback)},ShiwantuijianView.prototype.timeoutCallback=function(){this._iscanmove=!0},ShiwantuijianView.prototype.upclick=function(){this._isdown&&(this._isdown=!1,this._nowvalue=this.list_0.scrollPane.percY,Laya.timer.once(2e3,this,this.timeoutCallback))},ShiwantuijianView.prototype.itemrenderlist=function(e,t){e<this._nowlist.length&&t.showData(this._nowlist[e],!0)},ShiwantuijianView.prototype.update=function(e){this._isStart&&this.list_0.scrollPane&&this._nowlist&&this._nowlist.length>0&&this._iscanmove&&(this.dir?(this._nowvalue+=.001,this._nowvalue>=1&&(this._nowvalue=1,this.dir=!1)):(this._nowvalue-=.001,this._nowvalue<=0&&(this._nowvalue=0,this.dir=!0)),this.list_0.scrollPane.setPercY(this._nowvalue))},ShiwantuijianView.prototype.dispose=function(){this._iscanmove=!1,o.TimerService.Instance.removeUpdateTarget(this),e.prototype.dispose.call(this)},ShiwantuijianView}(n.PanelChildControl);a.default=r},{"../Control/PanelChildControl":25,"../Time/TimerService":59,"./RecommendView":55}],57:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./RecommendView"),i=e("../View/ViewManager"),o=e("../Control/PanelBaseControl"),r=e("../utils/GameUtils"),s=e("../WXSDK/FYHD_Sdk"),l=function(e){function TuijianView(){return e.call(this,"main","tuijianView")||this}return __extends(TuijianView,e),TuijianView.prototype.initView=function(){this.list_1.setVirtual(),this.list_1.itemRenderer=Laya.Handler.create(this,this.itemrenderlist1,null,!1),this.list_2.setVirtual(),this.list_2.itemRenderer=Laya.Handler.create(this,this.itemrenderlist2,null,!1),this._nowlist1=n.Recommend.gdyxData,this._nowlist2=n.Recommend.gdyxData,this.list_1.numItems=7,this.list_2.numItems=this._nowlist2.length},TuijianView.prototype.initEvent=function(){this.AddEventByType(this.btn_close,Laya.Event.CLICK,this,this.onclosefun),this.AddEventByType(this.more,Laya.Event.CLICK,this,this.JumpApp)},TuijianView.prototype.itemrenderlist1=function(e,t){e<7&&t.showData(this._nowlist1[e])},TuijianView.prototype.itemrenderlist2=function(e,t){e<this._nowlist2.length&&t.showData(this._nowlist2[e])},TuijianView.prototype.onclosefun=function(){i.ViewManager.Instance.close(TuijianView)},TuijianView.prototype.JumpApp=function(){var e=r.GameUtils.randRangeint(0,this._nowlist1.length-1);s.FYHD_Sdk.ShowHuTuiJump(this._nowlist1[e],!1)},TuijianView.key="TuijianView",TuijianView}(o.PanelBaseControl);a.default=l},{"../Control/PanelBaseControl":24,"../View/ViewManager":70,"../WXSDK/FYHD_Sdk":71,"../utils/GameUtils":87,"./RecommendView":55}],58:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function TimeUtils(){}return TimeUtils.formatData=function(e){var t=new Date(1e3*e);return this.getTwo(t.getMonth()+1)+"/"+this.getTwo(t.getDate())+" "+this.getTwo(t.getHours())+":"+this.getTwo(t.getMinutes())},TimeUtils.formatData1=function(e){var t=new Date(1e3*e);return t.getMonth()+1+"月"+t.getDate()+"日"},TimeUtils.formatYearMonthDate=function(e){var t=new Date(1e3*e);return t.getFullYear()+"."+(t.getMonth()+1)+"."+t.getDate()},TimeUtils.formatYearMonthDate1=function(e){var t=new Date(1e3*e),a=t.getMonth()+1>=10?(t.getMonth()+1).toString():"0"+(t.getMonth()+1),n=t.getDate()>=10?t.getDate().toString():"0"+t.getDate();return t.getFullYear()+"-"+a+"-"+n},TimeUtils.LXandJXTimeType=function(e){var t="";if(e<0)t="0秒";else if(e<60)t=Math.floor(e)+"秒";else if(e<3600)t=Math.floor(e/60)+"分钟";else{var a;t=(a=Math.floor(e/60/60))+"小时",t+=Math.floor((e-60*a*60)/60)+"分钟"}return t},TimeUtils.formatTime=function(e){var t="",a=Math.floor(e/3600);a>0&&(t+=a>=10?a+":":"0"+a+":");var n=Math.floor(e%3600/60);t+=n>=10?n+":":"0"+n+":";var i=Math.floor(e%60);return t+=i>=10?i+"":"0"+i},TimeUtils.formatTime1=function(e){var t="",a=Math.floor(e/3600);return a>0&&(t+=a+"小时"),t+=Math.floor(e%3600/60)+"分钟",t+=Math.floor(e%60)+"秒"},TimeUtils.formatTime5=function(e){var t="",a=Math.floor(e/3600);a>0&&(t+=a+"小时");var n=Math.floor(e%3600/60);return n>0&&(t+=n+"分"),t+=Math.floor(e%60)+"秒"},TimeUtils.formatTime2=function(e){var t="",a=Math.floor(e/86400);a>0&&(t+=a+"天");var n=Math.floor(e/3600);n>0&&(t+=n+"小时");var i=Math.floor(e%3600/60);return i>0&&(t+=i+"分钟"),t+=Math.ceil(e%60)+"秒"},TimeUtils.formatTime6=function(e){var t="",a=0,n=Math.floor(e/86400);n>0&&(t+=n+"天",a++);var i=Math.floor(e%86400/3600);if(i>0&&(t+=i+"小时",a++),a<2){var o=Math.floor(e%3600/60);o>0&&(t+=o+"分",a++)}a<2&&(t+=Math.ceil(e%60)+"秒");return t},TimeUtils.formatTime3=function(e){var t="";return t+=Math.floor(e/86400)+"天",t+=Math.floor(e%86400/3600)+"小时",t+=Math.floor(e%86400%3600/60)+"分"},TimeUtils.formatTime4=function(e){var t="";e>86400&&(t+=Math.floor(e/86400)+"天");e>3600&&(t+=Math.floor(e%86400/3600)+"小时");e>60&&(t+=Math.floor(e%86400%3600/60)+"分钟");return t},TimeUtils.formatTime4Arr=function(e){var t=[];if(e>=3600){var a=Math.floor(e%86400/3600);t.unshift(String(a))}if(e>=60){var n=Math.floor(e%86400%3600/60);t.unshift(String(n))}return t},TimeUtils.getTwo=function(e){var t=String(e);return t.length<2&&(t="0"+t),t},TimeUtils.datetoTime=function(e){return Date.parse(e)/1e3},TimeUtils}();a.TimeUtils=n},{}],59:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(e){function TimerService(){var t=e.call(this)||this;return t._timeScale=1,t._unscalableList=[],TimerService.ins=t,t}return __extends(TimerService,e),Object.defineProperty(TimerService,"Instance",{get:function(){return null==TimerService.ins?new TimerService:TimerService.ins},enumerable:!0,configurable:!0}),TimerService.prototype.init=function(){Laya.timer.frameLoop(1,this,this.onTimer)},TimerService.prototype.initEvent=function(){},TimerService.prototype.stop=function(){Laya.timer.clear(this,this.onTimer)},TimerService.prototype.recover=function(){this.stop(),Laya.timer.frameLoop(1,this,this.onTimer)},TimerService.prototype.onTimer=function(){var e=0;for(e=0;e<this._unscalableList.length;e++)this._unscalableList[e].update(Laya.timer.delta*this._timeScale)},TimerService.prototype.hasUpdataTarget=function(e){return-1!=this._unscalableList.indexOf(e)},TimerService.prototype.addUpdateTarget=function(e){-1==this._unscalableList.indexOf(e)&&this._unscalableList.push(e)},TimerService.prototype.removeUpdateTarget=function(e){var t=this._unscalableList.indexOf(e);-1!=t&&this._unscalableList.splice(t,1)},Object.defineProperty(TimerService.prototype,"timeScale",{get:function(){return this._timeScale},set:function(e){(e<0||isNaN(e))&&(e=1),this._timeScale=e},enumerable:!0,configurable:!0}),TimerService}(Laya.EventDispatcher);a.TimerService=n},{}],60:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Data/UserDataInfo"),i=e("../Control/LocalDataControl"),o=function(){function TimesTamper(){this.lastgameTime=0,this._serverTime=0,this.iscan=!1,this._onlinedistime=0,this._time=0,this._onlinetime=0}return Object.defineProperty(TimesTamper,"Instance",{get:function(){return null==TimesTamper.ins?new TimesTamper:TimesTamper.ins},enumerable:!0,configurable:!0}),TimesTamper.prototype.init=function(){this.lastgameTime=i.LocalDataControl.Instance.getnum(n.UserDataInfo.lasttime),Laya.timer.frameLoop(1,this,this.update)},TimesTamper.prototype.updateServiceTime=function(e){this._serverTime=Number(e),this.iscan=!0,this._onlinedistime=this._serverTime,i.LocalDataControl.Instance.addstr(n.UserDataInfo.lasttime,this._serverTime.toString())},TimesTamper.prototype.update=function(){this.iscan&&(this._time+=Laya.timer.delta,this._onlinetime+=Laya.timer.delta,this._serverTime+=Laya.timer.delta/1e3,this._time>=3e4&&(this._time=0,i.LocalDataControl.Instance.addstr(n.UserDataInfo.lasttime,this._serverTime.toString())),this._onlinetime>=9e4&&(this._onlinetime=0,this.sendonlineTongji()))},TimesTamper.prototype.sendonlineTongji=function(){this.serverTime-this._onlinedistime>0&&(this._onlinedistime=this.serverTime)},Object.defineProperty(TimesTamper.prototype,"serverTime",{get:function(){return this._serverTime},enumerable:!0,configurable:!0}),TimesTamper}();a.TimesTamper=o},{"../Control/LocalDataControl":23,"../Data/UserDataInfo":35}],61:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelBaseControl"),i=e("../utils/ViewAction"),o=e("../Control/GameStateControl"),r=e("../Agency/AgencyUserMessage"),s=e("../Agency/AgencyInGame"),l=e("../WXSDK/PlayerAccount"),c=e("../View/ViewManager"),h=e("../WXSDK/GuangGao"),u=e("../utils/GameState"),p=e("../Game/Player"),d=e("../PrefabControl/PropManager"),m=e("../utils/DispatcherManager"),f=e("../PrefabControl/CharacterState"),g=e("../WXSDK/RecordManager"),y=e("../WXSDK/ttad"),C=function(e){function CompletePanel(t){var a=e.call(this,"main","gameresult",!1,i.ViewAction.ActionType_none,1)||this;return a.getgold=0,a._position=new Laya.Vector3,a._outPos=new Laya.Vector3,a.scaleDelta=0,a.scale=new Laya.Vector3(.1,.1,.1),a.time=9,a.count=!1,a.fuhuo=!1,a.getgold=t,a}return __extends(CompletePanel,e),CompletePanel.prototype.loadScene=function(){Laya.Scene3D.load("res/threeDimen/scene/ParticleScene/Example_01.ls",Laya.Handler.create(this,function(e){this.scene=Laya.stage.addChildAt(e,0),this.scene.addChild(new Laya.Camera(0,.1,100)).transform.translate(new Laya.Vector3(0,1,0))}))},CompletePanel.prototype.garbageCollection=function(){this.scene.destroy(),this.scene=null,Laya.Resource.destroyUnusedResources()},CompletePanel.prototype.btn1click=function(){0==this.c_state.selectedIndex?this.duihao.visible?this.playvideocallback():(this.getProxy(r.AgencyUserMessage).GoldUp(this.getgold),this.getProxy(r.AgencyUserMessage).LevelUp(),this._gameProxy.returnmainview(!0)):1==this.c_state.selectedIndex?(this.getProxy(r.AgencyUserMessage).GoldUp(this.getgold),this._gameProxy.returnmainview()):2==this.c_state.selectedIndex&&this.sharerevive()},CompletePanel.prototype.onComplete=function(){Laya.Sprite3D.load("res/threeDimen/skinModel/LayaMonkey/LayaMonkey.lh",Laya.Handler.create(this,function(e){this.layaMonkey3D=e,this.scene.addChild(e),this.layaMonkey2D=Laya.stage.addChild(new Laya.Image("res/threeDimen/monkey.png")),Laya.timer.frameLoop(1,this,this.animate)}))},CompletePanel.prototype.animate=function(){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)},CompletePanel.prototype.btn0click=function(){0==this.c_state.selectedIndex?this.playvideocallback():1==this.c_state.selectedIndex?(this.getProxy(r.AgencyUserMessage).GoldUp(this.getgold),this._gameProxy.returnmainview()):2==this.c_state.selectedIndex&&(this.count=!1,this.playvideorevive())},CompletePanel.prototype.playvideorevive=function(){var e=this;y.ttad.ShowVideo(function(t){t?(u.GameState.fuhuocishu--,c.ViewManager.Instance.close(CompletePanel),u.GameState.isdie=!1,p.Player.Instance._iscanMove=!0,p.Player.Instance.nowAction=f.CharacterState.run,""==p.Player.Instance._nowscenename||""==p.Player.Instance._nowbuildname?(console.log("玩家位置----",p.Player.Instance._initPosVec),console.log("玩家速度_moveVec",p.Player.Instance._moveVec),p.Player.Instance._transform.position=new Laya.Vector3(0,1,3)):(console.log("当前场景名字---",p.Player.Instance._nowscenename),console.log("当前建筑名字---",p.Player.Instance._nowbuildname),console.log("建筑物位置----",d.PropManager.getPosVecbyScene(p.Player.Instance._nowscenename,p.Player.Instance._nowbuildname)),p.Player.Instance._transform.position=d.PropManager.getPosVecbyScene(p.Player.Instance._nowscenename,p.Player.Instance._nowbuildname).clone()),p.Player.Instance._speedMoveV3.z=2*-p.Player.Instance._RoleData.movespeed,Laya.timer.once(3e3,e,function(){p.Player.Instance._speedMoveV3.z=-p.Player.Instance._RoleData.movespeed})):e.count=!0})},CompletePanel.prototype.sharerevive=function(){var e=this;g.RecordManager.Instance.ShareVideo(function(t){t?(g.RecordManager.Instance.RecordStart(),u.GameState.fuhuocishu--,c.ViewManager.Instance.close(CompletePanel),u.GameState.isdie=!1,p.Player.Instance._iscanMove=!0,p.Player.Instance.nowAction=f.CharacterState.run,""==p.Player.Instance._nowscenename||""==p.Player.Instance._nowbuildname?(console.log("玩家位置----",p.Player.Instance._initPosVec),p.Player.Instance._transform.position=new Laya.Vector3(0,1,3)):(console.log("当前场景名字---",p.Player.Instance._nowscenename),console.log("当前建筑名字---",p.Player.Instance._nowbuildname),console.log("建筑物位置----",d.PropManager.getPosVecbyScene(p.Player.Instance._nowscenename,p.Player.Instance._nowbuildname)),p.Player.Instance._transform.position=d.PropManager.getPosVecbyScene(p.Player.Instance._nowscenename,p.Player.Instance._nowbuildname).clone()),p.Player.Instance._speedMoveV3.z=2*-p.Player.Instance._RoleData.movespeed,Laya.timer.once(3e3,e,function(){p.Player.Instance._speedMoveV3.z=-p.Player.Instance._RoleData.movespeed})):e.count=!0})},CompletePanel.prototype.playvideocallback=function(){var e=this;y.ttad.ShowVideo(function(t){t&&(e.getProxy(r.AgencyUserMessage).GoldUp(3*e.getgold),e.getProxy(r.AgencyUserMessage).LevelUp(),e._gameProxy.returnmainview(!0),e.BattleBtn.visible=!1)})},CompletePanel.prototype.ShareVideoCallBack=function(){var e=this;g.RecordManager.Instance.ShareVideo(function(t){t&&(e.getProxy(r.AgencyUserMessage).GoldUp(3*e.getgold),e.BattleBtn.visible=!1,e.ShareVideo.visible=!1)})},CompletePanel.prototype.ClickKuang=function(){this.duihao.visible?(this.duihao.visible=!1,this.btn_1.visible=this.duihao.visible,this.btn_2.visible=!this.duihao.visible):(this.duihao.visible=!0,this.btn_1.visible=this.duihao.visible,this.btn_2.visible=!this.duihao.visible)},CompletePanel.prototype.destory=function(){Laya.timer.clear(this,this.CountTime),y.ttad.Clear(),e.prototype.destory.call(this)},CompletePanel.prototype.initView=function(){var e=this;this.tianjia.visible=!1,this.TianJiaAni=this.getTransitionByName("tianjiaani"),this.TianJiaAni.stop(),this.count=!0,this._gameProxy=this.getProxy(s.AgencyInGame),this.c_state=this.getControllerByBame("c_state"),this.txt_gold.text=this.getgold.toString(),this.duihao=this.kuang.getChildAt(1),this.duihao.visible=l.PlayerAccount.CurrentAccount.CurAccountData.Choose,this.share_goldnum=this.ShareVideo.getChildAt(4),this.ShareVideoBtn=this.ShareVideo.getChildAt(1),this.jiesuanbtn=this.ShareVideo.getChildAt(2),this.share_goldnum.text=this.getgold.toString(),this.btn_1.visible=this.duihao.visible,this.btn_2.visible=!this.duihao.visible,u.GameState.recordscree?this.BattleBtn.visible=!1:(this.BattleBtn.visible=!1,l.PlayerAccount.CurrentAccount.CurAccountData.ShowBattleBtn&&(this.BattleBtn.visible=!0)),u.GameState.isdie?u.GameState.fuhuocishu>0?(this.c_state.selectedIndex=2,Laya.timer.loop(1e3,this,this.CountTime)):this.c_state.selectedIndex=1:0==o.GameStateControl.Instance.endGamePlayerArr.length?this.c_state.selectedIndex=0:this.c_state.selectedIndex=1,0==this.c_state.selectedIndex?(this.ShareVideo.visible=!0,this.jiesuanbtn.visible=!1,Laya.timer.once(2e3,this,function(){e.jiesuanbtn.visible=!0})):this.ShareVideo.visible=!1,h.GuangGao.CheatBanner(this.btn_1)},CompletePanel.prototype.playanimator=function(){this.TianJiaAni.play(null,1)},CompletePanel.prototype.ClickJieSuan=function(){this.ShareVideo.visible=!1},CompletePanel.prototype.initEvent=function(){this.AddEventByType(this.btn_0,Laya.Event.CLICK,this,this.btn0click),this.AddEventByType(this.btn_1,Laya.Event.CLICK,this,this.btn1click),this.AddEventByType(this.BattleBtn,Laya.Event.CLICK,this,this.ShareBattle),this.AddEventByType(this.btn_2,Laya.Event.CLICK,this,this.btn1click),this.AddEventByType(this.kuang,Laya.Event.CLICK,this,this.ClickKuang),this.AddEventByType(this.ShareVideoBtn,Laya.Event.CLICK,this,this.ShareVideoCallBack),this.AddEventByType(this.jiesuanbtn,Laya.Event.CLICK,this,this.ClickJieSuan)},CompletePanel.prototype.CountTime=function(){this.count&&this.time>0&&(this.time-=1,this.timenum.text=this.time.toString(),this.time<1&&(Laya.timer.clear(this,this.CountTime),u.GameState.fuhuocishu--,c.ViewManager.Instance.close(CompletePanel),m.DispatcherManager.dispatchEvent(u.GameState.lose)))},CompletePanel.prototype.ShareBattle=function(){var e=this;g.RecordManager.Instance.ShareVideo(function(t){t&&(e.BattleBtn.visible=!1)})},CompletePanel.key="CompletePanel",CompletePanel}(n.PanelBaseControl);a.CompletePanel=C},{"../Agency/AgencyInGame":2,"../Agency/AgencyUserMessage":8,"../Control/GameStateControl":21,"../Control/PanelBaseControl":24,"../Game/Player":40,"../PrefabControl/CharacterState":46,"../PrefabControl/PropManager":49,"../View/ViewManager":70,"../WXSDK/GuangGao":72,"../WXSDK/PlayerAccount":75,"../WXSDK/RecordManager":76,"../WXSDK/ttad":83,"../utils/DispatcherManager":85,"../utils/GameState":86,"../utils/ViewAction":93}],62:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelBaseControl"),i=e("../utils/GameUtils"),o=e("../Time/TimerService"),r=e("../WXSDK/GuangGao"),s=e("../utils/ViewAction"),l=e("./ViewManager"),c=e("../Control/SceneControl"),h=e("../Control/GameStateControl"),u=e("../utils/GlobalTip"),p=e("../WXSDK/ttad"),d=function(e){function EggPanel(){var t=e.call(this,"main","eggview",!1,s.ViewAction.ActionType_none,1)||this;return t._isComplete=!1,t._isShowBanner=!1,t._bannerVal=.5,t._maxClickCnt=18,t._clickCnt=0,t._interval=100,t._decrement=1,t._time=0,t}return __extends(EggPanel,e),EggPanel.prototype.initView=function(){this.hitani=this.getTransitionByName("hitani"),this.pro_0.value=1,this._bannerVal=i.GameUtils.randRangefloat(.2,.4),o.TimerService.Instance.addUpdateTarget(this),p.ttad.Clear();var e=Laya.stage.height;this.btn_1.y=e-this.btn_1.height-15,this.getrewardbtn.y=this.btn_1.y,this.getrewardbtn.visible=!1,0==c.SceneControl.EggGGroup&&(this.n6.visible=!0)},EggPanel.prototype.bannercallback=function(){},EggPanel.prototype.initEvent=function(){this.AddEventByType(this.btn_1,Laya.Event.CLICK,this,this.qiaoDa),this.AddEventByType(this.btn_close,Laya.Event.CLICK,this,EggPanel.onclosefun),this.AddEventByType(this.getrewardbtn,Laya.Event.CLICK,this,EggPanel.VideoGetReward)},EggPanel.prototype.update=function(e){this._time+=e,this._time>=this._interval&&(this._time=0,this.Daojishi())},EggPanel.prototype.Daojishi=function(){var e=this.pro_0.value;(e-=this._decrement)<=0&&(e=1),this.pro_0.value=e,this._clickCnt=Math.ceil(e*this._maxClickCnt/100)},EggPanel.prototype.qiaoDa=function(){var e=this;if(!this._isComplete){null==this.hitani||this.hitani.playing||this.hitani.play(null,1),this._clickCnt++,this._clickCnt>this._maxClickCnt&&(this._clickCnt=this._maxClickCnt);var t=this._clickCnt/this._maxClickCnt;t>1&&(t=1),this.pro_0.value=100*t,t>=this._bannerVal&&!this._isShowBanner&&(this._isShowBanner=!0,this.getrewardbtn.visible=!0,Laya.timer.once(2e3,this,function(){e.getrewardbtn.visible=!1})),t>=1&&(this._isComplete=!0,EggPanel.getreward())}},EggPanel.getreward=function(){u.GlobalTip.Instance.showWordTips("获得开局加速"),EggPanel.onclosefun()},EggPanel.VideoGetReward=function(){p.ttad.ShowVideo(function(e){e?(u.GlobalTip.Instance.showWordTips("获得开局加速"),EggPanel.onclosefun()):EggPanel.onclosefun()})},EggPanel.prototype.hidebanner=function(){r.GuangGao.hidebanner()},EggPanel.onclosefun=function(){l.ViewManager.Instance.close(EggPanel)},EggPanel.prototype.destory=function(){o.TimerService.Instance.removeUpdateTarget(this),e.prototype.destory.call(this),h.GameStateControl.Instance.entergame(!0)},EggPanel.key="EggPanel",EggPanel}(n.PanelBaseControl);a.default=d},{"../Control/GameStateControl":21,"../Control/PanelBaseControl":24,"../Control/SceneControl":29,"../Time/TimerService":59,"../WXSDK/GuangGao":72,"../WXSDK/ttad":83,"../utils/GameUtils":87,"../utils/GlobalTip":88,"../utils/ViewAction":93,"./ViewManager":70}],63:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelBaseControl"),i=e("../utils/GameUtils"),o=e("../Time/TimerService"),r=e("../WXSDK/GuangGao"),s=e("./ViewManager"),l=e("../utils/GlobalTip"),c=e("../WXSDK/PlayerAccount"),h=e("../Data/RoleData"),u=e("../WXSDK/ttad"),p=function(e){function GiftView(){var t=e.call(this,"main","giftcheatview")||this;return t._isComplete=!1,t._isShowBanner=!1,t._bannerVal=.5,t._maxClickCnt=18,t._clickCnt=0,t._interval=100,t._decrement=1,t._time=0,t}return __extends(GiftView,e),GiftView.prototype.initView=function(){this.anniu=this.item.asCom.getChildAt(2),this.kuaisudianji=this.item.asCom.getChildAt(0),this.shou=this.item.asCom.getChildAt(3),this.di=this.item.asCom.getChildAt(1),this.getrewardbtn=this.item.asCom.getChildAt(4),this.getrewardbtn.visible=!1,this.clickani=this.item.getTransition("clickbtnani"),this.jindu.value=1,this._bannerVal=i.GameUtils.randRangefloat(.2,.4),o.TimerService.Instance.addUpdateTarget(this),u.ttad.Clear(),Laya.timer.loop(2e3,this,this.playAnimator)},GiftView.prototype.playAnimator=function(){this.clickani.play(null,1)},GiftView.prototype.initEvent=function(){this.AddEventByType(this.anniu,Laya.Event.CLICK,this,this.qiaoDa),this.AddEventByType(this.getrewardbtn,Laya.Event.CLICK,this,this.VideoGetReward)},GiftView.prototype.update=function(e){this._time+=e,this._time>=this._interval&&(this._time=0,this.Daojishi())},GiftView.prototype.Daojishi=function(){var e=this.jindu.value;(e-=this._decrement)<=0&&(e=1),this.jindu.value=e,this._clickCnt=Math.ceil(e*this._maxClickCnt/100)},GiftView.prototype.qiaoDa=function(){var e=this;if(this.shou.visible&&(this.shou.visible=!1,this.kuaisudianji.visible=!1,Laya.timer.clear(this,this.playAnimator)),!this._isComplete){this._clickCnt++,this._clickCnt>this._maxClickCnt&&(this._clickCnt=this._maxClickCnt);var t=this._clickCnt/this._maxClickCnt;t>1&&(t=1),this.jindu.value=100*t,t>=this._bannerVal&&!this._isShowBanner&&(this._isShowBanner=!0,this.getrewardbtn.visible=!0,Laya.timer.once(2e3,this,function(){e.getrewardbtn.visible=!1})),t>=1&&(this._isComplete=!0,GiftView.getreward())}},GiftView.getreward=function(){h.RoleData.Instance.Money+=c.PlayerAccount.CurrentAccount.CurAccountData.CheatReward,l.GlobalTip.Instance.showWordTips("获得"+c.PlayerAccount.CurrentAccount.CurAccountData.CheatReward+"金币"),GiftView.onclosefun()},GiftView.prototype.VideoGetReward=function(){u.ttad.ShowVideo(function(e){e?(h.RoleData.Instance.Money+=c.PlayerAccount.CurrentAccount.CurAccountData.CheatReward,l.GlobalTip.Instance.showWordTips("获得"+c.PlayerAccount.CurrentAccount.CurAccountData.CheatReward+"金币"),GiftView.onclosefun()):GiftView.onclosefun()})},GiftView.prototype.hidebanner=function(){r.GuangGao.hidebanner()},GiftView.onclosefun=function(){s.ViewManager.Instance.close(GiftView)},GiftView.prototype.destory=function(){r.GuangGao.hidebanner(),o.TimerService.Instance.removeUpdateTarget(this),e.prototype.destory.call(this)},GiftView.key="GiftView",GiftView}(n.PanelBaseControl);a.default=p},{"../Control/PanelBaseControl":24,"../Data/RoleData":33,"../Time/TimerService":59,"../WXSDK/GuangGao":72,"../WXSDK/PlayerAccount":75,"../WXSDK/ttad":83,"../utils/GameUtils":87,"../utils/GlobalTip":88,"./ViewManager":70}],64:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelBaseControl"),i=e("../utils/DispatcherManager"),o=e("../utils/GameState"),r=function(e){function WordTipsPanel(){var t=e.call(this,"loading","wordTips")||this;return t.nowword="",t}return __extends(WordTipsPanel,e),WordTipsPanel.prototype.showText=function(){var e=new Laya.Text;e.text="Orientation-Portrait",e.color="gray",e.font="Impact",e.fontSize=50,e.x=Laya.stage.width-e.width>>1,e.y=Laya.stage.height-e.height>>1,Laya.stage.addChild(e)},WordTipsPanel.prototype.showWord=function(e){this.nowword=e,this.text_word.text=e,this.t1.play(Laya.Handler.create(this,this.playEndCallback),1)},WordTipsPanel.prototype.onInit=function(){e.prototype.onInit.call(this),this.t1=this.getpanelTransition("t1")},WordTipsPanel.prototype.createCantralRect=function(){this.rect=new Laya.Sprite,this.rect.graphics.drawRect(-100,-100,200,200,"gray"),Laya.stage.addChild(this.rect),this.updateRectPos()},WordTipsPanel.prototype.updateRectPos=function(){this.rect.x=Laya.stage.width/2,this.rect.y=Laya.stage.height/2},WordTipsPanel.prototype.playEndCallback=function(){i.DispatcherManager.dispatchEvent(o.GameState.removeselect,this)},WordTipsPanel.key="WordTipsPanel",WordTipsPanel}(n.PanelBaseControl);a.WordTipsPanel=r},{"../Control/PanelBaseControl":24,"../utils/DispatcherManager":85,"../utils/GameState":86}],65:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(e){function LoadingPanel(){return e.call(this,"loading","loading")||this}return __extends(LoadingPanel,e),LoadingPanel.prototype.onInit=function(){e.prototype.onInit.call(this)},LoadingPanel.prototype.showWord=function(e){this.pro.value=e},LoadingPanel.prototype.onBoyClick=function(e){var t=e.target;1===t.scaleX?t.scale(1.2,1.2):t.scale(1,1)},LoadingPanel.prototype.onTxtClick=function(e){e.stopPropagation()},LoadingPanel.prototype.destory=function(){this.clearEvent(),e.prototype.destory.call(this)},LoadingPanel.key="LoadingPanel",LoadingPanel}(e("../Control/PanelBaseControl").PanelBaseControl);a.LoadingPanel=n},{"../Control/PanelBaseControl":24}],66:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelBaseControl"),i=e("../utils/ViewAction"),o=e("../View/ViewManager"),r=e("../CFG/LotteryCFG"),s=e("../Config/AssetPath"),l=e("../CFG/RoleCFG"),c=e("../Agency/AgencyLottery"),h=e("../WXSDK/GuangGao"),u=e("../WXSDK/ttad"),p=function(e){function LotteryPanel(){return e.call(this,"main","LotteryView",!1,i.ViewAction.ActionType_none,1)||this}return __extends(LotteryPanel,e),LotteryPanel.prototype.showLogger=function(){this.logger=new Laya.Text,this.logger.fontSize=30,this.logger.color="#FFFFFF",this.logger.align="center",this.logger.valign="middle",this.logger.size(Laya.stage.width,Laya.stage.height),this.logger.text="等待响应...\n",Laya.stage.addChild(this.logger)},LotteryPanel.prototype.onHttpRequestError=function(e){console.log(e)},LotteryPanel.prototype.initEvent=function(){this.AddEventByType(this.backbtn,Laya.Event.CLICK,this,this.onclosefun),this.AddEventByType(this.lotterybtn,Laya.Event.CLICK,this,this.choujiangclick)},LotteryPanel.prototype.playComplte=function(){this.tw&&(this.tw.clear(),this.tw=null),this.backbtn.enabled=!0,this.lotterybtn.enabled=!0,this.agencylottery.getreward(this._selectcfg)},LotteryPanel.prototype.onclosefun=function(){this.tw&&(this.tw.clear(),this.tw=null),h.GuangGao.Clear(),o.ViewManager.Instance.close(LotteryPanel)},LotteryPanel.prototype.initView=function(){this.agencylottery=this.getProxy(c.AgencyLottery);for(var e=r.default.vec,t=0;t<e.length;t++){var a=e[t];if(1==a.type)this["icon_"+t].url=fairygui.UIPackage.getItemURL("main","img_gold"),this["txt_"+t].text="X"+a.value;else{var n=l.default.dict[a.value];this["icon_"+t].url=s.AssetPath.getroleicon(n.icon),this["txt_"+t].text=n.rolename}}h.GuangGao.CheatBanner(this.lotterybtn)},LotteryPanel.prototype.onSocketClose=function(){console.log("Socket closed")},LotteryPanel.prototype.onMessageReveived=function(e){console.log("Message from server:"),"string"==typeof e?console.log(e):ArrayBuffer},LotteryPanel.prototype.choujiangclick=function(){this.videocallback()},LotteryPanel.prototype.videocallback=function(){var e=this;u.ttad.ShowVideo(function(t){t&&e.startPlay()})},LotteryPanel.prototype.startPlay=function(){var e=this.agencylottery.GetReward();this._selectcfg=r.default.vec[e],this.backbtn.enabled=!1,this.lotterybtn.enabled=!1,this._nowgetIndex=e;var t=2160+45*this._nowgetIndex-15;0==this.item_panel.rotation?this._tweeObject={value:0}:this._tweeObject={value:45*this._preIndex-15},this._preIndex=this._nowgetIndex,this.tw=laya.utils.Tween.to(this._tweeObject,{value:t},3e3,laya.utils.Ease.quadInOut,Laya.Handler.create(this,this.playComplte)),this.tw.update=Laya.Handler.create(this,function(){var e=this._tweeObject.value%360;this.item_panel.rotation=e},null,!1)},LotteryPanel.key="LotteryPanel",LotteryPanel}(n.PanelBaseControl);a.LotteryPanel=p},{"../Agency/AgencyLottery":4,"../CFG/LotteryCFG":12,"../CFG/RoleCFG":14,"../Config/AssetPath":15,"../Control/PanelBaseControl":24,"../View/ViewManager":70,"../WXSDK/GuangGao":72,"../WXSDK/ttad":83,"../utils/ViewAction":93}],67:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelBaseControl"),i=e("../Control/GameStateControl"),o=e("../utils/DispatcherManager"),r=e("../utils/GameState"),s=e("../PrefabControl/PropManager"),l=e("../Agency/AgencyUserMessage"),c=e("../Data/UserInfoEvent"),h=e("../Agency/AgencySkin"),u=e("../Agency/AgencyInGame"),p=e("../View/ViewManager"),d=e("../Agency/AgencyLottery"),m=e("../Push/TuijianView"),f=e("../WXSDK/ttad"),g=e("../WXSDK/Sdk"),y=e("../WXSDK/PlayerAccount"),C=e("../Config/AssetPath"),_=e("../Control/LocalDataControl"),v=e("../Data/UserDataInfo"),w=e("../Control/SceneControl"),S=function(e){function MainPanel(){var t=e.call(this,"main","mainview")||this;return t.phoenixWidth=550,t.phoenixHeight=400,t.bgColorTweener=new Laya.Tween,t.gradientInterval=2e3,t.bgColorChannels={r:99,g:0,b:255},t.isShowSign=!1,t.PaoKuSign="PaoKuSignInfo",t.SignInfo=null,MainPanel.instance=t,t}return __extends(MainPanel,e),MainPanel.prototype.updateUserDataHandler=function(){this.txt_gold.text=this.agencyusermessage.RoleData.Money.toString()},MainPanel.prototype.returnmainHandler=function(){this.agencyusermessage.RoleData;this.c_state.selectedIndex=1},MainPanel.prototype.onInit=function(){e.prototype.onInit.call(this)},MainPanel.prototype.createPhoenixes=function(){var e=Math.min(Laya.stage.width/(2*this.phoenixWidth),Laya.stage.height/this.phoenixHeight);(void 0).blendMode="lighter",(void 0).scale(e,e),(void 0).y=(Laya.stage.height-this.phoenixHeight*e)/2,(void 0).scale(e,e),(void 0).x=this.phoenixWidth*e,(void 0).y=(Laya.stage.height-this.phoenixHeight*e)/2},MainPanel.prototype.initView=function(){this.ExitBtn.visible=!1,this.MoreFunBtn.visible=!1,this.MoreGameBtn.visible=!1,f.ttad.Showbanner(),this.MoreFunBtnScale=this.getTransitionByName("morefunbtnscale"),Laya.timer.loop(1e3,this,this.playanimator2),this.SkinAni=this.SkinBtn.getTransition("skinani"),this.LotteryAni=this.LotteryBtn.getTransition("lotteryani"),this.MoreAni=this.MoreGameBtn.getTransition("moreani"),Laya.timer.loop(3e3,this,this.playanimator),this.agencyusermessage=this.getProxy(l.AgencyUserMessage),s.PropManager.pro_jindu=this.pro_dis,s.PropManager.txt_mingci=this.txt_mingci,this.c_state=this.getControllerByBame("c_state"),i.GameStateControl.Instance.setClickPanel(this.load_clickpanel),this.returnmainHandler(),this.updateUserDataHandler(),this.InitSignItem()},MainPanel.prototype.playanimator=function(){this.SkinAni.play(null,1),this.LotteryAni.play(null,1),this.MoreAni.play(null,1)},MainPanel.prototype.playanimator2=function(){this.MoreFunBtnScale.play(null,1)},MainPanel.prototype.choujiangclick=function(){w.SceneControl.IsShowSign||(f.ttad.Clear(),this.getProxy(d.AgencyLottery).openView())},MainPanel.prototype.tuijianclick=function(){w.SceneControl.IsShowSign||p.ViewManager.Instance.add(m.default)},MainPanel.prototype.skinclick=function(){w.SceneControl.IsShowSign||(f.ttad.Clear(),this.getProxy(h.AgencySkin).openview())},MainPanel.prototype.moreclick=function(){w.SceneControl.IsShowSign||f.ttad.CreateMoreGameBtn()},MainPanel.prototype.btnclick=function(){w.SceneControl.IsShowSign||(r.GameState.GameNum++,f.ttad.Clear(),this.c_state.selectedIndex=2,this.txt_lv.text=this.agencyusermessage.RoleData.getNowServerLevel().toString(),this.getProxy(u.AgencyInGame).startGame())},MainPanel.prototype.setclick=function(){},MainPanel.prototype.mapLoaded=function(){this.layer=this.tiledMap.getLayerByIndex(0);var e=32*Math.tan(180/Math.PI*30);this.sprite=new Laya.Sprite,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)},MainPanel.prototype.initEvent=function(){this.AddEventByType(this.load_start,Laya.Event.CLICK,this,this.btnclick),this.AddEventByType(this.SkinBtn,Laya.Event.CLICK,this,this.skinclick),this.addDataEvent(r.GameState.returnMainView,this,this.returnmainHandler),this.AddEventByType(this.LotteryBtn,Laya.Event.CLICK,this,this.choujiangclick),this.addDataEvent(c.UserInfoEvent.UserInfoEvent_updateUserData,this,this.updateUserDataHandler)},MainPanel.prototype.InitSignItem=function(){this.LoadSignData();var e=!0;this.getSystemTime()==this.SignInfo.time?e=!1:this.SignInfo.FisstLoad=0,1==this.SignInfo.FisstLoad&&(e=!1),w.SceneControl.IsShowSign=e,this.SignPanel.visible=e,e&&this.SignFun()},MainPanel.prototype.btn_SignFun=function(){this.getSystemTime()==this.SignInfo.time&&(this.isShowSign=!0),this.SignFun(),this.isShowSign&&(g.WxApi.ShowTxt("已签到"),this.SignSelectedMoney="0")},MainPanel.prototype.SignFun=function(){this.SignItem=new Array,this.SignItem.push(this.SignItem1),this.SignItem.push(this.SignItem2),this.SignItem.push(this.SignItem3),this.SignItem.push(this.SignItem4),this.SignItem.push(this.SignItem5),this.SignItem.push(this.SignItem6),this.SignItem.push(this.SignItem7),this.SignTickImage=this.SignAd.asCom.getChildAt(2);var e=this.SignAd.asCom.getChildAt(1);this.signAdButton=this.SignAd.asCom.getChildAt(3),this.signNoramButton=this.SignAd.asCom.getChildAt(4),this.SignDanbeiBtn=this.SignAd.asCom.getChildAt(5),this.SignTickImage.visible=y.PlayerAccount.CurrentAccount.CurAccountData.ShowSign,this.SignDanbeiBtn.visible=!1,this.AddEventByType(e,Laya.Event.CLICK,this,this.SignTickButtonFun),this.AddEventByType(this.signAdButton,Laya.Event.CLICK,this,this.SignAdButtonFun),this.AddEventByType(this.signNoramButton,Laya.Event.CLICK,this,this.SignNormalButtonFun);var t=this.SignInfo.day,a=100;t<7?a=100:(a=107,t%=7),this.SignPiFu=null,this.SignSelectedMoney="0";for(var n=0;n<this.SignItem.length;n++){var i=y.PlayerAccount.CurrentAccount.CurAccountData.GetRewardConfig(a+1+n),o=null;if(1e3!=i.reward_item&&Number(i.reward_item)>6e3){var r=Number(i.reward_item)%6e3;o=y.PlayerAccount.CurrentAccount.CurAccountData.GetSkinAttr(r),console.log(o)}var s,l=!0,c=!0;n<t?(l=!0,c=!1):n==t?(l=!1,c=!0):(l=!1,c=!1),s=n<6?"第 "+(n+1)+" 天":"豪华皮肤",this.SetSignItemInfo(this.SignItem[n],s,i,l,c,o)}f.ttad.Showbanner()},MainPanel.prototype.SetSignItemInfo=function(e,t,a,n,i,o){if(console.log(a),null==o){console.log(111111111111),e.asCom.getChildAt(2).text=t,e.asCom.getChildAt(3).text=a.reward_num,e.asCom.getChildAt(5).visible=!1,n?(e.asCom.getChildAt(1).visible=!1,e.asCom.getChildAt(6).visible=!0,e.asCom.getChildAt(7).visible=!0):i?(e.asCom.getChildAt(1).visible=!0,e.asCom.getChildAt(7).visible=!1,e.asCom.getChildAt(6).visible=!1,this.SignSelectedItem=e,this.SignSelectedText=t,this.SignSelectedMoney=a.reward_num):(e.asCom.getChildAt(1).visible=!1,e.asCom.getChildAt(6).visible=!1,e.asCom.getChildAt(7).visible=!1)}else{console.log(2222222222);e.asCom.getChildAt(2);e.asCom.getChildAt(3).visible=!1,e.asCom.getChildAt(4).visible=!1;var r=e.asCom.getChildAt(5);n?(r.icon=C.AssetPath.getroleicon(o.icon),e.asCom.getChildAt(1).visible=!1,e.asCom.getChildAt(6).visible=!0,e.asCom.getChildAt(7).visible=!0):i?(e.asCom.getChildAt(1).visible=!0,e.asCom.getChildAt(7).visible=!1,e.asCom.getChildAt(6).visible=!1,this.SignSelectedItem=e,this.SignSelectedText=t,this.SignSelectedMoney="0",this.SignPiFu=o,r.visible=!0,r.icon=C.AssetPath.getroleicon(this.SignPiFu.icon)):(r.icon=C.AssetPath.getroleicon(o.icon),e.asCom.getChildAt(1).visible=!1,e.asCom.getChildAt(6).visible=!1,e.asCom.getChildAt(7).visible=!1)}},MainPanel.prototype.SignButtonFun=function(){var e=this;console.log("收取了"),this.getSystemTime!=this.SignInfo.time&&(this.SignAd.visible=!0,Laya.timer.once(3e3,this,function(){e.signNoramButton.visible=!0}),this.SetSignItemInfo(this.SignSelectedItem,this.SignSelectedText,this.SignSelectedMoney,!0,!1,this.SignPiFu),this.SaveSignData())},MainPanel.prototype.SignTickButtonFun=function(){this.SignTickImage.visible=!this.SignTickImage.visible},MainPanel.prototype.SignAdButtonFun=function(){this.WinAdButtonFun()},MainPanel.prototype.SignNormalButtonFun=function(){this.SaveSignData(),1==this.SignTickImage.visible?this.WinAdButtonFun():(this.getProxy(l.AgencyUserMessage).GoldUp(1*Number(this.SignSelectedMoney)),null!=this.SignPiFu&&this.SignAddPifu(),this.updateUserDataHandler(),w.SceneControl.IsShowSign=!1,this.SignPanel.visible=!1,f.ttad.Clear())},MainPanel.prototype.WinAdButtonFun=function(){var e=this;g.WxApi.recordAldEvent("签到..."),Laya.Browser.onMobile&&f.ttad.ShowVideo(function(t){console.log("播放视频返回成功"+t),t&&(console.log("播放视频返回"),e.getProxy(l.AgencyUserMessage).GoldUp(2*Number(e.SignSelectedMoney)),null!=e.SignPiFu&&e.SignAddPifu(),e.SaveSignData(),e.SignPanel.visible=!1,w.SceneControl.IsShowSign=!1,e.updateUserDataHandler(),f.ttad.Clear())})},MainPanel.prototype.LoadSignData=function(){if(this.SignInfo=Laya.LocalStorage.getJSON(this.PaoKuSign),0==this.SignInfo||null==this.SignInfo){this.getSystemTime();this.SignInfo={day:0,time:0,FisstLoad:0},Laya.LocalStorage.setJSON(this.PaoKuSign,this.SignInfo)}console.log("asdasd")},MainPanel.prototype.SaveSignData=function(){this.SignInfo.FisstLoad=1,this.SignInfo.day++,this.SignInfo.time=this.getSystemTime(),Laya.LocalStorage.setJSON(this.PaoKuSign,this.SignInfo)},MainPanel.prototype.getSystemTime=function(){var e=new Date,t=e.getMonth()+1;console.log("月:"+t.toString());var a=e.getDate();return console.log("日:"+a.toString()),Number(t+""+a)},MainPanel.prototype.SignAddPifu=function(){for(var e=_.LocalDataControl.Instance.GetLocalCaCheData(v.UserDataInfo.skin),t=this.SignPiFu.id,a=this.getProxy(h.AgencySkin),n=null,i=0;i<a.pifuArr.length&&(n=a.pifuArr[i]).roleCFG.id!=t;i++);n.state=1,h.AgencySkin.instance.AddLocalSkinData(n.roleCFG.id,n.state,n.hasnum),o.DispatcherManager.dispatchEvent(r.GameState.updateSKinView),console.log("获取皮肤"),console.log(e)},MainPanel.key="MainPanel",MainPanel}(n.PanelBaseControl);a.MainPanel=S},{"../Agency/AgencyInGame":2,"../Agency/AgencyLottery":4,"../Agency/AgencySkin":6,"../Agency/AgencyUserMessage":8,"../Config/AssetPath":15,"../Control/GameStateControl":21,"../Control/LocalDataControl":23,"../Control/PanelBaseControl":24,"../Control/SceneControl":29,"../Data/UserDataInfo":35,"../Data/UserInfoEvent":36,"../PrefabControl/PropManager":49,"../Push/TuijianView":57,"../View/ViewManager":70,"../WXSDK/PlayerAccount":75,"../WXSDK/Sdk":77,"../WXSDK/ttad":83,"../utils/DispatcherManager":85,"../utils/GameState":86}],68:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelBaseControl"),i=e("../utils/ViewAction"),o=e("../Agency/AgencySkin"),r=e("../utils/GameState"),s=e("../Data/UserInfoEvent"),l=e("../Control/ResourceControl"),c=e("../Config/AssetPath"),h=e("../PrefabControl/CharacterState"),u=e("../View/ViewManager"),p=e("../PrefabControl/CharacterPool"),d=e("../Game/Player"),m=function(e){function SkinPanel(){var t=e.call(this,"main","skinview",!1,i.ViewAction.ActionType_none,0)||this;return t._isdestorys=!1,t._out=new Laya.Quaternion,t}return __extends(SkinPanel,e),SkinPanel.prototype.initView=function(){this._isdestorys=!1,this.c_title=this.getControllerByBame("c_title"),this.agencyskin=this.getProxy(o.AgencySkin),this.list_0.setVirtual(),this.list_0.itemRenderer=Laya.Handler.create(this,this.itemlistrender,null,!1),this.c_title.selectedIndex=0,this.onchange(),this._ui3DScene=this.displayObject.addChildAt(new Laya.Scene3D,0),this._uicarma3D=this._ui3DScene.addChild(new Laya.Camera(0,.1,80)),this._uicarma3D.viewport=new Laya.Viewport(this.x,this.y,this.width,this.height),this._uicarma3D.transform.translate(new Laya.Vector3(0,1.2,5),!1),this.updateroleHandler()},SkinPanel.prototype.initEvent=function(){this.AddEventByType(this.btn_close,Laya.Event.CLICK,this,this.onclosefun),this.AddEventByType(this.c_title,fairygui.Events.STATE_CHANGED,this,this.onchange),this.addDataEvent(r.GameState.updateSKinView,this,this.onchange),this.addDataEvent(s.UserInfoEvent.userinfoEvent_updateroleid,this,this.updateroleHandler)},SkinPanel.prototype.ClearCharacter=function(){if(this._rolemo){var e=this._rolemo.getComponent(d.Player);p.CharacterPool.ClearCharacter(this._rolemo,e.resouseName,e),this._rolemo=null}},SkinPanel.prototype.onclosefun=function(){u.ViewManager.Instance.close(SkinPanel)},SkinPanel.prototype.destory=function(){this._isdestorys=!0,this.ClearCharacter(),this._uicarma3D&&(this._uicarma3D.destroy(),this._uicarma3D=null),this._ui3DScene&&(this._ui3DScene.destroy(),this._ui3DScene=null),e.prototype.destory.call(this)},SkinPanel.prototype.onchange=function(){0==this.c_title.selectedIndex?this.list_0.numItems=this.agencyskin.pifuArr.length:this.list_0.numItems=0},SkinPanel.prototype.itemlistrender=function(e,t){0==this.c_title.selectedIndex&&e<this.agencyskin.pifuArr.length&&t.showData(this.agencyskin.pifuArr[e])},SkinPanel.prototype.updateroleHandler=function(){var e=this.agencyskin.RoleData;this.ClearCharacter();var t=[];t.push({url:c.AssetPath.get3DRoleModel(e.roleCfg.name)}),l.ResourceControl.Instance.loader3DArr(t,this,this.loadcomplete,null,!0,e.roleCfg.name)},SkinPanel.prototype.loadcomplete=function(e){var t=this.agencyskin.RoleData;!this._isdestorys&&this._ui3DScene&&e==t.roleCfg.name&&(this._rolemo=p.CharacterPool.AddCharacter(e,d.Player,this._ui3DScene),this._rolemo.transform.position=new Laya.Vector3(0,2,0),Laya.Quaternion.createFromAxisAngle(new Laya.Vector3(0,1,0),-24300/Math.PI,this._out),this._rolemo.transform.rotation=this._out,this._rolemo.getComponent(d.Player).PlayAnimator(h.CharacterState.stand))},SkinPanel.key="SkinPanel",SkinPanel}(n.PanelBaseControl);a.SkinPanel=m},{"../Agency/AgencySkin":6,"../Config/AssetPath":15,"../Control/PanelBaseControl":24,"../Control/ResourceControl":28,"../Data/UserInfoEvent":36,"../Game/Player":40,"../PrefabControl/CharacterPool":45,"../PrefabControl/CharacterState":46,"../View/ViewManager":70,"../utils/GameState":86,"../utils/ViewAction":93}],69:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Control/PanelBaseControl"),i=e("../utils/ViewAction"),o=e("../utils/GameUtils"),r=e("../Config/AssetPath"),s=e("../Agency/AgencyTrial"),l=e("../WXSDK/GuangGao"),c=e("../WXSDK/ttad"),h=function(e){function TrialPanel(t){var a=e.call(this,"main","shiyongView",!1,i.ViewAction.ActionType_none,1)||this;return a.skinarr=t,a}return __extends(TrialPanel,e),TrialPanel.prototype.onInit=function(){e.prototype.onInit.call(this)},TrialPanel.prototype.initView=function(){this.agencytrial=this.getProxy(s.AgencyTrial);var e=o.GameUtils.randRangeint(0,this.skinarr.length-1);this._selectvo=this.skinarr[e],this.load_icon.url=r.AssetPath.getroleicon(this._selectvo.roleCFG.icon),l.GuangGao.CheatBanner(this.btn_close)},TrialPanel.prototype.initEvent=function(){this.AddEventByType(this.btn_close,Laya.Event.CLICK,this,this.onclosefun),this.AddEventByType(this.btn_video,Laya.Event.CLICK,this,this.videofun)},TrialPanel.prototype.videofun=function(){this.videocallback()},TrialPanel.prototype.videocallback=function(){var e=this;c.ttad.ShowVideo(function(t){t&&e.agencytrial.ExitPanel(e._selectvo)})},TrialPanel.prototype.onclosefun=function(){this.agencytrial.ExitPanel(null)},TrialPanel.prototype.destory=function(){c.ttad.Clear(),e.prototype.destory.call(this)},TrialPanel.key="TrialPanel",TrialPanel}(n.PanelBaseControl);a.TrialPanel=h},{"../Agency/AgencyTrial":7,"../Config/AssetPath":15,"../Control/PanelBaseControl":24,"../WXSDK/GuangGao":72,"../WXSDK/ttad":83,"../utils/GameUtils":87,"../utils/ViewAction":93}],70:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../utils/LayOUT"),i=e("../Control/LayoutControl"),o=function(e){function ViewManager(){var t=e.call(this)||this;return ViewManager.ins=t,t}return __extends(ViewManager,e),Object.defineProperty(ViewManager,"Instance",{get:function(){return null==ViewManager.ins?new ViewManager:ViewManager.ins},enumerable:!0,configurable:!0}),ViewManager.prototype.init=function(){this._views={},this.initEvent()},ViewManager.prototype.initEvent=function(){},ViewManager.prototype.add=function(e,t,a){if(void 0===t&&(t=null),void 0===a&&(a=n.LayOUT.UI),null==e.key)throw new Error("view have no key");var o,r=e.key;return this._views[r]?this._views[r]:((o=null!=t?new e(t):new e).viewKey=e,o.gameLayer=a,i.LayoutControl.Instance.AddLayerByName(o,a),this._views[r]=o,o)},ViewManager.prototype.close=function(e,t,a){void 0===t&&(t=!1),void 0===a&&(a=!0);var n=e.key,o=this._views[n];o&&(i.LayoutControl.Instance.ClearLayerByName(o.gameLayer),a?o.ExitView():o.destory(),delete this._views[n])},ViewManager.prototype.onresize=function(e,t){if(null!=this._views)for(var a in this._views)this._views[a].setSize(e,t)},ViewManager.prototype.getView=function(e){var t=e.key;return this._views[t]},ViewManager}(Laya.EventDispatcher);a.ViewManager=o},{"../Control/LayoutControl":22,"../utils/LayOUT":90}],71:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Push/RecommendView"),i=e("../View/ViewManager"),o=e("../Push/ChoutiPanView"),r=function(){function FYHD_Sdk(){}return FYHD_Sdk.InitSdk=function(){Laya.Browser.window.sdk.getFyhd().startSdk(),FYHD_Sdk.UserInfoAuth()},FYHD_Sdk.UserInfoAuth=function(){Laya.Browser.onWeiXin&&Laya.Browser.window.sdk.getFyhd().getFyhdUserInfo(null,!1,function(e){console.log("无授权回调:"+JSON.stringify(e)),e.result.user&&(FYHD_Sdk.openid=e.result.user.openid,FYHD_Sdk.AuthInfo())})},FYHD_Sdk.AuthInfo=function(){var e={openid:FYHD_Sdk.openid};Laya.Browser.window.sdk.getFyhd().loginData(e,function(e){console.log("授权上报回调:"+JSON.stringify(e)),FYHD_Sdk.ValueUser()})},FYHD_Sdk.ValueUser=function(){var e={openid:FYHD_Sdk.openid};Laya.Browser.window.sdk.getFyhd().valueuser(e,function(e){console.log("有效用户上报:"+JSON.stringify(e))})},FYHD_Sdk.getWhiteConfig=function(){Laya.Browser.window.sdk.getFyhd().whiteConfig(function(e){FYHD_Sdk.iswhite=e.data.is_white,FYHD_Sdk.iswhite&&Laya.LocalStorage.setItem("is_white","1"),console.log("白名单---",e)})},FYHD_Sdk.SetHuTuiList=function(e,t,a){void 0===t&&(t=1),void 0===a&&(a="");var n=this.pushData;n&&0!=n.length&&(e.selectEnable=!1,1==t?e.vScrollBarSkin="":e.hScrollBarSkin="",e.renderHandler=Laya.Handler.create(this,this.updateItem,[a],!1),e.array=n,e.refresh())},FYHD_Sdk.updateItem=function(e,t,a){},FYHD_Sdk.ClickAd=function(e){if(console.log("上报类型---",e),Laya.Browser.onWeiXin){var t={ad_type:e,openid:FYHD_Sdk.openid};console.log("点击参数:"+t),Laya.Browser.window.sdk.getFyhd().advertisement(t,function(e){console.log("点击结果:"+JSON.stringify(e))})}},FYHD_Sdk.PushData=function(){if(Laya.Browser.onWeiXin){Laya.Browser.window.sdk.getFyhd().shareRecommend({},function(e){console.log("热门游戏数据--",e),e.data&&(FYHD_Sdk.pushData=e.data,FYHD_Sdk.pushData.sort(FYHD_Sdk.ListSort),FYHD_Sdk.isHaveDate=!0),console.log("获取互推信息:"+JSON.stringify(FYHD_Sdk.pushData)),new n.Recommend})}},FYHD_Sdk.ShowHuTuiJump=function(e,t){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:function(t){console.log("上报成功:"+JSON.stringify(t)),FYHD_Sdk.PushClick(e.to_appid)},fail:function(e){t&&i.ViewManager.Instance.add(o.default)}}):0==e.jump_type&&Laya.Browser.window.wx.navigateToMiniProgram({appId:e.platform_appid,path:e.jump_path,success:function(t){console.log("上报成功:"+JSON.stringify(t)),FYHD_Sdk.PushClick(e.to_appid)},fail:function(e){t&&i.ViewManager.Instance.add(o.default)}}))},FYHD_Sdk.PushClick=function(e){if(Laya.Browser.onWeiXin){var t={openid:FYHD_Sdk.openid,to_appid:e};Laya.Browser.window.sdk.getFyhd().sharePlay(t,function(e){console.log("点击上报结果:"+JSON.stringify(e))})}},FYHD_Sdk.ListSort=function(e,t){return Number(e.panel)<Number(t.panel)?-1:Number(e.panel)==Number(t.panel)?0:Number(e.panel)>Number(t.panel)?1:void 0},FYHD_Sdk.Ad_ClickType={Video:"video_click",Watch:"watch",Share:"share",Banner:"banner",Push:"push",PushClick:"icon_click"},FYHD_Sdk.pushData=[],FYHD_Sdk.isHaveDate=!1,FYHD_Sdk.ShowAd="ShowAd",FYHD_Sdk}();a.FYHD_Sdk=r},{"../Push/ChoutiPanView":51,"../Push/RecommendView":55,"../View/ViewManager":70}],72:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./PlayerAccount"),i=e("./ttad"),o=function(){return function(){this.appNameHidden=!1,this.color="C93B3BFF",this.size=100,this.borderWidth=50,this.borderColor="A1A0A0FF"}}();a.WxGameItem=o;var r=function(){function GuangGao(){this.isVideoLoadCom=!1}return Object.defineProperty(GuangGao,"hasbanner",{get:function(){return!!n.PlayerAccount.CurrentAccount.CurAccountData.banner},enumerable:!0,configurable:!0}),Object.defineProperty(GuangGao,"hasvideo",{get:function(){if(Laya.Browser.onWeiXin&&n.PlayerAccount.CurrentAccount.CurAccountData.video){n.PlayerAccount.CurrentAccount.CurAccountData.GetGlobe;return!0}return!1},enumerable:!0,configurable:!0}),GuangGao.InitVideo=function(){var e=this;Laya.Browser.onWeiXin&&n.PlayerAccount.CurrentAccount.CurAccountData.video&&(console.log(this.bannerAdUnitId),this.fsaasfafssfa=Laya.Browser.window.wx.createRewardedVideoAd({adUnitId:this.videlAdUnitId}),this.fsaasfafssfa.onLoad(function(){console.log("激励视频 广告加载成功"),e.asfasfsaffsa=!0}),this.fsaasfafssfa.onError(function(t){console.log("激励视屏加载失败:"+t),e.asfasfsaffsa=!1}),this.afsfsaafsfsa=!0)},GuangGao.ShowVideo=function(e){var t=this;this.hasvideo?this.asfasfsaffsa&&(console.log("showVideoAd:"+this.asfasfsaffsa),this.SetVideoCallBack(e),this.fsaasfafssfa.show().catch(function(a){t.fsaasfafssfa.load().then(function(){t.SetVideoCallBack(e),t.fsaasfafssfa.show()})})):e(!1)},GuangGao.SetVideoCallBack=function(e){var t=this;this.fsaasfafssfa.offClose(),this.fsaasfafssfa.onClose(function(a){console.log("激励视频关闭:"+a.isEnded),a&&a.isEnded||void 0===a?e&&e(!0):e&&e(!1),t.fsaasfafssfa.offClose()})},GuangGao.OpenBanner=function(e,t,a){var n=this;if(void 0===e&&(e=0),void 0===t&&(t=null),void 0===a&&(a=!1),Laya.Browser.onWeiXin){this.canshowbanner=!0;var i=this.bannerAdUnitId;console.log("adUnitId:"+i);var o=Laya.Browser.window.wx.createBannerAd({adUnitId:i,style:{left:0,top:0,width:460}});o.onError(function(e){console.log(e),t(null)}),o.onLoad(function(){n.curbanner&&n.curbanner.destroy(),n.curbanner=o;var i=n.GetRealHight(e);null!=t&&t(i),n.canshowbanner&&!a?n.curbanner.show():n.curbanner.hide()})}else t(null)},GuangGao.GetRealHight=function(e){if(this.curbanner){var 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}},GuangGao.Clear=function(){GuangGao.clearTween(),Laya.timer.clearAll(this),Laya.Tween.clearAll(this),this.canshowbanner=!1,this.curbanner&&this.curbanner.hide()},GuangGao.hidebanner=function(){Laya.Browser.onWeiXin&&this.curbanner&&this.curbanner.hide()},GuangGao.showbanner=function(){Laya.Browser.onWeiXin&&this.curbanner&&this.curbanner.show()},Object.defineProperty(GuangGao,"cancheat",{get:function(){return!!n.PlayerAccount.CurrentAccount.CurAccountData.cheat},enumerable:!0,configurable:!0}),GuangGao.SetPosBanner=function(e,t){var a=this;if(Laya.Browser.onPC)t(!1);else{var n=Laya.Browser.window.wx.getSystemInfoSync(),i=e.y*n.windowHeight/Laya.stage.height,o=this.bannerAdUnitId;console.log("adUnitId:"+o),this.curbanner&&this.curbanner.destroy();var r=Laya.Browser.window.wx.createBannerAd({adUnitId:o,style:{left:0,top:0,width:720}});r.onError(function(e){console.log(e),t(!1)}),r.onLoad(function(){a.curbanner=r,a.curbanner.style.top=i,a.curbanner&&(console.log("banner show"),a.curbanner.show(),Laya.timer.once(2300,a,function(){a.curbanner.style.top=n.windowHeight-GuangGao.bannerhigt,t(!0)}))}),r.onResize(function(e){GuangGao.bannerhigt=e.height,a.curbanner.style.width=n.windowWidth,a.curbanner.style.top=i})}},GuangGao.CheatBanner=function(e,t,a){void 0===t&&(t=null),void 0===a&&(a=0),i.ttad.Showbanner()},GuangGao.clearTween=function(){GuangGao.tween&&(GuangGao.tween.clear(),GuangGao.tween=null)},GuangGao.prototype.loadVideo=function(e){var t=this;if(Laya.Browser.onWeiXin)if(this._onLoadVideo=e,this._rewardedVideoAd)this.isVideoLoadCom?(this._onLoadVideo&&this._onLoadVideo(!0),this._onLoadVideo=null):(this._onLoadVideo&&this._onLoadVideo(!1),this._onLoadVideo=null);else{var a=GuangGao.videlAdUnitId;this._rewardedVideoAd=Laya.Browser.window.wx.createRewardedVideoAd({adUnitId:a});var n=!1;this._rewardedVideoAd.onLoad(function(){console.log("[LOG] 激励视频广告加载成功"),t.isVideoLoadCom=!0,n||(n=!0,t._onLoadVideo&&t._onLoadVideo(!0),t._onLoadVideo=null)}),this._rewardedVideoAd.onError(function(e){console.log("[LOG] 激励视频广告加载失败"),console.log(e),t.isVideoLoadCom=!1,t._onLoadVideo&&t._onLoadVideo(!1),t._onLoadVideo=null}),this._rewardedVideoAd.onClose(function(e){!e||e.isEnded?(t._onVideoClose&&t._onVideoClose(!0),t._onVideoClose=null):(t._onVideoClose&&t._onVideoClose(!1),t._onVideoClose=null)})}else e&&e(!0)},GuangGao.prototype.showVideo=function(e){var t=this;Laya.Browser.onWeiXin?(this._onVideoClose=e,this._rewardedVideoAd.show().catch(function(e){t._rewardedVideoAd.load().then(function(){t._rewardedVideoAd.show()})})):e&&e(!0)},GuangGao.videlAdUnitId="adunit-0c687084c908ee89",GuangGao.bannerAdUnitId="adunit-8c2d586135fa6d4f",GuangGao.afsfsaafsfsa=!1,GuangGao.asfasfsaffsa=!1,GuangGao.canshowbanner=!0,GuangGao.bannerhigt=0,GuangGao}();a.GuangGao=r},{"./PlayerAccount":75,"./ttad":83}],73:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=Laya.Event,i=Laya.HttpRequest,o=e("./PlayerAccount"),r=e("./Sdk"),s=e("../Time/TimesTamper"),l=e("../Global"),c="https://parkourracetoutiao2api.xwxgame.com/",h=function(){function PROTOCOLS(){}return PROTOCOLS.Login="user/login",PROTOCOLS.game="game/start",PROTOCOLS.end="game/play",PROTOCOLS.Sign="sign/sign",PROTOCOLS.Buy="theme/buy",PROTOCOLS.Equip="theme/equip",PROTOCOLS.share="fission/share",PROTOCOLS.vd="fission/vd",PROTOCOLS.revival="game/revival",PROTOCOLS.fission="theme/fission",PROTOCOLS.themefission="theme/fission",PROTOCOLS.treasure="treasure/click",PROTOCOLS.Config="config/table",PROTOCOLS.Lottery="lottery/lottery",PROTOCOLS.GetAchieve="achievement/getRewards",PROTOCOLS.usersync="user/sync",PROTOCOLS}();a.PROTOCOLS=h;var u=function(){function NetworkManager(){NetworkManager.instance=this}return Object.defineProperty(NetworkManager,"Instance",{get:function(){return NetworkManager.instance?NetworkManager.instance:new NetworkManager},enumerable:!0,configurable:!0}),NetworkManager.prototype.login=function(e,t,a){var r=o.PlayerAccount.CurrentAccount,s=l.Global.gameVersion,u="code="+r.Code+"&nickname="+r.NickName+"&avatar="+r.Avatar+"&gender="+r.Gender+"&country="+r.Country+"&province="+r.Province+"&city="+r.City+"& device="+r.Device+"$&share_id="+r.ShareId+"&scene="+r.Scene+"&v="+s,p=new i;p.once(n.PROGRESS,this,this.onHttpRequestProgress,[e,p]),p.once(n.COMPLETE,this,this.onLoginRequestComplete,[t,p]),p.once(n.ERROR,this,this.onHttpRequestError,[a,p]),p.send(c+h.Login,u,"post","text")},NetworkManager.prototype.onHttpRequestProgress=function(e,t){e&&(console.log("HttpRequestProgress:..."),e.run())},NetworkManager.prototype.onLoginRequestComplete=function(e,t){var a=JSON.parse(t.data);if("0"!=a.code)return console.log("登录异常错误!错误信息:",t.data),void r.WxApi.recordAldEvent("登录异常错误!错误信息:= "+a.code,"httpRequest.dat");o.PlayerAccount.ServerTime=a.t,s.TimesTamper.Instance.updateServiceTime(Number(a.t)),r.WxApi.recordAldEvent("登录正式成功"),o.PlayerAccount.CurrentAccount.SetAccountData(a,e)},NetworkManager.prototype.onHttpRequestError=function(e,t){null!=e&&e.runWith(t),r.WxApi.recordAldEvent("Error! Http request error.. ","httpRequest.dat"),r.WxApi.ShowLoading("连接网络失败..."),Laya.timer.once(8e3,this,function(){r.WxApi.HideLoading()}),console.log("Error! Http request error..."+t.data)},NetworkManager.prototype.HttpPostRequest=function(e,t,a,s,l){void 0===l&&(l=!0);var u="",p=c+e,d=o.PlayerAccount.CurrentAccount.CurAccountData;if(1==l&&(u="token="+d.m_token+"&"),r.WxApi.ShowLoading("连接网络中..."),e==h.game||e==h.end||e==h.fission||e==h.vd||e==h.themefission||e==h.Lottery||e==h.usersync){for(var m="abcdefghijkimnopqrstuvwxyz0123456789",f="{",g="",y=0;y<4;y++)g+=m[Math.floor(100*Math.random())%m.length];for(y=0;y<t.length;y++){for(var C in t[y])f+='"'+C+'":"'+t[y][C]+'"';y<t.length-1?f+=",":f+="}"}u+="_r="+g+this.base64Encode(f)}else if(null!=t)for(y=0;y<t.length;y++)for(var C in t[y]){u+=C+"="+t[y][C],y<t.length-1&&(u+="&")}var _=new i;_.once(n.COMPLETE,this,this.onHttpRequestComplete,[a,s,_]),_.once(n.ERROR,this,this.onHttpRequestError,[s,_]),_.send(p,u,"post","text")},NetworkManager.prototype.onHttpRequestComplete=function(e,t,a){r.WxApi.HideLoading();var n=JSON.parse(a.data);0==n.code?(o.PlayerAccount.CurrentAccount.SetAccountData(n,null),null!=e&&e.runWith(n)):(null!=t&&t.runWith(n),console.log("Error! Http request complete error, code: "+n.code+" message: "+n.message))},NetworkManager.prototype.base64Encode=function(e){for(var t,a,n,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",o=0,r=e.length,s="";o<r;){if(t=255&e.charCodeAt(o++),o==r){s+=i.charAt(t>>2),s+=i.charAt((3&t)<<4),s+="==";break}if(a=e.charCodeAt(o++),o==r){s+=i.charAt(t>>2),s+=i.charAt((3&t)<<4|(240&a)>>4),s+=i.charAt((15&a)<<2),s+="=";break}n=e.charCodeAt(o++),s+=i.charAt(t>>2),s+=i.charAt((3&t)<<4|(240&a)>>4),s+=i.charAt((15&a)<<2|(192&n)>>6),s+=i.charAt(63&n)}return s},NetworkManager}();a.NetworkManager=u},{"../Global":41,"../Time/TimesTamper":60,"./PlayerAccount":75,"./Sdk":77}],74:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function PlatfromType(){}return PlatfromType.pc="pc",PlatfromType.wx="wx",PlatfromType.qq="qq",PlatfromType.tt="tt",PlatfromType}();a.PlatfromType=n},{}],75:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n,i,o,r,s=e("../WXSDK/Sdk"),l=e("../utils/GameUtils"),c=e("./NetworkManager"),h=e("../utils/DispatcherManager"),u=e("../Data/UserInfoEvent");!function(e){e[e["系统赠送"]=1]="系统赠送",e[e["金币购买"]=2]="金币购买",e[e["观看视频"]=3]="观看视频",e[e["分享"]=4]="分享",e[e["签到"]=5]="签到",e[e["活动"]=6]="活动",e[e["通过关卡"]=7]="通过关卡",e[e["累计登陆"]=8]="累计登陆",e[e["邀请人数达到"]=9]="邀请人数达到",e[e["砖石购买"]=10]="砖石购买"}(a.requiretype||(a.requiretype={})),function(e){e[e.crop=0]="crop",e[e.things=1]="things",e[e.land=2]="land",e[e.global=3]="global",e[e.entity=4]="entity",e[e.sign=5]="sign",e[e.rewards=6]="rewards",e[e.achievement=7]="achievement",e[e.invite=8]="invite",e[e.mission=9]="mission",e[e.treasure_click=10]="treasure_click",e[e.theme=11]="theme",e[e.lottery=12]="lottery"}(n=a.AccountConfig||(a.AccountConfig={})),function(e){e[e.money=0]="money",e[e.diamond=1]="diamond",e[e.user_id=2]="user_id",e[e.game_times=3]="game_times",e[e.get_themes=4]="get_themes",e[e.video_times=5]="video_times",e[e.equip_themes=6]="equip_themes",e[e.last_action_time=7]="last_action_time",e[e.last_favorite_time=8]="last_favorite_time",e[e.progress_themes=9]="progress_themes",e[e.revival=10]="revival",e[e.stage=11]="stage",e[e.vmoney=12]="vmoney"}(i=a.AccountUser||(a.AccountUser={})),function(e){e[e.id=0]="id",e[e.name=1]="name",e[e.quality=2]="quality",e[e.icon=3]="icon",e[e.prefab=4]="prefab",e[e.require_num=5]="require_num",e[e.require_type=6]="require_type"}(a.heroAttr||(a.heroAttr={})),function(e){e[e.sign_days=0]="sign_days",e[e.sign_time=1]="sign_time"}(o=a.signdata||(a.signdata={})),function(e){e[e.id=0]="id",e[e.name=1]="name",e[e.entity_id=2]="entity_id",e[e.icon=3]="icon"}(r=a.entity||(a.entity={})),function(e){e[e.effectValue_1=0]="effectValue_1",e[e.effectValue_2=1]="effectValue_2",e[e.effectValue_3=2]="effectValue_3",e[e.effectValue_4=3]="effectValue_4"}(a.skinattr||(a.skinattr={}));var p=function(){function AccountData(e,t,a,n,i,o,r,s,l,c,h,u){void 0===o&&(o=null),void 0===r&&(r=null),this.openid="",this.userId="",this.roadconfig={},this.m_RewardDic={},this.m_EntityDic={},this.m_AchievementDic={},this.m_token=e,this.m_app_setting=a,this.m_user=n,this.m_user_base=i,this.m_sign=s,this.m_task=l,this.lottery=c,this.m_use_land_task=h,this.m_user_video=u,this.userId=this.m_user.user_id,this.openid=this.m_user_base.openid,console.log("user_id:"+this.userId)}return Object.defineProperty(AccountData.prototype,"DieDistance",{get:function(){return Number(this.m_app_setting.DieDistance)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"HitEgg",{get:function(){return Number(this.m_app_setting.HitEgg)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"EndCheat",{get:function(){return Number(this.m_app_setting.EndCheat)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"CheatReward",{get:function(){return Number(this.m_app_setting.CheatReward)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"WhiteUser",{get:function(){return"1"==this.m_app_setting.WhiteUser},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"StrategySwitch",{get:function(){return"1"==this.m_app_setting.StrategySwitch},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"ShowSign",{get:function(){return"1"==this.m_app_setting.ShowSign},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"Choose",{get:function(){return"1"==this.m_app_setting.choose},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"ShowBattleBtn",{get:function(){return"1"==this.m_app_setting.ShowBattleBtn},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"lotterytime",{get:function(){return Number(this.lottery.day_video_times)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"share",{get:function(){return"1"==this.m_app_setting.share},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"sharecontent",{get:function(){return this.m_app_setting.sharecontent},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"ShareImage",{get:function(){return this.m_app_setting.ShareImage},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"cheattime",{get:function(){return Number(this.m_app_setting.cheattime)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"banner",{get:function(){return"1"==this.m_app_setting.banner},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"video",{get:function(){return"1"==this.m_app_setting.video},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"BtnCanMove",{get:function(){return"1"==this.m_app_setting.BtnCanMove},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"checkscence",{get:function(){return"1"==this.m_app_setting.checkscence},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"banner_dis",{get:function(){return Number(this.m_app_setting.banner_dis)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"bannerMoveTime",{get:function(){return Number(this.m_app_setting.bannerMoveTime)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"createBannerTimes",{get:function(){return Number(this.m_app_setting.createBannerTimes)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"bannerMoveProp",{get:function(){return Number(this.m_app_setting.bannerMoveProp)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"isShareThenVideo",{get:function(){return"1"==this.m_app_setting.isShareThenVideo},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"isShowHuiTui",{get:function(){return"1"==this.m_app_setting.isShowHuiTui},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"start_sprint",{get:function(){return Number(this.m_app_setting.start_sprint)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"IsVideoModel",{get:function(){return"1"==this.m_app_setting.IsVideoModel},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"videoModelNum",{get:function(){return Number(this.m_app_setting.videoModelNum)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"VideoModelTitle",{get:function(){return this.m_app_setting.VideoModelTitle},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"failcount",{get:function(){return Number(this.m_app_setting.failcount)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"spminspeed",{get:function(){return Number(this.m_app_setting.spminspeed)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"bgm",{get:function(){return"1"==this.m_app_setting.bgm},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"camerahight",{get:function(){return Number(this.m_app_setting.camerahight)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"ctnfilename",{get:function(){return this.m_app_setting.ctnfilename},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"cheat",{get:function(){return"1"==this.m_app_setting.cheat},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"shakestage",{get:function(){return this.m_app_setting.shakestage&&"1"==this.m_app_setting.shakestage},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"stageconfigcdn",{get:function(){return"1"==this.m_app_setting.stageconfigcdn},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"playerspeed",{get:function(){return Number(this.m_app_setting.playerspeed)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"videlAdUnitId",{get:function(){return this.m_app_setting.videlAdUnitId},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"bannerAdUnitId",{get:function(){return this.m_app_setting.bannerAdUnitId},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"tri",{get:function(){return"1"==this.m_app_setting.tri},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"recommend",{get:function(){return"1"==this.m_app_setting.recommend},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"recommendflg",{get:function(){return this.m_app_setting.recommendflg},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"egg",{get:function(){return"1"==this.m_app_setting.egg},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"eggrate",{get:function(){return Number(this.m_app_setting.eggrate)},enumerable:!0,configurable:!0}),Object.defineProperty(AccountData.prototype,"UseId",{get:function(){return this.userId},enumerable:!0,configurable:!0}),AccountData.prototype.GetConfig=function(e){var t=n[e];return this.m_configs[t]},AccountData.prototype.GetUser=function(e){var t=i[e];return this.m_user[t]},Object.defineProperty(AccountData.prototype,"GetVideoTotal",{get:function(){return Number(this.m_user_video.total)},enumerable:!0,configurable:!0}),AccountData.prototype.GetSign=function(e){var t=o[e];return this.m_sign[t]},AccountData.prototype.GetRewardConfig=function(e){return this.m_RewardDic[e]},AccountData.prototype.GetEntity=function(e,t){return this.m_EntityDic[e]?this.m_EntityDic[e][r[t]]:null},AccountData.prototype.GetRewardDic=function(){var e=this.GetConfig(n.rewards);for(var t in e)this.m_RewardDic[e[t].id]=e[t]},AccountData.prototype.GetEntityDic=function(){var e=this.GetConfig(n.entity);for(var t in e)this.m_EntityDic[e[t].entity_id]=e[t]},AccountData.prototype.GetThemeById=function(e){var t=this.GetConfig(n.theme);if(t)for(var a=0;a<t.length;a++){var i=t[a];if(i.id==e)return i}},AccountData.prototype.GetSkinAttr=function(e){for(var t=this.GetConfig(n.theme),a=0;a<t.length;a++)if(t[a].id==e)return t[a]},AccountData.prototype.GetAchievementData=function(){var e=this.GetConfig(n.achievement),t={};for(var a in e){var i=e[a].type;if(!t[i]){var o=[];for(var r in e){i==e[r].type&&o.push(e[r])}t[i]=o}}this.m_AchievementDic=t},AccountData.prototype.HasTheme=function(e){for(var t=!1,a=this.GetUser(i.get_themes),n=0;n<a.length;n++)a[n]==e&&(t=!0);return t},AccountData.prototype.GetSkinDic=function(e){},AccountData.prototype.GetHeroProgress=function(e){var t=this.m_user.progress_heroes;return t[e]?t[e]:0},AccountData.prototype.GetHatProgress=function(e){var t=this.m_user.progress_hats;return t[e]?t[e]:0},AccountData.prototype.GetCbProgress=function(e){var t=this.m_user.progress_dances;return t[e]?t[e]:0},AccountData.prototype.HasMotor=function(e){for(var t=this.GetUser(i.get_themes),a=0;a<t.length;a++){if(e==t[a])return!0}return!1},AccountData.prototype.GetMotorProgress=function(e){var t=this.m_user.progress_themes;return t[e]?t[e]:0},AccountData.prototype.GetSeverConfig=function(e){this.m_configs=e,this.GetSkinDic(this.m_configs),this.GetRewardDic(),this.GetEntityDic();for(var t=e.global,a=0;a<t.length;a++){var n=t[a];if("tilirec"==n.key)return void(d.CurrentAccount.tilirec=Number(n.value))}},AccountData.prototype.UpdateSkinDic=function(){this.GetSkinDic(this.m_configs)},AccountData.prototype.GetGlobe=function(e){var t=this.GetConfig(n.global);for(var a in t){var i=t[a];if(i.key==e)return i.value}return null},AccountData}();a.AccountData=p;var d=function(){function PlayerAccount(e,t,a,n,i,o,r,s,l,c,h){this.IsTest=!1,this.localTime=Laya.timer.currTimer,this.Code=e,this.NickName=t,this.Avatar=a,this.Gender=n,this.Country=i,this.Province=o,this.City=r,this.Device=s,this.ShareId=l,this.Scene=c,this.ver=h,this.IsTest=!1,PlayerAccount.instance=this}return Object.defineProperty(PlayerAccount,"CurrentAccount",{get:function(){return null==PlayerAccount.instance?(console.log("生成本地测试账号..."),PlayerAccount.TestAccount):PlayerAccount.instance},enumerable:!0,configurable:!0}),Object.defineProperty(PlayerAccount,"TestAccount",{get:function(){var e=Laya.LocalStorage.getItem("localcode");if(e)console.log("老用户",e);else{var t=(new Date).getTime().toString(),a=l.GameUtils.randRangeint(1e4,99999).toString();e="xj_"+t+a,Laya.LocalStorage.setItem("localcode",e),console.log(t,a),console.log("新用户",e)}var n=new PlayerAccount(e,null,null,null,null,null,null,null,null,null,null);return n.IsTest=!0,n},enumerable:!0,configurable:!0}),PlayerAccount.prototype.SetAccountData=function(e,t){var a=this,n=e.token,i=e.configs,o=e.app_setting,r=e.user,l=e.user_base,c=e.user_sign,d=e.user_achievement,m=e.user_lottery,f=e.user_land_task,g=e.user_video;null==this.CurAccountData?(s.WxApi.recordAldEvent("开始获取config数据"),this.CurAccountData=new p(n,i,o,r,l,null,null,c,d,m,f,g),this.CheckLocalConfig(e.table_version,function(n){a.CurAccountData.GetSeverConfig(n),a.nowConfig=n,null!=t&&t.runWith(e)})):(i&&(this.CurAccountData.m_configs=i),o&&(this.CurAccountData.m_app_setting=o),r&&(this.CurAccountData.m_user=r),l&&(this.CurAccountData.m_user_base=l),c&&(this.CurAccountData.m_sign=c),d&&(this.CurAccountData.m_task=d),m&&(this.CurAccountData.lottery=m),f&&(this.CurAccountData.m_use_land_task=f),g&&(this.CurAccountData.m_user_video=g)),h.DispatcherManager.dispatchEvent(u.UserInfoEvent.updatePlayerInfo)},PlayerAccount.prototype.CheckLocalConfig=function(e,t){var a=Laya.LocalStorage.getJSON(PlayerAccount.localcofigkey);a?a.ver==e?(console.log("sever配置是最新的...",e),s.WxApi.recordAldEvent("config接口获取成功"),t(a)):c.NetworkManager.Instance.HttpPostRequest(c.PROTOCOLS.Config,null,Laya.Handler.create(this,function(a){a.configs.ver=e,Laya.LocalStorage.setJSON(PlayerAccount.localcofigkey,a.configs),console.log("sever配置更新完成...",e),s.WxApi.recordAldEvent("config接口获取成功"),t(a.configs)}),Laya.Handler.create(this,function(e){console.log("配置获取失败"+e),s.WxApi.recordAldEvent("config接口获取失败")})):c.NetworkManager.Instance.HttpPostRequest(c.PROTOCOLS.Config,null,Laya.Handler.create(this,function(a){a.configs.ver=e,Laya.LocalStorage.setJSON(PlayerAccount.localcofigkey,a.configs),console.log("sever保存配置完成...",e),s.WxApi.recordAldEvent("config接口获取成功"),t(a.configs)}),Laya.Handler.create(this,function(e){console.log("配置获取失败"+e),s.WxApi.recordAldEvent("config接口获取失败")}))},Object.defineProperty(PlayerAccount.prototype,"ServerTime",{get:function(){var e=Laya.timer.currTimer;return PlayerAccount.ServerTime+Math.ceil((e-this.localTime)/1e3)},enumerable:!0,configurable:!0}),PlayerAccount.localcofigkey="mconfig",PlayerAccount}();a.PlayerAccount=d},{"../Data/UserInfoEvent":36,"../WXSDK/Sdk":77,"../utils/DispatcherManager":85,"../utils/GameUtils":87,"./NetworkManager":73}],76:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function RecordManager(){RecordManager.instance=this,console.log("new record")}return Object.defineProperty(RecordManager,"Instance",{get:function(){if(RecordManager.instance)return RecordManager.instance;var e=new RecordManager;return e.OnNew(),e},enumerable:!0,configurable:!0}),RecordManager.prototype.RecordStart=function(){Laya.Browser.onMobile&&(console.log("RecordStart"),this.record.start({duration:60}))},RecordManager.prototype.RecordStop=function(){Laya.Browser.onMobile&&(console.log("RecordStop"),this.record.stop())},RecordManager.prototype.ShareVideo=function(e){Laya.Browser.onMobile&&Laya.Browser.window.tt.shareAppMessage({channel:"video",query:"",templateId:"266q4fgb8al7i3e7ie",title:"赢得了我,认你做大哥又如何",desc:"赢得了我,认你做大哥又如何",extra:{videoPath:this.completepath,videoTopics:["赢得了我,认你做大哥又如何"]},success:function(){e&&e(!0),console.log("分享视频成功")},fail:function(t){e&&e(!1),console.log("分享视频失败")}})},RecordManager.prototype.OnNew=function(){var e=this;Laya.Browser.onMobile&&(this.record=Laya.Browser.window.tt.getGameRecorderManager(),this.record.onStart(function(e){console.log(e)}),this.record.onStop(function(t){e.completepath=t.videoPath,console.log(t.videoPath)}))},RecordManager}();a.RecordManager=n},{}],77:[function(e,t,a){"use strict";var n;Object.defineProperty(a,"__esModule",{value:!0}),function(e){e[e.ios=0]="ios",e[e.android=1]="android",e[e.other=2]="other"}(n=a.systemtype||(a.systemtype={}));var i=function(){function WxApi(){}return WxApi.recordAldEvent=function(e,t){void 0===t&&(t=""),console.log("事件: ",e)},WxApi.WXLogin=function(e){Laya.Browser.window.wx.login({success:function(t){t.code?(console.log("code:",t.code),e(t)):console.log("获取用户登录态失败!"+t.errMsg)},fail:function(e){console.log("wx.login: failed, res="+e)}})},WxApi.WxInit=function(){var e=this;Laya.Browser.onWeiXin&&(Laya.Browser.window.wx.showShareMenu({withShareTicket:!0}),Laya.Browser.window.wx.onShow(function(t){console.log(t),e.shareOpenId=t.query.userId,e.querychannel=t.query.channel,t.referrerInfo&&(e.referrerInfoappId=t.referrerInfo.appId,console.log("onShow appId is:",t.referrerInfo.appId)),e.sceneValue=t.scene;var a=Laya.LocalStorage.getItem("scene");a?(e.sceneValue=a,console.log("读取配置场景值:"+a)):(console.log("第一次拉取场景值:"+e.sceneValue),Laya.LocalStorage.setItem("scene",e.sceneValue))}))},WxApi.ShowLoading=function(e){void 0===e&&(e="加载中...")},WxApi.HideLoading=function(){},WxApi.aldSendOpenid=function(e){},WxApi.CheckWXUpdate=function(){var e=Laya.Browser.window.tt.getUpdateManager();e.onCheckForUpdate(function(e){console.log("最新版本:"+e.hasUpdate)}),e.onUpdateReady(function(){Laya.Browser.window.tt.showModal({showCancel:!1,title:"更新提示",content:"新版本已经准备好,是否重启应用?",success:function(t){e.applyUpdate()},fail:function(t){e.applyUpdate()}})})},WxApi.levelStart=function(e,t,a){},WxApi.levelRunning=function(e,t,a,n){console.log("记录关卡中:"+e)},WxApi.levelSuccess=function(e,t,a){console.log("记录关卡:完成"+e)},WxApi.levelFail=function(e,t,a,n,i){console.log("记录关卡:失败"+e)},WxApi.OnShow=function(e){Laya.Browser.window.tt&&Laya.Browser.window.tt.onShow(e)},WxApi.OffShow=function(e){Laya.Browser.onWeiXin&&Laya.Browser.window.tt.offShow(e)},WxApi.shake=function(){Laya.Browser.window.tt.vibrateShort({})},WxApi.shakeLong=function(){Laya.Browser.window.tt.vibrateLong({})},WxApi.Shake=function(e){void 0===e&&(e=!0),Laya.Browser.window.tt&&WxApi.CanShake&&(e?this.shake():this.shakeLong()),e||this.stageShake()},WxApi.stageShake=function(e,t){if(void 0===e&&(e=null),void 0===t&&(t=32),!this.isShake&&this.canshakestage){this.isShake=!0;var a=new Laya.Vector2(Laya.stage.x,Laya.stage.y);Laya.stage.timerLoop(t,this,this.shakeObject,[a,e])}},WxApi.shakeObject=function(e,t){var a=this.num++%4;this.offsetArr[this.num%2]=a<2?0:this.offset,Laya.stage.x=this.offsetArr[0]+e.x,Laya.stage.y=this.offsetArr[1]+e.y,this.num>4*this.times+1&&(Laya.stage.clearTimer(this,this.shakeObject),Laya.stage.pos(0,0),this.num=0,this.isShake=!1,null!=t&&t())},WxApi.ShowTxt=function(e){Laya.Browser.window.tt?Laya.Browser.window.tt.showToast({title:e}):console.log(e)},Object.defineProperty(WxApi,"SystemFrom",{get:function(){if(!Laya.Browser.onWeiXin)return n.other;var e=Laya.Browser.window.wx.getSystemInfoSync().system,t=-1!=e.indexOf("iOS"),a=-1!=e.indexOf("Android");return t?n.ios:a?n.android:n.other},enumerable:!0,configurable:!0}),Object.defineProperty(WxApi,"IsLongScreenSystem",{get:function(){if(!Laya.Browser.onWeiXin)return!1;var e=Laya.Browser.window.wx.getSystemInfoSync(),t="ipx";if(null!=e){var a=e.model;return t=e.brand+"_"+a+"_"+e.system+"_wx"+e.version+"_SDKVer"+e.SDKVersion,console.log("platformModel:"+t),!(a.indexOf("X")<0)||(a.indexOf("oppo")>=0||a.indexOf("OPPO")>=0)&&(a.indexOf("R15")>=0||a.indexOf("r15")>=0)||e.statusBarHeight>20||a.indexOf("Note")>=0&&(a.indexOf("7")>=0||a.indexOf("8")>=0)||a.indexOf("iPhone")>=0&&a.indexOf("11")>=0}},enumerable:!0,configurable:!0}),WxApi.writeStage=function(e){var t=new Array,a=(new Date).getTime(),n=JSON.stringify({wxgame:{stage:e,update_time:a.toString()}});t.push({key:"stage",value:n}),Laya.Browser.window.wx&&Laya.Browser.window.wx.setUserCloudStorage({KVDataList:t,success:function(e){console.log("上传分数成功")}})},WxApi.cpVersionGreaterOrEqual=function(e,t){console.log("[LOG]基础库版本号 curVer:"+e+" targVer:"+t);var a=e.split("."),n=t.split("."),i=a.length;n.length<i&&(i=n.length);for(var o=0;o<i;o++){var r=Number(a[o]),s=Number(n[o]);if(r>s)return!0;if(r<s)return!1}return a.length>=n.length},WxApi.newaccount=!1,WxApi.sceneValue="",WxApi.shareOpenId="",WxApi.querychannel="",WxApi.referrerInfoappId="",WxApi.isShowing=!1,WxApi.CanShake=!0,WxApi.times=1.3,WxApi.num=0,WxApi.offsetArr=[0,0],WxApi.offset=14,WxApi.canshakestage=!1,WxApi}();a.WxApi=i},{}],78:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../utils/DispatcherManager"),i=e("../WXSDK/SocketNofify"),o=function(){function ServerSocket(){this._offlinestate=0,this._connetNums=0,this._socketconneting=!1,ServerSocket.ins=this}return Object.defineProperty(ServerSocket,"Instance",{get:function(){return null==ServerSocket.ins?new ServerSocket:ServerSocket.ins},enumerable:!0,configurable:!0}),ServerSocket.prototype.connectServer=function(e){this._socketconneting=!0,this.removeSocket(),this.sock&&this.sock.connected||(this.openwaitpanel(),this.sock||(this.sock=new Laya.Socket,this.sock.on(Laya.Event.OPEN,this,this.onSocketOpen),this.sock.on(Laya.Event.MESSAGE,this,this.onReceiveMessage),this.sock.on(Laya.Event.CLOSE,this,this.onSocketClose),this.sock.on(Laya.Event.ERROR,this,this.ioErro)),this.sock.connectByUrl(e))},ServerSocket.prototype.isConnect=function(){return!(!this.sock||!this.sock.connected)},ServerSocket.prototype.ioErro=function(e){void 0===e&&(e=null),this._socketconneting=!1,this._connetNums++,this.closewaitpanel(),this.removeSocket(),this._offlinestate=1},ServerSocket.prototype.removeSocket=function(){this._socketconneting=!1,this.sock&&(this.sock.off(Laya.Event.OPEN,this,this.onSocketOpen),this.sock.off(Laya.Event.MESSAGE,this,this.onReceiveMessage),this.sock.off(Laya.Event.CLOSE,this,this.onSocketClose),this.sock.off(Laya.Event.ERROR,this,this.ioErro),this.sock.cleanSocket(),this.sock.close(),this.sock=null)},ServerSocket.prototype.colseSocket=function(e){void 0===e&&(e=1),this.isConnect()&&(this.closewaitpanel(),this.removeSocket(),-1!=e&&(this._offlinestate=e),n.DispatcherManager.dispatchEvent(i.SocketNofify.SOCKET_CLOSE))},ServerSocket.prototype.onSocketClose=function(e){void 0===e&&(e=null),this._socketconneting=!1,this.closewaitpanel(),this._offlinestate=1,n.DispatcherManager.dispatchEvent(i.SocketNofify.SOCKET_CLOSE)},ServerSocket.prototype.closewaitpanel=function(){fairygui.GRoot.inst.closeModalWait()},ServerSocket.prototype.openwaitpanel=function(){fairygui.GRoot.inst.showModalWait()},ServerSocket.prototype.onSocketOpen=function(e){void 0===e&&(e=null),this._connetNums=0,this.closewaitpanel(),this._offlinestate=0,n.DispatcherManager.dispatchEvent(i.SocketNofify.SOCKET_CONNECT_SUCCEED,null,!1)},ServerSocket.prototype.sendMessage=function(e,t,a){void 0===a&&(a=!0),this.sock&&this.sock.connected&&(a&&this.openwaitpanel(),t||(t={}),t.ACTION=e,this.sock.send(JSON.stringify(t)))},ServerSocket.prototype.onReceiveMessage=function(e){void 0===e&&(e=null);JSON.parse(e)},ServerSocket}();a.ServerSocket=o},{"../WXSDK/SocketNofify":79,"../utils/DispatcherManager":85}],79:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function SocketNofify(){}return SocketNofify.SOCKET_CONNECT_SUCCEED="SOCKET_CONNECT_SUCCEED",SocketNofify.SOCKET_CLOSE="SOCKET_CLOSE",SocketNofify.Game_againConnetSocket="Game_againConnetSocket",SocketNofify}();a.SocketNofify=n},{}],80:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function WECHATEVENT(){}return WECHATEVENT.WECHATEVENT_onhide="WECHATEVENT_onhide",WECHATEVENT.WECHATEVENT_onAudioInterruptionEnd="WECHATEVENT_onAudioInterruptionEnd",WECHATEVENT.WECHATEVENT_losefocus="WECHATEVENT_losefocus",WECHATEVENT.WECHATEVENT_getfocus="WECHATEVENT_getfocus",WECHATEVENT.WECHATEVENT_updateVideoNums="WECHATEVENT_updateVideoNums",WECHATEVENT.message_9891002="9891002",WECHATEVENT.message_9891101="9891101",WECHATEVENT.WECHATEVENT_loginSucceed="WECHATEVENT_loginSucceed",WECHATEVENT.WECHATEVENT_onshow="WECHATEVENT_onshow",WECHATEVENT.WECHATEVENT_fromscorfk="WECHATEVENT_fromscorfk",WECHATEVENT.message_9891001="9891001",WECHATEVENT.message_9891102="9891102",WECHATEVENT.message_9891103="9891103",WECHATEVENT}();a.WECHATEVENT=n},{}],81:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../utils/GameUtils"),i=e("../WXSDK/WECHATEVENT"),o=e("../Global"),r=e("../Control/DateControl"),s=e("../Control/LocalDataControl"),l=e("../Data/UserDataInfo"),c=e("../utils/GlobalTip"),h=e("../utils/DispatcherManager"),u=e("../Control/AudioControl"),p=function(){function WXGamePlatform(){this.isShareing=!1,this.bannerRunTime=0,this._bannerTypeList=[],this._screenwidth=0,this.bannerheight=0,this.bannerwidth=0,this.isonResize=!1,this._openrankDict={},WXGamePlatform.ins=this}return Object.defineProperty(WXGamePlatform,"Instance",{get:function(){return null==WXGamePlatform.ins?new WXGamePlatform:WXGamePlatform.ins},enumerable:!0,configurable:!0}),WXGamePlatform.prototype.init=function(){this.showShareMenu({withShareTicket:!0}),this.onAudioInterruptionBegin(),this.onAudioInterruptionEnd()},WXGamePlatform.prototype.initShareDian=function(e){if(e&&e.length>0){var t;for(var a in e)t=e[a],WXGamePlatform.ShareDict[t.key]=t;var n=e[0];this.onShareAppMessage(n.tile,o.Global.cdnurl+n.img)}},WXGamePlatform.prototype.initData=function(){r.DateControl.Fresh?(WXGamePlatform.dayShareNum=0,WXGamePlatform.dayVideoNum=0,this.updateDayShareInfo(),this.updateDayVideoInfo()):(WXGamePlatform.dayShareNum=s.LocalDataControl.Instance.getnum(l.UserDataInfo.nowdayShare),WXGamePlatform.dayVideoNum=s.LocalDataControl.Instance.getnum(l.UserDataInfo.nowdayVideo))},WXGamePlatform.prototype.updateDayShareInfo=function(){s.LocalDataControl.Instance.addstr(l.UserDataInfo.nowdayShare,WXGamePlatform.dayShareNum.toString())},WXGamePlatform.prototype.updateDayVideoInfo=function(){s.LocalDataControl.Instance.addstr(l.UserDataInfo.nowdayVideo,WXGamePlatform.dayVideoNum.toString())},WXGamePlatform.prototype.createUserAndLogin=function(e,t,a,n){void 0===a&&(a=null),void 0===n&&(n=null),WXGamePlatform.loginCallobj=e,WXGamePlatform.loginsucceedcallback=t,WXGamePlatform.loginprogressCallback=a;var i=Laya.Browser.window.wx;if(i){var o=WXGamePlatform.Instance.getLaunchOptionsSync();if(o){var r=o.query;r&&r.ChanID&&(WXGamePlatform.QuDaoID=r.ChanID);var s=o.referrerInfo;""==WXGamePlatform.QuDaoID&&s&&s.appId&&(WXGamePlatform.QuDaoID=s.appId),o.scene&&(WXGamePlatform.fromscene=Number(o.scene))}i.getSystemInfoSync().SDKVersion;if(i.getUpdateManager){var l=i.getUpdateManager();l.onCheckForUpdate(function(a){1==a.hasUpdate?(l.onUpdateReady(function(){Laya.Browser.window.wx.showModal({title:"更新提示",content:"新版本已经准备好,是否重启应用?",success:function(e){e.confirm?l.applyUpdate():WXGamePlatform.Instance.exitGame()}})}),l.onUpdateFailed(function(){WXGamePlatform.Instance.exitGame()})):WXGamePlatform.Instance.login(e,t,n)})}else{WXGamePlatform.Instance.login(e,t,n)}}},WXGamePlatform.prototype.createUserInfoButton=function(e,t,a){this.userinfocallobj=e,this.userinfosuccallback=t,this.userinfofailcallback=a;var n=Laya.Browser.window.wx,i=n.getSystemInfoSync();if(i){var o=(i.windowWidth-151)/2,r=i.windowHeight-172-40;WXGamePlatform.Instance.userinfobutton=n.createUserInfoButton({type:"image",image:"wxlocal/login.png",style:{left:o,top:r,width:151,height:72}}),WXGamePlatform.Instance.userinfobutton.onTap(WXGamePlatform.Instance.userinfoButtonClick)}},WXGamePlatform.prototype.getaccredit=function(e,t){if(0==WXGamePlatform.accreditstate){var a=Laya.Browser.window.wx;a?a.getSetting({success:function(a){var n=a.authSetting;n.hasOwnProperty("scope.userInfo")&&1==n["scope.userInfo"]?t&&e&&t.call(e,!0):t&&e&&t.call(e,!1)}}):t&&e&&t.call(e,!0)}else t&&e&&t.call(e,!0)},WXGamePlatform.prototype.userinfoButtonClick=function(e){var t=WXGamePlatform.Instance;e&&("getUserInfo:ok"==e.errMsg?(WXGamePlatform.accreditstate=1,t.closeuserinfobUtton(),t.getUserInfo(!1,t.userinfocallobj,t.userinfosuccallback,t.userinfofailcallback)):t.userinfocallobj&&t.userinfofailcallback&&t.userinfofailcallback.call(t.userinfocallobj))},WXGamePlatform.prototype.closeuserinfobUtton=function(){var e=WXGamePlatform.Instance;e.userinfobutton&&(e.userinfobutton.offTap(e.userinfoButtonClick),e.userinfobutton.destroy(),e.userinfobutton=null)},WXGamePlatform.prototype.getUserInfo=function(e,t,a,n){fairygui.GRoot.inst.showModalWait();var i=WXGamePlatform.Instance,o=Laya.Browser.window.wx;o&&o.getUserInfo({success:function(o){var r=o.userInfo;WXGamePlatform.nickName=r.nickName,e?i.login(t,a,n):t&&a&&a.call(t,WXGamePlatform.nickName)}})},WXGamePlatform.prototype.login=function(e,t,a){var n=WXGamePlatform.Instance;Laya.Browser.window.wx&&Laya.Browser.window.wx.login({success:function(e){WXGamePlatform.code=e.code;var t={};""!=WXGamePlatform.QuDaoID&&(t.ChanID=WXGamePlatform.QuDaoID),t.Code=WXGamePlatform.code,t.AppID=o.Global.appid,t.Version=o.Global.gameVersion},fail:function(i){n.login(e,t,a)}})},WXGamePlatform.prototype.loginSucceedCallback=function(e){WXGamePlatform.loginCallobj&&WXGamePlatform.loginsucceedcallback&&WXGamePlatform.loginsucceedcallback.call(WXGamePlatform.loginCallobj,e)},WXGamePlatform.prototype.loadSubpackage=function(e,t,a,n,i){if(Laya.Browser.window.wx){this._subcallobj=t,this._subcallback=a,this._updatecallback=n,this._subfailcallback=i;var o=Laya.Browser.window.wx;if(o.loadSubpackage){var r=o.loadSubpackage({name:e,success:function(e){var t=WXGamePlatform.Instance;t._subcallback&&t._subcallobj&&t._subcallback.call(t._subcallobj)},fail:function(e){var t=WXGamePlatform.Instance;t._subfailcallback&&t._subcallobj&&t._subfailcallback.call(t._subcallobj)}});r.onProgressUpdate&&r.onProgressUpdate(function(e){var t=WXGamePlatform.Instance;t._updatecallback&&t._subcallobj&&t._updatecallback.call(t._subcallobj,e.progress)})}else t&&a&&a.call(t)}else t&&a&&a.call(t)},WXGamePlatform.prototype.getShareInfo=function(e,t,a,n){void 0===n&&(n=null),Laya.Browser.window.wx&&Laya.Browser.window.wx.getShareInfo({shareTicket:e.shareTicket,success:function(e){a.call(t,e)}})},WXGamePlatform.prototype.onShareAppMessage=function(e,t){Laya.Browser.window.wx&&Laya.Browser.window.wx.onShareAppMessage(function(){return{title:e,imageUrl:t}})},WXGamePlatform.prototype.shareAppMessage=function(e){Laya.Browser.window.wx&&Laya.Browser.window.wx.shareAppMessage(e)},WXGamePlatform.prototype.showShareMenu=function(e){void 0===e&&(e=null),Laya.Browser.window.wx&&Laya.Browser.window.wx.showShareMenu(e)},WXGamePlatform.prototype.updateShareMenu=function(e){void 0===e&&(e=null),Laya.Browser.window.wx&&Laya.Browser.window.wx.updateShareMenu(e)},WXGamePlatform.prototype.showMenu=function(){Laya.Browser.window.wx&&Laya.Browser.window.wx.showShareMenu()},WXGamePlatform.prototype.setStorageSync=function(e,t){var a=Laya.Browser.window.wx;a&&a.setStorageSync(e,t)},WXGamePlatform.prototype.getStorageSync=function(e){var t=Laya.Browser.window.wx;return t?t.getStorageSync(e):null},WXGamePlatform.prototype.setUserCloudStorage=function(e,t,a,n){void 0===t&&(t=null),void 0===a&&(a=null),void 0===n&&(n=null);var i=Laya.Browser.window.wx;i&&i.setUserCloudStorage&&i.setUserCloudStorage({KVDataList:e,success:function(e){a&&a.call(t,e)},fail:function(e){n&&n.call(t)}})},WXGamePlatform.prototype.toast=function(e){Laya.Browser.window.wx&&Laya.Browser.window.wx.showToast({title:e})},WXGamePlatform.prototype.postMessage=function(e,t){void 0===t&&(t=null);var a=Laya.Browser.window.wx;a&&a.getOpenDataContext().postMessage({action:e,data:t})},WXGamePlatform.prototype.createInnerAudioContext=function(){return Laya.Browser.window.wx?Laya.Browser.window.wx.createInnerAudioContext():null},WXGamePlatform.prototype.getSystemInfoSync=function(){return Laya.Browser.window.wx?Laya.Browser.window.wx.getSystemInfoSync():null},WXGamePlatform.prototype.previewImage=function(e){Laya.Browser.window.wx&&Laya.Browser.window.wx.previewImage(e)},WXGamePlatform.prototype.onHide=function(e,t){Laya.Browser.window.wx&&Laya.Browser.window.wx.onHide(function(a){WXGamePlatform.isShowing=!1,t&&e&&t.call(e,a)})},WXGamePlatform.prototype.getLaunchOptionsSync=function(){return Laya.Browser.window.wx?Laya.Browser.window.wx.getLaunchOptionsSync():null},WXGamePlatform.prototype.hideToast=function(e){Laya.Browser.window.wx&&Laya.Browser.window.wx.hideToast(e)},WXGamePlatform.prototype.showModal=function(e){Laya.Browser.window.wx&&Laya.Browser.window.wx.showModal(e)},WXGamePlatform.prototype.clearStorage=function(){Laya.Browser.window.wx&&Laya.Browser.window.wx.clearStorageSync()},WXGamePlatform.prototype.vibrateShort=function(){Laya.Browser.window.wx&&Laya.Browser.window.wx.vibrateShort()},WXGamePlatform.prototype.removeStorage=function(e){Laya.Browser.window.wx&&Laya.Browser.window.wx.removeStorage(e)},WXGamePlatform.prototype.onAudioInterruptionBegin=function(){Laya.Browser.window.wx&&Laya.Browser.window.wx.onAudioInterruptionBegin(function(){u.AudioControl.Instance.ClearAllSOUND()})},WXGamePlatform.prototype.onAudioInterruptionEnd=function(){Laya.Browser.window.wx&&Laya.Browser.window.wx.onAudioInterruptionEnd(function(){var e=WXGamePlatform.Instance;Laya.timer.clear(e,e.onAudioEndCallback),Laya.timer.once(500,e,e.onAudioEndCallback)})},WXGamePlatform.prototype.onAudioEndCallback=function(){h.DispatcherManager.dispatchEvent(i.WECHATEVENT.WECHATEVENT_onAudioInterruptionEnd)},WXGamePlatform.prototype.exitGame=function(){var e=Laya.Browser.window.wx;e&&e.exitMiniProgram()},WXGamePlatform.prototype.openCustomerService=function(){var e=Laya.Browser.window.wx;if(e){var t=e.getSystemInfoSync().SDKVersion;n.GameUtils.compareVersion(t,"2.0.3")>=0&&e.openCustomerServiceConversation&&e.openCustomerServiceConversation({showMessageCard:!0,sendMessageImg:"https://resource.51yoyoyo.com/res/wxsendmessageimg/smi.jpg"})}},WXGamePlatform.prototype.onMemoryWarning=function(){var e=Laya.Browser.window.wx;e&&e.onMemoryWarning&&e.onMemoryWarning(function(){})},WXGamePlatform.prototype.onError=function(){var e=Laya.Browser.window.wx;e&&e.onError&&e.onError(function(e){console.log("*****onError",e)})},WXGamePlatform.prototype.startShareApp=function(e,t,a,n){void 0===t&&(t=null),void 0===a&&(a=null),void 0===n&&(n=null),WXGamePlatform.nowShareindex=0,WXGamePlatform.ShareDict[e]&&this.shareApp(WXGamePlatform.ShareDict[e],t,a,n)},WXGamePlatform.prototype.shareApp=function(e,t,a,n){this.nowshareObj=t,this.nowshareinfo=e,this.nowsharesucceedfun=a,this.nowsharefailfun=n,this.startShareTime=Laya.Browser.now(),this.isShareing=!0,WXGamePlatform.callbackfailstate=0,this.shareAppMessage({title:e.tile,imageUrl:o.Global.cdnurl+e.img,query:"",success:function(e){},fail:function(e){c.GlobalTip.Instance.showWordTips("您取消了分享"),n&&t&&n.call(t)},cancel:function(e){WXGamePlatform.callbackfailstate=1}})},WXGamePlatform.prototype.onShow=function(e,t,a){void 0===e&&(e=null),void 0===t&&(t=null),void 0===a&&(a=null),this.showobj=e,this.showCallback=t;var n=Laya.Browser.window.wx;n&&n.onShow(function(e){WXGamePlatform.isShowing=!0,e&&e.scene&&(WXGamePlatform.fromscene=Number(e.scene)),Laya.timer.frameOnce(1,WXGamePlatform.Instance,WXGamePlatform.Instance.onShowSucceed)})},WXGamePlatform.prototype.onShowSucceed=function(){var e=WXGamePlatform.Instance;if(e.showobj&&e.showCallback&&e.showCallback.call(e.showobj),e.isShareing){e.isShareing=!1;var t=!1;if(0==WXGamePlatform.callbackfailstate)((Laya.Browser.now()-e.startShareTime)/1e3>=WXGamePlatform.ShareTime||WXGamePlatform.nowShareindex>=3)&&(t=!0);WXGamePlatform.callbackfailstate=0,t?(WXGamePlatform.dayShareNum++,e.updateDayShareInfo(),e.nowshareObj&&e.nowsharesucceedfun&&e.nowsharesucceedfun.call(e.nowshareObj)):(WXGamePlatform.nowShareindex++,e.showModal({title:"提示",content:"请每次分享到不同群,是否重新分享?",showCancel:!0,cancelText:"取消",confirmText:"确定",success:function(e){var t=WXGamePlatform.Instance;e.confirm?WXGamePlatform.Instance.shareApp(t.nowshareinfo,t.nowshareObj,t.nowsharesucceedfun,t.nowsharefailfun):t.nowsharefailfun&&t.nowshareObj&&t.nowsharefailfun.call(t.nowshareObj)},fail:function(){},complete:function(){}}))}},WXGamePlatform.prototype.playVideo=function(e,t,a,n,o){var r=this;void 0===t&&(t=null),void 0===a&&(a=null),void 0===n&&(n=null),void 0===o&&(o=!0);var s=Laya.Browser.window.wx;if(s&&s.createRewardedVideoAd&&!WXGamePlatform.videoplaying){var l=this.lockVideoLeftTime();if(l>0)return void c.GlobalTip.Instance.showWordTips("广告尚未准备好,请"+l+"秒后再试");h.DispatcherManager.dispatchEvent(i.WECHATEVENT.WECHATEVENT_losefocus),WXGamePlatform.istongjiVideoNum=o,this.nowvideokey=e,WXGamePlatform.videoplaying=!0,this.videocallobj=t,this.videosucceedCallback=a,this.videofailCallback=n,this.videoAd=s.createRewardedVideoAd({adUnitId:"adunit-0c687084c908ee89"}),this.videoAd.onClose(this.closeAD),this.videoAd.onError(this.onerro),this.videoAd.load().then(function(){return r.videoAd.show()}).catch(function(e){console.log(e.errMsg),WXGamePlatform.Instance.failVideo()})}},WXGamePlatform.prototype.lockVideoLeftTime=function(){var e=(Laya.Browser.now()-WXGamePlatform.lastVideoTime)/1e3;return e=WXGamePlatform.VideoTime-e,Math.ceil(e)},WXGamePlatform.prototype.onerro=function(e){var t=WXGamePlatform.Instance;WXGamePlatform.videoplaying=!1,t.videoAd.offError(t.onerro),t.videoAd.offClose(t.closeAD),h.DispatcherManager.dispatchEvent(i.WECHATEVENT.WECHATEVENT_getfocus)},WXGamePlatform.prototype.closeAD=function(e){WXGamePlatform.lastVideoTime=Laya.Browser.now();var t=WXGamePlatform.Instance;e&&e.isEnded||null==e?(WXGamePlatform.istongjiVideoNum&&(WXGamePlatform.dayVideoNum++,t.updateDayVideoInfo(),h.DispatcherManager.dispatchEvent(i.WECHATEVENT.WECHATEVENT_updateVideoNums)),t.videocallobj&&t.videosucceedCallback&&t.videosucceedCallback.call(t.videocallobj)):(c.GlobalTip.Instance.showWordTips("未观看完整视频,无法获得奖励"),t.videocallobj&&t.videofailCallback&&t.videofailCallback.call(t.videocallobj)),WXGamePlatform.videoplaying=!1,t.videoAd.offError(t.onerro),t.videoAd.offClose(t.closeAD),h.DispatcherManager.dispatchEvent(i.WECHATEVENT.WECHATEVENT_getfocus)},WXGamePlatform.prototype.failVideo=function(){WXGamePlatform.lastVideoTime=Laya.Browser.now(),WXGamePlatform.videoplaying=!1,c.GlobalTip.Instance.showWordTips("广告加载失败,试试别的方式吧~");var e=WXGamePlatform.Instance;e.videoAd.offError(e.onerro),e.videoAd.offClose(e.closeAD),e.videocallobj&&e.videofailCallback&&e.videofailCallback.call(e.videocallobj),h.DispatcherManager.dispatchEvent(i.WECHATEVENT.WECHATEVENT_getfocus)},WXGamePlatform.prototype.isCanVideo=function(){if(WXGamePlatform.dayVideoNum<WXGamePlatform.VideoNum){if(0==WXGamePlatform.dayVideoNum)return!0;var e=Math.floor(WXGamePlatform.dayVideoNum/WXGamePlatform.VideotoShare),t=Math.floor(WXGamePlatform.dayShareNum/WXGamePlatform.SharetoVideo);return!(e>t)&&(e<t||(0!=WXGamePlatform.dayVideoNum%WXGamePlatform.VideotoShare||0==WXGamePlatform.dayShareNum%WXGamePlatform.SharetoVideo))}return!1},WXGamePlatform.prototype.createBanner=function(e,t){if(void 0===e&&(e=""),Laya.Browser.window.wx){if(""!=e){for(var a=!1,n=0;n<this._bannerTypeList.length;n++)if(e==this._bannerTypeList[n].type){this._bannerTypeList[n].style=t;var i=this._bannerTypeList.splice(n,1);this._bannerTypeList.push(i[0]),a=!0;break}a||this._bannerTypeList.push({type:e,style:t})}else{if(0==this._bannerTypeList.length)return;t=this._bannerTypeList[this._bannerTypeList.length-1].style}if(this.bannerAd)Laya.Browser.now()-this.bannerRunTime>18e4?(this.bannerAd.offError(this.bannerError),this.bannerAd.offResize(this.bannerResize),this.bannerAd.destory(),this.createNewBanner(t)):this.showBanner(t);else this.createNewBanner(t)}},WXGamePlatform.prototype.createNewBanner=function(e){var t=Laya.Browser.window.wx;if(t&&t.createBannerAd){this.nowStype=e,this.bannerRunTime=Laya.Browser.now();var a=this.getSystemInfoSync();this._screenwidth=a.screenWidth;var n=1;e.hasOwnProperty("scale")&&(n=e.scale),this.bannerAd=t.createBannerAd({adUnitId:"adunit-8c2d586135fa6d4f",adIntervals:30,style:{left:0,top:a.screenHeight-105,width:a.screenWidth*n}}),this.bannerAd&&(this.bannerAd.onError(this.bannerError),this.showBanner(e))}},WXGamePlatform.prototype.bannerResize=function(e){var t=WXGamePlatform.Instance;t.bannerAd.offResize(t.bannerResize),t.isonResize=!1;var a=t.nowStype;if(a){var n=t.getSystemInfoSync(),i=Laya.Browser.clientHeight/Laya.stage.displayHeight,o=Laya.Browser.clientWidth/Laya.stage.displayWidth;t.bannerwidth=e.width,t.bannerheight=e.height,a.hasOwnProperty("x")&&0!=a.x?t.bannerAd.style.left=a.x*o:t.bannerAd.style.left=.5*(n.windowWidth-e.width),a.hasOwnProperty("y")&&0!=a.y?t.bannerAd.style.top=a.y*i:t.bannerAd.style.top=n.windowHeight-e.height-15}},WXGamePlatform.prototype.bannerError=function(e){},WXGamePlatform.prototype.showBanner=function(e){if(this.bannerAd){this.nowStype=e;var t=this.getSystemInfoSync(),a=this.nowStype,n=1;a.hasOwnProperty("scale")&&(n=a.scale);var i=Laya.Browser.clientHeight/Laya.stage.displayHeight,o=Laya.Browser.clientWidth/Laya.stage.displayWidth;a.hasOwnProperty("x")&&0!=a.x?this.bannerAd.style.left=a.x*o:this.bannerAd.style.left=.5*(t.windowWidth-this.bannerwidth),a.hasOwnProperty("y")&&0!=a.y?this.bannerAd.style.top=a.y*i:this.bannerAd.style.top=t.windowHeight-this.bannerheight-15,this.bannerAd.style.width=t.screenWidth*n,this.isonResize||(this.isonResize=!0,this.bannerAd.onResize(this.bannerResize)),this.bannerAd.show()}},WXGamePlatform.prototype.hideBanner=function(e){if(void 0===e&&(e=""),this.bannerAd&&this.bannerAd.hide(),""!=e){for(var t=0;t<this._bannerTypeList.length;t++)if(e==this._bannerTypeList[t].type){this._bannerTypeList.splice(t,1);break}if(this._bannerTypeList.length>0){var a=this._bannerTypeList[this._bannerTypeList.length-1];this.createBanner(a.type,a.style)}}},WXGamePlatform.prototype.openFriendRank=function(e,t,a,n,i){void 0===n&&(n=null),void 0===i&&(i=null),this.closeziyuStage(),this._openrankDict[t]={type:e,viewType:t,rect:a,parent:n,data:i},this.initziyuStage(a,n),this.postMessage(e,i)},WXGamePlatform.prototype.changeFriendRank=function(e){this.postMessage(e)},WXGamePlatform.prototype.prePageRank=function(){},WXGamePlatform.prototype.nextPageRank=function(){},WXGamePlatform.prototype.closeFriendRank=function(e){for(var t in this.closeziyuStage(),this._openrankDict[e]&&delete this._openrankDict[e],this._openrankDict){var a=this._openrankDict[t];this.openFriendRank(a.type,a.viewType,a.rect,a.parent,a.data);break}},WXGamePlatform.prototype.initziyuStage=function(e,t){},WXGamePlatform.prototype.closeziyuStage=function(){},WXGamePlatform.prototype.storeToCloud=function(e,t){var a=s.LocalDataControl.Instance,n=a.getnum("param1"),i=e=Math.floor(e),o=t=Math.floor(t);i<n?i=n:a.addstr("param1",i.toString());var r=[];r.push({key:"param1",value:i.toString()}),r.push({key:"param2",value:o+""}),this.setUserCloudStorage(r)},WXGamePlatform.prototype.createGameClubButton=function(e,t){void 0===t&&(t="green");var a=Laya.Browser.window.wx;a&&e&&(e.width=40,e.height=40,WXGamePlatform.gameclubButton=a.createGameClubButton({icon:t,style:e}),WXGamePlatform.gameclubButton&&WXGamePlatform.gameclubButton.show())},WXGamePlatform.QuDaoID="",WXGamePlatform.isShowing=!0,WXGamePlatform.accreditstate=0,WXGamePlatform.dayShareNum=0,WXGamePlatform.dayVideoNum=0,WXGamePlatform.ShareTime=0,WXGamePlatform.VideoNum=0,WXGamePlatform.VideoTime=0,WXGamePlatform.jiliweitime=100,WXGamePlatform.SharetoVideo=1,WXGamePlatform.VideotoShare=1,WXGamePlatform.ShareDict={},WXGamePlatform.fromscene=0,WXGamePlatform.nowShareindex=0,WXGamePlatform.callbackfailstate=0,WXGamePlatform.lastVideoTime=0,WXGamePlatform.videoplaying=!1,WXGamePlatform.istongjiVideoNum=!0,WXGamePlatform}();a.WXGamePlatform=p},{"../Control/AudioControl":18,"../Control/DateControl":20,"../Control/LocalDataControl":23,"../Data/UserDataInfo":35,"../Global":41,"../WXSDK/WECHATEVENT":80,"../utils/DispatcherManager":85,"../utils/GameUtils":87,"../utils/GlobalTip":88}],82:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../WXSDK/WXGamePlatform"),i=e("./PlatfromType"),o=e("../WXSDK/WECHATEVENT"),r=e("../Global"),s=e("../utils/DispatcherManager"),l=e("../Time/TimesTamper"),c=e("../Control/DateControl"),h=e("../Control/AudioControl"),u=function(){function pingtaiutils(){this._isenable=!1,pingtaiutils.ins=this}return Object.defineProperty(pingtaiutils,"Instance",{get:function(){return null==pingtaiutils.ins?new pingtaiutils:pingtaiutils.ins},enumerable:!0,configurable:!0}),pingtaiutils.prototype.initPlatfrom=function(){Laya.Browser.window.tt?r.Global.nowplatfrom=i.PlatfromType.tt:Laya.Browser.window.wx?r.Global.nowplatfrom=i.PlatfromType.wx:r.Global.nowplatfrom=i.PlatfromType.pc},pingtaiutils.prototype.init=function(){this.initPlatfrom()},pingtaiutils.prototype.initData=function(){switch(c.DateControl.Instance.SetSelf(),r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.initData()}},pingtaiutils.checkEnable=function(){return 1==pingtaiutils.islegal},pingtaiutils.prototype.login=function(e,t,a,o){switch(void 0===e&&(e=null),void 0===t&&(t=null),void 0===a&&(a=null),void 0===o&&(o=null),fairygui.GRoot.inst.showModalWait(),this._logincallobj=e,this._loginsucceedcallback=t,r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.createUserAndLogin(this,this.loginSucceed,this.loginprogressCallback,this.loginfailcallback);break;default:this.loginSucceed(null)}},pingtaiutils.prototype.loginprogressCallback=function(e){},pingtaiutils.prototype.loginSucceed=function(e){fairygui.GRoot.inst.closeModalWait()},pingtaiutils.prototype.loginfailcallback=function(){},pingtaiutils.prototype.onShow=function(e,t,a){switch(void 0===e&&(e=null),void 0===t&&(t=null),void 0===a&&(a=null),r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.onShow(e,t,a);break;case i.PlatfromType.qq:}},pingtaiutils.prototype.showcallback=function(){Laya.timer.clear(this,this.againplaybgSound),Laya.timer.once(500,this,this.againplaybgSound),s.DispatcherManager.dispatchEvent(o.WECHATEVENT.WECHATEVENT_onshow),s.DispatcherManager.dispatchEvent(o.WECHATEVENT.WECHATEVENT_getfocus);var e=pingtaiutils.fromscene();1089!=e&&1131!=e||s.DispatcherManager.dispatchEvent(o.WECHATEVENT.WECHATEVENT_fromscorfk)},pingtaiutils.prototype.againplaybgSound=function(){s.DispatcherManager.dispatchEvent(o.WECHATEVENT.WECHATEVENT_onAudioInterruptionEnd)},pingtaiutils.prototype.onHide=function(e,t){switch(void 0===e&&(e=null),void 0===t&&(t=null),r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.onHide(e,t);break;case i.PlatfromType.qq:}},pingtaiutils.prototype.hidecallback=function(){l.TimesTamper.Instance.sendonlineTongji(),h.AudioControl.Instance.ClearAllSOUND(),s.DispatcherManager.dispatchEvent(o.WECHATEVENT.WECHATEVENT_onhide),s.DispatcherManager.dispatchEvent(o.WECHATEVENT.WECHATEVENT_losefocus)},Object.defineProperty(pingtaiutils.prototype,"isshow",{get:function(){var e=!0;switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.isShowing&&(e=!0),e=!1}return e},enumerable:!0,configurable:!0}),pingtaiutils.prototype.loadSubpackage=function(e,t,a,o,s){switch(void 0===s&&(s=null),r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.loadSubpackage(e,t,a,o,s);break;default:t&&a&&a.call(t)}},pingtaiutils.prototype.isaccredit=function(e,t){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:case i.PlatfromType.qq:n.WXGamePlatform.Instance.getaccredit(e,t);break;default:t&&e&&t.call(e,!0)}},pingtaiutils.prototype.createaccredit=function(e,t,a){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.createUserInfoButton(e,t,a)}},pingtaiutils.prototype.closeuserinfoButton=function(){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.closeuserinfobUtton()}},pingtaiutils.prototype.exitGame=function(){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.exitGame()}},pingtaiutils.prototype.openCustomerService=function(){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.openCustomerService()}},pingtaiutils.prototype.vibrateShort=function(){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.vibrateShort()}},pingtaiutils.isCanVideo=function(){var e=!1;if(pingtaiutils.checkEnable())e=!0;else switch(r.Global.nowplatfrom){case i.PlatfromType.wx:e=n.WXGamePlatform.Instance.isCanVideo();break;default:e=!0}return e},pingtaiutils.prototype.startShareApp=function(e,t,a,o){switch(void 0===t&&(t=null),void 0===a&&(a=null),void 0===o&&(o=null),r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.startShareApp(e,t,a,o);break;default:t&&a&&a.call(t)}},pingtaiutils.prototype.playVideo=function(e,t,a,o,s){switch(void 0===t&&(t=null),void 0===a&&(a=null),void 0===o&&(o=null),void 0===s&&(s=!0),r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.playVideo(e,t,a,o,s);break;default:t&&a&&a.call(t)}},pingtaiutils.prototype.createBanner=function(e,t){switch(void 0===t&&(t={x:0,y:0,scale:1}),r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.createBanner(e,t)}},pingtaiutils.prototype.hideBanner=function(e){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.hideBanner(e)}},pingtaiutils.prototype.storeToCloud=function(e,t){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.storeToCloud(e,t)}},pingtaiutils.prototype.openFriendRank=function(e,t,a,o,s){switch(void 0===o&&(o=null),void 0===s&&(s=null),r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.openFriendRank(e,t,a,o,s)}},pingtaiutils.prototype.changeFriendRank=function(e){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.changeFriendRank(e)}},pingtaiutils.prototype.prePageRank=function(){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.prePageRank()}},pingtaiutils.prototype.nextPageRank=function(){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.nextPageRank()}},pingtaiutils.prototype.closeFriendRank=function(e){switch(r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.closeFriendRank(e)}},pingtaiutils.prototype.lockVideoLeftTime=function(){var e=0;switch(r.Global.nowplatfrom){case i.PlatfromType.wx:e=n.WXGamePlatform.Instance.lockVideoLeftTime()}return e},pingtaiutils.dayVideoNums=function(){var e=0;switch(r.Global.nowplatfrom){case i.PlatfromType.wx:e=n.WXGamePlatform.dayVideoNum}return e},pingtaiutils.fromscene=function(){var e=0;switch(r.Global.nowplatfrom){case i.PlatfromType.wx:e=n.WXGamePlatform.fromscene}return e},pingtaiutils.createGameClubButton=function(e,t){switch(void 0===t&&(t="green"),r.Global.nowplatfrom){case i.PlatfromType.wx:n.WXGamePlatform.Instance.createGameClubButton(e,t)}},pingtaiutils.islegal=0,pingtaiutils}();a.pingtaiutils=u},{"../Control/AudioControl":18,"../Control/DateControl":20,"../Global":41,"../Time/TimesTamper":60,"../WXSDK/WECHATEVENT":80,"../WXSDK/WXGamePlatform":81,"../utils/DispatcherManager":85,"./PlatfromType":74}],83:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./PlayerAccount"),i=function(){function ttshare(){}return ttshare.share=function(){Laya.Browser.window.tt.shareAppMessage({channel:"article",templateId:"ocgf9b46464b9anlff",title:"冲啊冲",imageUrl:"jiazai/123.png",query:"res.query",success:function(){},fail:function(){}})},ttshare}();a.ttshare=i;var o=function(){function ttad(){ttad.instance=this}return Object.defineProperty(ttad,"Instance",{get:function(){return ttad.instance?ttad.instance:new ttad},enumerable:!0,configurable:!0}),ttad.InitAD=function(){n.PlayerAccount.CurrentAccount.CurAccountData.video&&Laya.Browser.onMobile&&(ttad.bannerAdUnitId=n.PlayerAccount.CurrentAccount.CurAccountData.bannerAdUnitId?n.PlayerAccount.CurrentAccount.CurAccountData.bannerAdUnitId:ttad.bannerAdUnitId,console.log("bannerAdUnitId",ttad.bannerAdUnitId),ttad.videlAdUnitId=n.PlayerAccount.CurrentAccount.CurAccountData.videlAdUnitId?n.PlayerAccount.CurrentAccount.CurAccountData.videlAdUnitId:ttad.videlAdUnitId,console.log("videlAdUnitId",ttad.videlAdUnitId),ttad.videoAd=Laya.Browser.window.tt.createRewardedVideoAd({adUnitId:this.videlAdUnitId}),ttad.videoAd.onClose(function(e){e.isEnded?ttad.closecallback&&ttad.closecallback(!0):ttad.closecallback&&ttad.closecallback(!1)}))},ttad.ShowVideo=function(e){var t=this;n.PlayerAccount.CurrentAccount.CurAccountData.video&&Laya.Browser.onMobile&&(console.log("show video"),ttad.closecallback=e,ttad.videoAd.show().then(function(){console.log("广告显示成功")}).catch(function(e){console.log("广告组件出现问题",e),Laya.timer.once(200,t,function(){ttad.videoAd.load().then(function(){return console.log("手动加载成功"),ttad.videoAd.show()})})}))},ttad.Showbanner=function(){if(Laya.Browser.onMobile){console.log("show banner"),ttad.canshow=!0;var e=Laya.Browser.window.tt.getSystemInfoSync();ttad.bannerAd&&ttad.bannerAd.destroy(),Laya.timer.once(200,this,function(){ttad.bannerAd=Laya.Browser.window.tt.createBannerAd({adUnitId:ttad.bannerAdUnitId,style:{width:200,top:e.windowHeight-112.5}}),ttad.bannerAd.onLoad(function(){ttad.canshow&&ttad.bannerAd.show().then(function(){console.log("广告显示成功")}).catch(function(e){console.log("广告组件出现问题",e)})}),ttad.bannerAd.onResize(function(t){console.log(t.width,t.height),ttad.bannerAd.style.top=e.windowHeight-t.height,ttad.bannerAd.style.left=(e.windowWidth-t.width)/2})})}},ttad.Clear=function(){ttad.canshow=!1,ttad.closecallback=null,ttad.bannerAd&&ttad.bannerAd.hide()},ttad.CreateMoreGameBtn=function(e){void 0===e&&(e=null),Laya.Browser.onMobile&&(Laya.Browser.onIOS?ttad.ShowTxt("暂未开放"):Laya.Browser.window.tt.showMoreGamesModal({appLaunchOptions:[{appId:"tt66d0106df9eaa083",query:"foo=bar&baz=qux",extraData:{}}],success:function(t){console.log("success",t.errMsg),e&&e()},fail:function(e){console.log("fail",e.errMsg)}}))},ttad.ShowTxt=function(e){Laya.Browser.window.tt?Laya.Browser.window.tt.showToast({title:e}):console.log(e)},ttad.videlAdUnitId="15gfgp58pocp80hbkb",ttad.bannerAdUnitId="dsk7cohbl2f4jpjtq5",ttad.canshow=!0,ttad}();a.ttad=o},{"./PlayerAccount":75}],84:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(e){function DisPatcherOn(){var t=e.call(this)||this;return t.isInit=!1,DisPatcherOn.ins=t,t.isInit,null==t._dispatcher&&(t._dispatcher=new Laya.EventDispatcher,t.isInit=!0),t}return __extends(DisPatcherOn,e),Object.defineProperty(DisPatcherOn,"Instance",{get:function(){return null==DisPatcherOn.ins?new DisPatcherOn:DisPatcherOn.ins},enumerable:!0,configurable:!0}),DisPatcherOn.prototype.addEventListener=function(e,t,a,n,i){void 0===n&&(n=!1),void 0===i&&(i=0),this._dispatcher.on(e,a,t)},DisPatcherOn.prototype.removeEventListener=function(e,t,a,n){void 0===n&&(n=!1),this._dispatcher.off(e,a,t)},DisPatcherOn.prototype.hasEventListener=function(e){return this._dispatcher.hasListener(e)},DisPatcherOn.prototype.dispatchEvent=function(e,t){return this._dispatcher.event(e,t)},DisPatcherOn}(Laya.EventDispatcher);a.DisPatcherOn=n},{}],85:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("./LEvent"),i=e("./DisPatcherOn"),o=function(){function DispatcherManager(){}return DispatcherManager.init=function(){i.DisPatcherOn.Instance},DispatcherManager.Event=function(e,t,a,i){return void 0===t&&(t=null),void 0===a&&(a=!1),void 0===i&&(i=!1),new n.LEvent(e,t,a,i)},DispatcherManager.dispatchEvent=function(e,t,a,n){void 0===t&&(t=null),void 0===a&&(a=!1),void 0===n&&(n=!1),i.DisPatcherOn.Instance.dispatchEvent(e,t)},DispatcherManager.addEventListener=function(e,t,a,n,o){void 0===n&&(n=!1),void 0===o&&(o=0),i.DisPatcherOn.Instance.addEventListener(e,a,t,n,o)},DispatcherManager.hasEventListener=function(e){return i.DisPatcherOn.Instance.hasEventListener(e)},DispatcherManager.removeEventListener=function(e,t,a,n,o){void 0===n&&(n=!1),void 0===o&&(o=0),i.DisPatcherOn.Instance.removeEventListener(e,a,t)},DispatcherManager}();a.DispatcherManager=o},{"./DisPatcherOn":84,"./LEvent":89}],86:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=Laya.Sprite,i=function(){function GameState(){this.btnArr=["res/button.png","res/button.png","res/button.png"],this.nameArr=["canvas截图","sprite截图","清理"]}return GameState.prototype.drawSomething=function(){this.sp=new n,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"})},GameState.prototype._onclick=function(e){switch(e.target.name){case this.nameArr[0]:var t=this._canvas.toDataURL("image/png",1);this.drawImage.skin=t;break;case this.nameArr[1]:var a=Laya.stage.drawToTexture(Laya.Browser.clientWidth,Laya.Browser.clientHeight,0,0);this.drawSp.graphics.drawTexture(a,0,0,this.drawSp.width,this.drawSp.height);break;case this.nameArr[2]:this.drawImage.skin=null,this.drawSp.graphics.clear(),this.drawSp.graphics.drawRect(0,0,this.drawSp.width,this.drawSp.height,"#ff0000")}},GameState.removeselect="GameState_removeselect",GameState.npcend="GameState_npcendGame",GameState.win="GameState_winGame",GameState.fail="GameState_failGame",GameState.jump="GameState_jumpgame",GameState.stop="GameState_stopGame",GameState.returnMainView="returnMainView",GameState.updateSKinView="GameState_updateSKinView",GameState.start="GameState_startGame",GameState.end="GameState_endGame",GameState.lose="GameState_loseGame",GameState.revive="GameState_reviveGame",GameState.isdie=!1,GameState.fuhuocishu=1,GameState.recordscree=!1,GameState.GameNum=0,GameState}();a.GameState=i},{}],87:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0}),function(e){e.randRangeint=function(e,t){var a=Math.floor(Math.random()*(t-e+1))+e;return a>t&&(a=t),a},e.randRangefloat=function(e,t){var a=Math.random()*(t-e+1)+e;return a>t&&(a=t),a},e.getTexbyPkgAndName=function(e,t){var a=fairygui.UIPackage.getByName(e);return a?a.getItemAssetByName(t):null},e.cutfenhaoPoint=function(e){var t=e.split(";");return new Laya.Point(Number(t[0]),Number(t[1]))},e.cutfenhaotoArrnum=function(e){var t=[];if(""==e)return t;for(var a=e.split(";"),n=0;n<a.length;n++)t.push(Number(a[n]));return t},e.cutfenhaotoArrstr=function(e){return e.split(";")},e.cutfenhaotoObj=function(e){var t={},a=e.split(";");return t.key=a[0],t.value=a[1],t},e.cutstrtoArr=function(e){return e.split("|")},e.cutstrtoArr1=function(e){var t=[],a=e.split("|"),n=0;for(n=0;n<a.length;n++){var i=a[n].split(";");t.push({key:i[0],value:i[1]})}return t},e.cutstrtoObj=function(e){var t={},a=e.split("|"),n=0;for(n=0;n<a.length;n++){var i=a[n].split(";");t[i[0]]=i[1]}return t},e.compareVersion=function(e,t){e=e.split("."),t=t.split(".");for(var a=Math.max(e.length,t.length);e.length<a;)e.push("0");for(;t.length<a;)t.push("0");for(var n=0;n<a;n++){var i=parseInt(e[n]),o=parseInt(t[n]);if(i>o)return 1;if(i<o)return-1}return 0}}(a.GameUtils||(a.GameUtils={}))},{}],88:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../View/GlobalTipPanel"),i=e("../Control/LayoutControl"),o=e("../utils/LayOUT"),r=e("../utils/DispatcherManager"),s=e("../utils/GameState"),l=function(){function GlobalTip(){GlobalTip.ins=this}return Object.defineProperty(GlobalTip,"Instance",{get:function(){return null==GlobalTip.ins?new GlobalTip:GlobalTip.ins},enumerable:!0,configurable:!0}),GlobalTip.prototype.initEvent=function(){GlobalTip.isEvent=!0,r.DispatcherManager.addEventListener(s.GameState.removeselect,this,this.addwordList)},GlobalTip.prototype.showWordTips=function(e){if(GlobalTip.isEvent||GlobalTip.Instance.initEvent(),GlobalTip.showWordList.length>0)GlobalTip.showWordList[GlobalTip.showWordList.length-1].nowword;if(GlobalTip.wordList.length>0){var t=GlobalTip.wordList.shift();i.LayoutControl.Instance.AddLayerByName(t,o.LayOUT.TIP),GlobalTip.showWordList.push(t),t.showWord(e)}else if(GlobalTip.showWordList.length<10){var a=new n.WordTipsPanel;i.LayoutControl.Instance.AddLayerByName(a,o.LayOUT.TIP),GlobalTip.showWordList.push(a),a.showWord(e)}else{(a=GlobalTip.showWordList.shift()).showWord(e),GlobalTip.showWordList.push(a)}},GlobalTip.prototype.addwordList=function(e){if(e){e.removeFromParent();var t=GlobalTip.showWordList.indexOf(e);-1!=t&&GlobalTip.showWordList.splice(t,1),i.LayoutControl.Instance.ClearLayerByName(o.LayOUT.TIP),GlobalTip.wordList.push(e)}},GlobalTip.wordList=[],GlobalTip.showWordList=[],GlobalTip.maxNum=10,GlobalTip.isEvent=!1,GlobalTip}();a.GlobalTip=l},{"../Control/LayoutControl":22,"../View/GlobalTipPanel":64,"../utils/DispatcherManager":85,"../utils/GameState":86,"../utils/LayOUT":90}],89:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(e){function LEvent(t,a,n,i){void 0===a&&(a=null),void 0===n&&(n=!1),void 0===i&&(i=!1);var o=e.call(this)||this;return o.CLASS_NAME="LEvent",a&&(o._obj=a),o}return __extends(LEvent,e),LEvent.prototype.clone=function(e){return new LEvent(this.type,e||this._obj)},LEvent.prototype.toString=function(){console.log(this.CLASS_NAME,"type","bubbles","cancelable")},Object.defineProperty(LEvent.prototype,"param",{get:function(){return this._obj},enumerable:!0,configurable:!0}),LEvent}(Laya.Event);a.LEvent=n},{}],90:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function LayOUT(){}return LayOUT.BG="BG",LayOUT.UI="UI",LayOUT.UITop="UITop",LayOUT.TIP="TIP",LayOUT.GUIDE="GUIDE",LayOUT}();a.LayOUT=n},{}],91:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(e){function Singleton(){return e.call(this)||this}return __extends(Singleton,e),Singleton.Instance=function(e){if(null==e.key)throw new Error("getinstance erro");return this._dict[e.key]},Singleton.getInstanceOrCreate=function(e){if(null==e.key)throw new Error("getInstanceOrCreate erro");return this.create(e),this._dict[e.key]},Singleton.create=function(e){if(null==e.key)throw new Error("create erro");return null==this._dict[e.key]&&(this._dict[e.key]=new e),this._dict[e.key]},Singleton.remove=function(e){var t=e.key;null!=this._dict[t]&&this._dict[t].destory()},Singleton.prototype.destory=function(){},Singleton._dict={},Singleton}(Laya.EventDispatcher);a.Singleton=n},{}],92:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=e("../Agency/AgencySkin"),i=e("../PrefabControl/PanelResDic"),o=e("../utils/GlobalTip"),r=e("../Config/AssetPath"),s=Laya.MovieClip,l=e("../WXSDK/ttad"),c=function(e){function SkinItem(){var t=e.call(this)||this;return t.bgColorChannels={r:99,g:0,b:255},t.SWFPath="res/swf/dragon.swf",t.MCWidth=318,t.MCHeight=406,t}return __extends(SkinItem,e),SkinItem.prototype.getHexColorString=function(){this.bgColorChannels.r=Math.floor(this.bgColorChannels.r),this.bgColorChannels.g=0,this.bgColorChannels.b=Math.floor(this.bgColorChannels.b);var e=this.bgColorChannels.r.toString(16);e=2==e.length?e:"0"+e;var t=this.bgColorChannels.g.toString(16);t=2==t.length?t:"0"+t;var a=this.bgColorChannels.b.toString(16);return"#"+e+t+(a=2==a.length?a:"0"+a)},SkinItem.prototype.constructFromXML=function(t){for(var a in e.prototype.constructFromXML.call(this,t),this._children){var n=this._children[a];this[n.name]=n}this.onInit()},SkinItem.prototype.onInit=function(){this.initView(),this.initEvent()},SkinItem.prototype.initView=function(){this.agencyskin=i.PanelResDic.Instance.getSingleTon(n.AgencySkin),this.c_state=this.getController("c_state")},SkinItem.prototype.initEvent=function(){this.on(Laya.Event.CLICK,this,this.btnclick)},SkinItem.prototype.btnclick=function(){if(this.pifuvo)switch(this.c_state.selectedIndex){case 0:break;case 1:this.agencyskin.GainPifu(this.pifuvo);break;case 2:o.GlobalTip.Instance.showWordTips("暂未开放");break;case 3:this.playvideocallback();break;case 4:this.agencyskin.GainPifu(this.pifuvo)}},SkinItem.prototype.createMovieClip=function(){var e=new s;e.load(this.SWFPath),e.x=(Laya.stage.width-this.MCWidth)/2,e.y=(Laya.stage.height-this.MCHeight)/2,Laya.stage.addChild(e)},SkinItem.prototype.playvideocallback=function(){var e=this;l.ttad.ShowVideo(function(t){t&&e.agencyskin.GainPifu(e.pifuvo)})},SkinItem.prototype.showData=function(e){if(this.pifuvo=e,this.pifuvo)if(this.load_icon.icon=r.AssetPath.getroleicon(this.pifuvo.roleCFG.icon),this.agencyskin.RoleData.CharacterID==this.pifuvo.roleCFG.id)this.c_state.selectedIndex=0;else if(1==this.pifuvo.state)this.c_state.selectedIndex=1;else switch(this.pifuvo.roleCFG.getState){case 1:this.c_state.selectedIndex=3,this.txt_need.text=this.pifuvo.hasnum+"/"+this.pifuvo.roleCFG.need;break;case 2:this.c_state.selectedIndex=4,this.txt_need.text=this.pifuvo.roleCFG.need.toString();break;case 3:this.c_state.selectedIndex=2}},SkinItem.prototype.preFixNumber=function(e,t){return("0000000000"+e).slice(-t)},SkinItem.prototype.evalBgColor=function(){var e=16777215*Math.random();this.getColorChannals(e)},SkinItem.prototype.getColorChannals=function(e){var t=[];return t.push(e>>16),t.push(e>>8&255),t.push(255&e),t},SkinItem.prototype.dispose=function(){this.off(Laya.Event.CLICK,this,this.btnclick),e.prototype.dispose.call(this)},SkinItem}(fairygui.GButton);a.SkinItem=c},{"../Agency/AgencySkin":6,"../Config/AssetPath":15,"../PrefabControl/PanelResDic":48,"../WXSDK/ttad":83,"../utils/GlobalTip":88}],93:[function(e,t,a){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=function(){function ViewAction(){this._text=null}return ViewAction.prototype.onStateEnter=function(){console.log("动画开始播放了"),this._text.text="动画状态:动画开始播放"},ViewAction.prototype.onStateUpdate=function(){console.log("动画状态更新了"),this._text.text="动画状态:动画更新中"},ViewAction.prototype.onStateExit=function(){console.log("动画退出了"),this._text.text="动画状态:动画开始退出"},ViewAction.prototype.addBox=function(){for(var e=0;e<8;e++)this.addVerticalBox(-.65,.165+.33*e*2,0),this.addVerticalBox(0,.165+.33*e*2,0),this.addVerticalBox(.65,.165+.33*e*2,0)},ViewAction.prototype.addVerticalBox=function(e,t,a){var n=this.scene.addChild(new Laya.MeshSprite3D(this.mesh1));n.meshRenderer.material=this.mat1,n.meshRenderer.castShadow=!0,n.meshRenderer.receiveShadow=!0,n.transform.position=new Laya.Vector3(e,t,a);var i=n.addComponent(Laya.Rigidbody3D);i.mass=10,i.friction=.4,i.restitution=.2;var o=new Laya.BoxColliderShape(.5,.33,2);i.colliderShape=o},ViewAction.ActionType_addscaleMinToMax="ActionType_addscaleMinToMax",ViewAction.ActionType_removescaleMaxToMin="ActionType_removescaleMaxToMin",ViewAction.ActionType_none="ActionType_none",ViewAction.ActionType_addmoveToMiddle="ActionType_addmoveToMiddle",ViewAction.ActionType_removemoveToRight="ActionType_removemoveToRight",ViewAction.ActionType_addmoveFromBottom="ActionType_addmoveFromBottom",ViewAction.ActionType_addmoveFromup="ActionType_addmoveFromup",ViewAction}();a.ViewAction=n},{}]},{},[44]);