Hydra-Mods / HydraUI

HydraUI is an interface replacement for World of Warcraft
https://www.curseforge.com/wow/addons/hydraui
21 stars 11 forks source link

Classic Era Vehicle Seat indicator with latest HydraUI Version #101

Closed Kewlie closed 1 year ago

Kewlie commented 1 year ago

Hi Hydra,

since the last update that was pushed to curse people playing on classic era have found that the vehicleseat indicator was causing issues and failing to load other HydraUI elements

i have come up with a temporary fix that seems to work for those playing on classic era via adding if classic then not to load that segment of script

starting on line 147 hydraui/elements/general.lua and replacing to the end of file with

`if HydraUI.IsClassic then return else

local SeatIndicator = HydraUI:NewModule("Vehicle Seats")

local SetSeatIndicatorPosition = function(self, anchor, parent) if (parent ~= SeatIndicator) then self:ClearAllPoints() self:SetPoint("CENTER", SeatIndicator, 0, 0) end end

function SeatIndicator:Load() local Anchor, Parent, Anchor2, X, Y = VehicleSeatIndicator:GetPoint()

self:SetSize(VehicleSeatIndicator:GetSize())
--self:SetPoint("CENTER", VehicleSeatIndicator, -360, 10)
self:SetPoint(Anchor, Parent, Anchor2, X, Y)

VehicleSeatIndicator:SetScript("OnShow", nil)
VehicleSeatIndicator:SetScript("OnHide", nil)
hooksecurefunc(VehicleSeatIndicator, "SetPoint", SetSeatIndicatorPosition)

HydraUI:CreateMover(self)

end end`

as stated this is a temp fix as im unsure if the classic era client has "vehicle seats" therefore needing the indicator panel

Hydra-Mods commented 1 year ago

Thanks for the report as always, 2.03 fixes this issue