From 76087a8eb9c4aa0e5615ddf3212e2088e63839da Mon Sep 17 00:00:00 2001 From: 157 <3619242020@qq.com> Date: Fri, 5 Apr 2024 22:09:13 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E3=80=90=E5=A4=99=E5=AE=88?= =?UTF-8?q?=E3=80=91=E6=8D=A2=E7=89=8Cai?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- character/xianding.js | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/character/xianding.js b/character/xianding.js index 3493d21cb..3ec41bb40 100644 --- a/character/xianding.js +++ b/character/xianding.js @@ -9529,7 +9529,24 @@ game.import('character',function(lib,game,ui,get,ai,_status){ if(changed2.includes(from.link)) return true; return changed.includes(to.link); }); + next.set('max',Math.min(hs.length,ts.length,player.getDamagedHp())); next.set('processAI',function(list){ + if(_status.event.max){ + let gain=list[0][1].sort((a,b)=>{ + return player.getUseValue(b,null,true)-player.getUseValue(a,null,true); + }).slice(0,_status.event.max),give=list[1][1].sort((a,b)=>{ + return get.value(a,player)-get.value(b,player); + }).slice(0,_status.event.max); + for(let i of gain){ + if(get.value(i,player)