Fix v10 datapath and functions

This commit is contained in:
sladecraven 2022-10-02 09:44:39 +02:00
parent a64ff7dd55
commit a679da4674
8 changed files with 128 additions and 128 deletions

View File

@ -143,7 +143,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.qn4ZpvTQIX4rcJDl\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.qn4ZpvTQIX4rcJDl\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornarm.png",
@ -175,7 +175,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.diseases.kKccDTGzWzSXCBOb\").then(disease=> {\n args.actor.createEmbeddedEntity(\"OwnedItem\", disease.data)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.diseases.kKccDTGzWzSXCBOb\").then(disease=> {\n args.actor.createEmbeddedDocuments(\"Item\", disease.toObject())\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornbody.png",
@ -557,7 +557,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.fBcZhOBn8IpoVqQ1\").then(injury => {\n let teeth = new Roll(\"1d10\").roll({async: false}).total\n ChatMessage.create({content : `<b>${this.actor.data.token.name}</b> a perdu ${teeth} dents`, speaker : {alias: this.effect.label}})\ninjury.location.value = `${teeth} ${injury.location.value}`\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury.data)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.fBcZhOBn8IpoVqQ1\").then(injury => {\n let teeth = new Roll(\"1d10\").roll({async: false}).total\n ChatMessage.create({content : `<b>${this.actor.prototypeToken.name}</b> a perdu ${teeth} dents`, speaker : {alias: this.effect.label}})\ninjury.location.value = `${teeth} ${injury.location.value}`\n args.actor.createEmbeddedDocuments(\"Item\", injury.toObject())\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/head.png",
@ -608,7 +608,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.EaqlLRQigwnsEAXX\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.EaqlLRQigwnsEAXX\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()] )\n} )"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornbody.png",
@ -640,7 +640,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "if (args.actor.isOwner)\n{\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"difficult\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"stunned\")\n })\n })\n\nfromUuid(\"Compendium.wfrp4e-core.injuries.4lj1ik958mbgAlaF\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\n\n}"
"script": "if (args.actor.isOwner)\n{\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"difficult\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"stunned\")\n })\n })\n\nfromUuid(\"Compendium.wfrp4e-core.injuries.4lj1ik958mbgAlaF\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\n\n}"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornarm.png",
@ -729,7 +729,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.nF5z1OEhpi4t6a6S\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.nF5z1OEhpi4t6a6S\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject() ] )\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornleg.png",
@ -848,7 +848,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid('Compendium.wfrp4e-core.injuries.EaqlLRQigwnsEAXX').then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid('Compendium.wfrp4e-core.injuries.EaqlLRQigwnsEAXX').then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()] )\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornbody.png",
@ -1004,7 +1004,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.QluSTTTq3viHJJUh\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.QluSTTTq3viHJJUh\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornbody.png",
@ -1054,7 +1054,7 @@
"wfrp4e": {
"effectApplication": "actor",
"effectTrigger": "oneTime",
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.2A7SW9eXsm7MvLsk\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.2A7SW9eXsm7MvLsk\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornarm.png",
@ -1246,7 +1246,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.weczkAMPlTjX7lqU\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\nfromUuid(\"Compendium.wfrp4e-core.injuries.SpPRZZRHxly7uo2G\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.weczkAMPlTjX7lqU\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.roObject()])\n})\n\nfromUuid(\"Compendium.wfrp4e-core.injuries.SpPRZZRHxly7uo2G\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/head.png",
@ -1321,7 +1321,7 @@
"effectApplication": "actor",
"effectTrigger": "endCombat",
"preventDuplicateEffects": false,
"script": "if (this.actor.isOwner)\n this.actor.setupSkill(\"Résistance\").then(setupData => {\n this.actor.basicTest(setupData).then(test => {\n if (test.result.outcome == \"failure\") {\n fromUuid(\"Compendium.wfrp4e-core.injuries.ZhMADOqoo0y8Q9bx\").then(injury => {\n this.actor.createEmbeddedEntity(\"OwnedItem\", injury.data)\n this.actor.deleteEmbeddedEntity(\"ActiveEffect\", this.effect._id)\n })\n }\n })\n })"
"script": "if (this.actor.isOwner)\n this.actor.setupSkill(\"Résistance\").then(setupData => {\n this.actor.basicTest(setupData).then(test => {\n if (test.result.outcome == \"failure\") {\n fromUuid(\"Compendium.wfrp4e-core.injuries.ZhMADOqoo0y8Q9bx\").then(injury => {\n this.actor.createEmbeddedDocuments(\"Item\", [injury..toObject()])\n this.actor.deleteEmbeddedDocuments(\"ActiveEffect\", this.effect._id)\n })\n }\n })\n })"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornleg.png",
@ -1461,7 +1461,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.GlShFJF2TpsNh1FX\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"hard\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"unconscious\")\n })\n })"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.GlShFJF2TpsNh1FX\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"hard\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"unconscious\")\n })\n })"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornarm.png",
@ -1644,7 +1644,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.GlShFJF2TpsNh1FX\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.GlShFJF2TpsNh1FX\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornarm.png",
@ -1772,7 +1772,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.SYjWiKDzMS6CtROJ\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.SYjWiKDzMS6CtROJ\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()] )\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornarm.png",
@ -1804,7 +1804,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.eWPN3CV2Eddwz8aM\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.eWPN3CV2Eddwz8aM\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornbody.png",
@ -1927,7 +1927,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.3S4OYOZLauXctmev\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\nfromUuid(\"Compendium.wfrp4e-core.injuries.7mCcI3q7hgWcmbBU\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.3S4OYOZLauXctmev\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\nfromUuid(\"Compendium.wfrp4e-core.injuries.7mCcI3q7hgWcmbBU\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornleg.png",
@ -2158,7 +2158,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.2iult41Jehz0F1O8\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.2iult41Jehz0F1O8\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornleg.png",
@ -2319,7 +2319,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.QluSTTTq3viHJJUh\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\").then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"prone\")\n })\n })"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.QluSTTTq3viHJJUh\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\").then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"prone\")\n })\n })"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornbody.png",
@ -2367,7 +2367,7 @@
"wfrp4e": {
"effectApplication": "actor",
"effectTrigger": "oneTime",
"script": "fromUuid(\"Compendium.wfrp4e-core.diseases.M8XyRs9DN12XsFTQ\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.diseases.M8XyRs9DN12XsFTQ\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornbody.png",
@ -2438,7 +2438,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.7mCcI3q7hgWcmbBU\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"hard\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"stunned\")\n })\n })"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.7mCcI3q7hgWcmbBU\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"hard\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"stunned\")\n })\n })"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornleg.png",
@ -2470,7 +2470,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.qn4ZpvTQIX4rcJDl\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.qn4ZpvTQIX4rcJDl\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornarm.png",
@ -2521,7 +2521,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.hCadFsTRvLN9faaY\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\").then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"unconscious\")\n })\n })"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.hCadFsTRvLN9faaY\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\").then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"unconscious\")\n })\n })"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/head.png",
@ -2572,7 +2572,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.nbhn2wX35b7Jrcbg\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.nbhn2wX35b7Jrcbg\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/head.png",
@ -2640,7 +2640,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.fBcZhOBn8IpoVqQ1\").then(injury => {\n let teeth = new Roll(\"1d10\").roll({async: false}).total\n ChatMessage.create({content : `<b>${this.actor.data.token.name}</b> loses ${teeth} teeth`, speaker : {alias: this.effect.label}})\ninjury.location.value = `${teeth} ${injury.location.value}`\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury.data)\n})\n\nfromUuid(\"Compendium.wfrp4e-core.injuries.rkJA1DlK51QuRlJy\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\nfromUuid(\"Compendium.wfrp4e-core.injuries.hCadFsTRvLN9faaY\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\").then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"unconscious\")\n })\n })"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.fBcZhOBn8IpoVqQ1\").then(injury => {\n let teeth = new Roll(\"1d10\").roll({async: false}).total\n ChatMessage.create({content : `<b>${this.actor.data.token.name}</b> loses ${teeth} teeth`, speaker : {alias: this.effect.label}})\ninjury.location.value = `${teeth} ${injury.location.value}`\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\nfromUuid(\"Compendium.wfrp4e-core.injuries.rkJA1DlK51QuRlJy\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\nfromUuid(\"Compendium.wfrp4e-core.injuries.hCadFsTRvLN9faaY\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\").then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"unconscious\")\n })\n })"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/head.png",
@ -2696,7 +2696,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.zyocWSzEZEC826NS\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"hard\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n { \n args.actor.addCondition(\"prone\")\n args.actor.addCondition(\"stunned\")\n }\n })\n })"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.zyocWSzEZEC826NS\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"hard\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n { \n args.actor.addCondition(\"prone\")\n args.actor.addCondition(\"stunned\")\n }\n })\n })"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornarm.png",
@ -2764,7 +2764,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.SYjWiKDzMS6CtROJ\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.SYjWiKDzMS6CtROJ\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()] )\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornarm.png",
@ -2954,7 +2954,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.weczkAMPlTjX7lqU\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.weczkAMPlTjX7lqU\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/head.png",
@ -3025,7 +3025,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.8piWcBKFlQ2J1E3A\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.8piWcBKFlQ2J1E3A\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/head.png",
@ -3182,7 +3182,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "if(args.actor.isOwner) {\n args.actor.setupSkill(\"Résistance\", { absolute: { difficulty: \"average\" } }).then(setupData => {\n args.actor.basicTest(setupData).then(test => {\n if (test.result.outcome == \"failure\") {\n args.actor.addCondition(\"prone\")\n fromUuid(\"Compendium.wfrp4e-core.injuries.ZhMADOqoo0y8Q9bx\").then(injury => {\n injury.location.value = `${Math.clamped(Math.abs(test.result.outcome.SL) + 1, 1, 5)} ${injury.location.value}`\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury.data)\n })\n }\n })\n })\n }"
"script": "if(args.actor.isOwner) {\n args.actor.setupSkill(\"Résistance\", { absolute: { difficulty: \"average\" } }).then(setupData => {\n args.actor.basicTest(setupData).then(test => {\n if (test.result.outcome == \"failure\") {\n args.actor.addCondition(\"prone\")\n fromUuid(\"Compendium.wfrp4e-core.injuries.ZhMADOqoo0y8Q9bx\").then(injury => {\n injury.location.value = `${Math.clamped(Math.abs(test.result.outcome.SL) + 1, 1, 5)} ${injury.location.value}`\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n })\n }\n })\n })\n }"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornleg.png",
@ -3272,7 +3272,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.gz2xy41OSVZ8YBgI\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.gz2xy41OSVZ8YBgI\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornleg.png",
@ -3460,7 +3460,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.k00PimCWkff11IA0\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.k00PimCWkff11IA0\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornleg.png",
@ -3492,7 +3492,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.3S4OYOZLauXctmev\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"hard\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"unconscious\")\n })\n })"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.3S4OYOZLauXctmev\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"hard\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"unconscious\")\n })\n })"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornleg.png",
@ -3582,7 +3582,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.MnMZv7ZXoRqoH9dS\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"hard\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"unconscious\")\n })\n })"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.MnMZv7ZXoRqoH9dS\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})\n\n\nif (args.actor.isOwner)\n args.actor.setupSkill(\"Résistance\", {absolute: {difficulty: \"hard\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\")\n args.actor.addCondition(\"unconscious\")\n })\n })"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornarm.png",
@ -3614,7 +3614,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.GlShFJF2TpsNh1FX\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.GlShFJF2TpsNh1FX\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornarm.png",
@ -3646,7 +3646,7 @@
"effectApplication": "actor",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.7rBhIRo96Mydo0Cv\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.injuries.7rBhIRo96Mydo0Cv\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/injuries/tornbody.png",

View File

@ -88,7 +88,7 @@
"wfrp4e": {
"effectApplication": "apply",
"effectTrigger": "prePrepareData",
"script": "args.actor.data.items = args.actor.data.items.filter(i => i.type != \"psychology\")"
"script": "args.actor.items = args.actor.items.filter(i => i.type != \"psychology\")"
}
},
"icon": "modules/wfrp4e-core/icons/prayers/miracles.png",
@ -753,7 +753,7 @@
"wfrp4e": {
"effectApplication": "apply",
"effectTrigger": "oneTime",
"script": "fromUuid(\"Compendium.wfrp4e-core.psychologies.5hH73j2NgPdsLCZN\").then(item => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", item)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.psychologies.5hH73j2NgPdsLCZN\").then(item => {\n args.actor.createEmbeddedDocuments(\"Item\", [item.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/prayers/miracles.png",
@ -802,7 +802,7 @@
"wfrp4e": {
"effectApplication": "apply",
"effectTrigger": "oneTime",
"script": "fromUuid(\"Compendium.wfrp4e-core.talents.J9MK0AIaTbvd5oF6\").then(item => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", item)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.talents.J9MK0AIaTbvd5oF6\").then(item => {\n args.actor.createEmbeddedDocuments(\"Item\", [item.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/prayers/miracles.png",
@ -898,7 +898,7 @@
"wfrp4e": {
"effectApplication": "apply",
"effectTrigger": "oneTime",
"script": "fromUuid(\"Compendium.wfrp4e-core.talents.CV9btQn09S9Fn8Jk\").then(item => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", item)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.talents.CV9btQn09S9Fn8Jk\").then(item => {\n args.actor.createEmbeddedDocuments(\"Item\", [item.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/prayers/miracles.png",
@ -989,7 +989,7 @@
"wfrp4e": {
"effectApplication": "apply",
"effectTrigger": "oneTime",
"script": "fromUuid(\"Compendium.wfrp4e-core.talents.g4Q6AtzZuo5iIvD4\").then(item => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", item)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.talents.g4Q6AtzZuo5iIvD4\").then(item => {\n args.actor.createEmbeddedDocuments(\"Item\", [item.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/prayers/miracles.png",
@ -1142,7 +1142,7 @@
"wfrp4e": {
"effectApplication": "apply",
"effectTrigger": "oneTime",
"script": "let damage = (await new Roll(\"1d10\")).roll({async: false}).total\n args.actor.applyBasicDamage(damage, {damageType : game.wfrp4e.config.DAMAGE_TYPE.IGNORE_ALL})\n\nif (args.actor.has(\"Mort-vivant\") || args.actor.data.has(\"Démoniaque\"))\n{\n args.actor.addCondition(\"ablaze\")\n}"
"script": "let damage = (await new Roll(\"1d10\")).roll({async: false}).total\n args.actor.applyBasicDamage(damage, {damageType : game.wfrp4e.config.DAMAGE_TYPE.IGNORE_ALL})\n\nif (args.actor.has(\"Mort-vivant\") || args.actor.has(\"Démoniaque\"))\n{\n args.actor.addCondition(\"ablaze\")\n}"
}
},
"icon": "modules/wfrp4e-core/icons/prayers/miracles.png",
@ -1235,7 +1235,7 @@
"effectApplication": "apply",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(\"Compendium.wfrp4e-core.traits.pLW9SVX0TVTYPiPv\").then(item => {\n item.specification.value = 3\n this.actor.createEmbeddedEntity(\"OwnedItem\", item)\n})\n\nfromUuid(\"Compendium.wfrp4e-core.traits.AtpAudHA4ybXVlWM\").then(item => {\n item.specification.value = 4\n this.actor.createEmbeddedEntity(\"OwnedItem\", item)\n})"
"script": "fromUuid(\"Compendium.wfrp4e-core.traits.pLW9SVX0TVTYPiPv\").then(item => {\n item.system.specification.value = 3\n this.actor.createEmbeddedDocuments(\"Item\", [item.toObject()])\n})\n\nfromUuid(\"Compendium.wfrp4e-core.traits.AtpAudHA4ybXVlWM\").then(item => {\n item.system.specification.value = 4\n this.actor.createEmbeddedDocuments(\"Item\", [item.toObject()])\n})"
}
},
"icon": "modules/wfrp4e-core/icons/prayers/miracles.png",

View File

@ -121,7 +121,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -550,7 +550,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -746,7 +746,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -804,7 +804,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -1008,7 +1008,7 @@
"effectApplication": "apply",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(this.effect.origin).then(caster=> {\n if (caster&& (args.actor.has(game.i18n.localize(\"NAME.Undead\")) || args.actor.has(game.i18n.localize(\"NAME.Daemonic\"))))\n {\n let wp = caster.characteristics.wp.value\n if (wp > args.actor.characteristics.t.value)\n {\n if (args.actor.has(game.i18n.localize(\"NAME.Unstable\")))\n {\n args.actor.update({\"data.status.wounds.value\" : 0})\n args.actor.addCondition(\"dead\")\n }\n else\n {\n fromUuid(\"Compendium.wfrp4e-core.traits.D0ImWEIMSDgElsnl\").then(item => {\n args.actor.createEmbeddedDocuments(\"Item\", [item])\n ChatMessage.create({content : `Ajout d'Instable à ${args.actor.data.token.name}`, speaker : {alias: caster.name}})\n })\n }\n }\n }\n })"
"script": "fromUuid(this.effect.origin).then(caster=> {\n if (caster&& (args.actor.has(game.i18n.localize(\"NAME.Undead\")) || args.actor.has(game.i18n.localize(\"NAME.Daemonic\"))))\n {\n let wp = caster.characteristics.wp.value\n if (wp > args.actor.characteristics.t.value)\n {\n if (args.actor.has(game.i18n.localize(\"NAME.Unstable\")))\n {\n args.actor.update({\"data.status.wounds.value\" : 0})\n args.actor.addCondition(\"dead\")\n }\n else\n {\n fromUuid(\"Compendium.wfrp4e-core.traits.D0ImWEIMSDgElsnl\").then(item => {\n args.actor.createEmbeddedDocuments(\"Item\", [item])\n ChatMessage.create({content : `Ajout d'Instable à ${args.actor.prototypeToken.name}`, speaker : {alias: caster.name}})\n })\n }\n }\n }\n })"
}
},
"icon": "modules/wfrp4e-core/icons/spells/banishment.png",
@ -1113,7 +1113,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -1136,7 +1136,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -1184,7 +1184,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -1213,7 +1213,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -1486,7 +1486,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -1688,7 +1688,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -1890,7 +1890,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -2100,7 +2100,7 @@
"effectApplication": "damage",
"effectTrigger": "applyDamage",
"preventDuplicateEffects": false,
"script": "let applyAP = (args.damageType == game.wfrp4e.config.DAMAGE_TYPE.IGNORE_TB || args.damageType == game.wfrp4e.config.DAMAGE_TYPE.NORMAL)\nlet applyTB = (args.damageType == game.wfrp4e.config.DAMAGE_TYPE.IGNORE_AP || args.damageType == game.wfrp4e.config.DAMAGE_TYPE.NORMAL)\n\n\nif (applyAP) \n{\n let AP = args.AP\n\n args.totalWoundLoss += AP.used\n let apIndex = args.messageElements.findIndex(i => i.includes(game.i18n.localize(\"AP\")))\n args.messageElements[apIndex] = \"0/\" + AP.value + \" \" + game.i18n.localize(\"AP\")\n}\n\nif (applyTB)\n{\n let TB = args.actor.characteristics.t.bonus\n args.totalWoundLoss += TB\n let apIndex = args.messageElements.findIndex(i => i.includes(game.i18n.localize(\"TB\")))\n args.messageElements[apIndex] = \"0/\" + TB + \" \" + game.i18n.localize(\"TB\")\n}\n\nlet woundsGained = Math.min(args.totalWoundLoss, args.actor.status.wounds.value)\n\nwoundsGained = Math.floor(woundsGained / 2)\n\nlet attackerWounds = duplicate(args.attacker.status.wounds)\n\nattackerWounds.value += woundsGained\n\nif (attackerWounds.value >= attackerWounds.max)\n attackerWounds.value = attackerWounds.max\n\nargs.attacker.update({ \"data.status.wounds\": attackerWounds })\n\nChatMessage.create({ content: `<b>${args.attacker.data.token.name}</b> subit ${woundsGained} Points de Blessures` })"
"script": "let applyAP = (args.damageType == game.wfrp4e.config.DAMAGE_TYPE.IGNORE_TB || args.damageType == game.wfrp4e.config.DAMAGE_TYPE.NORMAL)\nlet applyTB = (args.damageType == game.wfrp4e.config.DAMAGE_TYPE.IGNORE_AP || args.damageType == game.wfrp4e.config.DAMAGE_TYPE.NORMAL)\n\n\nif (applyAP) \n{\n let AP = args.AP\n\n args.totalWoundLoss += AP.used\n let apIndex = args.messageElements.findIndex(i => i.includes(game.i18n.localize(\"AP\")))\n args.messageElements[apIndex] = \"0/\" + AP.value + \" \" + game.i18n.localize(\"AP\")\n}\n\nif (applyTB)\n{\n let TB = args.actor.characteristics.t.bonus\n args.totalWoundLoss += TB\n let apIndex = args.messageElements.findIndex(i => i.includes(game.i18n.localize(\"TB\")))\n args.messageElements[apIndex] = \"0/\" + TB + \" \" + game.i18n.localize(\"TB\")\n}\n\nlet woundsGained = Math.min(args.totalWoundLoss, args.actor.status.wounds.value)\n\nwoundsGained = Math.floor(woundsGained / 2)\n\nlet attackerWounds = duplicate(args.attacker.status.wounds)\n\nattackerWounds.value += woundsGained\n\nif (attackerWounds.value >= attackerWounds.max)\n attackerWounds.value = attackerWounds.max\n\nargs.attacker.update({ \"data.status.wounds\": attackerWounds })\n\nChatMessage.create({ content: `<b>${args.attacker.prototypeToken.name}</b> subit ${woundsGained} Points de Blessures` })"
}
},
"icon": "modules/wfrp4e-core/icons/spells/caress-of-laniph.png",
@ -2221,7 +2221,7 @@
"effectApplication": "apply",
"effectTrigger": "preOpposedDefender",
"preventDuplicateEffects": false,
"script": "if ((args.attackerTest.weapon && args.attackerTest.weapon.attackType == \"melee\") || (args.attackerTest.trait && !args.attackerTest.trait.name.includes(\"Ranged\")))\n{\n let content = `<b>${args.attackerTest.actor.data.token.name}</b> reçoit ${this.actor.characteristics.wp.bonus} Dégats du Bouclier Céruléen si il utilise une arme en métal.`\n args.opposedTest.result.other.push(content);\n}"
"script": "if ((args.attackerTest.weapon && args.attackerTest.weapon.attackType == \"melee\") || (args.attackerTest.trait && !args.attackerTest.trait.name.includes(\"Ranged\")))\n{\n let content = `<b>${args.attackerTest.actor.prototypeToken.name}</b> reçoit ${this.actor.characteristics.wp.bonus} Dégats du Bouclier Céruléen si il utilise une arme en métal.`\n args.opposedTest.result.other.push(content);\n}"
}
},
"icon": "modules/wfrp4e-core/icons/spells/cerulean-shield.png",
@ -2267,7 +2267,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -2596,7 +2596,7 @@
"effectApplication": "apply",
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.data.token.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.prototypeToken.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.prototypeToken.name}})"
}
},
"icon": "modules/wfrp4e-core/icons/blank.png",
@ -2628,7 +2628,7 @@
"effectApplication": "apply",
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.data.token.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.prototypeToken.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actorprototypeToken.name}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -2645,7 +2645,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -2676,7 +2676,7 @@
"effectApplication": "apply",
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.data.token.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.prototypeToken.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.prototypeToken.name}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/daemonology.png",
@ -2708,7 +2708,7 @@
"effectApplication": "apply",
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.data.token.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.prototypeToken.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.prototypeToken.name}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/death.png",
@ -2756,7 +2756,7 @@
"effectApplication": "apply",
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.data.token.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.prototypeToken.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.prototypeToken.name}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/fire.png",
@ -2804,7 +2804,7 @@
"effectApplication": "apply",
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.data.token.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.prototypeToken.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.prototypeToken.name}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/heavens.png",
@ -2852,7 +2852,7 @@
"effectApplication": "apply",
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.data.token.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.prototypeToken.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.prototypeToken.name}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/life.png",
@ -2900,7 +2900,7 @@
"effectApplication": "apply",
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.data.token.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.prototypeToken.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.prototypeToken.name}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/light.png",
@ -2948,7 +2948,7 @@
"effectApplication": "apply",
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.data.token.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.prototypeToken.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.prototypeToken.name}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/metal.png",
@ -2996,7 +2996,7 @@
"effectApplication": "apply",
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.data.token.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.prototypeToken.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.prototypeToken.name}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/necromancy.png",
@ -3028,7 +3028,7 @@
"effectApplication": "apply",
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.data.token.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}</b>: Toutes les cibles au contact avec <b>${this.actor.prototypeToken.name}</b> encaissent [[/r 1d10]] Dégâts, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.prototypeToken.name}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/shadow.png",
@ -3287,7 +3287,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -3672,7 +3672,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -4101,7 +4101,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -4328,7 +4328,7 @@
"effectApplication": "damage",
"effectTrigger": "applyDamage",
"preventDuplicateEffects": false,
"script": "let wounds = duplicate(args.attacker.status.wounds)\nwounds.value+=1\n\nif (wounds.value > wounds.max)\n wounds.value = wounds.max\n\nargs.attacker.update({\"data.status.wounds\" : wounds})\n\nChatMessage.create({content: `${args.attacker.data.token.name} récupère 1 blessure.`})"
"script": "let wounds = duplicate(args.attacker.status.wounds)\nwounds.value+=1\n\nif (wounds.value > wounds.max)\n wounds.value = wounds.max\n\nargs.attacker.update({\"data.status.wounds\" : wounds})\n\nChatMessage.create({content: `${args.attacker.prototypeToken.name} récupère 1 blessure.`})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/petty.png",
@ -4358,7 +4358,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -4585,7 +4585,7 @@
"effectApplication": "apply",
"effectTrigger": "endRound",
"preventDuplicateEffects": false,
"script": "fromUuid(this.effect.origin).then(caster => {\n if (caster)\n {\n let bonus = caster.characteristics.wp.bonus\n this.actor.modifyWounds(bonus)\n\n ChatMessage.create({content: `${this.actor.data.token.name} regagne ${bonus} Points de Blessures (si en contact direct avec la Terre)`, speaker : {alias : this.effect.label}})\n }\n})"
"script": "fromUuid(this.effect.origin).then(caster => {\n if (caster)\n {\n let bonus = caster.characteristics.wp.bonus\n this.actor.modifyWounds(bonus)\n\n ChatMessage.create({content: `${this.actor.prototypeToken.name} regagne ${bonus} Points de Blessures (si en contact direct avec la Terre)`, speaker : {alias : this.effect.label}})\n }\n})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/earthblood.png",
@ -4734,7 +4734,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -5211,7 +5211,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Select a target to apply the effect.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Select a target to apply the effect.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/blank.png",
@ -5236,7 +5236,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/blank.png",
@ -5268,7 +5268,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -5285,7 +5285,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -5316,7 +5316,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/spells/daemonology.png",
@ -5348,7 +5348,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/spells/death.png",
@ -5396,7 +5396,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/spells/fire.png",
@ -5444,7 +5444,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/spells/heavens.png",
@ -5492,7 +5492,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/spells/life.png",
@ -5540,7 +5540,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/spells/light.png",
@ -5588,7 +5588,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/spells/metal.png",
@ -5636,7 +5636,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/spells/necromancy.png",
@ -5668,7 +5668,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Sélectionnez une cible pour appliquer l'effet.\")\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/spells/shadow.png",
@ -5932,7 +5932,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -6355,7 +6355,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -6603,7 +6603,7 @@
"effectApplication": "apply",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(this.effect.origin).then(caster => {\n if (caster)\n {\n let healed= caster.characteristics.wp.bonus + caster.characteristics.int.bonus\n let wounds = duplicate(args.actor.status.wounds)\n wounds.value+=healed\n \n if (wounds.value > wounds.max)\n wounds.value = wounds.max\n \n args.actor.update({\"data.status.wounds\" : wounds})\n ChatMessage.create({content: `${this.actor.data.token.name} regains ${healed} Wounds`, speaker : {alias : this.effect.label}})\n }\n})\n\nthis.actor.setupSkill(\"Résistance\", {absolute : {difficulty : \"vhard\"}, context : {success : \"1 Corruption point that was gained within the last hour is removed.\", failure: \"Nothing happens\"}}).then(setupData => {\n this.actor.basicTest(setupData)\n})"
"script": "fromUuid(this.effect.origin).then(caster => {\n if (caster)\n {\n let healed= caster.characteristics.wp.bonus + caster.characteristics.int.bonus\n let wounds = duplicate(args.actor.status.wounds)\n wounds.value+=healed\n \n if (wounds.value > wounds.max)\n wounds.value = wounds.max\n \n args.actor.update({\"data.status.wounds\" : wounds})\n ChatMessage.create({content: `${this.actor.prototypeToken.name} regains ${healed} Wounds`, speaker : {alias : this.effect.label}})\n }\n})\n\nthis.actor.setupSkill(\"Résistance\", {absolute : {difficulty : \"vhard\"}, context : {success : \"1 Corruption point that was gained within the last hour is removed.\", failure: \"Nothing happens\"}}).then(setupData => {\n this.actor.basicTest(setupData)\n})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/healing-light.png",
@ -6677,7 +6677,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -6787,7 +6787,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -7047,7 +7047,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -7249,7 +7249,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -7576,7 +7576,7 @@
"effectApplication": "apply",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "fromUuid(this.effect.origin).then(caster => {\n if (caster)\n {\n let healed= caster.characteristics.wp.bonus\n let wounds = duplicate(args.actor.status.wounds)\n wounds.value+=healed\n \n if (wounds.value > wounds.max)\n wounds.value = wounds.max\n \n args.actor.update({\"data.status.wounds\" : wounds})\n ChatMessage.create({content: `${this.actor.data.token.name} regains ${healed} Wounds`, speaker : {alias : this.effect.label}})\n }\n})"
"script": "fromUuid(this.effect.origin).then(caster => {\n if (caster)\n {\n let healed= caster.characteristics.wp.bonus\n let wounds = duplicate(args.actor.status.wounds)\n wounds.value+=healed\n \n if (wounds.value > wounds.max)\n wounds.value = wounds.max\n \n args.actor.update({\"data.status.wounds\" : wounds})\n ChatMessage.create({content: `${this.actor.prototypeToken.name} regains ${healed} Wounds`, speaker : {alias : this.effect.label}})\n }\n})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/nostrum.png",
@ -7842,7 +7842,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -8443,7 +8443,7 @@
"effectApplication": "damage",
"effectTrigger": "applyDamage",
"preventDuplicateEffects": true,
"script": "let applyAP = (args.damageType == game.wfrp4e.config.DAMAGE_TYPE.IGNORE_TB || args.damageType == game.wfrp4e.config.DAMAGE_TYPE.NORMAL)\n\nif (applyAP) \n{\n let AP = args.AP\n\n args.totalWoundLoss += AP.used\n let apIndex = args.messageElements.findIndex(i => i.includes(game.i18n.localize(\"AP\")))\n args.messageElements[apIndex] = \"0/\" + AP.value + \" \" + game.i18n.localize(\"AP\")\n}\n\nlet woundsGained = Math.min(args.actor.status.wounds.value, args.totalWoundLoss)\nwoundsGained = Math.ceil(woundsGained / 2)\n\nlet attackerWounds = duplicate(args.attacker.status.wounds)\n\nattackerWounds.value += woundsGained\n\nif (attackerWounds.value >= attackerWounds.max)\n attackerWounds.value = attackerWounds.max\n\nargs.attacker.update({\"data.status.wounds\" : attackerWounds})\n\nargs.actor.addCondition(\"fatigued\")\n\nChatMessage.create({content: `<b>${args.attacker.data.token.name}</b> récupère ${woundsGained} Points de Blessures`, alias : {speaker : this.effect.label}})"
"script": "let applyAP = (args.damageType == game.wfrp4e.config.DAMAGE_TYPE.IGNORE_TB || args.damageType == game.wfrp4e.config.DAMAGE_TYPE.NORMAL)\n\nif (applyAP) \n{\n let AP = args.AP\n\n args.totalWoundLoss += AP.used\n let apIndex = args.messageElements.findIndex(i => i.includes(game.i18n.localize(\"AP\")))\n args.messageElements[apIndex] = \"0/\" + AP.value + \" \" + game.i18n.localize(\"AP\")\n}\n\nlet woundsGained = Math.min(args.actor.status.wounds.value, args.totalWoundLoss)\nwoundsGained = Math.ceil(woundsGained / 2)\n\nlet attackerWounds = duplicate(args.attacker.status.wounds)\n\nattackerWounds.value += woundsGained\n\nif (attackerWounds.value >= attackerWounds.max)\n attackerWounds.value = attackerWounds.max\n\nargs.attacker.update({\"data.status.wounds\" : attackerWounds})\n\nargs.actor.addCondition(\"fatigued\")\n\nChatMessage.create({content: `<b>${args.attacker.prototypeToken.name}</b> récupère ${woundsGained} Points de Blessures`, alias : {speaker : this.effect.label}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/steal-life.png",
@ -8566,7 +8566,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -8770,7 +8770,7 @@
"effectApplication": "apply",
"effectTrigger": "invoke",
"preventDuplicateEffects": false,
"script": "let value = 1\nlet name = this.actor.data.token.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Select a target to apply the effect.\")\n game.user.targets.forEach(t => {\n t.actor.applyTerror(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postTerror(value, name)\n}"
"script": "let value = 1\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM)\n{\nif (!game.user.targets.size)\n return ui.notifications.warn(\"Select a target to apply the effect.\")\n game.user.targets.forEach(t => {\n t.actor.applyTerror(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postTerror(value, name)\n}"
}
},
"icon": "modules/wfrp4e-core/icons/blank.png",
@ -8794,7 +8794,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -9015,7 +9015,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -9069,7 +9069,7 @@
"effectApplication": "apply",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "let fortunePoints = {{result.overcast.other.current}}\nlet current = this.actor.status.fortune.value\n\nthis.actor.update({\"data.status.fortune.value\" : fortunePoints + current})\n\nChatMessage.create({content : `<b>${this.actor.data.token.name}</b> a désormais ${fortunePoints + current} Points de Chance`, speaker : {alias : this.effect.label}})"
"script": "let fortunePoints = {{result.overcast.other.current}}\nlet current = this.actor.status.fortune.value\n\nthis.actor.update({\"data.status.fortune.value\" : fortunePoints + current})\n\nChatMessage.create({content : `<b>${this.actor.prototypeToken.name}</b> a désormais ${fortunePoints + current} Points de Chance`, speaker : {alias : this.effect.label}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/the-first-portent-of-amul.png",
@ -9117,7 +9117,7 @@
"effectApplication": "apply",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "let fortunePoints = {{result.overcast.other.current}}\nlet current = this.actor.status.fortune.value\n\nthis.actor.update({\"data.status.fortune.value\" : fortunePoints + current})\n\nChatMessage.create({content : `<b>${this.actor.data.token.name}</b> a désormais ${fortunePoints + current} Points de Chance`, speaker : {alias : this.effect.label}})"
"script": "let fortunePoints = {{result.overcast.other.current}}\nlet current = this.actor.status.fortune.value\n\nthis.actor.update({\"data.status.fortune.value\" : fortunePoints + current})\n\nChatMessage.create({content : `<b>${this.actor.prototypeToken.name}</b> a désormais ${fortunePoints + current} Points de Chance`, speaker : {alias : this.effect.label}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/the-second-portent-of-amul.png",
@ -9165,7 +9165,7 @@
"effectApplication": "apply",
"effectTrigger": "oneTime",
"preventDuplicateEffects": false,
"script": "let current = this.actor.status.fate.value\n\nthis.actor.update({\"data.status.fate.value\" : current + 1})\n\nChatMessage.create({content : `<b>${this.actor.data.token.name}</b> a désormais ${current + 1} Points de Destin!`, speaker : {alias : this.effect.label}})"
"script": "let current = this.actor.status.fate.value\n\nthis.actor.update({\"data.status.fate.value\" : current + 1})\n\nChatMessage.create({content : `<b>${this.actor.prototypeToken.name}</b> a désormais ${current + 1} Points de Destin!`, speaker : {alias : this.effect.label}})"
}
},
"icon": "modules/wfrp4e-core/icons/spells/the-third-portent-of-amul.png",
@ -9344,7 +9344,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",
@ -9546,7 +9546,7 @@
"effectApplication": "actor",
"effectTrigger": "invoke",
"lore": true,
"script": "\n let value = 1\n let name = this.actor.data.token.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
"script": "\n let value = 1\n let name = this.actor.prototypeToken.name\n \n if (game.user.isGM) {\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n }\n else {\n game.wfrp4e.utility.postFear(value, name)\n }\n "
}
},
"icon": "modules/wfrp4e-core/icons/spells/beasts.png",

View File

@ -24,7 +24,7 @@
"wfrp4e": {
"effectApplication": "actor",
"effectTrigger": "prePrepareItems",
"script": "args.actor.data.flags.rangedDamageIncrease += 1"
"script": "args.actor.flags.rangedDamageIncrease += 1"
}
},
"icon": "modules/wfrp4e-core/icons/talents/accurate-shot.png",
@ -129,7 +129,7 @@
"wfrp4e": {
"effectApplication": "actor",
"effectTrigger": "prepareData",
"script": "args.actor.data.flags.ambi+= 1"
"script": "args.actor.flags.ambi+= 1"
}
},
"icon": "modules/wfrp4e-core/icons/talents/ambidextrous.png",
@ -2000,7 +2000,7 @@
"effectApplication": "actor",
"effectTrigger": "prePrepareItems",
"preventDuplicateEffects": false,
"script": "args.actor.data.flags.meleeDamageIncrease += 1"
"script": "args.actor.flags.meleeDamageIncrease += 1"
}
},
"icon": "modules/wfrp4e-core/icons/talents/strike-mighty-blow.png",

View File

@ -256,7 +256,7 @@
"effectTrigger": "takeDamage",
"preventDuplicateEffects": true,
"effectApplication": "actor",
"script": "let content = `<b>${this.effect.label}<\/b>: Toutes les cibles engagées avec <b>${this.actor.data.token.name}<\/b> subissent [[\/r 1d10]] dégats, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.data.token.name}})"
"script": "let content = `<b>${this.effect.label}<\/b>: Toutes les cibles engagées avec <b>${this.actor.prototypeToken.name}<\/b> subissent [[\/r 1d10]] dégats, modifiés par le BE et les PA.`\n\nChatMessage.create({content, speaker : {alias : this.actor.prototypeToken.name}})"
}
},
"_id": "mzNcVAruDOTiCGhS",
@ -353,7 +353,7 @@
"transfer": true,
"flags": {
"wfrp4e": {
"script": "let value = parseInt(this.item.specification.value)\nlet name = this.actor.data.token.name\n\nif (game.user.isGM && game.user.targets.size)\n{\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}",
"script": "let value = parseInt(this.item.specification.value)\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM && game.user.targets.size)\n{\n game.user.targets.forEach(t => {\n t.actor.applyFear(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postFear(value, name)\n}",
"preventDuplicateEffects": false,
"effectTrigger": "invoke",
"effectApplication": "actor"
@ -798,7 +798,7 @@
"label": "Attaque caudale",
"flags": {
"wfrp4e": {
"script": "let actorSize = game.wfrp4e.config.actorSizeNums[args.actor.details.size.value]\nlet attackerSize = game.wfrp4e.config.actorSizeNums[args.attacker.details.size.value]\n\nif (attackerSize > actorSize)\n{\n args.actor.addCondition(\"prone\")\n ChatMessage.create({content: `<b>Attaque caudale<\/b>: ${args.actor.data.token.name} est maintenant @Condition[Prone](A Terre)`, speaker : {alias: args.attacker.data.token.name}})\n}",
"script": "let actorSize = game.wfrp4e.config.actorSizeNums[args.actor.details.size.value]\nlet attackerSize = game.wfrp4e.config.actorSizeNums[args.attacker.details.size.value]\n\nif (attackerSize > actorSize)\n{\n args.actor.addCondition(\"prone\")\n ChatMessage.create({content: `<b>Attaque caudale<\/b>: ${this.actor.prototypeToken.name} est maintenant @Condition[Prone](A Terre)`, speaker : {alias: args.actor.prototypeToken.name}})\n}",
"effectApplication": "damage",
"effectTrigger": "applyDamage",
"preventDuplicateEffects": true
@ -830,7 +830,7 @@
"label": "Terreur",
"flags": {
"wfrp4e": {
"script": "let value = parseInt(this.item.specification.value)\nlet name = this.actor.data.token.name\n\nif (game.user.isGM && game.user.targets.size)\n{\n game.user.targets.forEach(t => {\n t.actor.applyTerror(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postTerror(value, name)\n}",
"script": "let value = parseInt(this.item.specification.value)\nlet name = this.actor.prototypeToken.name\n\nif (game.user.isGM && game.user.targets.size)\n{\n game.user.targets.forEach(t => {\n t.actor.applyTerror(value, name)\n })\n game.user.updateTokenTargets([]);\n}\nelse \n{\n game.wfrp4e.utility.postTerror(value, name)\n}",
"effectApplication": "actor",
"effectTrigger": "invoke",
"preventDuplicateEffects": false
@ -864,7 +864,7 @@
"effectTrigger": "applyDamage",
"preventDuplicateEffects": false,
"effectApplication": "damage",
"script": "let actorSize = game.wfrp4e.config.actorSizeNums[args.actor.details.size.value]\nlet attackerSize = game.wfrp4e.config.actorSizeNums[args.attacker.details.size.value]\n\nif (attackerSize > actorSize)\n{\n args.actor.addCondition(\"entangled\")\n ChatMessage.create({content: `<b>Langue préhensible<\/b>: ${args.actor.data.token.name} is now @Condition[Entangled]`, speaker : {alias: args.attacker.data.token.name}})\n}"
"script": "let actorSize = game.wfrp4e.config.actorSizeNums[args.actor.details.size.value]\nlet attackerSize = game.wfrp4e.config.actorSizeNums[args.attacker.details.size.value]\n\nif (attackerSize > actorSize)\n{\n args.actor.addCondition(\"entangled\")\n ChatMessage.create({content: `<b>Langue préhensible<\/b>: ${args.actor.prototypeToken.name} is now @Condition[Entangled]`, speaker : {alias: args.actor.prototypeToken.name}})\n}"
}
},
"transfer": true,

View File

@ -76,7 +76,7 @@
"wfrp4e": {
"effectTrigger": "oneTime",
"effectApplication": "apply",
"script": "args.actor.setupSkill(\"Résistance\", {context : {failure: \"1 Point de Corruption acquis\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\" && args.actor.data.type == \"character\")\n {\n args.actor.update({\"data.status.corruption.value\" : parseInt(args.actor.status.corruption.value) + 1})\n args.actor.checkCorruption()\n }\n })\n })",
"script": "args.actor.setupSkill(\"Résistance\", {context : {failure: \"1 Point de Corruption acquis\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\" && args.actor.type == \"character\")\n {\n args.actor.update({\"data.status.corruption.value\" : parseInt(args.actor.status.corruption.value) + 1})\n args.actor.checkCorruption()\n }\n })\n })",
"preventDuplicateEffects": false
}
}
@ -103,7 +103,7 @@
"wfrp4e": {
"effectTrigger": "oneTime",
"effectApplication": "apply",
"script": "args.actor.setupSkill(\"Résistance\", {context : {failure: \"1 Point de Corruption acquis\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\" && args.actor.data.type == \"character\")\n {\n args.actor.update({\"data.status.corruption.value\" : parseInt(args.actor.status.corruption.value) + 1})\n args.actor.checkCorruption()\n }\n })\n })",
"script": "args.actor.setupSkill(\"Résistance\", {context : {failure: \"1 Point de Corruption acquis\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\" && args.actor.type == \"character\")\n {\n args.actor.update({\"data.status.corruption.value\" : parseInt(args.actor.status.corruption.value) + 1})\n args.actor.checkCorruption()\n }\n })\n })",
"preventDuplicateEffects": false
}
}
@ -142,7 +142,7 @@
"wfrp4e": {
"effectTrigger": "oneTime",
"effectApplication": "apply",
"script": "args.actor.setupSkill(\"Résistance\", { context: { failure: \"1 Point de Corruption acquis\" } }).then(setupData => {\n args.actor.basicTest(setupData).then(test => {\n if (test.result.outcome == \"failure\" && args.actor.data.type == \"character\") {\n let msg = \"\"\n args.actor.update({ \"data.status.corruption.value\": parseInt(args.actor.status.corruption.value) + 1 })\n msg += `<b>${args.actor.data.token.name}</b> gains a Corruption point<br>`\n if ((test.result.outcome.roll % 11 == 0) || test.result.outcome.roll == 100 || test.result.outcome.roll == 99)\n msg += `<b>${args.actor.data.token.name}</b> reçoit une mutation (@Table[expandedmutatephys]{Physique} ou @Table[expandedmutatemental]{Mentale}) et reçoit @Compendium[wfrp4e-core.talents.hiU7vhBOVpVI8c7C]{Chaos Magic (Tzeentch)}`\n ChatMessage.create({content : msg, speaker : {alias : this.effect.label}})\n args.actor.checkCorruption()\n }\n })\n})",
"script": "args.actor.setupSkill(\"Résistance\", { context: { failure: \"1 Point de Corruption acquis\" } }).then(setupData => {\n args.actor.basicTest(setupData).then(test => {\n if (test.result.outcome == \"failure\" && args.actor.type == \"character\") {\n let msg = \"\"\n args.actor.update({ \"data.status.corruption.value\": parseInt(args.actor.status.corruption.value) + 1 })\n msg += `<b>${args.actor.prototypeToken.name}</b> gains a Corruption point<br>`\n if ((test.result.outcome.roll % 11 == 0) || test.result.outcome.roll == 100 || test.result.outcome.roll == 99)\n msg += `<b>${args.actor.prototypeToken.name}</b> reçoit une mutation (@Table[expandedmutatephys]{Physique} ou @Table[expandedmutatemental]{Mentale}) et reçoit @Compendium[wfrp4e-core.talents.hiU7vhBOVpVI8c7C]{Chaos Magic (Tzeentch)}`\n ChatMessage.create({content : msg, speaker : {alias : this.effect.label}})\n args.actor.checkCorruption()\n }\n })\n})",
"preventDuplicateEffects": false
}
}
@ -181,7 +181,7 @@
"wfrp4e": {
"effectTrigger": "oneTime",
"effectApplication": "apply",
"script": "args.actor.setupSkill(\"Résistance\", {context : {failure: \"1 Point de Corruption acquis\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\" && args.actor.data.type == \"character\")\n {\n args.actor.update({\"data.status.corruption.value\" : parseInt(args.actor.status.corruption.value) + 1})\n args.actor.checkCorruption()\n }\n })\n })",
"script": "args.actor.setupSkill(\"Résistance\", {context : {failure: \"1 Point de Corruption acquis\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\" && args.actor.type == \"character\")\n {\n args.actor.update({\"data.status.corruption.value\" : parseInt(args.actor.status.corruption.value) + 1})\n args.actor.checkCorruption()\n }\n })\n })",
"preventDuplicateEffects": false
}
}
@ -208,7 +208,7 @@
"wfrp4e": {
"effectTrigger": "oneTime",
"effectApplication": "apply",
"script": "args.actor.setupSkill(\"Résistance\", {context : {failure: \"1 Point de Corruption acquis\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\" && args.actor.data.type == \"character\")\n {\n args.actor.update({\"data.status.corruption.value\" : parseInt(args.actor.status.corruption.value) + 1})\n args.actor.checkCorruption()\n }\n })\n })",
"script": "args.actor.setupSkill(\"Résistance\", {context : {failure: \"1 Point de Corruption acquis\"}}).then(setupData => {\n args.actor.basicTest(setupData).then(test => \n {\n if (test.result.outcome == \"failure\" && args.actor.type == \"character\")\n {\n args.actor.update({\"data.status.corruption.value\" : parseInt(args.actor.status.corruption.value) + 1})\n args.actor.checkCorruption()\n }\n })\n })",
"preventDuplicateEffects": false
}
}

