diff --git a/card/gujian.js b/card/gujian.js index c4bb47a0e..2ce52a0f6 100644 --- a/card/gujian.js +++ b/card/gujian.js @@ -667,11 +667,9 @@ card.gujian={ return target!=player&&target.num('he')>0; }, changeTarget:function(player,targets){ - game.countPlayer(function(current){ - if(get.distance(targets[0],current,'pure')==1&¤t.num('he')){ - targets.push(current); - } - }); + game.filterPlayer(function(current){ + return get.distance(targets[0],current,'pure')==1&¤t.num('he'); + },targets); }, content:function(){ var he=target.get('he'); diff --git a/card/guozhan.js b/card/guozhan.js index 11812816a..7fe660995 100644 --- a/card/guozhan.js +++ b/card/guozhan.js @@ -89,21 +89,18 @@ card.guozhan={ fullskin:true, type:'trick', enable:function(card,player){ - for(var i=0;i0){ - num++; - } - else if(eff<0){ - num--; - } + return game.countPlayer(function(current){ + if(current.isLinked()){ + return get.sgn(ai.get.damageEffect(current,player,target,'fire')); } - } - return num; + }); } } } @@ -527,11 +503,9 @@ card.guozhan={ basic:{ equipValue:function(card,player){ if(player.identity=='unknown'||player.identity=='ye') return 2.5; - var num=2; - for(var i=0;i0; + return game.hasPlayer(function(current){ + return current!=event.player&&get.distance(event.player,current)<=1; + }); }, content:function(){ "step 0" diff --git a/card/hearth.js b/card/hearth.js index 4ea38ae40..4916bb033 100644 --- a/card/hearth.js +++ b/card/hearth.js @@ -423,7 +423,7 @@ card.hearth={ content:function(){ 'step 0' event.current=target; - event.num=game.players.length; + event.num=game.countPlayer(lib.filter.all); if(event.num%2==0){ event.num--; } @@ -619,11 +619,7 @@ card.hearth={ result:{ target:function(player,target){ if(target.hasSkillTag('nothunder')) return 0; - var num=0; - for(var i=0;i1) return 0; + if(player.hasUnknown()) return 0; var nh=target.num('he'); if(target==player) nh--; if(nh==2) return -2.5; diff --git a/card/sp.js b/card/sp.js index bc6b72e3f..b93faeda4 100644 --- a/card/sp.js +++ b/card/sp.js @@ -68,7 +68,7 @@ card.sp={ fullskin:true, enable:true, chongzhu:function(){ - return game.players.length<=2; + return game.countPlayer(lib.filter.all)<=2; }, singleCard:true, type:'trick', @@ -200,25 +200,23 @@ card.sp={ }, result:{ player:function(player,target){ - var num=0; - for(var i=0;i3){ - num+=1.1; + return 1.1; } else if(att>0){ - num++; + return 1; } else if(att<-3){ - num-=1.1; + return -1.1; } else if(att<0){ - num--; + return -1; } } - } - return num; + }); }, target:-1 }, @@ -304,14 +302,12 @@ card.sp={ game.broadcast(function(muniu,cards){ muniu.cards=cards; },muniu,muniu.cards); - var players=[]; - for(var i=0;i=3&&ai.get.attitude(game.players[i],player)>=3){ - players.push(game.players[i]); + var players=game.filterPlayer(function(current){ + if(!current.get('e','5')&¤t!=player&&!current.isTurnedOver()&& + ai.get.attitude(player,current)>=3&&ai.get.attitude(current,player)>=3){ + return true; } - } + }); players.sort(lib.sort.seat); var choice=players[0]; var next=player.chooseTarget('是否移动木牛流马?',function(card,player,target){ diff --git a/character/rank.js b/character/rank.js index d86e5e641..6d6cdc672 100644 --- a/character/rank.js +++ b/character/rank.js @@ -74,7 +74,6 @@ window.characterRank={ 'hs_laxiao', 'hs_shaku', 'hs_fandral', - 'hs_totemic', 'sundeng', 'hs_xialikeer', 'hs_sainaliusi', @@ -144,6 +143,7 @@ window.characterRank={ ], am:[ 'old_wangyi', + 'hs_totemic', 'swd_duanmeng', 'pal_wenhui', 'gjqt_xunfang', diff --git a/game/game.js b/game/game.js index 02adb22f5..702ec3539 100644 --- a/game/game.js +++ b/game/game.js @@ -22687,12 +22687,14 @@ } return num; }, - filterPlayer:function(func){ - var list=[]; + filterPlayer:function(func,list){ + if(!Array.isArray(list)){ + list=[]; + } for(var i=0;i0) return 1; + if(num<0) return -1; + return 0; + }, rand:function(num,num2){ if(typeof num2=='number'){ return num+Math.floor(Math.random()*(num2-num+1)); diff --git a/image/card/sanjian.png b/image/card/sanjian.png old mode 100755 new mode 100644 index e91c9ecd3..ac4062950 Binary files a/image/card/sanjian.png and b/image/card/sanjian.png differ diff --git a/layout/default/layout.css b/layout/default/layout.css index e8a1a5dbd..1840cbde8 100644 --- a/layout/default/layout.css +++ b/layout/default/layout.css @@ -752,7 +752,7 @@ table { opacity: 0; pointer-events: none; } -#arena.auto #me .card{ +#arena.auto #me .handcards{ opacity: 0.5 } #autonode>div {