Files
bdot1andClaude Opus 5.5 f679318d70 v1.15.0: drag and drop only - everything ships with WhoDidIt, no CMD for players
Holybunny tested it: players had to run CMD files to get half the addon,
the "not downloaded yet" prompt sent them to the sync helper (which then
read 2,929 raid logs for ~50 minutes), and the built-in Chronicle logger
started logging for someone who had switched ChronicleCompanion off.

- Chronicle\, RollFor\ and DopingControl\ now ship in the repository at
  their pinned commits, each with a WDI_NOTICE.txt crediting its authors
  (DopingControl keeps its MIT LICENSE; ChronicleCompanion and RollFor
  state no licence: not under WhoDidIt's MIT licence, removed on request).
  The maintainer's decision.
- the built-in Chronicle logger logs nothing until the player says yes
  (asked the first time they enter a raid, or Start logging); until then
  its auto-logging is off. If the separate ChronicleCompanion is installed
  but switched off, the built-in copy stays off too.
- no player is told to run a CMD any more: missing parts say "download
  WhoDidIt again"; raid times aren't counted as missing (they come from the
  master feed); the Rankings bar shows the feed for players, and Sync now /
  helper states only for the master's characters
- the sync helper and AutoSync are maintainer-only: they check the WTF
  folder for a B.MASTERS character and otherwise explain and stop (-Force
  overrides; AutoSync-Off works for anyone). The helper no longer installs
  addons; EmbedUpdate.ps1 is the maintainer tool for moving pins.
- README (install = drag and drop), CLAUDE.md

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-08 00:00:04 +01:00

63 lines
1.8 KiB
Lua

if WDI_CHRON_SKIP then return end -- Fix the global gmatch function for older Lua versions
cstrjoin = string.join or function(delim, ...)
if type(arg) == 'table' then
return table.concat(arg, delim)
else
return delim
end
end
cgmatch = string.gmatch or string.gfind
cunpack = unpack or table.unpack
cmatch = string.match or function (s, pattern, init)
init = init or 1
-- try to find captures
local results = { string.find(s, pattern, init) }
if table.getn(results) > 2 then
-- drop the start/end positions, keep captures
local captures = {}
for i = 3, table.getn(results) do
table.insert(captures, results[i])
end
return cunpack(captures)
elseif results[1] and results[2] then
-- no captures, return the matched substring
return string.sub(s, results[1], results[2])
end
return nil
end
-- Compare version strings like "1.5.2" > "1.5"
---@param v1 string
---@param v2 string
---@return number
function ChronicleCompareVersion(v1, v2)
-- Returns: 1 if v1 > v2, -1 if v1 < v2, 0 if equal
local function split(str)
local parts = {}
for num in cgmatch(str, "(%d+)") do
table.insert(parts, tonumber(num))
end
return parts
end
local p1, p2 = split(v1), split(v2)
local maxLen = math.max(table.getn(p1), table.getn(p2))
for i = 1, maxLen do
local n1 = p1[i] or 0
local n2 = p2[i] or 0
if n1 > n2 then return 1 end
if n1 < n2 then return -1 end
end
return 0
end
function Chronicle_NampowerVersion()
local version = ""
if GetNampowerVersion then
local major, minor, patch = GetNampowerVersion()
if major then version = major .. "." .. (minor or 0) .. "." .. (patch or 0) end
end
return version
end