修复桃不够依旧救人的ai问题

This commit is contained in:
157 2024-03-28 11:00:17 +08:00
parent 612d0231b3
commit 1aeb2cd227
1 changed files with 5 additions and 5 deletions

View File

@ -469,13 +469,13 @@ game.import('card',function(lib,game,ui,get,ai,_status){
return 2; return 2;
}, },
target_use:(player,target,card)=>{ target_use:(player,target,card)=>{
if(!player.isPhaseUsing()||player.hasSkillTag('nokeep',true,{ let mode = get.mode(),
taos = player.getCards('hs',i=>get.name(i)==='tao'&&lib.filter.cardEnabled(i,target,'forceEnable'));
if(target!==_status.event.dying){
if(!player.isPhaseUsing() || player.hasSkillTag('nokeep',true,{
card:card, card:card,
target:target target:target
},true)) return 2; },true)) return 2;
let mode = get.mode(),
taos = player.getCards('hs',i=>get.name(i)==='tao'&&lib.filter.cardEnabled(i,target,'forceEnable'));
if(target.hp>0){
let min = 7.2-4*player.hp/player.maxHp, let min = 7.2-4*player.hp/player.maxHp,
nd = player.needsToDiscard(0,(i,player)=>{ nd = player.needsToDiscard(0,(i,player)=>{
return !player.canIgnoreHandcard(i)&&(taos.includes(i)||get.value(i)>=min); return !player.canIgnoreHandcard(i)&&(taos.includes(i)||get.value(i)>=min);