Here we go again, 5000 lines added and 500 removed...
Official addons will be updated to work with this version right after this is released.
BodyHealth v4.0.0
Renamed 'BODY' (body part) to 'TORSO'. Your config, language files, the selected storage, and BetterHud's configuration will automatically be migrated to reflect that change, but if you are using body parts anywhere externally, you need to migrate that manually.
Retextured all HUD elements of the 'DAMAGED' state to match the quality standard imposed by the four other states.
Added Folia support! BetterHud should already work on Folia as-is, for PlaceholderAPI, you will need to use a fork that supports Folia, until the main version does:
https://github.com/Folia-Inquisitors/PlaceholderAPI-Folia/releases/tag/Tango
NOTE: On Folia, it is not possible to reliably remove all effects from a player on shutdown, because the global thread is no longer available. Instead, we store all currently active effects per player and remove them the next time the player joins. On PaperMC and its forks, you can toggle this behavior with a new
remove-effects-on-shutdown setting in config.yml.
Added an optional 'enabled' property to permission overrides that allows you to disable them and disabled the default overrides.
Added a data command ('/bh data save/dump/erase/move') that allows for asynchronous data management and easy storage type changes.
Added HUD scaling! You can now scale BodyHealth's HUD with a new config option at
display.betterhud.position.scale (default is 1.5).
Added a debug command that allows toggling both debug modes, as well as dumping debug information that could be useful for diagnosing issues.
Added a translated variant of the state placeholder ('%bodyhealth_state_<part>_translated%') — outputs new translations that may contain other placeholders and formatting.
Improved the default body-damage configuration to not apply the damage you take when dying to all of your body parts.
Improved BodyHealth's UpdateChecker to show name and current version in "You are running the latest version" messages.
Improved the default effect configuration further, aiming to showcase all effects while still making sense in a survival environment.
Improved tips at the end of config.yml to include instructions on how to merge BetterHud's pack with ItemsAdder for those who need that.
Improved Debug logging in AddonManager so you better understand what went wrong with an addon, if problems with one arise.
Fixed default prefix missing a formatting-reset at the end.
Fixed the UpdateChecker's first empty line not being shown in some consoles.
Fixed BodyHealth's calculations not considering the change in head height caused by sneaking.
Fixed some parts of the plugin still not using the by now no longer new, but still robust error logging logic.
Fixed some effects not being listed as ongoing, despite them being active (didn't matter before v4).
Fixed the Japanese language translation (submitted by jekyllh, thank you!).
Fixed many other small inaccuracies and updated many dependencies.
For Developers
Renamed BodyPart.BODY to BodyPart.TORSO.
Renamed BodyHealthAddon#onAddonPreEnable to BodyHealthAddon#onAddonLoad (it is now called onLoad).
Renamed BodyHealthAddon#onBodyHealthReload to BodyHealthAddon#onAddonReload.
Fixed missing
@NotNull annotations in BodyPartHealthChangeEvent.