Show a Top 10 List Using Placeholders
AJ Leaderboards works through PlaceholderAPI. Any numeric placeholder can become a leaderboard, and you display its entries by position with the plugin's own placeholders.
How the placeholders are built
The general pattern is:
%ajlb_lb_<board>_<position>_<type>%
- board: the placeholder you want to rank, written without its percent signs. For example, a money placeholder from your economy plugin, or a playtime or kills placeholder from a statistics plugin.
- position: 1 for first place, 2 for second, and so on.
- type: what to show. Common types are
nameandvalue. Prefix and suffix types are also available.
For first place you would use one placeholder for the name and another for the value.
Steps
1. Confirm PlaceholderAPI is working and the placeholder you want to rank returns a number for a player.
2. In a hologram, scoreboard, tab list or chat-format plugin that supports PlaceholderAPI, add one line per position. Each line combines a name placeholder and a value placeholder, e.g. #1 <name> - <value>.
3. Repeat for positions 2 to 10, changing only the position number.
4. Open the line in-game. A new board may take a short while to fill, because the plugin has to start tracking players first.
Tips
- If a line shows nothing, the board may not have data yet. Check that online players actually return a value for the base placeholder.
- Run
/ajlb helpto see the exact subcommands your install supports, such as reloading or listing boards.