mirror of
https://github.com/mapbase-source/source-sdk-2013.git
synced 2024-12-25 14:25:32 +03:00
Merge pull request #262 from Blixibon/mapbase/feature/hl2-pistol-upwards-viewkick
weapon_pistol upwards view kick cvar
This commit is contained in:
commit
8505ab4579
@ -526,6 +526,10 @@ bool CWeaponPistol::Reload( void )
|
|||||||
return fRet;
|
return fRet;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef MAPBASE
|
||||||
|
ConVar weapon_pistol_upwards_viewkick( "weapon_pistol_upwards_viewkick", "0" );
|
||||||
|
#endif
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
// Purpose:
|
// Purpose:
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
@ -538,7 +542,11 @@ void CWeaponPistol::AddViewKick( void )
|
|||||||
|
|
||||||
QAngle viewPunch;
|
QAngle viewPunch;
|
||||||
|
|
||||||
|
#ifdef MAPBASE
|
||||||
|
viewPunch.x = weapon_pistol_upwards_viewkick.GetBool() ? random->RandomFloat( -0.5f, -0.25f ) : random->RandomFloat( 0.25f, 0.5f );
|
||||||
|
#else
|
||||||
viewPunch.x = random->RandomFloat( 0.25f, 0.5f );
|
viewPunch.x = random->RandomFloat( 0.25f, 0.5f );
|
||||||
|
#endif
|
||||||
viewPunch.y = random->RandomFloat( -.6f, .6f );
|
viewPunch.y = random->RandomFloat( -.6f, .6f );
|
||||||
viewPunch.z = 0.0f;
|
viewPunch.z = 0.0f;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user