public void ClickNextBtn() { audioSvc.PlayUIAudio(Constants.UIClickBtn); index += 1; if (index == dialogArr.Length) { //对话完成 发送任务完成的服务器消息 SetWndState(false); PlayerData.GuideID += 1; PlayerData.Coin += curtTaskData.coin; ComTools.CalcExp(curtTaskData.exp); GameRoot.AddTips(Constants.Color("任务奖励 金币+" + curtTaskData.coin + "经验" + curtTaskData.exp, TxtColor.Blue)); switch (curtTaskData.actID) { case 0: break; case 1: MainCitySys.Instance.OpenFubenWnd(); break; case 2: MainCitySys.Instance.OpenStrongWnd(); break; case 3: MainCitySys.Instance.OpenBuyWnd(0); break; case 4: MainCitySys.Instance.OpenBuyWnd(1); break; case 5: MainCitySys.Instance.OpenChatWnd(); break; default: break; } NetUpdatPlayerData net = new NetUpdatPlayerData(); } else { SetTalk(); } }
public void ClickFuben(int FubenID) { audioSvc.PlayUIAudio(Constants.UIClickBtn); //检查体力是否足够 if (PlayerData.Power >= resSvc.GetMapCfgData(FubenID).power) { GameRoot.AddTips("进入副本!"); PlayerData.Power -= resSvc.GetMapCfgData(FubenID).power; NetUpdatPlayerData netUpdatPlayerData = new NetUpdatPlayerData(); BattleSys.Instance.StartBattle(PlayerData.Fuben); } else { GameRoot.AddTips("体力不足!无法进入副本"); } }
public void GetMoney() { PlayerData.Coin += 100; PlayerData.Crystal += 10; NetUpdatPlayerData netUpdatPlayerData = new NetUpdatPlayerData(); }