Statistics and Rating
How kills and deaths are counted, the ELO, fixed and hybrid rating, the modifiers that change it, kill streaks, ranks, anti-abuse, seasons and the Discord log.
Two modules keep score.
| Module | File | Does |
|---|---|---|
| Statistic | configs/statistic/StatisticSettings.yml | Stores every player's numbers, shows /stats, saves to the database |
| AdvancedStatistic | configs/statistic/AdvancedStatistic.yml | Rating, kill streaks, ranks, anti-abuse, leaderboards, seasons and the Discord log |
Both are on by default. With AdvancedStatistic on, it does the counting; with it off, Statistic counts kills, deaths and damage only.
What counts as a kill
A kill is counted when a tag ends with a death or a logout, never from a vanilla death message:
| Tag ends with | Counted |
|---|---|
DEATH | The last attacker gets a kill and a win, the dead player a death and a loss |
LOGOUT | The same, with processCombatLogouts: true (the default) |
EXPIRED | Nothing, both walk away |
| A tag removed by staff | Nothing |
So a tagged player who falls into lava still gives the kill to whoever hit them last, and a player who dies to a mob while not tagged loses nothing.
Wins and losses always move with kills and deaths: in 2.0.0 a win is a kill and a loss is a death.
A kill is not counted when:
| Case | What happens instead |
|---|---|
| Killer and victim are in the same team, or allied teams | Nothing at all. See teams |
| Killer and victim have the same IP | The victim gets a death, the killer nothing, and is told why |
| The victim was AFK | The victim gets a death, the killer an AFK kill and nothing else |
The killer already killed this victim maxKillsPerPlayer times within resetTimeMinutes | The victim gets a death, the killer nothing |
The last three are the anti-abuse checks.
/stats
/stats shows your numbers, /stats <player> someone else's. The lines are ownStatsFormat and
otherStatsFormat in StatisticSettings.yml, and can use every
statistic placeholder.
messages:
ownStatsFormat:
- "<gold><bold>Your PvP stats"
- "<gray>Kills: <white>{pvp_kills} <gray>Deaths: <white>{pvp_deaths}"
- "<gray>Rating: <white>{pvp_rating} <gray>({pvp_rank_displayname})"
- "<gray>Best streak: <white>{pvp_best_streak}"
| Key | Default | Meaning |
|---|---|---|
processCombatLogouts | true | Count a combat log as a death and a kill |
viewOthersPermission | uxmpvpcore.statistic.others | Needed for /stats <player> |
viewOfflinePlayerStatsPermission | uxmpvpcore.statistic.offline | Needed when that player is offline |
playerCache.flushMinutes | 10 | Numbers are written to the database every this many minutes, and on shutdown |
playerCache.saveOnQuit | true | Also write a player's numbers when they leave |
playerCache.keepCacheOnQuit | true | Keep a player's numbers in memory after they leave |
playerCache.viewCacheDurationMinutes | 5 | How long an offline player's numbers stay in memory after someone looked at them |
broadcastDeathMessage, deathMessage and maxBattleLogCache are in the file but do nothing in
2.0.0. For a message on every kill, use Kill Messages.
Rating
Every counted kill moves rating: the killer gains, the victim loses. New players start at
startingRating, and rating never leaves minRating to maxRating.
Key in ratingSettings | Default | Meaning |
|---|---|---|
enabled | true | Turns rating on or off. Kills are still counted |
mode | ELO | ELO, FIXED or HYBRID, below |
startingRating | 1000 | Rating of a new player |
minRating, maxRating | 100, 3000 | The lowest and highest rating possible |
showRatingChange | true | Tell both players how much they gained or lost |
showDetailedBreakdown | false | Also show the killer the mode, base change and multiplier |
The three modes
| Mode | How much the killer gains | How much the victim loses |
|---|---|---|
ELO | More for beating a stronger player, less for a weaker one. Up to kFactor (32) | The same amount |
FIXED | Always killPoints (25) | Always deathPoints (15) |
HYBRID | 70 % of the ELO amount plus 30 % of baseKillPoints (20) | 70 % of the ELO amount plus 30 % of baseDeathPoints (10) |
In ELO, two players with equal rating move 16 points each. A 1000 player who kills a 1400 player
gains about 29, while the 1400 player killing the 1000 player gains about 3. This keeps strong
players from farming weak ones.
FIXED is simple and predictable. With scaleWithOpponentRating: true, the killer gains
scalingFactor (0.01) more per point the victim was rated above them, and less when the victim was
rated below. With the defaults, killing a player rated 300 higher gives 28 instead of 25.
ratingSettings:
mode: HYBRID
startingRating: 1000
eloConfig:
kFactor: 40
fixedPointsConfig:
killPoints: 25
deathPoints: -15
hybridConfig:
eloWeight: 0.7
fixedWeight: 0.3
baseKillPoints: 20
baseDeathPoints: -10
Death points are written as negative numbers.
Modifiers
After the mode gives a base amount, modifiers multiply it based on how the fight went. Each is a
section in modifierSettings, and globalEnabled: false turns all of them off.
| Modifier | Raises the killer's gain when | Default |
|---|---|---|
healthRisk | The killer won with little health left | Below 50 % health ×1.1, below 25 % ×1.3, below 10 % ×1.5 |
weaponSkill | The killer won with a weaker or harder weapon | Per item, from weapons. Fists ×2.0, trident ×1.6, mace and crossbow ×1.5, bow ×1.4, netherite sword ×0.9. Anything not listed ×1.0 |
criticalSkill | The killer landed many critical hits | Up to ×2.0 above 30 % critical hits, down to ×0.7 below. Needs 5 hits, a fight of 3 seconds and a victim with 10 armour points |
armor | The killer had at least 3 armour points less | +0.02 per point, at most +0.25. With 3 or more points more, it lowers the gain by 0.1 per point, at most 0.15 |
shutdown | The victim was on a kill streak of 3 or more | +0.04 per kill of their streak, at most +0.4 |
gangProtection | The killer was fighting 2 or more players at once | +0.03 per attacker, at most +0.5 |
gangProtection also protects the victim: when 2 or more players were fighting the victim, the
victim loses 15 % less per attacker, at most 60 % less.
All killer multipliers are multiplied together and capped at maxTotalMultiplier (2.0); the victim's
protection is capped at maxTotalProtection (0.8, so a victim always loses at least 20 % of the base).
modifierSettings:
globalEnabled: true
maxTotalMultiplier: 1.5
weaponSkill:
enabled: true
defaultMultiplier: 1.0
weapons:
AIR: 1.5
BOW: 1.2
MACE: 1.0
criticalSkill:
enabled: false
Every kill writes the change to the console, such as [Rating] Steve killed Alex | Steve: +18.4 ....
Kill streaks
A streak is the number of kills since the player last died. When it reaches a level in
killStreakSettings.levels, a message goes to every player with broadcasts on.
| Streak | Name | Message |
|---|---|---|
| 3 | First Blood | {player} is on a Killing Spree (3 kills) |
| 5 | Rampage | {player} is on a Rampage |
| 7 | Dominating | {player} is Dominating |
| 10 | Unstoppable | {player} is Unstoppable |
| 15 | Godlike | {player} is Godlike |
killStreakSettings:
enabled: true
levels:
3:
name: Killing Spree
broadcastMessage: "<gold>{player} <gray>has <gold>3</gold> kills in a row."
enabled: true
20:
name: Legendary
broadcastMessage: "<red><bold>{player} has 20 kills in a row!"
enabled: true
Messages can use {player} and the statistic placeholders, not
PlaceholderAPI. Only the exact count triggers a message, and killing a player on a streak of 3 or
more gives the shutdown bonus.
Ranks
A rank is a rating range. When a player's rating moves into another range after a kill, their rank changes, they get a message, everyone gets a broadcast, and the rank's commands run.
| Rank | Rating |
|---|---|
BEGINNER | 0 to 100 |
AMATEUR | 100 to 300 |
SKILLED | 300 to 600 |
EXPERT | 600 to 1000 |
MASTER | 1000 to 1500 |
GRANDMASTER | 1500 to 2000 |
LEGEND | 2000 to 2500 |
MYTHIC | 2500 and above |
New players start at 1000, so they begin as MASTER. Change the ranges or startingRating so they
fit each other.
rankSettings:
enabled: true
autoRankUp: true
broadcastRankChange: true
ranks:
- name: BRONZE
minRating: 0
maxRating: 1100
displayName: "<#CD7F32>Bronze"
commands:
- "lp user {player} parent set bronze"
- name: SILVER
minRating: 1100
maxRating: 1400
displayName: "<gray>Silver"
commands:
- "lp user {player} parent set silver"
| Key | Meaning |
|---|---|
name | The rank's id, shown by {pvp_rank} |
minRating, maxRating | The range |
displayName | Shown by {pvp_rank_displayname} and in rank messages |
commands | Console commands run when a player enters this rank, going up or down. {player} is the name, {rank} the display name |
autoRankUp | Update ranks after kills. Off, ranks never change |
broadcastRankChange | Send rankUpBroadcast and rankDownBroadcast to everyone |
Ranks are checked only after a counted kill: a rating changed with /aps set shows the new rank after
the player's next fight.
Anti-abuse
penaltySettings keeps players from farming rating. enabled: false turns every check off.
| Check | Section | Default |
|---|---|---|
| Same IP | ipProtection | Players on the same IP gain no rating from each other |
| AFK victim | activityTracking | A victim who has not moved 1 block (minimumMovementDistance) in 5 minutes (afkThresholdMinutes) is AFK |
| Repeat kills | killAbuseProtection | The same victim gives rating at most 3 times (maxKillsPerPlayer) per 60 minutes (resetTimeMinutes) |
Each check has a message sent to the killer. combatLogoutPenalty and afkKillPenalty are in the
file but take no rating in 2.0.0.
Teams
File: configs/TeamIntegration.yml. With BetterTeams or TulparClan installed, fights inside a team
can be left out.
| Key | Default | Meaning |
|---|---|---|
enabled | true | Turns team checks on or off |
provider | auto | auto picks the installed plugin; or BetterTeams, TulparClan |
blockSameTeamStatistics | true | Kills between teammates count nothing |
blockSameTeamHeadDrop | true | Teammates drop no head for each other |
allyProtectionEnabled | true | Treat allied teams like teammates for the two settings below |
blockAllyStatistics | true | Kills between allies count nothing |
blockAllyHeadDrop | true | Allies drop no head for each other |
Team relations also decide the glow colours.
Daily statistics
{pvp_daily_kills} and {pvp_daily_deaths} go back to 0 every 24 hours, counted from when the server
started, not at midnight. Only players in memory, those online or seen recently, are reset; others
keep their numbers until the next reset that finds them.
Seasons
/resetseason ends a season: it writes the top 10 to the console, saves everyone's statistics to
plugins/uxmPVPCore/backups/stats_backup_<date>.json, puts every rating back to startingRating,
and clears peak, lowest, gained and lost rating. Kills, deaths and streaks stay. It asks no question,
so make a database backup first. Its messages are in seasonResetMessages.
Discord log
discordSettings posts every rated kill to a Discord channel through a webhook.
| Key | Default | Meaning |
|---|---|---|
enabled | true | Turns the log on, once a webhook is set |
webhookUrl | empty | The channel's webhook URL. Empty means no log |
username, avatarUrl | uxmPVPCore Logger, empty | How the sender looks |
embedColor | #FF5555 | The embed's colour |
embedTitle, embedFooter | PvP Kill, uxmPVPCore PvP Logger | Its title and footer |
logKills | true | Post kills |
showCombatDetails | true | Add damage and fight details |
showModifiers | true | Add the rating modifiers |
Create the webhook in Discord under the channel's settings, Integrations, Webhooks, and paste its URL.
Related: Leaderboards, Placeholders, Commands
Was this page helpful?