fix: Correct critical bugs and complete Creature/Group DataModel implementation

- Fix TypeError: controls.find is not a function in hooks.mjs
- Fix undefined 'npc' variable in applications.mjs
- Fix CONFIG.VERMINE.model undefined by checking game.system.template existence
- Fix TypeError: html.find(...).forEach is not a function in roll.mjs
- Fix Cannot set properties of undefined (setting 'initial') in actor.mjs
- Fix Cannot read properties of undefined (reading 'difficulty') in actor.mjs
- Fix ActiveEffect application phase 'initial' already completed by adding combatStatus to base template
- Fix Missing helper: 'select' in roll-dialog.hbs (removed invalid Handlebars select block)
- Add SIZE_LEVELS labels to creatureSizeLevels config
- Add SIZE_LEVELS translations to fr.json
- Add combatStatus to base actor template
- Convert all .html templates to .hbs for Foundry v14 compatibility
- Update item-sheet.mjs to use .hbs extension
- Update handlebars-manager.mjs to use .hbs for all partials

Complete Vermine2047 Creature and Group sheet implementation:
- Creature: Pattern, Size, Role, Pack with computed values
- Group: Totem, Reserve, Morale, Objectives, Members management
- All templates functional with proper styling

Generated by Mistral Vibe.
Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
2026-06-04 20:58:22 +02:00
parent f9f07cbc7e
commit 30d6f71fc7
43 changed files with 19225 additions and 609 deletions
+55
View File
@@ -0,0 +1,55 @@
<form class="{{cssClass}}" autocomplete="off">
{{> "systems/vermine2047/templates/item/partials/header.hbs"}}
<section class="sheet-body">
{{> "systems/vermine2047/templates/item/partials/traits.hbs"}}
<h4 class="flexrow">
<div class="resource align-center flexcol">
<label class="resource-label">{{ localize "VERMINE.ranges"}}</label>
<div class="flexrow align-center">
<div class="hexa">
<input type="number" name="system.min_range" value="{{system.min_range}}" data-dtype="Number"/>
</div>/
<div class="hexa">
<input type="number" name="system.max_range" value="{{system.max_range}}" data-dtype="Number"/></div>
</div>
</div>
<div class="resource align-center flexcol">
<label class="resource-label">{{ localize "VERMINE.damages"}}</label>
<div class="flexcol align-center">
<div class="flexrow">
<div class="hexa">
<input type="number" name="system.damage.value" value="{{system.damage.value}}" data-dtype="Number"/>
</div>
<span>
<input type="checkbox" data-tooltip="ajouter la vigueur" name="system.damage.addVigor" {{#if system.damage.addVigor}} checked {{/if}}>
</span>
</div>
<select name="system.damage.type">
<option value="0">type</option>
{{#each config.damageTypes as |label index|}}
<option value="{{label}}" {{#ife @root.system.damage.type label}} selected {{/ife}}>
{{label}}
</option>
{{/each}}
</select>
</div>
</div>
<div class="resource align-center flexcol">
<label class="resource-label">{{ localize "VERMINE.ammo"}}</label>
<div class="hexa"><input type="number" name="system.ammo" value="{{system.ammo}}" data-dtype="Number"/></div>
</div>
</h4>
{{> "systems/vermine2047/templates/item/partials/physicalItems.hbs"}}
</section>
</form>