public void onCompleteReceivePlaySigong() { P_Sigong p = GameManager.me.uiManager.popupInstantDungeon.selectSigongData; if (p.roundId.StartsWith("PVP")) { DebugManager.instance.pvpPlayerData = TestModeData.getTestModePlayerData(selectSigongData.roundId.Substring(4), false, "AI_PVP6"); DebugManager.instance.pvpPlayerData2 = null; UIPlay.pvpleagueGrade = 6; UIPlay.pvpImageUrl = DebugManager.instance.pvpPlayerData.id; UIPlay.playerImageUrl = PandoraManager.instance.localUser.image_url; GameManager.me.stageManager.setNowRound(GameManager.info.roundData["PVP"], GameType.Mode.Sigong); } else { GameManager.me.stageManager.setNowRound(GameManager.info.roundData[GameManager.me.uiManager.popupInstantDungeon.selectSigongData.roundId], GameType.Mode.Sigong); } GameManager.me.stageManager.sigongData = p; hide(); GameManager.me.uiManager.showLoading(); GamePlayerData gpd = null; if (string.IsNullOrEmpty(p.forcedDeck) == false) { if (p.forcedDeck == "HERO_SELECT") { gpd = selectHeroData; } else { gpd = TestModeData.getTestModePlayerData(p.forcedDeck, true, DebugManager.instance.ai, p.handicap); } } if (gpd == null) { if (string.IsNullOrEmpty(p.handicap) == false) { string heroId = GameDataManager.instance.selectHeroId; gpd = new GamePlayerData(heroId); P_Hero heroData = GameDataManager.instance.serverHeroData[GameDataManager.instance.selectHeroId]; string[] u = new string[5]; string[] s = new string[3]; if (p.handicap == WSDefine.HANDICAP_TYPE_UNIT || p.handicap == WSDefine.HANDICAP_TYPE_BOTH) { u[0] = string.Empty; u[1] = string.Empty; u[2] = string.Empty; u[3] = string.Empty; u[4] = string.Empty; } else { u = GameDataManager.instance.getSelectUnitRunes(null); } if (p.handicap == WSDefine.HANDICAP_TYPE_SKILL || p.handicap == WSDefine.HANDICAP_TYPE_BOTH) { s[0] = string.Empty; s[1] = string.Empty; s[2] = string.Empty; } else { s = GameDataManager.instance.getSelectSkillRunes(null); } DebugManager.instance.setPlayerData(gpd, true, heroData.name, heroData.selEqts[HeroParts.HEAD], heroData.selEqts[HeroParts.BODY], heroData.selEqts[HeroParts.WEAPON], heroData.selEqts[HeroParts.VEHICLE], u, s); } } GameManager.me.startGame(0.5f, gpd); }
void onClickRecommand(GameObject go) { string checkId = _id; if (_isSigong) { checkId = GameManager.info.testSigong[_id].roundId; if (checkId.StartsWith("PVP")) { checkId = "PVP"; } } if (GameManager.info.roundData.ContainsKey(checkId)) { if (GameManager.info.testModeData.ContainsKey(checkId)) { bool isPVPMode = true; DebugManager.useTestRound = true; if (checkId.ToLower().Contains("pvp") == false) { GameManager.me.stageManager.setNowRound(GameManager.info.roundData[checkId], GameType.Mode.Epic); isPVPMode = false; GameManager.me.uiManager.showLoading(); } else { GameManager.me.stageManager.setNowRound(GameManager.info.roundData[checkId], GameType.Mode.Championship); } if (checkId == "INTRO") { StartCoroutine(GameManager.me.startOpening()); } else { TestModeData tmd = GameManager.info.testModeData[checkId]; GamePlayerData testModeData = new GamePlayerData(tmd.hero); string[] u = new string[5]; u[0] = tmd.u1; u[1] = tmd.u2; u[2] = tmd.u3; u[3] = tmd.u4; u[4] = tmd.u5; string[] s = new string[3]; s[0] = tmd.s1; s[1] = tmd.s2; s[2] = tmd.s3; if (isPVPMode) { if (setMyInfo) { setMyInfo = false; lbId.text = _id + " : PVP 설정"; DebugManager.instance.setPlayerData(testModeData, true, tmd.hero, tmd.head, tmd.body, tmd.weapon, tmd.vehicle, u, s, DebugManager.instance.pvpAi); setTestModeData = testModeData; } else { GameManager.me.uiManager.showLoading(); DebugManager.instance.pvpPlayerData = new GamePlayerData(tmd.hero); DebugManager.instance.setPlayerData(DebugManager.instance.pvpPlayerData, true, tmd.hero, tmd.head, tmd.body, tmd.weapon, tmd.vehicle, u, s, DebugManager.instance.ai); GameManager.me.startGame(1, setTestModeData); } } else { GameManager.me.uiManager.showLoading(); DebugManager.instance.setPlayerData(testModeData, true, tmd.hero, tmd.head, tmd.body, tmd.weapon, tmd.vehicle, u, s, DebugManager.instance.pvpAi); GameManager.me.startGame(1, testModeData); } } } else { UISystemPopup.open(UISystemPopup.PopupType.Default, "추천덱이 없습니다."); } } }