controller/gamecontext: ignore weird projection points rather than stopping movement altogether

This commit is contained in:
Matthias Schiffer 2018-11-05 22:41:38 +01:00
parent ae7674181e
commit f086908e08
Signed by: neocturne
GPG key ID: 16EF3F64CB201D9C

View file

@ -115,7 +115,7 @@ export class GameContext {
if (!vec2.exactEquals(dest, dest2)) {
// Ensure termination
if (vec2.squaredDistance(this.entityPos, dest2) >= vec2.squaredDistance(this.entityPos, dest))
return;
continue;
vec2.copy(dest, dest2);
rescan = true;