Welcome to hackvshack.net Forum!
Download Free HvH CS2/CS:GO Cheats, CFG, LUA/JS Scripts, and More!
Register

C++ fast reload

bitcoinbandit

Rookie HvHer
User ID:
59772
Messages:
78
Reactions:
24
Badges:
11
REP:
−0/0+
Level:
94
SHOWCASE:
call it in createmove and set cl_weapon_stealth_reload_toggle 1
also allows u to fire during a reload

The Code:
Expand Collapse Copy
void CFastReload::Run( CUserCmd* pCmd, C_CSPlayerPawn* pLocal ) {
    C_CSWeaponBase* pWeapon = pLocal->GetActiveWeapon( );
    if ( !pWeapon || pWeapon->GetVData( )->ReloadsSingleShells( ) || !pWeapon->InReload( ) ) {
        m_nPresses = 0;
        return;
    }
    CInButtonStatePB* pButtons = pCmd->m_Pb.base->buttons_pb;
    const int         nState   = pWeapon->GameplayAnimState( );
    if ( nState == ANIM_RELOAD ) {
        if ( pWeapon->ReloadHeldSinceStart( ) ) {
            pButtons->buttonstate1 |= IN_RELOAD;
        }
        return;
    }
    if ( nState != ANIM_RELOAD_SILENT || m_nPresses >= 8) {
        return;
    }
    const float flWait = static_cast< float >( pWeapon->NextPrimaryAttackTick( ) - ( pCmd->m_nTick - 1 ) ) + pWeapon->NextPrimaryAttackTickRatio( );
    if ( flWait <= 0.0f ) {
        return;
    }
    pButtons->buttonstate1 |= IN_RELOAD;
    pButtons->buttonstate2 |= IN_RELOAD;
    ++m_nPresses;
}
 
  • Like
Reactions: zaneATAT
SHOWCASE:
call it in createmove and set cl_weapon_stealth_reload_toggle 1
also allows u to fire during a reload

The Code:
Expand Collapse Copy
void CFastReload::Run( CUserCmd* pCmd, C_CSPlayerPawn* pLocal ) {
    C_CSWeaponBase* pWeapon = pLocal->GetActiveWeapon( );
    if ( !pWeapon || pWeapon->GetVData( )->ReloadsSingleShells( ) || !pWeapon->InReload( ) ) {
        m_nPresses = 0;
        return;
    }
    CInButtonStatePB* pButtons = pCmd->m_Pb.base->buttons_pb;
    const int         nState   = pWeapon->GameplayAnimState( );
    if ( nState == ANIM_RELOAD ) {
        if ( pWeapon->ReloadHeldSinceStart( ) ) {
            pButtons->buttonstate1 |= IN_RELOAD;
        }
        return;
    }
    if ( nState != ANIM_RELOAD_SILENT || m_nPresses >= 8) {
        return;
    }
    const float flWait = static_cast< float >( pWeapon->NextPrimaryAttackTick( ) - ( pCmd->m_nTick - 1 ) ) + pWeapon->NextPrimaryAttackTickRatio( );
    if ( flWait <= 0.0f ) {
        return;
    }
    pButtons->buttonstate1 |= IN_RELOAD;
    pButtons->buttonstate2 |= IN_RELOAD;
    ++m_nPresses;
}
cs2 reload canceling meta