From 5f7bd2c1aa9900e827ce748d8ebe622f7dfd8fa6 Mon Sep 17 00:00:00 2001 From: WEBXOSS Date: Sun, 14 May 2017 22:53:43 +0800 Subject: [PATCH] fix shadow --- Player.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Player.js b/Player.js index 51a1207..8da6955 100644 --- a/Player.js +++ b/Player.js @@ -1922,10 +1922,9 @@ Player.prototype.selectSomeTargetsAsyn = function (cards,min,max,careOrder) { Player.prototype.selectSomeAsyn = function (label,items,min,max,careOrder,extraCards) { // 过滤 shadow 目标 items = items.filter(item => { - if (item.shadow) { - if ((item.player !== this) || ((this.game.getEffectSource() || {}).player !== this)) { - return false; - } + var source = this.game.getEffectSource(); + if (item.shadow && source && source.player !== item.player) { + return false; } return true; });