From 9d5b8192dca33a70f1ef5b31ccf16b38169e9cb1 Mon Sep 17 00:00:00 2001 From: Spmario233 Date: Mon, 9 Oct 2023 00:23:56 +0800 Subject: [PATCH] bugfix --- card/extra.js | 2 +- character/sp2.js | 2 +- game/game.js | 4 +++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/card/extra.js b/card/extra.js index 4e6cfa057..94869ef17 100644 --- a/card/extra.js +++ b/card/extra.js @@ -225,7 +225,7 @@ game.import('card',function(lib,game,ui,get,ai,_status){ value:[3,1], useful:1, }, - wuxie:function(target,card,player,current,state){ + wuxie:function(target,card,player,viewer,state){ let att=get.attitude(viewer,target), eff=get.effect(target,card,player,target); if(status*get.attitude(viewer,player)>0&&!player.isMad() || status*eff*att>=0) return 0; if(get.attitude(viewer,player)>=0 || _status.event.getRand('huogong_wuxie')*4>player.countCards('h')) return 0; diff --git a/character/sp2.js b/character/sp2.js index 5a3bbbed4..8635c4118 100644 --- a/character/sp2.js +++ b/character/sp2.js @@ -2870,7 +2870,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){ viewAs:{name:'juedou'}, position:'h', filterTarget:lib.filter.targetEnabled, - check:(card)=>get.name(card)=='sha'?0:5.5-get.value(card); + check:(card)=>get.name(card)=='sha'?0:5.5-get.value(card), log:false, precontent:function(){ delete event.result.skill; diff --git a/game/game.js b/game/game.js index 388ae0769..d9063bf2f 100644 --- a/game/game.js +++ b/game/game.js @@ -8487,7 +8487,9 @@ enumerable:false, writable:true, value:function(){ - for(const i of Array.from(arguments)) this.add(...i); + for(const arr of arguments){ + for(const item of arr) this.add(item); + } return this; } });