void CANVANS_BUILDING_INFO_RESP(int nErrorCode) { if (nErrorCode == 0) { //加载画布和建筑 RoomMap.CreateCanvansArea(); BattleEnvironmentM.BuildScene(); } }
public override void BuildUI() { Life.Environment = LifeEnvironment.Combat; CombatScheduler.SetCSState(CSState.Ready); if (BattleEnvironmentM.GetBattleEnvironmentMode() == BattleEnvironmentMode.CombatPVE) { if (StageDC.GetPveMode() == PVEMode.Attack) { WndManager.GetDialog <SelectSoldierwnd>(); BattleEnvironmentM.BuildScene(); } else { BattleEnvironmentM.BuildScene(); WndManager.GetDialog <CombatWnd>(); CombatInfoWnd wnd = WndManager.GetDialog <CombatInfoWnd>(); if (wnd != null) { wnd.SetWndMode(CombatInfoMode.combat); } if (CmCarbon.GetGodSkill(StageDC.GetPveMode() == PVEMode.Attack) != null) { //船长技能设置 GodSkillWnd gsw = WndManager.GetDialog <GodSkillWnd>(); if (gsw != null) { gsw.SetCurMana(CmCarbon.GetGodSkillMana(true)); gsw.SetRequireMana(CmCarbon.GetGodSkill(true).GetRequireMana()); } } // } } else { WndManager.GetDialog <CombatWnd>(); WndManager.GetDialog <CombatCountDownWnd>(); CombatInfoWnd wnd = WndManager.GetDialog <CombatInfoWnd>(); if (wnd != null) { wnd.SetWndMode(CombatInfoMode.view); } BattleEnvironmentM.BuildScene(); } BattleEnvironmentM.AddFireSoldierCompent(); Screen.sleepTimeout = SleepTimeout.NeverSleep;//prevent phone from going to sleep m_oldUserInfo.Level = UserDC.GetLevel(); m_oldUserInfo.Physical = UserDC.GetPhysical(); }
/// <summary> /// 1003 金银岛掠夺 /// </summary> /// <param name="Info"></param> void CanRob(int nErrorCode) { if (nErrorCode == 0) { CmCarbon.ReadyCombat(); BattleEnvironmentM.BuildScene(); JoinCombat(); } else { WndManager.GetDialog <TreasureCanNotRobWnd>(); } DataCenter.AntiRegisterHooks((int)gate.Command.CMD.CMD_1004, CanRob); }
void DoFinish() { //U3DUtil.DestroyAllChild(BattleEnvironmentM.GetLifeMBornNode(true).gameObject,false); RoomMap.CreateCanvansArea(); ShipPlan Plan = ShipPlanDC.GetCurShipPlan(); Plan.ReCalcShipBuildInfoXY(XYmode.Save2Edit); BattleEnvironmentM.SetBattleEnvironmentMode(BattleEnvironmentMode.Edit); BattleEnvironmentM.BuildScene(); WndManager.DestoryDialog <ShipShowWnd>(); WndManager.DestoryDialog <FangAnMenuWnd>(); GenerateShip.CreateMiddleBeam(); WndManager.GetDialog <ShipCanvasWnd>().ShowDialog(); MainCameraM.s_Instance.EnableOthOn(true); }