Files
cuberite-2a/MCServer/Plugins/Core/plugins.lua
T

18 lines
446 B
Lua
Raw Normal View History

2013-07-27 16:24:03 +01:00
function HandlePluginsCommand( Split, Player )
2013-08-11 16:00:53 +01:00
2013-07-27 16:24:03 +01:00
local PluginManager = cRoot:Get():GetPluginManager()
local PluginList = PluginManager:GetAllPlugins()
local PluginTable = {}
for k, Plugin in pairs( PluginList ) do
2013-08-11 16:00:53 +01:00
if Plugin then
table.insert( PluginTable, Plugin:GetName() )
2013-07-27 16:24:03 +01:00
end
end
2013-08-11 16:00:53 +01:00
SendMessage( Player, "There are " .. #PluginTable .. " loaded plugins" )
SendMessage( Player, table.concat( PluginTable , " " ) )
2013-07-27 16:24:03 +01:00
return true
2013-08-11 16:00:53 +01:00
end