Various fixes

This commit is contained in:
2023-03-11 12:11:27 +01:00
parent 02f8207fb7
commit f26cd7670c
11 changed files with 111 additions and 71 deletions

View File

@@ -14,8 +14,8 @@ export class HeritiersActorSheet extends ActorSheet {
return mergeObject(super.defaultOptions, {
classes: ["fvtt-les-heritiers", "sheet", "actor"],
template: "systems/fvtt-les-heritiers/templates/actor-sheet.html",
width: 640,
height: 720,
width: 780,
height: 840,
tabs: [{ navSelector: ".sheet-tabs", contentSelector: ".sheet-body", initial: "stats" }],
dragDrop: [{ dragSelector: ".item-list .item", dropSelector: null }],
editScore: false
@@ -38,7 +38,8 @@ export class HeritiersActorSheet extends ActorSheet {
effects: this.object.effects.map(e => foundry.utils.deepClone(e.data)),
limited: this.object.limited,
skills: this.actor.getSkills(),
utileSkills :this.actor.organizeUtileSkills(),
utileSkillsMental :this.actor.organizeUtileSkills("mental"),
utileSkillsPhysical :this.actor.organizeUtileSkills("physical"),
futileSkills :this.actor.organizeFutileSkills(),
contacts: this.actor.organizeContacts(),
armes: duplicate(this.actor.getWeapons()),
@@ -136,6 +137,10 @@ export class HeritiersActorSheet extends ActorSheet {
const key = $(event.currentTarget).data("key")
this.actor.rollCarac(key, false)
})
html.find('.roll-rang').click((event) => {
const key = $(event.currentTarget).data("rang-key")
this.actor.rollRang(key, false)
})
html.find('.roll-competence').click((event) => {
const li = $(event.currentTarget).parents(".item")
let compId = li.data("item-id")