Having trouble with an addon? These guides may help:
- How to install addons
- WoWInterface’s guide to installing addons, with pictures!
- Quickly troubleshoot an addon problem
- How figure out what’s wrong with an addon and write a good bug report.
- Turn any code into an addon
- Perfect for code snippets you find on forums!
Thinking about writing your first addon? Check these pages to make sure your idea is possible and allowed before you invest too much time in it:
- Things addons and macros can’t do
- List of things that aren’t technically possible within the WoW UI addon system.
- Blizzard’s official addon policy
- List of things you’re not allowed to do with an addon, like charge money for it, advertise anything or ask for donations in-game, or spam other players.
Lua is the Portuguese word for “moon” (it’s not an acronym or initialism) and the name of the programming language in which the WoW UI and addons are written. Here are some resources to help you learn about Lua syntax and functions:
- Lua Users Wiki
- Wiki with general Lua information, tips, ideas, and code snippets.
- Programming in Lua
- Introduction and general guide to the Lua programming language.
- Lua 5.1 Reference Manual
- Reference manual for the Lua programming language.
- WoWInterface’s Lua/XML Help forum
- The WoWInterface community is very active. I read almost every post there, and respond to many posts.
- Blizzard UI source code
- You can also get a local copy from your game client.
- Wowpedia’s Interface Customization portal
- Community-powered wiki with tons of great resources, including detailed references for:
- WoW Programming
- Companion to the “World of Warcraft Programming” book, with lots of resources, including:
This is a list mostly of forum posts that offer how-to guides or good explanations of tricky API functions and Lua concepts. It is mirrored on the WoWInterface forums.
Common questions and misconceptions
General tips and tricks
- General addon optimization tips
- Q&A on different ways to access globals, upvaluing, etc.
- How upvalues (local copies of global functions) work
- Speed tests for globals vs. locals (including upvalues)
- Old "coding tips" page on WowAce — mostly still relevant, but everything about Ace2 is obsolete, and a lot of the discussions are also obsolete
Localizing your addon means making sure that your addon works in different languages and regions. A bit part of this is translation: identifying all of the text it shows to users, getting translations for each string (or piece) of text, and adding code so your addon will show the right text depending on what language the user is playing WoW in.
However, localization also means avoiding dependence on translations, so your addon will work in a French client even if nobody has translated it into French yet. For example, rather than detecting classes, spells, items, and map zones by their name, use their ID numbers instead, since those don't change between languages.
It’s usually a good idea to localize your addon from the beginning. Often, someone who plays in another language will translate it for you, and send you the translations to include in your next version so that other players in their country or region can enjoy your addon too. You can also add a note to your addon’s download page asking for help with translations for specific languages, or make a forum post. Some languages have strong addon communities whose members actively look for addons to translate.
Finally, you can often just use Google Translate for single words and short phrases. Even if the translations aren’t perfect, they’re probably better than no translations at all, and may encourage users of that language to contact you with corrections. However, it’s usually a bad idea to try to use Google for complex sentences, like this one, since the result may not actually make any sense to readers of the target language!
- How to localize an addon
- If you’re lazy or in a hurry, you can just copy and paste some code, but if you have time, you should read through the explanation to learn how the code works.
- GlobalStrings.lua files for all locales
- The GlobalStrings.lua file contains Blizzard’s translations for the default UI. These are particularly helpful when you need to know how to refer to game mechanics and UI features in other languages.
- Looking at the tooltip text for spells, items, and other things can be helpful when you need to know how to refer to game mechanics in other languages, or when designing Lua patterns for use in tooltip scanning. To switch languages on Wowhead, use the dropdown in the top right corner of the page.