Ajout multiples pour le combat et ameliorations des items
This commit is contained in:
parent
10b7fcac09
commit
629d369693
BIN
images/icons/blessure.webp
Normal file
BIN
images/icons/blessure.webp
Normal file
Binary file not shown.
After Width: | Height: | Size: 56 KiB |
BIN
images/icons/maladie.webp
Normal file
BIN
images/icons/maladie.webp
Normal file
Binary file not shown.
After Width: | Height: | Size: 69 KiB |
BIN
images/icons/simple.webp
Normal file
BIN
images/icons/simple.webp
Normal file
Binary file not shown.
After Width: | Height: | Size: 61 KiB |
BIN
images/ui/femme_gauche.webp
Normal file
BIN
images/ui/femme_gauche.webp
Normal file
Binary file not shown.
After Width: | Height: | Size: 160 KiB |
BIN
images/ui/homme_droit.webp
Normal file
BIN
images/ui/homme_droit.webp
Normal file
Binary file not shown.
After Width: | Height: | Size: 288 KiB |
@ -11,7 +11,10 @@
|
||||
"armure": "Armure",
|
||||
"grace": "Grace",
|
||||
"origine": "Origine",
|
||||
"education": "Education"
|
||||
"education": "Education",
|
||||
"blessure": "Blessure",
|
||||
"maladie": "Maladie",
|
||||
"simple": "Simple"
|
||||
}
|
||||
}
|
||||
}
|
@ -11,7 +11,7 @@ export class TeDeumActorPJSheet extends ActorSheet {
|
||||
/** @override */
|
||||
static get defaultOptions() {
|
||||
|
||||
return mergeObject(super.defaultOptions, {
|
||||
return foundry.utils.mergeObject(super.defaultOptions, {
|
||||
classes: ["fvtt-te-deum", "sheet", "actor"],
|
||||
template: "systems/fvtt-te-deum/templates/actors/actor-sheet.hbs",
|
||||
width: 860,
|
||||
@ -33,10 +33,10 @@ export class TeDeumActorPJSheet extends ActorSheet {
|
||||
name: this.actor.name,
|
||||
editable: this.isEditable,
|
||||
cssClass: this.isEditable ? "editable" : "locked",
|
||||
system: duplicate(this.object.system),
|
||||
system: foundry.utils.duplicate(this.object.system),
|
||||
limited: this.object.limited,
|
||||
competences: this.actor.getCompetences(),
|
||||
config: duplicate(game.system.tedeum.config),
|
||||
config: foundry.utils.duplicate(game.system.tedeum.config),
|
||||
armes: this.actor.getArmes(),
|
||||
caracList: this.actor.prepareCaracteristiques(),
|
||||
providence: this.actor.prepareProvidence(),
|
||||
@ -44,6 +44,11 @@ export class TeDeumActorPJSheet extends ActorSheet {
|
||||
equipements: this.actor.getEquipements(),
|
||||
armures: this.actor.getArmures(),
|
||||
graces: this.actor.getGraces(),
|
||||
blessures: this.actor.getBlessures(),
|
||||
maladies: this.actor.getMaladies(),
|
||||
poisons: this.actor.getPoisons(),
|
||||
combat: this.actor.prepareCombat(),
|
||||
santeModifier: this.actor.getSanteModifier(),
|
||||
description: await TextEditor.enrichHTML(this.object.system.description, { async: true }),
|
||||
notes: await TextEditor.enrichHTML(this.object.system.notes, { async: true }),
|
||||
options: this.options,
|
||||
|
@ -89,48 +89,91 @@ export class TeDeumActor extends Actor {
|
||||
|
||||
/* -------------------------------------------- */
|
||||
getCompetences() {
|
||||
let comp = duplicate(this.items.filter(item => item.type == 'competence') || [])
|
||||
let comp = foundry.utils.duplicate(this.items.filter(item => item.type == 'competence') || [])
|
||||
return comp;
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
getGraces() {
|
||||
let comp = duplicate(this.items.filter(item => item.type == 'grace') || [])
|
||||
let comp = foundry.utils.duplicate(this.items.filter(item => item.type == 'grace') || [])
|
||||
TeDeumUtility.sortArrayObjectsByName(comp)
|
||||
return comp;
|
||||
}
|
||||
getArmes() {
|
||||
let comp = duplicate(this.items.filter(item => item.type == 'arme') || [])
|
||||
let comp = foundry.utils.duplicate(this.items.filter(item => item.type == 'arme') || [])
|
||||
TeDeumUtility.sortArrayObjectsByName(comp)
|
||||
return comp;
|
||||
}
|
||||
getEquipements() {
|
||||
let comp = duplicate(this.items.filter(item => item.type == 'equipement') || [])
|
||||
let comp = foundry.utils.duplicate(this.items.filter(item => item.type == 'equipement') || [])
|
||||
TeDeumUtility.sortArrayObjectsByName(comp)
|
||||
return comp;
|
||||
}
|
||||
getArmures() {
|
||||
let comp = duplicate(this.items.filter(item => item.type == 'armure') || [])
|
||||
let comp = foundry.utils.duplicate(this.items.filter(item => item.type == 'armure') || [])
|
||||
TeDeumUtility.sortArrayObjectsByName(comp)
|
||||
return comp;
|
||||
}
|
||||
getBlessures() {
|
||||
let comp = foundry.utils.duplicate(this.items.filter(item => item.type == 'blessure') || [])
|
||||
for (let c of comp) {
|
||||
let blessDef = game.system.tedeum.config.blessures[c.system.typeBlessure]
|
||||
c.malus = blessDef.modifier
|
||||
}
|
||||
TeDeumUtility.sortArrayObjectsByName(comp)
|
||||
return comp;
|
||||
}
|
||||
getMaladies() {
|
||||
let comp = foundry.utils.duplicate(this.items.filter(item => item.type == 'maladie') || [])
|
||||
for (let c of comp) {
|
||||
c.malus = "N/A"
|
||||
if (c.system.appliquee) {
|
||||
let malDef = game.system.tedeum.config.virulence[c.system.virulence]
|
||||
c.malus = malDef.modifier
|
||||
}
|
||||
}
|
||||
TeDeumUtility.sortArrayObjectsByName(comp)
|
||||
return comp;
|
||||
}
|
||||
getPoisons() {
|
||||
let comp = foundry.utils.duplicate(this.items.filter(item => item.type == 'poison') || [])
|
||||
for (let c of comp) {
|
||||
c.malus = "N/A"
|
||||
if (c.system.appliquee) {
|
||||
let poisDef = game.system.tedeum.config.virulencePoison[c.system.virulence]
|
||||
c.malus = poisDef.modifier
|
||||
}
|
||||
}
|
||||
TeDeumUtility.sortArrayObjectsByName(comp)
|
||||
return comp;
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
calculMalusBlessures() {
|
||||
let modifierBlessures = 0
|
||||
let nbBlessures = 0
|
||||
// Cumul des malus de blessures
|
||||
for (let locKey in this.system.localisation) {
|
||||
let loc = this.system.localisation[locKey]
|
||||
let bDef = game.system.tedeum.config.blessures[loc.blessures]
|
||||
modifierBlessures += bDef.modifier
|
||||
nbBlessures += bDef.count
|
||||
getSanteModifier() {
|
||||
let comp = foundry.utils.duplicate(this.items.filter(item => item.type == 'maladie') || [])
|
||||
let modTotal = 0
|
||||
for (let c of comp) {
|
||||
if (c.system.appliquee) {
|
||||
let maladieDef = game.system.tedeum.config.virulence[c.system.virulence]
|
||||
modTotal += maladieDef.modifier
|
||||
}
|
||||
}
|
||||
let simples= foundry.utils.duplicate(this.items.filter(item => item.type == 'simple') || [])
|
||||
for (let c of simples) {
|
||||
if (c.system.appliquee) {
|
||||
let simpleDef = game.system.tedeum.config.virulencePoison[c.system.virulence]
|
||||
modTotal += simpleDef.modifier
|
||||
}
|
||||
}
|
||||
let blessures = foundry.utils.duplicate(this.items.filter(item => item.type == 'blessure') || [])
|
||||
for (let c of blessures) {
|
||||
let blessDef = game.system.tedeum.config.blessures[c.system.typeBlessure]
|
||||
modTotal += blessDef.modifier
|
||||
}
|
||||
// Si le nombre de blessures est supérieur au score d'endurance, alors malus supplémentaire
|
||||
let endurance = this.items.find(item => item.type == "competence" && item.name.toLowerCase() == "endurance")
|
||||
if ( nbBlessures > endurance.system.score) {
|
||||
modifierBlessures += -1
|
||||
if ( blessures.length > endurance.system.score) {
|
||||
modTotal += -1
|
||||
}
|
||||
return modifierBlessures
|
||||
return modTotal
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
@ -160,7 +203,26 @@ export class TeDeumActor extends Actor {
|
||||
providence.dice = game.system.tedeum.config.providence[providence.value].diceValue
|
||||
return providence
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
prepareCombat() {
|
||||
let combatLoc = foundry.utils.deepClone(this.system.localisation)
|
||||
for (let key in combatLoc) {
|
||||
combatLoc[key] = foundry.utils.mergeObject(combatLoc[key], game.system.tedeum.config.LOCALISATION[key])
|
||||
combatLoc[key].armures = []
|
||||
combatLoc[key].protectionTotal = 0
|
||||
let armures = this.getArmures()
|
||||
for (let armure of armures) {
|
||||
if (armure.system.equipe && armure.system.localisation[key].protege) {
|
||||
combatLoc[key].armures.push(armure)
|
||||
combatLoc[key].protectionTotal += armure.system.protection
|
||||
}
|
||||
}
|
||||
let endurance = this.items.find(item => item.type == "competence" && item.name.toLowerCase() == "endurance")
|
||||
combatLoc[key].endurance = endurance.system.score + game.system.tedeum.config.LOCALISATION[key].locMod
|
||||
combatLoc[key].touche = combatLoc[key].endurance + combatLoc[key].protectionTotal
|
||||
}
|
||||
return combatLoc
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
modifyProvidence(value) {
|
||||
let providence = foundry.utils.duplicate(this.system.providence)
|
||||
@ -202,7 +264,7 @@ export class TeDeumActor extends Actor {
|
||||
getItemById(id) {
|
||||
let item = this.items.find(item => item.id == id);
|
||||
if (item) {
|
||||
item = duplicate(item)
|
||||
item = foundry.utils.duplicate(item)
|
||||
}
|
||||
return item;
|
||||
}
|
||||
@ -232,7 +294,7 @@ export class TeDeumActor extends Actor {
|
||||
|
||||
/* ------------------------------------------- */
|
||||
async buildContainerTree() {
|
||||
let equipments = duplicate(this.items.filter(item => item.type == "equipment") || [])
|
||||
let equipments = foundry.utils.duplicate(this.items.filter(item => item.type == "equipment") || [])
|
||||
for (let equip1 of equipments) {
|
||||
if (equip1.system.iscontainer) {
|
||||
equip1.system.contents = []
|
||||
@ -288,10 +350,13 @@ export class TeDeumActor extends Actor {
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
getInitiativeScore(combatId, combatantId) {
|
||||
let init = Math.floor((this.system.attributs.physique.value + this.system.attributs.habilite.value) / 2)
|
||||
let subValue = new Roll("1d20").roll({ async: false })
|
||||
return init + (subValue.total / 100)
|
||||
getInitiativeScore() {
|
||||
let initiative = this.items.find(it=>it.type == "competence" && it.name.toLowerCase() == "initiative")
|
||||
if ( initiative ) {
|
||||
return initiative.system.score
|
||||
}
|
||||
ui.notifications.warn("Impossible de trouver la compétence Initiative pour l'acteur " + this.name)
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
@ -327,7 +392,7 @@ export class TeDeumActor extends Actor {
|
||||
rollData.actorId = this.id
|
||||
rollData.img = this.img
|
||||
rollData.providence = this.prepareProvidence()
|
||||
rollData.malusBlessures = this.calculMalusBlessures()
|
||||
rollData.santeModifier = this.getSanteModifier()
|
||||
|
||||
return rollData
|
||||
}
|
||||
@ -336,7 +401,7 @@ export class TeDeumActor extends Actor {
|
||||
getCommonCompetence(compId) {
|
||||
let rollData = this.getCommonRollData()
|
||||
|
||||
let competence = duplicate(this.items.find(it => it.type =="competence" && it.id == compId))
|
||||
let competence = foundry.utils.duplicate(this.items.find(it => it.type =="competence" && it.id == compId))
|
||||
|
||||
rollData.competence = competence
|
||||
let c = foundry.utils.duplicate(this.system.caracteristiques[competence.system.caracteristique])
|
||||
@ -357,15 +422,30 @@ export class TeDeumActor extends Actor {
|
||||
|
||||
|
||||
/* -------------------------------------------- */
|
||||
rollArme(armeId) {
|
||||
rollArme(armeId, compName = undefined) {
|
||||
let weapon = this.items.get(armeId)
|
||||
if (weapon) {
|
||||
weapon = duplicate(weapon)
|
||||
weapon = foundry.utils.duplicate(weapon)
|
||||
let rollData = this.getCommonRollData()
|
||||
rollData.mode = "arme"
|
||||
rollData.arme = weapon
|
||||
rollData.img = weapon.img
|
||||
rollData.title = weapon.name
|
||||
|
||||
// Setup competence + carac
|
||||
if (!compName) {
|
||||
compName = weapon.system.competence
|
||||
}
|
||||
let competence = this.items.find(item => item.type == "competence" && item.name.toLowerCase() == compName.toLowerCase())
|
||||
if ( competence) {
|
||||
rollData.competence = competence
|
||||
let c = foundry.utils.duplicate(this.system.caracteristiques[competence.system.caracteristique])
|
||||
this.updateCarac( c, competence.system.caracteristique)
|
||||
rollData.carac = c
|
||||
} else {
|
||||
ui.notifications.warn("Impossible de trouver la compétence " + compName)
|
||||
return
|
||||
}
|
||||
this.startRoll(rollData).catch("Error on startRoll")
|
||||
} else {
|
||||
ui.notifications.warn("Impossible de trouver l'arme concernée ")
|
||||
|
@ -6,11 +6,10 @@ export class TeDeumCombat extends Combat {
|
||||
/* -------------------------------------------- */
|
||||
async rollInitiative(ids, formula = undefined, messageOptions = {} ) {
|
||||
ids = typeof ids === "string" ? [ids] : ids;
|
||||
for (let cId = 0; cId < ids.length; cId++) {
|
||||
const c = this.combatants.get(ids[cId]);
|
||||
let id = c._id || c.id;
|
||||
let initBonus = c.actor ? c.actor.getInitiativeScore( this.id, id ) : -1;
|
||||
await this.updateEmbeddedDocuments("Combatant", [ { _id: id, initiative: initBonus } ]);
|
||||
for (let cId of ids) {
|
||||
const c = this.combatants.get(cId);
|
||||
let initBonus = c.actor ? c.actor.getInitiativeScore( this.id, cId ) : -1;
|
||||
await this.updateEmbeddedDocuments("Combatant", [ { _id: cId, initiative: initBonus } ]);
|
||||
}
|
||||
|
||||
return this;
|
||||
|
@ -13,17 +13,16 @@ export const TEDEUM_CONFIG = {
|
||||
{ value: 10 }, { value: 30 }, { value: 50 }],
|
||||
|
||||
LOCALISATION: {
|
||||
"pieddroit": { label: "Pied Droit", value: 1, id: "pieddroit", nbArmure: 1 },
|
||||
"jambedroite": { label: "Jambe Droite", value: 1, id: "jambedroite", nbArmure: 1 },
|
||||
"jambegauche": { label: "Jambe Gauche", value: 1, id: "jambegauche", nbArmure: 1 },
|
||||
"piedgauche": { label: "Pied Gauche", value: 1, id: "piedgauche", nbArmure: 1 },
|
||||
"piedgauche": { label: "Pied Gauche", value: 1, id: "piedgauche", nbArmure: 1 },
|
||||
"maindroite": { label: "Main Droite", value: 1, id: "maindroite", nbArmure: 1 },
|
||||
"maingauche": { label: "Main Gauche", value: 1, id: "maingauche", nbArmure: 1 },
|
||||
"brasdroit": { label: "Bras Droit", value: 1, id: "brasdroit", nbArmure: 2 },
|
||||
"brasgauche": { label: "Bras Gauche", value: 1, id: "brasgauche", nbArmure: 2 },
|
||||
"corps": { label: "Corps", value: 1, id: "corps", nbArmure: 2 },
|
||||
"tete": { label: "Tête", value: 1, id: "tete", nbArmure: 2 },
|
||||
"pieddroit": { label: "Pied Droit", value: 1, locMod:0, id: "pieddroit", nbArmure: 1, score: {min: 1, max:1}, coord: { top: 500, left: 0 } },
|
||||
"jambedroite": { label: "Jambe Droite", value: 1, locMod:-1,id: "jambedroite", nbArmure: 1, score: {min: 3, max:4},coord: { top: 400, left: 100 } },
|
||||
"jambegauche": { label: "Jambe Gauche", value: 1, locMod:-1,id: "jambegauche", nbArmure: 1, score: {min: 5, max:6},coord: { top: 400, left: 300 } },
|
||||
"piedgauche": { label: "Pied Gauche", value: 1, locMod:0,id: "piedgauche", nbArmure: 1, score: {min: 2, max:2},coord: { top: 500, left: 400 } },
|
||||
"maindroite": { label: "Main Droite", value: 1, locMod:0,id: "maindroite", nbArmure: 1, score: {min: 7, max:7},coord: { top: 0, left: 0 } },
|
||||
"maingauche": { label: "Main Gauche", value: 1, locMod:0,id: "maingauche", nbArmure: 1, score: {min: 8, max:8},coord: { top: 0, left: 400 } },
|
||||
"brasdroit": { label: "Bras Droit", value: 1, locMod:-1,id: "brasdroit", nbArmure: 2, score: {min: 9, max:10},coord: { top: 200, left: 0 } },
|
||||
"brasgauche": { label: "Bras Gauche", value: 1, locMod:-1,id: "brasgauche", nbArmure: 2, score: {min: 11, max:12},coord: { top: 200, left: 400 } },
|
||||
"corps": { label: "Corps", value: 1, id: "corps", locMod:-2,nbArmure: 2, score: {min: 13, max:17},coord: { top: 200, left: 200 } },
|
||||
"tete": { label: "Tête", value: 1, id: "tete", locMod:-2,nbArmure: 2 , score: {min: 18, max:20},coord: { top: 0, left: 200 }},
|
||||
},
|
||||
|
||||
ARME_SPECIFICITE: {
|
||||
@ -157,13 +156,32 @@ export const TEDEUM_CONFIG = {
|
||||
{ value: "1", label: "+1 niveau" },
|
||||
{ value: "2", label: "+2 niveaux" }
|
||||
],
|
||||
blessures: [
|
||||
{ value: 0, label: "Indemne", degatsMax: -1, count: 0, modifier: 0 },
|
||||
{ value: 1, label: "Estafilade/Contusion", degatsMax: 2, count: 1, modifier: 0 },
|
||||
{ value: 2, label: "Plaie", degatsMax: 4, count: 1, modifier: -1 },
|
||||
{ value: 3, label: "Plaie béante", degatsMax: 6, count: 1, modifier: -2 },
|
||||
{ value: 4, label: "Plaie atroce", degatsMax: 6, count: 1, horsCombat: true, modifier: -12 },
|
||||
{ value: 5, label: "Tué net", degatsMax: 100, count: 1, horsCombat: true, mort: true, modifier: -12 }
|
||||
]
|
||||
|
||||
blessures: {
|
||||
indemne: { value: 0, label: "Indemne", key: "indemne", degatsMax: -1, count: 0, modifier: 0 },
|
||||
estafilade: { value: 1, label: "Estafilade", key: "estafilade", degatsMax: 2, count: 1, modifier: 0 },
|
||||
plaie: { value: 2, label: "Plaie", key: "plaie", degatsMax: 4, count: 1, modifier: -1 },
|
||||
plaiebeante: { value: 3, label: "Plaie béante", key: "plaiebeante", degatsMax: 6, count: 1, modifier: -2 },
|
||||
plaieatroce: { value: 4, label: "Plaie atroce", key: "plaieatroce", degatsMax: 6, count: 1, horsCombat: true, modifier: -12 },
|
||||
tunenet: { value: 5, label: "Tué net", key: "tuenet", degatsMax: 100, count: 1, horsCombat: true, mort: true, modifier: -12 }
|
||||
},
|
||||
virulence: {
|
||||
fatigue: { label: "Fatigue", value: "fatigue", modifier: 0 },
|
||||
epuisement: { label: "Epuisement", value: "epuisement",modifier: -1 },
|
||||
souffrance: { label: "Souffrance", value: "souffrance", modifier: -2 },
|
||||
agonie: { label: "Agonie", value: "agonie", modifier: -3 }
|
||||
},
|
||||
fievre: {
|
||||
aucune: { label: "Aucune", value: "aucune" },
|
||||
legere: { label: "Légère", value: "legere" },
|
||||
forte: { label: "Forte", value: "forte" },
|
||||
grave: { label: "Grave", value: "grave" }
|
||||
},
|
||||
virulencePoison: {
|
||||
aucune: { label: "Aucune", value: "nausee", modifier: 0 },
|
||||
nausee: { label: "Nausées & Vertiges", value: "nausee", modifier:0 },
|
||||
inflammation: { label: "Inflammations & Vomissements", value: "inflammation", modifier: -1 },
|
||||
elancement: { label: "Elancements & Hémorragies", value: "elancement" , modifier: -2 },
|
||||
convulsion: { label: "Convulsions & Délire hallucinatoire", value: "convulsion", modifier: -3 },
|
||||
mort: { label: "Inconscience & Mort", value: "mort", modifier: -12 }
|
||||
}
|
||||
}
|
@ -50,6 +50,10 @@ export class TeDeumUtility {
|
||||
//console.log("getConfigLabel", configName, key)
|
||||
return game.system.tedeum.config[configName][key].label
|
||||
})
|
||||
Handlebars.registerHelper('getConfigLabelArray', function (configName, key) {
|
||||
//console.log("getConfigLabel", configName, key)
|
||||
return game.system.tedeum.config[configName][key].label
|
||||
})
|
||||
Handlebars.registerHelper('isSpecArmeType', function (key, armeType) {
|
||||
return game.system.tedeum.config.ARME_SPECIFICITE[key][armeType]
|
||||
})
|
||||
@ -360,6 +364,10 @@ export class TeDeumUtility {
|
||||
/* -------------------------------------------- */
|
||||
static modifyDice(dice, bonusMalus) {
|
||||
let newIndex = game.system.tedeum.config.diceValeur.indexOf(dice) + Number(bonusMalus)
|
||||
if (newIndex < 0) {
|
||||
ui.notifications.error("Vos blessures ou maladies vous empêchent de réaliser cette action, vous êtes trop faibles")
|
||||
return undefined
|
||||
}
|
||||
newIndex = Math.min(Math.max(newIndex, 0), game.system.tedeum.config.diceValeur.length - 1)
|
||||
return game.system.tedeum.config.diceValeur[newIndex]
|
||||
}
|
||||
@ -368,7 +376,8 @@ export class TeDeumUtility {
|
||||
static computeRollFormula(rollData, actor, isConfrontation = false) {
|
||||
let diceFormula = ""
|
||||
if (rollData.competence) {
|
||||
let diceBase = this.modifyDice(rollData.carac.dice, rollData.bonusMalus+rollData.malusBlessures)
|
||||
let diceBase = this.modifyDice(rollData.carac.dice, Number(rollData.bonusMalus)+rollData.santeModifier)
|
||||
if (!diceBase) return;
|
||||
diceFormula = diceBase + "x + " + rollData.competence.system.score
|
||||
}
|
||||
if (rollData.enableProvidence) {
|
||||
@ -386,8 +395,9 @@ export class TeDeumUtility {
|
||||
rollData.difficulty = 7
|
||||
}
|
||||
rollData.difficulty = game.system.tedeum.config.difficulte[rollData.difficulty].value
|
||||
|
||||
let diceFormula = this.computeRollFormula(rollData, actor)
|
||||
if (!diceFormula) return;
|
||||
console.log("RollData", rollData, diceFormula )
|
||||
|
||||
// Performs roll
|
||||
let myRoll = await new Roll(diceFormula).roll()
|
||||
@ -501,7 +511,7 @@ export class TeDeumUtility {
|
||||
/* -------------------------------------------- */
|
||||
static getBasicRollData() {
|
||||
let rollData = {
|
||||
rollId: randomID(16),
|
||||
rollId: foundry.utils.randomID(16),
|
||||
type: "roll-data",
|
||||
rollMode: game.settings.get("core", "rollMode"),
|
||||
difficulty: "pardefaut",
|
||||
@ -509,7 +519,7 @@ export class TeDeumUtility {
|
||||
isReroll : false,
|
||||
enableProvidence : false,
|
||||
malusBlessures: 0,
|
||||
config: duplicate(game.system.tedeum.config)
|
||||
config: foundry.utils.duplicate(game.system.tedeum.config)
|
||||
}
|
||||
TeDeumUtility.updateWithTarget(rollData)
|
||||
return rollData
|
||||
|
@ -49,6 +49,8 @@ export class TeDeumArmeSchema extends foundry.abstract.TypeDataModel {
|
||||
schema.prix = new fields.NumberField({ ...requiredDouble, initial: 0, min: 0 });
|
||||
schema.monnaie = new fields.StringField({ required: true, blank: false, initial: "denier" });
|
||||
|
||||
schema.equipe = new fields.BooleanField({initial: false}),
|
||||
|
||||
schema.description = new fields.HTMLField({ required: true, blank: true });
|
||||
|
||||
return schema;
|
||||
|
@ -20,6 +20,8 @@ export class TeDeumArmureSchema extends foundry.abstract.TypeDataModel {
|
||||
schema.prix = new fields.NumberField({ ...requiredDouble, initial: 0, min: 0 });
|
||||
schema.monnaie = new fields.StringField({ required: true, blank: false, initial: "denier" });
|
||||
|
||||
schema.equipe = new fields.BooleanField({initial: false}),
|
||||
|
||||
schema.description = new fields.HTMLField({ required: true, blank: true });
|
||||
|
||||
return schema;
|
||||
|
14
modules/data/tedeum-schema-blessure.js
Normal file
14
modules/data/tedeum-schema-blessure.js
Normal file
@ -0,0 +1,14 @@
|
||||
export class TeDeumBlessureSchema extends foundry.abstract.TypeDataModel {
|
||||
static defineSchema() {
|
||||
const fields = foundry.data.fields;
|
||||
const requiredInteger = { required: true, nullable: false, integer: true };
|
||||
const schema = {};
|
||||
|
||||
schema.typeBlessure = new fields.StringField({required: true, choices: ["indemne", "estafilade", "plaie", "plaiebeante", "plaieatroce", "tuenet"], initial: "estafilade"});
|
||||
schema.localisation = new fields.StringField({required: true, choices: ["piedgauche", "pieddroit", "jambegauche", "jambedroite", "maingauche", "maindroite", "brasgauche", "brasdroit", "tete", "corps"], initial: "corps"});
|
||||
|
||||
schema.description = new fields.HTMLField({ required: true, blank: true });
|
||||
|
||||
return schema;
|
||||
}
|
||||
}
|
18
modules/data/tedeum-schema-maladie.js
Normal file
18
modules/data/tedeum-schema-maladie.js
Normal file
@ -0,0 +1,18 @@
|
||||
export class TeDeumMaladieSchema extends foundry.abstract.TypeDataModel {
|
||||
static defineSchema() {
|
||||
const fields = foundry.data.fields;
|
||||
const requiredInteger = { required: true, nullable: false, integer: true };
|
||||
const schema = {};
|
||||
|
||||
schema.transmission = new fields.HTMLField({ required: true, blank: true });
|
||||
schema.difficulteEndurance = new fields.StringField({required:true, initial:"routine"});
|
||||
schema.virulence = new fields.StringField({required: true, choices: ["fatigue", "epuisement", "souffrance", "agonie"], initial: "fatigue"});
|
||||
schema.fievre = new fields.StringField({required: true, choices: ["aucune", "legere", "forte", "grave"], initial: "aucune"});
|
||||
schema.symptomes = new fields.HTMLField({ required: true, blank: true });
|
||||
schema.appliquee = new fields.BooleanField({initial: false}),
|
||||
|
||||
schema.description = new fields.HTMLField({ required: true, blank: true });
|
||||
|
||||
return schema;
|
||||
}
|
||||
}
|
@ -24,6 +24,8 @@ export class TeDeumPJSchema extends foundry.abstract.TypeDataModel {
|
||||
schema.localisation = new fields.SchemaField(
|
||||
Object.values(game.system.tedeum.config.LOCALISATION).reduce((obj, loc) => {
|
||||
obj[loc.id] = new fields.SchemaField({
|
||||
armure: new fields.NumberField({ ...requiredInteger, initial: 0, min: 0, max: 20 }),
|
||||
touche: new fields.NumberField({ ...requiredInteger, initial: 0, min: 0, max: 20 }),
|
||||
blessures: new fields.NumberField({ ...requiredInteger, initial: 0, min: 0, max: 20 })
|
||||
});
|
||||
return obj;
|
||||
|
20
modules/data/tedeum-schema-simple.js
Normal file
20
modules/data/tedeum-schema-simple.js
Normal file
@ -0,0 +1,20 @@
|
||||
export class TeDeumMaladieSchema extends foundry.abstract.TypeDataModel {
|
||||
static defineSchema() {
|
||||
const fields = foundry.data.fields;
|
||||
const requiredInteger = { required: true, nullable: false, integer: true };
|
||||
const schema = {};
|
||||
|
||||
schema.difficulteEndurance = new fields.StringField({required:true, initial:"routine"});
|
||||
schema.virulence = new fields.StringField({required: true, choices: ["aucune", "nausee", "inflammation", "elancement", "convulsion", "mort"], initial: "fatigue"});
|
||||
schema.vertus = new fields.HTMLField({ required: true, blank: true });
|
||||
schema.toxicite = new fields.HTMLField({ required: true, blank: true });
|
||||
schema.appliquee = new fields.BooleanField({initial: false}),
|
||||
|
||||
schema.prix = new fields.NumberField({ ...requiredDouble, initial: 0, min: 0 });
|
||||
schema.monnaie = new fields.StringField({ required: true, blank: false, initial: "denier" });
|
||||
|
||||
schema.description = new fields.HTMLField({ required: true, blank: true });
|
||||
|
||||
return schema;
|
||||
}
|
||||
}
|
@ -8,7 +8,7 @@ export class TeDeumItemSheet extends ItemSheet {
|
||||
|
||||
/** @override */
|
||||
static get defaultOptions() {
|
||||
return mergeObject(super.defaultOptions, {
|
||||
return foundry.utils.mergeObject(super.defaultOptions, {
|
||||
classes: ["fvtt-te-deum", "sheet", "item"],
|
||||
template: "systems/fvtt-te-deum/templates/item-sheet.hbs",
|
||||
dragDrop: [{ dragSelector: null, dropSelector: null }],
|
||||
|
@ -7,6 +7,9 @@ export const defaultItemImg = {
|
||||
competence: "systems/fvtt-te-deum/images/icons/competence.webp",
|
||||
education: "systems/fvtt-te-deum/images/icons/education.webp",
|
||||
grace: "systems/fvtt-te-deum/images/icons/grace.webp",
|
||||
blessure: "systems/fvtt-te-deum/images/icons/blessure.webp",
|
||||
maladie: "systems/fvtt-te-deum/images/icons/maladie.webp",
|
||||
simple: "systems/fvtt-te-deum/images/icons/simple.webp",
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -19,6 +19,8 @@ import { TeDeumEquipementSchema } from "./data/tedeum-schema-equipement.js";
|
||||
import { TeDeumOrigineSchema } from "./data/tedeum-schema-origine.js";
|
||||
import { TeDeumEducationSchema } from "./data/tedeum-schema-education.js";
|
||||
import { TeDeumGraceSchema } from "./data/tedeum-schema-grace.js";
|
||||
import { TeDeumBlessureSchema } from "./data/tedeum-schema-blessure.js";
|
||||
import { TeDeumMaladieSchema } from "./data/tedeum-schema-maladie.js";
|
||||
|
||||
import { TeDeumItem } from "./items/tedeum-item.js";
|
||||
import { TeDeumItemSheet } from "./items/tedeum-item-sheet.js";
|
||||
@ -71,7 +73,9 @@ Hooks.once("init", async function () {
|
||||
armure: TeDeumArmureSchema,
|
||||
origine: TeDeumOrigineSchema,
|
||||
education: TeDeumEducationSchema,
|
||||
grace: TeDeumGraceSchema
|
||||
grace: TeDeumGraceSchema,
|
||||
blessure: TeDeumBlessureSchema,
|
||||
maladie: TeDeumMaladieSchema,
|
||||
};
|
||||
|
||||
console.log("TeDeum RPG | Ready");
|
||||
|
Binary file not shown.
BIN
packs/competences/000121.ldb
Normal file
BIN
packs/competences/000121.ldb
Normal file
Binary file not shown.
@ -1 +1 @@
|
||||
MANIFEST-000105
|
||||
MANIFEST-000146
|
||||
|
@ -1,8 +1,8 @@
|
||||
2024/06/06-16:27:16.818495 7fcfb2a006c0 Recovering log #103
|
||||
2024/06/06-16:27:16.829929 7fcfb2a006c0 Delete type=3 #101
|
||||
2024/06/06-16:27:16.830004 7fcfb2a006c0 Delete type=0 #103
|
||||
2024/06/06-17:16:48.801172 7fcfb16006c0 Level-0 table #108: started
|
||||
2024/06/06-17:16:48.801212 7fcfb16006c0 Level-0 table #108: 0 bytes OK
|
||||
2024/06/06-17:16:48.838666 7fcfb16006c0 Delete type=0 #106
|
||||
2024/06/06-17:16:48.894707 7fcfb16006c0 Manual compaction at level-0 from '!folders!4OPhigzcPv46qbWW' @ 72057594037927935 : 1 .. '!items!zwC0H39ar5Pl1l92' @ 0 : 0; will stop at (end)
|
||||
2024/06/06-17:16:48.894760 7fcfb16006c0 Manual compaction at level-1 from '!folders!4OPhigzcPv46qbWW' @ 72057594037927935 : 1 .. '!items!zwC0H39ar5Pl1l92' @ 0 : 0; will stop at (end)
|
||||
2024/07/07-21:34:33.552483 7fdbf4c006c0 Recovering log #144
|
||||
2024/07/07-21:34:33.562583 7fdbf4c006c0 Delete type=3 #142
|
||||
2024/07/07-21:34:33.562681 7fdbf4c006c0 Delete type=0 #144
|
||||
2024/07/08-07:54:26.000826 7fdbefe006c0 Level-0 table #149: started
|
||||
2024/07/08-07:54:26.000937 7fdbefe006c0 Level-0 table #149: 0 bytes OK
|
||||
2024/07/08-07:54:26.043881 7fdbefe006c0 Delete type=0 #147
|
||||
2024/07/08-07:54:26.179609 7fdbefe006c0 Manual compaction at level-0 from '!folders!4OPhigzcPv46qbWW' @ 72057594037927935 : 1 .. '!items!zwC0H39ar5Pl1l92' @ 0 : 0; will stop at (end)
|
||||
2024/07/08-07:54:26.179705 7fdbefe006c0 Manual compaction at level-1 from '!folders!4OPhigzcPv46qbWW' @ 72057594037927935 : 1 .. '!items!zwC0H39ar5Pl1l92' @ 0 : 0; will stop at (end)
|
||||
|
@ -1,8 +1,8 @@
|
||||
2024/06/05-23:00:55.185946 7f1e64e006c0 Recovering log #99
|
||||
2024/06/05-23:00:55.196553 7f1e64e006c0 Delete type=3 #97
|
||||
2024/06/05-23:00:55.196655 7f1e64e006c0 Delete type=0 #99
|
||||
2024/06/05-23:35:36.332443 7f1e5da006c0 Level-0 table #104: started
|
||||
2024/06/05-23:35:36.332474 7f1e5da006c0 Level-0 table #104: 0 bytes OK
|
||||
2024/06/05-23:35:36.338443 7f1e5da006c0 Delete type=0 #102
|
||||
2024/06/05-23:35:36.338563 7f1e5da006c0 Manual compaction at level-0 from '!folders!4OPhigzcPv46qbWW' @ 72057594037927935 : 1 .. '!items!zwC0H39ar5Pl1l92' @ 0 : 0; will stop at (end)
|
||||
2024/06/05-23:35:36.338586 7f1e5da006c0 Manual compaction at level-1 from '!folders!4OPhigzcPv46qbWW' @ 72057594037927935 : 1 .. '!items!zwC0H39ar5Pl1l92' @ 0 : 0; will stop at (end)
|
||||
2024/07/07-13:46:28.434141 7fdbf6a006c0 Recovering log #140
|
||||
2024/07/07-13:46:28.444184 7fdbf6a006c0 Delete type=3 #138
|
||||
2024/07/07-13:46:28.444239 7fdbf6a006c0 Delete type=0 #140
|
||||
2024/07/07-16:48:21.944701 7fdbefe006c0 Level-0 table #145: started
|
||||
2024/07/07-16:48:21.944735 7fdbefe006c0 Level-0 table #145: 0 bytes OK
|
||||
2024/07/07-16:48:21.951284 7fdbefe006c0 Delete type=0 #143
|
||||
2024/07/07-16:48:21.964341 7fdbefe006c0 Manual compaction at level-0 from '!folders!4OPhigzcPv46qbWW' @ 72057594037927935 : 1 .. '!items!zwC0H39ar5Pl1l92' @ 0 : 0; will stop at (end)
|
||||
2024/07/07-16:48:21.975753 7fdbefe006c0 Manual compaction at level-1 from '!folders!4OPhigzcPv46qbWW' @ 72057594037927935 : 1 .. '!items!zwC0H39ar5Pl1l92' @ 0 : 0; will stop at (end)
|
||||
|
Binary file not shown.
BIN
packs/competences/MANIFEST-000146
Normal file
BIN
packs/competences/MANIFEST-000146
Normal file
Binary file not shown.
@ -1 +1 @@
|
||||
MANIFEST-000166
|
||||
MANIFEST-000206
|
||||
|
@ -1,7 +1,7 @@
|
||||
2024/06/06-16:27:16.805501 7fcfb8e006c0 Recovering log #164
|
||||
2024/06/06-16:27:16.816044 7fcfb8e006c0 Delete type=3 #162
|
||||
2024/06/06-16:27:16.816128 7fcfb8e006c0 Delete type=0 #164
|
||||
2024/06/06-17:16:48.641100 7fcfb16006c0 Level-0 table #169: started
|
||||
2024/06/06-17:16:48.641163 7fcfb16006c0 Level-0 table #169: 0 bytes OK
|
||||
2024/06/06-17:16:48.684021 7fcfb16006c0 Delete type=0 #167
|
||||
2024/06/06-17:16:48.684347 7fcfb16006c0 Manual compaction at level-0 from 'undefined' @ 72057594037927935 : 1 .. 'undefined' @ 0 : 0; will stop at (end)
|
||||
2024/07/07-21:34:33.538979 7fdbf60006c0 Recovering log #204
|
||||
2024/07/07-21:34:33.549574 7fdbf60006c0 Delete type=3 #202
|
||||
2024/07/07-21:34:33.549666 7fdbf60006c0 Delete type=0 #204
|
||||
2024/07/08-07:54:26.137628 7fdbefe006c0 Level-0 table #209: started
|
||||
2024/07/08-07:54:26.137703 7fdbefe006c0 Level-0 table #209: 0 bytes OK
|
||||
2024/07/08-07:54:26.179305 7fdbefe006c0 Delete type=0 #207
|
||||
2024/07/08-07:54:26.179685 7fdbefe006c0 Manual compaction at level-0 from 'undefined' @ 72057594037927935 : 1 .. 'undefined' @ 0 : 0; will stop at (end)
|
||||
|
@ -1,7 +1,7 @@
|
||||
2024/06/05-23:00:55.173863 7f1e5ea006c0 Recovering log #160
|
||||
2024/06/05-23:00:55.183501 7f1e5ea006c0 Delete type=3 #158
|
||||
2024/06/05-23:00:55.183581 7f1e5ea006c0 Delete type=0 #160
|
||||
2024/06/05-23:35:36.305356 7f1e5da006c0 Level-0 table #165: started
|
||||
2024/06/05-23:35:36.305385 7f1e5da006c0 Level-0 table #165: 0 bytes OK
|
||||
2024/06/05-23:35:36.311763 7f1e5da006c0 Delete type=0 #163
|
||||
2024/06/05-23:35:36.321710 7f1e5da006c0 Manual compaction at level-0 from 'undefined' @ 72057594037927935 : 1 .. 'undefined' @ 0 : 0; will stop at (end)
|
||||
2024/07/07-13:46:28.422245 7fdbf56006c0 Recovering log #200
|
||||
2024/07/07-13:46:28.431962 7fdbf56006c0 Delete type=3 #198
|
||||
2024/07/07-13:46:28.432013 7fdbf56006c0 Delete type=0 #200
|
||||
2024/07/07-16:48:21.951406 7fdbefe006c0 Level-0 table #205: started
|
||||
2024/07/07-16:48:21.951432 7fdbefe006c0 Level-0 table #205: 0 bytes OK
|
||||
2024/07/07-16:48:21.957697 7fdbefe006c0 Delete type=0 #203
|
||||
2024/07/07-16:48:21.964354 7fdbefe006c0 Manual compaction at level-0 from 'undefined' @ 72057594037927935 : 1 .. 'undefined' @ 0 : 0; will stop at (end)
|
||||
|
Binary file not shown.
BIN
packs/equipment/MANIFEST-000206
Normal file
BIN
packs/equipment/MANIFEST-000206
Normal file
Binary file not shown.
@ -493,7 +493,7 @@ ul, li {
|
||||
flex: 1 1 5rem;
|
||||
}
|
||||
.list-item-shadow {
|
||||
background: rgba(87, 60, 32, 0.35);
|
||||
background: rgba(170, 168, 167, 0.35);
|
||||
flex-grow: 0;
|
||||
flex-wrap: nowrap;
|
||||
justify-content: flex-start;
|
||||
@ -1205,3 +1205,34 @@ ul, li {
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
.corps-combat-block {
|
||||
position: relative;
|
||||
width: 600px;
|
||||
height: 600px;
|
||||
}
|
||||
.silhouette-combat-picture {
|
||||
width: 250px;
|
||||
max-width: 250px;
|
||||
border: 0;
|
||||
}
|
||||
.silhouette-combat-block {
|
||||
position: absolute;
|
||||
background: white;
|
||||
border-color: darkgray;
|
||||
border-style: ridge;
|
||||
border: 1;
|
||||
width: 180px;
|
||||
height: 84px;
|
||||
margin: 0 auto;
|
||||
font-size: 0.8rem;
|
||||
align-self: center;
|
||||
}
|
||||
.silhouette-combat-space {
|
||||
width: 60px;
|
||||
min-width: 60px;
|
||||
}
|
||||
.center-content {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
@ -455,7 +455,7 @@ ul, li {
|
||||
flex: 1 1 5rem;
|
||||
}
|
||||
.list-item-shadow {
|
||||
background: rgba(87, 60, 32, 0.35);
|
||||
background: rgba(170, 168, 167, 0.35);
|
||||
flex-grow: 0;
|
||||
flex-wrap: nowrap;
|
||||
justify-content: flex-start;
|
||||
@ -1133,3 +1133,34 @@ ul, li {
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
.corps-combat-block {
|
||||
position: relative;
|
||||
width: 600px;
|
||||
height: 600px;
|
||||
}
|
||||
.silhouette-combat-picture {
|
||||
width: 250px;
|
||||
max-width: 250px;
|
||||
border: 0;
|
||||
}
|
||||
.silhouette-combat-block {
|
||||
position: absolute;
|
||||
background: white;
|
||||
border-color: darkgray;
|
||||
border-style: ridge;
|
||||
border: 1;
|
||||
width: 180px;
|
||||
height: 84px;
|
||||
margin: 0 auto;
|
||||
font-size: 0.8rem;
|
||||
align-self: center;
|
||||
}
|
||||
.silhouette-combat-space {
|
||||
width: 60px;
|
||||
min-width: 60px;
|
||||
}
|
||||
.center-content {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
@ -6,8 +6,10 @@
|
||||
"pnj": {}
|
||||
},
|
||||
"Item": {
|
||||
"types": ["arme", "competence", "armure", "grace", "equipement", "origine", "education"],
|
||||
"htmlFields": ["description"],
|
||||
"types": ["arme", "competence", "armure", "grace", "equipement", "origine", "education", "blessure", "maladie", "simple"],
|
||||
"htmlFields": ["description", "transmission", "symptomes", "vertus", "toxicité"],
|
||||
"blessure": {},
|
||||
"maladie": {},
|
||||
"arme": {},
|
||||
"competence": {},
|
||||
"armure": {},
|
||||
|
@ -39,12 +39,14 @@
|
||||
|
||||
<div class="grid grid-2col">
|
||||
|
||||
<div>
|
||||
<ul class="item-list alternate-list">
|
||||
{{#each caracList as |char key|}}
|
||||
<li class="item flexrow list-item carac-box">
|
||||
<img class="sheet-competence-img" src="/systems/fvtt-te-deum/images/icons/{{key}}.webp" />
|
||||
<label class="item-left-pad item-field item-field-label-medium">{{char.name}}</label>
|
||||
<select type="text" class="input-numeric-short" name="system.caracteristiques.{{key}}.value"data-dtype="Number" />
|
||||
<select type="text" class="input-numeric-short" name="system.caracteristiques.{{key}}.value"
|
||||
data-dtype="Number" />
|
||||
{{selectOptions @root.config.descriptionValeur selected=char.value labelAttr="valeur"}}
|
||||
</select>
|
||||
<label class="item-field item-field-label-medium">{{char.qualite}}</label>
|
||||
@ -53,12 +55,95 @@
|
||||
{{/each}}
|
||||
</ul>
|
||||
|
||||
<div>
|
||||
<h4>Malus de santé : {{santeModifier}} niveaux</h4>
|
||||
</div>
|
||||
|
||||
<ul class="item-list alternate-list">
|
||||
<li class="item flexrow list-item items-title-bg">
|
||||
<span class="item-field-title-long">
|
||||
<h3><label class="item-field-label-long">Blessures</label></h3>
|
||||
</span>
|
||||
</li>
|
||||
{{#each blessures as |blessure key|}}
|
||||
<li class="item flexrow list-item list-item-shadow item-id" data-item-id="{{blessure._id}}">
|
||||
<a class="item-edit item-name-img" title="Editer Item"><img class="sheet-competence-img"
|
||||
src="{{blessure.img}}" /></a>
|
||||
<span class="item-field-label-medium">
|
||||
{{blessure.name}}
|
||||
</span>
|
||||
<span class="item-field-label-short">
|
||||
{{getConfigLabel "blessures" blessure.system.typeBlessure}}
|
||||
</span>
|
||||
<span class="item-field-label-short">
|
||||
{{getConfigLabel "LOCALISATION" blessure.system.localisation}}
|
||||
</span>
|
||||
<span class="item-field-label-short">
|
||||
{{blessure.malus}}
|
||||
</span>
|
||||
<div class="item-filler"> </div>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
<a class="item-control item-edit" title="Editer"><i class="fas fa-edit"></i></a>
|
||||
<a class="item-control item-delete" title="Supprimer l'arme"><i class="fas fa-trash"></i></a>
|
||||
</div>
|
||||
</li>
|
||||
{{/each}}
|
||||
</ul>
|
||||
|
||||
{{#if (or (count maladies) (count poisons))}}
|
||||
<ul class="item-list alternate-list">
|
||||
<li class="item flexrow list-item items-title-bg">
|
||||
<span class="item-field-title-long">
|
||||
<h3><label class="item-field-label-long">Maladies & Poisons</label></h3>
|
||||
</span>
|
||||
</li>
|
||||
{{#each maladies as |maladie key|}}
|
||||
<li class="item flexrow list-item list-item-shadow item-id" data-item-id="{{maladie._id}}">
|
||||
<a class="item-edit item-name-img" title="Editer Item"><img class="sheet-competence-img"
|
||||
src="{{maladie.img}}" /></a>
|
||||
<span class="item-field-label-medium">
|
||||
{{maladie.name}}
|
||||
</span>
|
||||
<span class="item-field-label-short">
|
||||
{{maladie.malus}}
|
||||
</span>
|
||||
<div class="item-filler"> </div>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
<a class="item-control item-edit" title="Editer"><i class="fas fa-edit"></i></a>
|
||||
<a class="item-control item-delete" title="Supprimer l'arme"><i class="fas fa-trash"></i></a>
|
||||
</div>
|
||||
</li>
|
||||
{{/each}}
|
||||
{{#each poisons as |poison key|}}
|
||||
<li class="item flexrow list-item list-item-shadow item-id" data-item-id="{{poison._id}}">
|
||||
<a class="item-edit item-name-img" title="Editer Item"><img class="sheet-competence-img"
|
||||
src="{{poison.img}}" /></a>
|
||||
<span class="item-field-label-medium">
|
||||
{{poison.name}}
|
||||
</span>
|
||||
<span class="item-field-label-short">
|
||||
{{poison.malus}}
|
||||
</span>
|
||||
<div class="item-filler"> </div>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
<a class="item-control item-edit" title="Editer"><i class="fas fa-edit"></i></a>
|
||||
<a class="item-control item-delete" title="Supprimer l'arme"><i class="fas fa-trash"></i></a>
|
||||
</div>
|
||||
</li>
|
||||
{{/each}}
|
||||
|
||||
</ul>
|
||||
{{/if}}
|
||||
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<ul class="item-list alternate-list">
|
||||
<li class="item flexrow list-item carac-box">
|
||||
<label class="item-left-pad item-field item-field-label-medium">Providence</label>
|
||||
<select type="text" class="input-numeric-short" name="system.providence.value" data-dtype="Number" />
|
||||
{{selectOptions @root.config.providence selected=providence.value nameAttr="value" valueAttr="value" labelAttr="value"}}
|
||||
{{selectOptions @root.config.providence selected=providence.value nameAttr="value" valueAttr="value"
|
||||
labelAttr="value"}}
|
||||
</select>
|
||||
<label class="item-field item-field-label-long">{{providence.qualite}}</label>
|
||||
<label class="item-field item-field-label-short">{{providence.dice}}</label>
|
||||
@ -151,7 +236,7 @@
|
||||
<a class="item-edit item-name-img" title="Edit Item"><img class="sheet-competence-img"
|
||||
src="{{arme.img}}" /></a>
|
||||
<span class="item-field-label-long">
|
||||
<a class="roll-arme">
|
||||
<a class="roll-arme" data-arme-id="{{arme._id}}">
|
||||
{{arme.name}}
|
||||
</a>
|
||||
</span>
|
||||
@ -191,6 +276,28 @@
|
||||
{{/each}}
|
||||
</ul>
|
||||
|
||||
<div class="center-content">
|
||||
<div class="corps-combat-block flexrow">
|
||||
<img src="/systems/fvtt-te-deum/images/ui/femme_gauche.webp" class="silhouette-combat-picture" />
|
||||
<div class="silhouette-combat-space"></div>
|
||||
<img src="/systems/fvtt-te-deum/images/ui/homme_droit.webp" class="silhouette-combat-picture" />
|
||||
|
||||
{{#each combat as |loc key|}}
|
||||
<div class="silhouette-combat-block" style="top:{{loc.coord.top}}px;left:{{loc.coord.left}}px;">
|
||||
<h4 class="center">{{loc.score.min}}-{{loc.score.max}}. {{loc.label}}</h4>
|
||||
<div class="flexcol">
|
||||
{{#each loc.armures as |armure idx| }}
|
||||
<span>{{armure.name}} ({{armure.system.protection}})</span>
|
||||
{{/each}}
|
||||
<span>Touché : {{touche}}</span>
|
||||
<span>Blessures : {{blessuresTete}}</span>
|
||||
</div>
|
||||
</div>
|
||||
{{/each}}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
@ -214,7 +321,8 @@
|
||||
</span>
|
||||
<div class="item-filler"> </div>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
<a class="item-control item-add" data-type="equipment" title="Créer un équipement"><i class="fas fa-plus"></i></a>
|
||||
<a class="item-control item-add" data-type="equipment" title="Créer un équipement"><i
|
||||
class="fas fa-plus"></i></a>
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
@ -27,6 +27,9 @@
|
||||
{{#if bonusMalus}}
|
||||
<li>Bonus/Malus: {{bonusMalus}} </li>
|
||||
{{/if}}
|
||||
{{#if santeModifier}}
|
||||
<li>Santé: {{santeModifier}} niveaux</li>
|
||||
{{/if}}
|
||||
{{#if enableProvidence}}
|
||||
<li>Un niveau de Providence a été utilisé !</li>
|
||||
{{/if}}
|
||||
|
@ -19,10 +19,10 @@
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{#if malusBlessures}}
|
||||
{{#if santeModifier}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Malus Blessures </span>
|
||||
<span class="roll-dialog-label">{{malusBlessures}} niveaux</span>
|
||||
<span class="roll-dialog-label">{{santeModifier}} niveaux</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
|
@ -85,6 +85,12 @@
|
||||
{{/each}}
|
||||
|
||||
<h3>Autres</h3>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Equipé?</label>
|
||||
<input type="checkbox" name="system.equipe" {{checked system.equipe}} />
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Bonus d'Initiative</label>
|
||||
<input type="text" class="padd-right numeric-input item-field-label-short"
|
||||
|
@ -32,6 +32,11 @@
|
||||
name="system.protection" value="{{system.protection}}" data-dtype="Number" />
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Equipé?</label>
|
||||
<input type="checkbox" name="system.equipe" {{checked system.equipe}} />
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Prix</label>
|
||||
<input type="text" class="padd-right numeric-input item-field-label-short"
|
||||
|
38
templates/items/item-blessure-sheet.hbs
Normal file
38
templates/items/item-blessure-sheet.hbs
Normal file
@ -0,0 +1,38 @@
|
||||
<form class="{{cssClass}}" autocomplete="off">
|
||||
<header class="sheet-header">
|
||||
<img class="item-sheet-img" src="{{img}}" data-edit="img" title="{{name}}" />
|
||||
<div class="header-fields">
|
||||
<h1 class="charname"><input name="name" type="text" value="{{name}}" placeholder="Name" /></h1>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
{{> systems/fvtt-te-deum/templates/items/partial-item-nav.hbs}}
|
||||
|
||||
|
||||
{{!-- Sheet Body --}}
|
||||
<section class="sheet-body">
|
||||
|
||||
{{> systems/fvtt-te-deum/templates/items/partial-item-description.hbs}}
|
||||
|
||||
<div class="tab details" data-group="primary" data-tab="details">
|
||||
|
||||
<ul>
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Type de Blessure</label>
|
||||
<select name="system.typeBlessure">
|
||||
{{selectOptions config.blessures selected=system.typeBlessure valueAttr="key" nameAttr="key" labelAttr="label"}}
|
||||
</select>
|
||||
</li>
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Localisation</label>
|
||||
<select name="system.localisation">
|
||||
{{selectOptions config.LOCALISATION selected=system.localisation valueAttr="id" nameAttr="id" labelAttr="label"}}
|
||||
</select>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</section>
|
||||
</form>
|
59
templates/items/item-maladie-sheet.hbs
Normal file
59
templates/items/item-maladie-sheet.hbs
Normal file
@ -0,0 +1,59 @@
|
||||
<form class="{{cssClass}}" autocomplete="off">
|
||||
<header class="sheet-header">
|
||||
<img class="item-sheet-img" src="{{img}}" data-edit="img" title="{{name}}" />
|
||||
<div class="header-fields">
|
||||
<h1 class="charname"><input name="name" type="text" value="{{name}}" placeholder="Name" /></h1>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
{{> systems/fvtt-te-deum/templates/items/partial-item-nav.hbs}}
|
||||
|
||||
|
||||
{{!-- Sheet Body --}}
|
||||
<section class="sheet-body">
|
||||
|
||||
{{> systems/fvtt-te-deum/templates/items/partial-item-description.hbs}}
|
||||
|
||||
<div class="tab details" data-group="primary" data-tab="details">
|
||||
|
||||
<h4 class="item-name-label-long">Transmission</h4>
|
||||
<textarea name="system.transmission" data-dtype="String">
|
||||
{{{system.transmission}}}
|
||||
</textarea>
|
||||
|
||||
<h4 class="item-name-label-long">Symptômes</h4>
|
||||
<textarea name="system.symptomes" data-dtype="String">
|
||||
{{{system.symptomes}}}
|
||||
</textarea>
|
||||
|
||||
<ul>
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Difficulté au test d'Endurance</label>
|
||||
<select class="" type="text" name="system.difficulteEndurance" data-dtype="String">
|
||||
{{selectOptions config.difficulte selected=system.difficulteEndurance abelAttr="label"}}
|
||||
</select>
|
||||
</li>
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Virulence</label>
|
||||
<select name="system.virulence">
|
||||
{{selectOptions config.virulence selected=system.virulence labelAttr="label"}}
|
||||
</select>
|
||||
</li>
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Fièvre</label>
|
||||
<select name="system.fievre">
|
||||
{{selectOptions config.fievre selected=system.fievre labelAttr="label"}}
|
||||
</select>
|
||||
</li>
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Appliquée?</label>
|
||||
<input type="checkbox" name="system.appliquee" {{checked system.appliquee}} />
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</section>
|
||||
</form>
|
62
templates/items/item-simple-sheet.hbs
Normal file
62
templates/items/item-simple-sheet.hbs
Normal file
@ -0,0 +1,62 @@
|
||||
<form class="{{cssClass}}" autocomplete="off">
|
||||
<header class="sheet-header">
|
||||
<img class="item-sheet-img" src="{{img}}" data-edit="img" title="{{name}}" />
|
||||
<div class="header-fields">
|
||||
<h1 class="charname"><input name="name" type="text" value="{{name}}" placeholder="Name" /></h1>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
{{> systems/fvtt-te-deum/templates/items/partial-item-nav.hbs}}
|
||||
|
||||
|
||||
{{!-- Sheet Body --}}
|
||||
<section class="sheet-body">
|
||||
|
||||
{{> systems/fvtt-te-deum/templates/items/partial-item-description.hbs}}
|
||||
|
||||
<div class="tab details" data-group="primary" data-tab="details">
|
||||
|
||||
<h4 class="item-name-label-long">Vertus médicinales</h4>
|
||||
<textarea name="system.vertus" data-dtype="String">
|
||||
{{{system.vertus}}}
|
||||
</textarea>
|
||||
|
||||
<h4 class="item-name-label-long">Toxicité</h4>
|
||||
<textarea name="system.toxicite" data-dtype="String">
|
||||
{{{system.toxicite}}}
|
||||
</textarea>
|
||||
|
||||
<ul>
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Difficulté au test d'Endurance</label>
|
||||
<select class="" type="text" name="system.difficulteEndurance" data-dtype="String">
|
||||
{{selectOptions config.difficulte selected=system.difficulteEndurance abelAttr="label"}}
|
||||
</select>
|
||||
</li>
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Virulence</label>
|
||||
<select name="system.virulence">
|
||||
{{selectOptions config.virulencePoison selected=system.virulence labelAttr="label"}}
|
||||
</select>
|
||||
</li>
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Appliquée?</label>
|
||||
<input type="checkbox" name="system.appliquee" {{checked system.appliquee}} />
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-name-label-long">Valeur moyenne</label>
|
||||
<input type="text" class="padd-right numeric-input item-field-label-short"
|
||||
name="system.prix" value="{{system.prix}}" data-dtype="Number" />
|
||||
<select name="system.monnaie">
|
||||
{{selectOptions config.monnaie selected=system.monnaie labelAttr="label" blank="denier"}}
|
||||
</select>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</section>
|
||||
</form>
|
Loading…
x
Reference in New Issue
Block a user