made working tauntslide

This commit is contained in:
julianacat 2017-06-18 00:38:24 -05:00
parent 890d33b390
commit f824452eaf
3 changed files with 17 additions and 10 deletions

View File

@ -249,7 +249,6 @@ void draw::OutlineRect(int x, int y, int w, int h, int color) {
g_ISurface->DrawOutlinedRect(x, y, x + w, y + h); g_ISurface->DrawOutlinedRect(x, y, x + w, y + h);
} }
//Potentially broken circle draw
void draw::DrawCircle(float x, float y, float r, int num_segments, int color) { void draw::DrawCircle(float x, float y, float r, int num_segments, int color) {
if (num_segments < 3 || r == 0 ) return; if (num_segments < 3 || r == 0 ) return;
g_ISurface->DrawSetColor(*reinterpret_cast<Color*>(&color)); g_ISurface->DrawSetColor(*reinterpret_cast<Color*>(&color));

View File

@ -674,7 +674,7 @@ EAimbotLocalState ShouldAim() {
} }
return EAimbotLocalState::GOOD; return EAimbotLocalState::GOOD;
} }
static CatVar fov_draw(CV_SWITCH, "aimbot_fov_draw", "0", "Draw Fov Ring", "Draws a ring to represent your current aimbot fov\nDoesnt change according to zoom fov\nWIP");
void PaintTraverse() { void PaintTraverse() {
if (!enabled) return; if (!enabled) return;

View File

@ -133,7 +133,7 @@ int StartSceneEvent_hooked(IClientEntity* _this, int sceneInfo, int choreoScene,
float last_bucket = 0; float last_bucket = 0;
static CatVar tauntslide_moveable(CV_SWITCH, "tauntslide_moveable", "0", "Taunt Slide", "Allows free movement while taunting with movable taunts\nOnly works in tf2"); static CatVar tauntslide_moveable(CV_SWITCH, "tauntslide_moveable", "0", "Taunt Slide", "Allows free movement while taunting with movable taunts\nOnly works in tf2\nWIP");
void CreateMove() { void CreateMove() {
static bool flswitch = false; static bool flswitch = false;
@ -145,17 +145,25 @@ void CreateMove() {
static bool changed = false; static bool changed = false;
static ConVar *pNoPush = g_ICvar->FindVar("tf_avoidteammates_pushaway"); static ConVar *pNoPush = g_ICvar->FindVar("tf_avoidteammates_pushaway");
//Only work if the catvar enables it //Only work if the catvar enables it
if (tauntslide_moveable) { if (tauntslide_moveable) {
//Check to prevent crashing
if (CE_GOOD(LOCAL_E)) {
//If the local player is taunting //If the local player is taunting
if (HasCondition<TFCond_Taunting>(LOCAL_E)) { if (HasCondition<TFCond_Taunting>(LOCAL_E)) {
//Set actual angles = the third person cameras angle logging::Info("sLIDDING ");
g_pUserCmd->viewangles.y = g_pLocalPlayer->v_OrigViewangles.y; //Grab Camera angle
static QAngle cameraAngle;
g_IEngine->GetViewAngles(cameraAngle);
//Set userAngle = camera angles
g_pUserCmd->viewangles.y = cameraAngle[1];
//Use silent since we dont want to prevent the player from looking around //Use silent since we dont want to prevent the player from looking around
g_pLocalPlayer->bUseSilentAngles = true; g_pLocalPlayer->bUseSilentAngles = true;
} }
} }
}
if (no_taunt_ticks && CE_GOOD(LOCAL_E)) { if (no_taunt_ticks && CE_GOOD(LOCAL_E)) {
RemoveCondition<TFCond_Taunting>(LOCAL_E); RemoveCondition<TFCond_Taunting>(LOCAL_E);
no_taunt_ticks--; no_taunt_ticks--;