-
Автор темы
- #1
bool CAutoWall::FireBullet(C_CSPlayer* pLocal, CBaseCombatWeapon* pWeapon, Vector& direction, float& currentDamage, int& possibleHitsRemaining) const
{
if (!pWeapon)
return false;
static auto UTIL_ClipTraceToPlayers = [](const Vector& vecAbsStart, const Vector& vecAbsEnd, unsigned int mask, ITraceFilter* filter, trace_t* tr)
{
static uintptr_t clptrtp = Utils::FindSignature(Utils::get_client_dll(), XorStr("53 8B DC 83 EC ? 83 E4 ? 83 C4 ? 55 8B 6B 04 89 6C 24 ? 8B EC 81 EC ? ? ? ? 8B 43 10 56 57 52 F3 0F 10 40"));
if (!clptrtp)
return false;
__asm {
push tr
push filter
push mask
lea edx, vecAbsEnd
lea ecx, vecAbsStart
call clptrtp
add esp, 0xC
}
};
{
if (!pWeapon)
return false;
static auto UTIL_ClipTraceToPlayers = [](const Vector& vecAbsStart, const Vector& vecAbsEnd, unsigned int mask, ITraceFilter* filter, trace_t* tr)
{
static uintptr_t clptrtp = Utils::FindSignature(Utils::get_client_dll(), XorStr("53 8B DC 83 EC ? 83 E4 ? 83 C4 ? 55 8B 6B 04 89 6C 24 ? 8B EC 81 EC ? ? ? ? 8B 43 10 56 57 52 F3 0F 10 40"));
if (!clptrtp)
return false;
__asm {
push tr
push filter
push mask
lea edx, vecAbsEnd
lea ecx, vecAbsStart
call clptrtp
add esp, 0xC
}
};