Remove unnecessary conditionals. They're always true.

This commit is contained in:
Yamagi Burmeister 2014-08-03 11:40:36 +02:00
parent 1859c42484
commit 6c854253de

View file

@ -398,15 +398,12 @@ prox_land(edict_t *ent, edict_t *other, cplane_t *plane, csurface_t *surf)
return;
}
if (plane->normal != 0)
{
VectorMA(ent->s.origin, -10.0, plane->normal, land_point);
VectorMA(ent->s.origin, -10.0, plane->normal, land_point);
if (gi.pointcontents(land_point) & (CONTENTS_SLIME | CONTENTS_LAVA))
{
Prox_Explode(ent);
return;
}
if (gi.pointcontents(land_point) & (CONTENTS_SLIME | CONTENTS_LAVA))
{
Prox_Explode(ent);
return;
}
if ((other->svflags & SVF_MONSTER) || other->client ||
@ -1258,15 +1255,12 @@ tesla_lava(edict_t *ent, edict_t *other /* unused */, cplane_t *plane, csurface_
return;
}
if (plane->normal != 0)
{
VectorMA(ent->s.origin, -20.0, plane->normal, land_point);
VectorMA(ent->s.origin, -20.0, plane->normal, land_point);
if (gi.pointcontents(land_point) & (CONTENTS_SLIME | CONTENTS_LAVA))
{
tesla_blow(ent);
return;
}
if (gi.pointcontents(land_point) & (CONTENTS_SLIME | CONTENTS_LAVA))
{
tesla_blow(ent);
return;
}
if (random() > 0.5)