OmniBar

OmniBar

16M Downloads

Tracking casts from party when being mind controlled (I set "Track All Enemies so it's not supposed to track party members)

SweepyBoop opened this issue ยท 1 comments

commented

This happens every time, I set unit to "Track All Enemies", but in arena if I get mind controlled, and my mage counterspells that mind game, my omnibar shows a counterspell icon.

commented

This function doesn't seem to count the case where the player themselves are mind controlled.

local function UnitIsHostile(unit)
if (not unit) then return end
if UnitIsUnit("player", unit) then return end
local reaction = UnitReaction("player", unit)
if (not reaction) then return end -- out of range
return UnitIsPlayer(unit) and reaction < 4 and (not UnitIsPossessed(unit))
end

The sourceGUID version IsSourceHostile seems to count that in