Wikia

WoWWiki

WoWBench/FAQ

Talk0
101,292pages on
this wiki

< WoWBench

Feel free to add a question of your own!

WoWBench Frequently Asked Questions Edit

Huh?! Edit

Questionmark But something like 99% of AddOns are UI-based, and WoWBench doesn't have an UI. What's the point?
  • No, using WoWBench to make your graphics look pretty is pointless. But even UI-heavy addons have actual code. Code that can bug. WoWBench helps you fix problems there much faster with its built-in debugging facilities. You can interact with your UI elements with text commands. Read on!
  • Also, if your AddOn works with the "mini" version of FrameXML, FrameXML-lite, reloading is much faster than it is in-game!
  • And even if you're not actively using WoWBench to run your AddOn, you can save time by using its syntax checker mode, "wowbench -x", which checks your Lua and XML files for errors, before doing a full interface reload in-game.


Questionmark Does this really work?
  • Yep! Some AddOns can go from alpha to release only living inside WoWBench. (Well, almost, you probably want to test it in-game, too =)). It all depends on what APIs you use. If they all already exist, you're fine and dandy. If not, you might be in for some API hacking.
  • Even if some APIs are missing, you can probably still use WoWBench to debug bits and pieces of your AddOn. Lua doesn't complain about missing functions until something actually tries to call them!


Questionmark Hey! GetSummonConfirmTimeLeft() isn't implemented!
  • Nope. It's a community project. People mostly chip in by implementing functions that they need, as they need them. You're welcome to do so yourself or put it in the API wish list, no guarantees on when it'll get done though. ;)


Questionmark What about the Widget API?
  • The Widget API is emulated as far as makes sense in a command line environment:
    • It will remember texts set in objects and allow you to Get() them.
    • It understands clicks and mouseovers (via commands) and correctly fires the corresponding widget event handlers
    • It fully understands virtual objects, and the 1.11 simulation understands e.g. the new fourth parameter of API CreateFrame.


Questionmark What about the XML? That's not handled, right?
  • Sure it is. WoWBench parses all the XML in FrameXML as well as in your AddOns. Nothing would work otherwise. The XML parser is probably a lot more lenient than Blizzard's own parser as to what object attributes it will allow, etc, but it does the job!
  • If you want strict XML verification, I suggest you load Blizzard's "UI.xsd" into an XML editor and verify your XML that way.


Questionmark What about the game world?
  • The game world is a bit slim at the moment. You can define objects and units, but you can't do very much with them. You can click them and mouse over them, but e.g. quest gossips, vendor interaction, etc is nowhere to be seen. Combat does not exist. Feel free to contribute :-)
  • One thing you can do is log in several of your characters in unique session with the login command. They can communicate with eachother like characters can in-game.


Installing Edit

Questionmark Can I run it under Linux?
  • Yes. Just get a Lua parser for your platform and you're good to go.


Questionmark I put WoWBench in Interface/Addons but it doesn't work?
  • Please read WoWBench/Installing. WoWBench is not an AddOn. It is as replacement for WoW, that you can run AddOns inside.


Using Edit

Questionmark So, how do I add something that's missing?


Questionmark How do I tweak an already-existing API to work better for my tests?


Questionmark Ok, fine, my AddOn loads and I get a prompt. Now what?
Whatever you want to do.
  • Call functions in your AddOn directly from the prompt:
MyAddOn_DoSomething("someParameter")
  • Make Alice, Bob or Charles (the default player characters) say something:
say Alice Help! Help! The horrible Murloc Warrior is hitting me!
  • Fire an event:
fire DUEL_REQUESTED Charles
  • Run a slash command:
/myaddon dosomething
  • Look at the frame that popped up:
look MyAddOnMainFrame
  • Click a button in it:
click MyAddOnMainFrameIWinButton
And much more :-)


Questionmark How do I run scripts? -Testing needs looots of repetition!
  • You can automatically run wowbench command line scripts by giving names of .txt files on the command line, e.g.:
wowbench MyAddon script.txt
  • You can load and run Lua code on demand from the command prompt (or from inside a script file):
> dofile("myluacode.lua")


Problems Edit

Questionmark I'm getting very weird errors / It seems like some stuff isn't even loading like it should?
  • Try the "-f" switch: lua wowbench.lua -f MyAddOn to force a re-parse of .toc and .xml files in case the dependencies haven't been updated properly. (WoWBench precompiles .xml files into .xml.lua files to speed subsequent loads up.)


Contribute? Edit

Questionmark Community Project? What's the license?
  • WoWBench is released under a BSD-style license, which basically means anyone can do whatever they want with it, but needs to attribute the effort to the "WoWBench developer community" if used anywhere.


Questionmark Cool! How can I contribute?


See also Edit

Around Wikia's network

Random Wiki