« Too Funny | Main | What Is Jorge Up To? »

WoW Combat Log Parser

World of Warcraft is my current gaming addiction. And, of course, I have even more fun when I can combine two things I like...such as gaming and writing code. So I've written a combat log parser for World of Warcraft. It's pretty easy to use. If you play the game, you can start logging your combat information by typing '/combatlog'. This will create a file named PlayerCombatLog.txt in the /Logs subdirectory of your WoW installation directory. My parser is browser-based, so you just need to put the name of the file in the edit box and hit the Parse button.

There are a couple of known issues at this time that I am working to resolve, mostly the result of how Blizzard is writing the combat information.

1. Monster names that have a ('s) as part of the name do not get parsed properly. For example, consider the following two lines:

Sneed's Shredder hits you for 74.
Sneed's Frost Bolt hits you for 82.

The format is identical, but in the first line I am getting hit by a monster named Sneed's Shredder, and in the second line I am getting hit by a Frost Bolt cast by a monster named Sneed. It's probably just a matter of arranging the regular expression matches and the lookahead, so I should have that fixed soon.

2. Special attacks are not counted as part of the parsing process. This is because all special attacks by friendly players have the exact same format (e.g., Sneed is afflicted by Rend). It would help if Blizzard added the PC name to this message so I would know which player performed the attack, but since I have no way of knowing, it is impossible for me to get an accurate count.

Here is a screenshot of some sample output.

wowparser.jpg

So, give it a try and let me know what you think.

Comments

Very nice! Can't wait to try it out.
Thanks

Hah Bytor nerding out in a new game!

Kage!

You should come join me, got a few friends playing and we're all spread out over a handful of servers and different levels. Let's see...

Bytor, level 55 dwarf priest on Windrunner.
Jodani, level 18 tauren warrior on Hyjal.
Bytor, level 8 gnome mage on Argent Dawn, lol.

Playing pretty casually for the most part, but I might do some raiding with my priest. You can get to level 10 in like one day.

What else is going on? Was checking out your site, funny pics. HUSE!

this cgi didnt work... browsed, clicked parse then nothing.. Can you make the perl script available for download?? thanks much

I put the perl script and css file up at the following location:

http://www.jorgev.com/wowparse.tar.gz

I haven't updated it in a while, so I may have to tweak it if the log file format has changed.

Nice, but it doesnt seem to report damage done for spell effects. I get a total resist count but thats it.

I'm curious as to whether you ever resolved your problem with apostrophes, since there are both attackers and actual attacks that contain apostrophes. For instance, how can you handle all of the following correctly:

"Sneed's Shredder hits you for 75.",
"Sneed's Shredder's Mortal Strike hits you for 75.",
"Sneed's Shredder's Frostbolt hits you for 75 Frost damage.",
"Sneed's Shredder's Smokey's Lighter hits you for 75 Fire damage."

Worst case might be something like

"Sneed's Shredder's Monkey's Smokey's Lighter hits you for 75 Fire damage."

Honestly, without having some vast lookup of attackers/attacks, I don't think that there is a way to reliably parse all of those correctly.

I haven't resolved that issue yet. It's going to be difficult to fix without doing some kind of lookup, as you suggested, but that would probably require more time and effort that I can dedicate at this time. I plan to spend some time this month trying to resolve any issues with the script, so we'll see if I can find a fix.

If you are going to try to do lookups, don't try to look up attackers and targets, lookup attacks. There will be a much more finite number of attack's. "hit" "mortal strike" "frost bolt", etc.

Still very prickly.