bugfix,出闪ai微调
This commit is contained in:
parent
9e2c6195de
commit
4c0faea3b0
|
@ -157,11 +157,10 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
||||||
if(target.hasSkillTag('useShan',null,event)) return true;
|
if(target.hasSkillTag('useShan',null,event)) return true;
|
||||||
if(target.isLinked()&&game.hasNature(event.card)&&get.attitude(target,player._trueMe||player)>0) return false;
|
if(target.isLinked()&&game.hasNature(event.card)&&get.attitude(target,player._trueMe||player)>0) return false;
|
||||||
if(event.baseDamage+event.extraDamage<=0&&!game.hasNature(event.card,'ice')) return false;
|
if(event.baseDamage+event.extraDamage<=0&&!game.hasNature(event.card,'ice')) return false;
|
||||||
if(target.hasSkillTag('freeShan',false,event,true)) return true;
|
|
||||||
if(event.shanRequired>1&&target.mayHaveShan(target,'use',null,'count')<event.shanRequired-(event.shanIgnored||0)) return false;
|
|
||||||
if(event.baseDamage+event.extraDamage>=target.hp+
|
if(event.baseDamage+event.extraDamage>=target.hp+
|
||||||
((player.hasSkillTag('jueqing',false,target)||target.hasSkill('gangzhi'))?target.hujia:0)) return true;
|
((player.hasSkillTag('jueqing',false,target)||target.hasSkill('gangzhi'))?target.hujia:0)) return true;
|
||||||
if(!game.hasNature(event.card,'ice')&&get.damageEffect(target,player,target,get.nature(event.card))>=0) return false;
|
if(!game.hasNature(event.card,'ice')&&get.damageEffect(target,player,target,get.nature(event.card))>=0) return false;
|
||||||
|
if(event.shanRequired>1&&target.mayHaveShan(target,'use',null,'count')<event.shanRequired-(event.shanIgnored||0)) return false;
|
||||||
return true;
|
return true;
|
||||||
})());
|
})());
|
||||||
//next.autochoose=lib.filter.autoRespondShan;
|
//next.autochoose=lib.filter.autoRespondShan;
|
||||||
|
@ -2911,14 +2910,19 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
||||||
},
|
},
|
||||||
audio:true,
|
audio:true,
|
||||||
check:function(event,player){
|
check:function(event,player){
|
||||||
if(event&&(event.ai||event.ai1)){
|
if(!event) return true;
|
||||||
var ai=event.ai||event.ai1;
|
if(event.ai){
|
||||||
|
var ai=event.ai;
|
||||||
var tmp=_status.event;
|
var tmp=_status.event;
|
||||||
_status.event=event;
|
_status.event=event;
|
||||||
var result=ai({name:'shan'},_status.event.player,event);
|
var result=ai({name:'shan'},_status.event.player,event);
|
||||||
_status.event=tmp;
|
_status.event=tmp;
|
||||||
return result>0;
|
return result>0;
|
||||||
}
|
}
|
||||||
|
let evt=event.getParent();
|
||||||
|
if(player.hasSkillTag('noShan',null,evt)) return false;
|
||||||
|
if(!evt||!evt.card||!evt.player||player.hasSkillTag('useShan',null,evt)) return true;
|
||||||
|
if(evt.card&&evt.player&&player.isLinked()&&game.hasNature(evt.card)&&get.attitude(player,evt.player._trueMe||evt.player)>0) return false;
|
||||||
return true;
|
return true;
|
||||||
},
|
},
|
||||||
content:function(){
|
content:function(){
|
||||||
|
@ -2943,8 +2947,6 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
||||||
if(!arg||!arg.player) return true;
|
if(!arg||!arg.player) return true;
|
||||||
if(arg.player.hasSkillTag('unequip',false,{
|
if(arg.player.hasSkillTag('unequip',false,{
|
||||||
target:player
|
target:player
|
||||||
})||arg.player.hasSkillTag('unequip_ai',false,{
|
|
||||||
target:player
|
|
||||||
})) return false;
|
})) return false;
|
||||||
return true;
|
return true;
|
||||||
},
|
},
|
||||||
|
|
|
@ -5441,8 +5441,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
if(!arg||!arg.player) return true;
|
if(!arg||!arg.player) return true;
|
||||||
if(arg.player.hasSkillTag('unequip',false,{
|
if(arg.player.hasSkillTag('unequip',false,{
|
||||||
target:player
|
target:player
|
||||||
})||arg.player.hasSkillTag('unequip_ai',false,{
|
|
||||||
target:player
|
|
||||||
})) return false;
|
})) return false;
|
||||||
return true;
|
return true;
|
||||||
},
|
},
|
||||||
|
|
|
@ -20128,8 +20128,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
if(!arg||!arg.player) return true;
|
if(!arg||!arg.player) return true;
|
||||||
if(arg.player.hasSkillTag('unequip',false,{
|
if(arg.player.hasSkillTag('unequip',false,{
|
||||||
target:player
|
target:player
|
||||||
})||arg.player.hasSkillTag('unequip_ai',false,{
|
|
||||||
target:player
|
|
||||||
})) return false;
|
})) return false;
|
||||||
return true;
|
return true;
|
||||||
},
|
},
|
||||||
|
|
|
@ -2295,7 +2295,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
||||||
return get.distance(player,current)>1;
|
return get.distance(player,current)>1;
|
||||||
})) return false;
|
})) return false;
|
||||||
if(tag=='directHit_ai') return arg.card.name=='sha';
|
if(tag=='directHit_ai') return arg.card.name=='sha';
|
||||||
if(arg.card.name!='sha'&&arg.card.name!='chuqibuyi') return false;
|
if(!arg||!arg.card||arg.card.name!='sha'&&arg.card.name!='chuqibuyi') return false;
|
||||||
var card=arg.target.getEquip(2);
|
var card=arg.target.getEquip(2);
|
||||||
if(card&&card.name.indexOf('bagua')!=-1) return true;
|
if(card&&card.name.indexOf('bagua')!=-1) return true;
|
||||||
if(player._xinbenxi_ai) return false;
|
if(player._xinbenxi_ai) return false;
|
||||||
|
|
Loading…
Reference in New Issue