Miskatonic-Investigative-Society / CoC7-FoundryVTT

An unofficial implementation of the Call of Cthulhu 7th Edition game system for Foundry Virtual Tabletop
https://discord.gg/foundryvtt
GNU General Public License v3.0
118 stars 98 forks source link

Ranged weapons not applying DB #1326

Open feanix opened 1 year ago

feanix commented 1 year ago

When using a ranged weapon, DB is not added when rolling damage

Description.

When using a ranged weapon, DB is not added when rolling damage. Melee weapons do this correctly.

Expected Behavior.

When rolling damage with a ranged weapon DB should be rolled as well, like melee weapons.

Actual Behavior.

When rolling damage with a ranged weapon DB is not rolled as well.

image image

kwitczak commented 1 year ago

@snap01 I've taken a look into it and it seems that rollDamage() in rangecombat.js is adjusted mainly to firearms and mechanics of volleys. It would probably be easy to inject db there if it's defined on a weapon, but it seems a bit confusing to deal with db if you're reading logic of firearms.

My idea is to make rollDamage() pick on of these approaches based on the weapon properties: