Compare commits
	
		
			1 Commits
		
	
	
		
			foundryvtt
			...
			foundryvtt
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 12fe0fd768 | 
| @@ -29,13 +29,13 @@ const _patch_eis = () => { | |||||||
|                 args.actor.setupSkill("Résistance", {context : {failure: "1 Point de Corruption reçu", success : "1 Point de Chance gagné"}}).then(setupData => { |                 args.actor.setupSkill("Résistance", {context : {failure: "1 Point de Corruption reçu", success : "1 Point de Chance gagné"}}).then(setupData => { | ||||||
|                     args.actor.basicTest(setupData).then(test =>  |                     args.actor.basicTest(setupData).then(test =>  | ||||||
|                      { |                      { | ||||||
|                          if (test.result.result == "success" && args.actor.type == "character") |                          if (test.result.result == "success" && args.actor.data.type == "character") | ||||||
|                          { |                          { | ||||||
|                              args.actor.update({"system.status.fortune.value" : args.actor.system.status.fortune.value + 1}) |                              args.actor.update({"data.status.fortune.value" : args.actor.data.data.status.fortune.value + 1}) | ||||||
|                          } |                          } | ||||||
|                          else if (test.result.result == "failure" && args.actor.type == "character") |                          else if (test.result.result == "failure" && args.actor.data.type == "character") | ||||||
|                          { |                          { | ||||||
|                           args.actor.update({"system.status.corruption.value" : args.actor.system.status.corruption.value + 1}) |                           args.actor.update({"data.status.corruption.value" : args.actor.data.data.status.corruption.value + 1}) | ||||||
|                          } |                          } | ||||||
|                      }) |                      }) | ||||||
|                   })` |                   })` | ||||||
| @@ -272,24 +272,24 @@ const __add_actors_translation = () => { | |||||||
|   const lang = game.settings.get('core', 'language'); |   const lang = game.settings.get('core', 'language'); | ||||||
|   if (lang == "fr") { |   if (lang == "fr") { | ||||||
|     let pack_array = []; |     let pack_array = []; | ||||||
|     for (let metadata of game.packs) { |     for (let metadata of game.data.packs) { | ||||||
|       if (!game.babele.isTranslated(metadata) && metadata.documentName === 'Actor') { |       if (!game.babele.isTranslated(metadata) && metadata.documentName === 'Actor') { | ||||||
|         //console.log("PACK : ", metadata); |         //console.log("PACK : ", metadata); | ||||||
|         let translations = { |         let translations = { | ||||||
|           "label": metadata.name, |           "label": metadata.name, | ||||||
|           "mapping": { |           "mapping": { | ||||||
|             "name": "name", |             "name": "name", | ||||||
|             "description": "system.biography.value", |             "description": "details.biography.value", | ||||||
|             "items": { |             "items": { | ||||||
|               "path": "items", |               "path": "items", | ||||||
|               "converter": "bestiary_traits" |               "converter": "bestiary_traits" | ||||||
|             }, |             }, | ||||||
|             "characteristics": { |             "characteristics": { | ||||||
|               "path": "system.characteristics", |               "path": "data.characteristics", | ||||||
|               "converter": "npc_characteristics" |               "converter": "npc_characteristics" | ||||||
|             }, |             }, | ||||||
|             "details": { |             "details": { | ||||||
|               "path": "system.details", |               "path": "data.details", | ||||||
|               "converter": "npc_details" |               "converter": "npc_details" | ||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|   | |||||||
| @@ -25,8 +25,8 @@ const vo_conditions = { | |||||||
| Hooks.once('init', () => { | Hooks.once('init', () => { | ||||||
|  |  | ||||||
|   // Check various settings in the installation   |   // Check various settings in the installation   | ||||||
|   game.modules.forEach((module, id) => { |   game.modules.forEach((module, name) => { | ||||||
|     if ( id == "wfrp4e-core" && module.active) { |     if ( name == "wfrp4e-core" && module.active) { | ||||||
|       compmod = "wfrp4e-core"; |       compmod = "wfrp4e-core"; | ||||||
|     } |     } | ||||||
|   } ); |   } ); | ||||||
| @@ -250,7 +250,6 @@ Hooks.once('init', () => { | |||||||
|           var name_en = trait_en.name.trim(); // strip \r in some traits name |           var name_en = trait_en.name.trim(); // strip \r in some traits name | ||||||
|              |              | ||||||
|           if ( trait_en.type == "trait") { |           if ( trait_en.type == "trait") { | ||||||
|             console.log("Trait translation", compmod, trait_en) |  | ||||||
|             if ( name_en.includes("Tentacles") ) { // Process specific Tentacles case |             if ( name_en.includes("Tentacles") ) { // Process specific Tentacles case | ||||||
|               var re  = /(.d*)x Tentacles/i; |               var re  = /(.d*)x Tentacles/i; | ||||||
|               var res = re.exec( name_en ); |               var res = re.exec( name_en ); | ||||||
| @@ -264,19 +263,19 @@ Hooks.once('init', () => { | |||||||
|               special = " (" + game.i18n.localize( res[2].trim() ) + ")"; // And the special keyword |               special = " (" + game.i18n.localize( res[2].trim() ) + ")"; // And the special keyword | ||||||
|             } |             } | ||||||
|             var trait_fr = game.babele.translate( compmod+'.traits', { name: name_en }, true ); |             var trait_fr = game.babele.translate( compmod+'.traits', { name: name_en }, true ); | ||||||
|             console.log(">>>>> Trait ?", name_en, nbt, trait_fr, trait_fr.name, special); |             //console.log(">>>>> Trait ?", name_en, nbt, trait_fr, trait_fr.name, special); | ||||||
|             trait_en.name = nbt + trait_fr.name + special; |             trait_en.name = nbt + trait_fr.name + special; | ||||||
|             if ( trait_fr.system && trait_fr.system.description && trait_fr.system.description.value ) { |             if ( trait_fr.data && trait_fr.data.description && trait_fr.data.description.value ) { | ||||||
|                 trait_en.system.description.value = trait_fr.system.description.value; |                 trait_en.data.description.value = trait_fr.data.description.value; | ||||||
|             } else if ( game.modules.get( 'wfrp4e-eis') ) { // No description in the FR compendium -> test other compendium if presenr |             } else if ( game.modules.get( 'wfrp4e-eis') ) { // No description in the FR compendium -> test other compendium if presenr | ||||||
|                 trait_fr = game.babele.translate( 'wfrp4e-eis.eisitems', { name: name_en }, true); |                 trait_fr = game.babele.translate( 'wfrp4e-eis.eisitems', { name: name_en }, true); | ||||||
|                 trait_en.name = nbt + trait_fr.name + special; |                 trait_en.name = nbt + trait_fr.name + special; | ||||||
|                 if ( trait_fr.system && trait_fr.system.description && trait_fr.system.description.value ) |                 if ( trait_fr.data && trait_fr.data.description && trait_fr.data.description.value ) | ||||||
|                   trait_en.system.description.value = trait_fr.system.description.value;               |                   trait_en.data.description.value = trait_fr.data.description.value;               | ||||||
|               } |               } | ||||||
|               if ( trait_en.system && trait_en.system.specification && isNaN(trait_en.system.specification.value) ) { // This is a string, so translate it |               if ( trait_en.data && trait_en.data.specification && isNaN(trait_en.data.specification.value) ) { // This is a string, so translate it | ||||||
|                 //console.log("Translating : ", trait_en.system.specification.value);             |                 //console.log("Translating : ", trait_en.data.specification.value);             | ||||||
|                 trait_en.system.specification.value = game.i18n.localize( trait_en.system.specification.value.trim() );             |                 trait_en.data.specification.value = game.i18n.localize( trait_en.data.specification.value.trim() );             | ||||||
|               } |               } | ||||||
|           } else if ( trait_en.type == "skill") { |           } else if ( trait_en.type == "skill") { | ||||||
|             if ( name_en.includes("(") && name_en.includes(")") ) { // Then process specific skills name with (xxxx) inside |             if ( name_en.includes("(") && name_en.includes(")") ) { // Then process specific skills name with (xxxx) inside | ||||||
| @@ -289,8 +288,8 @@ Hooks.once('init', () => { | |||||||
|             //console.log(">>>>> Skill ?", name_en, special, trait_fr.name, trait_fr); |             //console.log(">>>>> Skill ?", name_en, special, trait_fr.name, trait_fr); | ||||||
|             if (trait_fr.name != name_en) { // Translation OK |             if (trait_fr.name != name_en) { // Translation OK | ||||||
|               trait_en.name = trait_fr.name + special; |               trait_en.name = trait_fr.name + special; | ||||||
|               if ( trait_fr.system ) { |               if ( trait_fr.data ) { | ||||||
|                 trait_en.system.description.value = trait_fr.system.description.value; |                 trait_en.data.description.value = trait_fr.data.description.value; | ||||||
|               } |               } | ||||||
|             } |             } | ||||||
|            |            | ||||||
| @@ -298,8 +297,8 @@ Hooks.once('init', () => { | |||||||
|             var trait_fr = game.babele.translate( compmod+'.prayers', { name: name_en }, true); |             var trait_fr = game.babele.translate( compmod+'.prayers', { name: name_en }, true); | ||||||
|             //console.log(">>>>> Prayer ?", name_en, special, trait_fr.name ); |             //console.log(">>>>> Prayer ?", name_en, special, trait_fr.name ); | ||||||
|             trait_en.name = trait_fr.name + special; |             trait_en.name = trait_fr.name + special; | ||||||
|             if ( trait_fr.system && trait_fr.system.description && trait_fr.system.description.value ) |             if ( trait_fr.data && trait_fr.data.description && trait_fr.data.description.value ) | ||||||
|               trait_en.system.description.value = trait_fr.system.description.value;                                       |               trait_en.data.description.value = trait_fr.data.description.value;                                       | ||||||
|            |            | ||||||
|           } else if ( trait_en.type == "spell") { |           } else if ( trait_en.type == "spell") { | ||||||
|             var trait_fr = game.babele.translate( compmod+'.spells', { name: name_en }, true); |             var trait_fr = game.babele.translate( compmod+'.spells', { name: name_en }, true); | ||||||
| @@ -311,8 +310,8 @@ Hooks.once('init', () => { | |||||||
|             } |             } | ||||||
|             //console.log(">>>>> Spell ?", name_en, special, trait_fr.name ); |             //console.log(">>>>> Spell ?", name_en, special, trait_fr.name ); | ||||||
|             trait_en.name = trait_fr.name + special; |             trait_en.name = trait_fr.name + special; | ||||||
|             if ( trait_fr.system && trait_fr.system.description && trait_fr.system.description.value ) |             if ( trait_fr.data && trait_fr.data.description && trait_fr.data.description.value ) | ||||||
|               trait_en.system.description.value = trait_fr.system.description.value;                           |               trait_en.data.description.value = trait_fr.data.description.value;                           | ||||||
|           } else if ( trait_en.type == "talent") { |           } else if ( trait_en.type == "talent") { | ||||||
|             if ( name_en.includes("(") && name_en.includes(")") ) { // Then process specific skills name with (xxxx) inside |             if ( name_en.includes("(") && name_en.includes(")") ) { // Then process specific skills name with (xxxx) inside | ||||||
|               var re  = /(.*) +\((.*)\)/i; |               var re  = /(.*) +\((.*)\)/i; | ||||||
| @@ -327,21 +326,21 @@ Hooks.once('init', () => { | |||||||
|             } |             } | ||||||
|             if ( trait_fr.name == "Sprinter" || trait_fr.name != name_en)  { // Talent translated! |             if ( trait_fr.name == "Sprinter" || trait_fr.name != name_en)  { // Talent translated! | ||||||
|               trait_en.name = trait_fr.name.trim() + special; |               trait_en.name = trait_fr.name.trim() + special; | ||||||
|               if ( trait_fr.system ) { // Why ??? |               if ( trait_fr.data ) { // Why ??? | ||||||
|                 trait_en.system.description.value = trait_fr.system.description.value; |                 trait_en.data.description.value = trait_fr.data.description.value; | ||||||
|               } |               } | ||||||
|             } |             } | ||||||
|           } else if ( trait_en.type == "career") { |           } else if ( trait_en.type == "career") { | ||||||
|             var career_fr = game.babele.translate( compmod+'.careers', trait_en, true ); |             var career_fr = game.babele.translate( compmod+'.careers', trait_en, true ); | ||||||
|             console.log(">>>>> Career ?", name_en, career_fr.name ); |             console.log(">>>>> Career ?", name_en, career_fr.name ); | ||||||
|             trait_en.name = career_fr.name; |             trait_en.name = career_fr.name; | ||||||
|             trait_en.system = duplicate(career_fr.system); |             trait_en.data = duplicate(career_fr.data); | ||||||
|           } else if ( trait_en.type == "trapping" || trait_en.type == "weapon" || trait_en.type == "armour" || trait_en.type == "container" || trait_en.type == "money") { |           } else if ( trait_en.type == "trapping" || trait_en.type == "weapon" || trait_en.type == "armour" || trait_en.type == "container" || trait_en.type == "money") { | ||||||
|             var trapping_fr = game.babele.translate( compmod+'.trappings',  trait_en, true ); |             var trapping_fr = game.babele.translate( compmod+'.trappings',  trait_en, true ); | ||||||
|             //console.log(">>>>> Trapping ?", name_en, trapping_fr.name); |             //console.log(">>>>> Trapping ?", name_en, trapping_fr.name); | ||||||
|             trait_en.name = trapping_fr.name; |             trait_en.name = trapping_fr.name; | ||||||
|             if ( trapping_fr.system) { |             if ( trapping_fr.data) { | ||||||
|               trait_en.system.description  = trapping_fr.system.description; |               trait_en.data.description  = trapping_fr.data.description; | ||||||
|             } |             } | ||||||
|           } |           } | ||||||
|         } |         } | ||||||
| @@ -355,17 +354,11 @@ Hooks.once('init', () => { | |||||||
|       "trapping_qualities_flaws": (value) => { |       "trapping_qualities_flaws": (value) => { | ||||||
|         if ( value ) {  |         if ( value ) {  | ||||||
|           let newQF = []; |           let newQF = []; | ||||||
|           //console.log("ATOUTS", value, typeof(value)); |           //console.log("ATOUTS", value); | ||||||
|           let list = value |           var i=0; | ||||||
|           if (typeof(value) == "string") { |           //var re  = /(.*) (\d+)/i;         | ||||||
|             let myList = value.split(",") |           for (i=0; i<value.length; i++) { | ||||||
|             list = [] |             newQF[i] = duplicate(value[i]); | ||||||
|             for (let l of myList) { |  | ||||||
|               list.push( { name: l.trim() } ) |  | ||||||
|             } |  | ||||||
|           } |  | ||||||
|           for (let i=0; i<list.length; i++) {             |  | ||||||
|             newQF[i] = duplicate(list[i] ) |  | ||||||
|             if ( newQF[i].name == "Trap Blade") { |             if ( newQF[i].name == "Trap Blade") { | ||||||
|               newQF[i].name = "TrapBlade"; // Auto-patch, without space! |               newQF[i].name = "TrapBlade"; // Auto-patch, without space! | ||||||
|               //console.log("PATCHED", trim); |               //console.log("PATCHED", trim); | ||||||
|   | |||||||
| @@ -2,22 +2,22 @@ | |||||||
| 	"label": "Carrières Religieuses", | 	"label": "Carrières Religieuses", | ||||||
| 	"mapping": { | 	"mapping": { | ||||||
|     "skills": { |     "skills": { | ||||||
|       "path": "system.skills", |       "path": "data.skills", | ||||||
|       "converter": "career_skills" |       "converter": "career_skills" | ||||||
|     }, |     }, | ||||||
|     "talents": { |     "talents": { | ||||||
|       "path": "system.talents", |       "path": "data.talents", | ||||||
|       "converter": "career_talents" |       "converter": "career_talents" | ||||||
|     }, |     }, | ||||||
|     "class": { |     "class": { | ||||||
|       "path": "dasystemta.class.value", |       "path": "data.class.value", | ||||||
|       "converter": "generic_localization" |       "converter": "generic_localization" | ||||||
|     }, |     }, | ||||||
|     "careergroup": { |     "careergroup": { | ||||||
|       "path": "system.careergroup.value", |       "path": "data.careergroup.value", | ||||||
|       "converter": "career_careergroup" |       "converter": "career_careergroup" | ||||||
|     }, |     }, | ||||||
|     "trappings": "system.trappings" |     "trappings": "data.trappings" | ||||||
|   },	 |   },	 | ||||||
| 	"entries": [ | 	"entries": [ | ||||||
| 		{ | 		{ | ||||||
|   | |||||||
| @@ -1,13 +1,13 @@ | |||||||
| { | { | ||||||
| 	"label": "Objets Religieux", | 	"label": "Objets Religieux", | ||||||
|   "mapping": {       |   "mapping": {       | ||||||
|     "special":  "system.special.value", |     "special":  "data.special.value", | ||||||
|     "qualities": { |     "qualities": { | ||||||
|       "path": "system.qualities.value", |       "path": "data.qualities.value", | ||||||
|       "converter": "trapping_qualities_flaws" |       "converter": "trapping_qualities_flaws" | ||||||
|     }, |     }, | ||||||
|     "flaws": { |     "flaws": { | ||||||
|       "path": "system.flaws.value", |       "path": "data.flaws.value", | ||||||
|       "converter": "trapping_qualities_flaws" |       "converter": "trapping_qualities_flaws" | ||||||
|     } |     } | ||||||
|   },	 |   },	 | ||||||
|   | |||||||
| @@ -6,7 +6,7 @@ | |||||||
|       "converter": "bestiary_traits" |       "converter": "bestiary_traits" | ||||||
|       }, |       }, | ||||||
|     "characteristics": { |     "characteristics": { | ||||||
|       "path": "system.characteristics", |       "path": "data.characteristics", | ||||||
|       "converter": "npc_characteristics" |       "converter": "npc_characteristics" | ||||||
|     } |     } | ||||||
|   }, |   }, | ||||||
|   | |||||||
| @@ -2,19 +2,19 @@ | |||||||
| 	"label": "Carrières", | 	"label": "Carrières", | ||||||
| 	"mapping": { | 	"mapping": { | ||||||
|     "skills": { |     "skills": { | ||||||
|       "path": "system.skills", |       "path": "data.skills", | ||||||
|       "converter": "career_skills" |       "converter": "career_skills" | ||||||
|     }, |     }, | ||||||
|     "talents": { |     "talents": { | ||||||
|       "path": "system.talents", |       "path": "data.talents", | ||||||
|       "converter": "career_talents" |       "converter": "career_talents" | ||||||
|     }, |     }, | ||||||
|     "class": { |     "class": { | ||||||
|       "path": "system.class.value", |       "path": "data.class.value", | ||||||
|       "converter": "generic_localization" |       "converter": "generic_localization" | ||||||
|     }, |     }, | ||||||
|     "careergroup": { |     "careergroup": { | ||||||
|       "path": "system.careergroup.value", |       "path": "data.careergroup.value", | ||||||
|       "converter": "career_careergroup" |       "converter": "career_careergroup" | ||||||
|     }, |     }, | ||||||
|     "trappings": "system.trappings" |     "trappings": "system.trappings" | ||||||
|   | |||||||
| @@ -3,7 +3,7 @@ | |||||||
|   "mapping": { |   "mapping": { | ||||||
|       "location": { |       "location": { | ||||||
|           "converter": "generic_localization", |           "converter": "generic_localization", | ||||||
|           "path": "system.location.value" |           "path": "data.location.value" | ||||||
|       }, |       }, | ||||||
|       "effects": "effects" |       "effects": "effects" | ||||||
|   }, |   }, | ||||||
| @@ -143,7 +143,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.qn4ZpvTQIX4rcJDl\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.qn4ZpvTQIX4rcJDl\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", | ||||||
| @@ -175,7 +175,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.diseases.kKccDTGzWzSXCBOb\").then(disease=> {\n args.actor.createEmbeddedDocuments(\"Item\", disease.toObject())\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.diseases.kKccDTGzWzSXCBOb\").then(disease=> {\n args.actor.createEmbeddedEntity(\"OwnedItem\", disease.data)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", | ||||||
| @@ -557,7 +557,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.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})" |                         "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})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", | ||||||
| @@ -608,7 +608,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.EaqlLRQigwnsEAXX\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()] )\n} )" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.EaqlLRQigwnsEAXX\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", | ||||||
| @@ -640,7 +640,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.createEmbeddedDocuments(\"Item\", [injury.toObject()])\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.createEmbeddedEntity(\"OwnedItem\", injury)\n})\n\n\n}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", | ||||||
| @@ -729,7 +729,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.nF5z1OEhpi4t6a6S\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject() ] )\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.nF5z1OEhpi4t6a6S\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", | ||||||
| @@ -848,7 +848,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid('Compendium.wfrp4e-core.injuries.EaqlLRQigwnsEAXX').then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()] )\n})" |                         "script": "fromUuid('Compendium.wfrp4e-core.injuries.EaqlLRQigwnsEAXX').then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", | ||||||
| @@ -1004,7 +1004,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.QluSTTTq3viHJJUh\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.QluSTTTq3viHJJUh\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", | ||||||
| @@ -1054,7 +1054,7 @@ | |||||||
|                     "wfrp4e": { |                     "wfrp4e": { | ||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.2A7SW9eXsm7MvLsk\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.2A7SW9eXsm7MvLsk\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", | ||||||
| @@ -1246,7 +1246,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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})" |                         "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})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", | ||||||
| @@ -1321,7 +1321,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "endCombat", |                         "effectTrigger": "endCombat", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.createEmbeddedDocuments(\"Item\", [injury..toObject()])\n            this.actor.deleteEmbeddedDocuments(\"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.createEmbeddedEntity(\"OwnedItem\", injury.data)\n            this.actor.deleteEmbeddedEntity(\"ActiveEffect\", this.effect._id)\n          })\n        }\n      })\n    })" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", | ||||||
| @@ -1461,7 +1461,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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     })" |                         "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     })" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", | ||||||
| @@ -1644,7 +1644,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.GlShFJF2TpsNh1FX\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.GlShFJF2TpsNh1FX\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", | ||||||
| @@ -1772,7 +1772,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.SYjWiKDzMS6CtROJ\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()] )\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.SYjWiKDzMS6CtROJ\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", | ||||||
| @@ -1804,7 +1804,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.eWPN3CV2Eddwz8aM\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.eWPN3CV2Eddwz8aM\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", | ||||||
| @@ -1927,7 +1927,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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})" |                         "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})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", | ||||||
| @@ -2158,7 +2158,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.2iult41Jehz0F1O8\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.2iult41Jehz0F1O8\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", | ||||||
| @@ -2319,7 +2319,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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     })" |                         "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     })" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", | ||||||
| @@ -2367,7 +2367,7 @@ | |||||||
|                     "wfrp4e": { |                     "wfrp4e": { | ||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.diseases.M8XyRs9DN12XsFTQ\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.diseases.M8XyRs9DN12XsFTQ\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", | ||||||
| @@ -2438,7 +2438,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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     })" |                         "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     })" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", | ||||||
| @@ -2470,7 +2470,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.qn4ZpvTQIX4rcJDl\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.qn4ZpvTQIX4rcJDl\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", | ||||||
| @@ -2521,7 +2521,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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     })" |                         "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     })" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", | ||||||
| @@ -2572,7 +2572,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.nbhn2wX35b7Jrcbg\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.nbhn2wX35b7Jrcbg\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", | ||||||
| @@ -2640,7 +2640,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.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     })" |                         "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     })" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", | ||||||
| @@ -2696,7 +2696,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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     })" |                         "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     })" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", | ||||||
| @@ -2764,7 +2764,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.SYjWiKDzMS6CtROJ\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()] )\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.SYjWiKDzMS6CtROJ\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", | ||||||
| @@ -2954,7 +2954,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.weczkAMPlTjX7lqU\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.weczkAMPlTjX7lqU\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", | ||||||
| @@ -3025,7 +3025,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.8piWcBKFlQ2J1E3A\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.8piWcBKFlQ2J1E3A\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/head.png", | ||||||
| @@ -3182,7 +3182,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.createEmbeddedDocuments(\"Item\", [injury.toObject()])\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.createEmbeddedEntity(\"OwnedItem\", injury.data)\n          })\n        }\n      })\n    })\n  }" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", | ||||||
| @@ -3272,7 +3272,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.gz2xy41OSVZ8YBgI\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.gz2xy41OSVZ8YBgI\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", | ||||||
| @@ -3460,7 +3460,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.k00PimCWkff11IA0\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.k00PimCWkff11IA0\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", | ||||||
| @@ -3492,7 +3492,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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     })" |                         "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     })" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornleg.png", | ||||||
| @@ -3582,7 +3582,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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     })" |                         "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     })" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", | ||||||
| @@ -3614,7 +3614,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.GlShFJF2TpsNh1FX\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.GlShFJF2TpsNh1FX\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornarm.png", | ||||||
| @@ -3646,7 +3646,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.7rBhIRo96Mydo0Cv\").then(injury => {\n args.actor.createEmbeddedDocuments(\"Item\", [injury.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.injuries.7rBhIRo96Mydo0Cv\").then(injury => {\n args.actor.createEmbeddedEntity(\"OwnedItem\", injury)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", |                 "icon": "modules/wfrp4e-core/icons/injuries/tornbody.png", | ||||||
|   | |||||||
| @@ -1,12 +1,12 @@ | |||||||
| { | { | ||||||
|   "mapping": { |   "mapping": { | ||||||
|     "durationValue": "system.duration.value", |     "durationValue": "data.duration.value", | ||||||
|     "durationUnit": "system.duration.unit", |     "durationUnit": "data.duration.unit", | ||||||
|     "contraction": "system.contraction.value", |     "contraction": "data.contraction.value", | ||||||
|     "incubationValue": "system.incubation.value", |     "incubationValue": "data.incubation.value", | ||||||
|     "incubationUnit": "system.incubation.unit", |     "incubationUnit": "data.incubation.unit", | ||||||
|     "symptoms": "system.symptoms.value", |     "symptoms": "data.symptoms.value", | ||||||
|     "permanent": "system.permanent.value", |     "permanent": "data.permanent.value", | ||||||
|     "effects": "effects" |     "effects": "effects" | ||||||
|   }, |   }, | ||||||
|   "label": "Maladies", |   "label": "Maladies", | ||||||
|   | |||||||
| @@ -1,9 +1,9 @@ | |||||||
| { | { | ||||||
| 	"label": "Blessures", | 	"label": "Blessures", | ||||||
|   "mapping": {       |   "mapping": {       | ||||||
|     "penalty": "system.penalty.value",     |     "penalty": "data.penalty.value",     | ||||||
|     "location": { |     "location": { | ||||||
|       "path": "system.location.value", |       "path": "data.location.value", | ||||||
|       "converter": "generic_localization" |       "converter": "generic_localization" | ||||||
|     }, |     }, | ||||||
|     "effects": "effects" |     "effects": "effects" | ||||||
|   | |||||||
										
											
												File diff suppressed because one or more lines are too long
											
										
									
								
							| @@ -2,11 +2,11 @@ | |||||||
| 	"label": "Mutations", | 	"label": "Mutations", | ||||||
| 	"mapping": { | 	"mapping": { | ||||||
|     "modifier": { |     "modifier": { | ||||||
|         "path": "system.modifier.value", |         "path": "data.modifier.value", | ||||||
|         "converter": "mutations_modifier" |         "converter": "mutations_modifier" | ||||||
|     }, |     }, | ||||||
|     "mutationType": { |     "mutationType": { | ||||||
|         "path": "system.mutationType.value", |         "path": "data.mutationType.value", | ||||||
|         "converter": "generic_localization" |         "converter": "generic_localization" | ||||||
|     }, |     }, | ||||||
|     "effects": { |     "effects": { | ||||||
|   | |||||||
| @@ -2,19 +2,19 @@ | |||||||
| 	"label": "Prières", | 	"label": "Prières", | ||||||
| 	"mapping": { | 	"mapping": { | ||||||
|     "pduration": { |     "pduration": { | ||||||
|       "path": "system.duration.value", |       "path": "data.duration.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "prange": { |     "prange": { | ||||||
|       "path": "system.range.value", |       "path": "data.range.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "ptarget": { |     "ptarget": { | ||||||
|       "path": "system.target.value", |       "path": "data.target.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     },     |     },     | ||||||
|     "pdamage": { |     "pdamage": { | ||||||
|       "path": "system.damage.value", |       "path": "data.damage.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "effects": "effects" |     "effects": "effects" | ||||||
| @@ -88,7 +88,7 @@ | |||||||
|                     "wfrp4e": { |                     "wfrp4e": { | ||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "prePrepareData", |                         "effectTrigger": "prePrepareData", | ||||||
|                         "script": "args.actor.items = args.actor.items.filter(i => i.type != \"psychology\")" |                         "script": "args.actor.data.items = args.actor.data.items.filter(i => i.type != \"psychology\")" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", |                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", | ||||||
| @@ -753,7 +753,7 @@ | |||||||
|                     "wfrp4e": { |                     "wfrp4e": { | ||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.psychologies.5hH73j2NgPdsLCZN\").then(item => {\n    args.actor.createEmbeddedDocuments(\"Item\", [item.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.psychologies.5hH73j2NgPdsLCZN\").then(item => {\n    args.actor.createEmbeddedEntity(\"OwnedItem\", item)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", |                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", | ||||||
| @@ -802,7 +802,7 @@ | |||||||
|                     "wfrp4e": { |                     "wfrp4e": { | ||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.talents.J9MK0AIaTbvd5oF6\").then(item => {\n    args.actor.createEmbeddedDocuments(\"Item\", [item.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.talents.J9MK0AIaTbvd5oF6\").then(item => {\n    args.actor.createEmbeddedEntity(\"OwnedItem\", item)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", |                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", | ||||||
| @@ -898,7 +898,7 @@ | |||||||
|                     "wfrp4e": { |                     "wfrp4e": { | ||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.talents.CV9btQn09S9Fn8Jk\").then(item => {\n    args.actor.createEmbeddedDocuments(\"Item\", [item.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.talents.CV9btQn09S9Fn8Jk\").then(item => {\n    args.actor.createEmbeddedEntity(\"OwnedItem\", item)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", |                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", | ||||||
| @@ -989,7 +989,7 @@ | |||||||
|                     "wfrp4e": { |                     "wfrp4e": { | ||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "script": "fromUuid(\"Compendium.wfrp4e-core.talents.g4Q6AtzZuo5iIvD4\").then(item => {\n    args.actor.createEmbeddedDocuments(\"Item\", [item.toObject()])\n})" |                         "script": "fromUuid(\"Compendium.wfrp4e-core.talents.g4Q6AtzZuo5iIvD4\").then(item => {\n    args.actor.createEmbeddedEntity(\"OwnedItem\", item)\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", |                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", | ||||||
| @@ -1142,7 +1142,7 @@ | |||||||
|                     "wfrp4e": { |                     "wfrp4e": { | ||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "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.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.data.has(\"Démoniaque\"))\n{\n  args.actor.addCondition(\"ablaze\")\n}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", |                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", | ||||||
| @@ -1235,7 +1235,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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})" |                         "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})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", |                 "icon": "modules/wfrp4e-core/icons/prayers/miracles.png", | ||||||
|   | |||||||
| @@ -2,19 +2,19 @@ | |||||||
| 	"label": "Sorts", | 	"label": "Sorts", | ||||||
| 	"mapping": { | 	"mapping": { | ||||||
|     "sduration": { |     "sduration": { | ||||||
|       "path": "system.duration.value", |       "path": "data.duration.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "srange": { |     "srange": { | ||||||
|       "path": "system.range.value", |       "path": "data.range.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "starget": { |     "starget": { | ||||||
|       "path": "system.target.value", |       "path": "data.target.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     },     |     },     | ||||||
|     "sdamage": { |     "sdamage": { | ||||||
|       "path": "system.damage.value", |       "path": "data.damage.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "effects": "effects" |     "effects": "effects" | ||||||
| @@ -121,7 +121,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -550,7 +550,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -746,7 +746,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -804,7 +804,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -1008,7 +1008,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.prototypeToken.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.data.token.name}`, speaker : {alias: caster.name}})\n                })\n             }\n         }\n    }\n })" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/banishment.png", |                 "icon": "modules/wfrp4e-core/icons/spells/banishment.png", | ||||||
| @@ -1113,7 +1113,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -1136,7 +1136,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -1184,7 +1184,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -1213,7 +1213,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -1486,7 +1486,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -1688,7 +1688,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -1890,7 +1890,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -2100,7 +2100,7 @@ | |||||||
|                         "effectApplication": "damage", |                         "effectApplication": "damage", | ||||||
|                         "effectTrigger": "applyDamage", |                         "effectTrigger": "applyDamage", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.prototypeToken.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.data.token.name}</b> subit ${woundsGained} Points de Blessures` })" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/caress-of-laniph.png", |                 "icon": "modules/wfrp4e-core/icons/spells/caress-of-laniph.png", | ||||||
| @@ -2221,7 +2221,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "preOpposedDefender", |                         "effectTrigger": "preOpposedDefender", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.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}" |                         "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}" | ||||||
|                       } |                       } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/cerulean-shield.png", |                 "icon": "modules/wfrp4e-core/icons/spells/cerulean-shield.png", | ||||||
| @@ -2267,7 +2267,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -2596,7 +2596,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "takeDamage", |                         "effectTrigger": "takeDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "preventDuplicateEffects": true, | ||||||
|                         "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}})" |                         "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}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/blank.png", |                 "icon": "modules/wfrp4e-core/icons/blank.png", | ||||||
| @@ -2628,7 +2628,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "takeDamage", |                         "effectTrigger": "takeDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "preventDuplicateEffects": true, | ||||||
|                         "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}})" |                         "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}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -2645,7 +2645,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -2676,7 +2676,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "takeDamage", |                         "effectTrigger": "takeDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "preventDuplicateEffects": true, | ||||||
|                         "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}})" |                         "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}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/daemonology.png", |                 "icon": "modules/wfrp4e-core/icons/spells/daemonology.png", | ||||||
| @@ -2708,7 +2708,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "takeDamage", |                         "effectTrigger": "takeDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "preventDuplicateEffects": true, | ||||||
|                         "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}})" |                         "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}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/death.png", |                 "icon": "modules/wfrp4e-core/icons/spells/death.png", | ||||||
| @@ -2756,7 +2756,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "takeDamage", |                         "effectTrigger": "takeDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "preventDuplicateEffects": true, | ||||||
|                         "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}})" |                         "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}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/fire.png", |                 "icon": "modules/wfrp4e-core/icons/spells/fire.png", | ||||||
| @@ -2804,7 +2804,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "takeDamage", |                         "effectTrigger": "takeDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "preventDuplicateEffects": true, | ||||||
|                         "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}})" |                         "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}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/heavens.png", |                 "icon": "modules/wfrp4e-core/icons/spells/heavens.png", | ||||||
| @@ -2852,7 +2852,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "takeDamage", |                         "effectTrigger": "takeDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "preventDuplicateEffects": true, | ||||||
|                         "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}})" |                         "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}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/life.png", |                 "icon": "modules/wfrp4e-core/icons/spells/life.png", | ||||||
| @@ -2900,7 +2900,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "takeDamage", |                         "effectTrigger": "takeDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "preventDuplicateEffects": true, | ||||||
|                         "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}})" |                         "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}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/light.png", |                 "icon": "modules/wfrp4e-core/icons/spells/light.png", | ||||||
| @@ -2948,7 +2948,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "takeDamage", |                         "effectTrigger": "takeDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "preventDuplicateEffects": true, | ||||||
|                         "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}})" |                         "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}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/metal.png", |                 "icon": "modules/wfrp4e-core/icons/spells/metal.png", | ||||||
| @@ -2996,7 +2996,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "takeDamage", |                         "effectTrigger": "takeDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "preventDuplicateEffects": true, | ||||||
|                         "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}})" |                         "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}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/necromancy.png", |                 "icon": "modules/wfrp4e-core/icons/spells/necromancy.png", | ||||||
| @@ -3028,7 +3028,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "takeDamage", |                         "effectTrigger": "takeDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "preventDuplicateEffects": true, | ||||||
|                         "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}})" |                         "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}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/shadow.png", |                 "icon": "modules/wfrp4e-core/icons/spells/shadow.png", | ||||||
| @@ -3287,7 +3287,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -3672,7 +3672,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -4101,7 +4101,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -4328,7 +4328,7 @@ | |||||||
|                         "effectApplication": "damage", |                         "effectApplication": "damage", | ||||||
|                         "effectTrigger": "applyDamage", |                         "effectTrigger": "applyDamage", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.prototypeToken.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.data.token.name} récupère 1 blessure.`})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/petty.png", |                 "icon": "modules/wfrp4e-core/icons/spells/petty.png", | ||||||
| @@ -4358,7 +4358,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -4585,7 +4585,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "endRound", |                         "effectTrigger": "endRound", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.prototypeToken.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.data.token.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", |                 "icon": "modules/wfrp4e-core/icons/spells/earthblood.png", | ||||||
| @@ -4734,7 +4734,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -5211,7 +5211,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/blank.png", |                 "icon": "modules/wfrp4e-core/icons/blank.png", | ||||||
| @@ -5236,7 +5236,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                       } |                       } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/blank.png", |                 "icon": "modules/wfrp4e-core/icons/blank.png", | ||||||
| @@ -5268,7 +5268,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -5285,7 +5285,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -5316,7 +5316,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/daemonology.png", |                 "icon": "modules/wfrp4e-core/icons/spells/daemonology.png", | ||||||
| @@ -5348,7 +5348,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/death.png", |                 "icon": "modules/wfrp4e-core/icons/spells/death.png", | ||||||
| @@ -5396,7 +5396,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/fire.png", |                 "icon": "modules/wfrp4e-core/icons/spells/fire.png", | ||||||
| @@ -5444,7 +5444,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/heavens.png", |                 "icon": "modules/wfrp4e-core/icons/spells/heavens.png", | ||||||
| @@ -5492,7 +5492,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/life.png", |                 "icon": "modules/wfrp4e-core/icons/spells/life.png", | ||||||
| @@ -5540,7 +5540,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/light.png", |                 "icon": "modules/wfrp4e-core/icons/spells/light.png", | ||||||
| @@ -5588,7 +5588,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/metal.png", |                 "icon": "modules/wfrp4e-core/icons/spells/metal.png", | ||||||
| @@ -5636,7 +5636,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/necromancy.png", |                 "icon": "modules/wfrp4e-core/icons/spells/necromancy.png", | ||||||
| @@ -5668,7 +5668,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/shadow.png", |                 "icon": "modules/wfrp4e-core/icons/spells/shadow.png", | ||||||
| @@ -5932,7 +5932,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -6355,7 +6355,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -6603,7 +6603,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.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})" |                         "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})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/healing-light.png", |                 "icon": "modules/wfrp4e-core/icons/spells/healing-light.png", | ||||||
| @@ -6677,7 +6677,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -6787,7 +6787,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -7047,7 +7047,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -7249,7 +7249,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -7576,7 +7576,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.prototypeToken.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.data.token.name} regains ${healed} Wounds`, speaker : {alias : this.effect.label}})\n   }\n})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/nostrum.png", |                 "icon": "modules/wfrp4e-core/icons/spells/nostrum.png", | ||||||
| @@ -7842,7 +7842,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -8443,7 +8443,7 @@ | |||||||
|                         "effectApplication": "damage", |                         "effectApplication": "damage", | ||||||
|                         "effectTrigger": "applyDamage", |                         "effectTrigger": "applyDamage", | ||||||
|                         "preventDuplicateEffects": true, |                         "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.prototypeToken.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.data.token.name}</b> récupère ${woundsGained} Points de Blessures`, alias : {speaker : this.effect.label}})" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/steal-life.png", |                 "icon": "modules/wfrp4e-core/icons/spells/steal-life.png", | ||||||
| @@ -8566,7 +8566,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -8770,7 +8770,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "preventDuplicateEffects": false, |                         "preventDuplicateEffects": false, | ||||||
|                         "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}" |                         "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}" | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/blank.png", |                 "icon": "modules/wfrp4e-core/icons/blank.png", | ||||||
| @@ -8794,7 +8794,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -9015,7 +9015,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -9069,7 +9069,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.prototypeToken.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.data.token.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", |                 "icon": "modules/wfrp4e-core/icons/spells/the-first-portent-of-amul.png", | ||||||
| @@ -9117,7 +9117,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.prototypeToken.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.data.token.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", |                 "icon": "modules/wfrp4e-core/icons/spells/the-second-portent-of-amul.png", | ||||||
| @@ -9165,7 +9165,7 @@ | |||||||
|                         "effectApplication": "apply", |                         "effectApplication": "apply", | ||||||
|                         "effectTrigger": "oneTime", |                         "effectTrigger": "oneTime", | ||||||
|                         "preventDuplicateEffects": false, |                         "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.prototypeToken.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.data.token.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", |                 "icon": "modules/wfrp4e-core/icons/spells/the-third-portent-of-amul.png", | ||||||
| @@ -9344,7 +9344,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
| @@ -9546,7 +9546,7 @@ | |||||||
|                         "effectApplication": "actor", |                         "effectApplication": "actor", | ||||||
|                         "effectTrigger": "invoke", |                         "effectTrigger": "invoke", | ||||||
|                         "lore": true, |                         "lore": true, | ||||||
|                         "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                " |                         "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                " | ||||||
|                     } |                     } | ||||||
|                 }, |                 }, | ||||||
|                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", |                 "icon": "modules/wfrp4e-core/icons/spells/beasts.png", | ||||||
|   | |||||||
| @@ -1,7 +1,7 @@ | |||||||
| { | { | ||||||
|   "label": "Talents", |   "label": "Talents", | ||||||
|   "mapping": { |   "mapping": { | ||||||
|     "tests": "system.tests.value", |     "tests": "data.tests.value", | ||||||
|     "effects": "effects" |     "effects": "effects" | ||||||
|   }, |   }, | ||||||
|   "entries": [ |   "entries": [ | ||||||
| @@ -24,7 +24,7 @@ | |||||||
|             "wfrp4e": { |             "wfrp4e": { | ||||||
|               "effectApplication": "actor", |               "effectApplication": "actor", | ||||||
|               "effectTrigger": "prePrepareItems", |               "effectTrigger": "prePrepareItems", | ||||||
|               "script": "args.actor.flags.rangedDamageIncrease += 1" |               "script": "args.actor.data.flags.rangedDamageIncrease += 1" | ||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|           "icon": "modules/wfrp4e-core/icons/talents/accurate-shot.png", |           "icon": "modules/wfrp4e-core/icons/talents/accurate-shot.png", | ||||||
| @@ -129,7 +129,7 @@ | |||||||
|             "wfrp4e": { |             "wfrp4e": { | ||||||
|               "effectApplication": "actor", |               "effectApplication": "actor", | ||||||
|               "effectTrigger": "prepareData", |               "effectTrigger": "prepareData", | ||||||
|               "script": "args.actor.flags.ambi+= 1" |               "script": "args.actor.data.flags.ambi+= 1" | ||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|           "icon": "modules/wfrp4e-core/icons/talents/ambidextrous.png", |           "icon": "modules/wfrp4e-core/icons/talents/ambidextrous.png", | ||||||
| @@ -2000,7 +2000,7 @@ | |||||||
|               "effectApplication": "actor", |               "effectApplication": "actor", | ||||||
|               "effectTrigger": "prePrepareItems", |               "effectTrigger": "prePrepareItems", | ||||||
|               "preventDuplicateEffects": false, |               "preventDuplicateEffects": false, | ||||||
|               "script": "args.actor.flags.meleeDamageIncrease += 1" |               "script": "args.actor.data.flags.meleeDamageIncrease += 1" | ||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|           "icon": "modules/wfrp4e-core/icons/talents/strike-mighty-blow.png", |           "icon": "modules/wfrp4e-core/icons/talents/strike-mighty-blow.png", | ||||||
|   | |||||||
| @@ -256,7 +256,7 @@ | |||||||
|               "effectTrigger": "takeDamage", |               "effectTrigger": "takeDamage", | ||||||
|               "preventDuplicateEffects": true, |               "preventDuplicateEffects": true, | ||||||
|               "effectApplication": "actor", |               "effectApplication": "actor", | ||||||
|               "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}})" |               "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}})" | ||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|           "_id": "mzNcVAruDOTiCGhS", |           "_id": "mzNcVAruDOTiCGhS", | ||||||
| @@ -353,7 +353,7 @@ | |||||||
|           "transfer": true, |           "transfer": true, | ||||||
|           "flags": { |           "flags": { | ||||||
|             "wfrp4e": { |             "wfrp4e": { | ||||||
|               "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}", |               "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}", | ||||||
|               "preventDuplicateEffects": false, |               "preventDuplicateEffects": false, | ||||||
|               "effectTrigger": "invoke", |               "effectTrigger": "invoke", | ||||||
|               "effectApplication": "actor" |               "effectApplication": "actor" | ||||||
| @@ -798,7 +798,7 @@ | |||||||
|           "label": "Attaque caudale", |           "label": "Attaque caudale", | ||||||
|           "flags": { |           "flags": { | ||||||
|             "wfrp4e": { |             "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>: ${this.actor.prototypeToken.name} est maintenant @Condition[Prone](A Terre)`, speaker : {alias: args.actor.prototypeToken.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>: ${args.actor.data.token.name} est maintenant @Condition[Prone](A Terre)`, speaker : {alias: args.attacker.data.token.name}})\n}", | ||||||
|               "effectApplication": "damage", |               "effectApplication": "damage", | ||||||
|               "effectTrigger": "applyDamage", |               "effectTrigger": "applyDamage", | ||||||
|               "preventDuplicateEffects": true |               "preventDuplicateEffects": true | ||||||
| @@ -830,7 +830,7 @@ | |||||||
|           "label": "Terreur", |           "label": "Terreur", | ||||||
|           "flags": { |           "flags": { | ||||||
|             "wfrp4e": { |             "wfrp4e": { | ||||||
|               "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}", |               "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}", | ||||||
|               "effectApplication": "actor", |               "effectApplication": "actor", | ||||||
|               "effectTrigger": "invoke", |               "effectTrigger": "invoke", | ||||||
|               "preventDuplicateEffects": false |               "preventDuplicateEffects": false | ||||||
| @@ -864,7 +864,7 @@ | |||||||
|               "effectTrigger": "applyDamage", |               "effectTrigger": "applyDamage", | ||||||
|               "preventDuplicateEffects": false, |               "preventDuplicateEffects": false, | ||||||
|               "effectApplication": "damage", |               "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.prototypeToken.name} is now @Condition[Entangled]`, speaker : {alias: args.actor.prototypeToken.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.data.token.name} is now @Condition[Entangled]`, speaker : {alias: args.attacker.data.token.name}})\n}" | ||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|           "transfer": true, |           "transfer": true, | ||||||
|   | |||||||
| @@ -1,13 +1,13 @@ | |||||||
| { | { | ||||||
| 	"label": "Equipement",   | 	"label": "Equipement",   | ||||||
| 	"mapping": {       | 	"mapping": {       | ||||||
|     "special":  "system.special.value", |     "special":  "data.special.value", | ||||||
|     "qualities": { |     "qualities": { | ||||||
|       "path": "system.qualities.value", |       "path": "data.qualities.value", | ||||||
|       "converter": "trapping_qualities_flaws" |       "converter": "trapping_qualities_flaws" | ||||||
|     }, |     }, | ||||||
|     "flaws": { |     "flaws": { | ||||||
|       "path": "system.flaws.value", |       "path": "data.flaws.value", | ||||||
|       "converter": "trapping_qualities_flaws" |       "converter": "trapping_qualities_flaws" | ||||||
|     }, |     }, | ||||||
|     "effects": "effects" |     "effects": "effects" | ||||||
|   | |||||||
| @@ -2,19 +2,19 @@ | |||||||
| 	"label": "Items (Death on the Reik)", | 	"label": "Items (Death on the Reik)", | ||||||
|   "mapping": { |   "mapping": { | ||||||
|     "sduration": { |     "sduration": { | ||||||
|       "path": "system.duration.value", |       "path": "data.duration.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "srange": { |     "srange": { | ||||||
|       "path": "system.range.value", |       "path": "data.range.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "starget": { |     "starget": { | ||||||
|       "path": "system.target.value", |       "path": "data.target.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     },     |     },     | ||||||
|     "sdamage": { |     "sdamage": { | ||||||
|       "path": "system.damage.value", |       "path": "data.damage.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     } |     } | ||||||
|   }, |   }, | ||||||
|   | |||||||
| @@ -2,22 +2,22 @@ | |||||||
| 	"label": "Items Ennemis Intérieur", | 	"label": "Items Ennemis Intérieur", | ||||||
|   "mapping": { |   "mapping": { | ||||||
|     "skills": { |     "skills": { | ||||||
|       "path": "system.skills", |       "path": "data.skills", | ||||||
|       "converter": "career_skills" |       "converter": "career_skills" | ||||||
|     }, |     }, | ||||||
|     "talents": { |     "talents": { | ||||||
|       "path": "system.talents", |       "path": "data.talents", | ||||||
|       "converter": "career_talents" |       "converter": "career_talents" | ||||||
|     }, |     }, | ||||||
|     "class": { |     "class": { | ||||||
|       "path": "system.class.value", |       "path": "data.class.value", | ||||||
|       "converter": "generic_localization" |       "converter": "generic_localization" | ||||||
|     }, |     }, | ||||||
|     "careergroup": { |     "careergroup": { | ||||||
|       "path": "system.careergroup.value", |       "path": "data.careergroup.value", | ||||||
|       "converter": "career_careergroup" |       "converter": "career_careergroup" | ||||||
|     }, |     }, | ||||||
|     "trappings": "system.trappings" |     "trappings": "data.trappings" | ||||||
|   },	 |   },	 | ||||||
| 	"entries": [ | 	"entries": [ | ||||||
| 		{ | 		{ | ||||||
|   | |||||||
| @@ -2,19 +2,19 @@ | |||||||
| 	"label": "Sorts Ennemi Intérieur", | 	"label": "Sorts Ennemi Intérieur", | ||||||
| 	"mapping": { | 	"mapping": { | ||||||
| 		"sduration": { | 		"sduration": { | ||||||
| 			"path": "system.duration.value", | 			"path": "data.duration.value", | ||||||
| 			"converter": "spells_duration_range_target_damage" | 			"converter": "spells_duration_range_target_damage" | ||||||
| 		}, | 		}, | ||||||
| 		"srange": { | 		"srange": { | ||||||
| 			"path": "system.range.value", | 			"path": "data.range.value", | ||||||
| 			"converter": "spells_duration_range_target_damage" | 			"converter": "spells_duration_range_target_damage" | ||||||
| 		}, | 		}, | ||||||
| 		"starget": { | 		"starget": { | ||||||
| 			"path": "system.target.value", | 			"path": "data.target.value", | ||||||
| 			"converter": "spells_duration_range_target_damage" | 			"converter": "spells_duration_range_target_damage" | ||||||
| 		}, | 		}, | ||||||
| 		"sdamage": { | 		"sdamage": { | ||||||
| 			"path": "system.damage.value", | 			"path": "data.damage.value", | ||||||
| 			"converter": "spells_duration_range_target_damage" | 			"converter": "spells_duration_range_target_damage" | ||||||
| 		}, | 		}, | ||||||
| 		"effets": "effects" | 		"effets": "effects" | ||||||
| @@ -76,7 +76,7 @@ | |||||||
| 						"wfrp4e": { | 						"wfrp4e": { | ||||||
| 							"effectTrigger": "oneTime", | 							"effectTrigger": "oneTime", | ||||||
| 							"effectApplication": "apply", | 							"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.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.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  })", | ||||||
| 							"preventDuplicateEffects": false | 							"preventDuplicateEffects": false | ||||||
| 						} | 						} | ||||||
| 					} | 					} | ||||||
| @@ -103,7 +103,7 @@ | |||||||
| 						"wfrp4e": { | 						"wfrp4e": { | ||||||
| 							"effectTrigger": "oneTime", | 							"effectTrigger": "oneTime", | ||||||
| 							"effectApplication": "apply", | 							"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.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.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  })", | ||||||
| 							"preventDuplicateEffects": false | 							"preventDuplicateEffects": false | ||||||
| 						} | 						} | ||||||
| 					} | 					} | ||||||
| @@ -142,7 +142,7 @@ | |||||||
| 						"wfrp4e": { | 						"wfrp4e": { | ||||||
| 							"effectTrigger": "oneTime", | 							"effectTrigger": "oneTime", | ||||||
| 							"effectApplication": "apply", | 							"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.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})", | 							"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})", | ||||||
| 							"preventDuplicateEffects": false | 							"preventDuplicateEffects": false | ||||||
| 						} | 						} | ||||||
| 					} | 					} | ||||||
| @@ -181,7 +181,7 @@ | |||||||
| 						"wfrp4e": { | 						"wfrp4e": { | ||||||
| 							"effectTrigger": "oneTime", | 							"effectTrigger": "oneTime", | ||||||
| 							"effectApplication": "apply", | 							"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.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.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  })", | ||||||
| 							"preventDuplicateEffects": false | 							"preventDuplicateEffects": false | ||||||
| 						} | 						} | ||||||
| 					} | 					} | ||||||
| @@ -208,7 +208,7 @@ | |||||||
| 						"wfrp4e": { | 						"wfrp4e": { | ||||||
| 							"effectTrigger": "oneTime", | 							"effectTrigger": "oneTime", | ||||||
| 							"effectApplication": "apply", | 							"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.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.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  })", | ||||||
| 							"preventDuplicateEffects": false | 							"preventDuplicateEffects": false | ||||||
| 						} | 						} | ||||||
| 					} | 					} | ||||||
|   | |||||||
| @@ -2,11 +2,11 @@ | |||||||
| 	"label": "Mutations Supplémentaires", | 	"label": "Mutations Supplémentaires", | ||||||
| 	"mappings": { | 	"mappings": { | ||||||
|     "modifier": { |     "modifier": { | ||||||
|         "path": "system.modifier.value", |         "path": "data.modifier.value", | ||||||
|         "converter": "mutations_modifier" |         "converter": "mutations_modifier" | ||||||
|     }, |     }, | ||||||
|     "mutationType": { |     "mutationType": { | ||||||
|         "path": "system.mutationType.value", |         "path": "data.mutationType.value", | ||||||
|         "converter": "generic_localization" |         "converter": "generic_localization" | ||||||
|     } |     } | ||||||
| 	}, | 	}, | ||||||
|   | |||||||
| @@ -2,22 +2,22 @@ | |||||||
| 	"label": "Items Rough Nights & Hard Days", | 	"label": "Items Rough Nights & Hard Days", | ||||||
| 	"mapping": {	 | 	"mapping": {	 | ||||||
|     "sduration": { |     "sduration": { | ||||||
|       "path": "system.duration.value", |       "path": "data.duration.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "srange": { |     "srange": { | ||||||
|       "path": "system.range.value", |       "path": "data.range.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "starget": { |     "starget": { | ||||||
|       "path": "system.target.value", |       "path": "data.target.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     },     |     },     | ||||||
|     "sdamage": { |     "sdamage": { | ||||||
|       "path": "system.damage.value", |       "path": "data.damage.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "tests": "system.tests.value" |     "tests": "data.tests.value" | ||||||
|   },	 |   },	 | ||||||
| 	"entries": [ | 	"entries": [ | ||||||
| 		{ | 		{ | ||||||
|   | |||||||
| @@ -1,35 +1,35 @@ | |||||||
| { | { | ||||||
|   "label": "Items Starter Set", |   "label": "Items Starter Set", | ||||||
| 	"mapping": { | 	"mapping": { | ||||||
|     "gmdescription": "system.gmdescription.value", |     "gmdescription": "data.gmdescription.value", | ||||||
|     "duration": "system.duration.value", |     "duration": "data.duration.value", | ||||||
|     "contraction": "system.contraction.value", |     "contraction": "data.contraction.value", | ||||||
|     "incubation": "system.incubation.value", |     "incubation": "data.incubation.value", | ||||||
|     "symptoms": "system.symptoms.value", |     "symptoms": "data.symptoms.value", | ||||||
|     "permanent": "system.permanent.value", |     "permanent": "data.permanent.value", | ||||||
|     "special":  "system.special.value", |     "special":  "data.special.value", | ||||||
|     "qualities": { |     "qualities": { | ||||||
|       "path": "system.qualities.value", |       "path": "data.qualities.value", | ||||||
|       "converter": "trapping_qualities_flaws" |       "converter": "trapping_qualities_flaws" | ||||||
|     }, |     }, | ||||||
|     "flaws": { |     "flaws": { | ||||||
|       "path": "system.flaws.value", |       "path": "data.flaws.value", | ||||||
|       "converter": "trapping_qualities_flaws" |       "converter": "trapping_qualities_flaws" | ||||||
|     }, |     }, | ||||||
|     "sduration": { |     "sduration": { | ||||||
|       "path": "system.duration.value", |       "path": "data.duration.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "srange": { |     "srange": { | ||||||
|       "path": "system.range.value", |       "path": "data.range.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "starget": { |     "starget": { | ||||||
|       "path": "system.target.value", |       "path": "data.target.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     },     |     },     | ||||||
|     "sdamage": { |     "sdamage": { | ||||||
|       "path": "system.damage.value", |       "path": "data.damage.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     } |     } | ||||||
|   },	 |   },	 | ||||||
|   | |||||||
| @@ -2,19 +2,19 @@ | |||||||
| 	"label": "UG - Carrières", | 	"label": "UG - Carrières", | ||||||
| 	"mapping": { | 	"mapping": { | ||||||
|     "skills": { |     "skills": { | ||||||
|       "path": "system.skills", |       "path": "data.skills", | ||||||
|       "converter": "career_skills" |       "converter": "career_skills" | ||||||
|     }, |     }, | ||||||
|     "talents": { |     "talents": { | ||||||
|       "path": "system.talents", |       "path": "data.talents", | ||||||
|       "converter": "career_talents" |       "converter": "career_talents" | ||||||
|     }, |     }, | ||||||
|     "class": { |     "class": { | ||||||
|       "path": "system.class.value", |       "path": "data.class.value", | ||||||
|       "converter": "generic_localization" |       "converter": "generic_localization" | ||||||
|     }, |     }, | ||||||
|     "careergroup": "system.careergroup.value", |     "careergroup": "data.careergroup.value", | ||||||
|     "trappings": "system.trappings" |     "trappings": "data.trappings" | ||||||
|   }, |   }, | ||||||
| 	"entries": [ | 	"entries": [ | ||||||
| 		{ | 		{ | ||||||
|   | |||||||
| @@ -6,7 +6,7 @@ | |||||||
|       "converter": "bestiary_traits" |       "converter": "bestiary_traits" | ||||||
|       }, |       }, | ||||||
|     "characteristics": { |     "characteristics": { | ||||||
|       "path": "system.characteristics", |       "path": "data.characteristics", | ||||||
|       "converter": "npc_characteristics" |       "converter": "npc_characteristics" | ||||||
|     } |     } | ||||||
|   }, |   }, | ||||||
|   | |||||||
| @@ -2,19 +2,19 @@ | |||||||
| 	"label": "UG - Sorts", | 	"label": "UG - Sorts", | ||||||
| 	"mapping": { | 	"mapping": { | ||||||
|     "sduration": { |     "sduration": { | ||||||
|       "path": "system.duration.value", |       "path": "data.duration.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "srange": { |     "srange": { | ||||||
|       "path": "system.range.value", |       "path": "data.range.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     }, |     }, | ||||||
|     "starget": { |     "starget": { | ||||||
|       "path": "system.target.value", |       "path": "data.target.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     },     |     },     | ||||||
|     "sdamage": { |     "sdamage": { | ||||||
|       "path": "system.damage.value", |       "path": "data.damage.value", | ||||||
|       "converter": "spells_duration_range_target_damage" |       "converter": "spells_duration_range_target_damage" | ||||||
|     } |     } | ||||||
|   }, |   }, | ||||||
|   | |||||||
							
								
								
									
										8
									
								
								fr.json
									
									
									
									
									
								
							
							
						
						
									
										8
									
								
								fr.json
									
									
									
									
									
								
							| @@ -665,7 +665,6 @@ | |||||||
|     "Actor Settings":"Paramètres d'Acteur", |     "Actor Settings":"Paramètres d'Acteur", | ||||||
|     "Add Encumbrance for Actors":"Ajouter l'encombrement pour les Acteurs", |     "Add Encumbrance for Actors":"Ajouter l'encombrement pour les Acteurs", | ||||||
|     "BROWSER.Button":"Navigateur", |     "BROWSER.Button":"Navigateur", | ||||||
|     "BROWSER.LoadingBrowser":"Chargement du navigateur...", |  | ||||||
|     "MOO.Bleeding":"Vous saignez gravement. Perdez 1 Blessure à la fin de chaque round, en ignorant tout autre modificateur. De plus, subissez une pénalité de -10 à tout vos Tests pour résister à une Blessure Purulente, un Infection Mineure ou une Infection du Sang. Si vous atteignez 0 Blessures, faites immédiatement un Test d'Endurance pour rester debout (avec une pénalite de -10 pour chaque étatHémorragique), sinon vous tombez  @Condition[Unconscious], et vous devez refaire ce test chaque fois que vous prenez des dommages dus à l'Hémorragie. Si vous êtes à 0 Blessures, que vous soyez Inconscient ou pas, vous avez 10% de mourrir à la fin du Round pour chaque état Hémorragique. Donc, si vous avez 3 états Hémorragiques, vous mourrez sur un jet de 01-30. Si un double est obtenu, votre blessure coagule un peu : retirez 1 état Hémorragique. Vous ne pouvez redevenir conscient que si tout les états Hémorragiques sont soignées (voir Blessures)<br><br>Un état Hémorragique peut être retiré avec : un test réussi de Guérison (chaque DR enlève 1 état Hémorragique); ou avec un sort ou une prière (avec un état enlevé par Point de Blessure gueri).<br><br>Lorsque tout les états Hémorragiques ont été soignés, recevez un état @Condition[Fatigued].", |     "MOO.Bleeding":"Vous saignez gravement. Perdez 1 Blessure à la fin de chaque round, en ignorant tout autre modificateur. De plus, subissez une pénalité de -10 à tout vos Tests pour résister à une Blessure Purulente, un Infection Mineure ou une Infection du Sang. Si vous atteignez 0 Blessures, faites immédiatement un Test d'Endurance pour rester debout (avec une pénalite de -10 pour chaque étatHémorragique), sinon vous tombez  @Condition[Unconscious], et vous devez refaire ce test chaque fois que vous prenez des dommages dus à l'Hémorragie. Si vous êtes à 0 Blessures, que vous soyez Inconscient ou pas, vous avez 10% de mourrir à la fin du Round pour chaque état Hémorragique. Donc, si vous avez 3 états Hémorragiques, vous mourrez sur un jet de 01-30. Si un double est obtenu, votre blessure coagule un peu : retirez 1 état Hémorragique. Vous ne pouvez redevenir conscient que si tout les états Hémorragiques sont soignées (voir Blessures)<br><br>Un état Hémorragique peut être retiré avec : un test réussi de Guérison (chaque DR enlève 1 état Hémorragique); ou avec un sort ou une prière (avec un état enlevé par Point de Blessure gueri).<br><br>Lorsque tout les états Hémorragiques ont été soignés, recevez un état @Condition[Fatigued].", | ||||||
|     "MOO.Broken":"Vous êtes terrifié, défait en état de panique ou convaincu que vous allez mourrir. A votre tour, votre Action et votre Mouvement doivent être utilisés pour fuir aussi loin que possible jusqu'à ce que vous trouviez un endroit pour vous cacher; vous pourrez alors utiliser votre Action avec une Compétence vous permettant de vous cacher effectivement. Vous recevez également une pénalité de -10 pour tout les Tests n'impliquant pas la course ou la dissimulation.<br><br>Vous ne pouvez faire de test pour récupérer de votre état Brisé si vous êtes au contact d'un ennemi. Si vous êtes désengagé, à la fin de chaque round, vous pouvez tenter un Test de Calme pour enlever un état Brisé par DR. La difficulté est déterminée par les circonstances: il est plus facile de se remettre en état caché à l'abri que d'être à 3 pas d'un démon souhaitant vous démembrer.<br><br>Si vous passez un Round complet à vous cacher hors de la ligne de vue de tout ennemi, vous enlevez 1 état Brisé.<br><br><strike>Lorsque tout les états Brisé sont enlevés, vous recevez 1 Etat Fatigué.</strike>.", |     "MOO.Broken":"Vous êtes terrifié, défait en état de panique ou convaincu que vous allez mourrir. A votre tour, votre Action et votre Mouvement doivent être utilisés pour fuir aussi loin que possible jusqu'à ce que vous trouviez un endroit pour vous cacher; vous pourrez alors utiliser votre Action avec une Compétence vous permettant de vous cacher effectivement. Vous recevez également une pénalité de -10 pour tout les Tests n'impliquant pas la course ou la dissimulation.<br><br>Vous ne pouvez faire de test pour récupérer de votre état Brisé si vous êtes au contact d'un ennemi. Si vous êtes désengagé, à la fin de chaque round, vous pouvez tenter un Test de Calme pour enlever un état Brisé par DR. La difficulté est déterminée par les circonstances: il est plus facile de se remettre en état caché à l'abri que d'être à 3 pas d'un démon souhaitant vous démembrer.<br><br>Si vous passez un Round complet à vous cacher hors de la ligne de vue de tout ennemi, vous enlevez 1 état Brisé.<br><br><strike>Lorsque tout les états Brisé sont enlevés, vous recevez 1 Etat Fatigué.</strike>.", | ||||||
|     "MOO.Items":"Le règles maison des ites ont été appliqués sur les compendiums. Voir la console (F12) pour détail.", |     "MOO.Items":"Le règles maison des ites ont été appliqués sur les compendiums. Voir la console (F12) pour détail.", | ||||||
| @@ -1908,12 +1907,7 @@ | |||||||
|     "BUGREPORT.Contact":"Informations de contact", |     "BUGREPORT.Contact":"Informations de contact", | ||||||
|     "BUGREPORT.ContactPlaceholder":"Tag Discord ou Email.", |     "BUGREPORT.ContactPlaceholder":"Tag Discord ou Email.", | ||||||
|     "BUGREPORT.DescriptionPlaceholder":"Ce qu'il s'est passsé, comment le reproduire, etc.", |     "BUGREPORT.DescriptionPlaceholder":"Ce qu'il s'est passsé, comment le reproduire, etc.", | ||||||
|     "BUGREPORT.ManyModules":"Vous avez des modules non-WFRP4e activés, peut-être que l'un d'entre eux interfère ?", |      | ||||||
|     "BUGREPORT.MatchingGrudges":"Est-ce que votre grief n'a pas déja été enregistré ?", |  | ||||||
|     "BUGREPORT.Warning":"<b>Attention</b>: Cette information est postée dans les tickets de GitHub, qui sont publics. Les Tags Discords sont donc à préférer. Sinon, contactez moi directement en Anglais à (<a href='mailto:russellt@cubicle7games.com'>Moo Man</a>).", |  | ||||||
|     "GrudgeError":"Les Longues Barbes gromellent et refusent votre soumission. Vérifier la console (F12) pour de plus amples détails.", |  | ||||||
|     "GrudgePost":"Les Longues Barbes ont reçu votre grief ! Consultez la console (F12) pour le lien.", |  | ||||||
|              |  | ||||||
|     "EFFECT.TabWFRP" : "WFRP", |     "EFFECT.TabWFRP" : "WFRP", | ||||||
|     "EFFECT.EffectType" : "Type d'Effet", |     "EFFECT.EffectType" : "Type d'Effet", | ||||||
|     "EFFECT.EffectApplication" : "Application de l'Effect", |     "EFFECT.EffectApplication" : "Application de l'Effect", | ||||||
|   | |||||||
							
								
								
									
										29
									
								
								module.json
									
									
									
									
									
								
							
							
						
						
									
										29
									
								
								module.json
									
									
									
									
									
								
							| @@ -8,7 +8,7 @@ | |||||||
|     } |     } | ||||||
|   ], |   ], | ||||||
|   "url": "https://www.uberwald.me/gitea/public/foundryvtt-wh4-lang-fr-fr", |   "url": "https://www.uberwald.me/gitea/public/foundryvtt-wh4-lang-fr-fr", | ||||||
|   "version": "6.2.6", |   "version": "6.1.9", | ||||||
|   "esmodules": [ |   "esmodules": [ | ||||||
|     "babele-register.js", |     "babele-register.js", | ||||||
|     "addon-register.js", |     "addon-register.js", | ||||||
| @@ -135,27 +135,10 @@ | |||||||
|       "flags": {} |       "flags": {} | ||||||
|     } |     } | ||||||
|   ], |   ], | ||||||
|   "manifest": "https://www.uberwald.me/gitea/public/foundryvtt-wh4-lang-fr-fr/raw/v10/module.json", |   "manifest": "https://www.uberwald.me/gitea/public/foundryvtt-wh4-lang-fr-fr/raw/v4/module.json", | ||||||
|   "download": "https://www.uberwald.me/gitea/public/foundryvtt-wh4-lang-fr-fr/archive/foundryvtt-wh4-lang-fr-6.2.6.zip", |   "download": "https://www.uberwald.me/gitea/public/foundryvtt-wh4-lang-fr-fr/archive/foundryvtt-wh4-lang-fr-6.1.9.zip", | ||||||
|   "id": "wh4-fr-translation", |   "id": "wh4-fr-translation", | ||||||
|   "compatibility": { |   "name": "wh4-fr-translation", | ||||||
|     "minimum": "10", |   "minimumCoreVersion": "0.8.0", | ||||||
|     "verified": "10.286" |   "compatibleCoreVersion": "9" | ||||||
|   }, |  | ||||||
|   "relationships": { |  | ||||||
|     "systems": [ |  | ||||||
|       { |  | ||||||
|         "id": "wfrp4e", |  | ||||||
|         "type": "system", |  | ||||||
|         "compatibility": {} |  | ||||||
|       } |  | ||||||
|     ], |  | ||||||
|     "requires": [ |  | ||||||
|       { |  | ||||||
|         "id": "babele", |  | ||||||
|         "type": "module", |  | ||||||
|         "compatibility": {} |  | ||||||
|       } |  | ||||||
|     ] |  | ||||||
|   } |  | ||||||
| } | } | ||||||
| @@ -726,9 +726,9 @@ export class WH4FRPatchConfig { | |||||||
|                             if (weaponLength > 3) |                             if (weaponLength > 3) | ||||||
|                             { |                             { | ||||||
|                                 let improv = duplicate(game.wfrp4e.config.systemItems.improv) |                                 let improv = duplicate(game.wfrp4e.config.systemItems.improv) | ||||||
|                                 improv.system.twohanded.value = args.item.twohanded.value |                                 improv.data.twohanded.value = args.item.twohanded.value | ||||||
|                                 improv.system.offhand.value = args.item.offhand.value |                                 improv.data.offhand.value = args.item.offhand.value | ||||||
|                                 args.item.update({"system" : improv.system, name : args.item.name + " (Combat au Contact")}) |                                 args.item.data.update({"data" : improv.data, name : args.item.name + " (Combat au Contact")}) | ||||||
|                             } |                             } | ||||||
|                         } |                         } | ||||||
|                 ` |                 ` | ||||||
| @@ -1161,7 +1161,7 @@ export class WH4FRPatchConfig { | |||||||
|                         let applicableCharacteristics = ["ws", "bs", "s", "fel", "ag", "t", "dex"] |                         let applicableCharacteristics = ["ws", "bs", "s", "fel", "ag", "t", "dex"] | ||||||
|                         if (applicableCharacteristics.includes(args.test.result.characteristic)) |                         if (applicableCharacteristics.includes(args.test.result.characteristic)) | ||||||
|                             this.actor.addCondition("stunned") |                             this.actor.addCondition("stunned") | ||||||
|                         else if (args.test.result.skill && applicableCharacteristics.includes(args.test.result.skill.system.characteristic.value)) |                         else if (args.test.result.skill && applicableCharacteristics.includes(args.test.result.skill.data.characteristic.value)) | ||||||
|                             this.actor.addCondition("stunned") |                             this.actor.addCondition("stunned") | ||||||
|                         else if (args.test.result.weapon) |                         else if (args.test.result.weapon) | ||||||
|                             this.actor.addCondition("stunned") |                             this.actor.addCondition("stunned") | ||||||
| @@ -1210,7 +1210,7 @@ export class WH4FRPatchConfig { | |||||||
|                                     { |                                     { | ||||||
|                                         if (test.result.outcome == "failure") |                                         if (test.result.outcome == "failure") | ||||||
|                                             fromUuid("Compendium.wfrp4e-core.diseases.kKccDTGzWzSXCBOb").then(disease => { |                                             fromUuid("Compendium.wfrp4e-core.diseases.kKccDTGzWzSXCBOb").then(disease => { | ||||||
|                                                 args.actor.createEmbeddedDocuments("Item", [disease.toObject()]) |                                                 args.actor.createEmbeddedEntity("OwnedItem", disease.data) | ||||||
|                                             }) |                                             }) | ||||||
|                                     }) |                                     }) | ||||||
|                                 }) |                                 }) | ||||||
|   | |||||||
| @@ -134,7 +134,7 @@ async function __findSkill(skillName, value = undefined) { | |||||||
|         let spec = XRegExp.replace(skillSplit.specialized, "(", ""); |         let spec = XRegExp.replace(skillSplit.specialized, "(", ""); | ||||||
|         spec = XRegExp.replace(spec, ")", ""); |         spec = XRegExp.replace(spec, ")", ""); | ||||||
|         let skillSplit2 = XRegExp.exec(dbSkill.name, XRegExp(parseStr, 'gi')); |         let skillSplit2 = XRegExp.exec(dbSkill.name, XRegExp(parseStr, 'gi')); | ||||||
|         dbSkill.update( { name: skillSplit2.name + '(' + game.i18n.localize( spec.trim() ) + ')' } ); |         dbSkill.data.update( { name: skillSplit2.name + '(' + game.i18n.localize( spec.trim() ) + ')' } ); | ||||||
|       } |       } | ||||||
|       //game.babele.translate('wfrp4e-core.skills', dbSkill); |       //game.babele.translate('wfrp4e-core.skills', dbSkill); | ||||||
|       return dbSkill; |       return dbSkill; | ||||||
| @@ -169,7 +169,7 @@ async function __findTalent(talentName) { | |||||||
|       if ( talentSplit.specialized  ) { |       if ( talentSplit.specialized  ) { | ||||||
|         let spec = XRegExp.replace(talentSplit.specialized, "(", ""); |         let spec = XRegExp.replace(talentSplit.specialized, "(", ""); | ||||||
|         spec = XRegExp.replace(spec, ")", ""); |         spec = XRegExp.replace(spec, ")", ""); | ||||||
|         dbTalent.update( { name: talentSplit.name + '(' + game.i18n.localize( spec.trim() ) + ')' } ); |         dbTalent.data.update( { name: talentSplit.name + '(' + game.i18n.localize( spec.trim() ) + ')' } ); | ||||||
|       } |       } | ||||||
|       return dbTalent; |       return dbTalent; | ||||||
|     } |     } | ||||||
| @@ -285,9 +285,9 @@ export default async function statParserFR(statString, type = "npc") { | |||||||
|             if (itemFound && value && value.length > 0) { |             if (itemFound && value && value.length > 0) { | ||||||
|               if (name.toLowerCase() == 'weapon' || name.toLowerCase() == "bite" || name.toLowerCase() == "tail" || |               if (name.toLowerCase() == 'weapon' || name.toLowerCase() == "bite" || name.toLowerCase() == "tail" || | ||||||
|                   name.toLowerCase() == 'arme' || name.toLowerCase() == "morsure" || name.toLowerCase() == "queue") { |                   name.toLowerCase() == 'arme' || name.toLowerCase() == "morsure" || name.toLowerCase() == "queue") { | ||||||
|                 itemFound.system.specification.value = Number(value) - Math.floor( Number(model.characteristics.s.initial) / 10) |                 itemFound.data.specification.value = Number(value) - Math.floor( Number(model.characteristics.s.initial) / 10) | ||||||
|               } else { |               } else { | ||||||
|                 itemFound.system.specification.value = game.i18n.localize(value) |                 itemFound.data.specification.value = game.i18n.localize(value) | ||||||
|               } |               } | ||||||
|             } |             } | ||||||
|             if (!itemFound) |             if (!itemFound) | ||||||
| @@ -301,7 +301,7 @@ export default async function statParserFR(statString, type = "npc") { | |||||||
|             if (itemFound) |             if (itemFound) | ||||||
|               itemFound = itemFound.toObject(); |               itemFound = itemFound.toObject(); | ||||||
|             if (itemFound && subres && value) { |             if (itemFound && subres && value) { | ||||||
|               itemFound.system.advances.value = Number(value) - Number(model.characteristics[itemFound.system.characteristic.value].initial); |               itemFound.data.advances.value = Number(value) - Number(model.characteristics[itemFound.data.characteristic.value].initial); | ||||||
|             } |             } | ||||||
|             if (!itemFound) |             if (!itemFound) | ||||||
|               ui.notifications.error("Compétence non trouvée, à ajouter manuellement : " + name, { permanent: true }) |               ui.notifications.error("Compétence non trouvée, à ajouter manuellement : " + name, { permanent: true }) | ||||||
| @@ -313,7 +313,7 @@ export default async function statParserFR(statString, type = "npc") { | |||||||
|             if (itemFound) |             if (itemFound) | ||||||
|               itemFound = itemFound.toObject(); |               itemFound = itemFound.toObject(); | ||||||
|             if (itemFound && subres && value) |             if (itemFound && subres && value) | ||||||
|               itemFound.system.advances.value = Number(value); |               itemFound.data.advances.value = Number(value); | ||||||
|             if (!itemFound) |             if (!itemFound) | ||||||
|               ui.notifications.error("Talent non trouvé, à ajouter manuellement : " + name, { permanent: true }) |               ui.notifications.error("Talent non trouvé, à ajouter manuellement : " + name, { permanent: true }) | ||||||
|           } else if (def.name == 'trapping') { |           } else if (def.name == 'trapping') { | ||||||
| @@ -323,7 +323,7 @@ export default async function statParserFR(statString, type = "npc") { | |||||||
|             catch { } |             catch { } | ||||||
|             if (!itemFound && name) { |             if (!itemFound && name) { | ||||||
|               itemFound = new game.entities.ItemWfrp4e({ img: "systems/wfrp4e/icons/blank.png", name: name, type: "trapping", data: game.system.model.Item.trapping }) |               itemFound = new game.entities.ItemWfrp4e({ img: "systems/wfrp4e/icons/blank.png", name: name, type: "trapping", data: game.system.model.Item.trapping }) | ||||||
|               itemFound.system.trappingType.value = "misc" |               itemFound.data.data.trappingType.value = "misc" | ||||||
|             }  |             }  | ||||||
|             if (itemFound) |             if (itemFound) | ||||||
|               itemFound = itemFound.toObject(); |               itemFound = itemFound.toObject(); | ||||||
| @@ -342,13 +342,13 @@ export default async function statParserFR(statString, type = "npc") { | |||||||
|       } |       } | ||||||
|     } |     } | ||||||
|     let moneyItems = await game.wfrp4e.utility.allMoneyItems() || []; |     let moneyItems = await game.wfrp4e.utility.allMoneyItems() || []; | ||||||
|     moneyItems = moneyItems.sort((a, b) => (a.system.coinValue.value > b.system.coinValue.value) ? -1 : 1); |     moneyItems = moneyItems.sort((a, b) => (a.data.coinValue.value > b.data.coinValue.value) ? -1 : 1); | ||||||
|     moneyItems.forEach(m => m.system.quantity.value = 0) |     moneyItems.forEach(m => m.data.quantity.value = 0) | ||||||
|     globalItemList = globalItemList.concat(moneyItems); |     globalItemList = globalItemList.concat(moneyItems); | ||||||
|     //console.log("My liste :", globalItemList); |     //console.log("My liste :", globalItemList); | ||||||
|     let name = pnjName; |     let name = pnjName; | ||||||
|  |  | ||||||
|     let effects = globalItemList.reduce((total, globItem) => total.concat(globItem.effects), []) |     let effects = globalItemList.reduce((total, globItem) => total.concat(globItem.data.effects), []) | ||||||
|     effects = effects.filter(e => !!e) |     effects = effects.filter(e => !!e) | ||||||
|     effects = effects.filter(e => e.transfer) |     effects = effects.filter(e => e.transfer) | ||||||
|  |  | ||||||
|   | |||||||
| @@ -2,7 +2,7 @@ package.path = package.path .. ";luajson/?.lua" | |||||||
| local JSON = require"json" | local JSON = require"json" | ||||||
|  |  | ||||||
| --local enjsonf = "/home/morr/foundry/foundrydata-dev/Data/modules/wfrp4e-dotr/lang/en.json" | --local enjsonf = "/home/morr/foundry/foundrydata-dev/Data/modules/wfrp4e-dotr/lang/en.json" | ||||||
| local enjsonf = "/home/morr/foundry/foundrydata-dev/Data/modules/wfrp4e-core/lang/en.json" | --local enjsonf = "/home/morr/foundry/foundrydata-dev/Data/modules/wfrp4e-core/lang/en.json" | ||||||
| local enjsonf = "../../WFRP4e-FoundryVTT/static/lang/en.json" | local enjsonf = "../../WFRP4e-FoundryVTT/static/lang/en.json" | ||||||
| local frjsonf = "../fr.json" | local frjsonf = "../fr.json" | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user