-
-
Notifications
You must be signed in to change notification settings - Fork 103
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add boss bar animation when it appears #300
Conversation
# Conflicts: # bukkit/src/main/java/dev/aurelium/auraskills/bukkit/ui/BossBarManager.java
Is the animation really needed in the case where the player already has the boss bar visible? Because it already "animates" between progress when the previous XP amount is already showing. Maybe add some way to detect if there's one actively showing for that skill and set the progress immediately? |
Maybe. It would require an
The only way to check is using the data in |
I just added an option to toggle it off since detecting if its showing wasn't as straightforward as I thought. Can you verify that it is still working as intended? |
Unfortunately it does not, you didn't account for the fact that |
In 584eecd I just changed code flow and comments to a way I feel would be easier to comprehend |
I actually made ANIMATE_PROGRESS a class field that didn't update on reload on purpose so it would be slightly more performant, especially since the boss bar is known to be a source of lag on larger servers. I would prefer if it was set back to a class field and updated through the existing BossBarManager#loadOptions method which is already called by ReloadExecutor. |
…eload" This reverts commit c58baff.
What's the reasoning behind making it |
You can make it non-final and update it in loadOptions. |
Here is a brief summary of the changes:
bossBar#progress(float)
method.handleNewBossBar
andhandleExistingBossBar
to take progress instead of currentXp and levelXp, and progress as float instead of doublenote that the first commit bf80e34 should have been amended but git complained with merge conflicts, so it looks like it got duplicated at 10c922e