Swamp Slogger
Posts: 182
Joined: Monday, 2nd July 2018, 16:47
Location: United States
Simplify the damage formula
The current damage formula has a lot of separate rolling, and at least one nested roll, and random rounding occurs many times. This makes the distribution complicated and pretty much impossible to visualize. I think it would be much better if we could reduce this to a uniform distribution or something very close to it. This would be much easier to visualize, as most people are familiar with the concept of dice, and would help people compare the relative values of skills and equipment. (For example, some people don't realize that strength is about as good as - or potentially, better than - slaying on characters with big weapons and high skills, and make bad equipment choices as a result.)
Here's how to achieve this: instead of calculating each bonus (skill, slaying, etc) with a roll and then adding or multiplying it to your rolled base damage, have each bonus be a deterministic addend or factor, and have each bonus be "inside" the base damage roll.
For a simple picture, the new damage formula would look something like:
There are many more possible modifiers (such as might) that would be applied in the same way (either a multiplier of the base, or an addition to the multiplied base). There are some total damage modifiers (such as indirect cleave) that would be a multiplier wrapping all of the above, but still be "inside" the roll and the random round.
Random rounding would only occur once; after all modifiers are calculated and before the dice is rolled.
The resulting distribution is nearly uniform. The only way in which it differs from uniform is: the maximum value is less likely than the rest of the values, because the random round makes it so that sometimes your dice doesn't have that maximum value on it.
General version of the formula:
- Code:
damage = 1d( randomRound( product(totalDamageMultipliers) * (baseDamage * product(baseDamageMultipliers) + sum(damageBonuses)) ))
totalDamageMultipliers is a list/array including items such as the indirect cleave modifier, shadow form modifier, etc
baseDamageMultipliers is a list/array including the strength modifier and skill modifier
damageBonuses is a list/array including the enchantment modifier, corrosion modifier, starvation modifier, etc
- For this message the author stormdragon has received thanks: 4
- chequers, duvessa, PseudoLoneWolf, VeryAngryFelid