View Single Post
07-01-14, 05:18 AM   #7
Resike
A Pyroguard Emberseer
AddOn Author - Click to view addons
Join Date: Mar 2010
Posts: 1,290
Originally Posted by Phanx View Post
Avoid infinite loops, and "action blocked in combat" errors:

Code:
local moving

hooksecurefunc(CharacterMicroButton, "SetPoint", function(self)
	if moving or InCombatLockdown() then return end
	moving = true
	self:ClearAllPoints()
	self:SetPoint("BOTTOMLEFT", UIParent, "BOTTOMLEFT", 794, 2)
	moving = nil
end)
Actually those frames are not protected so you can freely move them in combat too.
  Reply With Quote