From 01eba6f5c1cdd962daf99269b96c0a779d5beada Mon Sep 17 00:00:00 2001 From: WEBXOSS Date: Fri, 23 Dec 2016 22:38:09 +0800 Subject: [PATCH] Fix PR-305 --- Card.js | 12 ++++++------ CardInfo.js | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Card.js b/Card.js index 146502e..27751af 100644 --- a/Card.js +++ b/Card.js @@ -1088,11 +1088,11 @@ Card.prototype.attackAsyn = function () { if (opposingSigni && !card.assassin) { // 战斗 // 触发"进行战斗"时点 + var onBattleEvent = { + card: card, + opposingSigni: opposingSigni + }; return this.game.blockAsyn(this,function () { - var onBattleEvent = { - card: card, - opposingSigni: opposingSigni - }; this.game.frameStart(); card.onBattle.trigger(onBattleEvent); opposingSigni.onBattle.trigger(onBattleEvent); @@ -1118,8 +1118,8 @@ Card.prototype.attackAsyn = function () { }); } }).callback(this,function () { - if (event._1877 && inArr(opposingSigni,opposingSigni.player.signis)) { - return this.game.blockAsyn(event._1877,this,function () { + if (onBattleEvent._1877 && inArr(opposingSigni,opposingSigni.player.signis)) { + return this.game.blockAsyn(onBattleEvent._1877,this,function () { opposingSigni.moveTo(opposingSigni.player.mainDeck,{bottom: true}); }); } diff --git a/CardInfo.js b/CardInfo.js index 1757369..19f9923 100644 --- a/CardInfo.js +++ b/CardInfo.js @@ -115267,7 +115267,7 @@ var CardInfo = { description: '1877-const-0', optional: true, actionAsyn: function (event) { - return this.discardAsyn(1).callback(this,function (cards) { + return this.player.discardAsyn(1).callback(this,function (cards) { if (!cards.length) return; event._1877 = this; });