Text values are text snapshots.
Connection
| Function | Returns |
|---|---|
server.address() |
Server address, nil in singleplayer |
server.ping() |
Your ping in ms |
server.brand() |
"vanilla", "paper", …; nil until the server says |
Tab list
| Function | Returns |
|---|---|
server.tablist.header() |
Custom header, or nil |
server.tablist.footer() |
Custom footer, or nil |
server.tablist.entries() |
Listed players in tab order |
An entry is {name, uuid, display_name, ping, gamemode}: account name, the rendered row with
team styling, latency in ms, and a gamemode like "survival".
for i, entry in ipairs(server.tablist.entries()) do
print(i, entry.display_name:string(), entry.ping .. "ms")
endBoss bars
server.bossbars() returns every visible bar in display order as
{uuid, name, percent, color, style}:
nameis a text componentpercentruns0..1coloris"pink"·"blue"·"red"·"green"·"yellow"·"purple"·"white"styleis"progress"·"notched_6"·"notched_10"·"notched_12"·"notched_20"
for _, bar in ipairs(server.bossbars() or {}) do
print(bar.name:string(), math.floor(bar.percent * 100) .. "%")
end