COWMODSКаталог модов

XRank

A title plugin that displays titles everywhere, in chat, tab, nametag, even system message. Supports MySQL, SQLite and YAML. Works on 1.8.x+ and all Bukkit based server.

Автор: Wind_Blood2250обновлён 23 авг. 2026 г.
УправлениеОбщениеУтилиты

Описание

XRank Logo

0 Why is this here

Just. For. Fun.

I actually planned a title plugin like this before, so now I completed it, XRank.


1 Features

1.1 Quad-Route Rendering System

XRank stands out with its comprehensive 4-route rendering approach, covering every aspect of player representation:

  • TAB List → Player#setPlayerListName(String)

    • Smart protocol-length truncation (supports RGB color codes)
    • Auto-detects TAB plugin and yields rendering to avoid conflicts
    • Fallback to plain name when tab name exceeds length limits
  • Chat Format → AsyncPlayerChatEvent#setFormat(String)

    • Customizable format with %rank%, %name%, %message% placeholders
    • Preserves other plugins' chat modifications (non-invasive)
    • Highest priority event handling
  • Name Tag (Above Head) → Scoreboard#Team with setPrefix/setSuffix + Team#setColor (reflection)

    • Color inheritance from rank display
    • Automatic team creation/per-player management
    • Conflict resolution when team names are occupied
  • System Messages → Player#displayName(Component) (Adventure, 1.16.5+) or reflection on NMS EntityPlayer#displayName (1.8.x–1.15.x)

    • Full Adventure API support for modern servers
    • NMS reflection fallback for legacy versions
    • Applies to death messages and most of the server's system-generated text

Why this matters: Most rank plugins only handle 2 routes (TAB + CHAT), with some advanced ones adding NAMETAG. XRank is one of the few plugins that completes all 4 routes, ensuring a consistent rank display experience everywhere the player's name appears.

BUT, some messages, such as the messages for /tp, may still use the raw player name instead of the version that is handled by XRank.

This is because the rank in system messages is based on displayName, and some vanilla commands use the raw one instead of displayName. This is basically unavoidable.

You can regard it as a passive design that facilitates debugging... it would be silly to have to useless rank when teleporting, but having a prefix in death messages is fine.

1.2 Multi-Storage Support

  • YAML - Simple file-based storage
  • SQLite - Lightweight database for small to medium servers (default)
  • MySQL - Enterprise-grade database for large servers
  • Auto-Migration - Seamlessly migrate between storage types without data loss

1.3 Flexible Rank Management

  • Multiple ranks per player
  • Configurable rank display names with color codes (&)
  • Default rank assignment for new players
  • Permission-based default rank bypass (xrank.ignore_default)
  • Batch operations for online/offline/all players

1.4 PlaceholderAPI Support (Optional)

  • %xrank_ranks% - Full rank display (with colors)
  • %xrank_ranks_raw% - Raw rank names (without formatting)
  • %xrank_has_rank% - Returns true if player has any rank
  • %xrank_prefix% - Rank prefix from format
  • %xrank_suffix% - Rank suffix from format

1.5 Developer API

  • Async CompletableFuture based API
  • Per-UUID locking for thread-safe operations
  • RankChangeEvent for listening to rank updates
  • API toggle via allow_to_use_api config option

1.6 Multi-Version & Platform Support

  • Supports Minecraft 1.8.9 through 1.21+
  • Folia compatibility with RegionScheduler
  • Paper/Purpur optimized
  • Spigot/Bukkit legacy support
  • TAB plugin auto-detection (yields TabList rendering)

Known Limitation: On Folia servers, nametag ranks are not available due to the Bukkit scoreboard API being disabled. This is a platform limitation.

1.7 Internationalization

  • Multi-language message support via lang config
  • No hardcoded player messages
  • Auto-fix configuration with missing key completion

1.8 Thread-Safe Operations

  • Per-UUID locks ensure atomic read-modify-write operations
  • Async database operations don't block the main thread
  • ConcurrentHashMap for player data caching

