ENhance actor sheet with roll messages
This commit is contained in:
@@ -86,6 +86,8 @@ export default class AwEActorSheet extends HandlebarsApplicationMixin(foundry.ap
|
||||
*/
|
||||
async _onRoll(event) {
|
||||
if (this.isEditMode) return
|
||||
// Skip if the element has a registered data-action (handled by the action system)
|
||||
if (event.currentTarget.dataset.action) return
|
||||
const attributeId = event.currentTarget.dataset.attributeId
|
||||
if (!attributeId) return
|
||||
await this.document.rollAttribute(attributeId)
|
||||
@@ -233,6 +235,7 @@ export default class AwEActorSheet extends HandlebarsApplicationMixin(foundry.ap
|
||||
static async #onItemDelete(event, target) {
|
||||
const itemUuid = target.getAttribute("data-item-uuid")
|
||||
const item = await fromUuid(itemUuid)
|
||||
if (!item) return
|
||||
await item.deleteDialog()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user