This commit is contained in:
aozhiwei 2023-06-25 16:09:21 +08:00
parent b6a24d878b
commit 9699569d82

View File

@ -1084,11 +1084,12 @@ bool Room::CanJoin(const std::string& accountid,
}
if (IsPvpRankModeRoom() && GetOnlinePlayerNum() >= mt::Param::s().rank_mode_min_player) {
if (lock_room_timer_.expired()) {
lock_room_timer_ = xtimer.SetIntervalWpEx
lock_room_timer_ = xtimer.SetTimeoutWpEx
(SERVER_FRAME_RATE * 10,
[this] (int event, const a8::Args* args)
{
if (a8::TIMER_EXEC_EVENT == event) {
LockRoom();
}
},
&xtimer_attacher_);