metamod/mutil.cpp
branchB-work
changeset 143 c8bb186f5851
parent 141 701dd0890b79
child 149 610def0c5b51
     1.1 --- a/metamod/mutil.cpp	Mon Aug 08 20:18:11 2005 +0000
     1.2 +++ b/metamod/mutil.cpp	Thu Aug 18 16:47:27 2005 +0000
     1.3 @@ -358,6 +358,19 @@
     1.4  	return (int)meta_errno;
     1.5  }
     1.6  
     1.7 +const char *mutil_IsQueryingClientCvar(plid_t plid, const edict_t *pEdict)
     1.8 +{
     1.9 +	int index = ENTINDEX(const_cast<edict_t *>(pEdict));
    1.10 +
    1.11 +	if (index < 1 || index > gpGlobals->maxClients)
    1.12 +	{
    1.13 +		return NULL;
    1.14 +		RETURN_ERRNO(NULL, ME_NOTFOUND);
    1.15 +	}
    1.16 +
    1.17 +	return g_Players[index].cvarName;
    1.18 +}
    1.19 +
    1.20  #ifdef UNFINISHED
    1.21  int mutil_HookGameEvent(plid_t plid, game_event_t event, 
    1.22  		event_func_t pfnHandle) 
    1.23 @@ -412,6 +425,7 @@
    1.24  	mutil_LoadMetaPlugin,	// pfnLoadPlugin
    1.25  	mutil_UnloadMetaPlugin, // pfnUnloadPlugin
    1.26  	mutil_UnloadMetaPluginByHandle, //pfnUnloadPluginByHandle
    1.27 +	mutil_IsQueryingClientCvar, //pfnIsQueryingClientCvar
    1.28  #ifdef UNFINISHED
    1.29  	mutil_HookGameEvent,	// pfnGameEvent
    1.30  	mutil_HookLogTrigger,	// pfnLogTrigger