Advertisement
GaMeRFoReVeR

Untitled

Jul 27th, 2015
449
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 1.06 KB | None | 0 0
  1. /* Plugin generated by AMXX-Studio */
  2.  
  3. #include <amxmodx>
  4. #include <amxmisc>
  5.  
  6. #define PLUGIN "Simple Aim Blocker"
  7. #define VERSION "1.0"
  8. #define AUTHOR "GaMeR FoReVeR"
  9.  
  10. new pOKills[33], pHeads[33], pSteamID[33][33];
  11.  
  12. public plugin_init()
  13. {
  14.     register_plugin(PLUGIN, VERSION, AUTHOR);
  15.    
  16.     register_event("DeathMsg", "DeathMsg", "a");
  17. }
  18.  
  19. public client_putinserver(id)
  20. {
  21.     get_user_authid(id, pSteamID[id], 31);
  22. }
  23.  
  24. public DeathMsg()
  25. {
  26.     new Attacker = read_data(1);
  27.     new Victim = read_data(2);
  28.     new Hs = read_data(3);
  29.    
  30.     if(!is_user_connected(Attacker) || !is_user_connected(Victim) || Attacker == Victim)
  31.         return PLUGIN_HANDLED;
  32.    
  33.     if(Hs)
  34.         pHeads[Attacker]++;
  35.     else
  36.         pOKills[Attacker]++;
  37.    
  38.     AimCheck(Attacker);
  39.     return PLUGIN_CONTINUE;
  40. }
  41.  
  42. public AimCheck(id)
  43. {
  44.     if(!is_user_connected(id))
  45.         return PLUGIN_HANDLED;
  46.    
  47.     if(pHeads[id] > pOKills[id])
  48.     {
  49.         new Percent = pHeads[id]-pOKills[id];
  50.         new Ammount = Percent/pOKills[id];
  51.        
  52.         if(Ammount > 9)
  53.             server_cmd("amx_ban %s 0 aimbot", pSteamID[id]);
  54.     }
  55.     return PLUGIN_CONTINUE;
  56. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement