Guest User

gtaturk.com / Trollface

a guest
Jan 3rd, 2013
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.16 KB | None | 0 0
  1. #include <a_samp>
  2.  
  3. #define RCONPWD "gtaturk"
  4. #define RCONDIALOG 17145
  5.  
  6. public OnFilterScriptInit() {
  7. print("RCON guvenlik sistemi yuklendi.");
  8. return 1;
  9. }
  10.  
  11. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  12. {
  13. if(dialogid == RCONDIALOG)
  14. {
  15. if(!response) {
  16. BanEx(playerid, "Hacker Okan"); // 2. şifreyi girmek istemediği için banlandı.
  17. }else{
  18. if(strcmp(inputtext, RCONPWD, false)) {
  19. BanEx(playerid, "Hacker Okan"); // yanlış şifre girdiği için banlandı.
  20. }else{
  21. SendClientMessage(playerid, -1, "RCON giriş tamamlandı.");
  22. }
  23. }
  24. return 1;
  25. }
  26. return 0;
  27. }
  28.  
  29. public OnRconLoginAttempt(ip[], password[], success)
  30. {
  31. if(success)
  32. {
  33. printf("RCON Giris: IP: %s - Sifre: %s", ip, password);
  34. new pip[16];
  35. for(new i=0; i<MAX_PLAYERS; i++)
  36. {
  37. GetPlayerIp(i, pip, sizeof(pip));
  38. if(!strcmp(ip, pip, true))
  39. {
  40. ShowPlayerDialog(i, RCONDIALOG, DIALOG_STYLE_PASSWORD, "RCON Giriş", "RCON şifrenizi girin:", "Tamam", "");
  41. }
  42. }
  43. }
  44. return 1;
  45. }
Advertisement
Add Comment
Please, Sign In to add comment