diff --git a/src/entityhitboxcache.cpp b/src/entityhitboxcache.cpp index a265a900..06221177 100644 --- a/src/entityhitboxcache.cpp +++ b/src/entityhitboxcache.cpp @@ -36,7 +36,8 @@ void EntityHitboxCache::Update() { SAFE_CALL(InvalidateCache()); if (CE_BAD(parent_ref)) return; } - +static CatVar add_tick(CV_SWITCH, "add_tick", "1", "Expand 2D Box", "Expand 2D box by N units"); +static CatVar add_ticks(CV_INT, "add_ticks", "2", "Expand 2D Box", "Expand 2D box by N units"); void EntityHitboxCache::Init() { model_t *model; studiohdr_t *shdr; @@ -45,6 +46,9 @@ void EntityHitboxCache::Init() { m_bInit = true; model = 0; if (CE_BAD(parent_ref)) return; + + tickcount += 1; + SAFE_CALL(model = (model_t*)RAW_ENT(parent_ref)->GetModel()); if (!model) return; if (!m_bModelSet || model != m_pLastModel) { @@ -80,7 +84,7 @@ bool EntityHitboxCache::VisibilityCheck(int id) { } static CatEnum setupbones_time_enum({ "ZERO", "CURTIME", "LP SERVERTIME", "SIMTIME" }); -static CatVar setupbones_time(setupbones_time_enum, "setupbones_time", "1", "Setupbones", "Defines setupbones 4th argument, change it if your aimbot misses, idk!!"); +static CatVar setupbones_time(setupbones_time_enum, "setupbones_time", "3", "Setupbones", "Defines setupbones 4th argument, change it if your aimbot misses, idk!!"); matrix3x4_t* EntityHitboxCache::GetBones() { static float bones_setup_time = 0.0f; diff --git a/src/hacks/Aimbot.cpp b/src/hacks/Aimbot.cpp index 53d1893a..0d4d672c 100644 --- a/src/hacks/Aimbot.cpp +++ b/src/hacks/Aimbot.cpp @@ -526,12 +526,10 @@ bool CanAutoShoot() { IF_GAME (IsTF2()) { - if (wait_for_charge) { - // Check if players current weapon is an ambasador - if (IsAmbassador(g_pLocalPlayer->weapon())) { - // Check if ambasador can headshot - if (!AmbassadorCanHeadshot()) return false; - } + // Check if players current weapon is an ambasador + if (IsAmbassador(g_pLocalPlayer->weapon())) { + // Check if ambasador can headshot + if (!AmbassadorCanHeadshot()) return false; } } @@ -553,25 +551,6 @@ bool CanAutoShoot() { // Return false due to setting not allowing autoshoot return false; } - static CatVar displace(CV_INT, "displace", "4", "Expand 2D Box", "Expand 2D box by N units"); -Vector SimpleThonkPrediction(CachedEntity* ent, int hb) { - if (!ent) return Vector(); - Vector result; - GetHitbox(ent, hb, result); - float latency = g_IEngine->GetNetChannelInfo()->GetLatency(FLOW_OUTGOING) + - g_IEngine->GetNetChannelInfo()->GetLatency(FLOW_INCOMING); - result -= CE_VECTOR(ent, netvar.vVelocity) * (int)displace; - return result; -} - -Vector SimpleDisplacementPrediction(CachedEntity* ent, int hb) { - if (!ent) return Vector(); - Vector result; - GetHitbox(ent, hb, result); - Vector displacement = RAW_ENT(ent)->GetAbsOrigin() - ent->m_vecOrigin; - result += displacement; - return result; -} // Grab a vector for a specific ent const Vector& PredictEntity(CachedEntity* entity) { @@ -592,7 +571,7 @@ const Vector& PredictEntity(CachedEntity* entity) { } else { // If using extrapolation, then predict a vector if (extrapolate) - result = SimpleThonkPrediction(entity, cd.hitbox); + result = SimpleLatencyPrediction(entity, cd.hitbox); // else just grab strait from the hitbox else GetHitbox(entity, cd.hitbox, result);