1
This commit is contained in:
parent
3e8b7757ec
commit
1aaf093be2
@ -672,6 +672,7 @@ void Player::_CMGuildCreate(f8::MsgHdr& hdr, const cs::CMGuildCreate& msg)
|
||||
|
||||
Player* hum = PlayerMgr::Instance()->GetPlayerBySocket(msg_context->socket_handle);
|
||||
if (hum && hum->AccountId() == msg_context->account_id) {
|
||||
hum->UpdateGuildData(msg_context->guild_id, kGuildOwner);
|
||||
cs::SMGuildCreate respmsg;
|
||||
hum->SendMsg(respmsg);
|
||||
}
|
||||
@ -1048,6 +1049,7 @@ void Player::_SS_IM_FriendApply(f8::MsgHdr& hdr, const ss::SS_IM_FriendApply& ms
|
||||
void Player::ReLogin(f8::MsgHdr& hdr, const cs::CMLogin& msg)
|
||||
{
|
||||
cs::SMLogin respmsg;
|
||||
FillSMLogin(respmsg);
|
||||
WSListener::Instance()->SendToClient(hdr.socket_handle, 0, respmsg);
|
||||
PlayerMgr::Instance()->ReBindSocket(hdr.socket_handle, this);
|
||||
}
|
||||
@ -1228,6 +1230,11 @@ void Player::UpdateGuildData(long long guild_id, int guild_job)
|
||||
OnDataVersion1Change();
|
||||
}
|
||||
|
||||
void Player::FillSMLogin(cs::SMLogin& respmsg)
|
||||
{
|
||||
FillMFUserInfo(respmsg.mutable_account_info()->mutable_user_info());
|
||||
}
|
||||
|
||||
void Player::FillApplyList(const cs::MFPaging& paging, cs::SMFriendApplyList& respmsg)
|
||||
{
|
||||
RemoveHandledApply();
|
||||
|
@ -123,6 +123,7 @@ class Player
|
||||
Friend* GetFriendById(const std::string& friend_id);
|
||||
Friend* GetBlackListById(const std::string& friend_id);
|
||||
void UpdateGuildData(long long guild_id, int guild_job);
|
||||
void FillSMLogin(cs::SMLogin& respmsg);
|
||||
|
||||
const std::string AccountId();
|
||||
const std::string SessionId();
|
||||
|
@ -553,6 +553,7 @@ void PlayerMgr::AsyncLoginOnOk(const std::string& account_id,
|
||||
cs::SMLogin respmsg;
|
||||
respmsg.set_errcode(0);
|
||||
respmsg.set_errmsg("ok");
|
||||
hum->FillSMLogin(respmsg);
|
||||
hum->SendMsg(respmsg);
|
||||
}
|
||||
long long login_tick = a8::XGetTickCount() - (long long)hdr->user_data;
|
||||
|
@ -38,8 +38,8 @@ message MFBaseUserData
|
||||
optional string avatar_url = 3; //头像
|
||||
optional int32 sex = 4; //性别 1:男 2:女 0:未知
|
||||
optional int32 last_login_time = 5; //最后登录时间
|
||||
optional int64 guild_id = 6; //工会id
|
||||
optional int32 guild_job = 7; //公会职位
|
||||
optional int64 guild_id = 6; //工会id(没有公会的话为0)
|
||||
optional int32 guild_job = 7; //公会职位 1:公会长 2:副公会长 3:精英成员 其他:普通会员
|
||||
|
||||
optional int64 user_value1 = 50; //用户字段1
|
||||
optional int64 user_value2 = 51; //用户字段2
|
||||
|
Loading…
x
Reference in New Issue
Block a user