生成卡牌时候, 如果无法生成对应的卡, 则直接返回, 并打印错误日志

This commit is contained in:
zhl 2020-12-29 11:23:04 +08:00
parent 1aa0bf05f3
commit ea19b69eca

View File

@ -187,7 +187,10 @@ Object.defineProperties(Room.prototype, {
tmpCards.push(card);
}
}
if (tmpCards.length == 0) {
error(`生成卡牌时, 无法获取对应的effect配置, ${dstplayer.id}, ${effectId}, ${realCount}`)
return 0;
}
let sourcePlayer;
if (typeof fromplayer == 'string') {