skripte in Ursprungsordner

This commit is contained in:
alzer
2025-05-10 00:11:46 +02:00
parent e5e43dda8a
commit 8015566cce
2979 changed files with 327 additions and 326 deletions
+16
View File
@@ -0,0 +1,16 @@
let careers = await warhammer.utility.findAllItems("career", "", true);
careers.forEach(c => {
if (!c.id)
{
c.id = c._id;
}
});
let choice = await ItemDialog.create(careers, 1, "Choisissez la carrière de votre double identité");
if (choice[0])
{
let career = await fromUuid(choice[0].uuid);
let data = career.toObject();
setProperty(data, "flags.wfrp4e.doubleLife", true);
this.actor.createEmbeddedDocuments("Item", [data], {fromEffect: this.effect.id})
this.effect.updateSource({name : this.effect.name + ` (${data.name})`})
}