From 0d993806e636f644e71107da42499b46935113b1 Mon Sep 17 00:00:00 2001 From: shagu Date: Fri, 28 Sep 2018 22:43:57 +0200 Subject: [PATCH] tbc: add initial version of the tbc compat module --- api/tbc.lua | 18 ++++++++++++++++++ pfUI.toc | 1 + 2 files changed, 19 insertions(+) create mode 100644 api/tbc.lua diff --git a/api/tbc.lua b/api/tbc.lua new file mode 100644 index 00000000..41f943f0 --- /dev/null +++ b/api/tbc.lua @@ -0,0 +1,18 @@ +if GetBuildInfo() ~= "2.4.3" then return end + +message("TBC compat module loaded. Good Luck!") + +-- load pfUI environment +setfenv(1, pfUI:GetEnvironment()) + +-- the "MiniMapTrackingFrame" is called "MiniMapTracking" +pfUI.api.MiniMapTrackingFrame = _G.MiniMapTracking + +-- blacklist pfUI functions +pfUI.api.hooksecurefunc = nil +pfUI.api.select = nil + +-- tbc removed the offset of -1 +function pfUI.api.GetPlayerBuff(id, btype) + return _G.GetPlayerBuff(id+1, btype) +end diff --git a/pfUI.toc b/pfUI.toc index d019e043..6617714f 100644 --- a/pfUI.toc +++ b/pfUI.toc @@ -34,6 +34,7 @@ env\profiles.lua # api api\api.lua +api\tbc.lua api\config.lua api\ui-widgets.lua api\unitframes.lua