WoW:API GetNumMacroIcons: Difference between revisions

'i' is inherently local already, don't confuse the reader
(docs)
 
('i' is inherently local already, don't confuse the reader)
Line 8: Line 8:


==Example==
==Example==
  local numIcons, i = GetNumMacroIcons(); -- i will be nil, but we do not really care at this point.
  local numIcons = GetNumMacroIcons()
  for i=1,numIcons do
  for i=1,numIcons do
   DEFAULT_CHAT_FRAME:AddMessage(string.format("Icon %d: %s",i,GetMacroIconInfo(i)));
   DEFAULT_CHAT_FRAME:AddMessage(string.format("Icon %d: %s",i,GetMacroIconInfo(i)));
Anonymous user