diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 26b41a3..dfc0cce 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -1,3 +1,7 @@ +v2.3 +- Added shortened attribute names to use in templates +- Handlebars "concat" helper added + v2.2 - Spanish translation added - Cohorts localization fix diff --git a/lang/en.json b/lang/en.json index cd0b60a..7a0f03c 100644 --- a/lang/en.json +++ b/lang/en.json @@ -138,18 +138,21 @@ "BITD.EffectGreat": "Great", "BITD.SkillsInsight": "Insight", + "BITD.SkillsInsightShort": "Insight", "BITD.SkillsHunt": "Hunt", "BITD.SkillsStudy": "Study", "BITD.SkillsSurvey": "Survey", "BITD.SkillsTinker": "Tinker", "BITD.SkillsProwess": "Prowess", + "BITD.SkillsProwessShort": "Prowess", "BITD.SkillsFinesse": "Finesse", "BITD.SkillsProwl": "Prowl", "BITD.SkillsSkirmish": "Skirmish", "BITD.SkillsWreck": "Wreck", "BITD.SkillsResolve": "Resolve", + "BITD.SkillsResolveShort": "Resolve", "BITD.SkillsAttune": "Attune", "BITD.SkillsCommand": "Command", "BITD.SkillsConsort": "Consort", diff --git a/lang/es.json b/lang/es.json index efe52e7..de90711 100644 --- a/lang/es.json +++ b/lang/es.json @@ -138,18 +138,21 @@ "BITD.EffectGreat": "Excelente", "BITD.SkillsInsight": "Perspicacia", + "BITD.SkillsInsightShort": "Per.", "BITD.SkillsHunt": "Cazar", "BITD.SkillsStudy": "Estudiar", "BITD.SkillsSurvey": "Analizar", "BITD.SkillsTinker": "Trastear", "BITD.SkillsProwess": "Destreza", + "BITD.SkillsProwessShort": "Des.", "BITD.SkillsFinesse": "Afinar", "BITD.SkillsProwl": "Acechar", "BITD.SkillsSkirmish": "Pelear", "BITD.SkillsWreck": "Destrozar", "BITD.SkillsResolve": "Voluntad", + "BITD.SkillsResolveShort": "Vol.", "BITD.SkillsAttune": "Armonizar", "BITD.SkillsCommand": "Mandar", "BITD.SkillsConsort": "Socializar", diff --git a/lang/ru.json b/lang/ru.json index dfa5222..196b66e 100644 --- a/lang/ru.json +++ b/lang/ru.json @@ -131,16 +131,19 @@ "BITD.EffectStandard": "Средняя", "BITD.EffectGreat": "Высокая", "BITD.SkillsInsight": "Чутьё", + "BITD.SkillsInsightShort": "Чутьё", "BITD.SkillsHunt": "Охота", "BITD.SkillsStudy": "Изучение", "BITD.SkillsSurvey": "Разведка", "BITD.SkillsTinker": "Ремесло", "BITD.SkillsProwess": "Удаль", + "BITD.SkillsProwessShort": "Удаль", "BITD.SkillsFinesse": "Сноровка", "BITD.SkillsProwl": "Проникновение", "BITD.SkillsSkirmish": "Драка", "BITD.SkillsWreck": "Разрушение", "BITD.SkillsResolve": "Воля", + "BITD.SkillsResolveShort": "Воля", "BITD.SkillsAttune": "Манипулирование", "BITD.SkillsCommand": "Приказ", "BITD.SkillsConsort": "Общение", diff --git a/module/blades-sheet.js b/module/blades-sheet.js index 63a37a1..cf34aa6 100644 --- a/module/blades-sheet.js +++ b/module/blades-sheet.js @@ -88,9 +88,7 @@ export class BladesSheet extends ActorSheet { items_to_add.push(items.find(e => e._id === $(this).val())); }); - items_to_add.forEach(e => { - this.actor.createEmbeddedEntity("OwnedItem", duplicate(e)); - }); + this.actor.createEmbeddedEntity("OwnedItem", items_to_add); } /* -------------------------------------------- */ diff --git a/module/blades.js b/module/blades.js index 9316b8f..5171714 100644 --- a/module/blades.js +++ b/module/blades.js @@ -165,6 +165,19 @@ Hooks.once("init", async function() { return accum; }); + // Concat helper + // https://gist.github.com/adg29/f312d6fab93652944a8a1026142491b1 + // Usage: (concat 'first 'second') + Handlebars.registerHelper('concat', function() { + var outStr = ''; + for(var arg in arguments){ + if(typeof arguments[arg]!='object'){ + outStr += arguments[arg]; + } + } + return outStr; + }); + }); /** diff --git a/system.json b/system.json index f85a418..f62a43e 100644 --- a/system.json +++ b/system.json @@ -2,8 +2,8 @@ "name": "blades-in-the-dark", "title": "Blades in the Dark", "description": "Blades in the dark game system.", - "version": "2.2", - "minimumCoreVersion": "0.5.3", + "version": "2.3", + "minimumCoreVersion": "0.6.6", "compatibleCoreVersion": "0.7.2", "templateVersion": 1, "author": "megastruktur", @@ -31,8 +31,8 @@ } ], "url": "https://github.com/megastruktur/foundryvtt-blades-in-the-dark/", - "manifest": "https://raw.githubusercontent.com/megastruktur/foundryvtt-blades-in-the-dark/2.2/system.json", - "download": "https://github.com/megastruktur/foundryvtt-blades-in-the-dark/archive/2.2.zip", + "manifest": "https://raw.githubusercontent.com/megastruktur/foundryvtt-blades-in-the-dark/2.3/system.json", + "download": "https://github.com/megastruktur/foundryvtt-blades-in-the-dark/archive/2.3.zip", "packs": [ { "name": "class", diff --git a/templates/parts/attributes.html b/templates/parts/attributes.html index 85081cc..fb826ce 100644 --- a/templates/parts/attributes.html +++ b/templates/parts/attributes.html @@ -5,7 +5,7 @@
{{#multiboxes attribute.exp}}