Skip to content

Commit

Permalink
DSN immediatelyShowRoll compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
cswendrowski committed Nov 15, 2020
1 parent d31204e commit cb47bdd
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
6 changes: 3 additions & 3 deletions module.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
"name": "tabbed-chatlog",
"title": "Tabbed Chatlog",
"description": "Splits the Chatlog into In Character (per scene), Rolls (per scene), and Out of Character (global).",
"version": "1.5.5",
"version": "1.5.6",
"minimumCoreVersion": "0.6.2",
"compatibleCoreVersion": "0.7.5",
"compatibleCoreVersion": "0.7.7",
"author": "Cody Swendrowski <[email protected]>",
"esmodules": [
"./tabbed-chatlog.js"
Expand All @@ -28,5 +28,5 @@
],
"url": "https://github.com/cswendrowski/FoundryVTT-tabbed-chatlog",
"manifest": "https://github.com/cswendrowski/FoundryVTT-tabbed-chatlog/releases/download/latest/module.json",
"download": "https://github.com/cswendrowski/FoundryVTT-tabbed-chatlog/releases/download/1.5.5/module.zip"
"download": "https://github.com/cswendrowski/FoundryVTT-tabbed-chatlog/releases/download/1.5.6/module.zip"
}
7 changes: 7 additions & 0 deletions tabbed-chatlog.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ Hooks.on("renderChatMessage", (chatMessage, html, data) => {
}
else if (data.message.type == 5 && sceneMatches) {
if (!html.hasClass('gm-roll-hidden')) {
if (game.dice3d && !game.settings.get("dice-so-nice", "immediatelyDisplayChatMessages")) return;
html.css("display", "list-item");
}
}
Expand Down Expand Up @@ -148,6 +149,12 @@ Hooks.on("renderChatMessage", (chatMessage, html, data) => {
}
});

Hooks.on("diceSoNiceRollComplete", (id) => {
if (currentTab != "rolls") {
$("#chat-log .message[data-message-id=" + id + "]").css("display", "none");
}
});

Hooks.on("createChatMessage", (chatMessage, content) => {
var sceneMatches = true;

Expand Down

0 comments on commit cb47bdd

Please sign in to comment.