So Zork wrote a cool addon "
rObjectiveTrackerMover"
The problem is me and another guy are having a bug where the ObjectiveTracker jumps in combat around. Weirdly, its not in every combat, I feel like its random, I couldn't figure how I recreate the problem.
Zork said he had problems before, he said it was fixed but the Issue is still sometimes occurring so I wanted to ask this smart forum.
This is basicly the important part of the code, I think
Lua Code:
local function AdjustSetPoint(self,...)
local a1,af,a2,x,y = ...
if a1 and af == "MinimapCluster" and y ~= cfg.y then
if InCombatLockdown() then
self:SetPoint(a1,af,a2,x,cfg.y)
else
frame.point = {a1,af,a2,x,cfg.y}
frame:RegisterEvent("PLAYER_REGEN_ENABLED")
end
end
end
frame:SetScript("OnEvent", function(self,event)
self:UnregisterEvent(event)
if event == "PLAYER_LOGIN" then
self.point = {ObjectiveTrackerFrame:GetPoint()}
hooksecurefunc(ObjectiveTrackerFrame, "SetPoint", AdjustSetPoint)
end
if InCombatLockdown() then
ObjectiveTrackerFrame:SetPoint(unpack(self.point))
end
end)
I think the problem is something with "If InCombatLockdown()" so my question is, how do I fix this bug of the ObjectiveTracker moving back to its position in Combat.