Item descriptions

This commit is contained in:
LeRatierBretonnien 2022-12-28 10:30:56 +01:00
parent d56be5dcd6
commit d49452efc5
12 changed files with 120 additions and 62 deletions

View File

@ -4,10 +4,11 @@ export const Hero6_CONFIG = {
rollCharac : { rollCharac : {
"str": "Strength", "str": "Strength",
"dex": "Dexterity", "dex": "Dexterity",
"pre": "Presence",
"int": "Intelligence",
"con": "Constitution", "con": "Constitution",
"ego": "Ego" "int": "Intelligence",
"ego": "Ego",
"pre": "Presence",
"manual": "Manual",
}, },
skillType: { skillType: {
"agility": "Agility", "agility": "Agility",
@ -15,7 +16,17 @@ export const Hero6_CONFIG = {
"intellect": "Intellect" , "intellect": "Intellect" ,
"background": "Background" , "background": "Background" ,
"combat": "Combat" , "combat": "Combat" ,
"custom": "Custom"
},
powerEquipmentType: {
"adjustement": "Adjustement",
"attack": "Attack",
"bodyaffecting": "Bodyaffecting",
"defense": "Defense",
"mental": "Mental",
"movement": "Movement",
"senseaffecting": "Senseaffecting",
"sensory": "Sensory",
"special": "Special"
} }
} }

View File

@ -42,6 +42,12 @@ export class Hero6Utility {
Handlebars.registerHelper('locationLabel', function (key) { Handlebars.registerHelper('locationLabel', function (key) {
return __locationNames[key] return __locationNames[key]
}) })
Handlebars.registerHelper('isSkillCustom', function (key) {
if (key == "custom" || key == "background" || key == "combat" ) {
return true;
}
return false
})
this.gameSettings() this.gameSettings()
@ -149,7 +155,9 @@ export class Hero6Utility {
'systems/fvtt-hero-system-6/templates/partials/partial-options-abilities.hbs', 'systems/fvtt-hero-system-6/templates/partials/partial-options-abilities.hbs',
'systems/fvtt-hero-system-6/templates/partials/partial-item-nav.hbs', 'systems/fvtt-hero-system-6/templates/partials/partial-item-nav.hbs',
'systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs', 'systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs',
'systems/fvtt-hero-system-6/templates/partials/partial-actor-equipment.hbs' 'systems/fvtt-hero-system-6/templates/partials/partial-actor-equipment.hbs',
'systems/fvtt-hero-system-6/templates/partials/partial-item-cost.hbs',
'systems/fvtt-hero-system-6/templates/partials/partial-power-equipment-cost.hbs',
] ]
return loadTemplates(templatePaths); return loadTemplates(templatePaths);
} }

View File

@ -82,7 +82,7 @@
"styles": [ "styles": [
"styles/simple.css" "styles/simple.css"
], ],
"version": "10.0.1", "version": "10.0.2",
"compatibility": { "compatibility": {
"minimum": "10", "minimum": "10",
"verified": "10", "verified": "10",
@ -90,7 +90,7 @@
}, },
"title": "Hero System v6 for FoundrtVTT (Official)", "title": "Hero System v6 for FoundrtVTT (Official)",
"manifest": "https://www.uberwald.me/gitea/uberwald/fvtt-hero-system-6/raw/branch/main/system.json", "manifest": "https://www.uberwald.me/gitea/uberwald/fvtt-hero-system-6/raw/branch/main/system.json",
"download": "https://www.uberwald.me/gitea/uberwald/fvtt-hero-system-6/archive/fvtt-hero-system-6-v10.0.1.zip", "download": "https://www.uberwald.me/gitea/uberwald/fvtt-hero-system-6/archive/fvtt-hero-system-6-v10.0.2.zip",
"url": "https://www.uberwald.me/gitea/uberwald/", "url": "https://www.uberwald.me/gitea/uberwald/",
"background": "images/ui/hro6_welcome_page.webp", "background": "images/ui/hro6_welcome_page.webp",
"id": "fvtt-hero-system-6" "id": "fvtt-hero-system-6"

View File

@ -24,7 +24,9 @@
"str": { "str": {
"label": "Strength", "label": "Strength",
"value": 10, "value": 10,
"base": 10 "base": 10,
"realcost": 0,
"activecost": 0
}, },
"dex": { "dex": {
"label": "Dexterity", "label": "Dexterity",
@ -91,12 +93,20 @@
"pd": { "pd": {
"label": "PD", "label": "PD",
"value": 2, "value": 2,
"base": 2 "base": 2,
"pd_nonresistant_total": 0,
"pd_resistant_toal": 0,
"pd_resistant_primary": 0,
"pd_resistant_secondary": 0
}, },
"ed": { "ed": {
"label": "ED", "label": "ED",
"value": 2, "value": 2,
"base": 2 "base": 2,
"ed_nonresistant_total": 0,
"ed_resistant_toal": 0,
"ed_resistant_primary": 0,
"ed_resistant_secondary": 0
}, },
"rec": { "rec": {
"label": "REC", "label": "REC",
@ -149,7 +159,11 @@
"leaping": { "leaping": {
"label": "Leaping", "label": "Leaping",
"value": 4, "value": 4,
"base": 4 "base": 4,
"leaping_horizontal_base": 0,
"leaping_horizontal_total": 0,
"leaping_vertical_base": 0,
"leaping_vertical_total": 0
}, },
"flying": { "flying": {
"label": "Flying", "label": "Flying",
@ -186,20 +200,25 @@
], ],
"templates": { "templates": {
"common": { "common": {
"displayname": "",
"description": "", "description": "",
"notes": "",
"effects": "", "effects": "",
"cost": "", "cost": "",
"activecost": 0,
"basecost": 0,
"value": 0, "value": 0,
"modifiers": [] "modifiers": []
}, },
"power": { "power": {
"description": "", "displayname": "",
"cost": "",
"modifiers": [], "modifiers": [],
"type": "", "petype": "",
"effect": 0,
"levels": 0, "levels": 0,
"end": 0, "quantity": 0,
"range": "",
"damage": "",
"endurance": 0,
"items": {} "items": {}
} }
}, },
@ -214,9 +233,9 @@
] ]
}, },
"skill": { "skill": {
"skilltype": "", "skilltype": "agility",
"characteristic": "", "characteristic": "",
"base": 0, "base": "",
"skillroll": 0, "skillroll": 0,
"levels": 0, "levels": 0,
"templates": [ "templates": [
@ -226,14 +245,16 @@
}, },
"power": { "power": {
"templates": [ "templates": [
"common",
"power" "power"
] ]
}, },
"equipment": { "equipment": {
"templates": [ "templates": [
"common",
"power" "power"
], ],
"quantity": 1, "value": 0,
"weight": 0, "weight": 0,
"moneycost": 0 "moneycost": 0
}, },
@ -288,21 +309,29 @@
"velValue": 0 "velValue": 0
}, },
"perk": { "perk": {
"roll": 0,
"templates": [ "templates": [
"common" "common"
] ]
}, },
"talent": { "talent": {
"roll": 0,
"templates": [ "templates": [
"common" "common"
] ]
}, },
"complication": { "complication": {
"hasroll": false,
"roll": 0,
"templates": [ "templates": [
"common" "common"
] ]
}, },
"martialart": { "martialart": {
"maneuver_phase": 0,
"maneuver_ocv": 0,
"maneuver_dcv": 0,
"maneuver_effect": "",
"templates": [ "templates": [
"common" "common"
] ]

View File

@ -13,10 +13,16 @@
{{> systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs}} {{> systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs}}
<li class="flexrow"><label class="generic-label">Cost</label> <li class="flexrow"><label class="item-field-label-long">Has Roll ?</label>
<input type="text" class="" name="system.cost" value="{{system.cost}}" data-dtype="Number"/> <label class="item-field-label-medium"><input type="checkbox" name="system.hasroll" {{checked system.hasroll}}/></label>
</li> </li>
<li class="flexrow"><label class="item-field-label-long">Roll</label>
<input type="text" class="item-field-label-medium" name="system.roll" value="{{system.roll}}" data-dtype="Number"/>
</li>
{{> systems/fvtt-hero-system-6/templates/partials/partial-item-cost.hbs}}
<div class="tab details" data-group="primary" data-tab="details"> <div class="tab details" data-group="primary" data-tab="details">
</div> </div>
</section> </section>

View File

@ -15,18 +15,22 @@
<div class="tab details" data-group="primary" data-tab="details"> <div class="tab details" data-group="primary" data-tab="details">
<ul> <ul>
<li class="flexrow"><label class="generic-label">Equipped ?</label>
<label class="attribute-value checkbox"><input type="checkbox" name="system.equipped" {{checked system.equipped}}/></label> {{> systems/fvtt-hero-system-6/templates/partials/partial-power-equipment-cost.hbs}}
<li class="flexrow"><label class="item-field-label-long">Equipped ?</label>
<label class="item-field-label-medium"><input type="checkbox" name="system.equipped" {{checked system.equipped}}/></label>
</li> </li>
<li class="flexrow"><label class="generic-label">Quantity</label>
<input type="text" class="input-numeric-short padd-right" name="system.quantity" value="{{system.quantity}}" data-dtype="Number"/> <li class="flexrow"><label class="item-field-label-long">Weight</label>
<input type="text" class="item-field-label-medium input-numeric-short padd-right" name="system.weight" value="{{system.weight}}" data-dtype="Number"/>
</li> </li>
<li class="flexrow"><label class="generic-label">Weight</label> <li class="flexrow"><label class="item-field-label-long">Value</label>
<input type="text" class="input-numeric-short padd-right" name="system.weight" value="{{system.weight}}" data-dtype="Number"/> <input type="text" class="item-field-label-medium input-numeric-short padd-right" name="system.value" value="{{system.value}}" data-dtype="Number"/>
</li>
<li class="flexrow"><label class="generic-label">Cost</label>
<input type="text" class="input-numeric-short padd-right" name="system.moneycost" value="{{system.moneycost}}" data-dtype="Number"/>
</li> </li>
{{> systems/fvtt-hero-system-6/templates/partials/partial-item-cost.hbs}}
</ul> </ul>
</div> </div>

View File

@ -13,9 +13,7 @@
{{> systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs}} {{> systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs}}
<li class="flexrow"><label class="generic-label">Cost</label> {{> systems/fvtt-hero-system-6/templates/partials/partial-item-cost.hbs}}
<input type="text" class="" name="system.cost" value="{{system.cost}}" data-dtype="Number"/>
</li>
<div class="tab details" data-group="primary" data-tab="details"> <div class="tab details" data-group="primary" data-tab="details">
</div> </div>

View File

@ -13,10 +13,12 @@
{{> systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs}} {{> systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs}}
<li class="flexrow"><label class="generic-label">Cost</label> <li class="flexrow"><label class="item-field-label-long">Roll</label>
<input type="text" class="" name="system.cost" value="{{system.cost}}" data-dtype="Number"/> <input type="text" class="item-field-label-medium" name="system.roll" value="{{system.roll}}" data-dtype="Number"/>
</li> </li>
{{> systems/fvtt-hero-system-6/templates/partials/partial-item-cost.hbs}}
<div class="tab details" data-group="primary" data-tab="details"> <div class="tab details" data-group="primary" data-tab="details">
</div> </div>
</section> </section>

View File

@ -13,9 +13,9 @@
{{> systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs}} {{> systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs}}
<li class="flexrow"><label class="generic-label">Cost</label> {{> systems/fvtt-hero-system-6/templates/partials/partial-power-equipment-cost.hbs}}
<input type="text" class="" name="system.cost" value="{{system.cost}}" data-dtype="Number"/>
</li> {{> systems/fvtt-hero-system-6/templates/partials/partial-item-cost.hbs}}
<div class="tab details" data-group="primary" data-tab="details"> <div class="tab details" data-group="primary" data-tab="details">
</div> </div>

View File

@ -15,8 +15,8 @@
<div class="tab details" data-group="primary" data-tab="details"> <div class="tab details" data-group="primary" data-tab="details">
<ul> <ul>
<li class="flexrow"><label class="generic-label">Type</label> <li class="flexrow"><label class="item-field-label-long">Type</label>
<select class="competence-base flexrow" type="text" name="system.skilltype" value="{{system.skilltype}}" data-dtype="String"> <select class="item-field-label-medium" type="text" name="system.skilltype" value="{{system.skilltype}}" data-dtype="String">
{{#select system.skilltype}} {{#select system.skilltype}}
{{#each config.skillType as |char key|}} {{#each config.skillType as |char key|}}
<option value="{{key}}">{{char}}</option> <option value="{{key}}">{{char}}</option>
@ -25,32 +25,28 @@
</select> </select>
</li> </li>
<li class="flexrow"><label class="generic-label">Base characteristic</label> {{#if (isSkillCustom system.skilltype)}}
<select class="competence-base flexrow" type="text" name="system.characteristic" value="{{system.characteristic}}" data-dtype="String"> <li class="flexrow"><label class="item-field-label-long">Base characteristic</label>
<select class="item-field-label-medium" type="text" name="system.characteristic" value="{{system.characteristic}}" data-dtype="String">
{{#select system.characteristic}} {{#select system.characteristic}}
{{#each config.rollCharac as |char key|}} {{#each config.rollCharac as |char key|}}
<option value="{{key}}">{{char}}</option> <option value="{{key}}">{{char}}</option>
{{/each}} {{/each}}
<option value="manual">Manual</option>
{{/select}} {{/select}}
</select> </select>
</li> </li>
{{#if (eq system.characteristic "manual")}}
<li class="flexrow"><label class="item-field-label-long">Base value</label>
<input type="text" class="item-field-label-medium" name="system.base" value="{{system.base}}" data-dtype="Number" {{#if (ne system.characteristic "manual")}}disabled{{/if}} />
</li>
{{/if}}
{{/if}}
<li class="flexrow"><label class="generic-label">Base value</label> <li class="flexrow"><label class="item-field-label-long">Skill Roll points</label>
<input type="text" class="" name="system.base" value="{{system.base}}" data-dtype="Number" {{#if (ne system.characteristic "manual")}}disabled{{/if}} /> <input type="text" class="item-field-label-medium" name="system.skillroll" value="{{system.skillroll}}" data-dtype="Number"/>
</li> </li>
<li class="flexrow"><label class="generic-label">Skill Roll points</label> {{> systems/fvtt-hero-system-6/templates/partials/partial-item-cost.hbs}}
<input type="text" class="" name="system.skillroll" value="{{system.skillroll}}" data-dtype="Number"/>
</li>
<li class="flexrow"><label class="generic-label">Base cost</label>
<input type="text" class="" name="system.cost" value="{{system.cost}}" data-dtype="Number"/>
</li>
<li class="flexrow"><label class="generic-label">+1 cost</label>
<input type="text" class="" name="system.plusonecost" value="{{system.plusonecost}}" data-dtype="Number"/>
</li>
</ul> </ul>
</div> </div>

View File

@ -13,9 +13,7 @@
{{> systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs}} {{> systems/fvtt-hero-system-6/templates/partials/partial-item-description.hbs}}
<li class="flexrow"><label class="generic-label">Cost</label> {{> systems/fvtt-hero-system-6/templates/partials/partial-item-cost.hbs}}
<input type="text" class="" name="system.cost" value="{{system.cost}}" data-dtype="Number"/>
</li>
<div class="tab details" data-group="primary" data-tab="details"> <div class="tab details" data-group="primary" data-tab="details">
</div> </div>

View File

@ -5,4 +5,10 @@
{{editor description target="system.description" button=true owner=owner editable=editable}} {{editor description target="system.description" button=true owner=owner editable=editable}}
</div> </div>
</div> </div>
<div>
<label class="generic-label">Notes</label>
<div class="medium-editor item-text-long-line">
{{editor notes target="system.notes" button=true owner=owner editable=editable}}
</div>
</div>
</div> </div>