-
Автор темы
- #1
This only works in local server usually only to check your animation fix or shot position and such functions.
Now before you start typing with "PUBLIC, LEAKED, I KNOW A BETTER WAY" just realize you haven't posted it so do it and we'll see. Also to the pasters I won't spoon-feed any more information then the functions code.
Yes to you the only person who don't understand the code I still created this code good luck pasting in the UC code and for it to just work...
Now before you start typing with "PUBLIC, LEAKED, I KNOW A BETTER WAY" just realize you haven't posted it so do it and we'll see. Also to the pasters I won't spoon-feed any more information then the functions code.
Yes to you the only person who don't understand the code I still created this code good luck pasting in the UC code and for it to just work...
C++:
void Client::DrawServerHitboxes() {
if (!g_cl.m_local || !g_cl.m_local->alive()) { // we checking both cus why not, can't hurt us.
return;
}
if (!g_csgo.m_input->CAM_IsThirdPerson()) { // useless in first-person.
return;
}
// Function to get a player by index
auto getPlayerByIndex = [](int index) -> Player* {
typedef Player* (__fastcall* playerByIndex)(int);
static auto playerIndexFunc = pattern::find(PE::GetModule(HASH("server.dll")), "85 C9 7E 2A A1").as<playerByIndex>();
if (!playerIndexFunc) {
return nullptr;
}
return playerIndexFunc(index);
};
// Find the function address
static auto functionAddress = pattern::find(PE::GetModule(HASH("server.dll")), "55 8B EC 81 EC ? ? ? ? 53 56 8B 35 ? ? ? ? 8B D9 57 8B CE").as<uintptr_t>();
auto duration = -1.f;
PVOID entity = nullptr;
entity = getPlayerByIndex(g_cl.m_local->index());
if (!entity) {
return;
}
// keep your assembly I won't...
typedef void(__fastcall* DrawFunction)(PVOID entity, float duration);
DrawFunction drawFn = reinterpret_cast<DrawFunction>(functionAddress);
drawFn(entity, duration);
}
credit:
des1gner UC
1337floesen UC