mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-13 20:21:06 +01:00
Merged with main
This commit is contained in:
commit
264a79f6e8
37 changed files with 1359 additions and 1493 deletions
|
|
@ -240,22 +240,26 @@ export default class DhpActor extends Actor {
|
|||
}
|
||||
|
||||
const cls = getDocumentClass('ChatMessage');
|
||||
const systemData = {
|
||||
title: game.i18n.format('DAGGERHEART.Chat.DamageRoll.Title', { damage: title }),
|
||||
roll: rollString,
|
||||
damage: {
|
||||
total: rollResult.total,
|
||||
type: damage.type
|
||||
},
|
||||
dice: dice,
|
||||
modifiers: modifiers,
|
||||
targets: targets
|
||||
};
|
||||
const msg = new cls({
|
||||
type: 'damageRoll',
|
||||
user: game.user.id,
|
||||
sound: CONFIG.sounds.dice,
|
||||
system: {
|
||||
title: game.i18n.format('DAGGERHEART.Chat.DamageRoll.Title', { damage: title }),
|
||||
roll: rollString,
|
||||
damage: {
|
||||
total: rollResult.total,
|
||||
type: damage.type
|
||||
},
|
||||
dice: dice,
|
||||
modifiers: modifiers,
|
||||
targets: targets
|
||||
},
|
||||
content: 'systems/daggerheart/templates/chat/damage-roll.hbs',
|
||||
system: systemData,
|
||||
content: await foundry.applications.handlebars.renderTemplate(
|
||||
'systems/daggerheart/templates/chat/damage-roll.hbs',
|
||||
systemData
|
||||
),
|
||||
rolls: [roll]
|
||||
});
|
||||
|
||||
|
|
@ -349,11 +353,14 @@ export default class DhpActor extends Actor {
|
|||
const cls = getDocumentClass('ChatMessage');
|
||||
const msg = new cls({
|
||||
user: game.user.id,
|
||||
content: await renderTemplate('systems/daggerheart/templates/chat/damage-roll.hbs', {
|
||||
roll: roll.formula,
|
||||
total: roll.result,
|
||||
type: action.damage.type
|
||||
})
|
||||
content: await foundry.applications.handlebars.renderTemplate(
|
||||
'systems/daggerheart/templates/chat/damage-roll.hbs',
|
||||
{
|
||||
roll: roll.formula,
|
||||
total: roll.result,
|
||||
type: action.damage.type
|
||||
}
|
||||
)
|
||||
});
|
||||
|
||||
cls.create(msg.toObject());
|
||||
|
|
@ -368,11 +375,14 @@ export default class DhpActor extends Actor {
|
|||
const cls = getDocumentClass('ChatMessage');
|
||||
const msg = new cls({
|
||||
user: game.user.id,
|
||||
content: await renderTemplate('systems/daggerheart/templates/chat/healing-roll.hbs', {
|
||||
roll: roll.formula,
|
||||
total: roll.result,
|
||||
type: action.healing.type
|
||||
})
|
||||
content: await foundry.applications.handlebars.renderTemplate(
|
||||
'systems/daggerheart/templates/chat/healing-roll.hbs',
|
||||
{
|
||||
roll: roll.formula,
|
||||
total: roll.result,
|
||||
type: action.healing.type
|
||||
}
|
||||
)
|
||||
});
|
||||
|
||||
cls.create(msg.toObject());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue