From 4aa2461875114d0b2ddc7701c29da9ac9673349c Mon Sep 17 00:00:00 2001 From: deardrops Date: Wed, 8 Feb 2017 15:56:08 +0800 Subject: [PATCH] fix player.draw --- CardInfo.js | 3 --- Player.js | 1 + 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/CardInfo.js b/CardInfo.js index 9e87ed0..0dcdc21 100644 --- a/CardInfo.js +++ b/CardInfo.js @@ -87853,9 +87853,6 @@ var CardInfo = { var effect = this.game.newEffect({ source: this, description: '1437-const-0', - triggerCondition: function () { - return !this.player.addCardTohandBanned - }, actionAsyn: function () { this.player.draw(1); } diff --git a/Player.js b/Player.js index c56bc52..cdef2c8 100644 --- a/Player.js +++ b/Player.js @@ -261,6 +261,7 @@ Player.prototype.up = function () { // 返回: // cards: Array,抽到的卡,长度可能少于n(卡组没有足够的卡可以抽),也可能为空数组. Player.prototype.draw = function (n) { + if (this.addCardToHandBanned) return []; var cards = this.mainDeck.getTopCards(n); if (!cards.length) return []; if (this.game.phase.isAttackPhase()) {