Fix scripts !

This commit is contained in:
2026-01-29 11:43:28 +01:00
parent 0e8237c233
commit 752a6701c0
104 changed files with 195 additions and 193 deletions

View File

@@ -27,7 +27,7 @@ else
if (choice.length)
{
let changes = foundry.utils.deepClone(this.effet.changes);
let changes = foundry.utils.deepClone(this.effect.changes);
for(let training of choice)
{
@@ -62,7 +62,7 @@ if (choice.length)
case "guard" :
let territorial = await fromUuid("Compendium.wfrp4e-core.items.Item.JIAe7i7dqTQBu4do");
await this.actor.createEmbeddedDocuments("Item", [territorial], {fromEffect: this.effet.id})
await this.actor.createEmbeddedDocuments("Item", [territorial], {fromEffect: this.effect.id})
foundry.utils.setProperty(args, "options.keepId", true);
break;
@@ -83,6 +83,6 @@ if (choice.length)
break;
}
}
this.effet.updateSource({name : `${this.effet.name} (${choice.map(i => i.name).join(", ")})`, changes, "flags.wfrp4e.trained" : choice.map(i => i.id)})
this.effect.updateSource({name : `${this.effect.name} (${choice.map(i => i.name).join(", ")})`, changes, "flags.wfrp4e.trained" : choice.map(i => i.id)})
this.item.updateSource({"system.specification.value" : `${choice.map(i => i.name).join(", ")}`})
}