2 Commands

CommandPermissionDescription
/xrank-Shows plugin version and status
/xrank give <player|-all|-online|-offline> <rank>xrank.giveGive a rank to the player(s)
/xrank remove <player|-all|-online|-offline> <rank>xrank.removeRemove a specific rank from player(s)
/xrank remove <player|-all|-online|-offline>xrank.removeRemove ALL ranks (requires confirmation)
/xrank list [player|-all|-online|-offline]xrank.listList ranks of player(s)
/xrank reloadxrank.adminReload configuration and apply changes

/xrk = /xrank

Batch Targets:

  • -all - All players (online + offline)
  • -online - All online players
  • -offline - All offline players

3 Permission Nodes

PermissionDescription
xrank.giveAllows giving ranks to players
xrank.removeAllows removing ranks from players
xrank.listAllows viewing ranks of players
xrank.adminFull administrative access (includes reload)
xrank.ignore_defaultPlayer will not receive default rank

4 Configuration

4.1 Basic Settings

# Language (messages section key)
lang: "en"

# Debug mode (logs additional information)
debug: false

# Show logo on startup
show_logo: true

# Default rank for new players (empty = none)
default-rank: "default"

# Enable display name modification
display-name-enabled: true

# API access toggle
allow_to_use_api: true

# Remove confirmation timeout (seconds)
remove-confirm-timeout: 30

4.2 Storage Configuration

storage:
  # Options: yaml, sqlite, mysql
  type: "sqlite"
  
  mysql:
    host: "localhost"
    port: 3306
    database: "xrank"
    username: "root"
    password: "password"

4.3 Format Configuration

# Tab list / display format (supports %rank%, %name%)
format: "%rank%%name%"

# Chat format (supports %rank%, %name%, %message%)
chat-format: "%rank%%name%&f: %message%"

4.4 Rank Definitions

ranks:
  owner: "&4[&cOwner&4] "
  admin: "&c[Admin] "
  vip: "&6[VIP] "
  default: "&7[Player] "

4.5 Message Customization

Messages are organized by language key. Example for en:

messages:
  en:
    no-permission: "&cYou don't have permission to do this."
    player-not-found: "&cPlayer {player} not found."
    rank-given: "&aSuccessfully gave {rank} to {players}"
    rank-removed: "&aSuccessfully removed {rank} from {players}"
    rank-not-found: "&cRank {rank} not found for {players}"
    confirm-warning: "&6This will remove ALL ranks from {player}"
    confirm-again: "&6Type /xrank remove {player} again within {seconds}s to confirm"
    confirm-done: "&aRemoved all ranks from {players}"
    reload-done: "&aConfiguration reloaded successfully!"
    list-header: "&6--- Rank List ---"
    list-format: "&f{player}&7: {ranks}"
    list-no-ranks: "&f{player}&7: No ranks"
    list-footer: "&6--- End of List ---"
    usage-give: "&cUsage: /xrank give <player|-all|-online|-offline> <rank>"
    usage-remove: "&cUsage: /xrank remove <player|-all|-online|-offline> [rank]"
    no-ranks-record: "&cNo rank records found."

5 Developer API

5.1 Getting Player Ranks

Main.getInstance().getPlayerRanks(uuid).thenAccept(ranks -> {
    // ranks is a List<String>
});

5.2 Setting Player Ranks

Main.getInstance().setPlayerRanks(uuid, "PlayerName", Arrays.asList("admin", "vip"))
    .thenAccept(success -> {
        // success is Boolean
    });

5.3 Adding a Rank

Main.getInstance().addRank(uuid, "PlayerName", "vip")
    .thenAccept(changed -> {
        // changed is Boolean
    });

5.4 Removing a Rank

Main.getInstance().removeRank(uuid, "vip")
    .thenAccept(changed -> {
        // changed is Boolean
    });

5.5 RankChangeEvent