View File

@ -8,7 +8,7 @@
}
],
"url": "https://www.uberwald.me/gitea/public/foundryvtt-wh4-lang-fr-fr",
"version": "6.2.5",
"version": "6.2.6",
"esmodules": [
"babele-register.js",
"addon-register.js",
@ -136,7 +136,7 @@
}
],
"manifest": "https://www.uberwald.me/gitea/public/foundryvtt-wh4-lang-fr-fr/raw/v10/module.json",
"download": "https://www.uberwald.me/gitea/public/foundryvtt-wh4-lang-fr-fr/archive/foundryvtt-wh4-lang-fr-6.2.5.zip",
"download": "https://www.uberwald.me/gitea/public/foundryvtt-wh4-lang-fr-fr/archive/foundryvtt-wh4-lang-fr-6.2.6.zip",
"id": "wh4-fr-translation",
"compatibility": {
"minimum": "10",

View File

@ -726,9 +726,9 @@ export class WH4FRPatchConfig {
if (weaponLength > 3)
{
let improv = duplicate(game.wfrp4e.config.systemItems.improv)
improv.data.twohanded.value = args.item.twohanded.value
improv.data.offhand.value = args.item.offhand.value
args.item.data.update({"data" : improv.data, name : args.item.name + " (Combat au Contact")})
improv.system.twohanded.value = args.item.twohanded.value
improv.system.offhand.value = args.item.offhand.value
args.item.update({"system" : improv.system, name : args.item.name + " (Combat au Contact")})
}
}
`
@ -1161,7 +1161,7 @@ export class WH4FRPatchConfig {
let applicableCharacteristics = ["ws", "bs", "s", "fel", "ag", "t", "dex"]
if (applicableCharacteristics.includes(args.test.result.characteristic))
this.actor.addCondition("stunned")
else if (args.test.result.skill && applicableCharacteristics.includes(args.test.result.skill.data.characteristic.value))
else if (args.test.result.skill && applicableCharacteristics.includes(args.test.result.skill.system.characteristic.value))
this.actor.addCondition("stunned")
else if (args.test.result.weapon)
this.actor.addCondition("stunned")
@ -1210,7 +1210,7 @@ export class WH4FRPatchConfig {
{
if (test.result.outcome == "failure")
fromUuid("Compendium.wfrp4e-core.diseases.kKccDTGzWzSXCBOb").then(disease => {
args.actor.createEmbeddedEntity("OwnedItem", disease.data)
args.actor.createEmbeddedDocuments("Item", [disease.toObject()])
})
})
})