Sorts rituels

This commit is contained in:
Vincent Vandemeulebrouck 2020-12-11 20:37:00 +01:00
parent 8254811a87
commit 0fe2919b91
4 changed files with 19 additions and 4 deletions

View File

@ -1318,7 +1318,12 @@ export class RdDActor extends Actor {
let rolled = rollData.rolled;
let sort = rollData.selectedSort;
let closeTMR = !rollData.isSortReserve;
if (sort.data.isrituel && isSortReserve) {
ui.notifications.error("Impossible de mettre le rituel '" + sort.name + "' en réserve");
this.currentTMR.close(); // Close TMR !
return;
}
let explications = rollData.isSortReserve
? ("<br>Mise en réserve du sort en " + rollData.coordLabel + "(" + rollData.coord + ")<strong>")
: "<br>Lancement du sort <strong>";

View File

@ -2,10 +2,10 @@
"name": "foundryvtt-reve-de-dragon",
"title": "Rêve de Dragon",
"description": "Rêve de Dragon RPG for FoundryVTT",
"version": "1.1.3",
"version": "1.1.4",
"minimumCoreVersion": "0.7.5",
"compatibleCoreVersion": "0.7.8",
"templateVersion": 60,
"templateVersion": 61,
"author": "LeRatierBretonnien",
"esmodules": [ "module/rdd-main.js", "module/hook-renderChatLog.js" ],
"styles": ["styles/simple.css"],

View File

@ -615,7 +615,9 @@
"caseTMRspeciale": "",
"ptreve": "",
"xp": 0,
"bonuscase": ""
"bonuscase": "",
"isrituel": false,
"coutseuil": 0
},
"herbe": {
"description": "",

View File

@ -36,6 +36,14 @@
<label for="xp">Coût en Rêve </label>
<input class="attribute-value" type="text" name="data.ptreve" value="{{data.ptreve}}" data-dtype="String"/>
</div>
<div class="form-group">
<label for="xp">Coût en Seuil </label>
<input class="attribute-value" type="text" name="data.coutseuil" value="{{data.coutseuil}}" data-dtype="Number"/>
</div>
<div class="form-group">
<label for="rituel">Rituel </label>
<input class="attribute-value" type="checkbox" name="data.isrituel" {{#if data.isrituel}}checked{{/if}}/>
</div>
<div class="form-group">
<label for="xp">Durée </label>
<input class="attribute-value" type="text" name="data.duree" value="{{data.duree}}" data-dtype="String"/>