- Fixed: When I converted the P_Thing_Projectile() code for target leading

to use the new vector routines, I had made dist calculate the squared
  length of the aim vector instead of the correct length.


SVN r494 (trunk)
This commit is contained in:
Randy Heit 2007-02-28 17:38:56 +00:00
parent 1ca9b88b11
commit eef025dd4e
2 changed files with 4 additions and 1 deletions

View file

@ -1,4 +1,7 @@
February 28, 2007
- Fixed: When I converted the P_Thing_Projectile() code for target leading
to use the new vector routines, I had made dist calculate the squared
length of the aim vector instead of the correct length.
- Fixed: When starting a new game from the menu while the fullscreen console
was open, the game was frozen before its initial setup tick until the
console was closed. The most obvious result of this is that your view was

View file

@ -281,7 +281,7 @@ bool P_Thing_Projectile (int tid, AActor *source, int type, const char * type_na
goto nolead;
}
}
double dist = aim | aim;
double dist = aim.Length();
double targspeed = tvel.Length();
double ydotx = -aim | tvel;
double a = acos (clamp (ydotx / targspeed / dist, -1.0, 1.0));