Combat log queries 101
Compiler errors -- where you typoed a constant name or you put a number where the program expects a word or string -- are easy to make and easy to fix. When it comes to knowing the "words" or spelling of a query expression, there's really no substitute for having a dictionary open nearby. Like real-life vocabularies, you'll eventually learn expressions through either memorization or simply by using them all the time. Here's the expression editor list of constants and identifiers
, and you can acquire a dictionary of spells by simply using a good database like Wowhead
On the other hand, logic errors -- e.g., where you put an 'and' when you meant an 'or' -- will still give you results, just not the ones you wanted. The order of operations is really simple: anything within parentheses goes together and then the editor goes in order left to right.
sourceName="Ponerya" and spell="Incinerate"
Using 'and' will tie together attributes and focus down your query results to specific events. This example returns all the times I cast Incinerate
sourceName="Ponerya" or spell="Incinerate"
Using 'or' means you're including a different item or attribute than the previous item. This example returns all the actions I did as well as all the times Incinerate
was cast, whether it was mine or another warlock's.
(sourceName="Ponerya" or sourceName="Rekviem") and spell="Incinerate"
sourceName="Ponerya" and (spell="Incinerate" or spell="Conflagrate")
Much like math, you can write parentheses to group similar chunks together. In the first example, I grouped together warlock names to show all the times either of us cast Incinerate
(but it would leave out all the times a third destruction warlock cast Incinerate). In the second example, I grouped together the spells to show all the times I cast either Incinerate
You can write the code all in one line, but entering a chunk of code on a new line can help you visually separate conceptual components and see if your logic will work as intended.
Now that we have the linguistic basics down, let's see a couple of warlock queries in action.Wreak Havoc with a bouncing Shadowburn
Much like affliction has a glyphed Soul Swap
to copy DoTs to two different targets, destruction has Havoc
to duplicate a filler or Immolate to two different targets.
is the reason for many awesome pictures of double dragons, a sweet trick with Havoc is to "bounce" Shadowburn
onto a healthier target using a second target who is about to die. Since Shadowburn consumes an ember and is only available during the execute range of health (below 20%), it's a powerful hit, often hitting as hard as Chaos Bolt
This trick is applicable in both PvP and PvE, as both often have multiple targets: there's almost always a group of enemy players or the raid boss and his/her minions. All you need are two targets with at least one below 20% health. Since the Havoc
target will be different from the Shadowburn
target, and moving mobs or players can cause difficulties in selecting targets quickly, warlocks often use focus, mouseover, or specific target macros for Havoc
/cast [@focus] Havoc
/cast [@mouseover] Havoc
/cast [tar="Tortos"] Havoc
But let's say you and I already have our Havoc
macros ready and used. We stepped into Throne of Thunder and realized that the fourth encounter
of turtle air hockey would give us plenty of Havoc-bouncing practice.
First, let's find out when I cast Shadowburn.
sourceName="Ponerya" and spell="Shadowburn"
Shadowburn is actually a complex spell: it deals damage and applies a debuff, and then 5 seconds later when the debuff falls off, it returns one of my class resources depending on whether the target died or not. This query result shows when I cast it, what got hit by it, how much damage it dealt, and how much mana I received from it. (Since the Whirl Turtles don't technically die but sit at 1 health point, you'll sadly never get embers from Shadowburning a Whirl Turtle.)
This query also shows all the times Shadowburn damaged the boss, but you won't see a line of me casting Shadowburn specifically on Tortos until the end (when Tortos fell under 20% health). Since I really only care about the Shadowburn and Havoc applications on Tortos, I'm going to focus the query a little more.
sourceName="Ponerya" and targetName="Tortos"
and (spell="Havoc" or spell="Shadowburn")
Havoc has 3 stacks and a 25-second cooldown. If you use Chaos Bolt with Havoc, you consume all three stacks with one Bolt. Everything else you can use with Havoc -- including Shadowburn -- consumes only one stack. So, assuming you time it correctly and have three full embers ready, you can hit Tortos three times with Shadowburn per Havoc application.
The times I remembered to hit Tortos with a Havoc, I never did so three times. Maybe I didn't have the embers? Maybe I wanted to refresh the Immolate on Tortos with Havoc? Maybe I forgot I had Havoc up and I cast Incinerate out of habit? We can expand the query if we want to.
sourceName="Ponerya" and targetName="Tortos"
spell="Havoc" or spell="Shadowburn"
or (fullType=SPELL_AURA_REFRESH and spell="Immolate")
Let's write it in English:
I want things only I cast, but only when the spells hit Tortos, and only these spells -- Shadowburn and also Havoc and also Incinerate and also Conflagrate and also whenever I reapplied Immolate.
From here, you'll get into complex combat logic like realizing that Incinerate has a travel time, so I would see me cast Incinerate twice before the first one even lands. And eventually you'll realize that sometimes the combat log goofs and puts events out of order, especially when multiple events happen within tenths of a second.
But I'm not here today to explain the intricacies of how the combat log interprets combat action. So let's move on to a proc and DoT example in the expression editor.
Tracking stacks with procs and DoTs
An important part of playing affliction is paying attention to gear and raid buff procs so DoT refreshes can be properly timed. But it's hard to tell with the buffs and debuffs graph
exactly whether you applied a DoT when a trinket proc occurred, or if it was just holdover from before the proc. So let's explore with the expression editor how an Agony refresh is timed with that great stacking proc trinket, Wushoolay's Final Choice
. (Since we often reapply DoTs with a Soulburn: Soul Swap
, Unstable Affliction
should also be applied, but let's keep this simple.)
I don't care about when Agony
ticked, so to borrow from the previous example, I'm only going to look at when I applied it, instead of also every time it dealt damage.
sourceName="Ponerya" and fullType=SPELL_AURA_REFRESH and spell="Agony"
Wushoolay's Final Choice actually has two effects going on: there's the duration of the buff and there's the stacking intellect buff (the tooltip has a placeholder number). The part we care about is the stacking intellect buff. In combat, the right overpowering number of stacks varies depending on what has been proccing so far for the player, but the general rule is to refresh DoTs with a Soulburn: Soul Swap on the fifth and tenth stacks of the buff. I also care when the stacking buff fell off, so the code becomes:
sourceName = "Ponerya" and spell = "Electrified"
and (amount >= 5 or fullType = SPELL_AURA_REMOVED)
Here's the combined query on a Patchwerk-like fight like Jin'rokh normal:
sourceName = "Ponerya"
(spell="Agony" and fullType=SPELL_AURA_REFRESH)
(spell = "Electrified" and (amount >= 5 or fullType = SPELL_AURA_REMOVED) )
And...that's really it for looking at a DoT with the expression editor. If we care about overall or average damage done, we'll probably get more use out of one of the charts or graphs.
You forgot demonology AGAIN
In fact, I've been spending the past couple of weeks playing demonology in a variety of PvE environments, for my own betterment at playing that spec I rarely play, but also because the ungodly awesome AoE makes me feel useful on Lei Shen 25N. I spent this week's column using destruction and affliction examples so I could spend an entire column next week drilling down on two demonology warlocks with CompareBot.
See, I didn't forget at all.
Blood Pact is a weekly column detailing DOTs, demons and all the dastardly deeds done by warlocks. We'll coach you in the fine art of staying alive, help pick the best target for Dark Intent, and steer you through tier 13 set bonuses.