Compare commits

...

29 Commits

Author SHA1 Message Date
cfe8bee1c2 Merge brnch 2022-08-27 19:16:27 +02:00
d4f0cce62b Sync system.json 2022-08-27 19:14:15 +02:00
8c0fbf15b6 Merge VK features 2022-08-27 19:12:44 +02:00
d4fddf8600 Merge pull request 'Arbre de conteneurs et recherche améliorée' (#546) from VincentVk/foundryvtt-reve-de-dragon:v1.5 into v1.5
Reviewed-on: #546
2022-08-27 19:11:56 +02:00
Vincent Vandemeulebrouck
4b1862fa48 Arborescence de conteneurs
Les conteneurs sont maintenant précédés d'une icone:
* pour ouvrir:  '+'
* pour fermer: '-'
* si vide: carré vide
2022-08-26 22:23:09 +02:00
Vincent Vandemeulebrouck
82115ed8d7 Amélioration recherche
La recherche de compétence fonctionne sur timer
2022-08-26 22:23:08 +02:00
59b4f62145 Merge1 2022-07-23 18:36:03 +02:00
3359492f13 v0.5 fixes 2022-07-23 18:34:17 +02:00
676e6739a6 Merge pull request 'Fix import' (#545) from VincentVk/foundryvtt-reve-de-dragon:v1.5 into v1.5
Reviewed-on: #545
2022-07-23 18:33:32 +02:00
Vincent Vandemeulebrouck
872d3fff31 Fix import 2022-07-23 16:48:49 +02:00
5f3361ecc6 Merge v1.5 2022-07-22 22:53:48 +02:00
9c71827baa Add Blurette 2022-07-22 22:45:41 +02:00
fc9ef06e7b Merge pull request 'Support des blurettes' (#544) from VincentVk/foundryvtt-reve-de-dragon:v1.5 into v1.5
Reviewed-on: #544
2022-07-22 22:44:49 +02:00
Vincent Vandemeulebrouck
9e63706de6 Support des blurettes
On peut définir Blurette comme type d'entité.
Pas de jet poour s'accorder aux blurettes.
2022-07-22 21:38:20 +02:00
3958b1bdc2 Add Vincent VK fixes 2022-07-22 10:46:39 +02:00
6d6843223b Merge pull request 'Petits fixes et petits conforts' (#543) from VincentVk/foundryvtt-reve-de-dragon:v1.5 into v1.5
Reviewed-on: #543
2022-07-22 10:45:44 +02:00
Vincent Vandemeulebrouck
46f5cb67f6 Créer un acteur depuis /nom 2022-07-22 01:34:15 +02:00
Vincent Vandemeulebrouck
d51243d74f Fix Bouton "prendre"
Le bouton devenait "Acheter" car le prix après la première prise était
récupéré sous forme de string (et le template fait une comparaison de
nombre)
2022-07-22 01:01:46 +02:00
Vincent Vandemeulebrouck
34cc671f12 Fix init Autre action 2022-07-22 00:36:16 +02:00
Vincent Vandemeulebrouck
16ce6a58dd Fix accorder entite de cauchemar
A priori vieille régression, pas vue depuis.

attaquant._id est devenu attaquant.id
2022-07-22 00:31:27 +02:00
c80cde6d18 Merge v1.5 2022-07-17 11:51:23 +02:00
89910e234d Add Vincent fixes 2022-07-17 11:05:28 +02:00
f30df47d22 Merge pull request 'v1.5' (#542) from VincentVk/foundryvtt-reve-de-dragon:v1.5 into v1.5
Reviewed-on: #542
2022-07-17 11:04:20 +02:00
Vincent Vandemeulebrouck
c3c42bdb21 Fix compétences créatures
Ne pas ajouter toutes les compétences à une nouvelle créature,
il faut presque toutes les enlever
2022-07-17 01:54:01 +02:00
Vincent Vandemeulebrouck
14eb655382 Fix Haubert d'Oniros - rituel 2022-07-17 01:53:02 +02:00
Vincent Vandemeulebrouck
52e4375972 Fix affichage description des entités 2022-07-16 23:38:03 +02:00
15e4bfb713 Fix combat.js 2022-07-14 22:32:57 +02:00
8c2d49652c v10 branch - Update manifest 2022-07-13 08:04:48 +02:00
ed02972a34 v10 branch - Update manifest 2022-07-13 08:03:45 +02:00
15 changed files with 376 additions and 514 deletions

View File

@@ -37,6 +37,7 @@ export class RdDActorSheet extends ActorSheet {
/* -------------------------------------------- */ /* -------------------------------------------- */
async getData() { async getData() {
const objectData = this.object.system const objectData = this.object.system
this.timerRecherche = undefined;
console.log("New actor", objectData) console.log("New actor", objectData)
let formData = { let formData = {
@@ -76,8 +77,8 @@ export class RdDActorSheet extends ActorSheet {
}; };
formData.competences.forEach(item => { formData.competences.forEach(item => {
item.system.visible = this.options.cherchercompetence item.visible = this.options.recherche
? RdDItemCompetence.nomContientTexte(item, this.options.cherchercompetence) ? RdDItemCompetence.nomContientTexte(item, this.options.recherche.text)
: (!this.options.showCompNiveauBase || !RdDItemCompetence.isNiveauBase(item)); : (!this.options.showCompNiveauBase || !RdDItemCompetence.isNiveauBase(item));
RdDItemCompetence.levelUp(item, formData.data.compteurs.experience.value); RdDItemCompetence.levelUp(item, formData.data.compteurs.experience.value);
}); });
@@ -422,12 +423,28 @@ export class RdDActorSheet extends ActorSheet {
this.options.editCaracComp = !this.options.editCaracComp; this.options.editCaracComp = !this.options.editCaracComp;
this.render(true); this.render(true);
}); });
html.find('.cherchercompetence').change(async event => {
this.options.cherchercompetence = event.currentTarget.value; html.find('.recherche')
this.render(true); .each((index, field) => {
}); if (this.options.recherche) {
field.focus();
field.setSelectionRange(this.options.recherche.start, this.options.recherche.end);
}
})
.keyup(async event => {
this.options.recherche = this._optionRecherche(event.currentTarget)
if (this.timerRecherche) {
clearTimeout(this.timerRecherche);
}
this.timerRecherche = setTimeout(() => {
this.timerRecherche = undefined;
this.render(true);
}, 500);
})
.change(async event =>
this.options.recherche = this._optionRecherche(event.currentTarget)
);
html.find('.vue-detaillee').click(async event => { html.find('.vue-detaillee').click(async event => {
console.log("CONTROLS", this.options.vueDetaillee)
this.options.vueDetaillee = !this.options.vueDetaillee; this.options.vueDetaillee = !this.options.vueDetaillee;
this.render(true); this.render(true);
}); });
@@ -513,6 +530,17 @@ export class RdDActorSheet extends ActorSheet {
}); });
} }
_optionRecherche(target) {
if (!target.value?.length){
return undefined;
}
return {
text: target.value,
start: target.selectionStart,
end: target.selectionEnd,
};
}
_getEventArmeCombat(event) { _getEventArmeCombat(event) {
const li = $(event.currentTarget)?.parents(".item"); const li = $(event.currentTarget)?.parents(".item");
let armeName = li.data("arme-name"); let armeName = li.data("arme-name");

View File

@@ -33,7 +33,8 @@ import { RollDataAjustements } from "./rolldata-ajustements.js";
import { DialogItemAchat } from "./dialog-item-achat.js"; import { DialogItemAchat } from "./dialog-item-achat.js";
import { RdDItem } from "./item.js"; import { RdDItem } from "./item.js";
import { RdDPossession } from "./rdd-possession.js"; import { RdDPossession } from "./rdd-possession.js";
import { SYSTEM_RDD, SYSTEM_SOCKET_ID } from "./constants.js"; import { ENTITE_BLURETTE, ENTITE_INCARNE, ENTITE_NONINCARNE, SYSTEM_RDD, SYSTEM_SOCKET_ID } from "./constants.js";
/* -------------------------------------------- */ /* -------------------------------------------- */
/** /**
@@ -98,7 +99,6 @@ export class RdDActor extends Actor {
* @param {Object} options (Unused) Additional options which customize the creation workflow. * @param {Object} options (Unused) Additional options which customize the creation workflow.
* *
*/ */
static async create(actorData, options) { static async create(actorData, options) {
// Case of compendium global import // Case of compendium global import
if (actorData instanceof Array) { if (actorData instanceof Array) {
@@ -115,12 +115,15 @@ export class RdDActor extends Actor {
return actor; return actor;
} }
const competences = await RdDUtility.loadCompendium(RdDItemCompetence.actorCompendium(actorData.type))
actorData.items = competences.map(i => i.toObject())
if (isPersonnage) { if (isPersonnage) {
const competences = await RdDUtility.loadCompendium(RdDItemCompetence.actorCompendium(actorData.type));
actorData.items = competences.map(i => i.toObject());
actorData.items = actorData.items.concat(Monnaie.monnaiesData()); actorData.items = actorData.items.concat(Monnaie.monnaiesData());
} }
return super.create(actorData, options) else {
actorData.items = [];
}
return super.create(actorData, options);
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
@@ -131,13 +134,6 @@ export class RdDActor extends Actor {
this.encTotal = 0; this.encTotal = 0;
this.prixTotalEquipement = 0; this.prixTotalEquipement = 0;
/*
// Auto-resize token
if (this.isToken) {
let tokenSize = actorData.data.carac.taille.value/10;
this.token.update({height: tokenSize, width: tokenSize } );
}*/
// Make separate methods for each Actor type (character, npc, etc.) to keep // Make separate methods for each Actor type (character, npc, etc.) to keep
// things organized. // things organized.
if (this.type === 'personnage') this._prepareCharacterData(this) if (this.type === 'personnage') this._prepareCharacterData(this)
@@ -242,7 +238,7 @@ export class RdDActor extends Actor {
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
getForce() { getForce() {
if (this.isEntiteCauchemar()) { if (this.isEntite()) {
return Misc.toInt(this.system.carac.reve?.value); return Misc.toInt(this.system.carac.reve?.value);
} }
return Misc.toInt(this.system.carac.force?.value); return Misc.toInt(this.system.carac.force?.value);
@@ -320,7 +316,7 @@ export class RdDActor extends Actor {
return this.filterItemsData(it => it.type == type); return this.filterItemsData(it => it.type == type);
} }
filterItemsData(filter) { filterItemsData(filter) {
return this.items.map( it => it).filter(filter) return this.items.map(it => it).filter(filter)
} }
filterItems(filter) { filterItems(filter) {
return this.items.filter(it => filter(it)) return this.items.filter(it => filter(it))
@@ -372,11 +368,11 @@ export class RdDActor extends Actor {
getDraconicOuPossession() { getDraconicOuPossession() {
const possessions = this.items.filter(it => it.type == 'competencecreature' && it.system.ispossession) const possessions = this.items.filter(it => it.type == 'competencecreature' && it.system.ispossession)
.sort(Misc.descending(it => it.system.niveau)); .sort(Misc.descending(it => it.system.niveau));
if (possessions.length>0) { if (possessions.length > 0) {
return duplicate(possessions[0]); return duplicate(possessions[0]);
} }
const draconics = this.getDraconicList().filter(it => it.system.niveau >= 0); const draconics = this.getDraconicList().filter(it => it.system.niveau >= 0);
if (draconics.length> 0) { if (draconics.length > 0) {
return duplicate(draconics[0]); return duplicate(draconics[0]);
} }
return { return {
@@ -613,7 +609,11 @@ export class RdDActor extends Actor {
whisper: ChatUtility.getWhisperRecipientsAndGMs(this.name), whisper: ChatUtility.getWhisperRecipientsAndGMs(this.name),
content: "Remise à neuf de " + this.name content: "Remise à neuf de " + this.name
}; };
if (this.isEntiteCauchemar()) { const actorData = Misc.data(this);
if (this.isEntite([ENTITE_NONINCARNE])) {
return;
}
if (this.isEntite([ENTITE_INCARNE, ENTITE_BLURETTE])) {
await this.santeIncDec("endurance", this.system.sante.endurance.max - this.system.sante.endurance.value); await this.santeIncDec("endurance", this.system.sante.endurance.max - this.system.sante.endurance.value);
} }
else { else {
@@ -828,7 +828,7 @@ export class RdDActor extends Actor {
async resultCombatReveDeDragon(rollData) { async resultCombatReveDeDragon(rollData) {
rollData.queues = []; rollData.queues = [];
if (rollData.rolled.isEchec) { if (rollData.rolled.isEchec) {
rollData.queues.push( await this.ajouterQueue()); rollData.queues.push(await this.ajouterQueue());
} }
if (rollData.rolled.isETotal) { if (rollData.rolled.isETotal) {
rollData.queues.push(await this.ajouterQueue()); rollData.queues.push(await this.ajouterQueue());
@@ -978,7 +978,7 @@ export class RdDActor extends Actor {
let nouveauNiveau = compValue ?? RdDItemCompetence.getNiveauBase(competence.system.categorie); let nouveauNiveau = compValue ?? RdDItemCompetence.getNiveauBase(competence.system.categorie);
const tronc = RdDItemCompetence.getListTronc(competence.name).filter(it => { const tronc = RdDItemCompetence.getListTronc(competence.name).filter(it => {
const comp = this.getCompetence(it); const comp = this.getCompetence(it);
const niveauTr = competence? competence.system.niveau : 0; const niveauTr = competence ? competence.system.niveau : 0;
return niveauTr < 0 && niveauTr < nouveauNiveau; return niveauTr < 0 && niveauTr < nouveauNiveau;
}); });
if (tronc.length > 0) { if (tronc.length > 0) {
@@ -1307,17 +1307,17 @@ export class RdDActor extends Actor {
} }
return Math.min(0, this.getEncombrementMax() - Math.ceil(Number(this.getEncTotal()))); return Math.min(0, this.getEncombrementMax() - Math.ceil(Number(this.getEncTotal())));
} }
getMessageSurEncombrement(){ getMessageSurEncombrement() {
return this.computeMalusSurEncombrement() <0 ? "Sur-Encombrement!" : ""; return this.computeMalusSurEncombrement() < 0 ? "Sur-Encombrement!" : "";
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
getEncombrementMax() { getEncombrementMax() {
switch (this.type){ switch (this.type) {
case 'vehicule': case 'vehicule':
return this.system.capacite_encombrement; return this.system.capacite_encombrement;
case 'entite': case 'entite':
return 0; return 0;
default: default:
return this.system.attributs.encombrement.value return this.system.attributs.encombrement.value
} }
@@ -1339,7 +1339,7 @@ export class RdDActor extends Actor {
/* -------------------------------------------- */ /* -------------------------------------------- */
async computeEncombrementTotalEtMalusArmure() { async computeEncombrementTotalEtMalusArmure() {
if ( !this.pack ) { if (!this.pack) {
await this.computeMalusArmure(); await this.computeMalusArmure();
return this.computeEncombrement(); return this.computeEncombrement();
} }
@@ -1617,7 +1617,7 @@ export class RdDActor extends Actor {
/* -------------------------------------------- */ /* -------------------------------------------- */
async setSonne(sonne = true) { async setSonne(sonne = true) {
if (this.isEntiteCauchemar()) { if (this.isEntite()) {
return; return;
} }
if (!game.combat && sonne) { if (!game.combat && sonne) {
@@ -1629,7 +1629,7 @@ export class RdDActor extends Actor {
/* -------------------------------------------- */ /* -------------------------------------------- */
getSConst() { getSConst() {
if (this.isEntiteCauchemar()) { if (this.isEntite()) {
return 0; return 0;
} }
return RdDCarac.calculSConst(this.system.carac.constitution.value) return RdDCarac.calculSConst(this.system.carac.constitution.value)
@@ -1744,7 +1744,7 @@ export class RdDActor extends Actor {
result.newValue = Math.max(minValue, Math.min(compteur.value + inc, compteur.max)); result.newValue = Math.max(minValue, Math.min(compteur.value + inc, compteur.max));
//console.log("New value ", inc, minValue, result.newValue); //console.log("New value ", inc, minValue, result.newValue);
let fatigue = 0; let fatigue = 0;
if (name == "endurance" && !this.isEntiteCauchemar()) { if (name == "endurance" && !this.isEntite()) {
if (result.newValue == 0 && inc < 0 && !isCritique) { // perte endurance et endurance devient 0 (sauf critique) -> -1 vie if (result.newValue == 0 && inc < 0 && !isCritique) { // perte endurance et endurance devient 0 (sauf critique) -> -1 vie
sante.vie.value--; sante.vie.value--;
result.perteVie = true; result.perteVie = true;
@@ -1781,7 +1781,7 @@ export class RdDActor extends Actor {
} }
isDead() { isDead() {
return !this.isEntiteCauchemar() && this.system.sante.vie.value < -this.getSConst() return !this.isEntite() && this.system.sante.vie.value < -this.getSConst()
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
@@ -1910,7 +1910,7 @@ export class RdDActor extends Actor {
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
async actionItem(item, onActionItem = async ()=>{}) { async actionItem(item, onActionItem = async () => { }) {
if (!item.getActionPrincipale()) return; if (!item.getActionPrincipale()) return;
switch (item.type) { switch (item.type) {
case 'nourritureboisson': return await this.actionNourritureboisson(item, onActionItem); case 'nourritureboisson': return await this.actionNourritureboisson(item, onActionItem);
@@ -1918,7 +1918,7 @@ export class RdDActor extends Actor {
case 'livre': return await this.actionLire(item); case 'livre': return await this.actionLire(item);
case 'conteneur': return await item.sheet.render(true); case 'conteneur': return await item.sheet.render(true);
case 'herbe': { case 'herbe': {
if (item.isHerbeAPotion()){ if (item.isHerbeAPotion()) {
return this.dialogFabriquerPotion(item); return this.dialogFabriquerPotion(item);
} }
return; return;
@@ -2665,7 +2665,7 @@ export class RdDActor extends Actor {
selectedCarac: duplicate(this.system.carac[selected]) selectedCarac: duplicate(this.system.carac[selected])
}, },
{ overwrite: false }); { overwrite: false });
artData.competence.system.defaut_carac = selected; artData.competence.system.defaut_carac = selected;
if (!artData.forceCarac) { if (!artData.forceCarac) {
artData.forceCarac = {}; artData.forceCarac = {};
artData.forceCarac[selected] = duplicate(this.system.carac[selected]); artData.forceCarac[selected] = duplicate(this.system.carac[selected]);
@@ -3286,10 +3286,10 @@ export class RdDActor extends Actor {
if (res) { if (res) {
let malus = Misc.toInt(res[3]) - 1; let malus = Misc.toInt(res[3]) - 1;
let armure = Misc.toInt(res[2]); let armure = Misc.toInt(res[2]);
if (armure+malus <= 0){ if (armure + malus <= 0) {
itemData.system.protection = 0; itemData.system.protection = 0;
} else { } else {
itemData.system.protection = '' + (res[1]??'1') + 'd' + armure + malus; itemData.system.protection = '' + (res[1] ?? '1') + 'd' + armure + malus;
} }
} }
else if (/\d+/.exec(itemData.system.protection)) { else if (/\d+/.exec(itemData.system.protection)) {
@@ -3322,7 +3322,7 @@ export class RdDActor extends Actor {
let encaissement = await this.jetEncaissement(rollData); let encaissement = await this.jetEncaissement(rollData);
this.ajouterBlessure(encaissement); // Will upate the result table this.ajouterBlessure(encaissement); // Will upate the result table
const perteVie = this.isEntiteCauchemar() const perteVie = this.isEntite()
? { newValue: 0 } ? { newValue: 0 }
: await this.santeIncDec("vie", - encaissement.vie); : await this.santeIncDec("vie", - encaissement.vie);
const perteEndurance = await this.santeIncDec("endurance", -encaissement.endurance, encaissement.critiques > 0); const perteEndurance = await this.santeIncDec("endurance", -encaissement.endurance, encaissement.critiques > 0);
@@ -3336,7 +3336,7 @@ export class RdDActor extends Actor {
sonne: perteEndurance.sonne, sonne: perteEndurance.sonne,
jetEndurance: perteEndurance.jetEndurance, jetEndurance: perteEndurance.jetEndurance,
endurance: santeOrig.endurance.value - perteEndurance.newValue, endurance: santeOrig.endurance.value - perteEndurance.newValue,
vie: this.isEntiteCauchemar() ? 0 : (santeOrig.vie.value - perteVie.newValue), vie: this.isEntite() ? 0 : (santeOrig.vie.value - perteVie.newValue),
show: defenderRoll?.show ?? {} show: defenderRoll?.show ?? {}
}); });
@@ -3525,8 +3525,8 @@ export class RdDActor extends Actor {
/* -------------------------------------------- */ /* -------------------------------------------- */
async accorder(entite, when = 'avant-encaissement') { async accorder(entite, when = 'avant-encaissement') {
if (when != game.settings.get(SYSTEM_RDD, "accorder-entite-cauchemar") if (when != game.settings.get(SYSTEM_RDD, "accorder-entite-cauchemar")
|| !entite.isEntiteCauchemar() || !entite.isEntite([ENTITE_INCARNE])
|| entite.isEntiteCauchemarAccordee(this)) { || entite.isEntiteAccordee(this)) {
return true; return true;
} }
const tplData = this.system; const tplData = this.system;
@@ -3550,29 +3550,29 @@ export class RdDActor extends Actor {
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
isEntiteCauchemar() { isEntite(typeentite = []) {
return this.type == 'entite'; return this.type == 'entite' && (typeentite.length == 0 || typeentite.includes(this.system.typeentite));
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
isEntiteCauchemarAccordee(attaquant) { isEntiteAccordee(attaquant) {
if (!this.isEntiteCauchemar()) { return true; } if (!this.isEntite([ENTITE_INCARNE])) { return true; }
let resonnance = this.system.sante.resonnance; let resonnance = this.system.sante.resonnance;
return (resonnance.actors.find(it => it == attaquant._id)); return (resonnance.actors.find(it => it == attaquant.id));
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
async setEntiteReveAccordee(attaquant) { async setEntiteReveAccordee(attaquant) {
if (!this.isEntiteCauchemar()) { if (!this.isEntite([ENTITE_INCARNE])) {
ui.notifications.error("Impossible de s'accorder à " + this.name + ": ce n'est pas une entite de cauchemer/rêve"); ui.notifications.error("Impossible de s'accorder à " + this.name + ": ce n'est pas une entite de cauchemer/rêve");
return; return;
} }
let resonnance = duplicate(this.system.sante.resonnance); let resonnance = duplicate(this.system.sante.resonnance);
if (resonnance.actors.find(it => it == attaquant._id)) { if (resonnance.actors.find(it => it == attaquant.id)) {
// déjà accordé // déjà accordé
return; return;
} }
resonnance.actors.push(attaquant._id); resonnance.actors.push(attaquant.id);
await this.update({ "system.sante.resonnance": resonnance }); await this.update({ "system.sante.resonnance": resonnance });
return; return;
} }
@@ -3599,7 +3599,7 @@ export class RdDActor extends Actor {
10: Math.floor(fortuneTotale / 10) % 10, // bronze 10: Math.floor(fortuneTotale / 10) % 10, // bronze
1: fortuneTotale % 10 // étain 1: fortuneTotale % 10 // étain
} }
console.log('RdDActor.optimizeArgent', fortuneTotale, 'nouvelleFortune', nouvelleFortune, 'monnaie_par_valeur',parValeur); console.log('RdDActor.optimizeArgent', fortuneTotale, 'nouvelleFortune', nouvelleFortune, 'monnaie_par_valeur', parValeur);
let updates = []; let updates = [];
for (const [valeur, nombre] of Object.entries(nouvelleFortune)) { for (const [valeur, nombre] of Object.entries(nouvelleFortune)) {
updates.push({ _id: parValeur[valeur].id, 'system.quantite': nombre }); updates.push({ _id: parValeur[valeur].id, 'system.quantite': nombre });
@@ -3668,7 +3668,8 @@ export class RdDActor extends Actor {
RdDActor.remoteActorCall({ RdDActor.remoteActorCall({
userId: Misc.connectedGMOrUser(), userId: Misc.connectedGMOrUser(),
actorId: this.id, actorId: this.id,
method: 'ajouterDeniers', args: [gain, fromActorId] }); method: 'ajouterDeniers', args: [gain, fromActorId]
});
} }
else { else {
const fromActor = game.actors.get(fromActorId) const fromActor = game.actors.get(fromActorId)
@@ -3703,8 +3704,9 @@ export class RdDActor extends Actor {
RdDActor.remoteActorCall({ RdDActor.remoteActorCall({
actorId: achat.vendeurId ?? achat.acheteurId, actorId: achat.vendeurId ?? achat.acheteurId,
method: 'achatVente', method: 'achatVente',
args: [achat] }, args: [achat]
); },
);
return; return;
} }
@@ -4075,7 +4077,7 @@ export class RdDActor extends Actor {
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
async consommerPotion(potion, onActionItem = async () => {}) { async consommerPotion(potion, onActionItem = async () => { }) {
const potionData = potion const potionData = potion
if (potionData.system.categorie.includes('Soin')) { if (potionData.system.categorie.includes('Soin')) {
@@ -4111,7 +4113,7 @@ export class RdDActor extends Actor {
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
getEffectByLabel(label) { getEffectByLabel(label) {
return this.getActiveEffects().find(it => it.system?.label == label); return this.getActiveEffects().find(it => it.system?.label == label);
} }
@@ -4122,7 +4124,7 @@ export class RdDActor extends Actor {
/* -------------------------------------------- */ /* -------------------------------------------- */
async setStatusEffect(label, status, updates = {}) { async setStatusEffect(label, status, updates = {}) {
if (this.isEntiteCauchemar() || this.type == 'vehicule') { if (this.isEntite() || this.type == 'vehicule') {
return; return;
} }
console.log("setStatusEffect", label, status, updates) console.log("setStatusEffect", label, status, updates)

View File

@@ -3,3 +3,7 @@ export const SYSTEM_SOCKET_ID = 'system.foundryvtt-reve-de-dragon';
export const HIDE_DICE = 'hide'; export const HIDE_DICE = 'hide';
export const SHOW_DICE = 'show'; export const SHOW_DICE = 'show';
export const ENTITE_INCARNE = 'incarne';
export const ENTITE_NONINCARNE = 'nonincarne';
export const ENTITE_BLURETTE = 'blurette';

View File

@@ -55,7 +55,7 @@ export class DialogItemAchat extends Dialog {
static prepareVenteData(buttonAcheter, vendeurId, vendeur, acheteur) { static prepareVenteData(buttonAcheter, vendeurId, vendeur, acheteur) {
const jsondata = buttonAcheter.attributes['data-jsondata']?.value; const jsondata = buttonAcheter.attributes['data-jsondata']?.value;
const prixLot = buttonAcheter.attributes['data-prixLot']?.value ?? 0; const prixLot = parseInt(buttonAcheter.attributes['data-prixLot']?.value ?? 0);
let venteData = { let venteData = {
item: JSON.parse(jsondata), item: JSON.parse(jsondata),
vendeurId: vendeurId, vendeurId: vendeurId,

View File

@@ -1,5 +1,5 @@
import { ChatUtility } from "./chat-utility.js"; import { ChatUtility } from "./chat-utility.js";
import { HIDE_DICE, SYSTEM_RDD, SYSTEM_SOCKET_ID } from "./constants.js"; import { ENTITE_INCARNE, ENTITE_NONINCARNE, HIDE_DICE, SYSTEM_RDD, SYSTEM_SOCKET_ID } from "./constants.js";
import { Grammar } from "./grammar.js"; import { Grammar } from "./grammar.js";
import { RdDItemArme } from "./item-arme.js"; import { RdDItemArme } from "./item-arme.js";
import { RdDItemCompetence } from "./item-competence.js"; import { RdDItemCompetence } from "./item-competence.js";
@@ -85,48 +85,23 @@ export class RdDCombatManager extends Combat {
// calculate initiative // calculate initiative
for (let cId = 0; cId < ids.length; cId++) { for (let cId = 0; cId < ids.length; cId++) {
const combatant = this.combatants.get(ids[cId]); const combatant = this.combatants.get(ids[cId]);
<<<<<<< HEAD
//if (!c) return results;
let rollFormula = formula; // Init per default
if (!rollFormula) {
let armeCombat, competence;
if (combatant.actor.system.type == 'creature' || combatant.actor.system.type == 'entite') {
for (const competenceItemData of combatant.actor.items) {
if (competenceItemData.system.iscombat) {
competence = duplicate(competenceItemData);
}
}
rollFormula = "2+( (" + RdDCombatManager.calculInitiative(competence.system.niveau, competence.system.carac_value) + ")/100)";
} else {
for (const itemData of combatant.actor.items) {
if (itemData.type == "arme" && itemData.data.equipe) {
armeCombat = duplicate(itemData);
}
}
let compName = (armeCombat == undefined) ? "Corps à corps" : armeCombat.system.competence;
competence = RdDItemCompetence.findCompetence(combatant.actor.items, compName);
let bonusEcaille = (armeCombat && armeCombat.data.magique) ? armeCombat.system.ecaille_efficacite : 0;
rollFormula = "2+( (" + RdDCombatManager.calculInitiative(competence.system.niveau, combatant.actor.system.carac[competence.system.defaut_carac].value, bonusEcaille) + ")/100)";
=======
let rollFormula = formula ?? RdDCombatManager.formuleInitiative(2, 10, 0, 0); let rollFormula = formula ?? RdDCombatManager.formuleInitiative(2, 10, 0, 0);
if (!formula) { if (!formula) {
if (combatant.actor.data.type == 'creature' || combatant.actor.data.type == 'entite') { if (combatant.actor.type == 'creature' || combatant.actor.type == 'entite') {
const competence = combatant.actor.data.items.find(it => it.data.data.iscombat) const competence = combatant.actor.items.find(it => it.system.iscombat)
if (competence) { if (competence) {
rollFormula = RdDCombatManager.formuleInitiative(2, competence.data.carac_value, competence.data.niveau, 0); rollFormula = RdDCombatManager.formuleInitiative(2, competence.system.carac_value, competence.system.niveau, 0);
} }
} else { } else {
const armeCombat = combatant.actor.data.items.find(it => it.type == 'arme' && itemData.data.equipe) const armeCombat = combatant.actor.items.find(it => it.type == 'arme' && itemData.system.equipe)
const compName = (armeCombat == undefined) ? "Corps à corps" : armeCombat.data.competence; const compName = (armeCombat == undefined) ? "Corps à corps" : armeCombat.system.competence;
const competence = RdDItemCompetence.findCompetence(combatant.actor.data.items, compName); const competence = RdDItemCompetence.findCompetence(combatant.actor.items, compName);
if (competence) { if (competence) {
const carac = combatant.actor.data.data.carac[competence.data.defaut_carac].value; const carac = combatant.actor.system.carac[competence.system.defaut_carac].value;
const niveau = competence.data.niveau; const niveau = competence.system.niveau;
const bonusEcaille = (armeCombat?.data.magique) ? armeCombat.data.ecaille_efficacite : 0; const bonusEcaille = (armeCombat?.data.magique) ? armeCombat.system.ecaille_efficacite : 0;
rollFormula = RdDCombatManager.formuleInitiative(2, carac, niveau, bonusEcaille); rollFormula = RdDCombatManager.formuleInitiative(2, carac, niveau, bonusEcaille);
} }
>>>>>>> origin/v1.5
} }
} }
//console.log("Combatat", c); //console.log("Combatat", c);
@@ -180,70 +155,37 @@ export class RdDCombatManager extends Combat {
// Gestion des armes 1/2 mains // Gestion des armes 1/2 mains
let actionsArme = []; let actionsArme = [];
for (const arme of armes) { for (const arme of armes) {
<<<<<<< HEAD
let armeData = duplicate(arme)
if (armeData.system.equipe) {
let compData = competences.find(c => c.name.toLowerCase() == armeData.system.competence.toLowerCase())
armesEquipe.push(armeData)
armeData.system.dommagesReels = Number(armeData.system.dommages)
armeData.system.niveau = compData.system.niveau
armeData.system.initiative = RdDCombatManager.calculInitiative(compData.system.niveau, carac[compData.system.defaut_carac].value);
// Dupliquer les armes pouvant être à 1 main et 2 mains en patchant la compétence
if (armeData.system.unemain && !armeData.system.deuxmains) {
armeData.system.mainInfo = "(1m)";
} else if (!armeData.system.unemain && armeData.system.deuxmains) {
armeData.system.mainInfo = "(2m)";
} else if (armeData.system.unemain && armeData.system.deuxmains) {
armeData.system.mainInfo = "(1m)";
const comp2m = armeData.system.competence.replace(" 1 main", " 2 mains"); // Replace !
const comp = competences.find(c => c.name == comp2m)
const arme2main = duplicate(armeData)
arme2main.system.mainInfo = "(2m)";
arme2main.system.niveau = comp.system.niveau;
arme2main.system.competence = comp2m;
arme2main.system.initiative = RdDCombatManager.calculInitiative(arme2main.niveau, carac[comp.system.defaut_carac].value)
armesEquipe.push(arme2main);
const containsSlash = armeData.system.dommages.includes("/");
if (containsSlash) {
const tableauDegats = armeData.system.dommages.split("/");
armeData.system.dommagesReels = Number(tableauDegats[0]);
arme2main.system.dommagesReels = Number(tableauDegats[1]);
=======
let action = duplicate(Misc.data(arme)); let action = duplicate(Misc.data(arme));
if (action.data.equipe) { if (action.system.equipe) {
let compData = competences.map(c => Misc.data(c)).find(c => c.name == action.data.competence); let compData = competences.find(c => c.name == action.system.competence)
actionsArme.push(action); actionsArme.push(action);
action.action = 'attaque'; action.action = 'attaque';
action.data.dommagesReels = Number(action.data.dommages); action.system.dommagesReels = Number(action.system.dommages);
action.data.niveau = compData.data.niveau; action.system.niveau = compData.data.niveau;
action.data.initiative = RdDCombatManager.calculInitiative(compData.data.niveau, carac[compData.data.defaut_carac].value); action.system.initiative = RdDCombatManager.calculInitiative(compData.system.niveau, carac[compData.system.defaut_carac].value);
// Dupliquer les armes pouvant être à 1 main et 2 mains en patchant la compétence // Dupliquer les armes pouvant être à 1 main et 2 mains en patchant la compétence
if (action.data.unemain && !action.data.deuxmains) { if (action.system.unemain && !action.system.deuxmains) {
action.data.mainInfo = "(1m)"; action.system.mainInfo = "(1m)";
} else if (!action.data.unemain && action.data.deuxmains) { } else if (!action.system.unemain && action.system.deuxmains) {
action.data.mainInfo = "(2m)"; action.system.mainInfo = "(2m)";
} else if (action.data.unemain && action.data.deuxmains) { } else if (action.system.unemain && action.system.deuxmains) {
action.data.mainInfo = "(1m)"; action.system.mainInfo = "(1m)";
const comp2m = action.data.competence.replace(" 1 main", " 2 mains"); // Replace ! const comp2m = action.system.competence.replace(" 1 main", " 2 mains"); // Replace !
const comp = Misc.data(competences.find(c => c.name == comp2m)); const comp = competences.find(c => c.name == comp2m)
const arme2main = duplicate(action); const arme2main = duplicate(action);
arme2main.data.mainInfo = "(2m)"; arme2main.system.mainInfo = "(2m)";
arme2main.data.niveau = comp.data.niveau; arme2main.system.niveau = comp.system.niveau;
arme2main.data.competence = comp2m; arme2main.system.competence = comp2m;
arme2main.data.initiative = RdDCombatManager.calculInitiative(arme2main.data.niveau, carac[comp.data.defaut_carac].value); arme2main.system.initiative = RdDCombatManager.calculInitiative(arme2main.system.niveau, carac[comp.system.defaut_carac].value);
actionsArme.push(arme2main); actionsArme.push(arme2main);
const containsSlash = action.data.dommages.includes("/"); const containsSlash = action.system.dommages.includes("/");
if (containsSlash) { if (containsSlash) {
const tableauDegats = action.data.dommages.split("/"); const tableauDegats = action.system.dommages.split("/");
action.data.dommagesReels = Number(tableauDegats[0]); action.system.dommagesReels = Number(tableauDegats[0]);
arme2main.data.dommagesReels = Number(tableauDegats[1]); arme2main.system.dommagesReels = Number(tableauDegats[1]);
>>>>>>> origin/v1.5
} }
else{ else{
ui.notifications.info("Les dommages de l'arme à 1/2 mains " + action.name + " ne sont pas corrects (ie sous la forme X/Y)"); ui.notifications.info("Les dommages de l'arme à 1/2 mains " + action.name + " ne sont pas corrects (ie sous la forme X/Y)");
@@ -378,7 +320,7 @@ export class RdDCombatManager extends Combat {
initOffset = 10; initOffset = 10;
caracForInit = combatant.actor.getReveActuel(); caracForInit = combatant.actor.getReveActuel();
initInfo = "Possession" initInfo = "Possession"
} else if (action.name == 'autre') { } else if (action.action == 'autre') {
initOffset = 2; initOffset = 2;
initInfo = "Autre Action" initInfo = "Autre Action"
} else if (action.action == 'haut-reve') { } else if (action.action == 'haut-reve') {
@@ -513,9 +455,9 @@ export class RdDCombat {
: "Vous devez choisir une cible à attaquer!"); : "Vous devez choisir une cible à attaquer!");
} }
else { else {
const defender = target?.actor const defender = target?.actor;
const defenderTokenId = target?.id const defenderTokenId = target?.id;
if ( defender.type == 'entite' && defender.system.definition.typeentite == 'nonincarne') { if ( defender.type == 'entite' && defender.system.definition.typeentite == ENTITE_NONINCARNE) {
ui.notifications.warn("Vous ne pouvez pas cibler une entité non incarnée !!!!"); ui.notifications.warn("Vous ne pouvez pas cibler une entité non incarnée !!!!");
} else { } else {
return this.create(attacker, defender, defenderTokenId, target) return this.create(attacker, defender, defenderTokenId, target)
@@ -857,7 +799,7 @@ export class RdDCombat {
async _onAttaqueNormale(attackerRoll) { async _onAttaqueNormale(attackerRoll) {
console.log("RdDCombat.onAttaqueNormale >>>", attackerRoll); console.log("RdDCombat.onAttaqueNormale >>>", attackerRoll);
attackerRoll.dmg = RdDBonus.dmg(attackerRoll, this.attacker.getBonusDegat(), this.defender.isEntiteCauchemar()); attackerRoll.dmg = RdDBonus.dmg(attackerRoll, this.attacker.getBonusDegat(), this.defender.isEntite());
let defenderRoll = { attackerRoll: attackerRoll, passeArme: attackerRoll.passeArme, show: {} } let defenderRoll = { attackerRoll: attackerRoll, passeArme: attackerRoll.passeArme, show: {} }
attackerRoll.show = { attackerRoll.show = {
cible: this.target ? this.defender.system.name : 'la cible', cible: this.target ? this.defender.system.name : 'la cible',
@@ -1306,8 +1248,8 @@ export class RdDCombat {
async accorderEntite(when = 'avant-encaissement') { async accorderEntite(when = 'avant-encaissement') {
if (when != game.settings.get(SYSTEM_RDD, "accorder-entite-cauchemar") if (when != game.settings.get(SYSTEM_RDD, "accorder-entite-cauchemar")
|| this.defender == undefined || this.defender == undefined
|| !this.defender.isEntiteCauchemar() || !this.defender.isEntite([ENTITE_INCARNE])
|| this.defender.isEntiteCauchemarAccordee(this.attacker)) { || this.defender.isEntiteAccordee(this.attacker)) {
return true; return true;
} }

View File

@@ -1,19 +1,29 @@
import { RdDActor } from "./actor.js";
import { Misc } from "./misc.js"; import { Misc } from "./misc.js";
import { RdDDice } from "./rdd-dice.js"; import { RdDDice } from "./rdd-dice.js";
const words = [ 'pore', 'pre', 'flor', 'lane', 'turlu', 'pin', 'a', 'alph', 'i', 'onse', 'iane', 'ane', 'zach', 'arri', 'ba', 'bo', 'bi', const words = ['pore', 'pre', 'flor', 'lane', 'turlu', 'pin', 'a', 'alph', 'i', 'onse', 'iane', 'ane', 'zach', 'arri', 'ba', 'bo', 'bi',
'alta', 'par', 'pir', 'zor', 'zir', 'de', 'pol', 'tran', 'no', 'la', 'al' , 'pul', 'one', 'ner', 'nur', 'mac', 'mery', 'alta', 'par', 'pir', 'zor', 'zir', 'de', 'pol', 'tran', 'no', 'la', 'al', 'pul', 'one', 'ner', 'nur', 'mac', 'mery',
'cat', 'do', 'di', 'der', 'er', 'el', 'far', 'fer', 'go', 'guer', 'hot', 'jor', 'jar', 'ji', 'kri', 'ket', 'lor', 'hur', 'cat', 'do', 'di', 'der', 'er', 'el', 'far', 'fer', 'go', 'guer', 'hot', 'jor', 'jar', 'ji', 'kri', 'ket', 'lor', 'hur',
'lar', 'lir', 'lu', 'pot', 'pro', 'pra', 'pit', 'qua', 'qui', 're', 'ral', 'sal', 'sen', 'ted', 'to', 'ta', 'lars', 'ver', 'lar', 'lir', 'lu', 'pot', 'pro', 'pra', 'pit', 'qua', 'qui', 're', 'ral', 'sal', 'sen', 'ted', 'to', 'ta', 'lars', 'ver',
'vin', 'ov', 'wal', 'ry', 'ly', '' ]; 'vin', 'ov', 'wal', 'ry', 'ly', ''];
/* -------------------------------------------- */ /* -------------------------------------------- */
export class RdDNameGen { export class RdDNameGen {
static async getName( msg, params ) { static async getName(msg, params) {
let name = Misc.upperFirst( await RdDDice.rollOneOf(words) + await RdDDice.rollOneOf(words) ) const html = await renderTemplate(`systems/foundryvtt-reve-de-dragon/templates/chat-command-nom.html`, {
//console.log(name); nom: Misc.upperFirst(await RdDDice.rollOneOf(words) + await RdDDice.rollOneOf(words))
ChatMessage.create( { content: `Nom : ${name}`, whisper: ChatMessage.getWhisperRecipients("GM") } ); });
ChatMessage.create({ content: html, whisper: ChatMessage.getWhisperRecipients("GM") });
} }
static async onCreerActeur(event) {
const button = event.currentTarget;
await RdDActor.create({
name: button.attributes['data-nom'].value,
type: button.attributes['data-type'].value
},
{renderSheet: true});
}
} }

View File

@@ -1,3 +1,5 @@
import { ENTITE_BLURETTE, ENTITE_INCARNE, ENTITE_NONINCARNE } from "./constants.js";
/** /**
* Extend the base Dialog entity by defining a custom window to perform roll. * Extend the base Dialog entity by defining a custom window to perform roll.
* @extends {Dialog} * @extends {Dialog}
@@ -7,15 +9,19 @@ export class RdDEncaisser extends Dialog {
/* -------------------------------------------- */ /* -------------------------------------------- */
constructor(html, actor) { constructor(html, actor) {
// Common conf // Common conf
const buttonsCreatures = { let buttons = {};
"mortel": { label: "Mortel", callback: html => this.performEncaisser("mortel") }, if (!actor.isEntite()){
"non-mortel": { label: "Non-mortel", callback: html => this.performEncaisser("non-mortel") }, buttons = {
"sonne": { label: "Sonné", callback: html => this.actor.setSonne() }, "mortel": { label: "Mortel", callback: html => this.performEncaisser("mortel") },
}; "non-mortel": { label: "Non-mortel", callback: html => this.performEncaisser("non-mortel") },
const buttonsEntitesCauchemar = { "sonne": { label: "Sonné", callback: html => this.actor.setSonne() },
"cauchemar": { label: "cauchemar", callback: html => this.performEncaisser("cauchemar") } };
}; }
const buttons = actor.isEntiteCauchemar() ? buttonsEntitesCauchemar : buttonsCreatures; else if (actor.isEntite([ENTITE_BLURETTE, ENTITE_INCARNE])){
buttons = {
"cauchemar": { label: "cauchemar", callback: html => this.performEncaisser("cauchemar") }
}
}
let dialogConf = { let dialogConf = {
title: "Jet d'Encaissement", title: "Jet d'Encaissement",
@@ -24,7 +30,6 @@ export class RdDEncaisser extends Dialog {
default: "mortel" default: "mortel"
} }
let dialogOptions = { let dialogOptions = {
classes: ["rdddialog"], classes: ["rdddialog"],
width: 320, width: 320,

View File

@@ -11,6 +11,7 @@ import { RdDDice } from "./rdd-dice.js";
import { RdDItem } from "./item.js"; import { RdDItem } from "./item.js";
import { Monnaie } from "./item-monnaie.js"; import { Monnaie } from "./item-monnaie.js";
import { RdDPossession } from "./rdd-possession.js"; import { RdDPossession } from "./rdd-possession.js";
import { RdDNameGen } from "./rdd-namegen.js";
/* -------------------------------------------- */ /* -------------------------------------------- */
// This table starts at 0 -> niveau -10 // This table starts at 0 -> niveau -10
@@ -463,34 +464,32 @@ export class RdDUtility {
/** Construit la structure récursive des conteneurs, avec imbrication potentielle /** Construit la structure récursive des conteneurs, avec imbrication potentielle
* *
*/ */
static buildConteneur(objet, niveau) { static buildConteneur(objet, profondeur) {
if (!niveau) niveau = 1; if (!profondeur) profondeur = 1;
objet.niveau = niveau; objet.niveau = profondeur;
//console.log("OBJ:", objet); const isConteneur = objet.type == 'conteneur';
let str = Handlebars.partials['systems/foundryvtt-reve-de-dragon/templates/actor-sheet-inventaire-conteneur.html']({ item: objet }); const isOuvert = isConteneur && this.getAfficheContenu(objet._id);
if (objet.type == 'conteneur') { const isVide = isConteneur && Misc.templateData(objet).contenu.length == 0;
const afficherContenu = this.getAfficheContenu(objet._id); const conteneur = Handlebars.partials['systems/foundryvtt-reve-de-dragon/templates/actor-sheet-inventaire-conteneur.html']({
str = str + RdDUtility.buildContenu(objet, niveau, afficherContenu); item: objet,
} vide: isVide,
return str; ouvert: isOuvert
});
const contenu = isConteneur ? RdDUtility.buildContenu(objet, profondeur, isOuvert) : '';
return conteneur + contenu;
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
static buildContenu(objet, niveau, afficherContenu) { static buildContenu(objet, profondeur, afficherContenu) {
if (!niveau) niveau = 1; if (!profondeur) profondeur = 1;
objet.niveau = niveau; objet.niveau = profondeur;
let strContenu = ""; const display = afficherContenu ? 'item-display-show' : 'item-display-hide';
//console.log("ITEM DISPLAYED", objet ); //console.log("ITEM DISPLAYED", objet );
if (afficherContenu) { let strContenu = `<ul class='item-list alterne-list ${display} list-item-margin${profondeur}'>`;
strContenu = "<ul class='item-list alterne-list item-display-show list-item-margin" + niveau + "'>";
} else {
strContenu = "<ul class='item-list alterne-list item-display-hide list-item-margin" + niveau + "'>";
}
for (let subItem of objet.subItems) { for (let subItem of objet.subItems) {
strContenu = strContenu + this.buildConteneur(subItem, niveau + 1); strContenu += this.buildConteneur(subItem, profondeur + 1);
} }
strContenu = strContenu + "</ul>"; return strContenu + "</ul>";
return strContenu;
} }
/* -------------------------------------------- */ /* -------------------------------------------- */
@@ -703,6 +702,7 @@ export class RdDUtility {
// gestion bouton tchat Acheter // gestion bouton tchat Acheter
html.on("click", '.button-acheter', event => DialogItemAchat.onButtonAcheter(event)); html.on("click", '.button-acheter', event => DialogItemAchat.onButtonAcheter(event));
html.on("click", '.button-creer-acteur', event => RdDNameGen.onCreerActeur(event));
// Gestion du bouton payer // Gestion du bouton payer
html.on("click", '.payer-button', event => { html.on("click", '.payer-button', event => {

File diff suppressed because one or more lines are too long

View File

@@ -806,16 +806,22 @@ ul, li {
} }
.list-item-margin1 { .list-item-margin1 {
margin-left: 1rem; margin-left: 0.5rem;
} }
.list-item-margin2 { .list-item-margin2 {
margin-left: 2rem; margin-left: 1rem;
} }
.list-item-margin3 { .list-item-margin3 {
margin-left: 3rem; margin-left: 1.5rem;
} }
.list-item-margin4 { .list-item-margin4 {
margin-left: 4rem; margin-left: 2rem;
}
.list-item-margin5 {
margin-left: 2.5rem;
}
.list-item-margin6 {
margin-left: 3rem;
} }
.sheet-competence-img { .sheet-competence-img {

View File

@@ -1,38 +1,43 @@
{ {
"name": "foundryvtt-reve-de-dragon", "id": "foundryvtt-reve-de-dragon",
"title": "Rêve de Dragon", "title": "Rêve de Dragon",
"description": "Rêve de Dragon RPG for FoundryVTT", "description": "Rêve de Dragon RPG for FoundryVTT",
"author": "LeRatierBretonnien",
"authors": [ "authors": [
{ {
"name": "LeRatierBretonnien" "name": "LeRatierBretonnien",
"flags": {}
}, },
{ {
"name": "VincentVK" "name": "VincentVK",
"flags": {}
}, },
{ {
"name": "Grendel" "name": "Grendel",
"flags": {}
}, },
{ {
"name": "Michael Nonne" "name": "Michael Nonne",
"flags": {}
}, },
{ {
"name": "Mandar" "name": "Mandar",
"flags": {}
}, },
{ {
"name": "Fred" "name": "Fred",
"flags": {}
}, },
{ {
"name": "Fab" "name": "Fab",
"flags": {}
} }
], ],
"url": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/", "url": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/",
"license": "LICENSE.txt", "license": "LICENSE.txt",
"flags": {}, "version": "10.0.6",
"version": "10.0.2", "compatibility": {
"minimumCoreVersion": "10", "minimum": "10"
"compatibleCoreVersion": "10", },
"scripts": [],
"esmodules": [ "esmodules": [
"module/rdd-main.js" "module/rdd-main.js"
], ],
@@ -44,12 +49,13 @@
"lang": "en", "lang": "en",
"name": "English", "name": "English",
"path": "lang/fr.json", "path": "lang/fr.json",
"unreal": "this is a trick" "flags": {}
}, },
{ {
"lang": "fr", "lang": "fr",
"name": "Français", "name": "Français",
"path": "lang/fr.json" "path": "lang/fr.json",
"flags": {}
} }
], ],
"packs": [ "packs": [
@@ -57,453 +63,284 @@
"name": "competences", "name": "competences",
"label": "Compétences", "label": "Compétences",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/competences.db",
"path": "./packs/competences.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"compétences"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "arts-et-divertissements", "name": "arts-et-divertissements",
"label": "Arts et Divertissements", "label": "Arts et Divertissements",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/arts-et-divertissements.db",
"path": "./packs/arts-et-divertissements.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"recette", "flags": {}
"cuisine",
"danse",
"musique",
"chant",
"jeux"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "competences-creatures", "name": "competences-creatures",
"label": "Compétences de Créatures", "label": "Compétences de Créatures",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/competences-creatures.db",
"path": "./packs/competences-creatures.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"compétences",
"créatures"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "competences-entites", "name": "competences-entites",
"label": "Compétences des Entités", "label": "Compétences des Entités",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/competences-entites.db",
"path": "./packs/competences-entites.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"compétences",
"entités"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "sorts-oniros", "name": "sorts-oniros",
"label": "Sorts d'Oniros", "label": "Sorts d'Oniros",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/sorts-oniros.db",
"path": "./packs/sorts-oniros.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"sorts"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "sorts-hypnos", "name": "sorts-hypnos",
"label": "Sorts d'Hypnos", "label": "Sorts d'Hypnos",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/sorts-hypnos.db",
"path": "./packs/sorts-hypnos.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"sorts"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "sorts-narcos", "name": "sorts-narcos",
"label": "Sorts de Narcos", "label": "Sorts de Narcos",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/sorts-narcos.db",
"path": "./packs/sorts-narcos.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"sorts"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "sorts-thanatos", "name": "sorts-thanatos",
"label": "Sorts de Thanatos", "label": "Sorts de Thanatos",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/sorts-thanatos.db",
"path": "./packs/sorts-thanatos.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"sorts"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "equipement", "name": "equipement",
"label": "Equipement", "label": "Equipement",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/equipement.db",
"path": "./packs/equipement.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"équipement",
"objet"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "maladies-et-poisons", "name": "maladies-et-poisons",
"label": "Maladies & Poisons", "label": "Maladies & Poisons",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/maladies-et-poisons.db",
"path": "./packs/maladies-et-poisons.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"maladie", "flags": {}
"poison"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "rappel-des-regles", "name": "rappel-des-regles",
"label": "Rappels des Règles", "label": "Rappels des Règles",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/rappel-des-regles.db",
"path": "./packs/rappel-des-regles.db",
"type": "JournalEntry", "type": "JournalEntry",
"tags": [ "private": false,
"journal", "flags": {}
"règles"
],
"entity": "JournalEntry",
"private": false
}, },
{ {
"name": "queues-de-dragon", "name": "queues-de-dragon",
"label": "Queues de Dragon", "label": "Queues de Dragon",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/queues-de-dragon.db",
"path": "./packs/queues-de-dragon.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"queue"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "ombres-de-thanatos", "name": "ombres-de-thanatos",
"label": "Ombres de Thanatos", "label": "Ombres de Thanatos",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/ombres-de-thanatos.db",
"path": "./packs/ombres-de-thanatos.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"ombre"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "souffles-de-dragon", "name": "souffles-de-dragon",
"label": "Souffles de Dragon", "label": "Souffles de Dragon",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/souffles-de-dragon.db",
"path": "./packs/souffles-de-dragon.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"souffle"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "tarot-draconique", "name": "tarot-draconique",
"label": "Tarot Draconique", "label": "Tarot Draconique",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/tarot-draconique.db",
"path": "./packs/tarot-draconique.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"tarot"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "tetes-de-dragon-pour-haut-revants", "name": "tetes-de-dragon-pour-haut-revants",
"label": "Têtes de Dragon (Hauts-Rêvants)", "label": "Têtes de Dragon (Hauts-Rêvants)",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/tetes-de-dragon-pour-haut-revants.db",
"path": "./packs/tetes-de-dragon-pour-haut-revants.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"tête"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "tetes-de-dragon-pour-tous-personnages", "name": "tetes-de-dragon-pour-tous-personnages",
"label": "Têtes de Dragon (Tous Personnages)", "label": "Têtes de Dragon (Tous Personnages)",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/tetes-de-dragon-pour-tous-personnages.db",
"path": "./packs/tetes-de-dragon-pour-tous-personnages.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"item", "flags": {}
"tête"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "tables-diverses", "name": "tables-diverses",
"label": "Tables Diverses", "label": "Tables Diverses",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/tables-diverses.db",
"path": "./packs/tables-diverses.db",
"type": "RollTable", "type": "RollTable",
"tags": [ "private": false,
"table", "flags": {}
"tables"
],
"entity": "RollTable",
"private": false
}, },
{ {
"name": "animaux", "name": "animaux",
"label": "Animaux", "label": "Animaux",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/animaux.db",
"path": "./packs/animaux.db",
"type": "Actor", "type": "Actor",
"tags": [ "private": false,
"animaux", "flags": {}
"creature"
],
"entity": "Actor",
"private": false
}, },
{ {
"name": "voyageurs", "name": "voyageurs",
"label": "Voyageurs", "label": "Voyageurs",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/voyageurs.db",
"path": "./packs/voyageurs.db",
"type": "Actor", "type": "Actor",
"tags": [ "private": false,
"voyageur", "flags": {}
"profils"
],
"entity": "Actor",
"private": false
}, },
{ {
"name": "vehicules", "name": "vehicules",
"label": "Véhicules", "label": "Véhicules",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/vehicules.db",
"path": "./packs/vehicules.db",
"type": "Actor", "type": "Actor",
"tags": [ "private": false,
"vehicule", "flags": {}
"bateau",
"charett",
"chariot",
"carriole",
"barque"
],
"entity": "Actor",
"private": false
}, },
{ {
"name": "archetypes", "name": "archetypes",
"label": "Archetypes PNJs", "label": "Archetypes PNJs",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/archetypes.db",
"path": "./packs/archetypes.db",
"type": "Actor", "type": "Actor",
"tags": [ "private": false,
"archetype", "flags": {}
"pnj"
],
"entity": "Actor",
"private": false
}, },
{ {
"name": "humanoides", "name": "humanoides",
"label": "Humanoïdes", "label": "Humanoïdes",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/humanoides.db",
"path": "./packs/humanoides.db",
"type": "Actor", "type": "Actor",
"tags": [ "private": false,
"humanoides", "flags": {}
"pnj"
],
"entity": "Actor",
"private": false
}, },
{ {
"name": "entites", "name": "entites",
"label": "Entités de Cauchemar", "label": "Entités de Cauchemar",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/entites-de-cauchemar.db",
"path": "./packs/entites-de-cauchemar.db",
"type": "Actor", "type": "Actor",
"tags": [ "private": false,
"entités", "flags": {}
"entite",
"cauchemar",
"ecni",
"eni"
],
"entity": "Actor",
"private": false
}, },
{ {
"name": "invocations", "name": "invocations",
"label": "Invocation d'Hypnos", "label": "Invocation d'Hypnos",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/invocations.db",
"path": "./packs/invocations.db",
"type": "Actor", "type": "Actor",
"tags": [ "private": false,
"hypnos", "flags": {}
"invocation"
],
"entity": "Actor",
"private": false
}, },
{ {
"name": "botanique", "name": "botanique",
"label": "Botanique", "label": "Botanique",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/botanique.db",
"path": "./packs/botanique.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"plantes", "flags": {}
"champignons",
"herbes"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "taches-courantes", "name": "taches-courantes",
"label": "Tâches courantes", "label": "Tâches courantes",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/taches-courantes.db",
"path": "./packs/taches-courantes.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"taches" "flags": {}
],
"entity": "Item",
"private": false
}, },
{ {
"name": "meditations-et-ecrits", "name": "meditations-et-ecrits",
"label": "Méditations et Ecrits", "label": "Méditations et Ecrits",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/meditations-et-ecrits.db",
"path": "./packs/meditations-et-ecrits.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"meditations", "flags": {}
"méditations",
"livres",
"livre",
"méditation",
"écrits",
"écrit"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "recettes-alchimiques", "name": "recettes-alchimiques",
"label": "Recettes Alchimiques", "label": "Recettes Alchimiques",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/recettes-alchimiques.db",
"path": "./packs/recettes-alchimiques.db",
"type": "Item", "type": "Item",
"tags": [ "private": false,
"recettes", "flags": {}
"recette",
"alchimie",
"alchimique",
"potion"
],
"entity": "Item",
"private": false
}, },
{ {
"name": "scenes-rdd", "name": "scenes-rdd",
"label": "Scenes Reve de Dragon", "label": "Scenes Reve de Dragon",
"system": "foundryvtt-reve-de-dragon", "system": "foundryvtt-reve-de-dragon",
"module": "foundryvtt-reve-de-dragon", "path": "packs/scenes-rdd.db",
"path": "./packs/scenes-rdd.db",
"type": "Scene", "type": "Scene",
"tags": [ "private": false,
"ecran", "flags": {}
"scene"
],
"entity": "Scene",
"private": false
} }
], ],
"system": [],
"dependencies": [],
"socket": true, "socket": true,
<<<<<<< HEAD
"manifest": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/raw/v10/system.json", "manifest": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/raw/v10/system.json",
"download": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/archive/foundryvtt-reve-de-dragon-10.0.2.zip", "download": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/archive/foundryvtt-reve-de-dragon-10.0.6.zip",
=======
"manifest": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/raw/v1.5/system.json",
"download": "https://www.uberwald.me/gitea/public/foundryvtt-reve-de-dragon/archive/foundryvtt-reve-de-dragon-1.5.86.zip",
"protected": false, "protected": false,
>>>>>>> origin/v1.5
"gridDistance": 1, "gridDistance": 1,
"gridUnits": "m", "gridUnits": "m",
"primaryTokenAttribute": "sante.vie", "primaryTokenAttribute": "sante.vie",
"secondaryTokenAttribute": "sante.endurance" "secondaryTokenAttribute": "sante.endurance"
} }

View File

@@ -28,7 +28,7 @@
{{!-- Carac Tab --}} {{!-- Carac Tab --}}
<div class="tab items" data-group="primary" data-tab="carac"> <div class="tab items" data-group="primary" data-tab="carac">
<div class="grid grid-2col"> <div class="grid grid-2col">
<div class="flex-group-left flexcol"> <div class="flex-group-left flexcol">
<ol class="carac-list alterne-list"> <ol class="carac-list alterne-list">
@@ -65,6 +65,7 @@
{{#select data.definition.typeentite}} {{#select data.definition.typeentite}}
<option value="incarne">Incarnée</option> <option value="incarne">Incarnée</option>
<option value="nonincarne">Non Incarnée</option> <option value="nonincarne">Non Incarnée</option>
<option value="blurette">Blurete</option>
{{/select}} {{/select}}
</select> </select>
</li> </li>
@@ -89,9 +90,7 @@
{{!-- Compétences Tab --}} {{!-- Compétences Tab --}}
<div class="tab competences" data-group="primary" data-tab="competences"> <div class="tab competences" data-group="primary" data-tab="competences">
<div class="flexcol"> <div class="flexcol">
<div class="flex-group-left flexcol competence-column"> <div class="flex-group-left flexcol competence-column">
<ol class="item-list alterne-list"> <ol class="item-list alterne-list">
{{#each competences as |comp key|}} {{#each competences as |comp key|}}
@@ -111,25 +110,24 @@
</li> </li>
{{/each}} {{/each}}
</ol> </ol>
</div>
<div class="flex-group-left flexcol competence-column"> <div class="flex-group-left flexcol competence-column">
<ol class="item-list alterne-list"> <ol class="item-list alterne-list">
{{#each possessions as |possession key|}} {{#each possessions as |possession key|}}
<li class="item flexrow list-item" data-item-id="{{possession._id}}"> <li class="item flexrow list-item" data-item-id="{{possession._id}}">
<img class="sheet-competence-img" src="{{possession.img}}" /> <img class="sheet-competence-img" src="{{possession.img}}" />
<span class="competence-label">{{possession.name}}</span> <span class="competence-label">{{possession.name}}</span>
<div class="item-controls"> <div class="item-controls">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></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> <a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div> </div>
</li> </li>
{{/each}} {{/each}}
</ol> </ol>
</div> </div>
</div> </div>
</div> </div>
{{!-- Biography Tab --}} {{!-- Biography Tab --}}
<div class="tab description" data-group="primary" data-tab="description"> <div class="tab description" data-group="primary" data-tab="description">
<div class="form-group editor"> <div class="form-group editor">
@@ -137,8 +135,6 @@
</div> </div>
{{>"systems/foundryvtt-reve-de-dragon/templates/actor-sheet-editor-notes-mj.html"}} {{>"systems/foundryvtt-reve-de-dragon/templates/actor-sheet-editor-notes-mj.html"}}
</div> </div>
</div>
</section> </section>
</form> </form>

View File

@@ -1,9 +1,28 @@
<li class="item flexrow list-item" data-item-id="{{item._id}}" draggable="true"> <li class="item flexrow list-item" data-item-id="{{item._id}}" draggable="true">
<img class="sheet-competence-img" src="{{item.img}}" title="{{item.name}}"/>
{{#if (eq item.type 'conteneur')}} {{#if (eq item.type 'conteneur')}}
<span class="item-name conteneur-name flex-grow"><a data-item-id="{{item._id}}">+{{item.name}}</a></span> <span class="sheet-competence-img conteneur-name">
{{#if vide}}
<i class="far fa-square"></i>
{{else}}
<a data-item-id="{{item._id}}">
{{#if ouvert}}
<i class="far fa-minus-square"></i>
<!-- <i class="far fa-caret-square-down"></i> -->
{{else}}
<i class="far fa-plus-square"></i>
<!-- <i class="fas fa-caret-square-right"></i> -->
{{/if}}
</a>
{{/if}}
</span>
<span class="item-name conteneur-name flex-grow">
<a data-item-id="{{item._id}}">
<img class="sheet-competence-img" src="{{item.img}}" title="{{item.name}}"/>
{{item.name}}
</a>
</span>
{{else}} {{else}}
<img class="sheet-competence-img" src="{{item.img}}" title="{{item.name}}"/>
<span class="item-name flex-grow">{{item.name}}</span> <span class="item-name flex-grow">{{item.name}}</span>
{{/if}} {{/if}}
<span class="item-quantite">{{item.system.quantite}} <span class="item-quantite">{{item.system.quantite}}
@@ -30,3 +49,4 @@
{{/if}} {{/if}}
</div> </div>
</li> </li>

View File

@@ -217,7 +217,7 @@
{{#if options.editCaracComp}}Verrouiller{{else}}Déverrouiller{{/if}}</a></span> {{#if options.editCaracComp}}Verrouiller{{else}}Déverrouiller{{/if}}</a></span>
<span class="flexrow"> <span class="flexrow">
<i class="fas fa-search"></i> <i class="fas fa-search"></i>
<input class="cherchercompetence" type="text" value="{{options.cherchercompetence}}" name="cherchercompetence" <input class="recherche" type="text" value="{{options.recherche.text}}" name="recherche"
size="8" data-dtype="String" placeholder="chercher"/> size="8" data-dtype="String" placeholder="chercher"/>
<span></span> <span></span>
</span> </span>
@@ -690,7 +690,7 @@
{{#each objets as |item id|}} {{#each objets as |item id|}}
{{#unless item.estContenu}} {{#unless item.estContenu}}
{{#if (ne item.type 'conteneur')}} {{#if (ne item.type 'conteneur')}}
{{> "systems/foundryvtt-reve-de-dragon/templates/actor-sheet-inventaire-conteneur.html" item=item }} {{> "systems/foundryvtt-reve-de-dragon/templates/actor-sheet-inventaire-conteneur.html" item=item vide=true ouvert=true }}
{{/if}} {{/if}}
{{/unless}} {{/unless}}
{{/each}} {{/each}}

View File

@@ -0,0 +1,16 @@
<h4>Proposition de nom: {{nom}}</h4>
<span class="chat-card-button-area">
<a class="button-creer-acteur chat-card-button"
data-nom='{{nom}}'
data-type='personnage'
>
Créer un Personnage</a>
</span>
<span class="chat-card-button-area">
<a class="button-creer-acteur chat-card-button"
data-nom='{{nom}}'
data-type='creature'>
Créer une créature</a>
</span>