@EventHandler
public void onRankChange(RankChangeEvent event) {
    UUID uuid = event.getPlayerId();
    String name = event.getPlayerName();
    List<String> oldRanks = event.getOldRanks();
    List<String> newRanks = event.getNewRanks();
    // Handle rank change
}

6 Installation

  1. Download the latest xrank-X.X.X.jar
  2. Place it in your server's plugins/ folder
  3. Restart or reload your server
  4. Configure plugins/xrank/config.yml to your needs
  5. Reload with /xrank reload

7 Requirements

  • Server: All Bukkit Based Server (1.8.9+)
  • Optional: PlaceholderAPI for placeholder support

9 Feedback

Just e-mail me with windblood@foxmail.com, thanks!

Последние версии

Все версии →
alpha

Fixes

1.2-alpha
23 авг. 2026 г.59Minecraft: 1.10, 1.10.1, 1.10.2, 1.11, 1.11.1, 1.11.2, 1.12, 1.12.1, 1.12.2, 1.13, 1.13.1, 1.13.2, 1.14, 1.14.1, 1.14.2, 1.14.3, 1.14.4, 1.15, 1.15.1, 1.15.2, 1.16, 1.16.1, 1.16.2, 1.16.3, 1.16.4, 1.16.5, 1.17, 1.17.1, 1.18, 1.18.1, 1.18.2, 1.19, 1.19.1, 1.19.2, 1.19.3, 1.19.4, 1.20, 1.20.1, 1.20.2, 1.20.3, 1.20.4, 1.20.5, 1.20.6, 1.21, 1.21.1, 1.21.10, 1.21.11, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.7.10, 1.8, 1.8.1, 1.8.2, 1.8.3, 1.8.4, 1.8.5, 1.8.6, 1.8.7, 1.8.8, 1.8.9, 1.9, 1.9.1, 1.9.2, 1.9.3, 1.9.4, 26.1, 26.1.1, 26.1.2, 26.2bukkit, folia, paper, purpur, spigot
Скачать
Что нового
### Added - **Full Folia support** — server detection via `RegionizedServer` class, with all player-entity operations dispatched through the region scheduler (`RegionScheduler.run`) via reflection - **`runOnRegion` scheduling helper** — dispatches player operations to the correct region thread on Folia, falls back to the main thread on Bukkit-based servers ### Changed - **Chat format handling** — `onChat` now builds the message strictly from `chat-format`, manually substituting `%rank%` → rank display text, `%name%` → player name, `%message%` → `%2$s` placeholder. The previous approach collapsed `%rank%`/`%name%` into `%1$s` (the displayName), which caused separators/ordering in `chat-format` (e.g. `%rank% / %name%`) to be ignored or duplicated - **`applyDisplayName`** — added a space between the rank text and the player name so system messages / chat prefixes have a natural separator ### Fixed - **`UnknownFormatConversionException` on chat** (`Conversion = '§'` / `'&'`) — the old code left `%rank%`/`%name%` residue which `setFormat`'s internal `String.format` choked on; the new manual substitution leaves only the legal `%2$s` placeholder, and `§` is a literal character safe from `String.format` - **Chat prefix duplicating / `chat-format` ignored** — `%rank% / %name%` now renders as `[Ranks] / Player > Message` or something like that, exactly as configured - **Folia: nametag failing with `UnsupportedOperationException`** — root-caused via stack traces: Folia 26 fully disables the Bukkit scoreboard API (`registerNewTeam` on the main board **and** `getNewScoreboard()` both throw). The scoreboard-based nametag is skipped on Folia (no crash), while Tab / chat / system messages continue to work - **Folia: `supportsLongTabName` misdetection** — Folia's version string isn't matched by the `1.x` regex, so the Tab length limit fell back to 16; now uses the `hasAdventure` capability check (Folia 26 has Adventure), so Tab correctly uses the 64-char limit ### Removed - *(nothing)*
release

Finally Fixed

