prettify modern flashlight addition to cl_tent
This commit is contained in:
parent
1501f7fea4
commit
cf09305f79
|
@ -2696,26 +2696,15 @@ void CL_AddEntityEffects( cl_entity_t *ent )
|
||||||
if( FBitSet( ent->curstate.effects, EF_BRIGHTFIELD ))
|
if( FBitSet( ent->curstate.effects, EF_BRIGHTFIELD ))
|
||||||
R_EntityParticles( ent );
|
R_EntityParticles( ent );
|
||||||
|
|
||||||
if (REF_GET_PARM( PARM_MODERNFLASHLIGHT, 1 ) == true)
|
if ( FBitSet( ent->curstate.effects, EF_DIMLIGHT ))
|
||||||
{
|
{
|
||||||
if( !ent->player )
|
if ( ent->player && !Host_IsQuakeCompatible( ))
|
||||||
{
|
{
|
||||||
if ( FBitSet( ent->curstate.effects, EF_DIMLIGHT ) )
|
if ( !REF_GET_PARM( PARM_MODERNFLASHLIGHT, 1))
|
||||||
{
|
{
|
||||||
dlight_t *dl = CL_AllocDlight( ent->index );
|
CL_UpdateFlashlight( ent );
|
||||||
dl->color.r = dl->color.g = dl->color.b = 100;
|
|
||||||
dl->radius = COM_RandomFloat( 200, 231 );
|
|
||||||
VectorCopy( ent->origin, dl->origin );
|
|
||||||
dl->die = cl.time + 0.001;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
else if ( FBitSet( ent->curstate.effects, EF_DIMLIGHT ))
|
|
||||||
{
|
|
||||||
if( ent->player && !Host_IsQuakeCompatible( ))
|
|
||||||
{
|
|
||||||
CL_UpdateFlashlight( ent );
|
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
dlight_t *dl = CL_AllocDlight( ent->index );
|
dlight_t *dl = CL_AllocDlight( ent->index );
|
||||||
|
|
Loading…
Reference in New Issue