Skip to content

Commit

Permalink
implemented native autobhop (untested)
Browse files Browse the repository at this point in the history
  • Loading branch information
nikooo777 committed Oct 14, 2016
1 parent f8f9d9a commit c7a1f5a
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
Binary file modified csgo/addons/sourcemod/plugins/ckSurf.smx
Binary file not shown.
10 changes: 8 additions & 2 deletions csgo/addons/sourcemod/scripting/ckSurf.sp
Original file line number Diff line number Diff line change
Expand Up @@ -687,7 +687,11 @@ bool g_bPracticeMode[MAXPLAYERS + 1]; // Client is in the practice mode

/*------------ late load linux fix --------*/
Handle g_cvar_sv_hibernate_when_empty = INVALID_HANDLE;
//bool g_useHibernate = false;

/**
* Autobhop handle
*/
Handle g_cvar_sv_autobunnyhopping = INVALID_HANDLE;

/*=========================================
= Predefined arrays =
Expand Down Expand Up @@ -1657,7 +1661,9 @@ public void OnPluginStart()

//linux late-loading fix
g_cvar_sv_hibernate_when_empty = FindConVar("sv_hibernate_when_empty");

g_cvar_sv_autobunnyhopping = FindConVar("sv_autobunnyhopping");
SetConVarBool(g_cvar_sv_autobunnyhopping, false);

if (GetConVarInt(g_cvar_sv_hibernate_when_empty) == 1)
{
SetConVarInt(g_cvar_sv_hibernate_when_empty, 0);
Expand Down
1 change: 1 addition & 0 deletions csgo/addons/sourcemod/scripting/ckSurf/commands.sp
Original file line number Diff line number Diff line change
Expand Up @@ -1835,6 +1835,7 @@ public void AutoBhop(int client)
PrintToChat(client, "%t", "AutoBhop3", MOSSGREEN, WHITE);

g_bAutoBhopClient[client] = !g_bAutoBhopClient[client];
SendConVarValue(client, g_cvar_sv_autobunnyhopping, (g_bAutoBhopClient[client]?"1":"0"));
}

public Action Client_Hide(int client, int args)
Expand Down

0 comments on commit c7a1f5a

Please sign in to comment.