From f6d0cf7ba141499007b0b1eebeacfea3eb18f508 Mon Sep 17 00:00:00 2001 From: Meow <30401521+me0wg4ming@users.noreply.github.com> Date: Sat, 21 Mar 2026 13:31:01 +0100 Subject: [PATCH] added a 100fps throttle for nameplates internally --- modules/nameplates.lua | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/modules/nameplates.lua b/modules/nameplates.lua index 6a750af6..e1c93817 100644 --- a/modules/nameplates.lua +++ b/modules/nameplates.lua @@ -574,8 +574,13 @@ nameplates:RegisterEvent("ZONE_CHANGED_NEW_AREA") end) nameplates:SetScript("OnUpdate", function() + -- PERF: Throttle central OnUpdate to ~100 FPS (0.01s) + local now = GetTime() + if (this.frameTick or 0) + 0.01 > now then return end + this.frameTick = now + -- PERF: Cache GetTime() once per frame - frameState.now = GetTime() + frameState.now = now frameState.hasTarget, frameState.targetGuid = UnitExists("target") frameState.hasMouseover = UnitExists("mouseover")