From 716138b5d3f7ad7d35699a4bf005da67da4ab9ae Mon Sep 17 00:00:00 2001 From: Emlembow <36314674+Emlembow@users.noreply.github.com> Date: Sun, 1 Sep 2024 17:26:29 -0700 Subject: [PATCH] More LLM Generated Garbage --- .DS_Store | Bin 6148 -> 6148 bytes BMHunter.lua | 20 ++++++++------------ 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/.DS_Store b/.DS_Store index 26000199749cfd9bece574a6fcec1aaae0827b1d..9b52aca7dff9765a923aadec9f0d8cac9cadff57 100644 GIT binary patch delta 279 zcmZoMXfc=|#>B)qu~2NHo}wrV0|Nsi1A_nqLmop3Ln=cNgC0Z9=7)^S88tytJPb|@ zz6>4=rO47iUSdH>l22)INfA(u&txk``+66Ke1>wMsvIDl$dJNN%%BhCyD(G&$r1)< zplAp~E|8@Ult~6!lgUs3B`mu~2NHo}wrd0|Nsi1A_nqLjXe}Lk{7^ADEA jADEdovvcrs0QGEs$o!poGQWr=2T&JC8`I_hkuA&s6PXg9 diff --git a/BMHunter.lua b/BMHunter.lua index 1982b48..cc2abe2 100644 --- a/BMHunter.lua +++ b/BMHunter.lua @@ -61,14 +61,14 @@ local InterruptTarget = Bastion.UnitManager:CreateCustomUnit('interrupttarget', Bastion.UnitManager:EnumEnemies(function(unit) if unit:IsAffectingCombat() and unit:GetDistance(Player) <= 40 and Player:CanSee(unit) and unit:IsCasting() and unit:IsInterruptible() then - local castPercentage = GetCastPercentage(unit) + local castPercentage = unit:GetChannelOrCastPercentComplete() if castPercentage >= 30 and castPercentage <= 80 then target = unit return true end end end) - return target or BestTarget + return target or Bastion.UnitManager:Get('none') end) local ExecuteTarget = Bastion.UnitManager:CreateCustomUnit('executetarget', function() @@ -355,16 +355,12 @@ PetAPL:AddSpell( -- Interrupt APL InterruptAPL:AddSpell( CounterShot:CastableIf(function(self) - if not BestTarget:Exists() or not self:IsKnownAndUsable() or Player:IsCastingOrChanneling() then - return false - end - - if BestTarget:IsCasting() and BestTarget:IsInterruptible() then - return ShouldInterrupt(BestTarget) - end - - return false - end):SetTarget(BestTarget) + local target = InterruptTarget + return target:Exists() and self:IsKnownAndUsable() and not Player:IsCastingOrChanneling() + and target:IsCasting() and target:IsInterruptible() + and target:GetChannelOrCastPercentComplete() >= 30 + and target:GetChannelOrCastPercentComplete() <= 80 + end):SetTarget(InterruptTarget) ) -- Defensive APL