From c7fe134222c45575391ebac095d153c4e2bbbbc7 Mon Sep 17 00:00:00 2001 From: Andrey Akhmichin Date: Sun, 1 Dec 2019 14:44:19 +0500 Subject: [PATCH] Double promotion fixes. --- dlls/effects.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/dlls/effects.cpp b/dlls/effects.cpp index fc61cf7e..171d4ed4 100644 --- a/dlls/effects.cpp +++ b/dlls/effects.cpp @@ -2367,13 +2367,13 @@ void CWarpBall::WarpBallUse( CBaseEntity *pActivator, CBaseEntity *pCaller, USE_ m_flMaxFrame = (float)MODEL_FRAMES( pev->modelindex ) - 1; pev->rendercolor = Vector( r, g, b ); - pev->scale = 1.2; + pev->scale = 1.2f; pev->frame = 0; if( m_pSprite ) { m_pSprite->SetTransparency( kRenderGlow, r, g, b, 255, kRenderFxNoDissipation ); - m_pSprite->pev->scale = 1.0; + m_pSprite->pev->scale = 1.0f; m_pSprite->TurnOn(); } @@ -2384,7 +2384,7 @@ void CWarpBall::WarpBallUse( CBaseEntity *pActivator, CBaseEntity *pCaller, USE_ if( m_pBeams ) { UTIL_SetOrigin( m_pBeams->pev, pev->origin ); - m_pBeams->m_restrike = -0.5; + m_pBeams->m_restrike = -0.5f; m_pBeams->SetColor( 0, 255, 0 ); m_pBeams->m_noiseAmplitude = 65; m_pBeams->m_life = 0.5; @@ -2400,11 +2400,11 @@ void CWarpBall::WarpBallUse( CBaseEntity *pActivator, CBaseEntity *pCaller, USE_ m_pBeams->Spawn(); m_pBeams->pev->solid = SOLID_NOT; m_pBeams->SetThink( &CLightning::StrikeThink ); - m_pBeams->pev->nextthink = gpGlobals->time + 0.1; + m_pBeams->pev->nextthink = gpGlobals->time + 0.1f; } SetThink( &CWarpBall::BallThink ); - pev->nextthink = gpGlobals->time + 0.1; + pev->nextthink = gpGlobals->time + 0.1f; m_flLastTime = gpGlobals->time; // m_fBeamsCleared = FALSE; @@ -2412,7 +2412,7 @@ void CWarpBall::WarpBallUse( CBaseEntity *pActivator, CBaseEntity *pCaller, USE_ if( !m_flDamageDelay ) { - RadiusDamage( pev->origin, pev, pev, 300.0, 48.0, CLASS_NONE, DMG_SHOCK ); + RadiusDamage( pev->origin, pev, pev, 300.0f, 48.0f, CLASS_NONE, DMG_SHOCK ); m_fDamageApplied = TRUE; } else @@ -2420,8 +2420,8 @@ void CWarpBall::WarpBallUse( CBaseEntity *pActivator, CBaseEntity *pCaller, USE_ m_fDamageApplied = FALSE; } - SUB_UseTargets( this, USE_TOGGLE, 0.0 ); - UTIL_ScreenShake( pev->origin, 4.0, 100.0, 2.0, 1000.0 ); + SUB_UseTargets( this, USE_TOGGLE, 0.0f ); + UTIL_ScreenShake( pev->origin, 4.0f, 100.0f, 2.0f, 1000.0f ); m_flWarpStart = gpGlobals->time; EMIT_SOUND_DYN( ENT( pev ), CHAN_WEAPON, "debris/alien_teleport.wav", 1.0, ATTN_NORM, 0, PITCH_NORM ); } @@ -2455,14 +2455,14 @@ void CWarpBall::BallThink( void ) if( m_pBeams ) { - if( pev->frame >= m_flMaxFrame - 4.0 ) + if( pev->frame >= m_flMaxFrame - 4.0f ) { m_pBeams->SetThink( NULL ); m_pBeams->pev->nextthink = gpGlobals->time; } } - pev->nextthink = gpGlobals->time + 0.1; + pev->nextthink = gpGlobals->time + 0.1f; m_flLastTime = gpGlobals->time; } }