use of com.voxelgameslib.voxelgameslib.components.map.Map in project VoxelGamesLibv2 by VoxelGamesLib.
the class MapInfoFeature method enable.
@Override
public void enable() {
MapFeature mapFeature = getPhase().getFeature(MapFeature.class);
Map map = mapFeature.getMap();
ScoreboardFeature scoreboardFeature = getPhase().getFeature(ScoreboardFeature.class);
Scoreboard scoreboard = scoreboardFeature.getScoreboard();
for (String mode : map.getInfo().getGamemodes()) {
scoreboard.createAndAddLine(mode);
}
scoreboard.createAndAddLine(ChatColor.YELLOW + "" + ChatColor.BOLD + "Gamemodes: ");
scoreboard.createAndAddLine(map.getInfo().getAuthor());
scoreboard.createAndAddLine(ChatColor.YELLOW + "" + ChatColor.BOLD + "Author: ");
scoreboard.createAndAddLine(map.getInfo().getDisplayName());
scoreboard.createAndAddLine(ChatColor.YELLOW + "" + ChatColor.BOLD + "Map: ");
}
Aggregations