增加优先匹配机器人的逻辑

This commit is contained in:
zhl 2021-01-19 11:33:08 +08:00
parent 9c49d2b2d3
commit ff12e937b1

View File

@ -282,7 +282,8 @@ export class RankedLobbyRoom extends Room {
* Match long-waiting clients with bots
* FIXME: peers of this group may be entered short ago
*/
(stat.waitingTime >= this.maxWaitingTime && this.allowUnmatchedGroups)
(stat.waitingTime >= this.maxWaitingTime && this.allowUnmatchedGroups) ||
stat.priority
) {
currentGroup.ready = true;
currentGroup = this.createGroup();