correct warning when rollhelpers didn't have a target

This commit is contained in:
Mike Bloy 2026-02-15 11:32:44 -06:00
parent b69c6c523c
commit 04627e001a

View File

@ -75,6 +75,10 @@ export async function preAttackRollModifiers(
log('bestNonStackingMods', bestNonStackingMods);
log('isRangedAttack', isRangedAttack, 'isMeleeAttack', isMeleeAttack);
if (!targetToken) {
return;
}
// Deflection
if (isMeleeAttack && hasDeflection(targetToken, 'melee')) {
additionalMods.push({ label: 'Target has melee deflection', value: -2 });