diff --git a/CHANGELOG.md b/CHANGELOG.md index 377be76..e6c4d8f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ # Changelog +## 1.3.5 - DsN hotfix +- Fixed a bug introduced by DiceSoNice 4.2.1 : context in "diceSoNiceRollStart" hook rebuild data and lost what we needed. The consequence is 3d dice flood a lot in RnK. + ## 1.3.4 - Compendiums Update - Fixed a bug with sheet item drop introduced in previous version. - Added FoV English Opportunities usage. diff --git a/system/scripts/hooks.js b/system/scripts/hooks.js index 616e8ae..c8e1d6d 100644 --- a/system/scripts/hooks.js +++ b/system/scripts/hooks.js @@ -259,7 +259,10 @@ export default class HooksL5r5e { * @param {object} context */ static diceSoNiceRollStart(messageId, context) { - if (context.roll.l5r5e?.history) { + // In DsN 4.2.1+ the roll is altered in context. + // So we need to get the original message instead of "context.roll.l5r5e?.history" + const message = game.messages.get(messageId); + if (message?._roll?.l5r5e?.history) { context.blind = true; } } diff --git a/system/system.json b/system/system.json index 4f3ae52..478146e 100644 --- a/system/system.json +++ b/system/system.json @@ -4,8 +4,8 @@ "description": "This is an authorised multilingual game system En|Fr|Es, for Legend of the Five Rings (5th Edition) by Edge Studio
- Join the official Discord server: Official Discord
- Rejoignez la communauté Francophone: Francophone Discord
", "url": "https://gitlab.com/teaml5r/l5r5e", "manifest": "https://gitlab.com/teaml5r/l5r5e/-/raw/master/system/system.json", - "download": "https://gitlab.com/teaml5r/l5r5e/-/jobs/artifacts/v1.3.4/raw/l5r5e.zip?job=build", - "version": "1.3.4", + "download": "https://gitlab.com/teaml5r/l5r5e/-/jobs/artifacts/v1.3.5/raw/l5r5e.zip?job=build", + "version": "1.3.5", "minimumCoreVersion": "0.8.5", "compatibleCoreVersion": "0.8.9", "manifestPlusVersion": "1.0.0",