From 6198cdc9a7fb51defc11eca82ae763e2b68994e0 Mon Sep 17 00:00:00 2001 From: Meow <30401521+me0wg4ming@users.noreply.github.com> Date: Mon, 12 Jan 2026 07:01:15 +0100 Subject: [PATCH] unitxp size reduce unitxp size reduce --- modules/unitxp.lua | 68 ++-------------------------------------------- 1 file changed, 2 insertions(+), 66 deletions(-) diff --git a/modules/unitxp.lua b/modules/unitxp.lua index bc9b1833..a4d240b7 100644 --- a/modules/unitxp.lua +++ b/modules/unitxp.lua @@ -1,5 +1,5 @@ -- UnitXP_SP3 integration module --- Provides Line of Sight indicator, OS notifications, and enhanced targeting +-- Provides Line of Sight indicator, OS notifications, and enhanced distance API -- Requires UnitXP_SP3 DLL: https://github.com/allfoxwy/UnitXP_SP3 pfUI:RegisterModule("unitxp", "vanilla", function () @@ -148,32 +148,6 @@ pfUI:RegisterModule("unitxp", "vanilla", function () return nil end - -- Smart Targeting Helpers - pfUI.api.TargetNearestEnemy = function() - local success, found = pcall(UnitXP, "target", "nearestEnemy") - return success and found - end - - pfUI.api.TargetHighestHP = function() - local success, found = pcall(UnitXP, "target", "mostHP") - return success and found - end - - pfUI.api.TargetNextEnemy = function() - local success, found = pcall(UnitXP, "target", "nextEnemyInCycle") - return success and found - end - - pfUI.api.TargetPreviousEnemy = function() - local success, found = pcall(UnitXP, "target", "previousEnemyInCycle") - return success and found - end - - pfUI.api.TargetNextMarked = function(order) - local success, found = pcall(UnitXP, "target", "nextMarkedEnemyInCycle", order) - return success and found - end - pfUI.api.UnitInLineOfSight = function(unit1, unit2) if not unit2 then unit2 = unit1 @@ -193,42 +167,4 @@ pfUI:RegisterModule("unitxp", "vanilla", function () if success then return behind end return nil end - - -- Debug command to test UnitXP indicators - SLASH_PFUNITXP1 = "/pfunitxp" - SlashCmdList["PFUNITXP"] = function() - local chat = DEFAULT_CHAT_FRAME - chat:AddMessage("|cff33ffccpfUI|r: UnitXP Indicator Debug") - - -- Check if target exists - if not UnitExists("target") then - chat:AddMessage(" |cffff0000No target selected|r") - return - end - - -- Test behind - local successB, behind = pcall(UnitXP, "behind", "player", "target") - chat:AddMessage(" Behind check: success=" .. tostring(successB) .. " value=" .. tostring(behind) .. " type=" .. type(behind)) - - -- Test LOS - local successL, inSight = pcall(UnitXP, "inSight", "player", "target") - chat:AddMessage(" LOS check: success=" .. tostring(successL) .. " value=" .. tostring(inSight) .. " type=" .. type(inSight)) - - -- Check if indicator frames exist - if pfUI.uf and pfUI.uf.target then - chat:AddMessage(" Target frame: |cff00ff00exists|r") - if pfUI.uf.target.behindIndicator then - chat:AddMessage(" Behind indicator: |cff00ff00created|r, visible=" .. tostring(pfUI.uf.target.behindIndicator:IsVisible())) - else - chat:AddMessage(" Behind indicator: |cffff0000NOT created|r (check settings)") - end - if pfUI.uf.target.losIndicator then - chat:AddMessage(" LOS indicator: |cff00ff00created|r") - else - chat:AddMessage(" LOS indicator: |cffff0000NOT created|r (check settings)") - end - else - chat:AddMessage(" Target frame: |cffff0000NOT found|r") - end - end -end) +end) \ No newline at end of file