diff --git a/server/gameserver/roommgr.cc b/server/gameserver/roommgr.cc index fbb2d9a3..bbf8d043 100644 --- a/server/gameserver/roommgr.cc +++ b/server/gameserver/roommgr.cc @@ -113,6 +113,9 @@ void RoomMgr::_CMJoin(f8::MsgHdr& hdr, const cs::CMJoin& msg) JoinErrorHandle(msg, 3, hdr.socket_handle); return; } + if (!msg.custom_room_payload().empty()) { + _CMJoinCustomBattle(hdr, msg); + } std::shared_ptr join_msg = std::make_shared(); *join_msg = msg; std::vector> join_msgs{join_msg}; @@ -841,6 +844,11 @@ std::shared_ptr RoomMgr::GetHisCustomRoom(const std::string& room_ return itr != his_custom_room_hash_.end() ? itr->second : nullptr; } +void RoomMgr::_CMJoinCustomBattle(f8::MsgHdr& hdr, const cs::CMJoin& msg) +{ + +} + void RoomMgr::SendGetCustomBattleData(std::shared_ptr join_msg, std::function)> cb) { diff --git a/server/gameserver/roommgr.h b/server/gameserver/roommgr.h index 6146a5bf..184e4251 100644 --- a/server/gameserver/roommgr.h +++ b/server/gameserver/roommgr.h @@ -118,6 +118,7 @@ class RoomMgr : public a8::Singleton void AdjustCMJoin(cs::CMJoin* msg); std::shared_ptr GetCustomRoom(const std::string& room_uuid); std::shared_ptr GetHisCustomRoom(const std::string& room_uuid); + void _CMJoinCustomBattle(f8::MsgHdr& hdr, const cs::CMJoin& msg); void SendGetCustomBattleData(std::shared_ptr join_msg, std::function)> cb);