foundryvtt-wh4-lang-fr-fr/scripts/R6SnyF3y4Vsq6oga.js

9 lines
447 B
JavaScript
Raw Permalink Normal View History

2024-05-16 17:57:51 +02:00
let lore = this.effect.name.split("(")[1].split(")")[0].toLowerCase();
let spellLore = game.wfrp4e.config.magicLores[args.spell.system.lore.value].toLowerCase();
2024-05-16 17:57:51 +02:00
// If channelling corresponding lore
if (args.type == "channelling" && spellLore == lore)
2024-05-16 17:57:51 +02:00
args.prefillModifiers.slBonus += 1
// If channelling or casting different lore
else if (spellLore != lore && args.spell.system.lore.value != "petty")
2024-06-08 01:45:05 +02:00
args.prefillModifiers.slBonus -= 1