Thread Tools Display Modes
Prev Previous Post   Next Post Next
08-05-22, 03:50 AM   #1
cozmos
A Murloc Raider
Join Date: Mar 2007
Posts: 8
Load variables at Client start

Hello,

im trying to set some variables at wow start to change the position of some ui elements but I´m experiencing some serious lags when using.

I´m modifying the buffframe so I think everytime a new buff is applied the client uses the variable from the addon which causes the lag.

Is there a way to set the varaibles without the client using the addon? Or am I just bad at coding?
Which I actually am

The Addon looks like this:

Code:
                BuffFrame:SetScale(1.5);
		TemporaryEnchantFrame:SetScale(1.5);
		
		local cap = ZoneAbilityFrame.ClearAllPoints
                local sp = ZoneAbilityFrame.SetPoint
            hooksecurefunc(ZoneAbilityFrame, "SetPoint", function(self)
            cap(self)
            sp(self, "BOTTOM", UIParent, "BOTTOM", 0, 90)
        end)
		ZoneAbilityFrame:SetScale(1.3);
		ZoneAbilityFrame.Style:SetAlpha(0)
		ZoneAbilityFrame.Style:Hide()
		
		DurabilityFrame:Hide();
		
		local cap = VehicleSeatIndicator.ClearAllPoints
        local sp = VehicleSeatIndicator.SetPoint
        hooksecurefunc(VehicleSeatIndicator, "SetPoint", function(self)
            cap(self)
            sp(self, "TOPRIGHT", Minimap, "BOTTOMLEFT", -30, -10)
        end)

SlashCmdList['RELOADUI'] = function() ReloadUI() end
	SLASH_RELOADUI1 = '/rl'

SlashCmdList["READYCHECK"] = function() DoReadyCheck() end
	SLASH_READYCHECK1 = '/rc'

SlashCmdList["CHECKROLE"] = function() InitiateRolePoll() end
	SLASH_CHECKROLE1 = '/cr'

print("|cFF0048ffButler|r - It aint much but its honest work")
  Reply With Quote
 

WoWInterface » AddOns, Compilations, Macros » AddOn Help/Support » Load variables at Client start


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off