summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornielsbreu@gmail.com <nielsbreu@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-04-03 18:30:02 +0200
committernielsbreu@gmail.com <nielsbreu@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-04-03 18:30:02 +0200
commitb72b7c33ac51a6c11827b40e956c30e7bc31d9d3 (patch)
tree19bf1f2bd6c5de3bcf3a465ce35dcfaec0744f75
parentServer: removed the artificial cap on reported tick duration (diff)
downloadcuberite-b72b7c33ac51a6c11827b40e956c30e7bc31d9d3.tar
cuberite-b72b7c33ac51a6c11827b40e956c30e7bc31d9d3.tar.gz
cuberite-b72b7c33ac51a6c11827b40e956c30e7bc31d9d3.tar.bz2
cuberite-b72b7c33ac51a6c11827b40e956c30e7bc31d9d3.tar.lz
cuberite-b72b7c33ac51a6c11827b40e956c30e7bc31d9d3.tar.xz
cuberite-b72b7c33ac51a6c11827b40e956c30e7bc31d9d3.tar.zst
cuberite-b72b7c33ac51a6c11827b40e956c30e7bc31d9d3.zip
-rw-r--r--MCServer/Plugins/Core/listgroups.lua14
1 files changed, 14 insertions, 0 deletions
diff --git a/MCServer/Plugins/Core/listgroups.lua b/MCServer/Plugins/Core/listgroups.lua
new file mode 100644
index 000000000..da9a6ce67
--- /dev/null
+++ b/MCServer/Plugins/Core/listgroups.lua
@@ -0,0 +1,14 @@
+function HandleListGroupsCommand( Split, Player )
+ local GroupsIni = cIniFile("groups.ini")
+ if GroupsIni:ReadFile() == false then
+ Player:SendMessage( cChatColor.Green .. "No groups found" )
+ end
+ Number = GroupsIni:NumKeys()
+ Groups = {}
+ for i=0, Number do
+ table.insert( Groups, GroupsIni:KeyName(i) )
+ end
+ Player:SendMessage( cChatColor.Green .. "Groups:" )
+ Player:SendMessage( cChatColor.Green .. table.concat( Groups, ", " ) )
+ return true
+end \ No newline at end of file