Java Code Examples for org.bukkit.boss.BarColor#YELLOW

The following examples show how to use org.bukkit.boss.BarColor#YELLOW . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: BukkitBossBarFactory.java    From helper with MIT License 6 votes vote down vote up
private static BarColor convertColor(BossBarColor color) {
    switch (color) {
        case PINK:
            return BarColor.PINK;
        case BLUE:
            return BarColor.BLUE;
        case RED:
            return BarColor.RED;
        case GREEN:
            return BarColor.GREEN;
        case YELLOW:
            return BarColor.YELLOW;
        case PURPLE:
            return BarColor.PURPLE;
        case WHITE:
            return BarColor.WHITE;
        default:
            return convertColor(BossBarColor.defaultColor());
    }
}
 
Example 2
Source File: TimeLimitCountdown.java    From ProjectAres with GNU Affero General Public License v3.0 5 votes vote down vote up
@Override
public BarColor barColor(Player viewer) {
    long seconds = remaining.getSeconds();
    if(seconds > 60) {
        return BarColor.GREEN;
    } else if(seconds > 30) {
        return BarColor.YELLOW;
    } else {
        return BarColor.RED;
    }
}
 
Example 3
Source File: HuddleCountdown.java    From ProjectAres with GNU Affero General Public License v3.0 4 votes vote down vote up
@Override
public BarColor barColor(Player viewer) {
    return BarColor.YELLOW;
}
 
Example 4
Source File: MonostableFilter.java    From ProjectAres with GNU Affero General Public License v3.0 4 votes vote down vote up
@Override
public BarColor barColor(Player viewer) {
    return BarColor.YELLOW;
}