CObject* CObjectManager::Radar(CObject* pThis, Math::Vector thisPosition, float thisAngle, ObjectType type, float angle, float focus, float minDist, float maxDist, bool furthest, RadarFilter filter, bool cbotTypes) { std::vector<ObjectType> types; if (type != OBJECT_NULL) types.push_back(type); return Radar(pThis, thisPosition, thisAngle, types, angle, focus, minDist, maxDist, furthest, filter, cbotTypes); }
CObject* CObjectManager::Radar(CObject* pThis, std::vector<ObjectType> type, float angle, float focus, float minDist, float maxDist, bool furthest, RadarFilter filter, bool cbotTypes) { Math::Vector iPos; float iAngle; if (pThis != nullptr) { iPos = pThis->GetPosition(); iAngle = pThis->GetRotationY(); iAngle = Math::NormAngle(iAngle); // 0..2*Math::PI } else { iPos = Math::Vector(); iAngle = 0.0f; } return Radar(pThis, iPos, iAngle, type, angle, focus, minDist, maxDist, furthest, filter, cbotTypes); }
int main() { std::cout << "Radar and Trigger\n\n"; Engine()->start(); std::thread engineThread(&CEngine::update, Engine()); std::cout << "Found\n\n"; std::cout << "Offsets\n"; std::cout << "Local player: 0x" << Engine()->Offsets()->toHex(Engine()->Offsets()->dwLocalPlayer) << "\n"; std::cout << "Entity list: 0x" << Engine()->Offsets()->toHex(Engine()->Offsets()->dwEntityList) << "\n"; std::cout << "Attack: 0x" << Engine()->Offsets()->toHex(Engine()->Offsets()->dwAttack) << "\n\n"; std::cout << "Hotkeys:\n"; std::cout << "Triggerkey: "; Settings()->trigger_key = whichKeyIsPressed(); std::cout << Settings()->trigger_key << "\n"; std::cout << "Trigger hold key (press ENTER for no hold key): "; Settings()->trigger_holdkey = whichKeyIsPressed(); if (Settings()->trigger_holdkey == VK_RETURN) { Settings()->trigger_holdkey = 0; } std::cout << Settings()->trigger_holdkey << "\n"; std::cout << "Radar key: "; Settings()->radar_key = whichKeyIsPressed(); std::cout << Settings()->radar_key << "\n\n"; std::cout << "The hack is now active!\n\n"; std::thread settingsThread(&CSettings::run, Settings()); std::thread radarThread(&Radar::run, Radar()); std::thread triggerThread(&Triggerbot::run, Triggerbot()); while (!GetAsyncKeyState(VK_END)) { Sleep(100); } exit(0); return 0; }
CObject* CObjectManager::FindNearest(CObject* pThis, Math::Vector thisPosition, std::vector<ObjectType> type, float maxDist, bool cbotTypes) { return Radar(pThis, thisPosition, 0.0f, type, 0.0f, Math::PI*2.0f, 0.0f, maxDist, false, FILTER_NONE, cbotTypes); }
CObject* CObjectManager::FindNearest(CObject* pThis, ObjectType type, float maxDist, bool cbotTypes) { return Radar(pThis, type, 0.0f, Math::PI*2.0f, 0.0f, maxDist, false, FILTER_NONE, cbotTypes); }