diff --git a/module/actor.js b/module/actor.js index f7a319e7..c25acfa5 100644 --- a/module/actor.js +++ b/module/actor.js @@ -2112,7 +2112,8 @@ export class RdDActor extends Actor { xp: carac.xp } if (display) { - ChatUtility.createChatWithRollMode(this.name, { + ChatMessage.create({ + whisper: ChatUtility.getWhisperRecipientsAndGMs(this.name), content: await renderTemplate(`systems/foundryvtt-reve-de-dragon/templates/chat-actor-carac-xp.html`, checkXp) }); } @@ -2143,7 +2144,8 @@ export class RdDActor extends Actor { archetypeWarning: newCompData.data.niveau > compData.data.niveau_archetype } if (display) { - ChatUtility.createChatWithRollMode(this.name, { + ChatMessage.create({ + whisper: ChatUtility.getWhisperRecipientsAndGMs(this.name), content: await renderTemplate(`systems/foundryvtt-reve-de-dragon/templates/chat-actor-competence-xp.html`, checkXp) }); } @@ -2157,11 +2159,10 @@ export class RdDActor extends Actor { if (!this.isPersonnage()) return; let xpData = await this._appliquerExperience(rollData.rolled, rollData.selectedCarac.label, rollData.competence); if (xpData && display) { - let message = { + ChatMessage.create({ whisper: ChatUtility.getWhisperRecipientsAndGMs(this.name), content: await renderTemplate(`systems/foundryvtt-reve-de-dragon/templates/chat-actor-gain-xp.html`, xpData) - } - ChatMessage.create(message); + }); } }