## Sunday, December 25, 2016

### Cloud Giant Damage

A general method for converting range notation to dice notation.

My first copy of the game was a Holmes edition with geomorphs.

The rules have staying power. This summer I met a Holmes player born after they went out of print!

And so the questions we asked thirty-five years ago are still getting asked. A classic is how to roll the 6–63 damage that cloud giants deal out:

The experienced referee makes this roll with a 3d20+3, but—and this is another example of the ambiguity of range notation—a 19d4-13 will also work.

One wonders whether there are other ways to make the roll. Also, is there an easy way to find those ways?

If we use a single type of die, then we must use a d20 or a d4 as above. If we allow more than one type of die in the roll, then 6d10+d4-1 works.

In fact, if we use more than one type of die, there are 164 ways to roll cloud giant damage.

To find them all, observe a fact about the difference between the largest and smallest value of each die; a d6 produces results in the range 1–6 and has a difference of 5. When multiple dice are summed, the difference of the sum is the sum of the differences of each die used; 2d6 has a range of 2–12 and a difference of 10; 3d6 has a range of 3–18 and a difference of 15.

The rule holds if we use more than one type of die: a d4 has a range of 1–4 and a difference of 3. A d4+d6 roll has a range of 2–10 and a difference of 3 + 5 = 8.

To find out how many ways there are to roll 6–63, we ask ourselves how many ways there are to sum to the difference of 57 given the differences we have available: 3 (d4), 5 (d6), 7 (d8), 9 (d10), 11 (d12), and 19 (d20). This is the unbounded knapsack problem where we are only interested in solutions which fill the "knapsack" completely.

The complete list of ways to roll cloud giant damage is here.

Code for finding ways to roll an arbitrary range is here.