fix stack overflow on some ui and syntax errors

This commit is contained in:
Jrc13245
2026-01-10 09:48:18 -05:00
parent d89853396b
commit 5ae45b3406
4 changed files with 53 additions and 13 deletions
+9
View File
@@ -11,17 +11,26 @@ local CleveRoids = _G.CleveRoids or {}
local Extension = CleveRoids.RegisterExtension("XPerl")
Extension.RegisterEvent("ADDON_LOADED", "OnLoad")
-- Re-entrancy guard to prevent stack overflow
local isProcessing = false
-- X-Perl uses XPerl_PlayerTip(unitid) for OnEnter and XPerl_PlayerTipHide() for OnLeave
-- We hook these functions to track mouseover
function Extension.OnEnter(unitid)
if isProcessing then return end
if unitid and unitid ~= "" then
isProcessing = true
CleveRoids.SetMouseoverFrom("xperl", unitid)
isProcessing = false
end
end
function Extension.OnLeave()
if isProcessing then return end
isProcessing = true
CleveRoids.ClearMouseoverFrom("xperl")
isProcessing = false
end
function Extension.OnLoad()