24.10.2011, 19:58
See.. FIRSTLY use
and i didnt get this question..
if u wanna make a health check timer...
Now this code .. will check all the time.. ALL PLAYERS.. if any player's health goes above hundread.. he be banned
pawn Код:
if(health>100)
Quote:
Helllo!,
But i fail with "Health" what can i put in? Is this possible to do ?? |
if u wanna make a health check timer...
pawn Код:
OnGameModeInit()
{
SetTimer("HealthCheck",10,1);
}
forward HealthCheck();
public HealthCheck()
{
for(new i ; i < MAX_PLAYERS ; i++)
{
if(IsPlayerConnected(i))
{
new Health = GetPlayerHealth(i);
if(Health>100)
{
Ban(i);
}
}
}
}