From 6f22d14206824911b620ecec450689f84e6d278b Mon Sep 17 00:00:00 2001 From: SmallJoker Date: Sun, 1 Jul 2018 12:31:28 +0200 Subject: Make the server status message customizable (#7357) Remove now redundant setting show_statusline_on_connect Improve documentation of `minetest.get_server_status` --- builtin/game/chatcommands.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'builtin/game/chatcommands.lua') diff --git a/builtin/game/chatcommands.lua b/builtin/game/chatcommands.lua index d56f2112b..4aef063de 100644 --- a/builtin/game/chatcommands.lua +++ b/builtin/game/chatcommands.lua @@ -799,7 +799,11 @@ core.register_chatcommand("rollback", { core.register_chatcommand("status", { description = "Show server status", func = function(name, param) - return true, core.get_server_status() + local status = core.get_server_status(name, false) + if status and status ~= "" then + return true, status + end + return false, "This command was disabled by a mod or game" end, }) -- cgit v1.2.3