forked from public/foundryvtt-reve-de-dragon
Fix: Commande /astro
This commit is contained in:
@ -609,12 +609,12 @@ export class RdDUtility {
|
||||
const encaissement = RdDUtility._selectEncaissement(jetTotal, rollData.dmg.mortalite);
|
||||
const over20 = Math.max(jetTotal - 20, 0);
|
||||
encaissement.dmg = rollData.dmg
|
||||
if (ReglesOptionnelles.isUsing('localisation-aleatoire')){
|
||||
if (ReglesOptionnelles.isUsing('localisation-aleatoire')) {
|
||||
encaissement.dmg.loc = rollData.dmg.loc ?? await RdDUtility.getLocalisation(actor.type)
|
||||
encaissement.dmg.loc.label = encaissement.dmg.loc.label ?? 'Corps;'
|
||||
}
|
||||
else{
|
||||
encaissement.dmg.loc = {label:''}
|
||||
else {
|
||||
encaissement.dmg.loc = { label: '' }
|
||||
}
|
||||
encaissement.dmg.bonusDegatsDiffLibre = bonusDegatsDiffLibre
|
||||
encaissement.roll = roll;
|
||||
@ -749,7 +749,7 @@ export class RdDUtility {
|
||||
static getSelectedToken(actor) {
|
||||
if (canvas.tokens.controlled.length > 0) {
|
||||
const tokens = canvas.tokens.controlled
|
||||
.filter(it => it.actor.id == actor.id)
|
||||
.filter(it => it.actor.id == actor.id)
|
||||
return tokens[0]
|
||||
}
|
||||
return undefined
|
||||
@ -881,10 +881,10 @@ export class RdDUtility {
|
||||
/* -------------------------------------------- */
|
||||
static afficherHeuresChanceMalchance(heureNaissance) {
|
||||
if (game.user.isGM) {
|
||||
const heure = RdDTimestamp.findHeure(heureNaissance - 1);
|
||||
const heure = RdDTimestamp.findHeure(heureNaissance)
|
||||
if (heureNaissance && heure) {
|
||||
let ajustement = game.system.rdd.calendrier.getAjustementAstrologique(heureNaissance);
|
||||
const current = game.system.rdd.calendrier.heureCourante();
|
||||
const ajustement = game.system.rdd.calendrier.getAjustementAstrologique(heureNaissance)
|
||||
const current = game.system.rdd.calendrier.heureCourante()
|
||||
ChatMessage.create({
|
||||
content: `A l'heure de <strong>${current.label}</strong>, le modificateur de Chance/Malchance est de <strong>${Misc.toSignedString(ajustement)}</strong> pour l'heure de naissance <strong>${heure.label}</strong>.`,
|
||||
whisper: ChatUtility.getGMs()
|
||||
|
Reference in New Issue
Block a user