Guest User

FS made by RASCAL

a guest
Oct 15th, 2010
308
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.74 KB | None | 0 0
  1. /* Filterscripta napravljena 15.10.2010. godine.
  2. FS napravio rascal
  3. Nemojte brisati CREDISE,iako znam da ce vas to vecina uraditi
  4. Eto nadam se da sam nekome pomogao
  5. Nisam optimizirao FS,jer sam ovo radio na brzinu...
  6. Vreme rada 2h.. :D
  7. */
  8.  
  9. #include <a_samp>
  10. #define MaxBrzina 230
  11. #define Crvena 0xFF0000AA
  12. new BrzinaHacker[MAX_PLAYERS];
  13.  
  14. forward Brzina();
  15. #if defined FILTERSCRIPT
  16.  
  17. public OnFilterScriptInit()
  18. {
  19. SetTimer("Brzina",5000,1);
  20. print("\n--------------------------------------");
  21. print(" AntiBrzinaHack filterscripta ucitana");
  22. print("made by: rascal\n");
  23. return 1;
  24. }
  25.  
  26. public OnFilterScriptExit()
  27. {
  28. return 1;
  29. }
  30.  
  31. #else
  32.  
  33. main()
  34. {
  35. print("\n----------------------------------");
  36. print(" Ovaj server koristi FS AntiSpeedHack");
  37. print("made by: rascal\n");
  38. }
  39.  
  40. #endif
  41.  
  42.  
  43.  
  44.  
  45. public Brzina()
  46. {
  47. for(new i = 0; i < MAX_PLAYERS; i++)
  48. {
  49. if(IsPlayerConnected(i) == 1)
  50. {
  51. if(IgracevaBrzina(i) >= MaxBrzina)
  52. {
  53.  
  54. if(!IsPlayerAdmin(i))
  55. {
  56. new playerState = GetPlayerState(i);
  57. if(playerState == PLAYER_STATE_DRIVER)
  58. {
  59. new Vozilo = GetVehicleModel(GetPlayerVehicleID(i));
  60. if(Vozilo == 592 || Vozilo== 577 ||Vozilo == 511 || Vozilo == 512
  61. || Vozilo == 593 || Vozilo== 520 || Vozilo== 553 || Vozilo == 476
  62. || Vozilo== 519 || Vozilo == 460 ||Vozilo == 513|| Vozilo == 425)
  63. {
  64. return 1;
  65. }
  66. else
  67. {
  68. BrzinaHacker[i] += 1;
  69. new ime[MAX_PLAYER_NAME], string[128];
  70. GetPlayerName(i, ime, sizeof(ime));
  71. format(string, sizeof(string), "AntiCheat: %s[%d] mozda koristi SpeedHack! Provjerite ga!", ime, i, i);
  72. SendClientMessageToAll(Crvena, string);
  73. }
  74. if(BrzinaHacker[i] >= 3)
  75. {
  76. new ime[MAX_PLAYER_NAME], string[128];
  77. GetPlayerName(i, ime, sizeof(ime));
  78. format(string, sizeof(string), "AntiCheat: %s je banovan sa servera. Razlog: SpeedHack!", ime);
  79. SendClientMessageToAll(Crvena, string);
  80. Ban(i);
  81. }
  82. }
  83. }
  84.  
  85. }
  86. }
  87. }
  88. return 1;
  89. }
  90. stock IgracevaBrzina(playerid)
  91. {
  92. new Float:ST[4];
  93. if(IsPlayerInAnyVehicle(playerid))
  94. GetVehicleVelocity(GetPlayerVehicleID(playerid),ST[0],ST[1],ST[2]);
  95. else GetPlayerVelocity(playerid,ST[0],ST[1],ST[2]);
  96. ST[3] = floatsqroot(floatpower(floatabs(ST[0]), 2.0) + floatpower(floatabs(ST[1]), 2.0) + floatpower(floatabs(ST[2]), 2.0)) * 179.28625;
  97. return floatround(ST[3]);
  98. }
Advertisement
Add Comment
Please, Sign In to add comment