TW卑弥呼【秉诏】bug修复

修复TW卑弥呼【秉诏】可以选择自己的势力的bug
This commit is contained in:
mengxinzxz 2023-09-07 23:37:52 +08:00 committed by GitHub
parent 03eaa92326
commit 3398d84f56
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 11 additions and 4 deletions

View File

@ -5499,7 +5499,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
mod:{
targetInRange:function(card,player,target){
if(!card.cards||!card.cards.length) return;
if(!card.cards) return;
for(var i of card.cards){
if(!i.hasGaintag('minsi2')||get.color(i)!='black') return;
}
@ -8546,16 +8546,23 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},
trigger:{global:['phaseBefore','zhuUpdate']},
filter:function(event,player){
if(!lib.group.some(function(group){
if(group==player.group) return false;
return lib.group.contains(group)||game.hasPlayer(function(current){
return current.group==group;
});
})) return false;
return !player.storage.bingzhao&&player.hasZhuSkill('bingzhao')&&(event.name!='phase'||game.phaseNumber==0);
},
content:function(){
'step 0'
var list=lib.group.filter(function(group){
return ['wei','shu','wu','qun'].contains(group)||game.hasPlayer(function(current){
if(group==player.group) return false;
return lib.group.contains(group)||game.hasPlayer(function(current){
return current.group==group;
})
});
player.chooseControl(list).set('prompt','秉诏:请选择一个势力').set('ai',function(){
});
player.chooseControl(list).set('prompt','秉诏:请选择一个其他势力').set('ai',function(){
var listx=list.slice(0);
listx.sort(function(a,b){
return game.countPlayer(function(current){