diff --git a/source/src/weapon.cpp b/source/src/weapon.cpp index 7033ce05..bdd29451 100644 --- a/source/src/weapon.cpp +++ b/source/src/weapon.cpp @@ -199,7 +199,7 @@ playerent *intersectclosest(vec &from, vec &to, playerent *at) loopv(players) { playerent *o = players[i]; - if(!o || o==at || o->state!=CS_ALIVE) continue; + if(!o || o==at || o->state!=CS_ALIVE || (o->type==ENT_PLAYER && !o->lastupdate)) continue; if(!intersect(o, from, to)) continue; float dist = at->o.dist(o->o); if(diststate!=CS_ALIVE) return; + if(o->state!=CS_ALIVE || (o!=player1 && o->type==ENT_PLAYER && !o->lastupdate)) return; vec dir; float dist = expdist(o, dir, v); if(diststate!=CS_ALIVE || !intersect(o, p.o, v)) return false; + if(o->state!=CS_ALIVE || (o!=player1 && o->type==ENT_PLAYER && !o->lastupdate) || !intersect(o, p.o, v)) return false; splash(p, v, p.o, o, qdam); vec dir; expdist(o, dir, v);