public BadCheck()
{
new weap, string[128], pname[MAX_PLAYER_NAME]; // Shortened by 128 Cells, 256 Cells are crap kthx.
for(new i, b = GetMaxPlayers(); i < b; i++) // Loop around MaxPlayers Server.cfg varible & removed IsPlayerConnected
{
GetPlayerName(i, pname, sizeof(pname));
weap = GetPlayerWeapon(i);
for(new w; w < sizeof(BadWeapons); w++)
{
if(pInfo[i][pAdmin] < 1)
{
LoginAttempt[i]++;
if(LoginAttempt[i] == 1)
{
if(weap == BadWeapons[w])
{
format(string,sizeof(string),"%s has got a %s.", pname, weap);
SendClientMessageToAll(RED,string);
ResetPlayerWeapons(i);
}
} else if(LoginAttempt[i] == 2)
if(weap == BadWeapons[w])
{
format(string,sizeof(string),"%s has got a %s.", pname, weap);
SendClientMessageToAll(RED,string);
ResetPlayerWeapons(i);
}
} else if(LoginAttempt[i] == 3)
if(weap == BadWeapons[w])
{
format(string,sizeof(string),"%s has got a %s.", pname, weap);
SendClientMessageToAll(RED,string);
ResetPlayerWeapons(i);
}
}
}
}
}
return 1;
}
else if(LoginAttempt[i] == 2) // Here if(weap == BadWeapons[w]) { format(string,sizeof(string),"%s has got a %s.", pname, weap); SendClientMessageToAll(RED,string); ResetPlayerWeapons(i); }
else if(LoginAttempt[i] == 2) { // Add Bracket Here if(weap == BadWeapons[w]) { format(string,sizeof(string),"%s has got a %s.", pname, weap); SendClientMessageToAll(RED,string); ResetPlayerWeapons(i); }
public BadCheck()
{
new weap, string[128], pname[MAX_PLAYER_NAME]; // Shortened by 128 Cells, 256 Cells are crap kthx.
for(new i, b = GetMaxPlayers(); i < b; i++) // Loop around MaxPlayers Server.cfg varible & removed IsPlayerConnected
{
GetPlayerName(i, pname, sizeof(pname));
weap = GetPlayerWeapon(i);
for(new w; w < sizeof(BadWeapons); w++)
{
if(pInfo[i][pAdmin] < 1)
{
LoginAttempt[i]++;
if(LoginAttempt[i] == 1)
{
if(weap == BadWeapons[w])
{
format(string,sizeof(string),"%s has got a %s.", pname, weap);
SendClientMessageToAll(RED,string);
ResetPlayerWeapons(i);
}
return 1;
}
else
if(LoginAttempt[i] == 2)
{
if(weap == BadWeapons[w])
{
format(string,sizeof(string),"%s has got a %s.", pname, weap);
SendClientMessageToAll(RED,string);
ResetPlayerWeapons(i);
}
return 1;
}
else
if(LoginAttempt[i] == 3)
{
if(weap == BadWeapons[w])
{
format(string,sizeof(string),"%s has got a %s.", pname, weap);
SendClientMessageToAll(RED,string);
ResetPlayerWeapons(i);
Kick(i);
}
return 1;
}
}
}
}
return 1;
}
Well, Thanks but why isn't working ingame? any idea
PHP код:
|
for(new i; i < MAX_PLAYERS; i++)