1
This commit is contained in:
parent
8bde103bf5
commit
c2eec25e39
@ -308,12 +308,12 @@ void Guild::_CMGuildDismiss(f8::MsgHdr& hdr, const cs::CMGuildDismiss& msg)
|
|||||||
SaveToDB();
|
SaveToDB();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Guild::_CMGuildRename(f8::MsgHdr& hdr, const cs::CMGuildRename& msg)
|
void Guild::_CMGuildChange(f8::MsgHdr& hdr, const cs::CMGuildChange& msg)
|
||||||
{
|
{
|
||||||
ss::SS_IM_ForwardGuildCMMsg *forward_msg = (ss::SS_IM_ForwardGuildCMMsg*)hdr.user_data;
|
ss::SS_IM_ForwardGuildCMMsg *forward_msg = (ss::SS_IM_ForwardGuildCMMsg*)hdr.user_data;
|
||||||
|
|
||||||
guild_name_ = msg.new_name();
|
guild_name_ = msg.new_name();
|
||||||
cs::SMGuildRename respmsg;
|
cs::SMGuildChange respmsg;
|
||||||
GuildMgr::Instance()->ForwardGuildSMMsg(hdr.socket_handle,
|
GuildMgr::Instance()->ForwardGuildSMMsg(hdr.socket_handle,
|
||||||
forward_msg->context(),
|
forward_msg->context(),
|
||||||
respmsg);
|
respmsg);
|
||||||
|
@ -22,7 +22,7 @@ public:
|
|||||||
void _CMGuildKick(f8::MsgHdr& hdr, const cs::CMGuildKick& msg);
|
void _CMGuildKick(f8::MsgHdr& hdr, const cs::CMGuildKick& msg);
|
||||||
void _CMGuildQuit(f8::MsgHdr& hdr, const cs::CMGuildQuit& msg);
|
void _CMGuildQuit(f8::MsgHdr& hdr, const cs::CMGuildQuit& msg);
|
||||||
void _CMGuildDismiss(f8::MsgHdr& hdr, const cs::CMGuildDismiss& msg);
|
void _CMGuildDismiss(f8::MsgHdr& hdr, const cs::CMGuildDismiss& msg);
|
||||||
void _CMGuildRename(f8::MsgHdr& hdr, const cs::CMGuildRename& msg);
|
void _CMGuildChange(f8::MsgHdr& hdr, const cs::CMGuildChange& msg);
|
||||||
void _CMGuildMemberList(f8::MsgHdr& hdr, const cs::CMGuildMemberList& msg);
|
void _CMGuildMemberList(f8::MsgHdr& hdr, const cs::CMGuildMemberList& msg);
|
||||||
void _CMGuildApplyList(f8::MsgHdr& hdr, const cs::CMGuildApplyList& msg);
|
void _CMGuildApplyList(f8::MsgHdr& hdr, const cs::CMGuildApplyList& msg);
|
||||||
void _CMGuildLog(f8::MsgHdr& hdr, const cs::CMGuildLog& msg);
|
void _CMGuildLog(f8::MsgHdr& hdr, const cs::CMGuildLog& msg);
|
||||||
|
@ -110,7 +110,7 @@ void HandlerMgr::RegisterNetMsgHandlers()
|
|||||||
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildKick);
|
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildKick);
|
||||||
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildQuit);
|
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildQuit);
|
||||||
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildDismiss);
|
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildDismiss);
|
||||||
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildRename);
|
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildChange);
|
||||||
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildSearch);
|
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildSearch);
|
||||||
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildRank);
|
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildRank);
|
||||||
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildMemberList);
|
RegisterNetMsgHandler(&wsmsghandler, &Player::_CMGuildMemberList);
|
||||||
@ -124,7 +124,7 @@ void HandlerMgr::RegisterNetMsgHandlers()
|
|||||||
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildKick);
|
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildKick);
|
||||||
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildQuit);
|
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildQuit);
|
||||||
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildDismiss);
|
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildDismiss);
|
||||||
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildRename);
|
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildChange);
|
||||||
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildMemberList);
|
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildMemberList);
|
||||||
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildApplyList);
|
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildApplyList);
|
||||||
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildLog);
|
RegisterNetMsgHandler(&guild_msghandler, &Guild::_CMGuildLog);
|
||||||
|
@ -757,9 +757,9 @@ void Player::_CMGuildDismiss(f8::MsgHdr& hdr, const cs::CMGuildDismiss& msg)
|
|||||||
ForwardGuildCMMsg(hdr, GuildId());
|
ForwardGuildCMMsg(hdr, GuildId());
|
||||||
}
|
}
|
||||||
|
|
||||||
void Player::_CMGuildRename(f8::MsgHdr& hdr, const cs::CMGuildRename& msg)
|
void Player::_CMGuildChange(f8::MsgHdr& hdr, const cs::CMGuildChange& msg)
|
||||||
{
|
{
|
||||||
cs::SMGuildRename respmsg;
|
cs::SMGuildChange respmsg;
|
||||||
if (GuildId() == 0) {
|
if (GuildId() == 0) {
|
||||||
respmsg.set_errcode(1);
|
respmsg.set_errcode(1);
|
||||||
respmsg.set_errmsg("你还没有公会");
|
respmsg.set_errmsg("你还没有公会");
|
||||||
|
@ -102,7 +102,7 @@ class Player
|
|||||||
void _CMGuildKick(f8::MsgHdr& hdr, const cs::CMGuildKick& msg);
|
void _CMGuildKick(f8::MsgHdr& hdr, const cs::CMGuildKick& msg);
|
||||||
void _CMGuildQuit(f8::MsgHdr& hdr, const cs::CMGuildQuit& msg);
|
void _CMGuildQuit(f8::MsgHdr& hdr, const cs::CMGuildQuit& msg);
|
||||||
void _CMGuildDismiss(f8::MsgHdr& hdr, const cs::CMGuildDismiss& msg);
|
void _CMGuildDismiss(f8::MsgHdr& hdr, const cs::CMGuildDismiss& msg);
|
||||||
void _CMGuildRename(f8::MsgHdr& hdr, const cs::CMGuildRename& msg);
|
void _CMGuildChange(f8::MsgHdr& hdr, const cs::CMGuildChange& msg);
|
||||||
void _CMGuildSearch(f8::MsgHdr& hdr, const cs::CMGuildSearch& msg);
|
void _CMGuildSearch(f8::MsgHdr& hdr, const cs::CMGuildSearch& msg);
|
||||||
void _CMGuildRank(f8::MsgHdr& hdr, const cs::CMGuildRank& msg);
|
void _CMGuildRank(f8::MsgHdr& hdr, const cs::CMGuildRank& msg);
|
||||||
void _CMGuildMemberList(f8::MsgHdr& hdr, const cs::CMGuildMemberList& msg);
|
void _CMGuildMemberList(f8::MsgHdr& hdr, const cs::CMGuildMemberList& msg);
|
||||||
|
@ -40,7 +40,7 @@ enum CMMessageId_e
|
|||||||
_CMGuildKick = 234;
|
_CMGuildKick = 234;
|
||||||
_CMGuildQuit = 235;
|
_CMGuildQuit = 235;
|
||||||
_CMGuildDismiss = 236;
|
_CMGuildDismiss = 236;
|
||||||
_CMGuildRename = 237;
|
_CMGuildChange = 237;
|
||||||
_CMGuildInfo = 238;
|
_CMGuildInfo = 238;
|
||||||
_CMGuildSearch = 239;
|
_CMGuildSearch = 239;
|
||||||
_CMGuildRank = 240;
|
_CMGuildRank = 240;
|
||||||
@ -87,7 +87,7 @@ enum SMMessageId_e
|
|||||||
_SMGuildKick = 234;
|
_SMGuildKick = 234;
|
||||||
_SMGuildQuit = 235;
|
_SMGuildQuit = 235;
|
||||||
_SMGuildDismiss = 236;
|
_SMGuildDismiss = 236;
|
||||||
_SMGuildRename = 237;
|
_SMGuildChange = 237;
|
||||||
_SMGuildInfo = 238;
|
_SMGuildInfo = 238;
|
||||||
_SMGuildSearch = 239;
|
_SMGuildSearch = 239;
|
||||||
_SMGuildRank = 240;
|
_SMGuildRank = 240;
|
||||||
|
@ -431,11 +431,11 @@ message SMGuildDismiss
|
|||||||
}
|
}
|
||||||
|
|
||||||
//公会改名
|
//公会改名
|
||||||
message CMGuildRename
|
message CMGuildChange
|
||||||
{
|
{
|
||||||
optional string new_name = 1; //新公会名
|
optional string new_name = 1; //新公会名
|
||||||
}
|
}
|
||||||
message SMGuildRename
|
message SMGuildChange
|
||||||
{
|
{
|
||||||
optional int32 errcode = 1; //错误码
|
optional int32 errcode = 1; //错误码
|
||||||
optional string errmsg = 2; //错误信息
|
optional string errmsg = 2; //错误信息
|
||||||
|
@ -44,7 +44,7 @@ enum SSMessageId_e
|
|||||||
_SS_IM_ForwardGuildCMMsg = 1027;
|
_SS_IM_ForwardGuildCMMsg = 1027;
|
||||||
_SS_IM_ForwardGuildSMMsg = 1028;
|
_SS_IM_ForwardGuildSMMsg = 1028;
|
||||||
_SS_IM_GuildMemberQuitRequest = 1031;
|
_SS_IM_GuildMemberQuitRequest = 1031;
|
||||||
_SS_IM_GuildMemberQuitResponsea = 1032;
|
_SS_IM_GuildMemberQuitResponse = 1032;
|
||||||
_SS_IM_GuildMemberUpdateRequest = 1033;
|
_SS_IM_GuildMemberUpdateRequest = 1033;
|
||||||
_SS_IM_GuildMemberUpdateResponse = 1034;
|
_SS_IM_GuildMemberUpdateResponse = 1034;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user