Skip to content
This repository has been archived by the owner on Apr 9, 2024. It is now read-only.

v1.11.0: Improve Player caching

Compare
Choose a tag to compare
@Andre601 Andre601 released this 10 Jan 19:48
· 1030 commits to master since this release
3859f29

This update improves the way players are cached. It brings somewhat breaking changes.

New Player caching

AdvancedServerList now stores cached players as a JSON Array of JSON objects in a playercache.json file.
When a player joins your server/network will it now collect and save the following information when disabling:

  • IP for identification
  • Player name
  • Player UUID

A quick example using myself (actual file would be minified by Gson):

[
  {
    "ip": "127.0.0.1",
    "name": "Andre_601",
    "uuid": "286f8d0c-b571-4720-b7ab-f2929cb38120"
  }
]

Placeholder changes

With the above changes are there also changes to the available placeholders.
Namely, ${player uuid} can now be used across all platforms and not just Spigot/Paper like in the previous versions.

In addition was a new option called unknown_player_uuid added to the config.yml. This String option would have the UUID used for ${player uuid} should the pinging player be unknown (not cached) by AdvancedServerList yet.
It defaults to 606e2ff0-ed77-4842-9d6c-e1d3321c7838 which is the UUID of MHF_Question.

OfflinePlayer handling in Spigot and Paper

With the Cache changes were also changes made to how AdvancedServerList obtains OfflinePlayer instances. It now uses UUID instead of player names to obtain an OfflinePlayer instance.

Please let me know if this has any unwanted side-effects for you.

What comes next?

The next major plan is to release v2 of AdvancedServerList, which brings an API for providing your own Placeholder values! You can check out #38 for further info and progress (Spoiler: It's pretty much done by now).