PVP Stats

Bukkit Plugins
56,309 Downloads Last Updated: Nov 26, 2020 Game Version: 1.16

You want to keep track of your users' PVP actions? There you go. Drop the jar into your plugin folder, restart the server, change the config, restart - done!


>> download for 1.7 and earlier <<


This plugin features saving of kills, deaths and killstreaks to a MySQL database, simple as that:

Table name: pvpstats

  • name
  • kills
  • deaths
  • streak
  • currentstreak
  • ELO
  • time

Since v0.6 it also supports more detailed stats, so you can check the kill / death count by time

Table name: pvpkillstats

  • name
  • kill
  • time

That's the basic equipment you need to display the PVP experience of your players. PVP Stats will create the databases for you! You just need to setup the database connection/settings in the config


/pvpstats - show your pvp stats /pvpstats [player] - show player's pvp stats
/pvpstats [amount] - show the top [amount] players (K-D)
/pvpstats top [amount] - show the top [amount] players (K-D)
/pvpstats top [type] - show the top 10 players of the type
/pvpstats top [type] [amount] - show the top [amount] players of the type
/pvpstats cleanup - clean the database of multi entries
/pvpstats debugkill [attacker] [victim] - manually insert a kill for debug purposes
/pvpstats migrate [from/to] [yml/sqlite/mysql] - migrate from/to a different database implementation
/pvpstats purge [amount] - purge KILLSTATS entries older than [amount] days
/pvpstats reload - reload the config
/pvpstats wipe [player] - wipe the stats [for a player]

Permission nodes:

description: Ability to cleanup (remove entries with the same player name)
  default: op
description: Permission to be counted
default: true
description: Ability to debug
default: op
description: Ability to add a debug kill
default: op
description: Ability to migrate
default: op
description: Ability to purge entries older than X days
default: op
description: Ability to reload
default: op
description: Permission to get global stats
default: true
description: Ability to wipe the stats
default: op
description: Permission to block being killed to be counted
default: false


> Commented config since 1.3 < (GitHub)


config before 1.3:

MySQL: true
MySQLhost: localhost
MySQLuser: [sql user]
MySQLpass: [sql password]
MySQLport: [sql port]
MySQLdb: [sql database]
MySQLtable: [sql table]
MySQLkilltable: [sql kill table]

PVPArena: false
checkabuse: true
abuseseconds: -1
updatecheck: true
autodownload: true
tracker: true
collectprecise: true
clearonstart: true
kdcalculation: '&k/(&d+1)'
- doNotTrack
  active: false
  minimum: 18
  default: 1500
  maximum: 3000
    below: 32
    above: 16
    threshold: 2000
  - '&cName: &7%n'
  - '&cKills: &7%k'
  - '&cDeaths: &7%d'
  - '&cRatio: &7%r'
  - '&cStreak: &7%s'
  - '&cMax Streak: &7%m'

PVPArena: should pvpstats try to hook into PA?
checkabuse: should pvpstats disallow scoring by killing of the same player in a row?
abuseseconds: the amount of seconds after which the abuse check gets reset
tracker: may pvpstats phone home to report that your server is using it?
collectprecise: should pvpstats save each kill with timestamp?
clearonstart: should pvpstats check the database for duplicates on startup?
kdcalculation: as stated in the config, this defines the calculation for the top X list, the following placeholders are possible:

  • &k - kills
  • &d - deaths
  • &s - current streak value
  • &m - max streak value

ignoreworlds: a list of worlds that will not make kills count eloscore:

  • active: should we care about previous kills?
  • minimum: minimum score possible
  • default: default ELO score
  • maximum: maximum score possible
  • k-factor below: k-factor below threshold
  • k-factor above: k-factor above threshold
  • k-factor threshold: the border between the two k-factors

New update config nodes in 1.0!
You now have a config block like this:

mode: both
type: beta

Mode case insensitively supports:

  • off (fallback default)
  • announce - announce updates to OP players when they join the server
  • download - download updates automatically for the next reboot
  • both - do both and simply inform players rather that the update will happen on reboot, rather than asking them to download

Type case insensitively supports:

  • alpha - bleeding edge
  • beta - fairly tested things
  • release (fallback default)

Database options:

  • a MySQL database
  • SQLite installed
  • YML Files (probably slow)


Webstats by Pandapipino

Placeholder API Player Placeholders:

  • Player based stats:
    • slipcorpvpstats_kills
    • slipcorpvpstats_deaths
    • slipcorpvpstats_streak
    • slipcorpvpstats_maxstreak
    • slipcorpvpstats_elo - the ELO score
    • slipcorpvpstats_ratio - the kill/death ratio
  • Top list stats:
    • slipcorpvpstats_top_kills_head_5 - heading ("Top 5 Kills")
    • slipcorpvpstats_top_kills_1 - Top player entry ("1. SLiPCoR: 100")
    • slipcorpvpstats_top_kills_2 - Second player entry ("2. garbagemule: 70")
    • slipcorpvpstats_top_kills_3 - ...
    • slipcorpvpstats_top_kills_4
    • slipcorpvpstats_top_kills_5
  • Worst list stats:
    • slipcorpvpstats_flop_kills_head_5 - heading ("Least 5 Kills")
    • slipcorpvpstats_flop_kills_1 - First player entry ("1. SLiPCoR: 5")
    • slipcorpvpstats_flop_kills_2 - Second player entry ("2. garbagemule: 10")
    • slipcorpvpstats_flop_kills_3 - ...
    • slipcorpvpstats_flop_kills_4
    • slipcorpvpstats_flop_kills_5

Valid list statistics are:

  • kills
  • deaths (top is sorted ascending!)
  • streak (maximum streak)
  • elo
  • k-d (kill/death ratio as defined in the config)


  • pandapipino for the idea :)

Source: GitHub

Phoning home

To determine popularity and usage of PVP Stats, the server contacts my private server for information purposes. It sends your port, IP (for proper server counting), and the plugin version. That's it! If you want to disable that, set "tracker" to false in the config!

UUID ready!

As of version 0.8, PVP Stats is ready for UUIDs, as soon as your server is. It updates the database to account for the new system of Player Unique Ids. If your server is ready, it connects to api.mojang.com and updates all database entries. This can cause lag, but it should be done in a few seconds. If your server is not ready, it will fall back to standard player name lookup, even if you decide to downgrade after "testing" the latest CraftBukkit dev version. However then, you will want to reset the new config setting about UUIDs to false again, so at next start, the database is converted again.


Posts Quoted: