2021-01-13 17:20:25 +01:00
|
|
|
{{!-- TODO: Refactor to avoid code duplication with special-creature-abilites-overview and talents-overview --}}
|
2021-01-02 01:01:41 +01:00
|
|
|
|
|
|
|
{{!-- ======================================================================== --}}
|
|
|
|
{{!-- INLINE PARTIAL DEFINITIONS --}}
|
|
|
|
{{!-- ======================================================================== --}}
|
|
|
|
|
|
|
|
|
2021-01-09 01:11:55 +01:00
|
|
|
{{!--
|
|
|
|
!-- Render the given partial block only if the given itemsArray has length > 0,
|
|
|
|
!-- else only an add button.
|
|
|
|
!--
|
|
|
|
!-- @param itemsArray: the array with the items to check the length of
|
|
|
|
!-- @param dataType: the string type of the item
|
|
|
|
--}}
|
|
|
|
{{#*inline "ifHasItemOfType"}}
|
|
|
|
{{#if (and (ne itemsArray undefined) (gt itemsArray.length 0))}}
|
2021-01-18 19:48:07 +01:00
|
|
|
{{> @partial-block}}
|
2021-01-09 01:11:55 +01:00
|
|
|
{{/if}}
|
2021-01-23 23:44:49 +01:00
|
|
|
{{> systems/ds4/templates/actor/partials/overview-add-button.hbs dataType=dataType }}
|
2021-01-09 01:11:55 +01:00
|
|
|
{{/inline}}
|
|
|
|
|
2021-01-02 01:01:41 +01:00
|
|
|
{{!-- ======================================================================== --}}
|
|
|
|
|
2021-01-18 19:59:25 +01:00
|
|
|
{{!-- WEAPONS --}}
|
2021-02-25 19:07:25 +01:00
|
|
|
<h4 class="ds4-item-list-title">{{localize 'DS4.ItemTypeWeaponPlural'}}</h4>
|
2021-01-18 19:59:25 +01:00
|
|
|
{{#> ifHasItemOfType itemsArray=itemsByType.weapon dataType='weapon' }}
|
2021-02-25 19:07:25 +01:00
|
|
|
<ol class="ds4-item-list ds4-item-list--weapon item-list">
|
2021-02-25 23:30:45 +01:00
|
|
|
{{#> systems/ds4/templates/actor/partials/item-list-header.hbs isEquipable=true hasQuantity=true}}
|
2021-02-26 01:08:55 +01:00
|
|
|
{{!-- attack type --}}
|
2021-02-25 19:07:25 +01:00
|
|
|
<div class="ds4-item-list__image" title="{{localize 'DS4.AttackType'}}">{{localize 'DS4.AttackTypeAbbr'}}</div>
|
2021-02-26 01:08:55 +01:00
|
|
|
|
|
|
|
{{!-- weapon bonus --}}
|
2021-02-25 19:07:25 +01:00
|
|
|
<div title="{{localize 'DS4.WeaponBonus'}}">
|
2021-01-18 19:59:25 +01:00
|
|
|
{{localize 'DS4.WeaponBonusAbbr'}}
|
|
|
|
</div>
|
2021-02-26 01:08:55 +01:00
|
|
|
|
|
|
|
{{!-- opponent defense --}}
|
2021-02-25 19:07:25 +01:00
|
|
|
<div title="{{localize 'DS4.OpponentDefense'}}">
|
2021-01-18 19:59:25 +01:00
|
|
|
{{localize 'DS4.OpponentDefenseAbbr'}}
|
|
|
|
</div>
|
2021-02-25 23:30:45 +01:00
|
|
|
{{/systems/ds4/templates/actor/partials/item-list-header.hbs}}
|
2021-02-26 01:08:55 +01:00
|
|
|
|
|
|
|
{{#each itemsByType.weapon as |itemData id|}}
|
|
|
|
{{#> systems/ds4/templates/actor/partials/item-list-entry.hbs itemData=itemData isEquipable=true hasQuantity=true}}
|
|
|
|
{{!-- attack type --}}
|
2021-02-25 19:07:25 +01:00
|
|
|
<div class="ds4-item-list__image"
|
2021-02-26 01:08:55 +01:00
|
|
|
style="background-image: url('{{lookup ../../config.icons.attackTypes itemData.data.attackType}}')"
|
|
|
|
title="{{lookup ../../config.i18n.attackTypes itemData.data.attackType}}">
|
2021-01-18 19:59:25 +01:00
|
|
|
</div>
|
2021-02-26 01:08:55 +01:00
|
|
|
|
|
|
|
{{!-- weapon bonus --}}
|
|
|
|
<div>{{ itemData.data.weaponBonus}}</div>
|
|
|
|
|
|
|
|
{{!-- opponent defense --}}
|
|
|
|
<div>{{ itemData.data.opponentDefense}}</div>
|
|
|
|
{{/systems/ds4/templates/actor/partials/item-list-entry.hbs}}
|
2021-01-18 19:59:25 +01:00
|
|
|
{{/each}}
|
|
|
|
</ol>
|
|
|
|
{{/ifHasItemOfType}}
|
|
|
|
|
|
|
|
{{!-- ARMOR --}}
|
2021-02-25 19:07:25 +01:00
|
|
|
<h4 class="ds4-item-list-title">{{localize 'DS4.ItemTypeArmorPlural'}}</h4>
|
2021-01-18 19:59:25 +01:00
|
|
|
{{#> ifHasItemOfType itemsArray=itemsByType.armor dataType='armor' }}
|
2021-02-25 19:07:25 +01:00
|
|
|
<ol class="ds4-item-list ds4-item-list--armor item-list">
|
2021-02-25 23:30:45 +01:00
|
|
|
{{#> systems/ds4/templates/actor/partials/item-list-header.hbs isEquipable=true hasQuantity=true}}
|
2021-02-26 01:08:55 +01:00
|
|
|
{{!-- armor material type --}}
|
2021-01-18 19:59:25 +01:00
|
|
|
<div title="{{localize 'DS4.ArmorMaterialType'}}">{{localize 'DS4.ArmorMaterialTypeAbbr'}}</div>
|
2021-02-26 01:08:55 +01:00
|
|
|
|
|
|
|
{{!-- armor type --}}
|
2021-01-18 19:59:25 +01:00
|
|
|
<div title="{{localize 'DS4.ArmorType'}}">{{localize 'DS4.ArmorTypeAbbr'}}</div>
|
2021-02-26 01:08:55 +01:00
|
|
|
|
|
|
|
{{!-- armor value --}}
|
2021-02-25 19:07:25 +01:00
|
|
|
<div title="{{localize 'DS4.ArmorValue'}}">
|
2021-01-18 19:59:25 +01:00
|
|
|
{{localize 'DS4.ArmorValueAbbr'}}
|
|
|
|
</div>
|
2021-02-25 23:30:45 +01:00
|
|
|
{{/systems/ds4/templates/actor/partials/item-list-header.hbs}}
|
2021-02-26 01:08:55 +01:00
|
|
|
|
|
|
|
{{#each itemsByType.armor as |itemData id|}}
|
|
|
|
{{#> systems/ds4/templates/actor/partials/item-list-entry.hbs itemData=itemData isEquipable=true hasQuantity=true}}
|
|
|
|
{{!-- armor material type --}}
|
|
|
|
<div title="{{lookup ../../config.i18n.armorMaterialTypes itemData.data.armorMaterialType}}">
|
|
|
|
{{lookup ../../config.i18n.armorMaterialTypesAbbr itemData.data.armorMaterialType}}
|
2021-01-18 19:59:25 +01:00
|
|
|
</div>
|
2021-02-26 01:08:55 +01:00
|
|
|
|
|
|
|
{{!-- armor type --}}
|
|
|
|
<div title="{{lookup ../../config.i18n.armorTypes itemData.dataData.armorType}}">
|
|
|
|
{{lookup ../../config.i18n.armorTypesAbbr itemData.dataData.armorType}}
|
2021-01-18 19:59:25 +01:00
|
|
|
</div>
|
2021-02-26 01:08:55 +01:00
|
|
|
|
|
|
|
{{!-- armor value --}}
|
|
|
|
<div>{{ itemData.data.armorValue}}</div>
|
|
|
|
{{/systems/ds4/templates/actor/partials/item-list-entry.hbs}}
|
2021-01-18 19:59:25 +01:00
|
|
|
{{/each}}
|
|
|
|
</ol>
|
|
|
|
{{/ifHasItemOfType}}
|
|
|
|
|
|
|
|
|
|
|
|
{{!-- SHIELD --}}
|
2021-02-25 19:07:25 +01:00
|
|
|
<h4 class="ds4-item-list-title">{{localize 'DS4.ItemTypeShieldPlural'}}</h4>
|
2021-01-18 19:59:25 +01:00
|
|
|
{{#> ifHasItemOfType itemsArray=itemsByType.shield dataType='shield' }}
|
2021-02-25 19:07:25 +01:00
|
|
|
<ol class="ds4-item-list ds4-item-list--shield item-list">
|
2021-02-25 23:30:45 +01:00
|
|
|
{{#> systems/ds4/templates/actor/partials/item-list-header.hbs isEquipable=true hasQuantity=true}}
|
2021-02-26 01:08:55 +01:00
|
|
|
{{!-- armor value --}}
|
2021-02-25 19:07:25 +01:00
|
|
|
<div title="{{localize 'DS4.ArmorValue'}}">
|
2021-01-18 19:59:25 +01:00
|
|
|
{{localize 'DS4.ArmorValueAbbr'}}
|
|
|
|
</div>
|
2021-02-25 23:30:45 +01:00
|
|
|
{{/systems/ds4/templates/actor/partials/item-list-header.hbs}}
|
2021-02-26 01:08:55 +01:00
|
|
|
{{#each itemsByType.shield as |itemData id|}}
|
|
|
|
{{#> systems/ds4/templates/actor/partials/item-list-entry.hbs itemData=itemData isEquipable=true hasQuantity=true}}
|
|
|
|
{{!-- armor value --}}
|
|
|
|
<div>{{itemData.data.armorValue}}</div>
|
|
|
|
{{/systems/ds4/templates/actor/partials/item-list-entry.hbs}}
|
2021-01-18 19:59:25 +01:00
|
|
|
{{/each}}
|
|
|
|
</ol>
|
|
|
|
{{/ifHasItemOfType}}
|
|
|
|
|
2021-02-21 03:40:54 +01:00
|
|
|
{{!-- EQUIPMENT --}}
|
2021-02-25 19:07:25 +01:00
|
|
|
<h4 class="ds4-item-list-title">{{localize 'DS4.ItemTypeEquipmentPlural'}}</h4>
|
2021-02-21 03:40:54 +01:00
|
|
|
{{#> ifHasItemOfType itemsArray=itemsByType.equipment dataType='equipment' }}
|
2021-02-25 19:07:25 +01:00
|
|
|
<ol class="ds4-item-list ds4-item-list--equipment item-list">
|
2021-02-25 23:30:45 +01:00
|
|
|
{{#> systems/ds4/templates/actor/partials/item-list-header.hbs isEquipable=true hasQuantity=true}}
|
2021-02-26 01:08:55 +01:00
|
|
|
{{!-- storage location --}}
|
2021-02-24 04:52:32 +01:00
|
|
|
<div>{{localize 'DS4.StorageLocation'}}</div>
|
2021-02-25 23:30:45 +01:00
|
|
|
{{/systems/ds4/templates/actor/partials/item-list-header.hbs}}
|
2021-02-26 01:08:55 +01:00
|
|
|
{{#each itemsByType.equipment as |itemData id|}}
|
|
|
|
{{#> systems/ds4/templates/actor/partials/item-list-entry.hbs itemData=itemData isEquipable=true hasQuantity=true}}
|
|
|
|
{{!-- storage location --}}
|
|
|
|
<input class="ds4-item-list__editable item-change" type="text" value="{{itemData.data.storageLocation}}"
|
2021-02-25 21:04:15 +01:00
|
|
|
data-dtype="String" data-property="data.storageLocation" title="{{localize 'DS4.StorageLocation'}}">
|
2021-02-26 01:08:55 +01:00
|
|
|
{{/systems/ds4/templates/actor/partials/item-list-entry.hbs}}
|
2021-01-18 19:59:25 +01:00
|
|
|
{{/each}}
|
|
|
|
</ol>
|
|
|
|
{{/ifHasItemOfType}}
|
|
|
|
|
2021-02-21 03:40:54 +01:00
|
|
|
{{!-- LOOT --}}
|
2021-02-25 19:07:25 +01:00
|
|
|
<h4 class="ds4-item-list-title">{{localize 'DS4.ItemTypeLootPlural'}}</h4>
|
2021-02-21 03:40:54 +01:00
|
|
|
{{#> ifHasItemOfType itemsArray=itemsByType.loot dataType='loot' }}
|
2021-02-25 19:07:25 +01:00
|
|
|
<ol class="ds4-item-list ds4-item-list--loot item-list">
|
2021-02-25 23:30:45 +01:00
|
|
|
{{#> systems/ds4/templates/actor/partials/item-list-header.hbs hasQuantity=true}}
|
2021-02-26 01:08:55 +01:00
|
|
|
{{!-- storage location --}}
|
2021-02-24 04:52:32 +01:00
|
|
|
<div>{{localize 'DS4.StorageLocation'}}</div>
|
2021-02-25 23:30:45 +01:00
|
|
|
{{/systems/ds4/templates/actor/partials/item-list-header.hbs}}
|
2021-02-26 01:08:55 +01:00
|
|
|
{{#each itemsByType.loot as |itemData id|}}
|
|
|
|
{{#> systems/ds4/templates/actor/partials/item-list-entry.hbs itemData=itemData hasQuantity=true}}
|
|
|
|
{{!-- storage location --}}
|
|
|
|
<input class="ds4-item-list__editable item-change" type="text" value="{{itemData.data.storageLocation}}"
|
2021-02-25 21:04:15 +01:00
|
|
|
data-dtype="String" data-property="data.storageLocation" title="{{localize 'DS4.StorageLocation'}}">
|
2021-02-26 01:08:55 +01:00
|
|
|
{{/systems/ds4/templates/actor/partials/item-list-entry.hbs}}
|
2021-01-18 19:59:25 +01:00
|
|
|
{{/each}}
|
|
|
|
</ol>
|
2021-02-20 22:41:33 +01:00
|
|
|
{{/ifHasItemOfType}}
|