More tests againts rolls

This commit is contained in:
2026-03-06 08:06:57 +01:00
parent 95b19c8f02
commit 16cf35aed6
15 changed files with 677 additions and 185 deletions
+13 -5
View File
@@ -42,12 +42,20 @@ export default class AwEActor extends Actor {
const attribute = this.system.attributes[attributeId]
if (!attribute) return null
// Collect knowledge bonuses from embedded Field items
const knowledgeBonuses = this.itemTypes.field?.map(f => ({
label: f.name,
bonus: f.system.knowledgeBonus ?? ""
})).filter(f => f.bonus !== "") ?? []
return AwERoll.prompt({
attributeKey: attributeId,
modifier: attribute.mod ?? 0,
actorId: this.id,
actorName: this.name,
actorImage: this.img,
attributeKey: attributeId,
modifier: attribute.mod ?? 0,
attributeBonus: attribute.bonus ?? 0,
knowledgeBonuses,
actorId: this.id,
actorName: this.name,
actorImage: this.img,
...options
})
}