Fixes skill calculation.
This commit is contained in:
@@ -32,18 +32,18 @@ export class M5Item extends Item {
|
||||
const actorCalc = character.derivedData({ skills: true, weapons: true, defensiveWeapons: true, armor: true, items: true, spells: true })
|
||||
if (actorCalc?.skillMods && Object.keys(actorCalc.skillMods).indexOf(itemId) !== -1) {
|
||||
pairs = pairs.concat(actorCalc.skillMods[itemId])
|
||||
}
|
||||
|
||||
if (itemData?.attribute && itemData.attribute !== "") {
|
||||
pairs.push({
|
||||
source: (this as any).name,
|
||||
mod: {
|
||||
type: M5ModType.SKILL,
|
||||
id: itemId,
|
||||
operation: M5ModOperation.ADD,
|
||||
value: actorCalc.attributes[itemData.attribute].bonus
|
||||
}
|
||||
})
|
||||
}
|
||||
if (itemData?.attribute && itemData.attribute !== "") {
|
||||
pairs.push({
|
||||
source: (this as any).name,
|
||||
mod: {
|
||||
type: M5ModType.SKILL,
|
||||
id: itemId,
|
||||
operation: M5ModOperation.ADD,
|
||||
value: actorCalc.attributes[itemData.attribute].bonus
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user