private void OnMsgGuildWarReqRevive(MemoryStream stream) { MS2C_GuildWarReqRevive mS2C_GuildWarReqRevive = Serializer.NonGeneric.Deserialize(typeof(MS2C_GuildWarReqRevive), stream) as MS2C_GuildWarReqRevive; if (mS2C_GuildWarReqRevive.Result != EGuildResult.EGR_Success) { GameUIManager.mInstance.ShowMessageTip("EGR", (int)mS2C_GuildWarReqRevive.Result); return; } GameUIManager.mInstance.ShowMessageTipByKey("guildCraft67", 0f, 0f); if (this.LocalClientMember == null) { this.LocalClientMember = new GuildWarClientTeamMember(); } if (this.LocalClientMember != null) { this.LocalClientMember.Member = mS2C_GuildWarReqRevive.Player; this.LocalClientMember.Data = Tools.LocalPlayerToRemote(); if (this.LocalMemberUpDateEvent != null) { this.LocalMemberUpDateEvent(); } } }
public GuildCraftKillLogData(GuildWarClientTeamMember tData, int rNum, bool isMvp) { this.mMemberData = tData; this.mRankNum = rNum; this.IsMVP = isMvp; }
private void OnMsgGuildWarRecoverHP(MemoryStream stream) { MS2C_GuildWarRecoverHP mS2C_GuildWarRecoverHP = Serializer.NonGeneric.Deserialize(typeof(MS2C_GuildWarRecoverHP), stream) as MS2C_GuildWarRecoverHP; if (mS2C_GuildWarRecoverHP.Result != EGuildResult.EGR_Success) { GameUIManager.mInstance.ShowMessageTip("EGR", (int)mS2C_GuildWarRecoverHP.Result); return; } if (this.LocalClientMember == null) { this.LocalClientMember = new GuildWarClientTeamMember(); } if (this.LocalClientMember != null) { this.LocalClientMember.Member = mS2C_GuildWarRecoverHP.Player; this.LocalClientMember.Data = Tools.LocalPlayerToRemote(); if (this.LocalMemberUpDateEvent != null) { this.LocalMemberUpDateEvent(); } if (this.GuildWarRecoverHpEvent != null) { this.GuildWarRecoverHpEvent(); } } }
private void OnMsgGuildWarQuitHold(MemoryStream stream) { MS2C_GuildWarQuitHold mS2C_GuildWarQuitHold = Serializer.NonGeneric.Deserialize(typeof(MS2C_GuildWarQuitHold), stream) as MS2C_GuildWarQuitHold; if (mS2C_GuildWarQuitHold.Result != EGuildResult.EGR_Success) { GameUIManager.mInstance.ShowMessageTip("EGR", (int)mS2C_GuildWarQuitHold.Result); return; } this.LocalClientMember = new GuildWarClientTeamMember(); if (this.LocalClientMember != null) { this.LocalClientMember.Member = mS2C_GuildWarQuitHold.Player; this.LocalClientMember.Data = Tools.LocalPlayerToRemote(); } if (0 <= mS2C_GuildWarQuitHold.SlotIndex - 1 && mS2C_GuildWarQuitHold.SlotIndex - 1 < this.StrongHoldMembers.Count && this.StrongHoldMembers[mS2C_GuildWarQuitHold.SlotIndex - 1] != null) { this.StrongHoldMembers[mS2C_GuildWarQuitHold.SlotIndex - 1].Member = null; } if (mS2C_GuildWarQuitHold.Kick) { GameUIManager.mInstance.ShowMessageTipByKey("guildCraft74", 0f, 0f); } if (this.LocalMemberUpDateEvent != null) { this.LocalMemberUpDateEvent(); } }
public void Clear() { this.Guild = null; this.Members = null; this.GuildList = null; this.GuildListForSearch = null; this.GuildEventList = null; this.GuildRankDataList = null; this.mGWPlayerData = null; this.mGWKillRankData = null; this.StrongHold = null; this.mWarStateInfo = null; this.LocalClientMember = null; this.guildBossData.Clear(); this.StrongHoldMembers.Clear(); this.BattleRecords.Clear(); this.BattleSupportInfo.Clear(); this.mInteractionMsgs.Clear(); this.mSignRecords.Clear(); if (Globals.Instance != null && Globals.Instance.Player != null) { Globals.Instance.Player.ShowChatGuildNewMark = false; Globals.Instance.Player.GuildMsgs.Clear(); } }
private void ShowMemberIconInSlot(GuildWarClientTeamMember clientMember) { if (clientMember != null) { this.mState0.SetActive(true); this.mState1.SetActive(false); this.mRankIcon.gameObject.SetActive(true); this.mLvName.gameObject.SetActive(true); this.mBattleNum.gameObject.SetActive(true); this.mRankIcon.spriteName = Tools.GetPlayerIcon(clientMember.Data.FashionID); this.mRankIconFrame.spriteName = Tools.GetItemQualityIcon(LocalPlayer.GetQuality(clientMember.Data.ConstellationLevel)); this.mRankHp.value = Mathf.Clamp01((float)clientMember.Member.HealthPct / 10000f); int i; for (i = 0; i < clientMember.Data.PetInfoID.Count; i++) { this.mPets[i].Refresh(clientMember.Data.PetInfoID[i], (float)clientMember.Member.HealthPct); } while (i < 3) { this.mPets[i].Refresh(0, 0f); i++; } this.mLvName.text = this.mSb.Remove(0, this.mSb.Length).Append("Lv").Append(clientMember.Data.Level).Append(" ").Append(clientMember.Data.Name).ToString(); this.mBattleNum.text = this.mSb.Remove(0, this.mSb.Length).Append(Singleton<StringManager>.Instance.GetString("BillboardFighting")).Append(":").Append(clientMember.Data.CombatValue).ToString(); } }
private int SortMembers(GuildWarClientTeamMember aM, GuildWarClientTeamMember bM) { if (aM == null || bM == null || aM.Member == null || bM.Member == null) { return 0; } if (aM.Member.Score > bM.Member.Score) { return -1; } if (aM.Member.Score < bM.Member.Score) { return 1; } if (aM.Member.KillNum > bM.Member.KillNum) { return -1; } if (aM.Member.KillNum < bM.Member.KillNum) { return 1; } if (aM.Member.KillerTimestamp < bM.Member.KillerTimestamp) { return -1; } if (aM.Member.KillerTimestamp > bM.Member.KillerTimestamp) { return 1; } return 0; }