Fix commande /tmra

This commit is contained in:
2025-01-14 21:42:02 +01:00
parent 7e8da49912
commit c5633a9fc5
4 changed files with 18 additions and 11 deletions

View File

@ -26,7 +26,7 @@ export class TMRRencontres {
* @param {*} forcedRoll
*/
async rollRencontre(terrain, forcedRoll) {
const tmrType = TMRUtility.findTMRLike(terrain)?.type
const tmrType = TMRUtility.findTMRLike(terrain, { inclusMauvaise: true })?.type
if (tmrType == undefined) {
return undefined;
}
@ -38,7 +38,7 @@ export class TMRRencontres {
const frequence = it => it.system.frequence[tmrType];
const row = await this.table.getRandom(frequence, filtreMauvaise, forcedRoll);
if (row) {
await CompendiumTableHelpers.tableRowToChatMessage(row, 'Item', {showSource: false});
await CompendiumTableHelpers.tableRowToChatMessage(row, 'Item', { showSource: false });
}
return row?.document;