diff --git a/src/assets/blunt.png b/src/assets/blunt.png new file mode 100644 index 0000000..ce5de85 Binary files /dev/null and b/src/assets/blunt.png differ diff --git a/src/assets/brace.png b/src/assets/brace.png new file mode 100644 index 0000000..5d77aec Binary files /dev/null and b/src/assets/brace.png differ diff --git a/src/assets/charge.png b/src/assets/charge.png new file mode 100644 index 0000000..23cbf32 Binary files /dev/null and b/src/assets/charge.png differ diff --git a/src/assets/melee.png b/src/assets/melee.png index 831b0fc..5bf9a08 100644 Binary files a/src/assets/melee.png and b/src/assets/melee.png differ diff --git a/src/assets/missile.png b/src/assets/missile.png index 20bf16c..50e91d0 100644 Binary files a/src/assets/missile.png and b/src/assets/missile.png differ diff --git a/src/assets/reload.png b/src/assets/reload.png new file mode 100644 index 0000000..ee3e42c Binary files /dev/null and b/src/assets/reload.png differ diff --git a/src/assets/slow.png b/src/assets/slow.png new file mode 100644 index 0000000..7445a41 Binary files /dev/null and b/src/assets/slow.png differ diff --git a/src/assets/splash.png b/src/assets/splash.png new file mode 100644 index 0000000..dcc7c78 Binary files /dev/null and b/src/assets/splash.png differ diff --git a/src/assets/twohanded.png b/src/assets/twohanded.png index 033cf04..ad23ed5 100644 Binary files a/src/assets/twohanded.png and b/src/assets/twohanded.png differ diff --git a/src/lang/en.json b/src/lang/en.json index 43b1286..112bcad 100644 --- a/src/lang/en.json +++ b/src/lang/en.json @@ -188,9 +188,6 @@ "OSE.items.RollTarget": "Target", "OSE.items.RollType": "Type", "OSE.items.Damage": "Damage", - "OSE.items.Melee": "Melee", - "OSE.items.Missile": "Missile", - "OSE.items.Slow": "Slow", "OSE.items.ArmorAC": "AC", "OSE.items.ArmorAAC": "AAC", "OSE.items.Bonus": "Bonus", @@ -201,6 +198,16 @@ "OSE.items.typeTag": "Type a comma separated list of tag e.g 'Melee,Missile (5’–10’ / 11’–20’ / 21’–30’)'", "OSE.items.pattern": "Attack pattern marker", + "OSE.items.Melee": "Melee", + "OSE.items.Missile": "Missile", + "OSE.items.Slow": "Slow", + "OSE.items.TwoHanded": "Two-handed", + "OSE.items.Blunt": "Blunt", + "OSE.items.Brace": "Brace", + "OSE.items.Splash": "Splash weapon", + "OSE.items.Reload": "Reload", + "OSE.items.Charge": "Charge", + "OSE.armor.type": "Armor Type", "OSE.armor.unarmored": "Unarmored", "OSE.armor.light": "Light", diff --git a/src/module/config.js b/src/module/config.js index 4f2014a..0ae8e6c 100644 --- a/src/module/config.js +++ b/src/module/config.js @@ -70,17 +70,22 @@ export const OSE = { melee: "OSE.items.Melee", missile: "OSE.items.Missile", slow: "OSE.items.Slow", - blunt: "OSE.items.Blunt", - reload: "OSE.items.Reload", - splash: "OSE.items.Splash", - brace: "OSE.items.Brace", twohanded: "OSE.items.TwoHanded", + blunt: "OSE.items.Blunt", + brace: "OSE.items.Brace", + splash: "OSE.items.Splash", + reload: "OSE.items.Reload", + charge: "OSE.items.Charge", }, tag_images: { melee: "/systems/ose/assets/melee.png", missile: "/systems/ose/assets/missile.png", - slow: "", + slow: "/systems/ose/assets/slow.png", twohanded: "/systems/ose/assets/twohanded.png", + blunt: "/systems/ose/assets/blunt.png", + brace: "/systems/ose/assets/brace.png", + splash: "/systems/ose/assets/splash.png", + reload: "/systems/ose/assets/reload.png", + charge: "/systems/ose/assets/charge.png", } -}; -// fa-sign-language \ No newline at end of file +}; \ No newline at end of file diff --git a/src/module/helpers.js b/src/module/helpers.js index 1e79bde..5b92cbe 100644 --- a/src/module/helpers.js +++ b/src/module/helpers.js @@ -38,6 +38,11 @@ export const registerHelpers = async function () { return Math.round(parseFloat(weight) / 100) / 10; }); + Handlebars.registerHelper("getTagIcon", function (tag) { + let idx = Object.keys(CONFIG.OSE.tags).find(k => (CONFIG.OSE.tags[k] == tag)); + return CONFIG.OSE.tag_images[idx]; + }); + Handlebars.registerHelper("counter", function (status, value, max) { return status ? Math.clamped((100.0 * value) / max, 0, 100) diff --git a/src/module/item/entity.js b/src/module/item/entity.js index de1e6db..58d47ff 100644 --- a/src/module/item/entity.js +++ b/src/module/item/entity.js @@ -190,8 +190,9 @@ export class OseItem extends Item { let title = ""; if (matches) { title = matches[1]; - val = val.substring(0, matches.index); + val = val.substring(0, matches.index).trim(); } else { + val = val.trim(); title = val; } // Auto fill checkboxes diff --git a/src/scss/actor-base.scss b/src/scss/actor-base.scss index a4427ee..f061272 100644 --- a/src/scss/actor-base.scss +++ b/src/scss/actor-base.scss @@ -290,6 +290,11 @@ img { border: none; margin: 3px 1px; + flex: 0 0 24px; + } + span { + font-size: 12px; + flex-grow: 0; } } .field-flex { diff --git a/src/templates/actors/partials/character-inventory-tab.html b/src/templates/actors/partials/character-inventory-tab.html index bcfa8e3..d153ed4 100644 --- a/src/templates/actors/partials/character-inventory-tab.html +++ b/src/templates/actors/partials/character-inventory-tab.html @@ -3,7 +3,7 @@
  • {{localize "OSE.items.Weapons"}}
    -
    {{localize "OSE.items.Qualities"}}
    +
    {{localize "OSE.items.Qualities"}}
    -
    +
    {{#each item.data.tags as |tag|}} - {{#if (lookup @root.config.tag_images tag.value)}} - - {{else}} - {{tag.value}} + {{#if (getTagIcon tag.value)}} + {{/if}} {{/each}} + {{#each item.data.tags as |tag|}} + {{#unless (getTagIcon tag.value)}} + {{tag.value}}{{#unless @last}},{{/unless}} + + {{/unless}} + {{/each}}
    {{#if @root.config.encumbranceBasic}}_{{else}}{{item.data.weight}}{{/if}}