1.1-rls
22 авг. 2026 г.146Minecraft: 1.10, 1.10.1, 1.10.2, 1.11, 1.11.1, 1.11.2, 1.12, 1.12.1, 1.12.2, 1.13, 1.13.1, 1.13.2, 1.14, 1.14.1, 1.14.2, 1.14.3, 1.14.4, 1.15, 1.15.1, 1.15.2, 1.16, 1.16.1, 1.16.2, 1.16.3, 1.16.4, 1.16.5, 1.17, 1.17.1, 1.18, 1.18.1, 1.18.2, 1.19, 1.19.1, 1.19.2, 1.19.3, 1.19.4, 1.20, 1.20.1, 1.20.2, 1.20.3, 1.20.4, 1.20.5, 1.20.6, 1.21, 1.21.1, 1.21.10, 1.21.11, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.8, 1.8.1, 1.8.2, 1.8.3, 1.8.4, 1.8.5, 1.8.6, 1.8.7, 1.8.8, 1.8.9, 1.9, 1.9.1, 1.9.2, 1.9.3, 1.9.4, 26.1, 26.1.1, 26.1.2, 26.2bukkit, folia, paper, purpur, spigot
Скачать
Что нового
### Added - **`lastRankStyle` helper** — extracts the last full style segment (color + format codes like `§6§l`) from a rank, used to make the player-name segment in `displayName` inherit the rank's formatting ### Changed - **Chat format handling (modern versions)** — `%rank%` / `%name%` combinations are now unified into `%1$s` (which expands to displayName already containing rank + name), eliminating prefix duplication and `%xxx%` residue - **`applyScoreboard`** — `setColor` now receives the §-translated rank (`rankColored`) instead of the raw `&` string, so `Team#setColor` actually applies - **`applyDisplayName`** — player-name segment now carries the rank's trailing style (color + bold) via `lastRankStyle`, so the name in system messages / chat follows the rank formatting ### Fixed - **`UnknownFormatConversionException` on chat (`Conversion = '§'` / `'&'`)** — `setFormat` internally runs `String.format`, which chokes on leftover `%rank%`/`%name%` placeholders; all rank/name placeholders are now replaced with `%1$s`/`%2$s` before calling `setFormat`, so it no longer throws - **System messages (death / tp) showing white player names** — the root cause was `lastRankColor` receiving the raw `&`-form rank (which only scans `§`), returning `null` and silently skipping `Team#setColor`; now receives the §-translated rank, so the name color in death/tp messages correctly inherits the rank color (color only, not bold — a `setColor` limitation on modern versions) - **`applyDisplayName` name segment white** — the last rank style (color + format) is now appended before the player name, so the name inherits the rank formatting ### Removed - *(nothing)*
beta

More Stable

1.1-beta
21 авг. 2026 г.5Minecraft: 1.10, 1.10.1, 1.10.2, 1.11, 1.11.1, 1.11.2, 1.12, 1.12.1, 1.12.2, 1.13, 1.13.1, 1.13.2, 1.14, 1.14.1, 1.14.2, 1.14.3, 1.14.4, 1.15, 1.15.1, 1.15.2, 1.16, 1.16.1, 1.16.2, 1.16.3, 1.16.4, 1.16.5, 1.17, 1.17.1, 1.18, 1.18.1, 1.18.2, 1.19, 1.19.1, 1.19.2, 1.19.3, 1.19.4, 1.20, 1.20.1, 1.20.2, 1.20.3, 1.20.4, 1.20.5, 1.20.6, 1.21, 1.21.1, 1.21.10, 1.21.11, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.8, 1.8.1, 1.8.2, 1.8.3, 1.8.4, 1.8.5, 1.8.6, 1.8.7, 1.8.8, 1.8.9, 1.9, 1.9.1, 1.9.2, 1.9.3, 1.9.4, 26.1, 26.1.1, 26.1.2, 26.2bukkit, folia, paper, purpur, spigot
Скачать
Что нового
### Added - **`%xrank_rank_count%` placeholder** — returns the number of effective ranks a player currently has - **`%xrank_rank_<index>%` placeholder** — returns the Nth rank (0-based); returns empty when out of range - **YAML `ReentrantReadWriteLock`** — read operations (`getRanks`, `getName`, `loadAll`) no longer block each other; only writes take the exclusive lock - **MySQL connection heartbeat with auto-reconnect** — connection validity is verified with `SELECT 1` after 5s of idle time (refreshed on every successful read/write), so dead connections from `wait_timeout` / firewall drops are detected and re-established automatically ### Changed - **PAPI expansion metadata now reads from `plugin.yml`** — `getIdentifier()` returns the plugin name forced to lowercase (stable `%xrank_*%` regardless of case), `getAuthor()` joins the full authors list (multi-coauthor support), `getVersion()` follows the plugin version - **`%xrank_prefix%` / `%xrank_suffix%`** remain format-derived, now correctly rendering colors ### Fixed - **Legacy color codes (`&`) showing literally on modern versions** — `applyDisplayName()` and the high-version chat branch now translate `&` → `§` before handing the string to Adventure's `LegacyComponentSerializer` / `setFormat`, so `&6&l` properly renders as gold bold instead of literal `&6&l` white text - (verified) 1.8.8 legacy path unaffected — NMS reflection branch already handled correctly ### Removed - *(nothing)*
alpha

