Skip to content

Commit

Permalink
Added plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
bearbin committed Jan 1, 2014
1 parent e8677bf commit 983d23c
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions plugin.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@

-- 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)

cPluginManager.AddHook(cPluginManager.HOOK_CHAT, OnChat)

LOG("Initialized " .. Plugin:GetName() .. " v." .. Plugin:GetVersion())
return true
end





function OnChat(Player, Message)
-- Lets get loggin'
LOGINFO("[" .. Player:GetName() .. "]: " .. StripColorCodes(Message));

return false
end

0 comments on commit 983d23c

Please sign in to comment.