// Token: 0x060012D7 RID: 4823 RVA: 0x0020DE64 File Offset: 0x0020C064 public void Recv_MSG_RESP_ARENA_BOARDDATA(MessagePacket MP) { ArenaManager.Instance.m_ArenaTargetHint.AllianceTagTag = MP.ReadString(3, -1); ArenaManager.Instance.m_ArenaTargetHint.Name = MP.ReadString(13, -1); ArenaManager.Instance.m_ArenaTargetHint.Place = (uint)((byte)MP.ReadULong(-1)); ArenaManager.Instance.m_ArenaTargetHint.HeroData = new ArenaTargetHeroDataType[5]; ArenaManager instance = ArenaManager.Instance; instance.m_ArenaTargetHint.Place = instance.m_ArenaTargetHint.Place + 1u; for (int i = 0; i < 5; i++) { ArenaManager.Instance.m_ArenaTargetHint.HeroData[i].ID = MP.ReadUShort(-1); ArenaManager.Instance.m_ArenaTargetHint.HeroData[i].Level = MP.ReadByte(-1); ArenaManager.Instance.m_ArenaTargetHint.HeroData[i].Rank = MP.ReadByte(-1); ArenaManager.Instance.m_ArenaTargetHint.HeroData[i].Star = MP.ReadByte(-1); ArenaManager.Instance.m_ArenaTargetHint.HeroData[i].Equip = MP.ReadByte(-1); MP.ReadInt(-1); } ArenaManager.Instance.m_ArenaTargetHint.Head = ArenaManager.Instance.m_ArenaTargetHint.HeroData[0].ID; Transform parent = this.hintTarget.transform.parent; this.hintTarget.transform.SetParent(this.hintCenter); Vector2 anchoredPosition = this.hintTarget.GetComponent <RectTransform>().anchoredPosition; this.hintTarget.transform.SetParent(parent); this.hintTarget.transform.SetSiblingIndex(11); float num = anchoredPosition.y + 410f; num = Mathf.Clamp(num, -190f, 150f); GUIManager.Instance.m_Arena_Hint.Show(this.hintTarget, -40f, num, 0); }
// Token: 0x06001099 RID: 4249 RVA: 0x001D7624 File Offset: 0x001D5824 public void RecvArena_Info(MessagePacket MP) { this.m_ArenaPlace = MP.ReadUInt(-1); Array.Clear(this.m_ArenaDefHero, 0, this.m_ArenaDefHero.Length); Array.Clear(this.m_ArenaTarget, 0, this.m_ArenaTarget.Length); for (int i = 0; i < 5; i++) { this.m_ArenaDefHero[i] = MP.ReadUShort(-1); } this.m_ArenaTodayChallenge = MP.ReadByte(-1); this.m_ArenaTodayResetChallenge = MP.ReadByte(-1); this.m_ArenaLastChallengeTime = MP.ReadLong(-1); this.m_ArenaCrystalPrize = MP.ReadUInt(-1); for (int j = 0; j < 3; j++) { this.m_ArenaTarget[j].Head = MP.ReadUShort(-1); this.m_ArenaTarget[j].Name = MP.ReadString(13, -1); this.m_ArenaTarget[j].AllianceTagTag = MP.ReadString(3, -1); this.m_ArenaTarget[j].Place = MP.ReadUInt(-1); if (this.m_ArenaTarget[j].HeroData == null) { this.m_ArenaTarget[j].HeroData = new ArenaTargetHeroDataType[5]; } for (int k = 0; k < 5; k++) { this.m_ArenaTarget[j].HeroData[k].ID = MP.ReadUShort(-1); this.m_ArenaTarget[j].HeroData[k].Level = MP.ReadByte(-1); this.m_ArenaTarget[j].HeroData[k].Rank = MP.ReadByte(-1); this.m_ArenaTarget[j].HeroData[k].Star = MP.ReadByte(-1); this.m_ArenaTarget[j].HeroData[k].Equip = MP.ReadByte(-1); } } this.m_ArenaNewReportNum = MP.ReadByte(-1); this.m_NowArenaTopicID[0] = MP.ReadByte(-1); this.m_NowArenaTopicID[1] = MP.ReadByte(-1); this.m_NowArenaTopicEndTime = MP.ReadLong(-1); this.m_NowTopicEffect[0].Effect = MP.ReadUShort(-1); this.m_NowTopicEffect[0].Value = MP.ReadUShort(-1); this.m_NowTopicEffect[1].Effect = MP.ReadUShort(-1); this.m_NowTopicEffect[1].Value = MP.ReadUShort(-1); this.m_NextArenaTopicID[0] = MP.ReadByte(-1); this.m_NextArenaTopicID[1] = MP.ReadByte(-1); this.m_NextArenaTopicBeginTime = MP.ReadLong(-1); this.m_NextTopicEffect[0].Effect = MP.ReadUShort(-1); this.m_NextTopicEffect[0].Value = MP.ReadUShort(-1); this.m_NextTopicEffect[1].Effect = MP.ReadUShort(-1); this.m_NextTopicEffect[1].Value = MP.ReadUShort(-1); this.m_ArenaHistoryPlace = MP.ReadUInt(-1); this.m_ArenaExtraChallenge = MP.ReadByte(-1); GUIManager.Instance.BuildingData.UpdateBuildState(5, 255); GUIManager.Instance.UpdateUI(EGUIWindow.UI_Arena, 6, 0); DataManager.MissionDataManager.CheckChanged(eMissionKind.Record, 28, this.GetHeroAstrologyNum()); if (this.m_ArenaHistoryPlace > 0u && this.m_ArenaHistoryPlace < 65535u) { DataManager.MissionDataManager.CheckChanged(eMissionKind.Record, 29, (ushort)(65535u - this.m_ArenaHistoryPlace)); } }
// Token: 0x06000114 RID: 276 RVA: 0x00012688 File Offset: 0x00010888 public void Recv_MSG_RESP_ALLIANCEWAR_COMBAT_REPORT(MessagePacket MP) { GUIManager.Instance.HideUILock(EUILock.AllianceWar_Fs); this.mReportRandSeed = MP.ReadUShort(-1); this.mReportRandGap = MP.ReadByte(-1); this.mReportResult = MP.ReadByte(-1); for (int i = 0; i < 2; i++) { this.m_CombatPlayerData[i].Name = MP.ReadString(13, -1); this.m_CombatPlayerData[i].KingdomID = MP.ReadUShort(-1); this.m_CombatPlayerData[i].StrongholdLevel = MP.ReadByte(-1); this.m_CombatPlayerData[i].Level = MP.ReadByte(-1); this.m_CombatPlayerData[i].Head = MP.ReadUShort(-1); this.m_CombatPlayerData[i].VIPLevel = MP.ReadByte(-1); this.m_CombatPlayerData[i].AllianceRank = MP.ReadByte(-1); for (int j = 0; j < 5; j++) { this.m_CombatPlayerData[i].HeroInfo[j].ID = MP.ReadUShort(-1); this.m_CombatPlayerData[i].HeroInfo[j].Rank = MP.ReadByte(-1); this.m_CombatPlayerData[i].HeroInfo[j].Star = MP.ReadByte(-1); } if (this.m_CombatPlayerData[i].HeroInfo[0].ID != 0) { this.m_CombatPlayerData[i].bMain = (this.m_CombatPlayerData[i].Head == this.m_CombatPlayerData[i].HeroInfo[0].ID); } else { this.m_CombatPlayerData[i].bMain = false; } this.m_CombatPlayerData[i].LosePower = MP.ReadULong(-1); for (int k = 0; k < 16; k++) { this.m_CombatPlayerData[i].SurviveTroop[k] = MP.ReadUInt(-1); } for (int l = 0; l < 16; l++) { this.m_CombatPlayerData[i].DeadTroop[l] = MP.ReadUInt(-1); } for (int m = 0; m < 4; m++) { this.m_CombatPlayerData[i].AttackAttr[m] = MP.ReadUInt(-1); } for (int n = 0; n < 4; n++) { this.m_CombatPlayerData[i].DefenceAttr[n] = MP.ReadUInt(-1); } for (int num = 0; num < 4; num++) { this.m_CombatPlayerData[i].HealthAttr[num] = MP.ReadUInt(-1); } this.m_CombatPlayerData[i].ArmyCoordIndex = MP.ReadByte(-1); this.m_CombatPlayerData[i].ArmyCoordIndex = (byte)Mathf.Clamp((int)this.m_CombatPlayerData[i].ArmyCoordIndex, 0, 5); } Door door = GUIManager.Instance.FindMenu(EGUIWindow.Door) as Door; if (door != null) { door.OpenMenu(EGUIWindow.UI_Alliance_FS, 0, 0, false); } }
// Token: 0x060010A3 RID: 4259 RVA: 0x001D8B5C File Offset: 0x001D6D5C public void RecvArena_Update_Single_target(MessagePacket MP) { byte b = MP.ReadByte(-1); b = (byte)Mathf.Clamp((int)b, 0, this.m_ArenaTarget.Length - 1); this.m_ArenaTarget[(int)b].Head = MP.ReadUShort(-1); this.m_ArenaTarget[(int)b].Name = MP.ReadString(13, -1); this.m_ArenaTarget[(int)b].AllianceTagTag = MP.ReadString(3, -1); this.m_ArenaTarget[(int)b].Place = MP.ReadUInt(-1); for (int i = 0; i < 5; i++) { this.m_ArenaTarget[(int)b].HeroData[i].ID = MP.ReadUShort(-1); this.m_ArenaTarget[(int)b].HeroData[i].Level = MP.ReadByte(-1); this.m_ArenaTarget[(int)b].HeroData[i].Rank = MP.ReadByte(-1); this.m_ArenaTarget[(int)b].HeroData[i].Star = MP.ReadByte(-1); this.m_ArenaTarget[(int)b].HeroData[i].Equip = MP.ReadByte(-1); } GUIManager.Instance.UpdateUI(EGUIWindow.UI_Arena, 8, (int)b); }
// Token: 0x06002153 RID: 8531 RVA: 0x003F6E14 File Offset: 0x003F5014 public static void RespSchedule(MessagePacket MP) { GUIManager.Instance.HideUILock(EUILock.AWS_Schedule); byte b = MP.ReadByte(-1); if (b == 0) { int num = (int)MP.ReadByte(-1); num = Mathf.Clamp(num, 0, 4); UI_AlliWarSchedule.Step = (UI_AlliWarSchedule.EAWSFightStep)num; Array.Clear(UI_AlliWarSchedule.AllianceData, 0, 16); Array.Clear(UI_AlliWarSchedule.FightData, 0, 15); for (int i = 0; i < 16; i++) { int num2 = UI_AlliWarSchedule.NodePos_S2C[i]; UI_AlliWarSchedule.AllianceData[num2].ID = MP.ReadUInt(-1); UI_AlliWarSchedule.AllianceData[num2].Emblem = MP.ReadUShort(-1); UI_AlliWarSchedule.AllianceData[num2].Tag = MP.ReadString(3, -1); } for (int j = 0; j < 15; j++) { int num3 = UI_AlliWarSchedule.LinePos_S2C[j]; UI_AlliWarSchedule.FightData[num3].Winner = MP.ReadByte(-1); UI_AlliWarSchedule.FightData[num3].Alliance1Index = UI_AlliWarSchedule.NodePosS2C(MP.ReadByte(-1)); UI_AlliWarSchedule.FightData[num3].Alliance2Index = UI_AlliWarSchedule.NodePosS2C(MP.ReadByte(-1)); UI_AlliWarSchedule.FightData[num3].Score1 = MP.ReadByte(-1); UI_AlliWarSchedule.FightData[num3].Score2 = MP.ReadByte(-1); if (j == 1) { byte b2 = UI_AlliWarSchedule.FightData[num3].Alliance1Index; UI_AlliWarSchedule.FightData[num3].Alliance1Index = UI_AlliWarSchedule.FightData[num3].Alliance2Index; UI_AlliWarSchedule.FightData[num3].Alliance2Index = b2; b2 = UI_AlliWarSchedule.FightData[num3].Score1; UI_AlliWarSchedule.FightData[num3].Score1 = UI_AlliWarSchedule.FightData[num3].Score2; UI_AlliWarSchedule.FightData[num3].Score2 = b2; } } if (GUIManager.Instance.FindMenu(EGUIWindow.UI_AlliWarSchedule)) { GUIManager.Instance.UpdateUI(EGUIWindow.UI_AlliWarSchedule, 0, 0); } else { Door door = GUIManager.Instance.FindMenu(EGUIWindow.Door) as Door; if (door != null) { door.OpenMenu(EGUIWindow.UI_AlliWarSchedule, 0, 0, false); } } } else if (b == 1 && DataManager.Instance.RoleAlliance.Id != 0u) { UI_AlliWarSchedule.Reconnect = true; } }
// Token: 0x0600109C RID: 4252 RVA: 0x001D7E68 File Offset: 0x001D6068 public void RecvArena_Refresh_Target(MessagePacket MP) { GUIManager.Instance.HideUILock(EUILock.Arena); byte b = MP.ReadByte(-1); if (MP.ReadByte(-1) == 0) { for (int i = 0; i < 3; i++) { this.m_ArenaTarget[i].Head = MP.ReadUShort(-1); this.m_ArenaTarget[i].Name = MP.ReadString(13, -1); this.m_ArenaTarget[i].AllianceTagTag = MP.ReadString(3, -1); this.m_ArenaTarget[i].Place = MP.ReadUInt(-1); for (int j = 0; j < 5; j++) { this.m_ArenaTarget[i].HeroData[j].ID = MP.ReadUShort(-1); this.m_ArenaTarget[i].HeroData[j].Level = MP.ReadByte(-1); this.m_ArenaTarget[i].HeroData[j].Rank = MP.ReadByte(-1); this.m_ArenaTarget[i].HeroData[j].Star = MP.ReadByte(-1); this.m_ArenaTarget[i].HeroData[j].Equip = MP.ReadByte(-1); } } GUIManager.Instance.UpdateUI(EGUIWindow.UI_Arena, 4, 0); if (b == 4) { GUIManager.Instance.UpdateUI(EGUIWindow.UI_BattleHeroSelect, 7, 0); if (GUIManager.Instance.m_Arena_Hint.m_RectTransform.gameObject.activeSelf) { for (int k = 0; k < 3; k++) { if (this.m_ArenaTargetHint.Name == this.m_ArenaTarget[k].Name) { this.m_ArenaTargetHint = this.m_ArenaTarget[k]; break; } } GUIManager.Instance.m_Arena_Hint.UpdateUI(); } } } }
// Token: 0x06001070 RID: 4208 RVA: 0x001D4FF0 File Offset: 0x001D31F0 public void RecvAmbush(MessagePacket MP) { byte b = MP.ReadByte(-1); if (b == 0) { byte b2 = MP.ReadByte(-1); if (b2 >= 8) { return; } this.DM.MarchEventData[(int)b2].Point.zoneID = MP.ReadUShort(-1); this.DM.MarchEventData[(int)b2].Point.pointID = MP.ReadByte(-1); this.DM.MarchEventTime[(int)b2].BeginTime = MP.ReadLong(-1); this.DM.MarchEventTime[(int)b2].RequireTime = MP.ReadUInt(-1); this.DM.MarchEventData[(int)b2].Type = EMarchEventType.EMET_CampMarching; this.DM.MarchEventData[(int)b2].bRallyHost = 1; this.DM.SetQueueBarData(EQueueBarIndex.MarchingBegin + (int)b2, true, this.DM.MarchEventTime[(int)b2].BeginTime, this.DM.MarchEventTime[(int)b2].RequireTime); this.DM.MarchEventData[(int)b2].PointKind = (POINT_KIND)MP.ReadByte(-1); this.DM.MarchEventData[(int)b2].DesPointLevel = MP.ReadByte(-1); this.DM.MarchEventData[(int)b2].DesPlayerName = MP.ReadString(13, -1); for (int i = 0; i < 5; i++) { this.DM.MarchEventData[(int)b2].HeroID[i] = MP.ReadUShort(-1); if ((int)this.DM.MarchEventData[(int)b2].HeroID[i] < this.DM.TempFightHeroID.Length) { this.DM.TempFightHeroID[(int)this.DM.MarchEventData[(int)b2].HeroID[i]] = 1; } } ushort num = MP.ReadUShort(-1); for (int j = 0; j < 16; j++) { if ((num >> j & 1) == 1) { this.DM.MarchEventData[(int)b2].TroopData[j / 4][j % 4] = MP.ReadUInt(-1); this.DM.RoleAttr.m_Soldier[j] -= this.DM.MarchEventData[(int)b2].TroopData[j / 4][j % 4]; this.DM.SoldierTotal -= (long)((ulong)this.DM.MarchEventData[(int)b2].TroopData[j / 4][j % 4]); } } this.DM.CancelShieldItemBuff(); this.DM.CheckTroolCount(); GameManager.OnRefresh(NetworkNews.Refresh_Hero, null); GUIManager.Instance.UpdateUI(EGUIWindow.UI_DevelopmentDetails, 2, 0); GUIManager.Instance.UpdateUI(EGUIWindow.UI_ArmyInfo, 0, 0); this.m_Door = this.GetDoor(); if (this.m_Door != null) { this.m_Door.m_GroundInfo.UpdateUI(0, 0); } this.DM.SetFightHeroData(); if (this.m_Door != null) { if (this.m_Door.m_eMapMode == EUIOriginMapMode.OriginMap) { this.m_Door.CloseMenu(false); } else { DataManager.msgBuffer[0] = 81; GameConstants.GetBytes((ushort)b2, DataManager.msgBuffer, 1); GameManager.notifyObservers(1, 0, DataManager.msgBuffer); } } GUIManager.Instance.AddHUDMessage(this.DM.mStringTable.GetStringByID(9740u), 29, true); DataManager.Instance.AttribVal.UpdateSoldierConsume(SoldierConsumeType.Inner, byte.MaxValue); DataManager.Instance.AttribVal.UpdateSoldierConsume(SoldierConsumeType.Outer, b2); } else { switch (b) { case 1: this.GM.OpenMessageBox(this.DM.mStringTable.GetStringByID(5715u), this.DM.mStringTable.GetStringByID(5716u), this.DM.mStringTable.GetStringByID(5717u), null, 0, 0, false, false, false, false, false); break; case 2: this.GM.OpenMessageBox(this.DM.mStringTable.GetStringByID(4826u), this.DM.mStringTable.GetStringByID(9725u), this.DM.mStringTable.GetStringByID(4828u), null, 0, 0, false, false, false, false, false); break; case 3: this.GM.OpenMessageBox(this.DM.mStringTable.GetStringByID(4829u), this.DM.mStringTable.GetStringByID(119u), null, null, 0, 0, false, false, false, false, false); break; case 5: this.GM.OpenMessageBox(this.DM.mStringTable.GetStringByID(4826u), this.DM.mStringTable.GetStringByID(9724u), this.DM.mStringTable.GetStringByID(4828u), null, 0, 0, false, false, false, false, false); this.m_Door = this.GetDoor(); if (this.m_Door != null) { this.m_Door.m_GroundInfo.Close(); } break; } } GUIManager.Instance.HideUILock(EUILock.Ambush); }
// Token: 0x06002583 RID: 9603 RVA: 0x0042BC58 File Offset: 0x00429E58 public void Enter(MessagePacket MP) { if (NetworkPeeper.Stage != LoginPhase.LP_Connecting) { this.LostInSpace = true; return; } AddressFamily addressFamily = AddressFamily.Unknown; CString cstring = StringManager.Instance.StaticString1024(); cstring.ClearString(); string text = MP.ReadString(16, MP.Offset + 4); GameConstants.GetHostName(cstring, text, "lm-proxy-"); IPAddress[] array = null; try { array = Dns.GetHostAddresses(cstring.ToString()); } catch (Exception ex) { Debug.Log("[Enter]:" + ex.Message); } if (array == null) { array = new IPAddress[1]; if (IPAddress.TryParse(text, out array[0])) { addressFamily = array[0].AddressFamily; } } else if (array.Length > 0 && array[0] != null) { addressFamily = array[0].AddressFamily; } cstring.ClearString(); if (addressFamily == AddressFamily.Unknown) { this.LostInSpace = true; return; } this.ConnectTime = 15f; NetworkPeeper.Sucket = new Socket(addressFamily, SocketType.Stream, ProtocolType.Tcp) { Blocking = false, SendTimeout = 0, ReceiveTimeout = 0 }; try { NetworkPeeper.Sucket.SetSocketOption(SocketOptionLevel.Tcp, SocketOptionName.Debug, true); NetworkPeeper.Sucket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.Linger, NetworkManager.LOL); } catch { } if (NetworkPeeper.Sucket.BeginConnect(array[0], MP.ReadInt(-1), new AsyncCallback(this.ConnectCallback), NetworkPeeper.Sucket).CompletedSynchronously) { this.ConnectCallback(null); } }
// Token: 0x0600109E RID: 4254 RVA: 0x001D80F0 File Offset: 0x001D62F0 public void RecvArena_Challenge(MessagePacket MP) { GUIManager.Instance.HideUILock(EUILock.Arena); byte b = MP.ReadByte(-1); if (b == 0) { this.BattleResult = MP.ReadByte(-1); this.m_ArenaPlace = MP.ReadUInt(-1); this.m_ArenaTodayChallenge = MP.ReadByte(-1); this.m_ArenaLastChallengeTime = MP.ReadLong(-1); DataManager dataManager = DataManager.Instance; dataManager.KingOldLv = dataManager.RoleAttr.Level; dataManager.KingOldExp = dataManager.RoleAttr.Exp; DataManager.StageDataController.UpdateRoleAttrLevel(MP.ReadByte(-1)); DataManager.StageDataController.UpdateRoleAttrExp(MP.ReadUInt(-1)); MP.ReadUInt(-1); for (int i = 0; i < 5; i++) { ushort num = MP.ReadUShort(-1); if (num != 0 && dataManager.curHeroData.ContainsKey((uint)num)) { CurHeroData curHeroData = dataManager.curHeroData[(uint)num]; dataManager.heroLv[i] = curHeroData.Level; dataManager.heroExp[i] = curHeroData.Exp; dataManager.UpdateHeroAttr(num, MP); } else { MP.ReadByte(-1); MP.ReadUInt(-1); MP.ReadUInt(-1); } } ArenaReportDataType arenaReportDataType = default(ArenaReportDataType); arenaReportDataType.MyHeroData = new ArenaHeroDataType[5]; arenaReportDataType.EnemyHeroData = new ArenaHeroDataType[5]; arenaReportDataType.TopicID = new byte[2]; arenaReportDataType.TopicEffect = new ArenaTopicEffectDataType[2]; arenaReportDataType.SimulatorVersion = MP.ReadUInt(-1); arenaReportDataType.SimulatorPatchNo = MP.ReadUInt(-1); arenaReportDataType.Flag = MP.ReadByte(-1); arenaReportDataType.TopicID[0] = MP.ReadByte(-1); arenaReportDataType.TopicID[1] = MP.ReadByte(-1); arenaReportDataType.TopicEffect[0].Effect = MP.ReadUShort(-1); arenaReportDataType.TopicEffect[0].Value = MP.ReadUShort(-1); arenaReportDataType.TopicEffect[1].Effect = MP.ReadUShort(-1); arenaReportDataType.TopicEffect[1].Value = MP.ReadUShort(-1); arenaReportDataType.ChangePlace = MP.ReadUInt(-1); for (int j = 0; j < 5; j++) { arenaReportDataType.MyHeroData[j].SkillLV = new byte[4]; arenaReportDataType.MyHeroData[j].ID = MP.ReadUShort(-1); arenaReportDataType.MyHeroData[j].Level = MP.ReadByte(-1); arenaReportDataType.MyHeroData[j].Rank = MP.ReadByte(-1); arenaReportDataType.MyHeroData[j].Star = MP.ReadByte(-1); arenaReportDataType.MyHeroData[j].Equip = MP.ReadByte(-1); for (int k = 0; k < 4; k++) { arenaReportDataType.MyHeroData[j].SkillLV[k] = MP.ReadByte(-1); } } arenaReportDataType.EnemyHead = MP.ReadUShort(-1); arenaReportDataType.EnemyName = MP.ReadString(13, -1); arenaReportDataType.EnemyAllianceTag = MP.ReadString(3, -1); for (int l = 0; l < 5; l++) { arenaReportDataType.EnemyHeroData[l].SkillLV = new byte[4]; arenaReportDataType.EnemyHeroData[l].ID = MP.ReadUShort(-1); arenaReportDataType.EnemyHeroData[l].Level = MP.ReadByte(-1); arenaReportDataType.EnemyHeroData[l].Rank = MP.ReadByte(-1); arenaReportDataType.EnemyHeroData[l].Star = MP.ReadByte(-1); arenaReportDataType.EnemyHeroData[l].Equip = MP.ReadByte(-1); for (int m = 0; m < 4; m++) { arenaReportDataType.EnemyHeroData[l].SkillLV[m] = MP.ReadByte(-1); } } arenaReportDataType.RandomSeed = MP.ReadUShort(-1); arenaReportDataType.RandomGap = MP.ReadByte(-1); arenaReportDataType.PrimarySide = MP.ReadByte(-1); arenaReportDataType.Time = MP.ReadLong(-1); if (!this.bArenaOpenGet) { if (this.m_ArenaReportData.Count == 20) { this.m_ArenaReportData.RemoveAt(0); } bool flag = false; if (this.RepoetUnReadCount > 0 && this.RepoetUnRead[0] == 0) { flag = true; this.RepoetUnReadCount -= 1; } if (flag) { int num2 = 0; while (num2 < (int)this.RepoetUnReadCount && this.RepoetUnReadCount < 19) { byte[] repoetUnRead = this.RepoetUnRead; int num3 = num2; byte[] repoetUnRead2 = this.RepoetUnRead; int num4 = num2 + 1; repoetUnRead[num3] = (repoetUnRead2[num4] -= 1); num2++; } } else { int num5 = 0; while (num5 < (int)this.RepoetUnReadCount && num5 < this.RepoetUnRead.Length) { byte[] repoetUnRead3 = this.RepoetUnRead; int num6 = num5; byte[] repoetUnRead4 = this.RepoetUnRead; int num7 = num5; repoetUnRead3[num6] = (repoetUnRead4[num7] -= 1); num5++; } } this.m_ArenaReportData.Add(arenaReportDataType); } this.m_ArenaHistoryPlace = MP.ReadUInt(-1); GUIManager.Instance.BuildingData.UpdateBuildState(5, 255); GUIManager.Instance.UpdateUI(EGUIWindow.UI_Arena, 2, 0); GUIManager.Instance.UpdateUI(EGUIWindow.UI_TreasureBox, 5, 0); if (this.m_ArenaHistoryPlace > 0u && this.m_ArenaHistoryPlace < 65535u) { DataManager.MissionDataManager.CheckChanged(eMissionKind.Record, 29, (ushort)(65535u - this.m_ArenaHistoryPlace)); } if ((arenaReportDataType.Flag & 2) != 0 && GUIManager.Instance.FindMenu(EGUIWindow.UI_BattleHeroSelect) != null) { if (WarManager.CheckVersion(arenaReportDataType.SimulatorVersion, arenaReportDataType.SimulatorPatchNo, true)) { this.ArenaPlayingData = arenaReportDataType; BattleController.BattleMode = EBattleMode.PVP; GUIManager.Instance.bClearWindowStack = false; if (GUIManager.Instance.m_WindowStack.Count > 0) { GUIManager.Instance.m_WindowStack.RemoveAt(GUIManager.Instance.m_WindowStack.Count - 1); } GUIManager.Instance.UpdateUI(EGUIWindow.UI_BattleHeroSelect, 0, 0); DataManager.Instance.SetArenaHeroBattleDataSave(); } else { GUIManager.Instance.UpdateUI(EGUIWindow.UI_BattleHeroSelect, 6, 0); } } FBAdvanceManager.Instance.TriggerFbUniqueEvent(EFBEvent.FIRST_COLOSSEUM_BATTLE); } else { if (b == 6) { GUIManager.Instance.AddHUDMessage(DataManager.Instance.mStringTable.GetStringByID(9157u), 255, true); } GUIManager.Instance.UpdateUI(EGUIWindow.UI_BattleHeroSelect, 6, 0); } }
// Token: 0x0600109B RID: 4251 RVA: 0x001D7A18 File Offset: 0x001D5C18 public void RecvArena_Report(MessagePacket MP) { byte b = MP.ReadByte(-1); GUIManager.Instance.HideUILock(EUILock.Arena); byte b2 = MP.ReadByte(-1); ArenaReportDataType arenaReportDataType = default(ArenaReportDataType); int index = 0; int num = 0; while (num < (int)b2 && num < 10) { if (!this.bArenaOpenGet) { if (b == 0 || b == 2) { index = (int)this.RepoetUnRead[num + 10]; } else if (b == 3 || b == 1) { index = (int)this.RepoetUnRead[num]; } arenaReportDataType = this.m_ArenaReportData[index]; } arenaReportDataType.MyHeroData = new ArenaHeroDataType[5]; arenaReportDataType.EnemyHeroData = new ArenaHeroDataType[5]; arenaReportDataType.TopicID = new byte[2]; arenaReportDataType.TopicEffect = new ArenaTopicEffectDataType[2]; arenaReportDataType.SimulatorVersion = MP.ReadUInt(-1); arenaReportDataType.SimulatorPatchNo = MP.ReadUInt(-1); arenaReportDataType.Flag = MP.ReadByte(-1); arenaReportDataType.TopicID[0] = MP.ReadByte(-1); arenaReportDataType.TopicID[1] = MP.ReadByte(-1); arenaReportDataType.TopicEffect[0].Effect = MP.ReadUShort(-1); arenaReportDataType.TopicEffect[0].Value = MP.ReadUShort(-1); arenaReportDataType.TopicEffect[1].Effect = MP.ReadUShort(-1); arenaReportDataType.TopicEffect[1].Value = MP.ReadUShort(-1); arenaReportDataType.ChangePlace = MP.ReadUInt(-1); for (int i = 0; i < 5; i++) { arenaReportDataType.MyHeroData[i].SkillLV = new byte[4]; arenaReportDataType.MyHeroData[i].ID = MP.ReadUShort(-1); arenaReportDataType.MyHeroData[i].Level = MP.ReadByte(-1); arenaReportDataType.MyHeroData[i].Rank = MP.ReadByte(-1); arenaReportDataType.MyHeroData[i].Star = MP.ReadByte(-1); arenaReportDataType.MyHeroData[i].Equip = MP.ReadByte(-1); for (int j = 0; j < 4; j++) { arenaReportDataType.MyHeroData[i].SkillLV[j] = MP.ReadByte(-1); } } arenaReportDataType.EnemyHead = MP.ReadUShort(-1); arenaReportDataType.EnemyName = MP.ReadString(13, -1); arenaReportDataType.EnemyAllianceTag = MP.ReadString(3, -1); for (int k = 0; k < 5; k++) { arenaReportDataType.EnemyHeroData[k].SkillLV = new byte[4]; arenaReportDataType.EnemyHeroData[k].ID = MP.ReadUShort(-1); arenaReportDataType.EnemyHeroData[k].Level = MP.ReadByte(-1); arenaReportDataType.EnemyHeroData[k].Rank = MP.ReadByte(-1); arenaReportDataType.EnemyHeroData[k].Star = MP.ReadByte(-1); arenaReportDataType.EnemyHeroData[k].Equip = MP.ReadByte(-1); for (int l = 0; l < 4; l++) { arenaReportDataType.EnemyHeroData[k].SkillLV[l] = MP.ReadByte(-1); } } arenaReportDataType.RandomSeed = MP.ReadUShort(-1); arenaReportDataType.RandomGap = MP.ReadByte(-1); arenaReportDataType.PrimarySide = MP.ReadByte(-1); arenaReportDataType.Time = MP.ReadLong(-1); if (!this.bArenaOpenGet) { this.m_ArenaReportData[index] = arenaReportDataType; } else { if (this.m_ArenaReportData.Count == 20) { this.m_ArenaReportData.RemoveAt(0); } this.m_ArenaReportData.Add(arenaReportDataType); } num++; } if (b == 2 || b == 3) { if (this.bArenaOpenGet) { this.bArenaOpenGet = false; } this.m_ArenaNewReportNum = 0; GUIManager.Instance.UpdateUI(EGUIWindow.UI_Arena_Replay, 1, 0); GUIManager.Instance.BuildingData.UpdateBuildState(5, 255); } }