This commit is contained in:
aozhiwei 2023-07-20 18:09:51 +08:00
parent 4b732218f1
commit 65c8d524a3

View File

@ -342,7 +342,15 @@ namespace mt
const RankMatchConf* Param::GetRankModeConfByRoomType(int room_type)
{
return nullptr;
if (s_.rank_mode_confs.empty()) {
abort();
}
for (auto conf : s_.rank_mode_confs) {
if (conf->room_type == room_type) {
return conf.get();
}
}
return s_.rank_mode_confs.at(s_.rank_mode_confs.size() - 1).get();
}
}