Repository navigation
feat(HealthColors): Introduces shared ownership with DeathTracker - #2375
Open
steverobertsuk wants to merge 6 commits into
Open
steverobertsuk wants to merge 6 commits into
steverobertsuk wants to merge 6 commits into
Conversation
DeathTracker 1.0 sets the dead, dying, stable and bloodied markers and tracks death saves itself. With both Mods running, HealthColors also added its Red X or dying marker to the same tokens, so the two fought over markers and HealthColors marked PCs nobody controlled as dead. When DeathTracker 1.0 or later is installed (it exposes isManagingDeathSaves; 0.1 does not), HealthColors now adds no dead, dying or stable marker and its Death Save Integration stays idle: no field watching, no polling, and `!aura deathsaves sync` says why. It still colours tokens and plays the death sound. The GM menu, the help handout (DeathTracker detected or not installed) and the startup log say so. Released as 2.5.0, with its snapshot. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
HealthColors and DeathTracker 1.0 can both track death saves with the dying, stable and dead markers, colour tokens by health and play hurt and heal effects. Until now HealthColors simply stood aside on death saves whenever DeathTracker was installed, with no way to choose. A new "Who handles what" section at the top of the !aura menu, and !aura owner <deathsaves|colours|effects> <HealthColors|DeathTracker|off>, choose which Mod does each, or neither. The choice is kept once in state.ModOwners, which DeathTracker reads and writes as well, so the two Mods always agree, and a change in either refreshes both Mods' tokens (the public API gains ownersChanged for this). With DeathTracker installed, DeathTracker starts with death saves and HealthColors with the colours and effects; without it, HealthColors does all three. When HealthColors does not handle an area it leaves it alone: no 0 HP markers and an idle Death Save Integration, no aura or tint (its own is taken off), or no heal and hurt effects. The death sound and nameplates stay HealthColors'. The help handout, menu notes and startup log show the choice. Still released as 2.5.0, with its snapshot. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
The README gains the "Who handles what" menu section, the !aura owner command and a table of the three shared areas, and the DeathTracker integration now describes the shared choice. TESTING.md checks the starting choice and hand-overs from both Mods' menus. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
… Journal The Help & Reference handout now use the plain HealthColors icon from Roll20's file store as their journal icon (the handout avatar). The icon is set when a handout is created and added to handouts from earlier versions, so existing games get it too. Roll20 stores the avatar as max.webp with a number, so a handout counts as having the icon when its avatar contains the image's path. Only the webp files exist (thumb.png is a 404), so the URL uses thumb.webp. The root script and the 2.5.0 snapshot stay identical. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
… handout Roll20 always stores a handout's journal icon as the full-size file, whatever size the Mod asks for, and shows that file at its natural size at the top of an open handout. The HealthColors icon was a 1024 pixel upload, so it filled the handout above the text. The icon now points at a 100 pixel copy of the same artwork. Handouts from earlier builds are matched on the image path, so they change to the small icon the next time the Mod starts. The 2.5.0 copy is updated with the script. The version number is unchanged. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements a shared ownership system with DeathTracker (v1.0+) to co-manage death saves, token colours, and particle effects. HealthColors now optionally defers control over these areas to DeathTracker or disables them entirely, preventing conflicts. Also updates the help handout to display the HealthColors icon and include detailed documentation on the new ownership system.
[2.5.0] – 2026-11-04
Added
!auramenu, and!aura owner <deathsaves|colours|effects> <HealthColors|DeathTracker|off>, choose which Mod does each, or neither. The choice is stored once (state.ModOwners) and DeathTracker's settings show and change the same values, so the two Mods always agree; changing it in either refreshes both Mods' tokens.!aura deathsaves syncsays who handles them). When it does not handle colours it adds no aura or tint and takes its own off; when it does not handle effects it plays no heal or hurt FX. The death sound and nameplates are always HealthColors'.HealthColors.ownersChanged(), which DeathTracker calls after a change.Breaking Changes
None. This update is additive and enhances compatibility with DeathTracker.
Signed-off-by: Steve Roberts steve@shadowcomputers.co.uk