/stats
Show a player's statistics
/stats [player]
Shows each player's statistics and server-wide leaderboards in menus. Players use /stats, /leaderboards and /baltop.
Main commands
/stats/stats Alex/leaderboards/leaderboards kills/leaderboards playtime/baltopDo I need DCurrency?
Only for the points ranking. Everything else works without it.
Why is a new player missing from a ranking?
Players with a value of zero are hidden by default (ranking.include-zero), and rankings refresh about once a minute.
Can I stop players using the leaderboards?
Yes. /leaderboards needs dstats.leaderboards and /baltop needs dstats.baltop. Both are on for everyone by default, so remove them from a rank to close the feature.
Where do the money numbers come from?
From the economy that DCore provides, the same one used by the other Devamy plugins.
Menus and messages come from the default DStats files. Run a command, click an example, or pick a menu.
No menu open. Run a command below or pick a menu from the list.
<name> you must fill in[name] optionalword typed as shown
Show a player's statistics
/stats [player]also /lb
Show every global leaderboard
/leaderboards/leaderboards money/leaderboards points/leaderboards kills/leaderboards deaths/leaderboards playtime/leaderboards mobkills/leaderboards mined/leaderboards placedNeeds dstats.leaderboards, which everyone has by default.
also /balancetop, /moneytop
Show the richest players
/baltopNeeds dstats.baltop, which everyone has by default.
Who has each one before you set anything up is in the middle column.
| Permission | Default | Grants |
|---|---|---|
| dstats.leaderboards | Everyone | Read the global leaderboards |
| dstats.baltop | Everyone | Open the balance top |
plugins/DStats/settings.yml
Stats: /stats shows a player's numbers, /lb and /baltop show the server rankings. Edit, then restart the server. This plugin only shows data and stores almost none of its own (only which playtime level a player was paid for), so turning it off loses nothing. Help and support: https://discord.devamy.net or dstudios@devamy.net
ENLanguage of the plugin's texts.
EN = English FR = French ES = Spanish
'�B5FF&lSMP &8| 'Text shown in front of every chat message from this plugin. Use '' for no prefix. & colour codes and &#RRGGBB work.
falseDo blocks broken, blocks placed and mobs killed in creative mode count in /stats?
false = no, so a builder in creative cannot top the blocks-placed ranking true = yes
--- The /lb overview ---
'---'What a ranking row shows when nobody holds that place yet.
45How many players each ranking holds in total, across all pages.
60How often the rankings are sorted again, in seconds. Menus read the finished list, so opening one never lags the server. A minute behind is not noticeable.
--- The full ranking menus (/lb <category> and /baltop) ---
60How often the full rankings are sorted again, in seconds. Only changes how fresh the numbers are.
falseAre players with a value of zero listed?
false = no, so the pages are not full of players who joined once and never did anything true = yes
10Player heads show skins. If a skin cannot be found, wait this many minutes before asking again. Until then that player has the plain default head.
2How many skin lookups may run at the same time. Lower it if the skin service starts refusing requests.
1000The shortest gap between two skin lookups, in milliseconds (1000 = 1 second). Mojang refuses servers that ask too fast. If two lookups in a row fail, lookups pause for a minute. Skins that were found are saved in data/skins.yml. Bedrock players are never looked up at Mojang.
--- Holograms at spawn --- This is the second of two ways to show the rankings on a board, and it is off.
Way 1 (recommended): the DHolograms plugin. It reads these placeholders, one line per rank:
%dstats_top_money_1_name% %dstats_top_money_1_value% name and value of rank 1 %dstats_top_money_1% the whole row, like "#1 Notch | $105.13K" %dstats_top_money_size% how many ranks exist
Statistics: money, points, kills, deaths, playtime, mobkills, mined, placed. The layout is in plugins/DHolograms/holograms/, so you can edit it without touching this plugin.
Way 2 (this section): push the rankings into plain Minecraft text_display entities. Summon one per board with the tag of that board, for example:
/summon text_display ~ ~2 ~ {Tags:["lb_money"],billboard:"vertical"}then set enabled: true. Use it only if you do not run a hologram plugin, or every board is drawn twice.
falsetrue = fill the text_display entities below.
'minecraft:spawn'The world the text_display entities stand in, written as Minecraft names it (minecraft:overworld, ...).
10How many ranks each board shows.
One entry per board. tag = the tag of the entity, statistic = what it ranks, title and icon = its heading, color = its colour.
lb_moneymoney'MONEY''$''#6BFF00'lb_pointspoints'%currency_upper%'You can use: %currency_upper% (the points currency name in capitals). Type plain text to fix the name.
'★''#00E0FF'lb_killskills'KILLS''🗡''#FF2121'lb_playtimeplaytime'PLAYTIME''⌚''#D2FF00'--- Playtime levels --- Players climb a level each time their total playtime passes a number of hours, and get a reward for it. Off by default. When you switch it on, players who already have more playtime than a level collect the reward for every level they have passed, once, the next time the check runs. Each reward is given only once per player. Edit, then restart the server.
falsetrue = levels and rewards are active, and the placeholders below work. false = nothing happens (default).
falseTell the whole server when someone reaches a level? Uses messages.playtime-level-broadcast.
60How many seconds pass between two checks for players who reached a new level.
'None'What %dstats_playtime_level_name% shows for a player who has not reached the first level.
The levels. Each one needs 'hours' (total playtime, decimals work, 0.5 = 30 minutes). The order here does not matter, they are sorted by hours. The level number is the place in that order: the lowest hours is level 1.
name = what the level is called money = money paid through your economy plugin, 0 = none commands = commands the console runs, without the slash. You can use: %player% %level% %name% %hours%
Placeholders (PlaceholderAPI): %dstats_playtime_level%, %dstats_playtime_level_name%, %dstats_playtime_level_next% (the name of the next level) and %dstats_playtime_level_progress% (0 to 100).
1'Newcomer'100[]5'Regular'250[]10'Settler'500[]25'Veteran'1000[]50'Hardened'2000[]100'Elder'4000[]200'Legend'8000[]350'Mythic'15000[]500'Ascended'25000[]1000'Eternal'50000[]--- Messages --- Chat messages. & colour codes and &#RRGGBB work.
'DFFB0You reached playtime level &f%level% &7(%name%)DFFB0!'You can use: %player% %level% %name% %hours%
'&f%player% &7reached playtime level DFFB0%level% &7(%name%)&7.'Only sent when playtime-levels.announce is true. You can use: %player% %level% %name% %hours%
'&#FF5C5CThis command is for players.''&#FF4D6DThat ranking does not exist. Try: �B5FF%categories%'You can use: %categories% (the rankings that exist)
'&#FF5C5CNo player called %player% has ever joined.'You can use: %player%
--- Database --- Where the cached player skins of the rankings is stored. With type default this plugin follows the database set in DCore's config.yml: a small sqlite file in this plugin's folder unless you chose mysql or mariadb there. Fill in the fields below only if this plugin should use a different database from the rest. Changes need a restart. The first start on this version moves data/skins.yml into the database by itself and keeps a copy in this plugin's backups folder.
defaultdefault follows DCore. Use sqlite, h2, mysql or mariadb to give this plugin its own database.
data/dstats.dbThe sqlite or h2 file inside this plugin's folder. Used when this plugin keeps its own file or when DCore uses a file database.
''A full jdbc:mysql:// or jdbc:mariadb:// address. When filled in, the fields below it are ignored.
localhostUsed only when type is mysql or mariadb. The database must exist and the user needs the right to create tables.
3306minecraft''''''Extra connection options joined with &, for example useSSL=false.
dstats_Every table of this plugin starts with this text. Use only a-z, 0-9 and _. Change it only if two servers must keep separate data in one database.
# Stats: /stats shows a player's numbers, /lb and /baltop show the server rankings.# Edit, then restart the server. This plugin only shows data and stores almost none of its own (only which playtime level a player was paid for), so turning it off loses nothing.# Help and support: https://discord.devamy.net or dstudios@devamy.net# Used by updates. Do not edit.config-version: 1# Language of the plugin's texts.# EN = English# FR = French# ES = Spanishlanguage: EN# Text shown in front of every chat message from this plugin.# Use '' for no prefix. & colour codes and &#RRGGBB work.prefix: '�B5FF&lSMP &8| '# Do blocks broken, blocks placed and mobs killed in creative mode count in /stats?# false = no, so a builder in creative cannot top the blocks-placed ranking# true = yescount-creative: false# --- The /lb overview ---leaderboard:# What a ranking row shows when nobody holds that place yet.empty: '---'# How many players each ranking holds in total, across all pages.size: 45# How often the rankings are sorted again, in seconds. Menus read the finished list, so opening one never lags# the server. A minute behind is not noticeable.refresh-seconds: 60# --- The full ranking menus (/lb <category> and /baltop) ---ranking:# How often the full rankings are sorted again, in seconds. Only changes how fresh the numbers are.refresh-seconds: 60# Are players with a value of zero listed?# false = no, so the pages are not full of players who joined once and never did anything# true = yesinclude-zero: false# Player heads show skins. If a skin cannot be found, wait this many minutes before asking again.# Until then that player has the plain default head.skin-retry-minutes: 10# How many skin lookups may run at the same time. Lower it if the skin service starts refusing requests.skin-lookups-at-once: 2# The shortest gap between two skin lookups, in milliseconds (1000 = 1 second).# Mojang refuses servers that ask too fast. If two lookups in a row fail, lookups pause for a minute.# Skins that were found are saved in data/skins.yml. Bedrock players are never looked up at Mojang.skin-lookup-spacing-ms: 1000# --- Holograms at spawn ---# This is the second of two ways to show the rankings on a board, and it is off.## Way 1 (recommended): the DHolograms plugin. It reads these placeholders, one line per rank:# %dstats_top_money_1_name% %dstats_top_money_1_value% name and value of rank 1# %dstats_top_money_1% the whole row, like "#1 Notch | $105.13K"# %dstats_top_money_size% how many ranks exist# Statistics: money, points, kills, deaths, playtime, mobkills, mined, placed.# The layout is in plugins/DHolograms/holograms/, so you can edit it without touching this plugin.## Way 2 (this section): push the rankings into plain Minecraft text_display entities. Summon one per board# with the tag of that board, for example:# /summon text_display ~ ~2 ~ {Tags:["lb_money"],billboard:"vertical"}# then set enabled: true. Use it only if you do not run a hologram plugin, or every board is drawn twice.holograms:# true = fill the text_display entities below.enabled: false# The world the text_display entities stand in, written as Minecraft names it (minecraft:overworld, ...).dimension: 'minecraft:spawn'# How many ranks each board shows.entries: 10# One entry per board. tag = the tag of the entity, statistic = what it ranks, title and icon = its heading,# color = its colour.boards:money:tag: lb_moneystatistic: moneytitle: 'MONEY'icon: '$'color: '#6BFF00'points:tag: lb_pointsstatistic: points# You can use: %currency_upper% (the points currency name in capitals). Type plain text to fix the name.title: '%currency_upper%'icon: '★'color: '#00E0FF'kills:tag: lb_killsstatistic: killstitle: 'KILLS'icon: '🗡'color: '#FF2121'playtime:tag: lb_playtimestatistic: playtimetitle: 'PLAYTIME'icon: '⌚'color: '#D2FF00'# --- Playtime levels ---# Players climb a level each time their total playtime passes a number of hours, and get a reward for it.# Off by default. When you switch it on, players who already have more playtime than a level collect the reward# for every level they have passed, once, the next time the check runs. Each reward is given only once per player.# Edit, then restart the server.playtime-levels:# true = levels and rewards are active, and the placeholders below work. false = nothing happens (default).enabled: false# Tell the whole server when someone reaches a level? Uses messages.playtime-level-broadcast.announce: false# How many seconds pass between two checks for players who reached a new level.check-seconds: 60# What %dstats_playtime_level_name% shows for a player who has not reached the first level.no-level-name: 'None'# The levels. Each one needs 'hours' (total playtime, decimals work, 0.5 = 30 minutes). The order here does not# matter, they are sorted by hours. The level number is the place in that order: the lowest hours is level 1.# name = what the level is called# money = money paid through your economy plugin, 0 = none# commands = commands the console runs, without the slash. You can use: %player% %level% %name% %hours%# Placeholders (PlaceholderAPI): %dstats_playtime_level%, %dstats_playtime_level_name%,# %dstats_playtime_level_next% (the name of the next level) and %dstats_playtime_level_progress% (0 to 100).levels:1:hours: 1name: 'Newcomer'money: 100commands: []2:hours: 5name: 'Regular'money: 250commands: []3:hours: 10name: 'Settler'money: 500commands: []4:hours: 25name: 'Veteran'money: 1000commands: []5:hours: 50name: 'Hardened'money: 2000commands: []6:hours: 100name: 'Elder'money: 4000commands: []7:hours: 200name: 'Legend'money: 8000commands: []8:hours: 350name: 'Mythic'money: 15000commands: []9:hours: 500name: 'Ascended'money: 25000commands: []10:hours: 1000name: 'Eternal'money: 50000commands: []# --- Messages ---# Chat messages. & colour codes and &#RRGGBB work.messages:# You can use: %player% %level% %name% %hours%playtime-level-up: 'DFFB0You reached playtime level &f%level% &7(%name%)DFFB0!'# Only sent when playtime-levels.announce is true. You can use: %player% %level% %name% %hours%playtime-level-broadcast: '&f%player% &7reached playtime level DFFB0%level% &7(%name%)&7.'players-only: '&#FF5C5CThis command is for players.'# You can use: %categories% (the rankings that exist)unknown-category: '&#FF4D6DThat ranking does not exist. Try: �B5FF%categories%'# You can use: %player%unknown-player: '&#FF5C5CNo player called %player% has ever joined.'# --- Database ---# Where the cached player skins of the rankings is stored. With type default this plugin follows the database set in DCore's config.yml:# a small sqlite file in this plugin's folder unless you chose mysql or mariadb there. Fill in the# fields below only if this plugin should use a different database from the rest. Changes need a restart.# The first start on this version moves data/skins.yml into the database by itself and keeps a copy in# this plugin's backups folder.database:# default follows DCore. Use sqlite, h2, mysql or mariadb to give this plugin its own database.type: default# The sqlite or h2 file inside this plugin's folder. Used when this plugin keeps its own file or when# DCore uses a file database.file: data/dstats.db# A full jdbc:mysql:// or jdbc:mariadb:// address. When filled in, the fields below it are ignored.url: ''# Used only when type is mysql or mariadb. The database must exist and the user needs the right to create tables.host: localhostport: 3306database: minecraftusername: ''password: ''# Extra connection options joined with &, for example useSSL=false.parameters: ''# Every table of this plugin starts with this text. Use only a-z, 0-9 and _. Change it only if two# servers must keep separate data in one database.table-prefix: dstats_
DCore Reads the shared player database from DCore. Stores nothing of its own, so removing this jar loses no progress.
PlaceholderAPI, DCurrency, Vault. Soft only: without PlaceholderAPI the plugin runs exactly as before, just without %dstats_top_*%. Listed so PAPI is loaded first when it is present - today that only happens by accident, via DCore's own softdepend. DCurrency holds the points balances; without it the points board shows 0 for everyone.
Paper 1.21 or newer, and forks like Purpur and Leaf. Folia is supported. Java 21 or newer.