forked from public/foundryvtt-reve-de-dragon
#27 Gestion des rencontres
This commit is contained in:
@ -282,7 +282,7 @@ export class TMRUtility {
|
||||
/* -------------------------------------------- */
|
||||
static async rencontreTMRRoll( coordTMR, cellDescr )
|
||||
{
|
||||
let rencontre = this.rencontreTMRTypeCase(cellDescr.type);
|
||||
let rencontre = await this.rencontreTMRTypeCase(cellDescr.type);
|
||||
//let rencontre = rencontresTable[4];
|
||||
if (rencontre){
|
||||
rencontre = duplicate(rencontre);
|
||||
@ -300,10 +300,11 @@ export class TMRUtility {
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
static rencontreTMRTypeCase(typeTMR, roll=undefined) {
|
||||
static async rencontreTMRTypeCase(typeTMR, roll=undefined) {
|
||||
if (!roll)
|
||||
{
|
||||
roll = RdDDice.show(new Roll("d100").evaluate()).total;
|
||||
//roll = await RdDDice.show(new Roll("d100").evaluate()).total;
|
||||
roll = new Roll("d100").roll().total;
|
||||
console.log("rencontreTMRTypeCase", roll);
|
||||
}
|
||||
typeTMR = typeTMR.toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g, "");
|
||||
|
Reference in New Issue
Block a user