Class BoostBar
java.lang.Object
nl.minetopiasdb.api.boosters.objects.BoostBar
Management class for the booster bar
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddPlayerToBar(org.bukkit.entity.Player player) Show bossbar to playervoidCreate the bossbar for all the online playersorg.bukkit.boss.BossBargetBar(org.bukkit.entity.Player player, ActiveBoost lastActivated) Get the bossbar for the provided boost percentagevoidReload the content of the bossbarvoidMethod called on server shutdown to remove the bossbarvoidsetBarLeft(double part) Change the progress of the bossbar
-
Constructor Details
-
BoostBar
-
-
Method Details
-
createBossBarForAll
public void createBossBarForAll()Create the bossbar for all the online players -
addPlayerToBar
public void addPlayerToBar(org.bukkit.entity.Player player) Show bossbar to player- Parameters:
player- player
-
reloadBar
public void reloadBar()Reload the content of the bossbar -
removeBarOnShutdown
public void removeBarOnShutdown()Method called on server shutdown to remove the bossbar -
getBar
Get the bossbar for the provided boost percentage- Parameters:
player- random player needed for getting message.lastActivated- last activated boost- Returns:
- bossbar
-
setBarLeft
public void setBarLeft(double part) Change the progress of the bossbar- Parameters:
part- bar progress (time in minutes left / 60)
-