From 43ca970dbdf4b326a14de2f9627ce9185bc2d738 Mon Sep 17 00:00:00 2001 From: sladecraven Date: Fri, 23 Apr 2021 12:51:52 +0200 Subject: [PATCH] Fix armes de tir --- modules/vadentis-actor-sheet.js | 1 + modules/vadentis-actor.js | 4 ++++ packs/equipement-armes-de-tirs.db | 24 ++++++++++++------------ system.json | 4 ++-- template.json | 7 ++++++- templates/actor-sheet.html | 15 +++++++++++++++ templates/item-monnaie-sheet.html | 19 +++++++++++++++++++ 7 files changed, 59 insertions(+), 15 deletions(-) create mode 100644 templates/item-monnaie-sheet.html diff --git a/modules/vadentis-actor-sheet.js b/modules/vadentis-actor-sheet.js index 5921fd9..4bd4c23 100644 --- a/modules/vadentis-actor-sheet.js +++ b/modules/vadentis-actor-sheet.js @@ -37,6 +37,7 @@ export class VadentisActorSheet extends ActorSheet { data.armes = this.actor.getArmes(); data.armures = this.actor.getArmures(); data.equipements = this.actor.getEquipements(); + data.monnaies = this.actor.getMonnaies(); data.optionsBase = VadentisUtility.createDirectOptionList(0, 50); data.optionsMalus = VadentisUtility.createDirectReverseOptionList(-50, 0); diff --git a/modules/vadentis-actor.js b/modules/vadentis-actor.js index f3fa7fa..ee091a6 100644 --- a/modules/vadentis-actor.js +++ b/modules/vadentis-actor.js @@ -85,6 +85,10 @@ export class VadentisActor extends Actor { getArmures() { return this.data.items.filter( item => item.type == 'armurebouclier' ); } + /* -------------------------------------------- */ + getMonnaies() { + return this.data.items.filter( item => item.type == 'monnaie' ); + } /* -------------------------------------------- */ async updateCompetence( name, field, value) { diff --git a/packs/equipement-armes-de-tirs.db b/packs/equipement-armes-de-tirs.db index 01e49f2..2b7f2e6 100644 --- a/packs/equipement-armes-de-tirs.db +++ b/packs/equipement-armes-de-tirs.db @@ -1,12 +1,12 @@ -{"name":"Arc long","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"","enc":0,"cost":150,"type":"jetdeuxmain","damage":"1D8","criticaldamage":"","munition":"Flèches","distance":"60m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"149r9qSlp9jc18AT"} -{"name":"Arc court","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"","enc":0,"cost":150,"type":"jetdeuxmain","damage":"1D6","criticaldamage":"","munition":"Flèches","distance":"40m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"1utoOckG2dfPMdm0"} -{"name":"Sarbacane","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"","enc":0,"cost":60,"type":"jetunemain","damage":"1D6","criticaldamage":"","munition":"Fléchettes","distance":"15m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"8dQ5Cx4uJPImYkRa"} -{"name":"Pistoler rafale","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"","enc":0,"cost":150,"type":"feuunemain","damage":"3D4","criticaldamage":"","munition":"Orbes élémentaires de Feu","distance":"15m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"DT0wnNk429QrNB1o"} -{"name":"Boomerang","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"

Si le jet d'Attaque avec le boomerang dépasse 15, le boomerang revient vers l'utilisateur 

","enc":0,"cost":60,"type":"jetunemain","damage":"1D4","criticaldamage":"","munition":"","distance":"20m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"E3H5OmocGONlfNKc"} -{"name":"Fusil","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"","enc":0,"cost":230,"type":"feudeuxmains","damage":"2D8","criticaldamage":"","munition":"Orbes élémentaires de Feu","distance":"15m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"JBez0rVYg03L3fcF"} -{"name":"Arbalète de poing","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"","enc":0,"cost":120,"type":"jetunemain","damage":"1D6","criticaldamage":"","munition":"Petits carreaux","distance":"30m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"NEzgTLHHDGzq1c2E"} -{"name":"Shuriken","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"","enc":0,"cost":80,"type":"jetunemain","damage":"1D6","criticaldamage":"","munition":"","distance":"15m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"TLe4fB9A15PkRwUc"} -{"name":"Arbalète","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"","enc":0,"cost":150,"type":"jetdeuxmain","damage":"1D8","criticaldamage":"","munition":"Carreaux","distance":"60m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"cAl9BCDhWogcMjdA"} -{"name":"Senbon","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"","enc":0,"cost":60,"type":"jetunemain","damage":"1D4","criticaldamage":"","munition":"","distance":"15m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"h2cqYZDUWSYZUqW1"} -{"name":"Pistolet","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"","enc":0,"cost":120,"type":"feuunemain","damage":"1d8","criticaldamage":"","munition":"Orbes élémentaires de Feu","distance":"20m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"oQPSW5XWhy0Hu2JW"} -{"name":"Fusil de précision","permission":{"default":0,"0FETyDL9AqSwhPI5":3},"type":"tir","data":{"equipee":false,"description":"

Un tour entie est nécessaire pour recharger l'arme. 

","enc":0,"cost":250,"type":"feudeuxmains","damage":"2D6","criticaldamage":"","munition":"Orbes élémentaires de Feu","distance":"80m"},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"pKQERwE0YAQs6xSo"} +{"name":"Boomerang","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":1,"equipee":false,"description":"

Si le jet d'Attaque avec le boomerang dépasse 15, le boomerang revient vers l'utilisateur 

","enc":0,"cost":60,"type":"jetunemain","damage":"1D4","criticaldamage":"2D4","munition":1,"distance":"20m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"7NLMTRV3JCpsSP10"} +{"name":"Arc court","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":1,"equipee":false,"description":"","enc":0,"cost":150,"type":"jetdeuxmain","damage":"1D6","criticaldamage":"2d6","munition":0,"distance":"40m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"8CEFHCG5gFdh6XuE"} +{"name":"Arc long","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":1,"equipee":false,"description":"","enc":0,"cost":150,"type":"jetdeuxmain","damage":"1D8","criticaldamage":"2D8","munition":0,"distance":"60m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"NSyDmjn0JJzdmFjS"} +{"name":"Arbalète de poing","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":1,"equipee":false,"description":"","enc":0,"cost":120,"type":"jetunemain","damage":"1D6","criticaldamage":"2D6","munition":0,"distance":"30m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"RnvXM0G37ZGhWfGx"} +{"name":"Fusil de précision","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":1,"equipee":false,"description":"

Un tour entie est nécessaire pour recharger l'arme. 

","enc":0,"cost":250,"type":"feudeuxmains","damage":"2D6","criticaldamage":"3D6","munition":0,"distance":"80m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"cI8eRHPfC4cZV4Vr"} +{"_id":"fSqJgYVSTMk5ztBM","name":"Arbalète","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":null,"equipee":false,"description":"","enc":0,"cost":150,"type":"jetdeuxmain","damage":"1D8","criticaldamage":"2d8","munition":0,"distance":"60m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[]} +{"name":"Senbon","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":1,"equipee":false,"description":"","enc":0,"cost":60,"type":"jetunemain","damage":"1D4","criticaldamage":"2D4","munition":0,"distance":"15m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"fp5aEALQrGQpt5Cz"} +{"name":"Pistolet","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":1,"equipee":false,"description":"","enc":0,"cost":120,"type":"feuunemain","damage":"1d8","criticaldamage":"2d8","munition":0,"distance":"20m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"lWJtovlOCugtpBKW"} +{"name":"Sarbacane","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":1,"equipee":false,"description":"","enc":0,"cost":60,"type":"jetunemain","damage":"1D6","criticaldamage":"2D6","munition":0,"distance":"15m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"qh0xEYTL0JeXa2Op"} +{"name":"Pistoler rafale","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":1,"equipee":false,"description":"","enc":0,"cost":150,"type":"feuunemain","damage":"3D4","criticaldamage":"4D4","munition":0,"distance":"15m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"tHhCs8Rv8PnZAqiz"} +{"name":"Fusil","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":1,"equipee":false,"description":"","enc":0,"cost":230,"type":"feudeuxmains","damage":"2D8","criticaldamage":"3D8","munition":0,"distance":"15m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"tgiS4o44uOukwOPv"} +{"name":"Shuriken","permission":{"default":0,"sCecJLVlaPEcY7nF":3},"type":"tir","data":{"quantite":1,"equipee":false,"description":"","enc":0,"cost":80,"type":"jetunemain","damage":"1D6","criticaldamage":"2D6","munition":1,"distance":"15m","valuecritical":20},"flags":{},"img":"systems/foundryvtt-vadentis/images/icons/icone_item_armes_tir.webp","effects":[],"_id":"yJcJLbOMIpECvB44"} diff --git a/system.json b/system.json index 5fc74ed..3d45915 100644 --- a/system.json +++ b/system.json @@ -2,11 +2,11 @@ "name": "foundryvtt-vadentis", "title": "Vadentis", "description": "Système Vadentis pour FoundryVTT", - "version": "0.1.2", + "version": "0.1.4", "manifestPlusVersion": "1.0.0", "minimumCoreVersion": "0.7.5", "compatibleCoreVersion": "0.7.9", - "templateVersion": 16, + "templateVersion": 17, "author": "Uberwald", "esmodules": [ "modules/vadentis-main.js" ], "styles": ["styles/simple.css"], diff --git a/template.json b/template.json index ee5fa76..175d883 100644 --- a/template.json +++ b/template.json @@ -91,7 +91,7 @@ } }, "Item": { - "types": ["competence", "attribut", "technique", "sort", "devotion", "armecc", "tir", "armurebouclier", "equipement", "donnee", "eglise" ], + "types": ["competence", "attribut", "technique", "sort", "devotion", "armecc", "tir", "armurebouclier", "equipement", "donnee", "eglise", "monnaie" ], "templates": { "sortcommun": { "xp": 0, @@ -174,6 +174,11 @@ }, "equipement": { "templates": [ "equipcommun" ] + }, + "monnaie": { + "nombre": 0, + "enc": 0, + "description": "" } } } diff --git a/templates/actor-sheet.html b/templates/actor-sheet.html index a555ba8..5db98f8 100644 --- a/templates/actor-sheet.html +++ b/templates/actor-sheet.html @@ -319,6 +319,20 @@ {{!-- Equipement Tab --}}
+

Argent

+

Armes