View Single Post
12-04-15, 09:20 PM   #8
SDPhantom
A Pyroguard Emberseer
 
SDPhantom's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 2,313
Originally Posted by Furchee View Post
With your code I do not see a way to call the functions with the xml file though?
The XML file isn't needed since it doesn't create its own frame to run the Lua code. It simply hooks into the original frame that responds to the event and runs itself after that frame is done with its own code. This is what LootFrame:HookScript() is doing. The only thing needed is to reference the Lua file directly from your ToC instead of going through the XML file.

For future reference, you should avoid using XML as it's exceedingly difficult to debug. If something is wrong with your syntax, the entire file fails to load with no notice. There are very few examples where XML is necessary. You can do almost everything using pure Lua.
__________________
WoWInterface AddOns
"All I want is a pretty girl, a decent meal, and the right to shoot lightning at fools."
-Anders (Dragon Age: Origins - Awakening)

Last edited by SDPhantom : 12-04-15 at 09:22 PM.
  Reply With Quote