This still bunnyhop slow.
how can make it bunnyhoper faster like in Jailbreak mod
PHP Code:
/*
*
* Author: Cheesy Peteza
* Date: 22-Apr-2004 (updated 17-October-2009 ConnorMcLeod)
*
*
* Description: Enable bunny hopping in Counter-Strike.
*
* Cvars:
* bh_noslowdown If set to 1 players will not slow down after jump (more speed)
* bh_autojump If set to 1 players just need to hold down jump to bunny hop (no skill required)
* bh_showusage If set to 1 it will inform joining players that bunny hopping has been enabled
* and how to use it if bh_autojump enabled.
*
* Requirements: AMXModX 1.8.0 or greater
*
*
*/
// Set this to true or false depending on how you want the bhop player state to be when he joins the server.
#define ENABLE_BHOP_WHEN_PLAYER_JOINS true
#include <amxmodx>
#include <engine>
#include <hamsandwich>
#define VERSION "1.6"
new bh_autojump, bh_showusage, bh_noslowdown
new g_bHasBhop[33 char]
public plugin_init()
{
register_plugin("Super Bunny Hopper", VERSION, "Cheesy Peteza")
register_cvar("sbhopper_version", VERSION, FCVAR_SERVER)
RegisterHam(Ham_Player_Jump, "player", "CBasePlayer_Jump")
bh_autojump = register_cvar("bh_autojump", "1")
bh_noslowdown = register_cvar("bh_noslowdown", "1")
bh_showusage = register_cvar("bh_showusage", "0")
register_clcmd("say /on", "ClCmd_Bhop");
register_clcmd("say_team /on", "ClCmd_Bhop");
register_clcmd("say /off", "ClCmd_Bhop");
register_clcmd("say_team /off", "ClCmd_Bhop");
}
public ClCmd_Bhop( id )
{
g_bHasBhop{ id } = !g_bHasBhop{ id }
client_print(id, print_chat, "AutoBhop is now %sable for you.", g_bHasBhop{ id } ? "en" : "dis")
}
public CBasePlayer_Jump(id)
{
if( g_bHasBhop{ id } && is_user_alive(id) )
{
if( get_pcvar_num(bh_noslowdown) && entity_get_float(id, EV_FL_fuser2) > 0.0 )
{
entity_set_float(id, EV_FL_fuser2, 0.0)
}
static const FL_FLAGS = FL_WATERJUMP|FL_ONGROUND
static iOldButtons
if( get_pcvar_num(bh_autojump)
&& entity_get_int(id, EV_INT_flags) & FL_FLAGS == FL_ONGROUND
&& entity_get_int(id, EV_INT_waterlevel) < 2
&& (iOldButtons = entity_get_int(id, EV_INT_oldbuttons)) & IN_JUMP )
{
entity_set_int(id, EV_INT_oldbuttons, iOldButtons & ~IN_JUMP)
}
}
}
public client_putinserver(id)
{
g_bHasBhop{ id } = ENABLE_BHOP_WHEN_PLAYER_JOINS
remove_task(id)
if( get_pcvar_num(bh_showusage) )
{
set_task(30.0, "Task_ShowUsage", id)
}
}
public Task_ShowUsage(id)
{
if( get_pcvar_num(bh_autojump) )
{
client_print(id, print_chat, "[AMXX] Auto bunny hopping is enabled on this server. Just hold down jump to bunny hop.")
}
if( get_pcvar_num(bh_noslowdown) )
{
client_print(id, print_chat, "[AMXX] Bunny hopping with higher speed is enabled on this server. You will not slow down after jumping.")
}
client_print(id, print_chat, "[AMXX] Type say /bhop to toggle bhop features.")
}
i want make it normal speed no slow..