mirror of
https://github.com/parnic/LibDogTag-Unit-3.0.git
synced 2025-06-16 21:41:53 -05:00
More Classic updates
Changed wow_classic checks to use the WOW_PROJECT_CLASSIC constant instead of interface version checks. Fixed GetQuestDifficultyColor errors in Classic. Fixed user-reported UnitHasVehicleUI errors in Combos tag.
This commit is contained in:
@ -20,7 +20,7 @@ local UnitGUID = UnitGUID
|
||||
local IsNormalUnit = DogTag.IsNormalUnit
|
||||
|
||||
local wow_ver = select(4, GetBuildInfo())
|
||||
local wow_classic = wow_ver < 20000 and wow_ver > 11300
|
||||
local wow_classic = WOW_PROJECT_ID == WOW_PROJECT_CLASSIC
|
||||
local wow_800 = wow_ver >= 80000
|
||||
|
||||
local playerGuid = nil
|
||||
|
@ -21,8 +21,9 @@ local L = DogTag_Unit.L
|
||||
local wow_320 = select(4, GetBuildInfo()) >= 30200
|
||||
local wow_700 = select(4, GetBuildInfo()) >= 70000
|
||||
local wow_800 = select(4, GetBuildInfo()) >= 80000
|
||||
local wow_classic = WOW_PROJECT_ID == WOW_PROJECT_CLASSIC
|
||||
local GetQuestDifficultyColor
|
||||
if not wow_320 then
|
||||
if not wow_320 and not wow_classic then
|
||||
GetQuestDifficultyColor = _G.GetDifficultyColor
|
||||
else
|
||||
GetQuestDifficultyColor = _G.GetQuestDifficultyColor
|
||||
@ -551,7 +552,7 @@ DogTag:AddTag("Unit", "HostileColor", {
|
||||
-- either enemy or friend, no violence
|
||||
r, g, b = unpack(DogTag.__colors.civilian)
|
||||
end
|
||||
elseif (not wow_700 and UnitIsTapped(unit) and not UnitIsTappedByPlayer(unit)) or (wow_700 and UnitIsTapDenied(unit)) or UnitIsDead(unit) then
|
||||
elseif (not wow_700 and not wow_classic and UnitIsTapped(unit) and not UnitIsTappedByPlayer(unit)) or ((wow_700 or wow_classic) and UnitIsTapDenied(unit)) or UnitIsDead(unit) then
|
||||
r, g, b = unpack(DogTag.__colors.tapped)
|
||||
else
|
||||
local reaction = UnitReaction(unit, "player")
|
||||
|
@ -26,9 +26,9 @@ DogTag:AddTag("Unit", "Combos", {
|
||||
end
|
||||
else
|
||||
if wow_600 then
|
||||
return UnitPower(UnitHasVehicleUI("player") and "vehicle" or "player", 4)
|
||||
return UnitPower((UnitHasVehicleUI and UnitHasVehicleUI("player")) and "vehicle" or "player", 4)
|
||||
else
|
||||
return GetComboPoints(UnitHasVehicleUI("player") and "vehicle" or "player", "target")
|
||||
return GetComboPoints((UnitHasVehicleUI and UnitHasVehicleUI("player")) and "vehicle" or "player", "target")
|
||||
end
|
||||
end
|
||||
end,
|
||||
|
@ -26,7 +26,7 @@ local deadTimes = {}
|
||||
|
||||
-- Parnic: support for cataclysm; Divine Intervention was removed
|
||||
local wow_ver = select(4, GetBuildInfo())
|
||||
local wow_classic = wow_ver < 20000 and wow_ver > 11300
|
||||
local wow_classic = WOW_PROJECT_ID == WOW_PROJECT_CLASSIC
|
||||
local wow_400 = wow_ver >= 40000
|
||||
local wow_500 = wow_ver >= 50000
|
||||
local wow_600 = wow_ver >= 60000
|
||||
|
Reference in New Issue
Block a user