public static void On_SC_Search_LBS_Rsp(CSPkg msg) { Singleton <CUIManager> .GetInstance().CloseSendMsgAlert(); SCPKG_CMD_LBS_SEARCH stLbsSearchRsq = msg.stPkgData.get_stLbsSearchRsq(); if (stLbsSearchRsq.dwResult == 0u) { Singleton <CFriendContoller> .get_instance().model.ClearLBSData(); int num = 0; while ((long)num < (long)((ulong)stLbsSearchRsq.dwLbsListNum)) { CSDT_LBS_USER_INFO cSDT_LBS_USER_INFO = stLbsSearchRsq.astLbsList[num]; if (cSDT_LBS_USER_INFO != null) { if (cSDT_LBS_USER_INFO.stLbsUserInfo.stUin.ullUid != Singleton <CRoleInfoManager> .GetInstance().GetMasterRoleInfo().playerUllUID) { Singleton <CFriendContoller> .get_instance().model.RemoveLBSUser(cSDT_LBS_USER_INFO.stLbsUserInfo.stUin.ullUid, cSDT_LBS_USER_INFO.stLbsUserInfo.stUin.dwLogicWorldId); Singleton <CFriendContoller> .get_instance().model.AddLBSUser(cSDT_LBS_USER_INFO); } } num++; } if (stLbsSearchRsq.dwLbsListNum == 0u) { string text = Singleton <CTextManager> .get_instance().GetText("LBS_Location_Error"); Singleton <CFriendContoller> .get_instance().model.searchLBSZero = text; if (Singleton <CFriendContoller> .get_instance().view != null && Singleton <CFriendContoller> .get_instance().view.ifnoText != null) { Singleton <CFriendContoller> .get_instance().view.ifnoText.text = text; } } else { Singleton <CFriendContoller> .get_instance().model.searchLBSZero = string.Empty; } Singleton <CFriendContoller> .get_instance().model.SortLBSFriend(); Singleton <EventRouter> .GetInstance().BroadCastEvent("Friend_LBS_User_Refresh"); } else { Singleton <CUIManager> .GetInstance().OpenTips(UT.ErrorCode_String(stLbsSearchRsq.dwResult), false, 1.5f, null, new object[0]); } }
public static void On_SC_Search_LBS_Rsp(CSPkg msg) { Singleton <CUIManager> .GetInstance().CloseSendMsgAlert(); SCPKG_CMD_LBS_SEARCH stLbsSearchRsq = msg.stPkgData.stLbsSearchRsq; if (stLbsSearchRsq.dwResult == 0) { Singleton <CFriendContoller> .instance.model.ClearLBSData(); for (int i = 0; i < stLbsSearchRsq.dwLbsListNum; i++) { CSDT_LBS_USER_INFO info = stLbsSearchRsq.astLbsList[i]; if ((info != null) && (info.stLbsUserInfo.stUin.ullUid != Singleton <CRoleInfoManager> .GetInstance().GetMasterRoleInfo().playerUllUID)) { Singleton <CFriendContoller> .instance.model.RemoveLBSUser(info.stLbsUserInfo.stUin.ullUid, info.stLbsUserInfo.stUin.dwLogicWorldId); Singleton <CFriendContoller> .instance.model.AddLBSUser(info); } } if (stLbsSearchRsq.dwLbsListNum == 0) { string text = Singleton <CTextManager> .instance.GetText("LBS_Location_Error"); Singleton <CFriendContoller> .instance.model.searchLBSZero = text; if ((Singleton <CFriendContoller> .instance.view != null) && (Singleton <CFriendContoller> .instance.view.ifnoText != null)) { Singleton <CFriendContoller> .instance.view.ifnoText.text = text; } } else { Singleton <CFriendContoller> .instance.model.searchLBSZero = string.Empty; } Singleton <CFriendContoller> .instance.model.SortLBSFriend(); Singleton <EventRouter> .GetInstance().BroadCastEvent("Friend_LBS_User_Refresh"); } else { Singleton <CUIManager> .GetInstance().OpenTips(UT.ErrorCode_String(stLbsSearchRsq.dwResult), false, 1.5f, null, new object[0]); } }