update np

This commit is contained in:
Bunny67
2018-07-28 16:10:35 +03:00
parent 093f57000e
commit 6853e1534a
-18
View File
@@ -344,24 +344,6 @@ function mod:UnitLevel(frame)
end
function mod:GetUnitInfo(frame)
if UnitExists("target") == 1 and frame:GetParent():IsShown() and frame:GetParent():GetAlpha() == 1 then
if UnitIsPlayer("target") then
if UnitIsEnemy("target", "player") then
return 2, "ENEMY_PLAYER"
else
return 5, "FRIENDLY_PLAYER"
end
else
if UnitIsEnemy("target", "player") then
return 2, "ENEMY_NPC"
elseif UnitReaction("target", "player") == 4 then
return 4, "ENEMY_NPC"
else
return 5, "FRIENDLY_NPC"
end
end
end
local r, g, b = mod:RoundColors(frame.oldHealthBar:GetStatusBarColor())
if r == 1 and g == 0 and b == 0 then
return 2, "ENEMY_NPC"