From 4ce77a7e087d33a4dbff244bee713c1c179a26f3 Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Wed, 3 Jun 2020 15:50:24 +0800 Subject: [PATCH] 1 --- server/gameserver/roommgr.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/gameserver/roommgr.cc b/server/gameserver/roommgr.cc index 251c81f..e914a03 100644 --- a/server/gameserver/roommgr.cc +++ b/server/gameserver/roommgr.cc @@ -310,7 +310,7 @@ int RoomMgr::AllocRoomIdx() if (current_room_idx_ < 0) { current_room_idx_ = 0; } - if (current_room_idx_ >= (MAX_ROOM_IDX - 1)) { + if (current_room_idx_ >= (MAX_ROOM_IDX - 3)) { current_room_idx_ = 0; } } while (GetRoomByIdx(++current_room_idx_));