diff --git a/server/gameserver/room.cc b/server/gameserver/room.cc index c2ebd0bd..6f792f07 100644 --- a/server/gameserver/room.cc +++ b/server/gameserver/room.cc @@ -947,6 +947,9 @@ bool Room::CanJoin(const std::string& accountid, int init_map_id, const cs::CMJoin& msg) { + if (lock_room_) { + return false; + } if (IsNewBieRoom()) { return false; } @@ -1008,6 +1011,9 @@ bool Room::CanJoin(const std::string& accountid, bool Room::CanJoin(class MatchTeam* team) { + if (lock_room_) { + return false; + } if (GetGasData().GetGasMode() != GasInactive) { return false; } diff --git a/server/gameserver/room.h b/server/gameserver/room.h index f5283d91..acebcabb 100644 --- a/server/gameserver/room.h +++ b/server/gameserver/room.h @@ -402,6 +402,7 @@ private: Team* victory_team_ = nullptr; bool force_over_ = false; + bool lock_room_ = false; friend class Incubator; friend class Team;