From 1907d6ecff7663db0110317eab3edda8658fc89a Mon Sep 17 00:00:00 2001 From: Lee Salzman Date: Sun, 19 Aug 2007 07:43:15 +0000 Subject: [PATCH] *** empty log message *** git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@1262 e016b1c5-ed68-44aa-a2f7-31cac88cffde --- source/src/weapon.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) 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);