Hi,
I am fed up of having to change the Macro Icon index's every time there is an update. Is there a way to either get the Index of an icon texture or create a macro using an icon texture instead of an index?
Example
Code:
local numIcons = GetNumMacroIcons();
local iconTexture = GetMacroIconInfo(1);
DEFAULT_CHAT_FRAME:AddMessage(iconTexture);
Result
Displays Interface\Icons\INV_Misc_QuestionMark in the default chat frame.
Is there a way to do that in reverse? E.g.
Code:
local numIcons = GetNumMacroIcons();
local iconIndex= GetMacroIconIndex("Interface\Icons\INV_Misc_QuestionMark");
DEFAULT_CHAT_FRAME:AddMessage(iconIndex);
Result
Displays 1 in the default chat frame.
OR
Code:
CreateMacro("MyMacro", "Interface\Icons\INV_Misc_QuestionMark", "Macro Text/Code", nil, 1);
If I can find the index for a texture or create a macro using the texture instead of the index, I wouldn't have to keep counting the macro icons to find out what the index has increased by.
Hope this makes sense.
Thanks in advance,
Felankor