Skip to content

Commit

Permalink
update for v11
Browse files Browse the repository at this point in the history
  • Loading branch information
BrotherSharper committed Jul 29, 2023
1 parent fe77723 commit 85da04a
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 13 deletions.
4 changes: 1 addition & 3 deletions compendium/pf1.class-abilities.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@
"label": "クラス特徴",
"mapping": {
"changes": "system.changes",
"contextNotes": "system.contextNotes",
"tags": "system.tags",
"classes": "system.associations.classes"
"contextNotes": "system.contextNotes"
},
"entries": [
{
Expand Down
4 changes: 0 additions & 4 deletions compendium/pf1.spells.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,6 @@
"materials_focus": "system.materials.focus",
"types": "system.types",
"subschool": "system.subschool",
"class": "system.learnedAt.class",
"domain": "system.learnedAt.domain",
"subDomain": "system.learnedAt.subDomain",
"bloodline": "system.learnedAt.bloodline",
"actions": {
"path": "system.actions",
"converter": "actions"
Expand Down
4 changes: 2 additions & 2 deletions module.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
"description": "FVTT用パスファインダー1eシステムの翻訳ファイルおよびBabele用の辞典翻訳ファイルを組み込むモッド。",
"version": "This is auto replaced",
"compatibility": {
"minimum": "10",
"verified": "10"
"minimum": "11",
"verified": "11"
},
"author": "Brother Sharp, Chiikun, Shoki, Yuu",
"languages": [
Expand Down
15 changes: 11 additions & 4 deletions scripts/converters.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,26 @@ class Converters {
usePf2eTokensBestiaries = false;

actions(value, translations) {
if (!translations) {
if (!value || !translations) {
return value;
}

value.forEach((type, index) => {
const data = translations[index];

value[index].duration.value = data.duration;
value[index].effectNotes = data.effectNotes;
value[index].save.description = data.save;
value[index].spellArea = data.spellArea;
value[index].spellEffect = data.spellEffect;
value[index].target.value = data.target;

if (value[index].duration?.value) {
value[index].duration.value = data.duration;
}
if (value[index].save?.description) {
value[index].save.description = data.save;
}
if (value[index].target?.value) {
value[index].target.value = data.target;
}
});

return value;
Expand Down

0 comments on commit 85da04a

Please sign in to comment.