From 4ff3a2cc2b706373a80ef26ee0e3bf888d111f62 Mon Sep 17 00:00:00 2001 From: julianacat Date: Sun, 4 Jun 2017 13:11:20 -0500 Subject: [PATCH] Added :b:one esp --- src/gui/ncc/Menu.cpp | 1 + src/hacks/ESP.cpp | 29 ++++++++++++++++++++++++++++- src/hacks/FollowBot.cpp | 3 +++ 3 files changed, 32 insertions(+), 1 deletion(-) diff --git a/src/gui/ncc/Menu.cpp b/src/gui/ncc/Menu.cpp index 50e65eaf..0bb33409 100644 --- a/src/gui/ncc/Menu.cpp +++ b/src/gui/ncc/Menu.cpp @@ -379,6 +379,7 @@ static const std::string list_tf2 = R"( "esp_enabled" "font_esp_family" "font_esp_height" + "esp_bone" "esp_conds" "esp_class" "esp_name" diff --git a/src/hacks/ESP.cpp b/src/hacks/ESP.cpp index 54eb37da..92595059 100644 --- a/src/hacks/ESP.cpp +++ b/src/hacks/ESP.cpp @@ -228,6 +228,26 @@ void Draw3DBox(CachedEntity* ent, int clr, bool healthbar, int health, int healt } } +static CatVar esp_bone(CV_SWITCH, "esp_bone", "0", "Bone esp", "Creates lines on the players bone"); + +void DrawBones(CachedEntity* ent, int clr) { + Vector scnSrt, scnEnd, boneStart, boneEnd; + + //Place for every bone to be "connected" to + int bonesx [17] = { 1, 2, 3, 4, 5, 5, 6, 7, 5, 9, 10, 1, 15, 16, 1, 12, 13 }; + int bonesy [17] = { 2, 3, 4, 5, 0, 6, 7, 8, 9, 10, 11, 15, 16, 17, 12, 13, 14 }; + + for (int i = 0; i < 17; i++) { + + GetHitbox(ent, bonesx[i], boneStart); + GetHitbox(ent, bonesy[i], boneEnd); + draw::WorldToScreen(boneStart, scnSrt); + draw::WorldToScreen(boneEnd, scnEnd); + draw::DrawLine(scnSrt.x, scnSrt.y, scnEnd.x - scnSrt.x, scnEnd.y - scnSrt.y, clr); + } +} + + static CatVar box_nodraw(CV_SWITCH, "esp_box_nodraw", "0", "Invisible 2D Box", "Don't draw 2D box"); static CatVar box_expand(CV_INT, "esp_box_expand", "0", "Expand 2D Box", "Expand 2D box by N units"); @@ -547,7 +567,14 @@ void _FASTCALL ProcessEntityPT(CachedEntity* ent) { fg = ent_data.color; if (!draw::EntityCenterToScreen(ent, screen) && !draw::WorldToScreen(ent->m_vecOrigin, origin_screen)) return; - + + if (esp_bone) { + if (ent->m_Type == ENTITY_PLAYER) { + if (!IsPlayerInvisible(ent)) { + DrawBones(ent, fg); + } + } + } if (box_esp) { switch (ent->m_Type) { case ENTITY_PLAYER: { diff --git a/src/hacks/FollowBot.cpp b/src/hacks/FollowBot.cpp index 460ea1fe..4588f3b7 100644 --- a/src/hacks/FollowBot.cpp +++ b/src/hacks/FollowBot.cpp @@ -233,6 +233,9 @@ CatCommand tool("fb_tool", "Followbot multitool", [](const CCommand& args) { CatCommand follow("fb_follow", "Follows you (or player with SteamID specified)", [](const CCommand& args) { follow_steamid = strtol(args.Arg(1), nullptr, 10); + allow_moving = true; + crumbForceMove = true; + CrumbStart(); }); CatVar bot(CV_SWITCH, "fb_bot", "0", "This player is a bot", "Set to 1 in followbots' configs"); CatVar mimic_slot(CV_SWITCH, "fb_mimic_slot", "1", "Mimic selected weapon", "If enabled, this bot will select same weapon slot as the owner");