Hmm, you're right, that won't work at all. You'll just need to hook it once like you were doing:
Code:
hooksecurefunc('ActionButton_Update', function(self)
for _, icon in pairs({
self:GetName(),
'MultiCastRecallSpellButton',
'MultiCastSummonSpellButton',
}) do
local macroname = _G[self:GetName()..'Name']
if (db.HideMacronames) then
macroname:SetAlpha(0)
end
end
end)
And reload the UI to apply the changes. Hooking it again in UpdateStuff won't do anything.