Great Weapon Fighting
Lately, I've been playing a paladin in the weekly 5e D&D sessions I have with several friends. He's the kind of guy that uses heavy melee weapons along with the Great Weapon Fighting Fighting Style, which lets you reroll 1s and 2s on damage dice. I also have the Polearm Master and Great Weapon Master feats - a great combination, especially if you have taken the Vengeance oath (which offers single-target advantage 1/short rest) the -5 attack +10 damage is almost always on and hits still go through. Anyway, I digress. I love probabilities and abilities like Great Weapon Fighting which features rerolls are pretty great to research exactly how much effective they are. For these reasons I regularly use the anydice calculator
I created a little program that outputs the probability of each roll, as well as the mean and deviation for each d&d die: d4, d6, d8, d10 and d12, which you can find here. In my case, since I'm using a halberd, I've got a d10 damage dice:
The function above yields the following results:
As you can see, getting a result of 1 or 2 has just a 4% probability. It's not that big of a deal to be honest, however, if you take into account that paladins do not only have just one damage die, but many more due to their smite ability, the damage bonus from rerolling is pretty significant. As I've got many dice to roll for a single attack and damage roll (imagine being blessed while flanking your enemy, having divine favor on and using smite at the same time) and since I don't really have a dice set, I started using a software dice roller. My party members suggested to me Quick Dice Roller - it's a great free app that doesn't have ads, which is awesome.
What is great about the app is that you can edit the dice and include your own custom die rolls. Is your attack roll 1d20+3? You can easily edit an existing die or add a new one and set the formula that you like.
Recently, the app was updated to include "Named Values", which are global values that you can use in your custom dice rolls. Since my paladin has a strength of 19, I set the named value "strength modifier" to have values from 0 to 5 and set its value to 4.
I then edit the d20 roll to use strength instead of a static +3 value that I have to change all the time when my character levels up.
Voila! The rolls show that the named value with the 'str' code is evaluated to 4.
Well, all these are pretty simple, however, I decided to automate my attack and damage rolls to the extreme - I wanted to get my character to skip all this rolling and cut to the chase in-battle. Thankfully, Quick Dice Roller includes a function library that's pretty extensive; unfortunately, this library doesn't have an if-then-else or a 'reroll' function, so Great Weapon Fighting is pretty hard to implement with its reroll 1s and 2s.
The function that can approximate this ability is the 'Exploding' function. 'Exploding' a die usually means that if you roll the maximum value of that die, you can roll it again and add it to the total; so if you roll a d6 and you get 6, you can roll it again - let's say that the second roll turns up to be 3, then you get a total of 9.
Quick Dice Roller's exploding function lets you define the target to obtain an explosion - so you can set it to something lower than the maximum value of the die - in my case that threshold would be 2.
I decided to implement the formula as following: expUp(1d10, 2, 1d10-2,-1,1) which, in english, means: if you get a die roll equal to or higher than 2, explode it once, but subtract two from the second roll. Unfortunately this isn't what I wanted, as Great Weapon Fighting enables you to reroll on die rolls less than or equal to 2, not higher than that value.
Then it hit me! What if you use negative values instead? I didn't know if Quick Dice Roller would support negative values in its functions, but I was pleasantly surprised when I found out it did!
Here is the final formula:
I decided to check out my formula with anydice, to see that everything is OK and I'm not doing anything wrong. Unfortunately what I feared was correct:
This means that my paladin has 1% chance of dealing 0 damage from that specific die roll and to make matters worse, that 1% is subtracted from the probability of the chance to deal maximum damage, because the die roll chances are shifted (0,1,2,3... instead of 1,2,3,4...). This happens when rolling a -1 on the first roll, and get -1 again on the second roll - then the total is -1 -1 +2 = 0.
Unfortunately, unless the application is updated to include a reroll x times on y threshold function or a feature to reference the exploded die roll is added, this can't be fixed, so I'll take it over physically rolling all that dice or making my own application from scratch.
My final custom formulas. First of all, here are my named values:
level (level) used to determine the proficiency bonus.
strength (str) used to determine attack and damage bonus.
constitution (con) used to determine hit points.
advantage (advan) is the number of d20 dice that will be used when attacking.
smite (smt) is the number of smite dice that will be used on the damage roll.
blessed (bls) adds a d4 on attack rolls if the named value is set to 1.
weapon (wpn) is the weapon damage die. In my case it's d10, so it's set to 10.
And here are the custom formulas for my attack & damage:
Finally, here are some rolls (notice that I got the 0 damage die roll in my first try)!
Here are some custom formulas, based on the named values above:
(1-abs(advan))*1d20+abs(rak(1d20*advan,abs(advan)+1,1))
Rolls |advan|+1 times 1d20 dice and picks the highest one if advan = 1 or the lowest if advan = -1. If advan = 0 rolls only one die. Use this function to implement advantage/disadvantage.
((level-1)/4)+2
This is the formula for the proficiency bonus, assuming that 'level' holds your current level.
(level-1)*((hd/2)+1) + hd + con*level
Returns your total hit points, assuming that you're using the half+1 rule. 'hd' should hold your hit die (6, 8, 10, etc) and 'level' your total levels. This can be expanded to include all hit dice, but it will be quite complicated for no good reason, as you usually calculate this once and forget about it.
expup(-1d(wpn),-2,-1d(wpn)+2,0,1)*(-1)
Implements the Great Weapon Fighting ability, as approximate as possible, for the reasons explained above (you're dealing slightly less damage - 6.20 mean instead of 6.30 for a d10 weapon die). 'wpn' is a named value holding your weapon's damage die.
rak(expup(-1d(wpn),-2,-1d(wpn)+2,0,1)*(-1),wpd,wpd)
As above, but with a Roll and Keep (rak) function, just in case you're using a heavy weapon with two damage dice (Greatsword or Maul). 'wpd' is the code for a named value that holds the number of your weapon dice (1 or 2 typically).
rak(expup(-1d8,-2,-1d8+2,0,1)*(-1),smt,smt)
Implements the Great Weapon Fighting ability when using your smite ability. 'smt' is the code for the named value that holds your smite dice - change it before rolling according to the spell level that you're going to expend.
Remember that you can also combine all these - for instance, my damage roll looks like this:
Damage
rak(expup(-1d(wpn),-2,-1d(wpn)+2,0,1)*(-1),wpd,wpd)+str+10*(hwm)+rak(expup(-1d8,-2,-1d8+2,0,1)*(-1),smt,smt)

wpn = 10 (using a halberd)
wpd = 1
hwm = 1 (I'm always using the -5 attack +10 damage option of heavy weapon master)
smt = 0..3 (I'm level 7, so I just have access to 1st- and 2nd-level spells)
and this is my attack formula:
Attack
(1-abs(advan))*1d20+abs(rak(1d20*advan,abs(advan)+1,1))+((level-1)/4)+2+str-5*(hwm)+(bls)d4

advan = -1,0,1 (based on whether I have advantage/disadvantage or neither
str   = 4
hwm   = 1
bls   = 0,1 (based on if I'm blessed or not)

Addendum

I figured out a way to make the damage function better. You're still going to deal slightly less damage if you use it, 1% of the time, but this way it's not possible to deal 0 damage. Without further ado, here's the best formula that approximates Great Weapon Fighting using Quick Dice Roller:
As you can see getting a '2' is slightly more possible, but at least the chance of getting a 0 out of it is completely removed - which is great if you're using a weapon with a lower damage die. Here is the final formula:
Damage
rak(expup(-1d(wpn),-2,min(-1d(wpn)+2,0),0,1)*(-1),wpd,wpd)+str+10*(hwm)+rak(expup(-1d8,-2,min(-1d8+2,0),0,1)*(-1),smt,smt)

wpn = 10 (using a halberd)
wpd = 1
hwm = 1 (I'm always using the -5 attack +10 damage option of heavy weapon master)
smt = 0..3 (I'm level 7, so I just have access to 1st- and 2nd-level spells)
Posted by
On Monday, March 2, 2015 at 12:36 PM

2 comments:

  1. Such impressive work deserve a prize: I'll add the "reroll" function on one of the upcoming release.

    Please consider to join the official Quick Dice Roller community and to become a beta tester.

    Cheers,
    Ohmnibus

    ReplyDelete
    Replies
    1. That's great news!
      I think that I'm interested in becoming a beta tester.

      Delete