Name | Scoreboard |
Syntax | scoreboard ({add}/remove) (viewers:<player>|...) (lines:<player>/<text>|...) (id:<value>/player/{main}) (objective:<value>) (criteria:<criteria>/{dummy}) (score:<#>) (displayslot:<value>/{sidebar}/none) (displayname:<name>) (rendertype:<type>) |
Short Description | Add or removes viewers, objectives and scores from scoreboards. |
Full Description | Lets you make players see a certain scoreboard and then a certain objective in that scoreboard.
Please note that a 'scoreboard' is NOT a 'sidebar' - if you want that thing where text is on the right side of the screen, use sidebar. 'Scoreboard' is the underlying internal system that powers sidebars, below_name plates, team prefixing, and a lot of other systems. Generally, you should avoid using this command directly. The ID can be 'main' for the global default scoreboard, 'player' for the attached player's current scoreboard, or any other value for a custom named scoreboard. There are currently three slots where objectives can be displayed: in the sidebar on the right of the screen, below player names and in the player list that shows up when you press Tab. The names of these slots can be found here: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/scoreboard/DisplaySlot.html Every objective has several lines of scores. Technically, the lines track players, but fake player names can be used by Denizen to let you call the lines anything you want. When using the sidebar as the display slot, all the scores set for an objective will be displayed there, but you will need to put actual player names in the lines to be able to use the below_name display slot (which displays each player's score underneath his/her name) and the player_list display slot (which displays each player's score to the right of his/her name in the player list). If you do not specify a display slot, the sidebar will be used. You can also use "none" as the display slot if you want to add a hidden objective without automatically making it get displayed. If the object already exists, and you don't specify the display slot, it will use the existing setting. When setting an objective, you can also optionally set the display name by using the "displayname:" argument. "Rendertype" can be "INTEGER" or "HEARTS". Defaults to integer. You can set scores manually, or you can use different Minecraft criteria that set and update the scores automatically. A list of these criteria can be found here: https://minecraft.wiki/w/Scoreboard#Objectives If the object already exists, and you don't specify the criteria, it will use the existing setting. You can use the "remove" argument to remove different parts of scoreboards. The more arguments you use with it, the more specific your removal will be. For example, if you only use the "remove" argument and the "id" argument, you will completely remove all the objectives in a scoreboard, but if you specify an objective as well, you will only delete that one objective from that scoreboard, and if you also specify certain lines, you will only delete those specific lines from that objective. Similarly, if you use the "remove" argument along with the "id" and "viewers" arguments, you will only remove those viewers from the scoreboard, not the entire scoreboard. |
Related Tags | <server.scoreboard[(<board>)].exists> Returns whether a given scoreboard exists on the server.
<server.scoreboard[(<board>)].team[<team>].members> Returns a list of all members of a scoreboard team. Generally returns as a list of names or text entries. (...)
<PlayerTag.scoreboard_id> Returns the ID of the scoreboard from scoreboard that a player is currently viewing, if any.
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Usage Example |
|
Group | server |
Source | https://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/server/ScoreboardCommand.java#L34 |