Okay, do the last commit acutally right... damage can be NULL.

This commit is contained in:
Yamagi Burmeister 2012-08-26 14:57:28 +02:00
parent 8819ad1c9a
commit 4a81e58128

View file

@ -390,7 +390,7 @@ blaster_touch(edict_t *self, edict_t *other, cplane_t *plane, csurface_t *surf)
return; return;
} }
if (!surf && (!surf->flags & SURF_SKY)) if (surf && (!surf->flags & SURF_SKY))
{ {
G_FreeEdict(self); G_FreeEdict(self);
return; return;
@ -412,12 +412,9 @@ blaster_touch(edict_t *self, edict_t *other, cplane_t *plane, csurface_t *surf)
mod = MOD_BLASTER; mod = MOD_BLASTER;
} }
if (plane)
{
T_Damage(other, self, self->owner, self->velocity, self->s.origin, T_Damage(other, self, self->owner, self->velocity, self->s.origin,
plane->normal, self->dmg, 1, DAMAGE_ENERGY, mod); plane->normal, self->dmg, 1, DAMAGE_ENERGY, mod);
} }
}
else else
{ {
gi.WriteByte(svc_temp_entity); gi.WriteByte(svc_temp_entity);