From 60953672512dab3a3d1a672486f63579b0b8c589 Mon Sep 17 00:00:00 2001 From: Vincent Vandemeulebrouck Date: Tue, 25 Jan 2022 21:45:29 +0100 Subject: [PATCH 1/2] Rename entity to type (warning in Foundry 9) --- system.json | 60 ++++++++++++++++++++++++++--------------------------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/system.json b/system.json index 0c33dee2..5b16a0dc 100644 --- a/system.json +++ b/system.json @@ -54,7 +54,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/competences.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "compétences" ] }, { @@ -63,7 +63,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/arts-et-divertissements.db", - "entity": "Item", + "type": "Item", "tags" : [ "recette", "cuisine", "danse", "musique", "chant", "jeux" ] }, { @@ -72,7 +72,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/competences-creatures.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "compétences", "créatures" ] }, { @@ -81,7 +81,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/competences-entites.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "compétences", "entités" ] }, { @@ -90,7 +90,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/sorts-oniros.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "sorts" ] }, { @@ -99,7 +99,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/sorts-hypnos.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "sorts" ] }, { @@ -108,7 +108,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/sorts-narcos.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "sorts" ] }, { @@ -117,7 +117,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/sorts-thanatos.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "sorts" ] }, { @@ -126,7 +126,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/equipement.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "équipement", "objet" ] }, { @@ -135,7 +135,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/maladies-et-poisons.db", - "entity": "Item", + "type": "Item", "tags" : [ "maladie", "poison" ] }, { @@ -144,7 +144,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/rappel-des-regles.db", - "entity": "JournalEntry", + "type": "JournalEntry", "tags" : [ "journal", "règles" ] }, { @@ -153,7 +153,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/queues-de-dragon.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "queue" ] }, { @@ -162,7 +162,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/ombres-de-thanatos.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "ombre" ] }, { @@ -171,7 +171,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/souffles-de-dragon.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "souffle" ] }, { @@ -180,7 +180,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/tarot-draconique.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "tarot" ] }, { @@ -189,7 +189,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/tetes-de-dragon-pour-haut-revants.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "tête" ] }, { @@ -198,7 +198,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/tetes-de-dragon-pour-tous-personnages.db", - "entity": "Item", + "type": "Item", "tags" : [ "item", "tête" ] }, { @@ -207,7 +207,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/tables-diverses.db", - "entity": "RollTable", + "type": "RollTable", "tags" : [ "table", "tables" ] }, { @@ -216,7 +216,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/animaux.db", - "entity": "Actor", + "type": "Actor", "tags" : [ "animaux", "creature" ] }, { @@ -225,7 +225,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/voyageurs.db", - "entity": "Actor", + "type": "Actor", "tags" : [ "voyageur", "profils" ] }, { @@ -234,7 +234,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/vehicules.db", - "entity": "Actor", + "type": "Actor", "tags" : [ "vehicule", "bateau", "charett", "chariot", "carriole", "barque" ] }, { @@ -243,7 +243,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/archetypes.db", - "entity": "Actor", + "type": "Actor", "tags" : [ "archetype", "pnj" ] }, { @@ -252,7 +252,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/humanoides.db", - "entity": "Actor", + "type": "Actor", "tags" : [ "humanoides", "pnj" ] }, { @@ -261,7 +261,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/entites-de-cauchemar.db", - "entity": "Actor", + "type": "Actor", "tags" : [ "entités", "entite", "cauchemar", "ecni", "eni" ] }, { @@ -270,7 +270,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/invocations.db", - "entity": "Actor", + "type": "Actor", "tags" : [ "hypnos", "invocation" ] }, { @@ -279,7 +279,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/botanique.db", - "entity": "Item", + "type": "Item", "tags" : [ "plantes", "champignons", "herbes" ] }, { @@ -288,7 +288,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/taches-courantes.db", - "entity": "Item", + "type": "Item", "tags" : [ "taches" ] }, { @@ -297,7 +297,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/meditations-et-ecrits.db", - "entity": "Item", + "type": "Item", "tags" : [ "meditations", "méditations", "livres", "livre", "méditation", "écrits", "écrit" ] }, { @@ -306,7 +306,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/recettes-alchimiques.db", - "entity": "Item", + "type": "Item", "tags" : [ "recettes", "recette", "alchimie", "alchimique", "potion" ] }, { @@ -315,7 +315,7 @@ "system": "foundryvtt-reve-de-dragon", "module": "foundryvtt-reve-de-dragon", "path": "./packs/scenes-rdd.db", - "entity": "Scene", + "type": "Scene", "tags" : [ "ecran", "scene" ] } ], From 1eefa62495450c19a2d2d08cb2dc87abf90b0785 Mon Sep 17 00:00:00 2001 From: Vincent Vandemeulebrouck Date: Tue, 25 Jan 2022 22:06:10 +0100 Subject: [PATCH 2/2] =?UTF-8?q?Cacher=20les=20points=20de=20t=C3=A2che?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- module/item.js | 10 ++++++---- templates/actor-sheet.html | 5 ++++- templates/chat-resultat-tache.html | 3 ++- 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/module/item.js b/module/item.js index 23bfb441..be445e19 100644 --- a/module/item.js +++ b/module/item.js @@ -404,10 +404,12 @@ export class RdDItem extends Item { `Compétence: ${tplData.competence}`, `Périodicité: ${tplData.periodicite}`, `Fatigue: ${tplData.fatigue}`, - `Difficulté: ${tplData.difficulte}`, - `Points de Tâche: ${tplData.points_de_tache}`, - `Points de Tâche atteints: ${tplData.points_de_tache_courant}` - ] + `Difficulté: ${tplData.difficulte}` + ].concat([ + tplData.cacher_points_de_tache ? [] :`Points de Tâche: ${tplData.points_de_tache}` + ]).concat([ + `Points de Tâche atteints: ${tplData.points_de_tache_courant}`] + ); return properties; } /* -------------------------------------------- */ diff --git a/templates/actor-sheet.html b/templates/actor-sheet.html index 142268df..10cbdf3e 100644 --- a/templates/actor-sheet.html +++ b/templates/actor-sheet.html @@ -381,7 +381,10 @@

Tâches

Créer une nouvelle Tâche