Creating addons in WoW
In the search for relevant and authentic tasks for young programmers, I have been looking at programming addons for World of Warcraft. Addons are used to customise the game's user interface. There are a number of popular addons including CT Raid Assist.
Blizzard warn that creating addons is not easy: "The creation of AddOns is a very technical endeavor, and you should not attempt it unless you have a good working knowledge of XML and Lua " Nevertheless, I was able to easily follow the Hello World tutorial. All I needed was Notepad and of course WoW to test the addon.
Getting Started
Go to http://www.blizzard.com/support/wow/?id=aww01671p and download the World of Warcraft Interface AddOn Kit.
WoW addons are written in Lua and XML. The kit extracts the XML files and Lua files for the addons and the user interface into directories. To see how the WoW interface is programmed, see the user interface directory "FrameXML".
The kit also installs the tutorial files.
Do the Hello World tutorial
Read about WoW Interface Customisation at WoWWiki in particular the API
Addons all have an XML file which describes the visual features of the addon, where more detailed programming is required, functions are called from a Lua file.
Lua
Lua is an extension programming language designed to support general procedural programming with data description facilities. It also offers good support for object-oriented programming, functional programming, and data-driven programming. Lua is intended to be used as a powerful, light-weight scripting language for any program that needs one. Lua is implemented as a library, written in clean C (that is, in the common subset of ANSI C and C++)
Lua is freely available and can be used for both academic and commercial purposes at absolutely no cost. You can experiment with the stand alone version of Lua.
XML
XML stands for EXtensible Markup Language
XML is a markup language much like HTML.
XML was designed to describe data.
XML tags are not predefined in XML.
You must define your own tags.
XML is self describing.
XML uses a DTD (Document Type Definition) to formally describe the data.
Slash Commands
Slash commands such as /sit and /dance can be entered in game in the chat window, two notable ones are /macro and /script
Macros
Slash commands can be put into macros
Scripts
Using the /script command, Lua scripts of API calls can be executed from the game chat window. This can be used to test code fragments immediately, prior to using them in addons.
For example,
/script message("Hello World") will bring up a message box
/script SendWho("gold") will list all players with gold in their name
/script message(GetMoney() ) your held money in copper in a message box
/script message(GetMapInfo()) will display your current location in a message box
/script RandomRoll(10,20) rolls a random number 10<20>
/script OpenAllBags() Open/Close all bags
/script x,y=GetCursorPosition() ; message(string.format("x%d y%d",x,y)) gives cursor position
In Summary
Lua is a powerful open source programming language which can be used to write addons for the World of Warcraft user interface. WoW is a popular MMORPG game with subscription costs of $A20 (US$15) per month. There are currently 7 million subscribers.
For one purchased game, the installation disks can be used to install WoW onto a number of computers though one account would only allow one computer to be online at a time for testing of code. Typically 10% to 50% of an Australian school will be existing WoW account holders. The challenge should be achievable for years 11 and 12.
Blizzard warn that creating addons is not easy: "The creation of AddOns is a very technical endeavor, and you should not attempt it unless you have a good working knowledge of XML and Lua " Nevertheless, I was able to easily follow the Hello World tutorial. All I needed was Notepad and of course WoW to test the addon.
Getting Started
Go to http://www.blizzard.com/support/wow/?id=aww01671p and download the World of Warcraft Interface AddOn Kit.
WoW addons are written in Lua and XML. The kit extracts the XML files and Lua files for the addons and the user interface into directories. To see how the WoW interface is programmed, see the user interface directory "FrameXML".
The kit also installs the tutorial files.
Do the Hello World tutorial
Read about WoW Interface Customisation at WoWWiki in particular the API
Addons all have an XML file which describes the visual features of the addon, where more detailed programming is required, functions are called from a Lua file.
Lua
Lua is an extension programming language designed to support general procedural programming with data description facilities. It also offers good support for object-oriented programming, functional programming, and data-driven programming. Lua is intended to be used as a powerful, light-weight scripting language for any program that needs one. Lua is implemented as a library, written in clean C (that is, in the common subset of ANSI C and C++)
Lua is freely available and can be used for both academic and commercial purposes at absolutely no cost. You can experiment with the stand alone version of Lua.
XML
XML stands for EXtensible Markup Language
XML is a markup language much like HTML.
XML was designed to describe data.
XML tags are not predefined in XML.
You must define your own tags.
XML is self describing.
XML uses a DTD (Document Type Definition) to formally describe the data.
Slash Commands
Slash commands such as /sit and /dance can be entered in game in the chat window, two notable ones are /macro and /script
Macros
Slash commands can be put into macros
Scripts
Using the /script command, Lua scripts of API calls can be executed from the game chat window. This can be used to test code fragments immediately, prior to using them in addons.
For example,
/script message("Hello World") will bring up a message box
/script SendWho("gold") will list all players with gold in their name
/script message(GetMoney() ) your held money in copper in a message box
/script message(GetMapInfo()) will display your current location in a message box
/script RandomRoll(10,20) rolls a random number 10
/script OpenAllBags() Open/Close all bags
/script x,y=GetCursorPosition() ; message(string.format("x%d y%d",x,y)) gives cursor position
In Summary
Lua is a powerful open source programming language which can be used to write addons for the World of Warcraft user interface. WoW is a popular MMORPG game with subscription costs of $A20 (US$15) per month. There are currently 7 million subscribers.
For one purchased game, the installation disks can be used to install WoW onto a number of computers though one account would only allow one computer to be online at a time for testing of code. Typically 10% to 50% of an Australian school will be existing WoW account holders. The challenge should be achievable for years 11 and 12.
Labels: WoW
5 Comments:
Hey blog readers, here’s an article I wrote on WOW, mainly on the Burning Crusade – hope you’ll find it interesting:
Almost 8 million World of Warcraft players around the world have been waiting for the release of the extension pack named The Burning Crusade. The WOW community was very excited to enter the new territories imagined and created for them by the ingenious Blizzard team. This extension brought to light two new races with new starting areas and quests, new dungeons, jewel crafting: the newest trade profession, PVP arenas and new battlegrounds. The big majority of WOW fans were very impressed of Blizzard's work.
The newest two races mentioned above are the "draenei" and the "blood elves" and they are great to start playing with all over again and no doubt new players will find the way up to level 70 very exciting.
The new territories look fantastic and the quests you have to pass in order to level up are very interesting. Many players' reviews agree that blood elves are more popular than the draenei and this fact can be easily explained. The Horde was never given the chance to play a good looking character until now while most Alliance characters are looking good and are physically attractive. Horde's characters are all looking funny; after all they don't have anything human in their look, but they have great jokes and it is a real pleasure to play as a troll, undead, orc or tauren.
Another important aspect to mention is that Horde was finally given the chance to play as paladin with blood elves. Blizzard balanced the two new classes by allowing draenei to play as shamans. However chances for the two new classes to interact with their neighbors are low while they are leveling up. The new classes will probably experience trouble in finding trainers and even some quest givers. The new profession, jewel crafting can be really profitable, especially when combined with mining.
The flying mount was something new for WOW players, but many reviewers agreed that flying mounts are cheap indeed but very slow, even slower than a non epic mount. The epic flying mount is fast and crucial for some quests and territories but it's a bit expensive to some players. However, camping in the new territories can be a real pleasure because the player is now able to raise more gold in a shorter time span than before and also has great chances to loot precious items they needs or they can sell in auction houses.
Patches are regularly released in order to improve the balance and the quality of the game. In addition Blizzard performs weekly server maintenance so they can prevent game bugs, account break in or other problems related to the technical support of the game engine. Game masters are always online and they solve players' problems very fast and in a professional manner. The Burning Crusade can be considered a great new real-time game and also the valuable proof that WOW was and still is an unique PC game that fascinated millions of people around the globe.
Michael
For more PC games cheats and downloads and Anarchy Online: Alien Invasion cheats and Armies of Exigo maps please visit my blog.
Hi there, I was led to this blog while searching for a way to create and export variables to XML files through Lua. I am doing this to make a 'WoW Bot' purely for educational purposes. To get the x,y coodinates etc I had to make my own WoW addon. I think this is a good guide for beginners. I am only in year9 myself.
Check out my progress at my website, http://www.gnollman.com
Thanks,
-Gnoll
i downloaded the addon kit and downloaded the interface and art now what doi do
hey im wondering if i can use the WOw addon studio to make an addon that allows me to run another prog while in wow, much like their "Bejewled" or "peggle" addons. how do i link a .exe file to run in my addon window or can i?
Sorry Cjmapope
Long time since I looked at this
good luck though.
Post a Comment
<< Home