mirror of
https://github.com/YGGverse/xash3d-fwgs.git
synced 2025-01-17 18:40:02 +00:00
Fix crash on broken model
This commit is contained in:
parent
a297a0b5ad
commit
1e5f12a0ae
@ -104,7 +104,7 @@ void R_MarkLights( dlight_t *light, int bit, mnode_t *node )
|
|||||||
msurface_t *surf;
|
msurface_t *surf;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
if( node->contents < 0 )
|
if( !node || node->contents < 0 )
|
||||||
return;
|
return;
|
||||||
|
|
||||||
dist = PlaneDiff( light->origin, node->plane );
|
dist = PlaneDiff( light->origin, node->plane );
|
||||||
@ -487,4 +487,4 @@ colorVec R_LightPoint( const vec3_t p0 )
|
|||||||
VectorSet( p1, p0[0], p0[1], p0[2] - 2048.0f );
|
VectorSet( p1, p0[0], p0[1], p0[2] - 2048.0f );
|
||||||
|
|
||||||
return R_LightVec( p0, p1, NULL, NULL );
|
return R_LightVec( p0, p1, NULL, NULL );
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user