Fiches de PNJ

This commit is contained in:
LeRatierBretonnien 2023-03-13 09:00:49 +01:00
parent f26cd7670c
commit 1b12dc44c9
11 changed files with 567 additions and 23 deletions

View File

@ -1,8 +1,7 @@
{
"ACTOR": {
"TypePersonnage": "Personnage",
"TypeCellule": "Cellule",
"TypeCreature": "Créature"
"TypePNJ": "PNJ"
},
"ITEM": {

View File

@ -0,0 +1,26 @@
/**
* Extend the basic ActorSheet with some very simple modifications
* @extends {ActorSheet}
*/
import { HeritiersActorSheet } from "./heritiers-actor-sheet.js";
import { HeritiersUtility } from "./heritiers-utility.js";
/* -------------------------------------------- */
export class HeritiersActorPNJSheet extends HeritiersActorSheet {
/** @override */
static get defaultOptions() {
return mergeObject(super.defaultOptions, {
classes: ["fvtt-les-heritiers", "sheet", "actor"],
template: "systems/fvtt-les-heritiers/templates/actor-pnj-sheet.html",
width: 780,
height: 840,
tabs: [{ navSelector: ".sheet-tabs", contentSelector: ".sheet-body", initial: "stats" }],
dragDrop: [{ dragSelector: ".item-list .item", dropSelector: null }],
editScore: false
})
}
}

View File

@ -64,7 +64,8 @@ export class HeritiersActorSheet extends ActorSheet {
options: this.options,
owner: this.document.isOwner,
editScore: this.options.editScore,
isGM: game.user.isGM
isGM: game.user.isGM,
isPNJ: (this.actor.type == "pnj")
}
this.formData = formData;
@ -141,6 +142,10 @@ export class HeritiersActorSheet extends ActorSheet {
const key = $(event.currentTarget).data("rang-key")
this.actor.rollRang(key, false)
})
html.find('.roll-root-competence').click((event) => {
const compKey = $(event.currentTarget).data("attr-key")
this.actor.rollRootCompetence(compKey)
})
html.find('.roll-competence').click((event) => {
const li = $(event.currentTarget).parents(".item")
let compId = li.data("item-id")

View File

@ -46,11 +46,7 @@ export class HeritiersActor extends Actor {
}
}
}
if (data.type == 'creature') {
const skills = await HeritiersUtility.loadCompendium("fvtt-les-heritiers.skills-creatures")
data.items = skills.map(i => i.toObject())
data.items.push({ name: "Arme naturelle 1", type: 'arme', img: "systems/fvtt-les-heritiers/assets/icons/melee.webp", system: { typearme: "contact", bonusmaniementoff: 0, seuildefense: 0, degats: "0" } })
data.items.push({ name: "Arme naturelle 2", type: 'arme', img: "systems/fvtt-les-heritiers/assets/icons/melee.webp", system: { typearme: "contact", bonusmaniementoff: 0, seuildefense: 0, degats: "0" } })
if (data.type == 'pnj') {
}
return super.create(data, options);
@ -178,19 +174,19 @@ export class HeritiersActor extends Actor {
let comp = {}
for (let key in game.system.lesheritiers.config.competenceProfil) {
if ( game.system.lesheritiers.config.competenceProfil[key].kind == kind)
comp[key] = []
comp[key] = { skills: [], niveau: this.system.competences[key].niveau }
}
for (let item of this.items) {
if (item.type == "competence") {
if (item.system.categorie == "utile" && comp[item.system.profil]) {
this.prepareUtileSkill(item)
comp[item.system.profil].push(item)
comp[item.system.profil].skills.push(item)
}
}
}
for (let key in comp) {
HeritiersUtility.sortArrayObjectsByName(comp[key])
HeritiersUtility.sortArrayObjectsByName(comp[key].skills)
}
return Object.fromEntries(Object.entries(comp).sort())
}
@ -564,6 +560,16 @@ export class HeritiersActor extends Actor {
let rollDialog = await HeritiersRollDialog.create(this, rollData)
rollDialog.render(true)
}
/* -------------------------------------------- */
async rollRootCompetence(compKey) {
let rollData = this.getCommonRollData()
rollData.mode = "competence"
console.log("Compkey", compKey)
rollData.competence = {name: this.system.competences[compKey].label, system: { niveau: this.system.competences[compKey].niveau }}
console.log("RollDatra", rollData)
let rollDialog = await HeritiersRollDialog.create(this, rollData)
rollDialog.render(true)
}
/* -------------------------------------------- */
async rollCompetence(compId) {

View File

@ -11,6 +11,7 @@
import { HeritiersActor } from "./heritiers-actor.js";
import { HeritiersItemSheet } from "./heritiers-item-sheet.js";
import { HeritiersActorSheet } from "./heritiers-actor-sheet.js";
import { HeritiersActorPNJSheet } from "./heritiers-actor-pnj-sheet.js";
import { HeritiersCreatureSheet } from "./heritiers-creature-sheet.js";
import { HeritiersUtility } from "./heritiers-utility.js";
import { HeritiersCombat } from "./heritiers-combat.js";
@ -55,7 +56,7 @@ Hooks.once("init", async function () {
// Register sheet application classes
Actors.unregisterSheet("core", ActorSheet);
Actors.registerSheet("fvtt-les-heritiers", HeritiersActorSheet, { types: ["personnage"], makeDefault: true })
Actors.registerSheet("fvtt-les-heritiers", HeritiersCreatureSheet, { types: ["creature"], makeDefault: true })
Actors.registerSheet("fvtt-les-heritiers", HeritiersActorPNJSheet, { types: ["pnj"], makeDefault: true })
Items.unregisterSheet("core", ItemSheet);
Items.registerSheet("fvtt-les-heritiers", HeritiersItemSheet, { makeDefault: true })

View File

@ -337,6 +337,12 @@ export class HeritiersUtility {
static async rollHeritiers(rollData) {
let actor = this.getActorFromRollData(rollData)
if ( typeof(rollData.pvMalus) != "number" ) {
ui.notifications.warn("Votre personnage est Moribond(e). Aucun jet autorisé")
return
}
//rollData.actionImg = "systems/fvtt-les-heritiers/assets/icons/" + actor.system.attributs[rollData.attrKey].labelnorm + ".webp"
rollData.carac = duplicate(actor.system.caracteristiques[rollData.caracKey])

View File

@ -1,7 +1,7 @@
{
"id": "fvtt-les-heritiers",
"description": "Les Héritiers pour FoundryVTT",
"version": "10.0.26",
"version": "10.0.29",
"authors": [
{
"name": "Uberwald/LeRatierBretonnien",
@ -19,7 +19,7 @@
"gridUnits": "m",
"license": "LICENSE.txt",
"manifest": "https://www.uberwald.me/gitea/public/fvtt-les-heritiers/raw/branch/master/system.json",
"download": "https://www.uberwald.me/gitea/public/fvtt-les-heritiers/archive/fvtt-les-heritiers-10.0.26.zip",
"download": "https://www.uberwald.me/gitea/public/fvtt-les-heritiers/archive/fvtt-les-heritiers-10.0.29.zip",
"languages": [
{
"lang": "fr",

View File

@ -2,7 +2,7 @@
"Actor": {
"types": [
"personnage",
"creature"
"pnj"
],
"templates": {
"biodata": {
@ -145,31 +145,37 @@
"competences": {
"aventurier": {
"label": "Aventurier",
"niveau": 0,
"rang": 0,
"pp": 0
},
"combattant": {
"label": "Aventurier",
"niveau": 0,
"rang": 0,
"pp": 0
},
"erudit": {
"label": "Erudit",
"niveau": 0,
"rang": 0,
"pp": 0
},
"gentleman": {
"label": "Gentleman",
"niveau": 0,
"rang": 0,
"pp": 0
},
"roublard": {
"label": "Roublard",
"niveau": 0,
"rang": 0,
"pp": 0
},
"savant": {
"label": "Savant",
"niveau": 0,
"rang": 0,
"pp": 0
}
@ -184,6 +190,8 @@
"demasquee": 0
},
"parade": {
"masquee": 0,
"demasquee": 0,
"value": 0
},
"resistancephysique": {
@ -223,6 +231,12 @@
"biodata",
"core"
]
},
"pnj": {
"templates": [
"biodata",
"core"
]
}
},
"Item": {

View File

@ -0,0 +1,470 @@
<form class="{{cssClass}}" autocomplete="off">
{{!-- Sheet Header --}}
<header class="sheet-header">
<div class="header-fields background-sheet-header">
<div class="flexrow">
<img class="profile-img" src="{{img}}" data-edit="img" title="{{name}}" />
<div class="flexcol">
<h1 class="charname"><input name="name" type="text" value="{{name}}" placeholder="Name" /></h1>
<div class="flexrow">
<div class="flexrow">
<ul class="item-list alternate-list">
{{#each system.caracteristiques as |carac key|}}
{{#if (eq kind "physical")}}
<li class="item flexrow ">
<h4 class="item-name-label competence-name roll-style"><a class="roll-carac" data-key="{{key}}">{{carac.label}}</a></h4>
<input type="text" class="padd-right status-small-label color-class-common item-field-label-short"
name="system.caracteristiques.{{key}}.value" value="{{carac.value}}" data-dtype="Number" />
<input type="text" class="padd-right status-small-label color-class-common item-field-label-short"
name="system.caracteristiques.{{key}}.rang" value="{{carac.rang}}" data-dtype="Number" />
</li>
{{/if}}
{{/each}}
</ul>
</div>
<div class="flexrow">
<ul class="item-list alternate-list">
{{#each system.caracteristiques as |carac key|}}
{{#if (eq kind "mental")}}
<li class="item flexrow ">
<h4 class="item-name-label competence-name roll-style"><a class="roll-carac" data-key="{{key}}">{{carac.label}}</a></h4>
<input type="text" class="padd-right status-small-label color-class-common item-field-label-short"
name="system.caracteristiques.{{key}}.value" value="{{carac.value}}" data-dtype="Number" />
<input type="text" class="padd-right status-small-label color-class-common item-field-label-short"
name="system.caracteristiques.{{key}}.rang" value="{{carac.rang}}" data-dtype="Number" />
</li>
{{/if}}
{{/each}}
</ul>
</div>
</div>
<div class="flexrow">
<label class="item-field-label-short">PV</label>
<input type="text" class="item-field-label-short" name="system.pv.value" value="{{system.pv.value}}" data-dtype="Number" />
<input type="text" class="item-field-label-short" name="system.pv.max" value="{{system.pv.max}}" data-dtype="Number" />
<label class="item-field-label-short">Malus</label>
<input type="text" class="item-field-label-short" value="{{pvMalus}}" data-dtype="Number" disabled />
<span>&nbsp;&nbsp;</span>
<label class="item-field-label-short">Tricherie</label>
<input type="text" class="item-field-label-short" name="system.rang.tricherie.value" value="{{system.rang.tricherie.value}}" data-dtype="Number" />
<input type="text" class="item-field-label-short" name="system.rang.tricherie.max" value="{{system.rang.tricherie.max}}" data-dtype="Number" />
</div>
</div>
</div>
</header>
{{!-- Sheet Tab Navigation --}}
<nav class="sheet-tabs tabs" data-group="primary">
<a class="item" data-tab="competences">Compétences</a>
<a class="item" data-tab="atouts">Atouts&Matériel</a>
<a class="item" data-tab="combat">Combat</a>
<a class="item" data-tab="notes">Notes</a>
</nav>
{{!-- Sheet Body --}}
<section class="sheet-body">
{{!-- Competence Tab --}}
<div class="tab competences" data-group="primary" data-tab="competences">
<div class="flexcol">
<div class="grid-2col">
<div>
{{#each utileSkillsPhysical as |skillDef keyProfil|}}
{{> systems/fvtt-les-heritiers/templates/partial-utile-skills.html skillDef=skillDef keyProfil=keyProfil isPNJ=true}}
{{/each}}
</div>
<div>
{{#each utileSkillsMental as |skillDef keyProfil|}}
{{> systems/fvtt-les-heritiers/templates/partial-utile-skills.html skillDef=skillDef keyProfil=keyProfil isPNJ=true}}
{{/each}}
</div>
</div>
<div class="sheet-box color-bg-archetype">
<ul class="item-list alternate-list">
<li class="item flexrow">
<span class="item-field-label-long2">
<h3><label class="items-title-text">Compétences Futiles</label></h3>
</span>
<span class="item-field-label-short">
<label class="short-label">Niveau</label>
</span>
<div class="item-filler">&nbsp;</div>
</li>
{{#each futileSkills as |skill key|}}
<li class="item flexrow " data-item-id="{{skill._id}}" data-item-type="competence">
<span class="item-field-label-long2 roll-style"><a class="roll-competence item-field-label-short"
data-attr-key="tochoose">{{skill.name}}</a></span>
<select class="item-field-label-short edit-item-data" type="text"
data-item-field="niveau" value="{{skill.system.niveau}}" data-dtype="Number">
{{#select skill.system.niveau}}
{{> systems/fvtt-les-heritiers/templates/partial-list-niveau.html}}
{{/select}}
</select>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</div>
</div>
</div>
{{!-- Equipement Tab --}}
<div class="tab combat" data-group="primary" data-tab="combat">
<ul class="item-list alternate-list">
<li class="item flexrow">
<button class="chat-card-button roll-initiative">Initiative (actuelle : {{initiative}} )</button>
</li>
<li class="item flexrow list-item items-title-bg">
<label class="item-field-label-medium"><strong>Esquive</strong></label>
<label class="item-field-label-medium">Masquée</label>
<input type="text" class="item-field-label-short" name="system.combat.esquive.masquee" value="{{system.combat.esquive.masquee}}" data-dtype="Number" />
<label class="item-field-label-medium">Démasquée</label>
<input type="text" class="item-field-label-short" name="system.combat.esquive.demasquee" value="{{system.combat.esquive.demasquee}}" data-dtype="Number" />
<label class="item-field-label-medium"><strong>Parade</strong></label>
<label class="item-field-label-medium">Masquée</label>
<input type="text" class="item-field-label-short" name="system.combat.parade.masquee" value="{{system.combat.parade.masquee}}" data-dtype="Number" />
<label class="item-field-label-medium">Démasquée</label>
<input type="text" class="item-field-label-short" name="system.combat.parade.demasquee" value="{{system.combat.parade.demasquee}}" data-dtype="Number" />
</li>
<li class="item flexrow list-item items-title-bg">
<label class="item-field-label-long">Rés. physique</label>
<input type="text" class="item-field-label-short" name="system.combat.resistancephysique.value" value="{{system.combat.resistancephysique.value}}" data-dtype="Number" />
<label class="item-field-label-long">Rés. psychique</label>
<input type="text" class="item-field-label-short" name="system.combat.resistancepsychique.value" value="{{system.combat.resistancepsychique.value}}" data-dtype="Number" />
<label class="item-field-label-medium">Protection : </label>
<input type="text" class="item-field-label-short" name="system.combat.protection.value" value="{{system.combat.protection.value}}" data-dtype="Number" />
</li>
<li class="item flexrow list-item items-title-bg">
<label class="item-field-label-long">Effets secondaires</label>
<input type="text" class="item-field-label-short" name="system.combat.effetssecondaires" value="{{system.combat.effetssecondaires}}" data-dtype="String" />
<label class="item-field-label-long">Dissimulation : </label>
<input type="text" class="item-field-label-short" name="system.combat.dissimulation.value" value="{{system.combat.dissimulation.value}}" data-dtype="Number" />
</li>
<li class="item flexrow list-item items-title-bg">
<label class="item-field-label-long"><strong>Corps à Corps</strong></label>
<label class="item-field-label-medium">Masqué</label>
<input type="text" class="item-field-label-short" name="system.combat.corpsacorps.masquee" value="{{system.combat.corpsacorps.masquee}}" data-dtype="Number" />
<label class="item-field-label-medium">Démasqué</label>
<input type="text" class="item-field-label-short" name="system.combat.corpsacorps.demasquee" value="{{system.combat.corpsacorps.demasquee}}" data-dtype="Number" />
</li>
<li class="item flexrow list-item items-title-bg">
<label class="item-field-label-long"><strong>A distance</strong></label>
<label class="item-field-label-medium">Masqué</label>
<input type="text" class="item-field-label-short" name="system.combat.tir.masquee" value="{{system.combat.tir.masquee}}" data-dtype="Number" />
<label class="item-field-label-medium">Démasqué</label>
<input type="text" class="item-field-label-short" name="system.combat.tir.demasquee" value="{{system.combat.tir.demasquee}}" data-dtype="Number" />
</li>
</ul>
<div class="flexcol">
<div class="sheet-box color-bg-archetype">
<ul class="item-list alternate-list">
<li class="item flexrow list-item items-title-bg">
<span class="item-name-label-header">
<h3><label class="items-title-text">Armes</label></h3>
</span>
<span class="item-field-label-short">
<label class="short-label">Attaque</label>
</span>
<span class="item-field-label-short">
<label class="short-label">Dégats</label>
</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-add" data-type="arme" title="Ajouter une arme"><i
class="fas fa-plus"></i></a>
</div>
</li>
{{#each armes as |arme key|}}
<li class="item flexrow " data-item-id="{{arme._id}}" data-item-type="arme">
<img class="item-name-img" src="{{arme.img}}" />
<span class="item-name-label competence-name">{{arme.name}}</span>
<span class="item-field-label-short">
<button class="roll-attaque-arme button-sheet-roll">Attaquer</button>
</span>
<span class="item-field-label-short">
{{arme.system.degats}}
</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-equip" title="Worn">{{#if arme.system.equipped}}<i
class="fas fa-circle"></i>{{else}}<i class="fas fa-genderless"></i>{{/if}}</a>
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</div>
<div class="sheet-box color-bg-archetype">
<ul class="item-list alternate-list">
<li class="item flexrow list-item items-title-bg">
<span class="item-name-label-header">
<h3><label class="items-title-text">Protections</label></h3>
</span>
<span class="item-field-label-short">
<label class="short-label">Protection</label>
</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-add" data-type="arme" title="Ajouter une arme"><i
class="fas fa-plus"></i></a>
</div>
</li>
{{#each protections as |protection key|}}
<li class="item flexrow " data-item-id="{{protection._id}}" data-item-type="protection">
<img class="item-name-img" src="{{protection.img}}" />
<span class="item-name-label competence-name">{{protection.name}}</span>
<span class="item-field-label-short arme-defensif"><label
class="arme-defensif">{{protection.system.protection}}</label>
</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</div>
</div>
</div>
{{!-- atouts Tab --}}
<div class="tab atouts" data-group="primary" data-tab="atouts">
<div class="flexrow">
<li class="item flexrow " data-item-id="{{fee._id}}" data-item-type="avantage">
<img class="item-name-img" src="{{fee.img}}" />
<span class="item-field-label-long2">{{fee.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
</div>
<div class="flexrow">
<ul>
<li class="flexrow item">
<label class="item-field-label-medium roll-style"><a class="roll-rang item-field-label-short" data-rang-key="feerie">Féerie</a></label>
<input type="text" class="item-field-label-short" name="system.rang.feerie.value" value="{{system.rang.feerie.value}}" data-dtype="Number" />
<input type="text" class="item-field-label-short" name="system.rang.feerie.max" value="{{system.rang.feerie.max}}" data-dtype="Number" />
<span class="item-field-label-long"></span>
<label class="item-field-label-medium roll-style"><a class="roll-rang item-field-label-short" data-rang-key="masque">Masque</a></label>
<input type="text" class="item-field-label-short" name="system.rang.masque.value" value="{{system.rang.masque.value}}" data-dtype="Number" />
<input type="text" class="item-field-label-short" name="system.rang.masque.max" value="{{system.rang.masque.max}}" data-dtype="Number" />
</li>
</ul>
</div>
<div class="flexcol">
<div class="sheet-box color-bg-archetype">
<ul class="item-list alternate-list">
<li class="item flexrow list-item items-title-bg">
<span class="item-name-label-header">
<h3><label class="items-title-text">Avantages</label></h3>
</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
</div>
</li>
{{#each avantages as |avantage key|}}
<li class="item flexrow " data-item-id="{{avantage._id}}" data-item-type="avantage">
<img class="item-name-img" src="{{avantage.img}}" />
<span class="item-field-label-long2">{{avantage.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</div>
<div class="sheet-box color-bg-archetype">
<ul class="item-list alternate-list">
<li class="item flexrow list-item items-title-bg">
<span class="item-name-label-header">
<h3><label class="items-title-text">Désavantages</label></h3>
</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
</div>
</li>
{{#each desavantages as |desavantage key|}}
<li class="item flexrow " data-item-id="{{desavantage._id}}" data-item-type="desavantage">
<img class="item-name-img" src="{{desavantage.img}}" />
<span class="item-field-label-long2">{{desavantage.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</div>
<div class="sheet-box color-bg-archetype">
<ul class="item-list alternate-list">
<li class="item flexrow list-item items-title-bg">
<span class="item-name-label-header">
<h3><label class="items-title-text">Atouts Féériques</label></h3>
</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
</div>
</li>
{{#each atouts as |atout key|}}
<li class="item flexrow " data-item-id="{{atout._id}}" data-item-type="atout">
<img class="item-name-img" src="{{atout.img}}" />
<span class="item-field-label-long2">{{atout.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</div>
<div class="sheet-box color-bg-archetype">
<ul class="item-list alternate-list">
<li class="item flexrow list-item items-title-bg">
<span class="item-name-label-header item-field-label-long2-img">
<h3><label class="items-title-text">Pouvoirs</label></h3>
</span>
<span class="item-field-label-medium">
<label class="short-label">Masque</label>
</span>
<span class="item-field-label-medium">
<label class="short-label">Type</label>
</span>
<span class="item-field-label-medium">
<label class="short-label">Niveau</label>
</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
</div>
</li>
{{#each pouvoirs as |pouvoir key|}}
<li class="item flexrow " data-item-id="{{pouvoir._id}}" data-item-type="pouvoir">
<img class="item-name-img" src="{{pouvoir.img}}" />
{{#if pouvoir.system.istest}}
<span class="item-field-label-long2 roll-style"><a class="roll-pouvoir">{{pouvoir.name}}</a></span>
{{else}}
<span class="item-field-label-long2">{{pouvoir.name}}</span>
{{/if}}
<span class="item-field-label-medium">{{upperFirst pouvoir.system.masquetype}}</span>
<span class="item-field-label-medium">{{upperFirst pouvoir.system.pouvoirtype}}</span>
<span class="item-field-label-medium">{{upperFirst pouvoir.system.niveau}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</div>
<div class="sheet-box color-bg-archetype">
<ul class="item-list alternate-list">
<li class="item flexrow list-item items-title-bg">
<span class="item-name-label-header">
<h3><label class="items-title-text">Capacités Naturelles</label></h3>
</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
</div>
</li>
{{#each capacites as |capa key|}}
<li class="item flexrow " data-item-id="{{capa._id}}" data-item-type="capacite">
<img class="item-name-img" src="{{capa.img}}" />
<span class="item-field-label-long2">{{capa.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</div>
<div class="sheet-box color-bg-archetype">
<ul class="item-list alternate-list">
<li class="item flexrow list-item items-title-bg">
<span class="item-name-label-header">
<h3><label class="items-title-text">Equipements</label></h3>
</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-add" data-type="equipement" title="Créer un équipement"><i class="fas fa-plus"></i></a>
</div>
</li>
{{#each equipements as |equip key|}}
<li class="item flexrow " data-item-id="{{equip._id}}" data-item-type="equipement">
<img class="item-name-img" src="{{equip.img}}" />
<span class="item-field-label-long2">{{equip.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</div>
</div>
</div>
<div class="tab notes" data-group="primary" data-tab="notes">
<span>
<h3>Historique</h3>
</span>
<div class="medium-editor item-text-long-line">
{{editor description target="system.biodata.description" button=true owner=owner editable=editable}}
</div>
</div>
</section>
</form>

View File

@ -81,14 +81,14 @@
<div class="grid-2col">
<div>
{{#each utileSkillsPhysical as |skillList keyProfil|}}
{{> systems/fvtt-les-heritiers/templates/partial-utile-skills.html skillList=skillList keyProfil=keyProfil}}
{{#each utileSkillsPhysical as |skillDef keyProfil|}}
{{> systems/fvtt-les-heritiers/templates/partial-utile-skills.html skillDef=skillDef keyProfil=keyProfil}}
{{/each}}
</div>
<div>
{{#each utileSkillsMental as |skillList keyProfil|}}
{{> systems/fvtt-les-heritiers/templates/partial-utile-skills.html skillList=skillList keyProfil=keyProfil}}
{{#each utileSkillsMental as |skillDef keyProfil|}}
{{> systems/fvtt-les-heritiers/templates/partial-utile-skills.html skillDef=skillDef keyProfil=keyProfil}}
{{/each}}
</div>
@ -144,7 +144,10 @@
<label class="item-field-label-medium">Démasquée</label>
<input type="text" class="item-field-label-short" name="system.combat.esquive.demasquee" value="{{system.combat.esquive.demasquee}}" data-dtype="Number" />
<label class="item-field-label-medium"><strong>Parade</strong></label>
<input type="text" class="item-field-label-short" name="system.combat.parade.value" value="{{system.combat.parade.value}}" data-dtype="Number" />
<label class="item-field-label-medium">Masquée</label>
<input type="text" class="item-field-label-short" name="system.combat.parade.masquee" value="{{system.combat.parade.masquee}}" data-dtype="Number" />
<label class="item-field-label-medium">Démasquée</label>
<input type="text" class="item-field-label-short" name="system.combat.parade.demasquee" value="{{system.combat.parade.demasquee}}" data-dtype="Number" />
</li>
<li class="item flexrow list-item items-title-bg">
<label class="item-field-label-long">Rés. physique</label>

View File

@ -1,15 +1,29 @@
<div class="sheet-box color-bg-archetype">
<ul class="item-list alternate-list">
<li class="item flexrow">
<span class="item-field-label-long">
<h3><label class="items-title-text">{{upperFirst keyProfil}}</label></h3>
{{#if isPNJ}}
<span class="item-field-label-long roll-style">
<a class="roll-root-competence item-field-label-short" data-attr-key="{{keyProfil}}">
<h3><label class="items-title-text">{{upperFirst keyProfil}}</label></h3>
</a>
</span>
{{else}}
<span class="item-field-label-long">
<h3><label class="items-title-text">{{upperFirst keyProfil}}</label></h3>
</span>
{{/if}}
<span class="item-field-label-short">
<label class="short-label">Niveau</label>
</span>
{{#if isPNJ}}
<span class="item-field-label-short">
<input type="text" data-dtype="Number" class="item-field-label-short" name="system.competences.{{keyProfil}}.niveau" value="{{skillDef.niveau}}">
</span>
{{/if}}
<div class="item-filler">&nbsp;</div>
</li>
{{#each skillList as |skill key|}}
{{#each skillDef.skills as |skill key|}}
<li class="item flexrow " data-item-id="{{skill._id}}" data-item-type="competence">
<span class="item-field-label-long roll-style"><a class="roll-competence item-field-label-short"
data-attr-key="tochoose">{{skill.name}}</a></span>