HLMOD.HU Forrás Megtekintés - www.hlmod.hu
  1. #include <amxmodx>
  2. #include <hamsandwich>
  3. #include <fun>
  4.  
  5. new const VERSION[] = "1.0.0"
  6.  
  7. public plugin_init() {
  8. register_plugin("SpawnBug Fix", VERSION, "NapoleoN#")
  9. RegisterHam(Ham_Spawn, "player", "fw_player_spawn", 1)
  10. }
  11.  
  12. public fw_player_spawn(id) {
  13. new szMap[32]; get_mapname(szMap, charsmax(szMap))
  14. if(containi(szMap, "35hp")) {
  15. if(get_user_health(id) != 35) {
  16. set_task(1.0, "Set35HP", id)
  17. }
  18. }
  19. if(containi(szMap, "1hp")) {
  20. if(get_user_health(id) != 1) {
  21. set_task(2.5, "Set1HP", id)
  22. }
  23. }
  24. else {
  25. return PLUGIN_HANDLED
  26. }
  27. return PLUGIN_CONTINUE
  28. }
  29.  
  30. public Set35HP(id) {
  31. set_user_health(id, 35)
  32. }
  33.  
  34. public Set1HP(id) {
  35. set_user_health(id, 1)
  36. }
  37. /* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
  38. *{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang2067\\ f0\\ fs16 \n\\ par }
  39. */
  40.