Remove 'txdist' keyword

git-svn-id: https://svn.eduke32.com/eduke32@251 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2006-07-29 00:17:46 +00:00
parent 590ba29bf3
commit 564b220add
4 changed files with 4 additions and 22 deletions

View file

@ -384,7 +384,7 @@ char *keyw[] = {
"setplayervar", // 238 "setplayervar", // 238
"mulscale", // 239 "mulscale", // 239
"setaspect", // 240 "setaspect", // 240
"txdist", // 241 "ezshoot", // 241
"spritenoshade", // 242 "spritenoshade", // 242
"movesprite", // 243 "movesprite", // 243
"checkavailweapon", // 244 "checkavailweapon", // 244
@ -438,7 +438,6 @@ char *keyw[] = {
"findnearactorzvar", // 292 "findnearactorzvar", // 292
"findnearspritez", // 293 "findnearspritez", // 293
"findnearspritezvar", // 294 "findnearspritezvar", // 294
"ezshoot", // 295
"<null>" "<null>"
}; };
@ -3536,7 +3535,6 @@ char parsecommand(void)
case CON_GMAXAMMO: case CON_GMAXAMMO:
case CON_DIST: case CON_DIST:
case CON_LDIST: case CON_LDIST:
case CON_TXDIST:
case CON_GETANGLE: case CON_GETANGLE:
case CON_MULSCALE: case CON_MULSCALE:
case CON_SETASPECT: case CON_SETASPECT:
@ -3545,7 +3543,6 @@ char parsecommand(void)
{ {
case CON_DIST: case CON_DIST:
case CON_LDIST: case CON_LDIST:
case CON_TXDIST:
case CON_GETANGLE: case CON_GETANGLE:
transvartype(GAMEVAR_FLAG_READONLY); transvartype(GAMEVAR_FLAG_READONLY);
break; break;
@ -3563,7 +3560,6 @@ char parsecommand(void)
{ {
case CON_DIST: case CON_DIST:
case CON_LDIST: case CON_LDIST:
case CON_TXDIST:
case CON_GETANGLE: case CON_GETANGLE:
transvar(); transvar();
break; break;

View file

@ -670,7 +670,7 @@ enum keywords {
CON_SETPLAYERVAR, // 238 CON_SETPLAYERVAR, // 238
CON_MULSCALE, // 239 CON_MULSCALE, // 239
CON_SETASPECT, // 240 CON_SETASPECT, // 240
CON_TXDIST, // 241 CON_EZSHOOT, // 241
CON_SPRITENOSHADE, // 242 CON_SPRITENOSHADE, // 242
CON_MOVESPRITE, // 243 CON_MOVESPRITE, // 243
CON_CHECKAVAILWEAPON, // 244 CON_CHECKAVAILWEAPON, // 244
@ -724,6 +724,5 @@ enum keywords {
CON_FINDNEARACTORZVAR, // 292 CON_FINDNEARACTORZVAR, // 292
CON_FINDNEARSPRITEZ, // 293 CON_FINDNEARSPRITEZ, // 293
CON_FINDNEARSPRITEZVAR, // 294 CON_FINDNEARSPRITEZVAR, // 294
CON_EZSHOOT, // 295
END END
}; };

View file

@ -4388,7 +4388,6 @@ SKIPJIBS:
case CON_DIST: case CON_DIST:
case CON_LDIST: case CON_LDIST:
case CON_TXDIST:
{ {
long distvar, xvar, yvar, distx=0; long distvar, xvar, yvar, distx=0;
@ -4405,9 +4404,6 @@ SKIPJIBS:
case CON_LDIST: case CON_LDIST:
distx = ldist(&sprite[GetGameVarID(xvar, g_i, g_p)],&sprite[GetGameVarID(yvar, g_i, g_p)]); distx = ldist(&sprite[GetGameVarID(xvar, g_i, g_p)],&sprite[GetGameVarID(yvar, g_i, g_p)]);
break; break;
case CON_TXDIST:
distx = txdist(&sprite[GetGameVarID(xvar, g_i, g_p)],&sprite[GetGameVarID(yvar, g_i, g_p)]);
break;
} }
SetGameVarID(distvar, distx, g_i, g_p); SetGameVarID(distvar, distx, g_i, g_p);
@ -5582,7 +5578,7 @@ good:
lTemp=ldist(&sprite[g_i], &sprite[j]); lTemp=ldist(&sprite[g_i], &sprite[j]);
if(lTemp < lMaxDist) if(lTemp < lMaxDist)
{ {
lTemp2=klabs(sprite[g_i].z-sprite[j].z);//txdist(&sprite[g_i], &sprite[j]); lTemp2=klabs(sprite[g_i].z-sprite[j].z);
if (lTemp2 < lMaxZDist) if (lTemp2 < lMaxZDist)
{ {
lFound=j; lFound=j;
@ -5632,7 +5628,7 @@ good:
lTemp=ldist(&sprite[g_i], &sprite[j]); lTemp=ldist(&sprite[g_i], &sprite[j]);
if(lTemp < lMaxDist) if(lTemp < lMaxDist)
{ {
lTemp2=klabs(sprite[g_i].z-sprite[j].z); // txdist(&sprite[g_i], &sprite[j]); lTemp2=klabs(sprite[g_i].z-sprite[j].z);
if (lTemp2 < lMaxZDist) if (lTemp2 < lMaxZDist)
{ {
lFound=j; lFound=j;

View file

@ -210,15 +210,6 @@ long dist(spritetype *s1,spritetype *s2)
return(FindDistance3D(vx,vy,vz>>4)); return(FindDistance3D(vx,vy,vz>>4));
} }
long txdist(spritetype *s1,spritetype *s2)
{
long vx,vy,vz;
vx = s1->x - s2->x;
vy = s1->y - s2->y;
vz = s1->z - s2->z - s2->yrepeat;
return(FindDistance3D(vx,vy,vz>>4));
}
short findplayer(spritetype *s,long *d) short findplayer(spritetype *s,long *d)
{ {
short j, closest_player; short j, closest_player;