HLMOD.HU Forrás Megtekintés - www.hlmod.hu
  1. /* Plugin generated by AMXX-Studio */
  2.  
  3. #include <amxmodx>
  4. #include <hamsandwich>
  5.  
  6. #define PLUGIN "1 Shot 1 Kill"
  7. #define VERSION "1.0"
  8. #define AUTHOR "DarkGL"
  9.  
  10. public plugin_init()
  11. {
  12. register_plugin(PLUGIN, VERSION, AUTHOR);
  13.  
  14. RegisterHam(Ham_TakeDamage, "player", "fwDamage",0);
  15. }
  16.  
  17. public fwDamage(this, idinflictor, idattacker, Float:damage, damagebits)
  18. {
  19. if(!is_user_alive(this) || !is_user_connected(idattacker) || !(damagebits & (1<<1)) ) return HAM_IGNORED;
  20.  
  21. SetHamParamFloat(4,float(get_user_health(this) + get_user_armor(this)))
  22.  
  23. return HAM_HANDLED;
  24. }
  25.