diff --git a/polymer/eduke32/source/game.c b/polymer/eduke32/source/game.c index eba5fc660..5b61a34a4 100644 --- a/polymer/eduke32/source/game.c +++ b/polymer/eduke32/source/game.c @@ -8582,7 +8582,7 @@ char opendemoread(char which_demo) // 0 = mine if (kread(recfilep,&ud.reccnt,sizeof(long)) != sizeof(long)) goto corrupt; if (kread(recfilep,&ver,sizeof(char)) != sizeof(char)) goto corrupt; - if(ver != BYTEVERSION && ver != 160 && ver != 116 && ver != 117) { /* old demo playback */ + if(ver != BYTEVERSION && ver != 160 /*&& ver != 116 && ver != 117*/) { /* old demo playback */ if (ver == BYTEVERSION_JF) initprintf("Demo %s is for Regular edition.\n", d); else if (ver == BYTEVERSION_JF+1) initprintf("Demo %s is for Atomic edition.\n", d); else if (ver == BYTEVERSION_JF+2) initprintf("Demo %s is for Shareware version.\n", d); diff --git a/polymer/eduke32/source/gameexec.c b/polymer/eduke32/source/gameexec.c index 56056bbe7..9a1566580 100644 --- a/polymer/eduke32/source/gameexec.c +++ b/polymer/eduke32/source/gameexec.c @@ -5365,10 +5365,10 @@ good: if(sprite[j].picnum == lType && j != g_i) { lTemp=ldist(&sprite[g_i], &sprite[j]); - lTemp2=txdist(&sprite[g_i], &sprite[j]); - if( (lTemp < lMaxDist) && (lTemp2 < lMaxZDist) ) + if(lTemp < lMaxDist && lTemp < lDist) { - if (lTemp < lDist) + lTemp2=txdist(&sprite[g_i], &sprite[j]); + if (lTemp2 < lMaxZDist) { lFound=j; j = MAXSPRITES; @@ -5416,10 +5416,10 @@ good: if(sprite[j].picnum == lType && j != g_i) { lTemp=ldist(&sprite[g_i], &sprite[j]); - lTemp2=txdist(&sprite[g_i], &sprite[j]); - if( (lTemp < lMaxDist) && (lTemp2 < lMaxZDist) ) + if(lTemp < lMaxDist && lTemp < lDist) { - if (lTemp < lDist) + lTemp2=txdist(&sprite[g_i], &sprite[j]); + if (lTemp2 < lMaxZDist) { lFound=j; j = MAXSPRITES; @@ -5429,7 +5429,7 @@ good: } j = nextspritestat[j]; } - if(tw==CON_FINDNEARACTOR3DVAR || j == MAXSPRITES) + if(tw==CON_FINDNEARACTOR3D || j == MAXSPRITES) break; } SetGameVarID(lVarID, lFound, g_i, g_p);