Various fixes
This commit is contained in:
@ -161,6 +161,8 @@ Hooks.once('init', () => {
|
||||
// Replace to manage specific bonuses/char. computations
|
||||
CONFIG.Actor.entityClass = ActorWfrp4e_fr;
|
||||
|
||||
WFRP4E.weaponQualities["distract"] = "PROPERTY.Distract"; // Patch missing quality
|
||||
|
||||
WFRP4E.talentBonuses = {
|
||||
"perspicace": "int",
|
||||
"affable": "fel",
|
||||
@ -488,17 +490,18 @@ Hooks.once('init', () => {
|
||||
},
|
||||
"trapping_qualities_flaws": (value) => {
|
||||
if ( value ) {
|
||||
console.log("ATOUTS", value);
|
||||
var list = value.split( "," );
|
||||
var i=0;
|
||||
var re = /(.*) (\d+)/i;
|
||||
for (i=0; i<list.length; i++) {
|
||||
let trim = list[i].trim();
|
||||
//console.log("Current quality", trim );
|
||||
if ( trim == "Trap Blade") {
|
||||
trim = "TrapBlade"; // Auto-patch, without space!
|
||||
//console.log("PATCHED", trim);
|
||||
}
|
||||
var splitted = re.exec( trim );
|
||||
console.log("Current quality", splitted, trim );
|
||||
if ( splitted ) {
|
||||
//console.log("FOund:", splitted[0], splitted[1], splitted[2] );
|
||||
list[i] = game.i18n.localize( splitted[1] ) + " " + splitted[2];
|
||||
@ -514,9 +517,10 @@ Hooks.once('init', () => {
|
||||
var compendium = game.packs.find(p => p.collection === 'wfrp4e.careers');
|
||||
return compendium.i18nName( { name: value } );
|
||||
},
|
||||
"mutations_modifier": (value) => {
|
||||
"mutations_modifier": (value) => { // This is really UGLYYYY i know, but i started like this and discovered afterward that many strings were not easy to automate... Sorry :)
|
||||
//console.log("Parsing mutation :", value);
|
||||
value = value.toLowerCase();
|
||||
value = value.replace("gain a broken condition if you fail a test derived from ", "Gagnez un état Brisé si vous échouez à un test dérivé de ");
|
||||
value = value.replace("weapon skill" ,"Capacité de Combat");
|
||||
value = value.replace("ballistic skill", "Capacité de Tir");
|
||||
value = value.replace("strength", "Force");
|
||||
@ -527,6 +531,18 @@ Hooks.once('init', () => {
|
||||
value = value.replace("fellowship", "Sociabilité");
|
||||
value = value.replace("initiative", "Initiative");
|
||||
value = value.replace("intelligence", "Intelligence");
|
||||
value = value.replace("armor points to the head", "PA à la Tête");
|
||||
value = value.replace("subject to frenzy", "Sujet à la Frénésie");
|
||||
value = value.replace("you do not scar", "Aucune cicatrice");
|
||||
value = value.replace("movement", "Mouvement");
|
||||
value = value.replace("armor points to all locations", "PA sur tout le corps");
|
||||
value = value.replace("to any test when alone", "à tout les tests lorsque seul");
|
||||
value = value.replace("track", "Pistage");
|
||||
value = value.replace("to any test not hurting another", "à tout les Tests n'aggressant pas autrui");
|
||||
value = value.replace("on tests to hurt", "pour les tests impliquant une agression")
|
||||
value = value.replace("to all language tests when speaking", "à tout les Tests de Langue lorsque vous parlez");
|
||||
value = value.replace("on perception tests involving sight", "aux Tests de Perception impliquant la Vue");
|
||||
value = value.replace("to all Sociabilité tests", "à tout les Tests de Sociabilité");
|
||||
return value;
|
||||
},
|
||||
// Auto-translate duration
|
||||
|
Reference in New Issue
Block a user