Advertisement
Guest User

Untitled

a guest
Mar 26th, 2019
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.78 KB | None | 0 0
  1. Riječ je o Ping Limitu da ispiše gore iznad para
  2.  
  3. /*Ovo je po meni unikatan sistem nema ga bas na serverima
  4. */
  5. new bool: USE_ANTI_HIGHPING = false;
  6.  
  7. // Maksimalan ping prije kicka igraca
  8. #define MAX_PING 650
  9. new PingTimer[MAX_PLAYERS];
  10. // PacketLoos kao na Counter Strike 1.6 hhhh Ajstajn war einer!
  11. new PlayerText: FPSPingPacket[MAX_PLAYERS]; // Pokazuje FPS Loost
  12.  
  13. // TextDraw Paketici <3!
  14. LoadPlayerTextDraws(playerid)
  15. {
  16. FPSPingPacket[playerid] = CreatePlayerTextDraw(playerid,500.5, 1.4, "_");
  17. PlayerTextDrawBackgroundColor(playerid, FPSPingPacket[playerid], 0x00000044);
  18. PlayerTextDrawFont(playerid, FPSPingPacket[playerid], 1);
  19. PlayerTextDrawLetterSize(playerid, FPSPingPacket[playerid], 0.190000, 0.93000);
  20. PlayerTextDrawColor(playerid, FPSPingPacket[playerid], 16711935);
  21. PlayerTextDrawSetOutline(playerid, FPSPingPacket[playerid], 1);
  22. PlayerTextDrawSetProportional(playerid, FPSPingPacket[playerid], 1);
  23. PlayerTextDrawSetShadow(playerid, FPSPingPacket[playerid],0);
  24. PlayerTextDrawAlignment(playerid, FPSPingPacket[playerid], 1);
  25. }
  26.  
  27. KillTimer(PingTimer[playerid]); //ovo dodane ispod onPlayerDisconect
  28. PingTimer[playerid] = SetTimerEx("CheckPing",1000,1,"i",playerid); // ovo dodane ispoud Public OnPlayerSpawn
  29.  
  30. forward CheckPing(playerid);
  31. public CheckPing(playerid)
  32. {
  33. if(USE_ANTI_HIGHPING == true)
  34. {
  35. SendClientMessage(playerid, COLOR_RED, "{539600}[ANTI-CHEAT]{74D400} Kikovani ste s servera radi pinga by Ajstajn. (above 600)");
  36. if(GetPlayerPing(playerid) > MAX_PING) Kick(playerid);
  37. }
  38. }
  39.  
  40. //OVO ZNATE GDJE SE DODANE NISTE BOTOVI VALJDA >.<
  41. stock GetAntiHighPingStatus()
  42. {
  43. new status[32];
  44. if(USE_ANTI_HIGHPING == true) { status = ""COL_NICEGREEN"ENABLED"COL_WHITE""; }
  45. else { status = ""COL_NICERED"DISABLED"COL_WHITE""; }
  46. return status;
  47. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement