forked from public/foundryvtt-wh4-lang-fr-fr
Update release
This commit is contained in:
@ -76,7 +76,7 @@ let __eis_tables = { "animalmishap":1, "beasthead":1, "coincedentalenc":1, "demo
|
||||
}
|
||||
let __dotr_tables = { "rowingboat":1, "sailingboat":1, "wind-direction": 1, "waterborne": 1, "traderumour": 1
|
||||
}
|
||||
let __wfrp4e_tables = { "career": 1, "critbody":1, "critleg": 1, "doom": 1, "eyes": 1, "majormis": 1, "mutatemental": 1, "oops": 1, "species":1, "travel": 1,
|
||||
let __wfrp4e_tables = { "career": 1, "critbody":1, "critleg": 1, "doom": 1, "doom2": 1, "eyes": 1, "majormis": 1, "mutatemental": 1, "oops": 1, "species":1, "travel": 1,
|
||||
"hitloc": 1, "critarm": 1, "crithead": 1, "delirium": 1, "event": 1, "hair": 1, "minormis": 1, "mutatephys": 1, "talents": 1, "wrath": 1,
|
||||
"astral": 1, "corruption": 1, "snake": 1, "spider": 1
|
||||
|
||||
@ -122,6 +122,19 @@ const __auto_patch_translation_journal_compendium = async (compmod) => {
|
||||
}
|
||||
}
|
||||
|
||||
/************************************************************************************/
|
||||
const loadCompendiumData = async (compendium) => {
|
||||
const pack = game.packs.get(compendium);
|
||||
return await pack?.getDocuments() ?? [];
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
/************************************************************************************/
|
||||
const loadCompendium = async (compendium, filter = item => true) => {
|
||||
let compendiumData = await loadCompendiumData(compendium);
|
||||
return compendiumData.filter(filter);
|
||||
}
|
||||
|
||||
/************************************************************************************/
|
||||
const patch_core_tables = (tableList) => {
|
||||
FilePicker.browse("data", "modules/WH4-fr-translation/tables/").then(resp => {
|
||||
@ -288,6 +301,18 @@ Hooks.once('ready', () => {
|
||||
setTimeout( __check_fix_wrong_modules, 20000, false, true);
|
||||
setTimeout( __add_actors_translation, 21000, false, true);
|
||||
|
||||
/* ATTEMPT !!
|
||||
loadCompendium("wfrp4e-core.spells").then( comp => {
|
||||
let sorted = {};
|
||||
for (let spell of comp) {
|
||||
if ( !sorted[spell.data.data.lore.value]) {
|
||||
sorted[spell.data.data.lore.value] = [];
|
||||
}
|
||||
sorted[spell.data.data.lore.value].push( duplicate(spell.data) );
|
||||
}
|
||||
console.log("SORTED", sorted);
|
||||
});*/
|
||||
|
||||
/*
|
||||
let compmod = "wfrp4e";
|
||||
// Check various settings in the installation
|
||||
|
Reference in New Issue
Block a user