void OnClickSendCreateLegion(string createName, int iconID) { if (LegionEvent.SendCreateLegionMsg != null) { LegionEvent.SendCreateLegionMsg(createName, iconID); } }
//踢出军团 void OnClickKickOut(long uid) { if (LegionEvent.SendMemberKickOut != null) { LegionEvent.SendMemberKickOut(uid); } }
private void OnClickSaveLimitBtn() { if (LegionEvent.SendSaveLimit != null) { LegionEvent.SendSaveLimit(int.Parse(limitLevelLabel.text), IsOpenApprove); } }
private void OnClick(GameObject go) { if (LegionEvent.OnClickMember != null) { LegionEvent.OnClickMember(uid); } }
void OnClickSendMail() { FusionAudio.PostEvent("UI/General/ButtonClick"); if (InputTitleLabel.text.Equals(noInputTitleStr) || InputContentLabel.text.Equals(noInputContentStr)) { MessageTemplateManager.ShowMessage(eMessageUIType.FloatingText, EB.Localizer.GetString("ID_codefont_in_LegionMailView_2531")); } else if (lessMailTimes <= 0) { MessageTemplateManager.ShowMessage(eMessageUIType.FloatingText, EB.Localizer.GetString("ID_codefont_in_LegionMailView_2680")); } else { if (LegionEvent.SendLegionMail != null) { LegionEvent.SendLegionMail(InputTitleLabel.text, InputContentLabel.text); } if (InputTitleLabel != null) { InputTitleLabel.text = noInputTitleStr; InputTitleLabel.GetComponent <UIInput>().value = string.Empty; InputContentLabel.text = noInputContentStr; InputContentLabel.GetComponent <UIInput>().value = string.Empty; } mDMono.gameObject.SetActive(false); } }
//降职 void OnClickDemote(long uid) { if (LegionEvent.SendMemberDemote != null) { LegionEvent.SendMemberDemote(uid); } }
private void OnClickTotalReject() { if (LegionEvent.SendRejectTotalRequestJoin != null) { LegionEvent.SendRejectTotalRequestJoin(); } }
void OnClickGoldDontae() { if (LegionEvent.SendGoldDonate != null) { LegionEvent.SendGoldDonate(); } }
private void OnClickConsentApprove(long id) { if (LegionEvent.SendConsentRequestJoin != null) { LegionEvent.SendConsentRequestJoin(id); } }
void OnClickItem() { if (LegionEvent.OnClickMember != null) { LegionEvent.OnClickMember(uid); } }
void OnClickZZDonate() { if (LegionEvent.SendLuxuryDonate != null) { LegionEvent.SendLuxuryDonate(); } }
void OnClickGiveMonthCard(long uid) { if (LegionEvent.SendGiveMonthCard != null) { LegionEvent.SendGiveMonthCard(uid, GiveMonthCardSucess); } }
//给团长 void OnClickGiveOwner(long uid) { if (LegionEvent.SendMemberGiveOwner != null) { LegionEvent.SendMemberGiveOwner(uid); } }
void OnClickDiamondDonate() { if (LegionEvent.SendDiamandDonate != null) { LegionEvent.SendDiamandDonate(); } }
private void OnClickRefuseApprove(long id) { if (LegionEvent.SendRejectRequestJoin != null) { LegionEvent.SendRejectRequestJoin(id); } }
void OnClickTalk(long uid) { if (LegionEvent.OpenMemberTalk != null) { LegionEvent.OpenMemberTalk(uid); } }
public void SetLegionMembers(List <AllianceMember> members) { int d = members.Count - legionData.listMember.Count; if (d > 0) { for (int i = 0; i < d; i++) { LegionMemberData md = new LegionMemberData(); legionData.listMember.Add(md); } } else if (d < 0) { for (int i = 0; i < -d; i++) { legionData.listMember.RemoveAt(legionData.listMember.Count - 1); } } for (int i = 0; i < members.Count; i++) { SetMember(members[i], legionData.listMember[i]); } RankLegionMembers(); if (LegionEvent.NotifyUpdateLegionData != null) { LegionEvent.NotifyUpdateLegionData(legionData); } }
void OnClickAddFriend(long uid) { if (LegionEvent.SendMemberAddFriend != null) { LegionEvent.SendMemberAddFriend(uid); } }
void OnClickLeaveLegion() { if (LegionEvent.SendLeaveLegion != null) { LegionEvent.SendLeaveLegion(); } }
void OnClickSaveNotice(string notice) { if (LegionEvent.SendSaveLegionNotice != null) { LegionEvent.SendSaveLegionNotice(notice); } }
void OnClickManager() { if (LegionEvent.OpenManagerMenu != null) { LegionEvent.OpenManagerMenu(); } }
/// <summary> /// 点击事件标题 /// </summary> private void OnClickChoiceMessage() { MainChoiceState = ChoiceState.Message; LegionLogic.GetInstance().IsHaveNewEvent = false; LTRedPointSystem.Instance.SetRedPointNodeNum(RedPointConst.haveevent, 0); if (LegionEvent.SendGetLegionMessages != null) { LegionEvent.SendGetLegionMessages(); } }
void OnLegionAccount(AllianceAccount data) { if (data.State == eAllianceState.Joined) { controller.Close(); if (LegionEvent.LegionShowUI != null) { LegionEvent.LegionShowUI(); } } }
void OnItemApply(int legionID, bool isApply) { if (isApply && LegionEvent.SendApplyJoinLegion != null) { LegionEvent.SendApplyJoinLegion(legionID); } else if (!isApply && LegionEvent.SendCancelApplyJoinLegion != null) { LegionEvent.SendCancelApplyJoinLegion(legionID); } }
public void OnClickQuickJoin() { if (!isCouldClick()) { return; } if (LegionEvent.SearchQuickJoinLegion != null) { LegionEvent.SearchQuickJoinLegion(); } }
void OnClickApply() { if (!isCouldClick) { return; } if (LegionEvent.SendApplyJoinLegion != null) { LegionEvent.SendApplyJoinLegion(legionID); } }
/// <summary> /// 可搜索列表进行自身数据维护 /// </summary> private void SearchItemDatasProcess() { int userLevel = BalanceResourceUtil.GetUserLevel(); if (searchItemDatas == null) { return; } for (int i = 0; i < searchItemDatas.Length; i++) { searchItemDatas[i].isHasApplyed = false; searchItemDatas[i].isReachCondition = true; if (applyItemDatas != null) //对已申请的做判断 { for (int j = 0; j < applyItemDatas.Length; j++) { if (applyItemDatas[j].legionID == searchItemDatas[i].id) { searchItemDatas[i].isReachCondition = false; searchItemDatas[i].isHasApplyed = true; break; } } } if (searchItemDatas[i].isHasApplyed) //如果已经申请过的 { continue; } if (searchItemDatas[i].conditionLevel > userLevel) { searchItemDatas[i].isReachCondition = false; continue; } if (searchItemDatas[i].currentPeopleNum >= searchItemDatas[i].maxPeopleNum) { searchItemDatas[i].isReachCondition = false; continue; } } if (LegionEvent.NotifyUpdateSearchItemDatas != null) { LegionEvent.NotifyUpdateSearchItemDatas(searchItemDatas); } }
public void SetAllianceApplys(List <AllianceApply> applies) { int d = applies.Count - legionData.listRequestJoin.Count; if (d > 0) { for (int i = 0; i < d; i++) { RequestJoinData rjd = new RequestJoinData(); legionData.listRequestJoin.Add(rjd); } } else if (d < 0) { for (int i = 0; i < -d; i++) { legionData.listRequestJoin.RemoveAt(legionData.listRequestJoin.Count - 1); } } int index = 0; for (int i = 0; i < applies.Count; i++) { RequestJoinData rjd = legionData.listRequestJoin[index]; AllianceApply data = applies[i]; if (data == null) //如果为空就移除 { legionData.listRequestJoin.RemoveAt(legionData.listRequestJoin.Count - 1); continue; } rjd.name = data.Name; rjd.level = data.Level; rjd.approveID = data.Uid; rjd.headIcon = data.Portrait; rjd.headFrame = data.Frame; index++; } if (LegionEvent.NotifyUpdateLegionData != null) { LegionEvent.NotifyUpdateLegionData(legionData); } }
public void OnClickSearchGroup() { if (!isCouldClick()) { return; } if (LegionEvent.SearchLegion != null && searchInput != null && !searchInput.value.Equals(searchNormalStr)) { searchNormalStr = searchInput.value; LegionEvent.SearchLegion(searchInput.value); } else if (searchInput.value.Equals(searchNormalStr)) { searchNormalStr = ""; LegionEvent.SearchLegion(""); } }
/// <summary> /// 合并操作成员列表 /// </summary> /// <param name="members"></param> public void MergeLegionMembers(List <AllianceMember> members) { if (members == null) { return; } for (int i = 0; i < members.Count; i++) { if (members[i] == null) { continue; } bool isFind = false; for (int j = 0; j < legionData.listMember.Count; j++) { if (legionData.listMember[j].uid == members[i].Uid) { SetMember(members[i], legionData.listMember[j]); isFind = true; break; } } if (!isFind) { LegionMemberData md = new LegionMemberData(); legionData.listMember.Add(md); SetMember(members[i], md); } } RankLegionMembers(); if (LegionEvent.NotifyUpdateLegionData != null) { LegionEvent.NotifyUpdateLegionData(legionData); } }