06.02.2014, 00:58
pawn Код:
public OnPlayerConnect(playerid)
{
new string[64]; // Create the string to store the read text in
new File:example = fopen("Startup.txt", io_read); // Open the file
if(example) // If the file opened sucessfully
{
while(fread(example, string)) // Reads the file line-by-line in a loop
{
if(strcmp(string, "Ban", true) == 0) //if any of the lines in the file say "Ban" the system will ban the player
{
Ban(playerid); //bans the player
}
}
fclose(example);
}
return 1;
}