diff options
author | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2013-01-13 12:10:26 +0100 |
---|---|---|
committer | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2013-01-13 12:10:26 +0100 |
commit | 752057fb1b3a71058b5391bde9b0e21d87196539 (patch) | |
tree | cfeb16a291ce13dc8408a82459224f029f56cd2f /MCServer/Plugins/ChatLog/plugin.lua | |
parent | Merged branch "branches/hooks" into "trunk". (diff) | |
download | cuberite-752057fb1b3a71058b5391bde9b0e21d87196539.tar cuberite-752057fb1b3a71058b5391bde9b0e21d87196539.tar.gz cuberite-752057fb1b3a71058b5391bde9b0e21d87196539.tar.bz2 cuberite-752057fb1b3a71058b5391bde9b0e21d87196539.tar.lz cuberite-752057fb1b3a71058b5391bde9b0e21d87196539.tar.xz cuberite-752057fb1b3a71058b5391bde9b0e21d87196539.tar.zst cuberite-752057fb1b3a71058b5391bde9b0e21d87196539.zip |
Diffstat (limited to '')
-rw-r--r-- | MCServer/Plugins/ChatLog/plugin.lua | 27 |
1 files changed, 21 insertions, 6 deletions
diff --git a/MCServer/Plugins/ChatLog/plugin.lua b/MCServer/Plugins/ChatLog/plugin.lua index 0288d1aa9..9ef321b48 100644 --- a/MCServer/Plugins/ChatLog/plugin.lua +++ b/MCServer/Plugins/ChatLog/plugin.lua @@ -1,15 +1,30 @@ -function Initialize( Plugin )
- Plugin:SetName( "ChatLog" )
- Plugin:SetVersion( 2 )
+
+-- plugin.lua
+
+-- Implements the main entrypoint for the plugin, as well as all the handling needed
+
+-- ChatLog plugin logs all chat messages into the server log
+
+
+
+
+
+function Initialize(Plugin)
+ Plugin:SetName("ChatLog")
+ Plugin:SetVersion(3)
PluginManager = cRoot:Get():GetPluginManager()
- PluginManager:AddHook( Plugin, cPluginManager.E_PLUGIN_CHAT )
+ PluginManager:AddHook(Plugin, cPluginManager.HOOK_CHAT)
- LOG( "Initialized " .. Plugin:GetName() .. " v." .. Plugin:GetVersion() )
+ LOG("Initialized " .. Plugin:GetName() .. " v." .. Plugin:GetVersion())
return true
end
-function OnChat( Player, Message )
+
+
+
+
+function OnChat(Player, Message)
-- Lets get loggin'
LOGINFO("[" .. Player:GetName() .. "]: " .. Message);
|