Page 2 of 2

Re: Knife Menu!

Posted: 25 Apr 2019, 14:13
by Luxurious
Plasma VIP_A
Storm VIP_F
Laevateinn VIP_i
WarHammer Dark Night VIP_l
Balrog Kosa VIP_l
Were Wolf VIP_l
Dead Master VIP_l
Hammer Chain VIP_i
Kataha VIP_i
WarHammer Ranger VIP_j

Re: Knife Menu!

Posted: 27 Apr 2019, 20:35
by Mark
Luxurious wrote:
3 Months Ago
Plasma VIP_A
Storm VIP_F
Laevateinn VIP_i
WarHammer Dark Night VIP_l
Balrog Kosa VIP_l
Were Wolf VIP_l
Dead Master VIP_l
Hammer Chain VIP_i
Kataha VIP_i
WarHammer Ranger VIP_j
Try this
  1. #include <zombie_escape>
  2. #include <engine>
  3. #include <fun>
  4. #include <ze_vip>
  5.  
  6. // Models
  7. new const Compat_Models[][] =
  8. {
  9.     "models/zombie_escape/v_combat_knife.mdl",
  10.     "models/zombie_escape/p_combat_knife.mdl"
  11. }
  12.  
  13. new const Strong_Models[][] =
  14. {
  15.     "models/zombie_escape/v_strong_knife.mdl",
  16.     "models/zombie_escape/p_strong_knife.mdl"
  17. }
  18.  
  19. new const Katana_Models[][] =
  20. {
  21.     "models/zombie_escape/v_katana_knife.mdl",
  22.     "models/zombie_escape/p_katana_knife.mdl"
  23. }
  24.  
  25. new const Hammer_Models[][] =
  26. {
  27.     "models/zombie_escape/v_hammer_knife.mdl",
  28.     "models/zombie_escape/p_hammer_knife.mdl"
  29. }
  30.  
  31. new const Turbulent9_Models[][] =
  32. {
  33.     "models/zombie_escape/v_turbulent9_knife.mdl",
  34.     "models/zombie_escape/p_turbulent9_knife.mdl"
  35. }
  36.  
  37. new const Bio_Models[][] =
  38. {
  39.     "models/zombie_escape/v_bio_knife.mdl",
  40.     "models/zombie_escape/p_bio_knife.mdl"
  41. }
  42.  
  43. new const Sabers_Models[][] =
  44. {
  45.     "models/zombie_escape/v_laser_knife.mdl",
  46.     "models/zombie_escape/p_laser_knife.mdl"
  47. }
  48.  
  49. new const Plasma_Models[][] =
  50. {
  51.     "models/zombie_escape/v_plasma_knife.mdl",
  52.     "models/zombie_escape/p_plasma_knife.mdl"
  53. }
  54.  
  55. new const Storm_Models[][] =
  56. {
  57.     "models/zombie_escape/v_storm_sword_knife.mdl",
  58.     "models/zombie_escape/p_storm_sword_knife.mdl"
  59. }
  60.  
  61. new const Laevateinn_Models[][] =
  62. {
  63.     "models/zombie_escape/v_laevateinn_knife.mdl",
  64.     "models/zombie_escape/p_laevateinn_knife.mdl"
  65. }
  66.  
  67. new const WarHammer_Dark_Knight_Models[][] =
  68. {
  69.     "models/zombie_escape/v_WarHammer_dark_knight_knife.mdl",
  70.     "models/zombie_escape/p_WarHammer_dark_knight_knife.mdl"
  71. }
  72.  
  73. new const Balrog_Kosa_Models[][] =
  74. {
  75.     "models/zombie_escape/v_balrog_kosa_knife.mdl",
  76.     "models/zombie_escape/p_balrog_kosa_knife.mdl"
  77. }
  78.  
  79. new const WereWolf_Models[][] =
  80. {
  81.     "models/zombie_escape/v_axe_werewolf.mdl",
  82.     "models/zombie_escape/p_axe_werewolf.mdl"
  83. }
  84.  
  85. new const DeadMaster_Models[][] =
  86. {
  87.     "models/zombie_escape/v_deadmaster_scythe.mdl",
  88.     "models/zombie_escape/p_deadmaster_scythe.mdl"
  89. }
  90.  
  91. new const HammerChain_Models[][] =
  92. {
  93.     "models/zombie_escape/v_hammer_chain.mdl",
  94.     "models/zombie_escape/p_hammer_chain.mdl"
  95. }
  96.  
  97. new const Kataha_Models[][] =
  98. {
  99.     "models/zombie_escape/v_kataha.mdl",
  100.     "models/zombie_escape/p_kataha.mdl"
  101. }
  102.  
  103. new const Ranger_Models[][] =
  104. {
  105.     "models/zombie_escape/v_warhammer-ranger.mdl",
  106.     "models/zombie_escape/p_warhammer-ranger.mdl"
  107. }
  108.  
  109. // Sounds
  110. new const g_sound_knife[] = "items/gunpickup2.wav"
  111.  
  112. new const combat_sounds[][] =
  113. {
  114.     "zombie_escape/knife_menu/combat_deploy.wav",
  115.     "zombie_escape/knife_menu/combat_hit.wav",
  116.     "zombie_escape/knife_menu/combat_hit.wav",
  117.     "zombie_escape/knife_menu/combat_hit.wav",
  118.     "zombie_escape/knife_menu/combat_hit.wav",
  119.     "zombie_escape/knife_menu/combat_hitwall.wav",
  120.     "zombie_escape/knife_menu/combat_slash.wav",
  121.     "zombie_escape/knife_menu/combat_slash.wav",
  122.     "zombie_escape/knife_menu/combat_stab.wav"
  123. }
  124.  
  125. new const strong_sounds[][] =
  126. {
  127.     "zombie_escape/knife_menu/strong_deploy.wav",
  128.     "zombie_escape/knife_menu/strong_hit.wav",
  129.     "zombie_escape/knife_menu/strong_hit.wav",
  130.     "zombie_escape/knife_menu/strong_hit.wav",
  131.     "zombie_escape/knife_menu/strong_hit.wav",
  132.     "zombie_escape/knife_menu/strong_hitwall.wav",
  133.     "zombie_escape/knife_menu/strong_slash.wav",
  134.     "zombie_escape/knife_menu/strong_slash.wav",
  135.     "zombie_escape/knife_menu/strong_stab.wav"
  136. }
  137.  
  138. new const katana_sounds[][] =
  139. {
  140.     "zombie_escape/knife_menu/katana_deploy.wav",
  141.     "zombie_escape/knife_menu/katana_hit.wav",
  142.     "zombie_escape/knife_menu/katana_hit.wav",
  143.     "zombie_escape/knife_menu/katana_hit.wav",
  144.     "zombie_escape/knife_menu/katana_hit.wav",
  145.     "zombie_escape/knife_menu/katana_hitwall.wav",
  146.     "zombie_escape/knife_menu/katana_slash.wav",
  147.     "zombie_escape/knife_menu/katana_slash.wav",
  148.     "zombie_escape/knife_menu/katana_stab.wav"
  149. }
  150.  
  151. new const hammer_sounds[][] =
  152. {
  153.     "zombie_escape/knife_menu/hammer_deploy.wav",
  154.     "zombie_escape/knife_menu/hammer_hit.wav",
  155.     "zombie_escape/knife_menu/hammer_hit.wav",
  156.     "zombie_escape/knife_menu/hammer_hit.wav",
  157.     "zombie_escape/knife_menu/hammer_hit.wav",
  158.     "zombie_escape/knife_menu/hammer_hitwall.wav",
  159.     "zombie_escape/knife_menu/hammer_slash.wav",
  160.     "zombie_escape/knife_menu/hammer_slash.wav",
  161.     "zombie_escape/knife_menu/hammer_stab.wav"
  162. }
  163.  
  164. new const turbulent9_sounds[][] =
  165. {
  166.     "zombie_escape/knife_menu/turbulent9_deploy.wav",
  167.     "zombie_escape/knife_menu/turbulent9_hit.wav",
  168.     "zombie_escape/knife_menu/turbulent9_hit.wav",
  169.     "zombie_escape/knife_menu/turbulent9_hit.wav",
  170.     "zombie_escape/knife_menu/turbulent9_hit.wav",
  171.     "zombie_escape/knife_menu/turbulent9_hitwall.wav",
  172.     "zombie_escape/knife_menu/turbulent9_slash.wav",
  173.     "zombie_escape/knife_menu/turbulent9_slash.wav",
  174.     "zombie_escape/knife_menu/turbulent9_stab.wav"
  175. }
  176.  
  177. new const bio_sounds[][] =
  178. {
  179.     "zombie_escape/knife_menu/bio_deploy.wav",
  180.     "zombie_escape/knife_menu/bio_hit.wav",
  181.     "zombie_escape/knife_menu/bio_hit.wav",
  182.     "zombie_escape/knife_menu/bio_hit.wav",
  183.     "zombie_escape/knife_menu/bio_hit.wav",
  184.     "zombie_escape/knife_menu/bio_hitwall.wav",
  185.     "zombie_escape/knife_menu/bio_slash.wav",
  186.     "zombie_escape/knife_menu/bio_slash.wav",
  187.     "zombie_escape/knife_menu/bio_stab.wav"
  188. }
  189.  
  190. new const sabers_sounds[][] =
  191. {
  192.     "zombie_escape/knife_menu/laser_deploy.wav",
  193.     "zombie_escape/knife_menu/laser_hit.wav",
  194.     "zombie_escape/knife_menu/laser_hit.wav",
  195.     "zombie_escape/knife_menu/laser_hit.wav",
  196.     "zombie_escape/knife_menu/laser_hit.wav",
  197.     "zombie_escape/knife_menu/laser_hitwall.wav",
  198.     "zombie_escape/knife_menu/laser_slash1.wav",
  199.     "zombie_escape/knife_menu/laser_slash2.wav",
  200.     "zombie_escape/knife_menu/laser_stab.wav"
  201. }
  202.  
  203. new const plasma_sounds[][] =
  204. {
  205.     "zombie_escape/knife_menu/plasma_deploy.wav",
  206.     "zombie_escape/knife_menu/plasma_hit.wav",
  207.     "zombie_escape/knife_menu/plasma_hit.wav",
  208.     "zombie_escape/knife_menu/plasma_hit.wav",
  209.     "zombie_escape/knife_menu/plasma_hit.wav",
  210.     "zombie_escape/knife_menu/plasma_hitwall.wav",
  211.     "zombie_escape/knife_menu/plasma_slash.wav",
  212.     "zombie_escape/knife_menu/plasma_slash.wav",
  213.     "zombie_escape/knife_menu/plasma_stab.wav"
  214. }
  215.  
  216. new const storm_sounds[][] =
  217. {
  218.     "zombie_escape/knife_menu/storm_sword_deploy.wav",
  219.     "zombie_escape/knife_menu/storm_sword_hit.wav",
  220.     "zombie_escape/knife_menu/storm_sword_hit.wav",
  221.     "zombie_escape/knife_menu/storm_sword_hit.wav",
  222.     "zombie_escape/knife_menu/storm_sword_hit.wav",
  223.     "zombie_escape/knife_menu/storm_sword_hitwall.wav",
  224.     "zombie_escape/knife_menu/storm_sword_slash.wav",
  225.     "zombie_escape/knife_menu/storm_sword_slash.wav",
  226.     "zombie_escape/knife_menu/storm_sword_stab.wav"
  227. }
  228.  
  229. new const laevateinn_sounds[][] =
  230. {
  231.     "zombie_escape/knife_menu/laevateinn_deploy.wav",
  232.     "zombie_escape/knife_menu/laevateinn_hit.wav",
  233.     "zombie_escape/knife_menu/laevateinn_hit.wav",
  234.     "zombie_escape/knife_menu/laevateinn_hit.wav",
  235.     "zombie_escape/knife_menu/laevateinn_hit.wav",
  236.     "zombie_escape/knife_menu/laevateinn_hitwall.wav",
  237.     "zombie_escape/knife_menu/laevateinn_slash.wav",
  238.     "zombie_escape/knife_menu/laevateinn_slash.wav",
  239.     "zombie_escape/knife_menu/laevateinn_stab.wav"
  240. }
  241.  
  242. new const warhammer_dark_knight_sounds[][] =
  243. {
  244.     "zombie_escape/knife_menu/WarHammer_dark_knight_deploy.wav",
  245.     "zombie_escape/knife_menu/WarHammer_dark_knight_hit.wav",
  246.     "zombie_escape/knife_menu/WarHammer_dark_knight_hit.wav",
  247.     "zombie_escape/knife_menu/WarHammer_dark_knight_hit.wav",
  248.     "zombie_escape/knife_menu/WarHammer_dark_knight_hit.wav",
  249.     "zombie_escape/knife_menu/WarHammer_dark_knight_hitwall.wav",
  250.     "zombie_escape/knife_menu/WarHammer_dark_knight_slash.wav",
  251.     "zombie_escape/knife_menu/WarHammer_dark_knight_slash.wav",
  252.     "zombie_escape/knife_menu/WarHammer_dark_knight_stab.wav"
  253. }
  254.  
  255. new const balrog_kosa_sounds[][] =
  256. {
  257.     "zombie_escape/knife_menu/balrog_kosa_deploy.wav",
  258.     "zombie_escape/knife_menu/balrog_kosa_hit.wav",
  259.     "zombie_escape/knife_menu/balrog_kosa_hit.wav",
  260.     "zombie_escape/knife_menu/balrog_kosa_hit.wav",
  261.     "zombie_escape/knife_menu/balrog_kosa_hit.wav",
  262.     "zombie_escape/knife_menu/balrog_kosa_hitwall.wav",
  263.     "zombie_escape/knife_menu/balrog_kosa_slash.wav",
  264.     "zombie_escape/knife_menu/balrog_kosa_slash.wav",
  265.     "zombie_escape/knife_menu/balrog_kosa_stab.wav"
  266. }
  267.  
  268. new const oldknife_sounds[][] =
  269. {
  270.     "weapons/knife_deploy1.wav",
  271.     "weapons/knife_hit1.wav",
  272.     "weapons/knife_hit2.wav",
  273.     "weapons/knife_hit3.wav",
  274.     "weapons/knife_hit4.wav",
  275.     "weapons/knife_hitwall1.wav",
  276.     "weapons/knife_slash1.wav",
  277.     "weapons/knife_slash2.wav",
  278.     "weapons/knife_stab.wav"
  279. }
  280.  
  281. new bool:g_bCompat[33], bool:g_bStrong[33], bool:g_bKatana[33], bool:g_bHammer[33], bool:g_bTurbulent9[33], bool:g_bBio[33], bool:g_bSabers[33], bool:g_bPlasma[33],
  282. bool:g_bStorm[33], bool:g_bLaevateinn[33], bool:g_bWarHammer_Dark_Knight[33], bool:g_bBalrog_Kosa[33], bool:g_bWereWolf[33], bool:g_bDeadMaster[33], bool:g_bHammerChain[33],
  283. bool:g_bKataha[33], bool:g_bRanger[33], bool:g_bNoSpeed, g_iUsedTimes[33], g_pCvarUseTimes
  284.  
  285. new cvar_speed_compat
  286. new cvar_speed_strong
  287. new cvar_speed_katana
  288. new cvar_speed_hammer
  289. new cvar_speed_turb
  290. new cvar_speed_bio
  291. new cvar_speed_sabers
  292. new cvar_speed_plasma
  293. new cvar_speed_storm
  294. new cvar_speed_laevat
  295. new cvar_speed_darknight
  296. new cvar_speed_kosa
  297. new cvar_speed_werewolf
  298. new cvar_speed_deadmaster
  299. new cvar_speed_hammerchain
  300. new cvar_speed_kataha
  301. new cvar_speed_ranger
  302.  
  303. public plugin_precache()
  304. {
  305.     new i
  306.  
  307.     for (i = 0; i <= charsmax(Compat_Models); i++)
  308.         precache_model(Compat_Models[i])
  309.  
  310.     for (i = 0; i <= charsmax(Hammer_Models); i++)
  311.         precache_model(Hammer_Models[i])
  312.  
  313.     for (i = 0; i <= charsmax(Katana_Models); i++)
  314.         precache_model(Katana_Models[i])
  315.  
  316.     for (i = 0; i <= charsmax(Strong_Models); i++)
  317.         precache_model(Strong_Models[i])
  318.  
  319.     for (i = 0; i <= charsmax(Turbulent9_Models); i++)
  320.         precache_model(Turbulent9_Models[i])
  321.  
  322.     for (i = 0; i <= charsmax(Bio_Models); i++)
  323.         precache_model(Bio_Models[i])
  324.  
  325.     for (i = 0; i <= charsmax(Sabers_Models); i++)
  326.         precache_model(Sabers_Models[i])
  327.  
  328.     for (i = 0; i <= charsmax(Plasma_Models); i++)
  329.         precache_model(Plasma_Models[i])
  330.  
  331.     for (i = 0; i <= charsmax(Storm_Models); i++)
  332.         precache_model(Storm_Models[i])
  333.  
  334.     for (i = 0; i <= charsmax(Laevateinn_Models); i++)
  335.         precache_model(Laevateinn_Models[i])
  336.  
  337.     for (i = 0; i <= charsmax(WarHammer_Dark_Knight_Models); i++)
  338.         precache_model(WarHammer_Dark_Knight_Models[i])
  339.  
  340.     for (i = 0; i <= charsmax(Balrog_Kosa_Models); i++)
  341.         precache_model(Balrog_Kosa_Models[i])
  342.        
  343.     for (i = 0; i <= charsmax(WereWolf_Models); i++)
  344.         precache_model(WereWolf_Models[i])
  345.  
  346.     for (i = 0; i <= charsmax(DeadMaster_Models); i++)
  347.         precache_model(DeadMaster_Models[i])
  348.  
  349.     for (i = 0; i <= charsmax(HammerChain_Models); i++)
  350.         precache_model(HammerChain_Models[i])
  351.  
  352.     for (i = 0; i <= charsmax(Kataha_Models); i++)
  353.         precache_model(Kataha_Models[i])
  354.  
  355.     for (i = 0; i <= charsmax(Ranger_Models); i++)
  356.         precache_model(Ranger_Models[i])
  357.  
  358.     for (i = 0; i <= charsmax(combat_sounds); i++)
  359.         precache_sound(combat_sounds[i])
  360.  
  361.     for (i = 0; i <= charsmax(strong_sounds); i++)
  362.         precache_sound(strong_sounds[i])
  363.  
  364.     for (i = 0; i <= charsmax(katana_sounds); i++)
  365.         precache_sound(katana_sounds[i])
  366.  
  367.     for (i = 0; i <= charsmax(hammer_sounds); i++)
  368.         precache_sound(hammer_sounds[i])
  369.  
  370.     for (i = 0; i <= charsmax(turbulent9_sounds); i++)
  371.         precache_sound(turbulent9_sounds[i])
  372.  
  373.     for (i = 0; i <= charsmax(bio_sounds); i++)
  374.         precache_sound(bio_sounds[i])
  375.  
  376.     for (i = 0; i <= charsmax(sabers_sounds); i++)
  377.         precache_sound(sabers_sounds[i])
  378.  
  379.     for (i = 0; i <= charsmax(plasma_sounds); i++)
  380.         precache_sound(plasma_sounds[i])
  381.  
  382.     for (i = 0; i <= charsmax(storm_sounds); i++)
  383.         precache_sound(storm_sounds[i])
  384.  
  385.     for (i = 0; i <= charsmax(laevateinn_sounds); i++)
  386.         precache_sound(laevateinn_sounds[i])
  387.  
  388.     for (i = 0; i <= charsmax(warhammer_dark_knight_sounds); i++)
  389.         precache_sound(warhammer_dark_knight_sounds[i])
  390.  
  391.     for (i = 0; i <= charsmax(balrog_kosa_sounds); i++)
  392.         precache_sound(balrog_kosa_sounds[i])
  393.  
  394.     precache_sound(g_sound_knife)
  395. }
  396.  
  397. public plugin_natives()
  398. {
  399.     register_native("ze_open_knife_menu", "native_ze_open_knife_menu", 1)
  400. }
  401.  
  402. public plugin_init()
  403. {
  404.     register_plugin("[ZE] Addon: Knife Menu", "1.3", "Mark")
  405.  
  406.     register_forward(FM_EmitSound, "fw_EmitSound")
  407.     register_forward(FM_PlayerPreThink, "fw_PlayerPreThink");
  408.  
  409.     register_event("CurWeapon", "CurrentWeapon", "be", "1=1")
  410.     RegisterHookChain(RG_CBasePlayer_ResetMaxSpeed, "Fw_RestMaxSpeed_Post", 1)
  411.    
  412.     g_pCvarUseTimes = register_cvar("ze_knife_menu_use_times", "2")
  413.  
  414.     register_message(get_user_msgid("DeathMsg"), "DeathMsg")
  415.  
  416.     register_clcmd("say /k", "Show_Knife_Menu")
  417.    
  418.     cvar_speed_compat = register_cvar("ze_compat_speed", "275.0")
  419.     cvar_speed_strong = register_cvar("ze_strong_speed", "275.0")
  420.     cvar_speed_katana = register_cvar("ze_katana_speed", "275.0")
  421.     cvar_speed_hammer = register_cvar("ze_hammer_speed", "275.0")
  422.     cvar_speed_turb = register_cvar("ze_turb_speed", "280.0")    
  423.     cvar_speed_bio = register_cvar("ze_bio_speed", "280.0")
  424.     cvar_speed_sabers = register_cvar("ze_sabers_speed", "285.0")
  425.     cvar_speed_plasma = register_cvar("ze_plasma_speed", "285.0")
  426.     cvar_speed_storm = register_cvar("ze_storm_speed", "290.0")    
  427.     cvar_speed_laevat = register_cvar("ze_laevat_speed", "290.0")  
  428.     cvar_speed_darknight = register_cvar("ze_darknight_speed", "295.0")
  429.     cvar_speed_kosa = register_cvar("ze_kosa_speed", "295.0")
  430.     cvar_speed_werewolf = register_cvar("ze_werewolf_speed", "310.0")
  431.     cvar_speed_deadmaster = register_cvar("ze_deadmaster_speed", "310.0")    
  432.     cvar_speed_hammerchain = register_cvar("ze_hammerchain_speed", "310.0")  
  433.     cvar_speed_kataha = register_cvar("ze_kataha_speed", "310.0")
  434.     cvar_speed_ranger = register_cvar("ze_ranger_speed", "310.0")
  435. }
  436.  
  437. public ze_user_humanized(id)
  438. {
  439.     g_iUsedTimes[id] = 0
  440. }
  441.  
  442. /*public ze_user_infected(Victim)
  443. {
  444.     g_bCompat[Victim] = false
  445.     g_bStrong[Victim] = false
  446.     g_bKatana[Victim] = false
  447.     g_bHammer[Victim] = false
  448.     g_bTurbulent9[Victim] = false
  449.     g_bBio[Victim] = false
  450.     g_bSabers[Victim] = false
  451.     g_bPlasma[Victim] = false
  452.     g_bStorm[Victim] = false
  453.     g_bLaevateinn[Victim] = false
  454.     g_bWarHammer_Dark_Knight[Victim] = false
  455.     g_bBalrog_Kosa[Victim] = false
  456.     g_iUsedTimes[Victim] = 0
  457. }*/
  458.  
  459. public client_putinserver(id)
  460. {
  461.     g_bCompat[id] = false
  462.     g_bStrong[id] = false
  463.     g_bKatana[id] = false
  464.     g_bHammer[id] = false
  465.     g_bTurbulent9[id] = false
  466.     g_bBio[id] = false
  467.     g_bSabers[id] = false
  468.     g_bPlasma[id] = false
  469.     g_bStorm[id] = false
  470.     g_bLaevateinn[id] = false
  471.     g_bWarHammer_Dark_Knight[id] = false
  472.     g_bBalrog_Kosa[id] = false
  473.     g_bWereWolf[id] = false
  474.     g_bDeadMaster[id] = false
  475.     g_bHammerChain[id] = false
  476.     g_bKataha[id] = false
  477.     g_bRanger[id] = false
  478.     g_iUsedTimes[id] = 0
  479. }
  480.  
  481. public client_disconnected(id)
  482. {
  483.     g_bCompat[id] = false
  484.     g_bStrong[id] = false
  485.     g_bKatana[id] = false
  486.     g_bHammer[id] = false
  487.     g_bTurbulent9[id] = false
  488.     g_bBio[id] = false
  489.     g_bSabers[id] = false
  490.     g_bPlasma[id] = false
  491.     g_bStorm[id] = false
  492.     g_bLaevateinn[id] = false
  493.     g_bWarHammer_Dark_Knight[id] = false
  494.     g_bBalrog_Kosa[id] = false
  495.     g_bWereWolf[id] = false
  496.     g_bDeadMaster[id] = false
  497.     g_bHammerChain[id] = false
  498.     g_bKataha[id] = false
  499.     g_bRanger[id] = false
  500.     g_iUsedTimes[id] = 0
  501. }
  502.  
  503. public ze_game_started()
  504. {
  505.     g_bNoSpeed = true
  506. }
  507.  
  508. public ze_zombie_release()
  509. {
  510.     g_bNoSpeed = false
  511.    
  512.     // call the reset speed function ;)
  513.     for(new id = 1; id <= 32; id++)
  514.     {
  515.         if (!is_user_alive(id))
  516.             continue;
  517.        
  518.         rg_reset_maxspeed(id)
  519.     }
  520. }
  521.  
  522. public Show_Knife_Menu(id)
  523. {
  524.     if (!is_user_connected(id))
  525.         return PLUGIN_CONTINUE
  526.  
  527.     if (ze_is_user_zombie(id))
  528.     {
  529.         ze_colored_print(id, "!tZombies can't open knife menu!y.")
  530.         return PLUGIN_HANDLED
  531.     }
  532.  
  533.     if (g_iUsedTimes[id] >= get_pcvar_num(g_pCvarUseTimes))
  534.     {
  535.         ze_colored_print(id, "!tYou can only open knife menu !y[!g%dx!y] per round!", get_pcvar_num(g_pCvarUseTimes))
  536.         return PLUGIN_HANDLED
  537.     }
  538.  
  539.     if (!is_user_alive(id))
  540.     {
  541.         ze_colored_print(id, "!tDead can't open knife menu!y.")
  542.         return PLUGIN_HANDLED
  543.     }
  544.  
  545.     Knife_Menu(id)
  546.     return PLUGIN_CONTINUE
  547. }
  548.  
  549. public Knife_Menu(id)
  550. {
  551.     new iMenu = menu_create("\rChoose Your Knife\w:^n^n- [ \ySpeed \rActivates \yon Zombie Release!\w ]^n-", "Menu_Handler")
  552.     menu_additem(iMenu, "\yCombat \w[ \r275 Speed\w ]", "", 0)
  553.     menu_additem(iMenu, "\yStrong \w[ \r275 Speed\w ]", "", 0)
  554.     menu_additem(iMenu, "\yKatana \w[ \r275 Speed\w ]", "", 0)
  555.     menu_additem(iMenu, "\yHammer \w[ \r275 Speed\w ]", "", 0)
  556.     menu_additem(iMenu, "\yTurbulent9 \w[ \r280 Speed\w ]", "", 0)
  557.     menu_additem(iMenu, "\yBio Hazard \w[ \r280 Speed\w ]", "", 0)
  558.     menu_additem(iMenu, "\ySabers \w[ \r285 Speed\w ]", "", 0)
  559.    
  560.     if (ze_get_vip_flags(id) & VIP_A)
  561.     {
  562.         menu_additem(iMenu, "\yPlasma \w[ \r285 Speed\w ]", "", 0)
  563.     }
  564.    
  565.     if (ze_get_vip_flags(id) & VIP_F)
  566.     {
  567.         menu_additem(iMenu, "\yStorm \w[ \r290 Speed\w ]", "", 0)
  568.     }
  569.    
  570.     if (ze_get_vip_flags(id) & VIP_I)
  571.     {
  572.         menu_additem(iMenu, "\yLaevateinn \w[ \r290 Speed\w ]", "", 0)
  573.         menu_additem(iMenu, "\yKataha \w[ \r310 Speed\w ]", "", 0)
  574.         menu_additem(iMenu, "\yHammer Chain \w[ \r310 Speed\w ]", "", 0)
  575.     }
  576.  
  577.     if (ze_get_vip_flags(id) & VIP_L)
  578.     {
  579.         menu_additem(iMenu, "\yWarHammer Dark Night \w [ \r290 Speed\w ]", "", 0)
  580.         menu_additem(iMenu, "\yBalrog Kosa \w[ \r290 Speed\w ]", "", 0)
  581.         menu_additem(iMenu, "\yWere Wolf \w[ \r310 Speed\w ]", "", 0)
  582.         menu_additem(iMenu, "\yDead Master \w[ \r310 Speed\w ]", "", 0)
  583.     }
  584.    
  585.     if (ze_get_vip_flags(id) & VIP_J)
  586.     {
  587.         menu_additem(iMenu, "\yWarHammer Ranger \w[ \r310 Speed\w ]", "", 0)
  588.     }
  589.  
  590.     menu_setprop(iMenu,MPROP_PERPAGE, 6)
  591.     menu_setprop(iMenu,MPROP_EXITNAME,"\rClose")
  592.     menu_setprop(iMenu, MPROP_EXIT, MEXIT_ALL)
  593.     menu_display(id, iMenu, 0)
  594. }
  595.  
  596. public Menu_Handler(id, iMenu, iKey)
  597. {
  598.     if(!is_user_alive(id) || ze_is_user_zombie(id))
  599.         return PLUGIN_HANDLED
  600.        
  601.     switch(iKey)
  602.     {
  603.         case 0: // Compat
  604.         {
  605.             g_bCompat[id] = true
  606.             g_bStrong[id] = false
  607.             g_bKatana[id] = false
  608.             g_bHammer[id] = false
  609.             g_bTurbulent9[id] = false
  610.             g_bBio[id] = false
  611.             g_bSabers[id] = false
  612.             g_bPlasma[id] = false
  613.             g_bStorm[id] = false
  614.             g_bLaevateinn[id] = false
  615.             g_bWarHammer_Dark_Knight[id] = false
  616.             g_bBalrog_Kosa[id] = false
  617.             g_bWereWolf[id] = false
  618.             g_bDeadMaster[id] = false
  619.             g_bHammerChain[id] = false
  620.             g_bKataha[id] = false
  621.             g_bRanger[id] = false
  622.             g_iUsedTimes[id]++
  623.             rg_remove_item(id, "weapon_knife")
  624.             rg_give_item(id, "weapon_knife", GT_APPEND)
  625.             //engclient_cmd(id, "weapon_knife")
  626.             //rg_reset_maxspeed(id)
  627.             //g_iUsedTimes[id]++
  628.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)
  629.         }
  630.         case 1: // Strong
  631.         {
  632.             g_bCompat[id] = false
  633.             g_bStrong[id] = true
  634.             g_bKatana[id] = false
  635.             g_bHammer[id] = false
  636.             g_bTurbulent9[id] = false
  637.             g_bBio[id] = false
  638.             g_bSabers[id] = false
  639.             g_bPlasma[id] = false
  640.             g_bStorm[id] = false
  641.             g_bLaevateinn[id] = false
  642.             g_bWarHammer_Dark_Knight[id] = false
  643.             g_bBalrog_Kosa[id] = false
  644.             g_bWereWolf[id] = false
  645.             g_bDeadMaster[id] = false
  646.             g_bHammerChain[id] = false
  647.             g_bKataha[id] = false
  648.             g_bRanger[id] = false
  649.             g_iUsedTimes[id]++
  650.             rg_remove_item(id, "weapon_knife")
  651.             rg_give_item(id, "weapon_knife", GT_APPEND)
  652.             //engclient_cmd(id, "weapon_knife")
  653.             //g_iUsedTimes[id]++
  654.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)
  655.         }
  656.         case 2: // Katana
  657.         {
  658.             g_bCompat[id] = false
  659.             g_bStrong[id] = false
  660.             g_bKatana[id] = true
  661.             g_bHammer[id] = false
  662.             g_bTurbulent9[id] = false
  663.             g_bBio[id] = false
  664.             g_bSabers[id] = false
  665.             g_bPlasma[id] = false
  666.             g_bStorm[id] = false
  667.             g_bLaevateinn[id] = false
  668.             g_bWarHammer_Dark_Knight[id] = false
  669.             g_bBalrog_Kosa[id] = false
  670.             g_bWereWolf[id] = false
  671.             g_bDeadMaster[id] = false
  672.             g_bHammerChain[id] = false
  673.             g_bKataha[id] = false
  674.             g_bRanger[id] = false
  675.             g_iUsedTimes[id]++
  676.             rg_remove_item(id, "weapon_knife")
  677.             rg_give_item(id, "weapon_knife", GT_APPEND)
  678.             //engclient_cmd(id, "weapon_knife")
  679.             //g_iUsedTimes[id]++
  680.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  681.         }
  682.         case 3: // Hammer
  683.         {
  684.             g_bCompat[id] = false
  685.             g_bStrong[id] = false
  686.             g_bKatana[id] = false
  687.             g_bHammer[id] = true
  688.             g_bTurbulent9[id] = false
  689.             g_bBio[id] = false
  690.             g_bSabers[id] = false
  691.             g_bPlasma[id] = false
  692.             g_bStorm[id] = false
  693.             g_bLaevateinn[id] = false
  694.             g_bWarHammer_Dark_Knight[id] = false
  695.             g_bBalrog_Kosa[id] = false
  696.             g_bWereWolf[id] = false
  697.             g_bDeadMaster[id] = false
  698.             g_bHammerChain[id] = false
  699.             g_bKataha[id] = false
  700.             g_bRanger[id] = false
  701.             g_iUsedTimes[id]++
  702.             rg_remove_item(id, "weapon_knife")
  703.             rg_give_item(id, "weapon_knife", GT_APPEND)
  704.             //engclient_cmd(id, "weapon_knife")
  705.             //g_iUsedTimes[id]++
  706.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  707.         }
  708.         case 4: // Turbulent
  709.         {
  710.  
  711.             g_bCompat[id] = false
  712.             g_bStrong[id] = false
  713.             g_bKatana[id] = false
  714.             g_bHammer[id] = false
  715.             g_bTurbulent9[id] = true
  716.             g_bBio[id] = false
  717.             g_bSabers[id] = false
  718.             g_bPlasma[id] = false
  719.             g_bStorm[id] = false
  720.             g_bLaevateinn[id] = false
  721.             g_bWarHammer_Dark_Knight[id] = false
  722.             g_bBalrog_Kosa[id] = false
  723.             g_bWereWolf[id] = false
  724.             g_bDeadMaster[id] = false
  725.             g_bHammerChain[id] = false
  726.             g_bKataha[id] = false
  727.             g_bRanger[id] = false
  728.             g_iUsedTimes[id]++
  729.             rg_remove_item(id, "weapon_knife")
  730.             rg_give_item(id, "weapon_knife", GT_APPEND)
  731.             //engclient_cmd(id, "weapon_knife")
  732.             //g_iUsedTimes[id]++
  733.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  734.            
  735.         }
  736.         case 5: // Bio
  737.         {
  738.  
  739.             g_bCompat[id] = false
  740.             g_bStrong[id] = false
  741.             g_bKatana[id] = false
  742.             g_bHammer[id] = false
  743.             g_bTurbulent9[id] = false
  744.             g_bBio[id] = true
  745.             g_bSabers[id] = false
  746.             g_bPlasma[id] = false
  747.             g_bStorm[id] = false
  748.             g_bLaevateinn[id] = false
  749.             g_bWarHammer_Dark_Knight[id] = false
  750.             g_bBalrog_Kosa[id] = false
  751.             g_bWereWolf[id] = false
  752.             g_bDeadMaster[id] = false
  753.             g_bHammerChain[id] = false
  754.             g_bKataha[id] = false
  755.             g_bRanger[id] = false
  756.             g_iUsedTimes[id]++
  757.             rg_remove_item(id, "weapon_knife")
  758.             rg_give_item(id, "weapon_knife", GT_APPEND)
  759.             //engclient_cmd(id, "weapon_knife")
  760.             //g_iUsedTimes[id]++
  761.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  762.            
  763.         }
  764.         case 6: // Sabers
  765.         {
  766.  
  767.             g_bCompat[id] = false
  768.             g_bStrong[id] = false
  769.             g_bKatana[id] = false
  770.             g_bHammer[id] = false
  771.             g_bTurbulent9[id] = false
  772.             g_bBio[id] = false
  773.             g_bSabers[id] = true
  774.             g_bPlasma[id] = false
  775.             g_bStorm[id] = false
  776.             g_bLaevateinn[id] = false
  777.             g_bWarHammer_Dark_Knight[id] = false
  778.             g_bBalrog_Kosa[id] = false
  779.             g_bWereWolf[id] = false
  780.             g_bDeadMaster[id] = false
  781.             g_bHammerChain[id] = false
  782.             g_bKataha[id] = false
  783.             g_bRanger[id] = false
  784.             g_iUsedTimes[id]++
  785.             rg_remove_item(id, "weapon_knife")
  786.             rg_give_item(id, "weapon_knife", GT_APPEND)
  787.             //engclient_cmd(id, "weapon_knife")
  788.             //g_iUsedTimes[id]++
  789.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  790.            
  791.         }
  792.         case 7: // Plasma
  793.         {
  794.  
  795.             g_bCompat[id] = false
  796.             g_bStrong[id] = false
  797.             g_bKatana[id] = false
  798.             g_bHammer[id] = false
  799.             g_bTurbulent9[id] = false
  800.             g_bBio[id] = false
  801.             g_bSabers[id] = false
  802.             g_bPlasma[id] = true
  803.             g_bStorm[id] = false
  804.             g_bLaevateinn[id] = false
  805.             g_bWarHammer_Dark_Knight[id] = false
  806.             g_bBalrog_Kosa[id] = false
  807.             g_bWereWolf[id] = false
  808.             g_bDeadMaster[id] = false
  809.             g_bHammerChain[id] = false
  810.             g_bKataha[id] = false
  811.             g_bRanger[id] = false
  812.             g_iUsedTimes[id]++
  813.             rg_remove_item(id, "weapon_knife")
  814.             rg_give_item(id, "weapon_knife", GT_APPEND)
  815.             //engclient_cmd(id, "weapon_knife")
  816.             //g_iUsedTimes[id]++
  817.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  818.            
  819.         }
  820.         case 8: // Storm
  821.         {
  822.  
  823.             g_bCompat[id] = false
  824.             g_bStrong[id] = false
  825.             g_bKatana[id] = false
  826.             g_bHammer[id] = false
  827.             g_bTurbulent9[id] = false
  828.             g_bBio[id] = false
  829.             g_bSabers[id] = false
  830.             g_bPlasma[id] = false
  831.             g_bStorm[id] = true
  832.             g_bLaevateinn[id] = false
  833.             g_bWarHammer_Dark_Knight[id] = false
  834.             g_bBalrog_Kosa[id] = false
  835.             g_bWereWolf[id] = false
  836.             g_bDeadMaster[id] = false
  837.             g_bHammerChain[id] = false
  838.             g_bKataha[id] = false
  839.             g_bRanger[id] = false
  840.             g_iUsedTimes[id]++
  841.             rg_remove_item(id, "weapon_knife")
  842.             rg_give_item(id, "weapon_knife", GT_APPEND)
  843.             //engclient_cmd(id, "weapon_knife")
  844.             //g_iUsedTimes[id]++
  845.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  846.  
  847.         }
  848.         case 9: // Laevateinn
  849.         {
  850.  
  851.             g_bCompat[id] = false
  852.             g_bStrong[id] = false
  853.             g_bKatana[id] = false
  854.             g_bHammer[id] = false
  855.             g_bTurbulent9[id] = false
  856.             g_bBio[id] = false
  857.             g_bSabers[id] = false
  858.             g_bPlasma[id] = false
  859.             g_bStorm[id] = false
  860.             g_bLaevateinn[id] = true
  861.             g_bWarHammer_Dark_Knight[id] = false
  862.             g_bBalrog_Kosa[id] = false
  863.             g_bWereWolf[id] = false
  864.             g_bDeadMaster[id] = false
  865.             g_bHammerChain[id] = false
  866.             g_bKataha[id] = false
  867.             g_bRanger[id] = false
  868.             g_iUsedTimes[id]++
  869.             rg_remove_item(id, "weapon_knife")
  870.             rg_give_item(id, "weapon_knife", GT_APPEND)
  871.             //engclient_cmd(id, "weapon_knife")
  872.             //g_iUsedTimes[id]++
  873.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  874.  
  875.         }
  876.         case 10: // Warhammer Dark Night
  877.         {
  878.  
  879.             g_bCompat[id] = false
  880.             g_bStrong[id] = false
  881.             g_bKatana[id] = false
  882.             g_bHammer[id] = false
  883.             g_bTurbulent9[id] = false
  884.             g_bBio[id] = false
  885.             g_bSabers[id] = false
  886.             g_bPlasma[id] = false
  887.             g_bStorm[id] = false
  888.             g_bLaevateinn[id] = false
  889.             g_bWarHammer_Dark_Knight[id] = true
  890.             g_bBalrog_Kosa[id] = false
  891.             g_bWereWolf[id] = false
  892.             g_bDeadMaster[id] = false
  893.             g_bHammerChain[id] = false
  894.             g_bKataha[id] = false
  895.             g_bRanger[id] = false
  896.             g_iUsedTimes[id]++
  897.             rg_remove_item(id, "weapon_knife")
  898.             rg_give_item(id, "weapon_knife", GT_APPEND)
  899.             //engclient_cmd(id, "weapon_knife")
  900.             //g_iUsedTimes[id]++
  901.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  902.        
  903.         }
  904.         case 11: // Balrog Kosa
  905.         {
  906.  
  907.             g_bCompat[id] = false
  908.             g_bStrong[id] = false
  909.             g_bKatana[id] = false
  910.             g_bHammer[id] = false
  911.             g_bTurbulent9[id] = false
  912.             g_bBio[id] = false
  913.             g_bSabers[id] = false
  914.             g_bPlasma[id] = false
  915.             g_bStorm[id] = false
  916.             g_bLaevateinn[id] = false
  917.             g_bWarHammer_Dark_Knight[id] = false
  918.             g_bBalrog_Kosa[id] = true
  919.             g_bWereWolf[id] = false
  920.             g_bDeadMaster[id] = false
  921.             g_bHammerChain[id] = false
  922.             g_bKataha[id] = false
  923.             g_bRanger[id] = false
  924.             g_iUsedTimes[id]++
  925.             rg_remove_item(id, "weapon_knife")
  926.             rg_give_item(id, "weapon_knife", GT_APPEND)
  927.             //engclient_cmd(id, "weapon_knife")
  928.             //g_iUsedTimes[id]++
  929.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  930.            
  931.         }
  932.         case 12: // Were Wolf
  933.         {
  934.  
  935.             g_bCompat[id] = false
  936.             g_bStrong[id] = false
  937.             g_bKatana[id] = false
  938.             g_bHammer[id] = false
  939.             g_bTurbulent9[id] = false
  940.             g_bBio[id] = false
  941.             g_bSabers[id] = false
  942.             g_bPlasma[id] = false
  943.             g_bStorm[id] = false
  944.             g_bLaevateinn[id] = false
  945.             g_bWarHammer_Dark_Knight[id] = false
  946.             g_bBalrog_Kosa[id] = false
  947.             g_bWereWolf[id] = true
  948.             g_bDeadMaster[id] = false
  949.             g_bHammerChain[id] = false
  950.             g_bKataha[id] = false
  951.             g_bRanger[id] = false
  952.             g_iUsedTimes[id]++
  953.             rg_remove_item(id, "weapon_knife")
  954.             rg_give_item(id, "weapon_knife", GT_APPEND)
  955.             //engclient_cmd(id, "weapon_knife")
  956.             //g_iUsedTimes[id]++
  957.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  958.            
  959.         }
  960.         case 13: // Dead Master
  961.         {
  962.  
  963.             g_bCompat[id] = false
  964.             g_bStrong[id] = false
  965.             g_bKatana[id] = false
  966.             g_bHammer[id] = false
  967.             g_bTurbulent9[id] = false
  968.             g_bBio[id] = false
  969.             g_bSabers[id] = false
  970.             g_bPlasma[id] = false
  971.             g_bStorm[id] = false
  972.             g_bLaevateinn[id] = false
  973.             g_bWarHammer_Dark_Knight[id] = false
  974.             g_bBalrog_Kosa[id] = false
  975.             g_bWereWolf[id] = false
  976.             g_bDeadMaster[id] = true
  977.             g_bHammerChain[id] = false
  978.             g_bKataha[id] = false
  979.             g_bRanger[id] = false
  980.             g_iUsedTimes[id]++
  981.             rg_remove_item(id, "weapon_knife")
  982.             rg_give_item(id, "weapon_knife", GT_APPEND)
  983.             //engclient_cmd(id, "weapon_knife")
  984.             //g_iUsedTimes[id]++
  985.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  986.            
  987.         }
  988.         case 14: // Hammer Chain
  989.         {
  990.  
  991.             g_bCompat[id] = false
  992.             g_bStrong[id] = false
  993.             g_bKatana[id] = false
  994.             g_bHammer[id] = false
  995.             g_bTurbulent9[id] = false
  996.             g_bBio[id] = false
  997.             g_bSabers[id] = false
  998.             g_bPlasma[id] = false
  999.             g_bStorm[id] = false
  1000.             g_bLaevateinn[id] = false
  1001.             g_bWarHammer_Dark_Knight[id] = false
  1002.             g_bBalrog_Kosa[id] = false
  1003.             g_bWereWolf[id] = false
  1004.             g_bDeadMaster[id] = false
  1005.             g_bHammerChain[id] = true
  1006.             g_bKataha[id] = false
  1007.             g_bRanger[id] = false
  1008.             g_iUsedTimes[id]++
  1009.             rg_remove_item(id, "weapon_knife")
  1010.             rg_give_item(id, "weapon_knife", GT_APPEND)
  1011.             //engclient_cmd(id, "weapon_knife")
  1012.             //g_iUsedTimes[id]++
  1013.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  1014.            
  1015.         }
  1016.         case 15: // Kataha
  1017.         {
  1018.  
  1019.             g_bCompat[id] = false
  1020.             g_bStrong[id] = false
  1021.             g_bKatana[id] = false
  1022.             g_bHammer[id] = false
  1023.             g_bTurbulent9[id] = false
  1024.             g_bBio[id] = false
  1025.             g_bSabers[id] = false
  1026.             g_bPlasma[id] = false
  1027.             g_bStorm[id] = false
  1028.             g_bLaevateinn[id] = false
  1029.             g_bWarHammer_Dark_Knight[id] = false
  1030.             g_bBalrog_Kosa[id] = false
  1031.             g_bWereWolf[id] = false
  1032.             g_bDeadMaster[id] = false
  1033.             g_bHammerChain[id] = false
  1034.             g_bKataha[id] = true
  1035.             g_bRanger[id] = false
  1036.             g_iUsedTimes[id]++
  1037.             rg_remove_item(id, "weapon_knife")
  1038.             rg_give_item(id, "weapon_knife", GT_APPEND)
  1039.             //engclient_cmd(id, "weapon_knife")
  1040.             //g_iUsedTimes[id]++
  1041.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  1042.            
  1043.         }      
  1044.         case 16: // WarHammer Ranger
  1045.         {
  1046.             g_bCompat[id] = false
  1047.             g_bStrong[id] = false
  1048.             g_bKatana[id] = false
  1049.             g_bHammer[id] = false
  1050.             g_bTurbulent9[id] = false
  1051.             g_bBio[id] = false
  1052.             g_bSabers[id] = false
  1053.             g_bPlasma[id] = false
  1054.             g_bStorm[id] = false
  1055.             g_bLaevateinn[id] = false
  1056.             g_bWarHammer_Dark_Knight[id] = false
  1057.             g_bBalrog_Kosa[id] = false
  1058.             g_bWereWolf[id] = false
  1059.             g_bDeadMaster[id] = false
  1060.             g_bHammerChain[id] = false
  1061.             g_bKataha[id] = false
  1062.             g_bRanger[id] = true
  1063.             g_iUsedTimes[id]++
  1064.             rg_remove_item(id, "weapon_knife")
  1065.             rg_give_item(id, "weapon_knife", GT_APPEND)
  1066.             //engclient_cmd(id, "weapon_knife")
  1067.             //g_iUsedTimes[id]++
  1068.             //emit_sound(id, CHAN_BODY, g_sound_knife, 1.0, ATTN_NORM, 0, PITCH_NORM)*/
  1069.            
  1070.         }
  1071.     }
  1072.  
  1073.     menu_destroy(iMenu)
  1074.     return PLUGIN_HANDLED
  1075. }
  1076.  
  1077. public fw_EmitSound(id, channel, const sound[])
  1078. {
  1079.     if(!is_user_alive(id) || ze_is_user_zombie(id))
  1080.         return FMRES_IGNORED
  1081.        
  1082.     new i
  1083.     for (i = 0; i <= charsmax(combat_sounds); i++)
  1084.     for (i = 0; i <= charsmax(strong_sounds); i++)
  1085.     for (i = 0; i <= charsmax(katana_sounds); i++)
  1086.     for (i = 0; i <= charsmax(hammer_sounds); i++)
  1087.     for (i = 0; i <= charsmax(turbulent9_sounds); i++)
  1088.     for (i = 0; i <= charsmax(bio_sounds); i++)
  1089.     for (i = 0; i <= charsmax(sabers_sounds); i++)
  1090.     for (i = 0; i <= charsmax(plasma_sounds); i++)
  1091.     for (i = 0; i <= charsmax(storm_sounds); i++)
  1092.     for (i = 0; i <= charsmax(laevateinn_sounds); i++)
  1093.     for (i = 0; i <= charsmax(warhammer_dark_knight_sounds); i++)
  1094.     for (i = 0; i <= charsmax(balrog_kosa_sounds); i++)
  1095.     {
  1096.         if(equal(sound, oldknife_sounds[i]))
  1097.         {
  1098.             if (g_bCompat[id])
  1099.             {
  1100.                 emit_sound(id, channel, combat_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1101.                 return FMRES_SUPERCEDE
  1102.             }
  1103.             else if (g_bStrong[id])
  1104.             {
  1105.                 emit_sound(id, channel, strong_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1106.                 return FMRES_SUPERCEDE
  1107.             }
  1108.             else if (g_bKatana[id])
  1109.             {
  1110.                 emit_sound(id, channel, katana_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1111.                 return FMRES_SUPERCEDE
  1112.             }
  1113.             else if (g_bHammer[id])
  1114.             {
  1115.                 emit_sound(id, channel, hammer_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1116.                 return FMRES_SUPERCEDE
  1117.             }
  1118.             else if (g_bTurbulent9[id])
  1119.             {
  1120.                 emit_sound(id, channel, turbulent9_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1121.                 return FMRES_SUPERCEDE
  1122.             }
  1123.             else if (g_bBio[id])
  1124.             {
  1125.                 emit_sound(id, channel, bio_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1126.                 return FMRES_SUPERCEDE
  1127.             }
  1128.             else if (g_bSabers[id])
  1129.             {
  1130.                 emit_sound(id, channel, sabers_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1131.                 return FMRES_SUPERCEDE
  1132.             }
  1133.             else if (g_bPlasma[id] && (ze_get_vip_flags(id) & VIP_A))
  1134.             {
  1135.                 emit_sound(id, channel, plasma_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1136.                 return FMRES_SUPERCEDE
  1137.             }
  1138.             else if (g_bStorm[id] && (ze_get_vip_flags(id) & VIP_F))
  1139.             {
  1140.                 emit_sound(id, channel, storm_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1141.                 return FMRES_SUPERCEDE
  1142.             }
  1143.             else if (g_bLaevateinn[id] && (ze_get_vip_flags(id) & VIP_I))
  1144.             {
  1145.                 emit_sound(id, channel, laevateinn_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1146.                 return FMRES_SUPERCEDE
  1147.             }
  1148.             else if (g_bWarHammer_Dark_Knight[id] && (ze_get_vip_flags(id) & VIP_L))
  1149.             {
  1150.                 emit_sound(id, channel, warhammer_dark_knight_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1151.                 return FMRES_SUPERCEDE
  1152.             }
  1153.             else if (g_bBalrog_Kosa[id] && (ze_get_vip_flags(id) & VIP_L))
  1154.             {
  1155.                 emit_sound(id, channel, balrog_kosa_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1156.                 return FMRES_SUPERCEDE
  1157.             }
  1158.             else if (g_bWereWolf[id] && (ze_get_vip_flags(id) & VIP_L))
  1159.             {
  1160.                 emit_sound(id, channel, storm_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1161.                 return FMRES_SUPERCEDE
  1162.             }
  1163.             else if (g_bDeadMaster[id] && (ze_get_vip_flags(id) & VIP_L))
  1164.             {
  1165.                 emit_sound(id, channel, balrog_kosa_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1166.                 return FMRES_SUPERCEDE
  1167.             }
  1168.             else if (g_bHammerChain[id] && (ze_get_vip_flags(id) & VIP_I))
  1169.             {
  1170.                 emit_sound(id, channel, warhammer_dark_knight_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1171.                 return FMRES_SUPERCEDE
  1172.             }
  1173.             else if (g_bKataha[id] && (ze_get_vip_flags(id) & VIP_I))
  1174.             {
  1175.                 emit_sound(id, channel, katana_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1176.                 return FMRES_SUPERCEDE
  1177.             }
  1178.             else if (g_bRanger[id] && (ze_get_vip_flags(id) & VIP_J))
  1179.             {
  1180.                 emit_sound(id, channel, warhammer_dark_knight_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1181.                 return FMRES_SUPERCEDE
  1182.             }
  1183.             else if (!g_bCompat[id] || !g_bStrong[id] || !g_bKatana[id] || !g_bHammer[id] || !g_bTurbulent9[id] || !g_bBio[id] || !g_bSabers[id] || !g_bPlasma[id] || !g_bStorm[id] || !g_bLaevateinn[id] || !g_bWarHammer_Dark_Knight[id] || !g_bBalrog_Kosa[id])
  1184.             {
  1185.                 emit_sound(id, channel, oldknife_sounds[i], 1.0, ATTN_NORM, 0, PITCH_NORM)
  1186.                 return FMRES_SUPERCEDE
  1187.             }
  1188.         }
  1189.     }
  1190.     return FMRES_IGNORED
  1191. }
  1192.  
  1193. public CurrentWeapon(id)
  1194. {
  1195.     if(!is_user_alive(id) || ze_is_user_zombie(id))
  1196.         return
  1197.        
  1198.     if(get_user_weapon(id) & CSW_KNIFE)
  1199.     {
  1200.         if(g_bCompat[id])
  1201.         {
  1202.             cs_set_player_view_model(id, CSW_KNIFE, Compat_Models[0])
  1203.             cs_set_player_weap_model(id, CSW_KNIFE, Compat_Models[1])
  1204.         }
  1205.         else if(g_bStrong[id])
  1206.         {
  1207.             cs_set_player_view_model(id, CSW_KNIFE, Strong_Models[0])
  1208.             cs_set_player_weap_model(id, CSW_KNIFE, Strong_Models[1])
  1209.         }
  1210.         else if(g_bKatana[id])
  1211.         {
  1212.             cs_set_player_view_model(id, CSW_KNIFE, Katana_Models[0])
  1213.             cs_set_player_weap_model(id, CSW_KNIFE, Katana_Models[1])
  1214.         }
  1215.         else if(g_bHammer[id])
  1216.         {
  1217.             cs_set_player_view_model(id, CSW_KNIFE, Hammer_Models[0])
  1218.             cs_set_player_weap_model(id, CSW_KNIFE, Hammer_Models[1])
  1219.         }
  1220.         else if(g_bTurbulent9[id])
  1221.         {
  1222.             cs_set_player_view_model(id, CSW_KNIFE, Turbulent9_Models[0])
  1223.             cs_set_player_weap_model(id, CSW_KNIFE, Turbulent9_Models[1])
  1224.         }
  1225.         else if(g_bBio[id])
  1226.         {
  1227.             cs_set_player_view_model(id, CSW_KNIFE, Bio_Models[0])
  1228.             cs_set_player_weap_model(id, CSW_KNIFE, Bio_Models[1])
  1229.         }
  1230.         else if(g_bSabers[id])
  1231.         {
  1232.             cs_set_player_view_model(id, CSW_KNIFE, Sabers_Models[0])
  1233.             cs_set_player_weap_model(id, CSW_KNIFE, Sabers_Models[1])
  1234.         }
  1235.         else if(g_bPlasma[id] && (ze_get_vip_flags(id) & VIP_A))
  1236.         {
  1237.             cs_set_player_view_model(id, CSW_KNIFE, Plasma_Models[0])
  1238.             cs_set_player_weap_model(id, CSW_KNIFE, Plasma_Models[1])
  1239.         }
  1240.         else if(g_bStorm[id] && (ze_get_vip_flags(id) & VIP_F))
  1241.         {
  1242.             cs_set_player_view_model(id, CSW_KNIFE, Storm_Models[0])
  1243.             cs_set_player_weap_model(id, CSW_KNIFE, Storm_Models[1])
  1244.         }
  1245.         else if(g_bLaevateinn[id] && (ze_get_vip_flags(id) & VIP_I))
  1246.         {
  1247.             cs_set_player_view_model(id, CSW_KNIFE, Laevateinn_Models[0])
  1248.             cs_set_player_weap_model(id, CSW_KNIFE, Laevateinn_Models[1])
  1249.         }
  1250.         else if(g_bWarHammer_Dark_Knight[id] && (ze_get_vip_flags(id) & VIP_L))
  1251.         {
  1252.             cs_set_player_view_model(id, CSW_KNIFE, WarHammer_Dark_Knight_Models[0])
  1253.             cs_set_player_weap_model(id, CSW_KNIFE, WarHammer_Dark_Knight_Models[1])
  1254.         }
  1255.         else if(g_bBalrog_Kosa[id] && (ze_get_vip_flags(id) & VIP_L))
  1256.         {
  1257.             cs_set_player_view_model(id, CSW_KNIFE, Balrog_Kosa_Models[0])
  1258.             cs_set_player_weap_model(id, CSW_KNIFE, Balrog_Kosa_Models[1])
  1259.         }
  1260.         else if(g_bWereWolf[id] && (ze_get_vip_flags(id) & VIP_L))
  1261.         {
  1262.             cs_set_player_view_model(id, CSW_KNIFE, WereWolf_Models[0])
  1263.             cs_set_player_weap_model(id, CSW_KNIFE, WereWolf_Models[1])
  1264.         }
  1265.         else if(g_bDeadMaster[id] && (ze_get_vip_flags(id) & VIP_L))
  1266.         {
  1267.             cs_set_player_view_model(id, CSW_KNIFE, DeadMaster_Models[0])
  1268.             cs_set_player_weap_model(id, CSW_KNIFE, DeadMaster_Models[1])
  1269.         }
  1270.         else if(g_bHammerChain[id] && (ze_get_vip_flags(id) & VIP_I))
  1271.         {
  1272.             cs_set_player_view_model(id, CSW_KNIFE, HammerChain_Models[0])
  1273.             cs_set_player_weap_model(id, CSW_KNIFE, HammerChain_Models[1])
  1274.         }
  1275.         else if(g_bKataha[id] && (ze_get_vip_flags(id) & VIP_I))
  1276.         {
  1277.             cs_set_player_view_model(id, CSW_KNIFE, Kataha_Models[0])
  1278.             cs_set_player_weap_model(id, CSW_KNIFE, Kataha_Models[1])
  1279.         }
  1280.         else if(g_bRanger[id] && (ze_get_vip_flags(id) & VIP_J))
  1281.         {
  1282.             cs_set_player_view_model(id, CSW_KNIFE, Ranger_Models[0])
  1283.             cs_set_player_weap_model(id, CSW_KNIFE, Ranger_Models[1])
  1284.         }
  1285.         else
  1286.         {
  1287.             cs_reset_player_view_model(id, CSW_KNIFE)
  1288.             cs_reset_player_weap_model(id, CSW_KNIFE)
  1289.         }
  1290.     }
  1291. }
  1292.  
  1293. public Fw_RestMaxSpeed_Post(id)
  1294. {
  1295.     if (g_bNoSpeed)
  1296.         return
  1297.        
  1298.     set_task(0.1, "DelayLoad", id)
  1299.    
  1300. }
  1301.  
  1302. public DelayLoad(id)
  1303. {
  1304.     new iWpnId = (get_user_weapon(id))
  1305.     if (iWpnId == CSW_KNIFE && g_bCompat[id])
  1306.     {
  1307.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1308.         {
  1309.             new iFlags = get_entvar(id, var_flags);
  1310.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1311.            
  1312.             if (!(iFlags & FL_ONGROUND))
  1313.                 return HC_CONTINUE
  1314.  
  1315.             if (iFlags & FL_WATERJUMP)
  1316.                 return HAM_IGNORED
  1317.  
  1318.             if (iWaterlvl > 1)
  1319.                 return HAM_IGNORED
  1320.            
  1321.             new Float:flVelocity[3]
  1322.             get_entvar(id , var_velocity , flVelocity)
  1323.  
  1324.             flVelocity[2] += 325
  1325.  
  1326.             set_entvar(id , var_velocity , flVelocity)
  1327.  
  1328.             set_entvar(id, var_gaitsequence, 6)
  1329.         }
  1330.        
  1331.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_compat))
  1332.     }
  1333.     if (iWpnId == CSW_KNIFE && g_bStrong[id])
  1334.     {
  1335.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1336.         {
  1337.             new iFlags = get_entvar(id, var_flags);
  1338.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1339.            
  1340.             if (!(iFlags & FL_ONGROUND))
  1341.                 return HC_CONTINUE
  1342.  
  1343.             if (iFlags & FL_WATERJUMP)
  1344.                 return HAM_IGNORED
  1345.  
  1346.             if (iWaterlvl > 1)
  1347.                 return HAM_IGNORED
  1348.            
  1349.             new Float:flVelocity[3]
  1350.             get_entvar(id , var_velocity , flVelocity)
  1351.  
  1352.             flVelocity[2] += 325
  1353.  
  1354.             set_entvar(id , var_velocity , flVelocity)
  1355.  
  1356.             set_entvar(id, var_gaitsequence, 6)
  1357.         }
  1358.        
  1359.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_strong))
  1360.     }
  1361.     if (iWpnId == CSW_KNIFE && g_bKatana[id])
  1362.     {
  1363.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1364.         {
  1365.             new iFlags = get_entvar(id, var_flags);
  1366.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1367.            
  1368.             if (!(iFlags & FL_ONGROUND))
  1369.                 return HC_CONTINUE
  1370.  
  1371.             if (iFlags & FL_WATERJUMP)
  1372.                 return HAM_IGNORED
  1373.  
  1374.             if (iWaterlvl > 1)
  1375.                 return HAM_IGNORED
  1376.            
  1377.             new Float:flVelocity[3]
  1378.             get_entvar(id , var_velocity , flVelocity)
  1379.  
  1380.             flVelocity[2] += 325
  1381.  
  1382.             set_entvar(id , var_velocity , flVelocity)
  1383.  
  1384.             set_entvar(id, var_gaitsequence, 6)
  1385.         }
  1386.        
  1387.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_katana))
  1388.     }
  1389.     if (iWpnId == CSW_KNIFE && g_bHammer[id])
  1390.     {
  1391.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1392.         {
  1393.             new iFlags = get_entvar(id, var_flags);
  1394.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1395.            
  1396.             if (!(iFlags & FL_ONGROUND))
  1397.                 return HC_CONTINUE
  1398.  
  1399.             if (iFlags & FL_WATERJUMP)
  1400.                 return HAM_IGNORED
  1401.  
  1402.             if (iWaterlvl > 1)
  1403.                 return HAM_IGNORED
  1404.            
  1405.             new Float:flVelocity[3]
  1406.             get_entvar(id , var_velocity , flVelocity)
  1407.  
  1408.             flVelocity[2] += 325
  1409.  
  1410.             set_entvar(id , var_velocity , flVelocity)
  1411.  
  1412.             set_entvar(id, var_gaitsequence, 6)
  1413.         }
  1414.        
  1415.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_hammer))
  1416.     }
  1417.     if (iWpnId == CSW_KNIFE && g_bTurbulent9[id])
  1418.     {
  1419.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1420.         {
  1421.             new iFlags = get_entvar(id, var_flags);
  1422.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1423.            
  1424.             if (!(iFlags & FL_ONGROUND))
  1425.                 return HC_CONTINUE
  1426.  
  1427.             if (iFlags & FL_WATERJUMP)
  1428.                 return HAM_IGNORED
  1429.  
  1430.             if (iWaterlvl > 1)
  1431.                 return HAM_IGNORED
  1432.            
  1433.             new Float:flVelocity[3]
  1434.             get_entvar(id , var_velocity , flVelocity)
  1435.  
  1436.             flVelocity[2] += 325
  1437.  
  1438.             set_entvar(id , var_velocity , flVelocity)
  1439.  
  1440.             set_entvar(id, var_gaitsequence, 6)
  1441.         }
  1442.        
  1443.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_turb))
  1444.     }
  1445.     if (iWpnId == CSW_KNIFE && g_bBio[id])
  1446.     {
  1447.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1448.         {
  1449.             new iFlags = get_entvar(id, var_flags);
  1450.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1451.            
  1452.             if (!(iFlags & FL_ONGROUND))
  1453.                 return HC_CONTINUE
  1454.  
  1455.             if (iFlags & FL_WATERJUMP)
  1456.                 return HAM_IGNORED
  1457.  
  1458.             if (iWaterlvl > 1)
  1459.                 return HAM_IGNORED
  1460.            
  1461.             new Float:flVelocity[3]
  1462.             get_entvar(id , var_velocity , flVelocity)
  1463.  
  1464.             flVelocity[2] += 325
  1465.  
  1466.             set_entvar(id , var_velocity , flVelocity)
  1467.  
  1468.             set_entvar(id, var_gaitsequence, 6)
  1469.         }
  1470.        
  1471.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_bio))
  1472.     }
  1473.     if (iWpnId == CSW_KNIFE && g_bSabers[id])
  1474.     {
  1475.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1476.         {
  1477.             new iFlags = get_entvar(id, var_flags);
  1478.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1479.            
  1480.             if (!(iFlags & FL_ONGROUND))
  1481.                 return HC_CONTINUE
  1482.  
  1483.             if (iFlags & FL_WATERJUMP)
  1484.                 return HAM_IGNORED
  1485.  
  1486.             if (iWaterlvl > 1)
  1487.                 return HAM_IGNORED
  1488.            
  1489.             new Float:flVelocity[3]
  1490.             get_entvar(id , var_velocity , flVelocity)
  1491.  
  1492.             flVelocity[2] += 325
  1493.  
  1494.             set_entvar(id , var_velocity , flVelocity)
  1495.  
  1496.             set_entvar(id, var_gaitsequence, 6)
  1497.         }
  1498.        
  1499.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_sabers))
  1500.     }
  1501.     if (iWpnId == CSW_KNIFE && g_bPlasma[id])
  1502.     {
  1503.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1504.         {
  1505.             new iFlags = get_entvar(id, var_flags);
  1506.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1507.            
  1508.             if (!(iFlags & FL_ONGROUND))
  1509.                 return HC_CONTINUE
  1510.  
  1511.             if (iFlags & FL_WATERJUMP)
  1512.                 return HAM_IGNORED
  1513.  
  1514.             if (iWaterlvl > 1)
  1515.                 return HAM_IGNORED
  1516.            
  1517.             new Float:flVelocity[3]
  1518.             get_entvar(id , var_velocity , flVelocity)
  1519.  
  1520.             flVelocity[2] += 325
  1521.  
  1522.             set_entvar(id , var_velocity , flVelocity)
  1523.  
  1524.             set_entvar(id, var_gaitsequence, 6)
  1525.         }
  1526.        
  1527.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_plasma))
  1528.     }
  1529.     if (iWpnId == CSW_KNIFE && g_bStorm[id])
  1530.     {
  1531.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1532.         {
  1533.             new iFlags = get_entvar(id, var_flags);
  1534.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1535.            
  1536.             if (!(iFlags & FL_ONGROUND))
  1537.                 return HC_CONTINUE
  1538.  
  1539.             if (iFlags & FL_WATERJUMP)
  1540.                 return HAM_IGNORED
  1541.  
  1542.             if (iWaterlvl > 1)
  1543.                 return HAM_IGNORED
  1544.            
  1545.             new Float:flVelocity[3]
  1546.             get_entvar(id , var_velocity , flVelocity)
  1547.  
  1548.             flVelocity[2] += 325
  1549.  
  1550.             set_entvar(id , var_velocity , flVelocity)
  1551.  
  1552.             set_entvar(id, var_gaitsequence, 6)
  1553.         }
  1554.        
  1555.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_storm))
  1556.     }
  1557.     if (iWpnId == CSW_KNIFE && g_bLaevateinn[id])
  1558.     {
  1559.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1560.         {
  1561.             new iFlags = get_entvar(id, var_flags);
  1562.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1563.            
  1564.             if (!(iFlags & FL_ONGROUND))
  1565.                 return HC_CONTINUE
  1566.  
  1567.             if (iFlags & FL_WATERJUMP)
  1568.                 return HAM_IGNORED
  1569.  
  1570.             if (iWaterlvl > 1)
  1571.                 return HAM_IGNORED
  1572.            
  1573.             new Float:flVelocity[3]
  1574.             get_entvar(id , var_velocity , flVelocity)
  1575.  
  1576.             flVelocity[2] += 325
  1577.  
  1578.             set_entvar(id , var_velocity , flVelocity)
  1579.  
  1580.             set_entvar(id, var_gaitsequence, 6)
  1581.         }
  1582.        
  1583.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_laevat))
  1584.     }
  1585.     if (iWpnId == CSW_KNIFE && g_bWarHammer_Dark_Knight[id])
  1586.     {
  1587.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1588.         {
  1589.             new iFlags = get_entvar(id, var_flags);
  1590.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1591.            
  1592.             if (!(iFlags & FL_ONGROUND))
  1593.                 return HC_CONTINUE
  1594.  
  1595.             if (iFlags & FL_WATERJUMP)
  1596.                 return HAM_IGNORED
  1597.  
  1598.             if (iWaterlvl > 1)
  1599.                 return HAM_IGNORED
  1600.            
  1601.             new Float:flVelocity[3]
  1602.             get_entvar(id , var_velocity , flVelocity)
  1603.  
  1604.             flVelocity[2] += 325
  1605.  
  1606.             set_entvar(id , var_velocity , flVelocity)
  1607.  
  1608.             set_entvar(id, var_gaitsequence, 6)
  1609.         }
  1610.        
  1611.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_darknight))
  1612.     }
  1613.     if (iWpnId == CSW_KNIFE && g_bBalrog_Kosa[id])
  1614.     {
  1615.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1616.         {
  1617.             new iFlags = get_entvar(id, var_flags);
  1618.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1619.            
  1620.             if (!(iFlags & FL_ONGROUND))
  1621.                 return HC_CONTINUE
  1622.  
  1623.             if (iFlags & FL_WATERJUMP)
  1624.                 return HAM_IGNORED
  1625.  
  1626.             if (iWaterlvl > 1)
  1627.                 return HAM_IGNORED
  1628.            
  1629.             new Float:flVelocity[3]
  1630.             get_entvar(id , var_velocity , flVelocity)
  1631.  
  1632.             flVelocity[2] += 325
  1633.  
  1634.             set_entvar(id , var_velocity , flVelocity)
  1635.  
  1636.             set_entvar(id, var_gaitsequence, 6)
  1637.         }
  1638.        
  1639.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_kosa))
  1640.     }
  1641.     if (iWpnId == CSW_KNIFE && g_bWereWolf[id])
  1642.     {
  1643.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1644.         {
  1645.             new iFlags = get_entvar(id, var_flags);
  1646.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1647.            
  1648.             if (!(iFlags & FL_ONGROUND))
  1649.                 return HC_CONTINUE
  1650.  
  1651.             if (iFlags & FL_WATERJUMP)
  1652.                 return HAM_IGNORED
  1653.  
  1654.             if (iWaterlvl > 1)
  1655.                 return HAM_IGNORED
  1656.            
  1657.             new Float:flVelocity[3]
  1658.             get_entvar(id , var_velocity , flVelocity)
  1659.  
  1660.             flVelocity[2] += 325
  1661.  
  1662.             set_entvar(id , var_velocity , flVelocity)
  1663.  
  1664.             set_entvar(id, var_gaitsequence, 6)
  1665.         }
  1666.        
  1667.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_werewolf))
  1668.     }
  1669.     if (iWpnId == CSW_KNIFE && g_bDeadMaster[id])
  1670.     {
  1671.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1672.         {
  1673.             new iFlags = get_entvar(id, var_flags);
  1674.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1675.            
  1676.             if (!(iFlags & FL_ONGROUND))
  1677.                 return HC_CONTINUE
  1678.  
  1679.             if (iFlags & FL_WATERJUMP)
  1680.                 return HAM_IGNORED
  1681.  
  1682.             if (iWaterlvl > 1)
  1683.                 return HAM_IGNORED
  1684.            
  1685.             new Float:flVelocity[3]
  1686.             get_entvar(id , var_velocity , flVelocity)
  1687.  
  1688.             flVelocity[2] += 325
  1689.  
  1690.             set_entvar(id , var_velocity , flVelocity)
  1691.  
  1692.             set_entvar(id, var_gaitsequence, 6)
  1693.         }
  1694.        
  1695.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_deadmaster))
  1696.     }
  1697.     if (iWpnId == CSW_KNIFE && g_bHammerChain[id])
  1698.     {
  1699.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1700.         {
  1701.             new iFlags = get_entvar(id, var_flags);
  1702.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1703.            
  1704.             if (!(iFlags & FL_ONGROUND))
  1705.                 return HC_CONTINUE
  1706.  
  1707.             if (iFlags & FL_WATERJUMP)
  1708.                 return HAM_IGNORED
  1709.  
  1710.             if (iWaterlvl > 1)
  1711.                 return HAM_IGNORED
  1712.            
  1713.             new Float:flVelocity[3]
  1714.             get_entvar(id , var_velocity , flVelocity)
  1715.  
  1716.             flVelocity[2] += 325
  1717.  
  1718.             set_entvar(id , var_velocity , flVelocity)
  1719.  
  1720.             set_entvar(id, var_gaitsequence, 6)
  1721.         }
  1722.        
  1723.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_hammerchain))
  1724.     }
  1725.     if (iWpnId == CSW_KNIFE && g_bKataha[id])
  1726.     {
  1727.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1728.         {
  1729.             new iFlags = get_entvar(id, var_flags);
  1730.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1731.            
  1732.             if (!(iFlags & FL_ONGROUND))
  1733.                 return HC_CONTINUE
  1734.  
  1735.             if (iFlags & FL_WATERJUMP)
  1736.                 return HAM_IGNORED
  1737.  
  1738.             if (iWaterlvl > 1)
  1739.                 return HAM_IGNORED
  1740.            
  1741.             new Float:flVelocity[3]
  1742.             get_entvar(id , var_velocity , flVelocity)
  1743.  
  1744.             flVelocity[2] += 325
  1745.  
  1746.             set_entvar(id , var_velocity , flVelocity)
  1747.  
  1748.             set_entvar(id, var_gaitsequence, 6)
  1749.         }
  1750.        
  1751.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_kataha))
  1752.     }
  1753.     if (iWpnId == CSW_KNIFE && g_bRanger[id])
  1754.     {
  1755.         if ((get_entvar(id, var_button) & IN_JUMP) && !(get_entvar(id, var_oldbuttons) & IN_JUMP))
  1756.         {
  1757.             new iFlags = get_entvar(id, var_flags);
  1758.             new iWaterlvl = get_entvar(id, var_waterlevel)
  1759.            
  1760.             if (!(iFlags & FL_ONGROUND))
  1761.                 return HC_CONTINUE
  1762.  
  1763.             if (iFlags & FL_WATERJUMP)
  1764.                 return HAM_IGNORED
  1765.  
  1766.             if (iWaterlvl > 1)
  1767.                 return HAM_IGNORED
  1768.            
  1769.             new Float:flVelocity[3]
  1770.             get_entvar(id , var_velocity , flVelocity)
  1771.  
  1772.             flVelocity[2] += 325
  1773.  
  1774.             set_entvar(id , var_velocity , flVelocity)
  1775.  
  1776.             set_entvar(id, var_gaitsequence, 6)
  1777.         }
  1778.        
  1779.         set_entvar(id, var_maxspeed, get_pcvar_float(cvar_speed_ranger))
  1780.     }
  1781.    
  1782.     return HC_CONTINUE
  1783. }
  1784.  
  1785. public DeathMsg(msg_id, msg_dest, id)
  1786. {
  1787.     static szTruncatedWeapon[33], iAttacker
  1788.     get_msg_arg_string(4, szTruncatedWeapon, charsmax(szTruncatedWeapon))
  1789.     iAttacker = get_msg_arg_int(1)
  1790.    
  1791.     if(!is_user_alive(iAttacker) || iAttacker == get_msg_arg_int(2) || !is_user_alive(get_msg_arg_int(2))) // get_msg_arg_int(2) = iVictim
  1792.         return
  1793.    
  1794.     if(equal(szTruncatedWeapon, "knife") && get_user_weapon(iAttacker) & CSW_KNIFE)
  1795.     {
  1796.         if(g_bCompat[id])
  1797.         {
  1798.             set_msg_arg_string(4, "Combat knife")
  1799.         }
  1800.         else if(g_bStrong[id])
  1801.         {
  1802.             set_msg_arg_string(4, "Strong knife")
  1803.         }
  1804.         else if(g_bKatana[id])
  1805.         {
  1806.             set_msg_arg_string(4, "Katana knife")
  1807.         }
  1808.         else if(g_bHammer[id])
  1809.         {
  1810.             set_msg_arg_string(4, "Ice knife")
  1811.         }
  1812.         else if(g_bTurbulent9[id])
  1813.         {
  1814.             set_msg_arg_string(4, "Turbulent9 knife")
  1815.         }
  1816.         else if(g_bBio[id])
  1817.         {
  1818.             set_msg_arg_string(4, "Biohazard knife")
  1819.         }
  1820.         else if(g_bSabers[id])
  1821.         {
  1822.             set_msg_arg_string(4, "Sabers knife")
  1823.         }
  1824.         else if(g_bPlasma[id])
  1825.         {
  1826.             set_msg_arg_string(4, "Plasma knife")
  1827.         }
  1828.         else if(g_bStorm[id])
  1829.         {
  1830.             set_msg_arg_string(4, "Storm knife")
  1831.         }
  1832.         else if(g_bLaevateinn[id])
  1833.         {
  1834.             set_msg_arg_string(4, "Laevateinn knife")
  1835.         }
  1836.         else if(g_bWarHammer_Dark_Knight[id])
  1837.         {
  1838.             set_msg_arg_string(4, "WarHammer Dark Knight knife")
  1839.         }
  1840.         else if(g_bBalrog_Kosa[id])
  1841.         {
  1842.             set_msg_arg_string(4, "Balrog Kosa Knife")
  1843.         }
  1844.        
  1845.         else if(g_bWereWolf[id])
  1846.         {
  1847.             set_msg_arg_string(4, "Were Wolf knife")
  1848.         }
  1849.         else if(g_bDeadMaster[id])
  1850.         {
  1851.             set_msg_arg_string(4, "Dead Master knife")
  1852.         }
  1853.         else if(g_bHammerChain[id])
  1854.         {
  1855.             set_msg_arg_string(4, "Hammer Chain knife")
  1856.         }
  1857.         else if(g_bKataha[id])
  1858.         {
  1859.             set_msg_arg_string(4, "Kataha knife")
  1860.         }
  1861.         else if(g_bRanger[id])
  1862.         {
  1863.             set_msg_arg_string(4, "Ranger Knife")
  1864.         }
  1865.     }
  1866. }
  1867.  
  1868. stock fm_set_user_maxspeed(index, Float:speed = -1.0)
  1869. {
  1870.         engfunc(EngFunc_SetClientMaxspeed, index, speed);
  1871.         set_pev(index, pev_maxspeed, speed);
  1872.  
  1873.         return 1;
  1874. }  
  1875.  
  1876. public native_ze_open_knife_menu(id)
  1877. {
  1878.     Show_Knife_Menu(id)
  1879. }

Re: Knife Menu!

Posted: 28 Apr 2019, 17:44
by Luxurious
i will test it when i open the pc ...

Re: Knife Menu!

Posted: 04 May 2019, 20:03
by Mark
Luxurious wrote:
3 Months Ago
i will test it when i open the pc ...
Im going to think this is working for you.

Re: Knife Menu!

Posted: 07 May 2019, 05:35
by Luxurious
Mark wrote:
3 Months Ago
Luxurious wrote:
4 Months Ago
Mark wrote:
4 Months Ago
Is your problem solved?
sorry for late ... i tried it today and it working but can u make 5 knifes free and more knives make access for it ...
I would need to know what Knives you want for VIP first.
I Still didn`t try it , cuz i have exams and i don`t have a time to open the pc ... i will test if after a few days .