Friday, February 20, 2009

In Case You Find This Useful

Kathy was on me to put my addon up on Curse. So I did. It’s at There is a bug with the release version that’s posted that I can’t fix until I get home tonight, so if you want to check it out, do that tomorrow.

One Down, 15 To Go

I just completed my first week of the “20/20 Lifestyles” weight management program. For the first week, my diet was restricted to meal replacement shakes (sold by them, ‘natch), berries, and very lean protein. I was really glad to finish that first week and get to add some vegetables back into my diet.

The good news is that I lost 7 1/2 pounds that first week. Woo hoo! Go me!

Tuesday, February 17, 2009

Monday, February 16, 2009

Weight Loss Program Woes

So I’m on this weightloss program for (counts on his fingers) four days now; nothing but meal replacement shakes and lean protein. When do I get to go back to Fatburger? I’m dying here.

World of Warcraft addon development is teh suXor

I’m leveling up a whole passel of toons. Six of them to be exact, and many of them have skinning as a profession. You can’t skin a corpse until you have looted it. Put those two together and you get “inventory is full”. A lot.

So I started writing an addon to notice when my bags filled up and destroy the cheapest grey item in my bag to make room for the new crappy loot item. When it was just that (find the single cheapest thing and get rid of it), it was all easy: just a bit of Lua code and Bob’s your uncle. Then I ran into the situation where I needed to loot two things before I could skin the mob. My addon destroyed the first item okay, but I was irked that I had to manually run the addon again to make room for the second crappy loot.

My friend SeanK suggested I open a window with some number of crappy grey items so I could easily click-to-destroy several of them at once. “No problem” I thought, and continued to think that right up until I actually tried to write the damned thing.

The documentation for the API is okay, such as it is, at WoWWiki. Blizzard of course doesn’t publish the API docs although I’m completely sure they have docs. But at least somebody is publishing something.

The big pain is the actual UI work. The UI is written in their FrameXML dialect (rather like XAML except really really poorly documented). The only saving grace was you can download a tool from Blizzard to extract all of the Blizzard-authored UI crap so you can see how they did it because really that’s all the docs they’re willing to share. Hmph.

The second big fly in the ointment is when you try to test the code. Lua errors in-game pop up a nice debugger window with stack traces and everything (from the !Swatter package, I think .. some addon I got as part of some other addon I wanted). But XML errors and your addon silently vanishes. Nothing. Nada.

And is there a schema file so you can validate your XML? Well, there’s a local copy embedded into the game files that you can extract via the Blizzard download tool, but why in the world does anybody do XML development environments without putting their schemata online at the URI where their namespace lives? Seriously … are you short the bandwidth or something?


Anyway, I finally got a release candidate after about two hours of honest effort embedded over two days of full-time cursing/researching/ReloadUI() iteration. Man, I wish we (MSFT) would take on addon development seriously because we would put out some serious motherf*@#!ing tools because THAT’S THE MICROSOFT WAY.