Пользователь
-
Автор темы
- #1
Onetap v2 fakeduck
Возможно вронг.
Возможно вронг.
C++:
void OneTap::Features::FakeDuck::Instance()
{
// [COLLAPSED LOCAL DECLARATIONS. PRESS KEYPAD CTRL-"+" TO EXPAND]
float m_flAwaitedDuck = 0.0;
int m_iMaxChoke = 4 * (g_pGlobals.Server.Type < 3) + 10;
bool m_bFactors = (g_pLocalPlayer->m_fFlags() & FL_ONGROUND) && !g_pGlobals.Exploits.IsAllowed && !g_pGlobals.Exploits.TickbaseShift
&& g_pGlobals.Server.AnimstateMode == ANIMSTATE_DEFAULT
&& g_pConfigs.Ragebot.Enabled
&& (g_pConfigs.Misc.FakeduckKey > 0 && g_pConfigs.Misc.Fakeduck)
&& g_pGlobals.Server.Tickrate == 64;
g_pGlobals.Data.FakeduckEnabled = m_bFactors;
if (!g_pGlobals.Data.FakeduckEnabled)
{
if (m_bFactors)
{
if (g_pClientState->m_iChokedCommands)
{
g_pGlobals.Data.FakeduckEnabled = false;
}
else
{
g_pGlobals.UserCmd->m_buttons |= IN_BULLRUSH;
g_pGlobals.UserCmd->m_buttons &= ~IN_DUCK;
}
}
return;
}
if (m_bFactors)
{
g_pGlobals.UserCmd->m_buttons |= IN_BULLRUSH;
if (g_pClientState->m_iChokedCommands < m_iMaxChoke)
g_pGlobals.UserCmd->m_buttons &= ~IN_DUCK;
else
g_pGlobals.UserCmd->m_buttons |= IN_DUCK;
}
if (g_pGlobals.UserCmd->m_buttons & IN_DUCK)
m_flAwaitedDuck = 1.0;
else
m_flAwaitedDuck = 0.0;
if (m_flAwaitedDuck == g_pLocalPlayer->m_flDuckAmount())
{
if (!g_pGlobals.Data.FakeduckEnabled)
return;
g_pGlobals.Data.NextChoke = m_iMaxChoke + g_pLocalPlayer->m_nTickbase() - g_pClientState->m_iChokedCommands + 1;
}
g_pGlobals.Data.FakeduckEnabled = true;
g_pGlobals.UserCmd->m_buttons |= IN_BULLRUSH;
if (m_flAwaitedDuck <= g_pLocalPlayer->m_flDuckAmount())
g_pGlobals.UserCmd->m_buttons &= ~IN_DUCK;
else
g_pGlobals.UserCmd->m_buttons |= IN_DUCK;
if (g_pClientState->m_iChokedCommands < m_iMaxChoke)
g_pGlobals.Data.IsChoked = true;
else
g_pGlobals.Data.NextChoke = g_pLocalPlayer->m_nTickbase() + 1;
}