mirror of
https://github.com/brues-code/pfUI.git
synced 2026-10-22 12:10:48 +00:00
librange: disable target sounds during scan
This commit is contained in:
@@ -90,6 +90,10 @@ local unitcache = {}
|
|||||||
-- actual unit-range table
|
-- actual unit-range table
|
||||||
local unitdata = { }
|
local unitdata = { }
|
||||||
|
|
||||||
|
-- setup sound function switches
|
||||||
|
local SoundOn = PlaySound
|
||||||
|
local SoundOff = function() return end
|
||||||
|
|
||||||
librange.id = 1
|
librange.id = 1
|
||||||
|
|
||||||
librange:Hide()
|
librange:Hide()
|
||||||
@@ -141,11 +145,16 @@ librange:SetScript("OnUpdate", function()
|
|||||||
if TradeFrame and TradeFrame:IsShown() then return nil end
|
if TradeFrame and TradeFrame:IsShown() then return nil end
|
||||||
if PlayerFrame and PlayerFrame.inCombat then return nil end
|
if PlayerFrame and PlayerFrame.inCombat then return nil end
|
||||||
|
|
||||||
|
_G.PlaySound = SoundOff
|
||||||
pfScanActive = true
|
pfScanActive = true
|
||||||
|
|
||||||
TargetUnit(unit)
|
TargetUnit(unit)
|
||||||
unitdata[unit] = IsActionInRange(librange.slot)
|
unitdata[unit] = IsActionInRange(librange.slot)
|
||||||
TargetLastTarget()
|
TargetLastTarget()
|
||||||
|
|
||||||
|
_G.PlaySound = SoundOn
|
||||||
pfScanActive = false
|
pfScanActive = false
|
||||||
|
|
||||||
this:ReAttack()
|
this:ReAttack()
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user