From 52cc1bed494203d1a0e6620907b9a3ca6cf8be27 Mon Sep 17 00:00:00 2001 From: sladecraven Date: Sun, 8 Nov 2020 23:39:47 +0100 Subject: [PATCH] PNJ importation --- module.json | 2 +- modules/import-stat-2.js | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/module.json b/module.json index d67cc83..ec9f73a 100644 --- a/module.json +++ b/module.json @@ -3,7 +3,7 @@ "name": "WH4-fr-translation", "title": "Traduction du module WH4 en Français.", "description": "La traduction du module WH4.", - "version": "1.3.18", + "version": "1.3.20", "minimumCoreVersion" : "0.6.6", "compatibleCoreVersion": "1.0.0", "author": "LeRatierBretonnien", diff --git a/modules/import-stat-2.js b/modules/import-stat-2.js index b874234..d1455df 100644 --- a/modules/import-stat-2.js +++ b/modules/import-stat-2.js @@ -33,15 +33,15 @@ import "./xregexp-all.js"; const us_carac = 'm\\s+ws\\s+bs\\s+s\\s+t\\s+i\\s+agi?\\s+dex\\s+int\\s+\\wp\\s+fel\\s+w'; const fr_carac = 'm\\s+ws\\s+bs\\s+s\\s+t\\s+i\\s+agi?\\s+dex\\s+int\\s+\\wp\\s+fel\\s+w'; const carac_val = '(?[0-9-]+)\\s+(?[0-9-]+)\\s+(?[0-9-]+)\\s+(?[0-9-]+)\\s+(?[0-9-]+)\\s+(?[0-9-]+)\\s+(?[0-9-]+)\\s+(?[0-9-]+)\\s+(?[0-9-]+)\\s+(?[0-9-]+)\\s+(?[0-9-]+)\\s+(?[0-9-]+)'; -const name_val = '(?[a-z\\s\\-]*)[\\s\\r\\n]*(?.*|[\\(\\)a-z0-9]+)'; +const name_val = '(?[a-z\\s\\-,]*)[\\s\\r\\n]*(?.*|[\\(\\)a-z0-9]+)'; let sectionData = [ { name: "trait", toFind:"Traits\\s*:", secondParse: '(?[a-z\\s]*)[\\s\\+]*(?.*|[0-9]+)', index:-1 }, - { name: "skill", toFind:"Skills\\s*:", secondParse: '(?[a-z\\s]*)[\\s\\+]*(?.*|[0-9]+)', index:-1 }, - { name: "talent", toFind:"Talents\\s*:", secondParse: '(?[a-z\\s]*)[\\s\\+]*(?.*|[0-9]+)', index:-1 }, + { name: "skill", toFind:"Skills\\s*:", secondParse: '(?[a-z\\s\\(\\)]*)[\\s\\+]*(?.*|[0-9]+)', index:-1 }, + { name: "talent", toFind:"Talents\\s*:", secondParse: '(?[a-z\\-\\s]*)[\\s\\+]*(?.*|[0-9]+)', index:-1 }, { name: "trapping", toFind:"Trappings\\s*:", secondParse: '(?[a-z\\s]*)[\\s\\+]*(?.*|[0-9]+)', index:-1 } ]; let regSep = XRegExp('\\s*,\\s*', 'gi'); // Term separator, with auto trim -let regLine1 = XRegExp('\\r|\\n|\\.', 'gi'); // Term separator, with auto trim +let regLine1 = XRegExp('[\\r\\n\\.]', 'gi'); // Term separator, with auto trim let regName = XRegExp(name_val, 'gi'); /************************************************************************************/