mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-12 03:31:07 +01:00
Cleanup
This commit is contained in:
parent
61d93297af
commit
1157b5286a
1 changed files with 12 additions and 16 deletions
|
|
@ -124,25 +124,21 @@ export default class SaveField extends fields.SchemaField {
|
||||||
*/
|
*/
|
||||||
static async updateSaveMessage(result, message, targetId) {
|
static async updateSaveMessage(result, message, targetId) {
|
||||||
if (!result) return;
|
if (!result) return;
|
||||||
const updateMsg = async function (message, targetId, result) {
|
|
||||||
// setTimeout(async () => {
|
const chatMessage = ui.chat.collection.get(message._id),
|
||||||
const chatMessage = ui.chat.collection.get(message._id),
|
changes = {
|
||||||
changes = {
|
flags: {
|
||||||
flags: {
|
[game.system.id]: {
|
||||||
[game.system.id]: {
|
reactionRolls: {
|
||||||
reactionRolls: {
|
[targetId]: {
|
||||||
[targetId]: {
|
result: result.roll.total,
|
||||||
result: result.roll.total,
|
success: result.roll.success
|
||||||
success: result.roll.success
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
}
|
||||||
await chatMessage.update(changes);
|
};
|
||||||
// }, 100);
|
await chatMessage.update(changes);
|
||||||
};
|
|
||||||
await updateMsg(message, targetId, result);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue