Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*******************************
- * Criador Caio_Freeze *
- * Versao 1.1 FINAL *************************
- * Data 26/05/2012 * NAO RETIRE OS CREDITOS *
- * *************************
- ********************************/
- #include < a_samp >
- new NomesProibidos[34][MAX_PLAYER_NAME] =
- {
- "com1",
- "com2",
- "com3",
- "com4",
- "com5",
- "com6",
- "com7",
- "com8",
- "com9",
- "lpt1",
- "lpt2",
- "lpt3",
- "lpt4",
- "lpt5",
- "lpt6",
- "lpt7",
- "lpt8",
- "lpt9",
- "Carl",
- "Rocky",
- "Sony",
- "clock$",
- "prn",
- "nul",
- "con",
- "Azucar",
- "CON",
- "con",
- "con1",
- "aux",
- "aux1",
- "prn",
- "PRN",
- "AUX"
- };
- public OnFilterScriptInit()
- {
- print("\n-------- Anti Nick --------");
- print("\n Anti Nick Ligado ");
- print("\n-------- Anti Nick --------");
- print("\n\n\n\n");
- print("|- - - - FilterScript - - - -|");
- print("| Criado Por Caio_Freeze |");
- print("|- - - - FilterScript - - - -|");
- return 1;
- }
- public OnFilterScriptExit()
- {
- print("\n-------- Anti Nick --------");
- print("\n Anti Nick Desligado ");
- print("\n-------- Anti Nick --------");
- print("\n\n\n\n");
- print("|- - - - FilterScript - - - -|");
- print("| Criado Por Caio_Freeze |");
- print("|- - - - FilterScript - - - -|");
- return 1;
- }
- public OnPlayerConnect(playerid)
- {
- for(new i; i<sizeof(NomesProibidos); i++)
- {
- new String[150],Nick[MAX_PLAYER_NAME];
- new ip[24];
- GetPlayerIp(playerid, ip, 24);
- GetPlayerName(playerid, Nick, sizeof(Nick));
- if(!strcmp(Nick, NomesProibidos[i], true))
- {
- SendClientMessage(playerid, 0xFFFF00AA, "[INFO-NICK] Você Foi Banido/Kickado Do Servidor Por Usar Um Nick Proibido!");
- format(String, sizeof(String), "[Anti Nick's] O Jogador %s Foi Kickado/Banido Por Tentar Entrar Com Nick Proibido IP do FDP: %s", Nick, ip);
- SendClientMessageToAll(0xFF0000AA, String);
- BanEx(playerid, "-=[Nick Proibido]=-");
- Kick(playerid);
- WriteLog("NicksProibidos", String);
- }
- }
- return 1;
- }
- stock WriteLog(filename[],text[])
- {
- printf("%s => %s", filename, text);
- new File:file;
- new filepath[256], string[150], year,day,month, hour,minute,second;
- getdate(year,day,month); gettime(hour,minute,second);
- format(filepath,sizeof(filepath),"/Anti-Nicks/%s.log",filename);
- file = fopen(filepath,io_append);
- format(string,sizeof(string),"[%02d/%02d/%d|%02d:%02d:%02d] %s\r\n",day,month,year,hour,minute,second,text);
- fwrite(file,string);
- fclose(file);
- return 1;
- }
- /*******************************
- * Criador Caio_Freeze *
- * Versao 1.1 FINAL *************************
- * Data 26/05/2012 * NAO RETIRE OS CREDITOS *
- * *************************
- ********************************/
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement