Skip to content

Commit

Permalink
Merge pull request #428 from vttred/fix/str-dex-bonus-accidentally-no…
Browse files Browse the repository at this point in the history
…t-being-added-with-damage-bonus-toggle

fix: str and dex modifier now added to damage roll
  • Loading branch information
anthonyronda authored May 15, 2023
2 parents 5c6a2d6 + 5d0f34a commit 4ba8eb6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/module/actor/entity.js
Original file line number Diff line number Diff line change
Expand Up @@ -475,7 +475,7 @@ export default class OseActor extends Actor {
if (!this.system.config?.ignoreBonusDamage && attData.item?.system?.bonus)
// Weapon Damage Bonus
dmgParts.push(attData.item?.system?.bonus);

const rollParts = ["1d20"];
const ascending = game.settings.get(game.system.id, "ascendingAC");

Expand All @@ -490,6 +490,9 @@ export default class OseActor extends Actor {
else if (options.type === "melee")
attackMods = [data.scores.str.mod, data.thac0.mod.melee];

dmgParts.push(...removeFalsyElements(attackMods));

// Add weapon bonus to attack roll only (already added to dmgParts)
if (attData.item) attackMods.push(attData.item?.system?.bonus);

rollParts.push(...removeFalsyElements(attackMods));
Expand Down

0 comments on commit 4ba8eb6

Please sign in to comment.