Skip to content

Commit 16d3a2c

Browse files
authored
Merge pull request #1 from League-of-Foundry-Developers/localize
v1.0.1
2 parents f16c571 + 32ba9be commit 16d3a2c

File tree

5 files changed

+305
-93
lines changed

5 files changed

+305
-93
lines changed

CHANGELOG.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Changelog
22

3+
## v1.0.1
4+
5+
- Added localization.
6+
- Removed `SetCompendiumSceneName()` as it is no longer needed.
7+
38
## v1.0.0
49

5-
- Initial release
10+
- Initial release.

README.md

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,6 @@ const creaturePacks = [`${moduleName}.actors`, 'dnd5e.monsters'];
5858
* const journalPacks = [];
5959
*/
6060
const journalPacks = [`${moduleName}.journals`];
61-
/**
62-
* compendiumSceneName set this to the "name" of the "pack" in your module.json file that has "entity": "Scene"
63-
*/
64-
const compendiumSceneName = 'maps';
6561

6662
Hooks.once('scenePackerReady', ({ getInstance }) => {
6763
// Initialise the Scene Packer with your adventure name and module name
@@ -78,9 +74,6 @@ Hooks.once('scenePackerReady', ({ getInstance }) => {
7874
if (additionalJournals.length) {
7975
packer.SetAdditionalJournalsToImport(additionalJournals);
8076
}
81-
if (compendiumSceneName) {
82-
packer.SetCompendiumSceneName(compendiumSceneName);
83-
}
8477
});
8578
```
8679

languages/en.json

Lines changed: 105 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,106 @@
11
{
2-
"MODULE.hello": "hello"
3-
}
2+
"SCENE-PACKER": {
3+
"ok": "Ok",
4+
"dontShow": "Don't show me again",
5+
"settings": {
6+
"context-menu": {
7+
"name": "Enable Scene Packer context menu",
8+
"hint": "Adds context menu items to assist with packing a Scene. You should only need to enable this while actively developing and packing a module with scenes."
9+
},
10+
"compendium": {
11+
"name": "Show the dialog information when opening a compendium"
12+
}
13+
},
14+
"notifications": {
15+
"first-launch": "First launch of this adventure! Unpacking scene...",
16+
"done": "All done!",
17+
"pack-scene": {
18+
"clear-reminder": "Don't forget to run ScenePacker.ClearPackedData() after exporting to prevent future duplicates.",
19+
"writing-journals": "Writing {number} journals to scene: {name}",
20+
"no-journal-pins": "No journal pins detected on the scene.",
21+
"no-token-name-warning": "Cannot pack a token that has no name. Check console for details.",
22+
"no-token-name-log": "Trying to pack a token that has no name is not going to end well. Please ensure the Token and Actor have a name.",
23+
"writing-tokens": "Writing {number} tokens to scene: {name}",
24+
"no-tokens": "No tokens detected on the scene."
25+
},
26+
"import-by-name": {
27+
"creating-data": "Importing {count} new {type}.",
28+
"missing-name": "Tried to find an actor for a token with no name.",
29+
"invalid-packs": {
30+
"error": "Invalid pack configuration. Cannot import {type}. Check console for more details.",
31+
"short": "ImportByName was called with no searchPacks defined.",
32+
"details": "ImportByName was called with no valid searchPacks defined. Received the following call details:",
33+
"reference": "ImportByName was called with a reference that is not registered with Foundry. Received the following call details:",
34+
"missing-pack": "Invalid pack configuration. Cannot find compendium {packName}. Check console for more details.",
35+
"missing-pack-details": "ImportByName was called to search for pack \"{packName}\" which is not found. Check for typos in your module setup."
36+
}
37+
},
38+
"find-actor": {
39+
"missing-name": "Cannot find a token that has no name. Check console for details.",
40+
"missing-name-details": "Trying to find a token that has no name is not going to end well. Please ensure the Token and Actor have a name prior to packing."
41+
},
42+
"link-tokens": {
43+
"missing": "Could not find {count} actors to link, they will remain unlinked. Check console for details.",
44+
"missing-details": "Could not find {count} actors to link. The following actor tokens were not found in the \"{adventureName}\" folder.",
45+
"linking": "Relinking {count} Tokens linked to actors."
46+
},
47+
"spawn-notes": {
48+
"missing": "Could not find {count} journals to link. Check console for details.",
49+
"missing-details": "Could not find {count} notes to spawn. The following journals were not found.",
50+
"spawning": "Spawning {count} journal notes."
51+
},
52+
"unpack": {
53+
"no-items": "No items to configure. All done!"
54+
},
55+
"clear-data": {
56+
"done": "Finished clearing Packed Data."
57+
}
58+
},
59+
"compendium": {
60+
"title": "{title} Importer",
61+
"info-scene": "Please <strong>view each scene</strong> after importing to allow the module to correctly relink Journal Pins and Actors.",
62+
"info-other": "To import this adventure correctly, please <strong>import just the scenes</strong> first and then view each one. This will allow the module to correctly relink Journal Pins and Actors."
63+
},
64+
"scene-context": {
65+
"pack": {
66+
"title": "Pack Scene Data"
67+
},
68+
"clear": {
69+
"title": "Clear Packed Scene Data"
70+
}
71+
},
72+
"log": {
73+
"invalidForce": "{moduleName} | Invalid log usage. Expected \"log(force, ...args)\" as boolean but got {force}"
74+
},
75+
"errors": {
76+
"adventureName": {
77+
"ui": "Invalid call to SetAdventureName(). See console for details.",
78+
"details": "Invalid adventure name passed to \"SetAdventureName()\". This must be the name of the adventure as defined in module.json under the \"title\" field."
79+
},
80+
"moduleName": {
81+
"ui": "Invalid call to SetModuleName(). See console for details.",
82+
"details": "Invalid module name passed to \"SetModuleName()\". This must be the name of the module as defined in module.json under the \"name\" field."
83+
},
84+
"welcomeJournal": {
85+
"ui": "Invalid call to SetWelcomeJournal(). See console for details.",
86+
"details": "Invalid journal name passed to \"SetWelcomeJournal()\". This must be the name of a journal in the module compendium.",
87+
"missing": "SetWelcomeJournal() called with no value. This disables importing a welcome journal. No journal will automatically be opened."
88+
},
89+
"additionalJournals": {
90+
"ui": "Invalid call to SetAdditionalJournalsToImport(). See console for details.",
91+
"details": "You must pass an array of strings to \"SetAdditionalJournalsToImport()\". They must be the names of journals. Received: {journal}",
92+
"missing": "SetAdditionalJournalsToImport() called with no value. This disables importing of additional journals. Only those journals linked to the scene by a map pin will be imported."
93+
},
94+
"creaturePacks": {
95+
"ui": "Invalid call to SetCreaturePacks(). See console for details.",
96+
"details": "You must pass an array of strings to \"SetCreaturePacks()\". They must be the names of Actor Packs. Received: {pack}",
97+
"missing": "SetCreatePacks() called with no value. This disables importing of Actors."
98+
},
99+
"journalPacks": {
100+
"ui": "Invalid call to SetJournalPacks(). See console for details.",
101+
"details": "You must pass an array of strings to \"SetJournalPacks()\". They must be the names of Journal Packs. Received: {pack}",
102+
"missing": "SetJournalPacks() called with no value. This disables importing of Journals."
103+
}
104+
}
105+
}
106+
}

module.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "scene-packer",
33
"title": "Library: Scene Packer",
44
"description": "A module to assist with Scene and Adventure packing and unpacking.",
5-
"version": "1.0.0",
5+
"version": "1.0.1",
66
"library": "true",
77
"manifestPlusVersion": "1.0.0",
88
"minimumCoreVersion": "0.7.9",
@@ -27,7 +27,7 @@
2727
}],
2828
"url": "https://github.com/League-of-Foundry-Developers/scene-packer",
2929
"manifest": "https://github.com/League-of-Foundry-Developers/scene-packer/releases/latest/download/module.json",
30-
"download": "https://github.com/League-of-Foundry-Developers/scene-packer/releases/download/1.0.0/module.zip",
30+
"download": "https://github.com/League-of-Foundry-Developers/scene-packer/releases/download/1.0.1/module.zip",
3131
"bugs": "https://github.com/League-of-Foundry-Developers/scene-packer/issues",
3232
"changelog": "https://github.com/League-of-Foundry-Developers/scene-packer/blob/master/changelog.md",
3333
"allowBugReporter": true

0 commit comments

Comments
 (0)