Fix broken server status line in 5.5+
parent
159ede89d4
commit
9664255b3e
|
@ -105,7 +105,7 @@ minetest.after(0, function()
|
|||
end)
|
||||
|
||||
local function stripstatus(msg, ...)
|
||||
local pref, clients, suff = string_match(msg, "^(.*)clients={([^}]*)}(.*)$")
|
||||
local pref, clients, suff = string_match(msg, "^(.*clients[^%w_]+)([^}]*)(.*)$")
|
||||
if not clients then return msg, ... end
|
||||
local clist = {}
|
||||
for pname in string_gmatch(clients, "%S+") do
|
||||
|
@ -116,7 +116,7 @@ local function stripstatus(msg, ...)
|
|||
clist[#clist + 1] = pname
|
||||
end
|
||||
end
|
||||
msg = pref .. "clients={" .. table_concat(clist, ", ") .. "}" .. suff
|
||||
msg = pref .. table_concat(clist, ", ") .. suff
|
||||
return msg, ...
|
||||
end
|
||||
local oldstatus = minetest.get_server_status
|
||||
|
|
Loading…
Reference in New Issue