Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- hooks.cpp
- if (SETTINGS::settings.autozeus_bool) aimbot->autozeus(cmd);
- so it looks like
- if (SETTINGS::settings.autozeus_bool) aimbot->autozeus(cmd);
- if (SETTINGS::settings.bhop_bool) movement->bunnyhop(cmd);
- if (SETTINGS::settings.duck_bool) movement->duckinair(cmd);
- aimbot.cpp
- void CAimbot::autozeus(SDK::CUserCmd *cmd) {
- for (int i = 1; i < 65; i++)
- {
- auto entity = INTERFACES::ClientEntityList->GetClientEntity(i);
- auto local_player = INTERFACES::ClientEntityList->GetClientEntity(INTERFACES::Engine->GetLocalPlayer());
- if (!entity)
- continue;
- if (!local_player)
- continue;
- bool is_local_player = entity == local_player;
- bool is_teammate = local_player->GetTeam() == entity->GetTeam() && !is_local_player;
- if (is_local_player)
- continue;
- if (!entity->IsAlive())
- continue;
- if (is_teammate)
- continue;
- if (!local_player->IsAlive())
- continue;
- auto weapon = reinterpret_cast<SDK::CBaseWeapon*>(INTERFACES::ClientEntityList->GetClientEntity(local_player->GetActiveWeaponIndex()));
- if (!weapon)
- continue;
- if (weapon->GetItemDefenitionIndex() == SDK::WEAPON_TASER) //if we have a taser men!1!!1
- {
- if (can_shoot(cmd))
- {
- int bone = zeus_hitbox(entity); //you can change this but keep in mind this has range stuff. it only has pelvis as a bone but why do other stuff really it will make it inaccurate shooting at arms and legs if they arent resolved right
- if (bone != 1)
- {
- Vector fucknigga = get_hitbox_pos(entity, bone);
- Vector local_position = local_player->GetVecOrigin() + local_player->GetViewOffset();
- if (fucknigga != Vector(0, 0, 0))
- {
- SDK::trace_t trace;
- autowall->UTIL_TraceLine(local_position, fucknigga, MASK_SOLID, local_player, 0, &trace);
- SDK::player_info_t info;
- if (!(INTERFACES::Engine->GetPlayerInfo(trace.m_pEnt->GetIndex(), &info)))
- continue;
- if (fucknigga != Vector(0, 0, 0))
- {
- cmd->viewangles = MATH::NormalizeAngle(UTILS::CalcAngle(local_position, fucknigga));
- GLOBAL::should_send_packet = true;
- cmd->buttons |= IN_ATTACK;
- }
- }
- }
- }
- continue;
- }
- }
- }
- int CAimbot::zeus_hitbox(SDK::CBaseEntity* entity)
- {
- auto local_player = INTERFACES::ClientEntityList->GetClientEntity(INTERFACES::Engine->GetLocalPlayer());
- if (!local_player)
- return -1;
- Vector local_position = local_player->GetVecOrigin() + local_player->GetViewOffset();
- float closest = 180.f;
- bestHitbox = -1;
- Vector point = get_hitbox_pos(entity, SDK::HitboxList::HITBOX_PELVIS);
- if (point != Vector(0, 0, 0))
- {
- float distance = fabs((point - local_position).Length());
- if (distance <= closest)
- {
- bestHitbox = SDK::HitboxList::HITBOX_PELVIS;
- closest = distance;
- }
- }
- return bestHitbox;
- }
- aimbot.h
- void autozeus(SDK::CUserCmd *cmd);
- int zeus_hitbox(SDK::CBaseEntity *entity);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement