diff --git a/CHANGELOG.md b/CHANGELOG.md index 1996b0b..fcf9ce5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ - Fixes for RnK : - Visibility mode is now consistent with the 1st message (public, private, gm...). - DiceSoNice will now not show the new dice(s) for explosive in non-public mode. +- Fixed Title's embed items tooltips. - Minor fixe on editable state. ## 1.3.2 - Ronin's Bubble diff --git a/system/scripts/actors/twenty-questions-dialog.js b/system/scripts/actors/twenty-questions-dialog.js index 6f8bab4..84732b4 100644 --- a/system/scripts/actors/twenty-questions-dialog.js +++ b/system/scripts/actors/twenty-questions-dialog.js @@ -175,7 +175,7 @@ export class TwentyQuestionsDialog extends FormApplication { super.activateListeners(html); // Commons - game.l5r5e.HelpersL5r5e.commonListeners(html); + game.l5r5e.HelpersL5r5e.commonListeners(html, this.actor); // BT Next html.find(".next").on("click", (event) => { diff --git a/system/scripts/helpers.js b/system/scripts/helpers.js index ae5be1a..ead7ffb 100644 --- a/system/scripts/helpers.js +++ b/system/scripts/helpers.js @@ -469,7 +469,12 @@ export class HelpersL5r5e { item = await HelpersL5r5e.getObjectGameOrPack({ id: propertyId, type: "Item" }); } else if (itemParentId) { // Embed Item - const parentItem = actor.items.get(itemParentId); + let parentItem; + if (actor) { + parentItem = actor.items?.get(itemParentId); + } else { + parentItem = game.items.get(itemParentId); + } if (!parentItem) { return; } diff --git a/system/scripts/items/item-sheet.js b/system/scripts/items/item-sheet.js index a1bded3..2002c42 100644 --- a/system/scripts/items/item-sheet.js +++ b/system/scripts/items/item-sheet.js @@ -113,7 +113,7 @@ export class ItemSheetL5r5e extends ItemSheet { super.activateListeners(html); // Commons - game.l5r5e.HelpersL5r5e.commonListeners(html); + game.l5r5e.HelpersL5r5e.commonListeners(html, this.actor); // Everything below here is only needed if the sheet is editable if (!this.isEditable) { diff --git a/system/templates/actors/character/advancement-others.html b/system/templates/actors/character/advancement-others.html index 8a1c725..542a302 100644 --- a/system/templates/actors/character/advancement-others.html +++ b/system/templates/actors/character/advancement-others.html @@ -1,5 +1,5 @@