PlayerVisibilty: Make it work w/o zombiereloaded.
This commit is contained in:
parent
ac71ba9e63
commit
dd9ac93b61
@ -33,6 +33,8 @@ int g_iMinPlayers;
|
|||||||
int g_Client_Alpha[MAXPLAYERS + 1] = {255, ...};
|
int g_Client_Alpha[MAXPLAYERS + 1] = {255, ...};
|
||||||
bool g_Client_bEnabled[MAXPLAYERS + 1] = {false, ...};
|
bool g_Client_bEnabled[MAXPLAYERS + 1] = {false, ...};
|
||||||
|
|
||||||
|
bool g_Plugin_zombiereloaded = false;
|
||||||
|
|
||||||
public void OnPluginStart()
|
public void OnPluginStart()
|
||||||
{
|
{
|
||||||
Handle hGameConf = LoadGameConfigFile("sdktools.games");
|
Handle hGameConf = LoadGameConfigFile("sdktools.games");
|
||||||
@ -79,6 +81,11 @@ public void OnPluginStart()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void OnAllPluginsLoaded()
|
||||||
|
{
|
||||||
|
g_Plugin_zombiereloaded = LibraryExists("zombiereloaded");
|
||||||
|
}
|
||||||
|
|
||||||
public void OnPluginEnd()
|
public void OnPluginEnd()
|
||||||
{
|
{
|
||||||
for(int client = 1; client <= MaxClients; client++)
|
for(int client = 1; client <= MaxClients; client++)
|
||||||
@ -254,7 +261,7 @@ public void OnPostThinkPost(int client)
|
|||||||
if(i == client || !IsClientInGame(i) || !IsPlayerAlive(i))
|
if(i == client || !IsClientInGame(i) || !IsPlayerAlive(i))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if(!ZR_IsClientHuman(i))
|
if(g_Plugin_zombiereloaded && !ZR_IsClientHuman(i))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
static float fVec1[3];
|
static float fVec1[3];
|
||||||
|
Loading…
Reference in New Issue
Block a user