Progress must be between 0.0 and 1.0 (NaN) error during PlayerItemConsumeEvent #319
Closed
3 tasks done
Labels
type: bug
Something is not working as intended
Server software and version
Paper 1.21.1-96-4514c71 (MC: 1.21.1)
Expected behavior
The BossBar should update normally, showing the player's XP progress after consuming an item without causing any errors.
Actual behavior
An exception is thrown (
IllegalArgumentException: Progress must be between 0.0 and 1.0
), causing the event to fail, and the XP BossBar is not displayed properly.How to reproduce
Additional information
The error seems related to how the plugin calculates the progress for the BossBar, potentially due to a divide-by-zero or other calculation error, resulting in a NaN value. This happens consistently upon item consumption by players.
Agreements
The text was updated successfully, but these errors were encountered: