Documentation Index
Fetch the complete documentation index at: https://velas.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
VelaBoard’s API is built around three core objects: ScoreboardHandler, Scoreboard, and a sidebar. This page shows you the complete flow to display a sidebar to a player and a shared sidebar visible to multiple players.
A PlayerSidebar is scoped to a single player. Use it for per-player HUDs that show individual data like score or level.
Get the handler
Obtain the ScoreboardHandler from the API entry point.ScoreboardHandler handler = ScoreboardAPI.getHandler();
Create a scoreboard
Create a Scoreboard instance through the handler.Scoreboard board = handler.createScoreboard();
Register the player
Add the player to the scoreboard before creating any sidebars for them. Create the sidebar
Create a PlayerSidebar with a display title.PlayerSidebar sidebar = board.createPlayerSidebar("§6My Plugin");
Set lines
Populate the sidebar lines. Line 0 is the top line.sidebar.setLine(0, "§7Score: §f100");
sidebar.setLine(1, "§7Level: §f5");
Assign and show
Assign the sidebar to the player, then call show() to display it.sidebar.setPlayer(player);
sidebar.show();
A SharedSidebar shows the same content to multiple players at once. Use it for server-wide information like online player count or a global event status.
// Create a shared sidebar with an ID and a display title
SharedSidebar shared = board.createSharedSidebar("server-info", "§bServer Info");
// Set lines
shared.setLine(0, "§7Online: §f" + Bukkit.getOnlinePlayers().size());
// Add a player and show to all registered players
shared.addPlayer(player);
shared.show();
To show the sidebar to a specific player by UUID without adding them to the default roster, use showTo(UUID):
shared.showTo(player.getUniqueId());
Call this code from within a Bukkit event handler such as PlayerJoinEvent,
or at any point after the player is fully online. Calling addPlayer or
show before the player has joined will have no effect.
You can use § color codes or Adventure API text components in both sidebar
titles and line content. For dynamic lines that update over time, call
setLine again with new content and re-call show() to refresh the display.