Why the raw Bukkit API makes your sidebar flicker, the Teams fix, the exact point where FastBoard becomes mandatory, how often to refresh without eating TPS, and where money, rank and ping data really comes from.
Because in the Bukkit API the visible text is the key of the line. As soon as the text changes, the line has to be removed and recreated, and between those two packets the client draws an incomplete sidebar. The fix is to pin invisible keys and let a Team prefix carry the text, which is an in-place update.
Because in the Bukkit API the visible text is the key of the line. As soon as the text changes, the line has to be removed and recreated, and between those two packets the client draws an incomplete sidebar. The fix is to pin invisible keys and let a Team prefix carry the text, which is an in-place update.
Every 20 ticks, once per second, is enough in almost every case. A 15 line sidebar refreshed every tick for 100 players is 30,000 line updates per second, against 1,500 at one refresh per second, for a visually identical result.
Online player count and ping live in memory and are free. Rank comes from LuckPerms or Vault. Money comes from the Vault Economy service, which often hides a SQL query, so it must be read asynchronously and cached, never from the render loop.