mirror of
https://github.com/parnic/ice-hud.git
synced 2025-06-16 06:40:13 -05:00
- switched from UnitIsInVehicle to Blizzard's method of UnitHasVehicleUI for determining where to get combo points from
- registered ENTERED_VEHICLE and EXITED_VEHICLE events to update the combo points appropriately
This commit is contained in:
@ -172,6 +172,8 @@ function ComboPoints.prototype:Enable(core)
|
||||
self:RegisterEvent("PLAYER_TARGET_CHANGED", "UpdateComboPoints")
|
||||
if IceHUD.WowVer >= 30000 then
|
||||
self:RegisterEvent("UNIT_COMBO_POINTS", "UpdateComboPoints")
|
||||
self:RegisterEvent("UNIT_ENTERED_VEHICLE", "UpdateComboPoints")
|
||||
self:RegisterEvent("UNIT_EXITED_VEHICLE", "UpdateComboPoints")
|
||||
else
|
||||
self:RegisterEvent("PLAYER_COMBO_POINTS", "UpdateComboPoints")
|
||||
end
|
||||
@ -293,7 +295,7 @@ function ComboPoints.prototype:UpdateComboPoints()
|
||||
points = 5
|
||||
elseif IceHUD.WowVer >= 30000 then
|
||||
-- Parnic: apparently some fights have combo points while the player is in a vehicle?
|
||||
local isInVehicle = UnitInVehicle("player")
|
||||
local isInVehicle = UnitHasVehicleUI("player")
|
||||
points = GetComboPoints(isInVehicle and "vehicle" or "player", "target")
|
||||
else
|
||||
points = GetComboPoints("target")
|
||||
|
Reference in New Issue
Block a user