foundryvtt-wh4-lang-fr-fr/reference_scripts/lZuavewrJzOehrJQ.js

14 lines
412 B
JavaScript
Raw Permalink Normal View History

2024-06-06 21:09:27 +02:00
let test = await this.actor.setupSkill('Endurance', {
appendTitle: ` ${this.effect.name}`,
skipTargets: true,
fields: {difficulty: 'easy'},
characteristic: 't',
context: {failure: "Mast shattered!"}
});
await test.roll();
if (test.failed) {
let crit = await fromUuid("Item.d4bCnR1zINTNF9VC");
await this.actor.createEmbeddedDocuments("Item", [crit]);
this.effect.update({disabled: true});
}