Commit 26c362d7 authored by Ivaria's avatar Ivaria
Browse files

Added workaround for bug in Blizzard API UnitPhaseReason

parent 3b85049c
## Interface: 90002
## Title: VuhDo ['vu:du:]
## Author: Iza@Gilneas, humfras, Ivaria@Hyjal
## Version: 3.120
## Version: 3.121
## Notes: Raid Frames providing click-heal functionality, buff and debuff control, main tank management and much more
## SavedVariablesPerCharacter: VUHDO_CONFIG, VUHDO_PANEL_SETUP, VUHDO_SPELL_ASSIGNMENTS, VUHDO_HOSTILE_SPELL_ASSIGNMENTS, VUHDO_MM_SETTINGS, VUHDO_PLAYER_TARGETS, VUHDO_MAINTANK_NAMES, VUHDO_BUFF_SETTINGS, VUHDO_POWER_TYPE_COLORS, VUHDO_SPELLS_KEYBOARD, VUHDO_SPELL_CONFIG, VUHDO_BUFF_ORDER, VUHDO_SPEC_LAYOUTS, VUHDO_GROUP_SIZE, VUHDO_RAID, VUHDO_INDICATOR_CONFIG
## SavedVariables: VUHDO_DEFAULT_LAYOUT, VUHDO_DEFAULT_PROFILE, VUHDO_PROFILES, VUHDO_MANUAL_ROLES, VUHDO_SPELL_LAYOUTS, VUHDO_USER_CLASS_COLORS, VUHDO_DEBUFF_BLACKLIST, VUHDO_BOUQUETS, VUHDO_COMBAT_LOG_TRACE, VUHDO_GLOBAL_CONFIG, VUHDO_DEBUG
......
......@@ -192,7 +192,7 @@ end
--
local function VUHDO_isPhasedValidator(anInfo, _)
if UnitPhaseReason(anInfo["unit"]) then
if VUHDO_unitPhaseReason(anInfo["unit"]) then
return true, "Interface\\TargetingFrame\\UI-PhasingIcon",
-1, -1, -1, nil, nil, 0.15625, 0.84375, 0.15625, 0.84375;
else
......@@ -205,7 +205,7 @@ end
--
local function VUHDO_isWarModePhasedValidator(anInfo, _)
local tPhaseReason = UnitPhaseReason(anInfo["unit"]);
local tPhaseReason = VUHDO_unitPhaseReason(anInfo["unit"]);
if tPhaseReason and tPhaseReason == Enum.PhaseReason.WarMode then
return true, "Interface\\TargetingFrame\\UI-PhasingIcon",
......
......@@ -1090,7 +1090,7 @@ local function VUHDO_updateAllRange()
end
-- Check if unit is phased
if UnitPhaseReason(tUnit) then
if VUHDO_unitPhaseReason(tUnit) then
tIsInRange = false;
else
-- Check if unit is in range
......
## Interface: 90002
## Title: VuhDo ['vu:du:] - Options
## Author: Iza@Gilneas, humfras, Ivaria@Hyjal
## Version: 3.120
## Version: 3.121
## Notes: VuhDo Options
## SavedVariables: VUHDO_OPTIONS_SETTINGS
## SavedVariablesPerCharacter: VUHDO_GLOBAL_ICONS, VUHDO_GI_SCAN_IDX
......
......@@ -280,13 +280,32 @@ local VUHDO_isTargetInRange = VUHDO_isTargetInRange;
-- FIXME: workaround for Blizzard API bug: https://github.com/Stanzilla/WoWUIBugs/issues/49
function VUHDO_unitPhaseReason(aUnit)
if not aUnit then
return nil;
end
local tPhaseReason = UnitPhaseReason(aUnit);
if (tPhaseReason == Enum.PhaseReason.WarMode or tPhaseReason == Enum.PhaseReason.ChromieTime) and UnitIsVisible(aUnit) then
return nil;
else
return tPhaseReason;
end
end
-- returns whether or not a unit is in range
function VUHDO_isInRange(aUnit)
if "player" == aUnit then
return true;
elseif VUHDO_isSpecialUnit(aUnit) then
return VUHDO_isTargetInRange(aUnit);
elseif UnitPhaseReason(aUnit) then
elseif VUHDO_unitPhaseReason(aUnit) then
return false;
elseif (sIsGuessRange) then
return UnitInRange(aUnit);
......
Version 3.121
Known issues:
-- Shadowlands stat squish cleanup still a work in progress
-- AOE Advice spell equations need complete overhaul
-- Some text providers need changes to better display small numbers
-- Debuff tooltips are currently bugged when using ElvUI
-- Deselect 'VuhDo Options > Panels > Tooltips > Tooltips > Debuffs'
Bugfixes:
-- Added workaround for bug in Blizzard API UnitPhaseReason
Improvements:
--------------------------------------------------------------
Version 3.120
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment