Include Weapons and effects

Changes:
 + include weapon pack and effect pack
 + handle effects as own entity
 + effects can influence your attributes and skills
 + add Aktive Effekte page for effects on your character
This commit is contained in:
2023-11-24 20:11:36 +01:00
parent 4b2daef20a
commit 68cb8fcf6d
308 changed files with 1794 additions and 101 deletions
+16
View File
@@ -0,0 +1,16 @@
<table>
<thead>
<tr>
<th>{{localize "ITEM.TypeEffect"}}</th>
<th></th>
</tr>
</thead>
<tbody>
{{#each data.calc.gear.effects as |item itemId|}}
<tr data-item="{{itemId}}">
<td class="padding edit-item">{{item.label}}</td>
<td class="fixed-value"><a class="item-delete" title="Delete Item"><i class="fas fa-trash"></i></a></td>
</tr>
{{/each}}
</tbody>
</table>
+5
View File
@@ -10,6 +10,7 @@
<a class="item" data-tab="skills">{{ localize "midgard5.skills" }}</a>
<a class="item" data-tab="gear">{{ localize "midgard5.gear" }}</a>
<a class="item" data-tab="spells">{{ localize "midgard5.spells" }}</a>
<a class="item" data-tab="effects">{{ localize "midgard5.effects" }}</a>
</nav>
<section class="sheet-content">
@@ -30,5 +31,9 @@
{{> "systems/midgard5/templates/sheets/character/spells.hbs"}}
</div>
<div class="tab base_values flexcol" data-group="primary" data-tab="effects">
{{> "systems/midgard5/templates/sheets/character/effects.hbs"}}
</div>
</section>
</form>
+78
View File
@@ -0,0 +1,78 @@
<form class="item-sheet {{cssClass}} m5item-item" autocomplete="off">
<header class="sheet-header">
<img class="item-img" src="{{item.img}}" data-edit="img" title="{{item.name}}" />
<h1><input name="name" type="text" value="{{item.name}}" placeholder="Name" /></h1>
</header>
<div class="sheet-content">
<table>
<tr>
<td>
<input id="data.magic" type="checkbox" name="data.magic" {{checked data.magic}}>
<label for="data.magic">{{localize "midgard5.magic"}}</label>
</td>
<td>
<div class="flexrow">
<span>{{localize "midgard5.item-value"}}</span>
<input name="data.value" type="text" value="{{data.value}}" data-dtype="Number" />
</div>
</td>
</tr>
</table>
<table>
<thead>
<tr>
<th>Mods</th>
<th></th>
<th></th>
<th><button class="add-mod">+</button></th>
</tr>
</thead>
<tbody>
{{#each data.mods as |mod modId|}}
<tr>
<td>
<select class="select-mod-type" name="data.mods.{{modId}}.type" data-type="String">
{{#select mod.type}}
<option value="attribute">{{localize "midgard5.attribute"}}</option>
<option value="stat">{{localize "midgard5.bonus"}}</option>
<option value="skill">{{localize "midgard5.skill"}}</option>
{{/select}}
</select>
</td>
<td>
<select class="select-id" name="data.mods.{{modId}}.id" data-type="String">
{{#select mod.id}}
<option value="">{{localize "midgard5.no-skill"}}</option>
{{#each (lookup ../data.calc.mods modId) as |name key|}}
<option value="{{key}}">{{name}}</option>
{{/each}}
{{/select}}
</select>
</td>
<td>
<select class="select-mod-operation" name="data.mods.{{modId}}.operation" data-type="String">
{{#select mod.operation}}
{{#if (eq mod.type "attribute")}}
<option value="add100">{{localize "midgard5.mod-operation-add100"}}</option>
{{/if}}
<option value="add">{{localize "midgard5.mod-operation-add"}}</option>
<option value="set">{{localize "midgard5.mod-operation-set"}}</option>
<option value="fixed">{{localize "midgard5.mod-operation-fixed"}}</option>
{{/select}}
</select>
</td>
<td>
<input name="data.mods.{{modId}}.value" type="text" value="{{mod.value}}" data-dtype="Number" />
</td>
</tr>
{{/each}}
</tbody>
</table>
{{editor content=data.description target="data.description" button=true owner=owner editable=editable}}
</div>
</form>