16 Aug 2012

This commit is contained in:
g-cont 2012-08-16 00:00:00 +04:00 committed by Alibek Omarov
parent a7ce431ab6
commit 0fa935ff5d
8 changed files with 15 additions and 14 deletions

View File

@ -527,6 +527,7 @@ void CCrossbow::WeaponIdle( void )
SendWeaponAnim( CROSSBOW_FIDGET2 );
m_flTimeWeaponIdle = UTIL_WeaponTimeBase() + 80.0 / 30.0;
}
m_flTimeWeaponIdle = UTIL_WeaponTimeBase() + UTIL_SharedRandomFloat( m_pPlayer->random_seed, 10, 15 );
}
}
}

View File

@ -494,7 +494,7 @@ void CEgon::WeaponIdle( void )
{
ResetEmptySound( );
if ( m_flTimeWeaponIdle > gpGlobals->time )
if ( m_flTimeWeaponIdle > UTIL_WeaponTimeBase())
return;
if ( m_fireState != FIRE_OFF )

View File

@ -583,8 +583,6 @@ void CGauss::WeaponIdle( void )
iAnim = GAUSS_FIDGET;
m_flTimeWeaponIdle = UTIL_WeaponTimeBase() + 3;
}
return;
SendWeaponAnim( iAnim );
}

View File

@ -233,7 +233,7 @@ void CGlock::Reload( void )
if (m_iClip == 0)
iResult = DefaultReload( 17, GLOCK_RELOAD, 1.5 );
else
iResult = DefaultReload( 18, GLOCK_RELOAD_NOT_EMPTY, 1.5 );
iResult = DefaultReload( 17, GLOCK_RELOAD_NOT_EMPTY, 1.5 );
if (iResult)
{
@ -249,7 +249,7 @@ void CGlock::WeaponIdle( void )
m_pPlayer->GetAutoaimVector( AUTOAIM_10DEGREES );
if (m_flTimeWeaponIdle > gpGlobals->time)
if (m_flTimeWeaponIdle > UTIL_WeaponTimeBase())
return;
// only idle if the slid isn't back

View File

@ -126,7 +126,7 @@ void CPython::Holster( int skiplocal /* = 0 */ )
}
m_pPlayer->m_flNextAttack = UTIL_WeaponTimeBase() + 1.0;
m_flTimeWeaponIdle = UTIL_SharedRandomFloat( m_pPlayer->random_seed, 10, 15 );
m_flTimeWeaponIdle = UTIL_WeaponTimeBase() + UTIL_SharedRandomFloat( m_pPlayer->random_seed, 10, 15 );
SendWeaponAnim( PYTHON_HOLSTER );
}
@ -152,7 +152,7 @@ void CPython::SecondaryAttack( void )
m_pPlayer->pev->fov = m_pPlayer->m_iFOV = 40;
}
m_flNextSecondaryAttack = 0.5;
m_flNextSecondaryAttack = UTIL_WeaponTimeBase() + 0.5;
}
void CPython::PrimaryAttack()
@ -211,7 +211,7 @@ void CPython::PrimaryAttack()
m_pPlayer->SetSuitUpdate("!HEV_AMO0", FALSE, 0);
m_flNextPrimaryAttack = 0.75;
m_flTimeWeaponIdle = UTIL_SharedRandomFloat( m_pPlayer->random_seed, 10, 15 );
m_flTimeWeaponIdle = UTIL_WeaponTimeBase() + UTIL_SharedRandomFloat( m_pPlayer->random_seed, 10, 15 );
}
@ -257,26 +257,26 @@ void CPython::WeaponIdle( void )
return;
int iAnim;
float flRand = UTIL_SharedRandomFloat( m_pPlayer->random_seed, 10, 15 );
float flRand = UTIL_SharedRandomFloat( m_pPlayer->random_seed, 0.0f, 1.0f );
if (flRand <= 0.5)
{
iAnim = PYTHON_IDLE1;
m_flTimeWeaponIdle = (70.0/30.0);
m_flTimeWeaponIdle = UTIL_WeaponTimeBase() + (70.0/30.0);
}
else if (flRand <= 0.7)
{
iAnim = PYTHON_IDLE2;
m_flTimeWeaponIdle = (60.0/30.0);
m_flTimeWeaponIdle = UTIL_WeaponTimeBase() + (60.0/30.0);
}
else if (flRand <= 0.9)
{
iAnim = PYTHON_IDLE3;
m_flTimeWeaponIdle = (88.0/30.0);
m_flTimeWeaponIdle = UTIL_WeaponTimeBase() + (88.0/30.0);
}
else
{
iAnim = PYTHON_FIDGET;
m_flTimeWeaponIdle = (170.0/30.0);
m_flTimeWeaponIdle = UTIL_WeaponTimeBase() + (170.0/30.0);
}
int bUseScope = FALSE;

View File

@ -485,6 +485,7 @@ void CRpg::PrimaryAttack()
else
{
PlayEmptySound( );
m_flNextPrimaryAttack = UTIL_WeaponTimeBase() + 0.2;
}
UpdateSpot( );
}

View File

@ -31,7 +31,7 @@ extern byte *r_temppool;
#define MAX_TEXTURES 4096
#define MAX_DETAIL_TEXTURES 256
#define MAX_LIGHTMAPS 128
#define MAX_LIGHTMAPS 256
#define SUBDIVIDE_SIZE 64
#define MAX_MIRRORS 32 // per one frame!

View File

@ -1301,6 +1301,7 @@ void R_StudioSetupChrome( float *pchrome, int bone, vec3_t normal )
VectorNormalize( chromeupvec );
CrossProduct( tmp, chromeupvec, chromerightvec );
VectorNormalize( chromerightvec );
VectorNegate( chromeupvec, chromeupvec );
}
Matrix3x4_VectorIRotate( g_bonestransform[bone], chromeupvec, g_chromeup[bone] );