diff --git a/main.lua b/main.lua index aff42ae..b7cde09 100644 --- a/main.lua +++ b/main.lua @@ -675,6 +675,11 @@ function Bookhoard:getContextText() end if not text or text == "" then return "" end + local char_offset = tonumber(xp:match("text%(%)%.?(%d+)")) or 0 + if char_offset > 0 and char_offset < #text then + text = text:sub(char_offset + 1) + end + if #text > 100 then text = text:sub(1, 100) end