/// <summary> /// 根据规则去显示3D的背景场景 /// </summary> void show3DScene() { TemporyData temp = Core.Data.temper; //展示3D场景 if (temp.currentBattleType == TemporyData.BattleType.BossBattle || temp.currentBattleType == TemporyData.BattleType.GPSWar) { main3DManager.ShowScreen(Core.Data.temper.CitySence); } else if (temp.currentBattleType == TemporyData.BattleType.FightWithFulisa) { main3DManager.ShowScreen(3); } else { int scence = Random.Range(1, 5); main3DManager.ShowScreen(scence); } }
// Use this for initialization void Start() { if (1 == Random.Range(0, 2)) { Swop = true; } else { Swop = false; } loader = new CRLuo_Main3D_DataLoad(); loader.load(); do { P1 = -1; P2 = -1; ScreenID = -1; Loading_Mode(); }while((P1 == -1 || P2 == -1 || ScreenID == -1) && !Try_Key); if (Swop) { int tempSwopID = P1; P1 = P2; P2 = tempSwopID; } GameObject main3D = Instantiate(go_Main3D, transform.localPosition, transform.localRotation) as GameObject; _Main3DManager = main3D.GetComponent <Main3DManager>(); _Main3DManager.showButtons = false; _Main3DManager.ShowScreen(ScreenID); CommandID = 0; if (loader.configs [ran].ActionList != null && loader.configs [ran].ActionList.Length != 0) { defaultActionList = loader.configs [ran].ActionList; } else { int rand = Random.Range(0, loader.DefaultActionList.Count); defaultActionList = loader.DefaultActionList[rand].ActionList; } ShowCommand(); ShowCommand(); }