mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-12 03:31:07 +01:00
.
This commit is contained in:
parent
36eac51041
commit
8881f14153
8 changed files with 84 additions and 13 deletions
|
|
@ -401,8 +401,18 @@ class RegisteredTriggers extends Map {
|
|||
if (currentActor?.uuid !== actor) continue;
|
||||
|
||||
for (let command of commands) {
|
||||
const commandUpdates = await command(...args);
|
||||
if (commandUpdates?.length) updates.push(...commandUpdates);
|
||||
try {
|
||||
const commandUpdates = await command(...args);
|
||||
if (commandUpdates?.length) updates.push(...commandUpdates);
|
||||
} catch (_) {
|
||||
const triggerName = game.i18n.localize(CONFIG.DH.TRIGGER.triggers[trigger].label);
|
||||
ui.notifications.error(
|
||||
game.i18n.format('DAGGERHEART.CONFIG.Triggers.triggerError', {
|
||||
trigger: triggerName,
|
||||
actor: currentActor?.name
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue