mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-07-23 02:49:55 +02:00
[Fix] Reload Fixes (#2099)
This commit is contained in:
parent
d50545af4e
commit
7f61715adf
10 changed files with 150 additions and 77 deletions
|
|
@ -139,7 +139,7 @@ export default class DHRoll extends BaseRoll {
|
|||
item?.system.hasReload &&
|
||||
action?.type === 'attack' &&
|
||||
reloadSetting === CONFIG.DH.SETTINGS.reloadChoices.auto.id;
|
||||
const needsReload = useReload ? await action?.handleReload?.() : false;
|
||||
const reloadResult = useReload ? await action?.handleReload?.() : {};
|
||||
|
||||
const cls = getDocumentClass('ChatMessage'),
|
||||
msgData = {
|
||||
|
|
@ -148,7 +148,11 @@ export default class DHRoll extends BaseRoll {
|
|||
title: roll.title,
|
||||
speaker: cls.getSpeaker({ actor: roll.data?.parent }),
|
||||
sound: config.mute ? null : CONFIG.sounds.dice,
|
||||
system: { ...config, actionDescription, needsReload },
|
||||
system: {
|
||||
...config,
|
||||
actionDescription,
|
||||
reloadCheckValue: reloadResult.rollValue
|
||||
},
|
||||
rolls: [roll]
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue