#include "console.h" #include "tier1/utlvector.h" void IConsole::RegisterVar( ConVar *cvar ) { } void IConsole::UnRegisterVar( ConVar *cvar ) { } ConVar *IConsole::FindVar( const char *pName ) { } void IConsole::RegisterCommand( ConVar *cvar ) { } void IConsole::UnRegisterCommand( ConVar *cvar ) { } ConCommand *IConsole::FindCommand( const char *pName ) { } void IConsole::Execute( void ) { } void IConsole::AddCommand( const char *psz ) { } void IConsole::InsertCommand( const char *psz ) { }; ConVar::ConVar( const char *pName, const char *pDefaultValue, int flags ) : ConVar(pName, pDefaultValue, flags, 0) { } ConVar::ConVar( const char *pName, const char *pDefaultValue, int flags, const char *pHelpString ) : ConVar(pName, pDefaultValue, flags, pHelpString, 0) { } ConVar::ConVar( const char *pName, const char *pDefaultValue, int flags, const char *pHelpString, ConCommandFn callback ) { m_szName = CUtlString(pName); m_flags = flags; m_szValue = pDefaultValue; m_fValue = V_atof(pDefaultValue); m_nValue = V_atoi(pDefaultValue); IConsole::RegisterVar(this); } bool ConVar::IsFlagSet( int flag ) { } const char *ConVar::GetHelpText( void ) { } bool ConVar::IsRegistered( void ) { } const char *ConVar::GetName( void ) { } void ConVar::AddFlags( int flags ) { } bool ConVar::IsCommand( void ) { } void ConVar::InstallChangeCallback( ConCommandFn ) { } float ConVar::GetFloat( void ) { return m_fValue; } int ConVar::GetInt( void ) { return m_nValue; } bool ConVar::GetBool( void ) { return m_nValue; } const char *ConVar::GetString( void ) { } void ConVar::SetValue( const char *szValue ) { if (!szValue) return; m_szValue = szValue; m_fValue = V_atof(szValue); m_nValue = V_atoi(szValue); } void ConVar::SetValue( float fValue ) { m_fValue = fValue; m_nValue = fValue; m_szValue = CUtlString("%f\n",fValue); } void ConVar::SetValue( int iValue ) { m_fValue = iValue; m_nValue = iValue; m_szValue = CUtlString("%i\n",iValue); }