| | |
| | | { |
| | | //mobile.secondworld.net.cn:53080\S9006\20251202\3042602\5b11338f-cf2c-11f0-a0a0-000c29b22418.tfr |
| | | var serverID = UIHelper.GetServerIDByAccount(PlayerDatas.Instance.baseData.AccID); |
| | | |
| | | |
| | | var url = ServerListCenter.Instance.GetServerUrl(serverID); |
| | | string assetVersionUrl = string.Empty; |
| | | |
| | | |
| | | if (string.IsNullOrEmpty(date)) |
| | | { |
| | | //公共战报 路径: C:\TurnFightReport\S服务器编号\功能地图ID\战报GUID |
| | |
| | | public string BattleDetailBattleName = string.Empty; |
| | | public string BattleDetailMyName = string.Empty; |
| | | public string BattleDetailEnemyName = string.Empty; |
| | | public bool isMyStartBattleDetail = false; // 是否是我方发起的战斗 |
| | | |
| | | // isMyStart 是否是我方发起的战斗 |
| | | public void OpenBattleDetailWin(string battleName, bool isMyStart = true) |
| | | public void OpenBattleDetailWin(string battleName) |
| | | { |
| | | if (UIManager.Instance.IsOpened<BattleDetailWin>()) |
| | | return; |
| | |
| | | return; |
| | | |
| | | BattleDetailBattleName = battleName; |
| | | this.isMyStartBattleDetail = isMyStart; |
| | | UIManager.Instance.OpenWindow<BattleDetailWin>(); |
| | | } |
| | | |
| | |
| | | return null; |
| | | } |
| | | |
| | | public List<BattleDetailHeroInfo> GetHeroInfo(BattleDetailMsg msg, bool isMyStart, string battleName, bool isWin) |
| | | // 左蓝右红 |
| | | // 目前玩家主动发起的阵容一定是1,对方是 2, 如果是那种系统自动打的,一般1-左,2-右 |
| | | public string GetFaction(bool isBlue) |
| | | { |
| | | return isBlue ? "1" : "2"; |
| | | } |
| | | |
| | | public List<BattleDetailHeroInfo> GetHeroInfoByFaction(BattleDetailMsg msg, string faction) |
| | | { |
| | | if (msg == null || msg.statInfo.IsNullOrEmpty()) |
| | | return null; |
| | | |
| | | int winFaction = msg.winFaction; // 获胜阵营 |
| | | Dictionary<string, Dictionary<string, BattleDetailHeroInfo>> lineupInfo = new Dictionary<string, Dictionary<string, BattleDetailHeroInfo>>(); |
| | | string statInfoKey = string.Empty; |
| | | |
| | | if (isMyStart) |
| | | { |
| | | // 天子战场玩家不会输 |
| | | if (battleName == BattleConst.TianziBillboradBattleField) |
| | | { |
| | | statInfoKey = isWin ? msg.statInfo.Keys.FirstOrDefault(key => key != winFaction.ToString()) : winFaction.ToString(); |
| | | } |
| | | else |
| | | { |
| | | statInfoKey = isWin ? winFaction.ToString() : msg.statInfo.Keys.FirstOrDefault(key => key != winFaction.ToString()); |
| | | } |
| | | } |
| | | |
| | | if (!msg.statInfo.TryGetValue(statInfoKey, out lineupInfo) || lineupInfo.IsNullOrEmpty()) |
| | | if (!msg.statInfo.TryGetValue(faction, out lineupInfo) || lineupInfo.IsNullOrEmpty()) |
| | | return null; |
| | | var lineupInfoKeyList = lineupInfo.Keys.ToList(); |
| | | if (lineupInfoKeyList.IsNullOrEmpty()) |
| | |
| | | } |
| | | return res; |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | } |