Fix ranged attacks again
Release Creation / build (release) Has been cancelled

This commit is contained in:
2026-05-24 09:41:06 +02:00
parent 38eb1a8d3d
commit c217490a5b
29 changed files with 94 additions and 148 deletions
-17
View File
@@ -283,23 +283,6 @@ export default class LethalFantasyCharacter extends foundry.abstract.TypeDataMod
*/
async roll(rollType, rollTarget, defenderId, defenderTokenId, extraShieldDr = 0) {
const hasTarget = false
// Ranged weapon attacks from PCs use the ranged attack dialog (range, movement, aim modifiers)
if (rollType === "weapon-attack" && rollTarget?.isRangedAttack === true) {
let roll = await LethalFantasyRoll.promptRangedAttack({
rollType: "weapon-attack",
actorId: this.parent.id,
actorName: this.parent.name,
actorImage: this.parent.img,
rollTarget,
defenderId,
defenderTokenId,
})
if (!roll) return null
await roll.toMessage({}, { messageMode: roll.options.rollMode })
return
}
let roll = await LethalFantasyRoll.prompt({
rollType,
rollTarget,