Extreme

1.1-alpha
20 авг. 2026 г.4Minecraft: 1.10, 1.10.1, 1.10.2, 1.11, 1.11.1, 1.11.2, 1.12, 1.12.1, 1.12.2, 1.13, 1.13.1, 1.13.2, 1.14, 1.14.1, 1.14.2, 1.14.3, 1.14.4, 1.15, 1.15.1, 1.15.2, 1.16, 1.16.1, 1.16.2, 1.16.3, 1.16.4, 1.16.5, 1.17, 1.17.1, 1.18, 1.18.1, 1.18.2, 1.19, 1.19.1, 1.19.2, 1.19.3, 1.19.4, 1.20, 1.20.1, 1.20.2, 1.20.3, 1.20.4, 1.20.5, 1.20.6, 1.21, 1.21.1, 1.21.10, 1.21.11, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.8, 1.8.1, 1.8.2, 1.8.3, 1.8.4, 1.8.5, 1.8.6, 1.8.7, 1.8.8, 1.8.9, 1.9, 1.9.1, 1.9.2, 1.9.3, 1.9.4, 26.1, 26.1.1, 26.1.2, 26.2bukkit, folia, paper, purpur, spigot
Скачать
Что нового
### Added - **MySQL & SQLite storage backends**, selectable via `storage.type` in config - **Automatic bidirectional migration** between YAML / SQLite / MySQL on storage type switch; YAML is backed up to `data.yml.bak` (never deleted) - **Developer API**: `getPlayerRanks()`, `setPlayerRanks()`, `addRank()`, `removeRank()` — fully async via `CompletableFuture` with a dedicated thread pool - **`RankChangeEvent`** so other plugins can listen to rank changes (old/new ranks) - **`allow_to_use_api`** config option to disable the public API - **PlaceholderAPI expansion** (optional dependency): `%xrank_ranks%`, `%xrank_ranks_raw%`, `%xrank_has_rank%`, `%xrank_prefix%`, `%xrank_suffix%` - **TAB plugin detection** — xrank yields TabList rendering to TAB when present and exposes ranks via PAPI instead - **`display-name-enabled` option** — `Player#displayName` is set so system messages (`/tp`, death messages, etc.) show the rank prefix; uses Adventure API on modern Paper and NMS reflection on legacy versions - **`-online` / `-offline` batch targets** alongside `-all` for `give`, `remove`, and `list` - **Team name collision fallback** — team names use `xr_` + UUID hash with `_1`..`_99` retry, so registration never throws - **Nametag color inheritance** — the team color is derived from the last effective color code in the rank, so nametag/name text matches the rank color (respects `&r`) - **Tab name length guard** — protocol-length check on both old (16) and new (64) versions; if exceeded, Tab falls back to the plain name and logs a warning - **Periodic cleanup** of expired remove-confirmation records (every 60s) - **Debug logging** for storage switches, migrations, joins, commands, and server detection - **UUID + name hybrid storage** — ranks are keyed by UUID with a redundant name column, so ranks follow a player across name changes ### Changed - **Storage keying** — switched from name-based to UUID + name hybrid - **Chat handling** — switched from `setCancelled(true)` + manual broadcast to `setFormat`, coexisting with other chat plugins - **Scoreboard** — switched from per-player independent scoreboards to the shared main scoreboard with per-player teams (no longer hijacks the player's scoreboard) - **Chat prefix logic** — modern versions rely on `%1$s` (displayName already contains the prefix); legacy versions assemble the prefix manually - **PAPI expansion metadata** — `getIdentifier()` / `getAuthor()` / `getVersion()` now read from `plugin.yml` (identifier forced lowercase; author supports multiple co-authors via the full authors list) - **Config philosophy** — all player-facing messages come from config (`messages.<lang>`), with `fixConfig` merging missing keys from the bundled config; `ranks` is intentionally never auto-filled - **Branding** — version display parses `-alpha`/`-beta`/`-rls` suffixes for color; `/xrank` with no/unknown args shows version info ### Fixed - **Chat double prefix** — rank prefix could appear twice on versions where `%1$s` expands to displayName - **`modifyRanks` double invocation** in `remove` — replaced with a single pass returning a `ModifyResult` (old/new/changed) - **`truncate` dropping the rest of the string** when an RGB color code didn't fit — now skips the code and keeps subsequent characters - **`saveData()` being a no-op** — now actually flushes the storage - **`{tag}` placeholder leaking into output** — removed unused placeholder from list format - **`(无头衔)` colliding with a real rank named that** — no-rank state now uses a dedicated message (`list-no-ranks`) - **`TreeSet<String>` type error** in name→UUID maps - **PAPI `register()` resolution** — switched to `PlaceholderAPI.registerExpansion` (with `ExpansionManager` fallback for older PAPI) - **RGB length accounting in truncation** — RGB codes counted as 14 protocol chars - **Legacy versions** — 1.8.8 verified working (system messages via NMS reflection, chat prefix via legacy branch) ### Removed - **`help` subcommand and help page** — redundant with tab-completion - **`list-default-tag`** — default ranks are no longer listed as records (list reflects only stored ranks) - **Chat takeover** — `setCancelled(true)` + manual broadcast removed in favor of `setFormat` - **Per-player independent scoreboards** — replaced by the shared scoreboard approach
release

