dvander@371: /** dvander@371: * vim: set ts=4 : dvander@371: * ====================================================== dvander@371: * Metamod:Source ds@523: * Copyright (C) 2004-2008 AlliedModders LLC and authors. dvander@371: * All rights reserved. dvander@371: * ====================================================== dvander@371: * dvander@371: * This software is provided 'as-is', without any express or implied warranty. dvander@371: * In no event will the authors be held liable for any damages arising from dvander@371: * the use of this software. dvander@371: * dvander@371: * Permission is granted to anyone to use this software for any purpose, dvander@371: * including commercial applications, and to alter it and redistribute it dvander@371: * freely, subject to the following restrictions: dvander@371: * dvander@371: * 1. The origin of this software must not be misrepresented; you must not dvander@371: * claim that you wrote the original software. If you use this software in a dvander@371: * product, an acknowledgment in the product documentation would be dvander@371: * appreciated but is not required. dvander@371: * 2. Altered source versions must be plainly marked as such, and must not be dvander@371: * misrepresented as being the original software. dvander@371: * 3. This notice may not be removed or altered from any source distribution. dvander@371: * dvander@371: * Version: $Id$ dvander@371: */ dvander@371: dvander@371: #include "console.h" dvander@371: #include "provider_ep2.h" dvander@371: dvander@371: using namespace SourceHook; dvander@371: dvander@371: SMConVarAccessor g_SMConVarAccessor; dvander@371: dvander@371: bool SMConVarAccessor::RegisterConCommandBase(ConCommandBase *pCommand) dvander@371: { dvander@371: pCommand->SetNext(NULL); dvander@371: icvar->RegisterConCommand(pCommand); dvander@371: dvander@371: return true; dvander@371: } dvander@371: dvander@371: bool SMConVarAccessor::Register(ConCommandBase *pCommand) dvander@371: { dvander@371: pCommand->SetNext(NULL); dvander@371: icvar->RegisterConCommand(pCommand); dvander@371: dvander@371: return true; dvander@371: } dvander@371: dvander@371: void SMConVarAccessor::Unregister(ConCommandBase *pCommand) dvander@371: { dvander@371: icvar->UnregisterConCommand(pCommand); dvander@371: } dvander@371: