PAPi Examples
Configure new Statistics (leaderboard using PAPi)
First you need to make sure placeholder you're using is dependent on player and that it returns basic number. (allowed formats: 0, 0.0 it cannot be text!) (good expansion for many statistics: https://github.com/PlaceholderAPI/PlaceholderAPI/wiki/Placeholders#statistic)
Second, you have to stop the server. After you stopped the server navigate to: server-root/plugins/HolographicPlaceholders folder. Where you'll see the following files:
config.yml
signs.yml
data.yml
To configure new leaderboard you have to open config.yml (notepad++ program is recommended for better readability). In config.yml you'll see the following settings:
system ( edited by the plugin do not edit)
addons (here you can enable different addons provided by the plugin)
placeholder-addons (you need to edit this part for custom leaderboards)
All other addons such as (PAPi, Baltop, baltopv2)
and config version
You have to go to section placeholder-addons (it should be something like provided code block):
To add new leaderboard you can copy the configuration (marked as from here, to here, on the code block), now search for your desired placeholder (if you haven't already). And replace the name of addon (marked on code block) After that you can configure other sections of the settings such as size, interval. If your placeholder returns time (must be in seconds) you can cange value type to time instead of number. After you complete the setup you can start the server.
Placeholders you now use on hologram are:
{hpe-<papi placeholder without %%>-#-user}
{hpe-<papi placeholder without %%>-#-value}
Replace the # with the position on the leaderboard (1,2,3,4,5...)
Example of placeholders for the provided code block:
{hpe-statistics_deaths-1-user} - displays name of the top 1 user on deaths leaderboard
{hpe-statistics_deaths-1-value} - displays the deaths of the top 1 user on leaderboard
Last updated