Skip to content

Commit 0e75eb4

Browse files
Splizardest31
Splizard
authored andcommitted
Add admin command which says who the administator is for the server.
1 parent c4e0d95 commit 0e75eb4

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

builtin/game/chatcommands.lua

+12
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,18 @@ core.register_chatcommand("me", {
8484
end,
8585
})
8686

87+
core.register_chatcommand("admin", {
88+
description = "Show the name of the server owner",
89+
func = function(name)
90+
local admin = minetest.setting_get("name")
91+
if admin then
92+
return true, "The administrator of this server is "..admin.."."
93+
else
94+
return false, "There's no administrator named in the config file."
95+
end
96+
end,
97+
})
98+
8799
core.register_chatcommand("help", {
88100
privs = {},
89101
params = "[all/privs/<cmd>]",

0 commit comments

Comments
 (0)