diff options
author | red-001 <red-001@outlook.ie> | 2017-04-01 12:40:56 +0100 |
---|---|---|
committer | Loïc Blot <nerzhul@users.noreply.github.com> | 2017-04-01 13:40:56 +0200 |
commit | 63ac62ec8abe30f0d6dd2cfe0ddaab291c36893f (patch) | |
tree | 76707d22d37fc2fd29e5c5326f3848780599eb36 /clientmods/preview | |
parent | 813a9a36b22a4e2d7383622311b6f52e31a94733 (diff) | |
download | minetest-63ac62ec8abe30f0d6dd2cfe0ddaab291c36893f.tar.gz minetest-63ac62ec8abe30f0d6dd2cfe0ddaab291c36893f.tar.bz2 minetest-63ac62ec8abe30f0d6dd2cfe0ddaab291c36893f.zip |
[CSM] Add function and chat command to disconnect from server. (#5487)
Diffstat (limited to 'clientmods/preview')
-rw-r--r-- | clientmods/preview/init.lua | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/clientmods/preview/init.lua b/clientmods/preview/init.lua index c57a62155..07464e927 100644 --- a/clientmods/preview/init.lua +++ b/clientmods/preview/init.lua @@ -127,3 +127,10 @@ core.register_chatcommand("list_players", { core.display_chat_message(dump(core.get_player_names())) end }) + +core.register_chatcommand("disconnect", { + description = "Exit to main menu", + func = function(param) + core.disconnect() + end, +}) |