The First Version

1.0-rls
19 авг. 2026 г.10Minecraft: 1.10, 1.10.1, 1.10.2, 1.11, 1.11.1, 1.11.2, 1.12, 1.12.1, 1.12.2, 1.13, 1.13.1, 1.13.2, 1.14, 1.14.1, 1.14.2, 1.14.3, 1.14.4, 1.15, 1.15.1, 1.15.2, 1.16, 1.16.1, 1.16.2, 1.16.3, 1.16.4, 1.16.5, 1.17, 1.17.1, 1.18, 1.18.1, 1.18.2, 1.19, 1.19.1, 1.19.2, 1.19.3, 1.19.4, 1.20, 1.20.1, 1.20.2, 1.20.3, 1.20.4, 1.20.5, 1.20.6, 1.21, 1.21.1, 1.21.10, 1.21.11, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.8, 1.8.1, 1.8.2, 1.8.3, 1.8.4, 1.8.5, 1.8.6, 1.8.7, 1.8.8, 1.8.9, 1.9, 1.9.1, 1.9.2, 1.9.3, 1.9.4, 26.1, 26.1.1, 26.1.2, 26.2bukkit, folia, paper, purpur, spigot
Скачать
Что нового
The plugin is done! _Todo: MySQL / SQLite / YAML_