Skip to content

feat: add PlayerMaxManaChangeEvent - #1780

Merged
Travja merged 2 commits into
devfrom
split/1677-player-max-mana-event
Jul 23, 2026
Merged

feat: add PlayerMaxManaChangeEvent#1780
Travja merged 2 commits into
devfrom
split/1677-player-max-mana-event

Conversation

@Travja

@Travja Travja commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Split out of #1677 (piece 7 of 8 — see that PR for the full breakdown).

What

Fires a new PlayerMaxManaChangeEvent after Fabled computes a player's max mana (including class bonuses and attribute scaling), letting other plugins apply additional flat bonuses via setMaxMana() before it's applied. The result is clamped to a minimum of 0.

Why split out separately

Small, additive, self-contained API surface — a new event class plus one call site. No dependency on any other piece of #1677.

Testing

Could not build locally (private Maven repo unreachable in this sandbox). Needs manual/CI verification that max mana still computes correctly with no listeners attached, and that a listener calling setMaxMana() takes effect.


Generated by Claude Code

Split out of #1677 (piece 7 of 8).

Fires a new PlayerMaxManaChangeEvent after Fabled computes a player's
max mana (including class bonuses and attribute scaling), letting other
plugins apply additional flat bonuses via setMaxMana() before it's
applied. The result is clamped to a minimum of 0.
@Travja Travja mentioned this pull request Jul 21, 2026
Covers that updatePlayerStat() fires PlayerMaxManaChangeEvent, that a
listener's setMaxMana() bonus is reflected in the player's final max
mana, and that a listener setting a negative value is clamped to 0.
@Travja
Travja merged commit 31ae3ac into dev Jul 23, 2026
3 checks passed
@Travja
Travja deleted the split/1677-player-max-mana-event branch July 23, 2026 02:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants