summaryrefslogblamecommitdiffstats
path: root/Plugins/SquirrelChatLog.nut
blob: 586e8d6e27787121b47abd0c27ecb726f966b6ea (plain) (tree)

























                                                                            
class SquirrelChatLog extends cPlugin__Squirrel
{
	constructor()
	{
		base.constructor();
	}
	
	function Initialize()
	{
		::print("SquirrelChatLog initialize()");
		this.SetName("SquirrelChatLog");
		
		local PluginManager = cRoot.Get().GetPluginManager();
		PluginManager.AddHook( this, PluginManager.E_PLUGIN_CHAT );
		return true;
	}

	function OnChat( Message, Player )
	{
		::print(Player.GetName() + ": " + Message);
	}
}


Plugin <- SquirrelChatLog();
cRoot.Get().GetPluginManager().AddPlugin( Plugin );