Fixed instant disconnect due to UDP flood, extremely jumpy interpolation

This commit is contained in:
Anuken
2018-05-05 12:48:50 -04:00
parent 1f439b4b0c
commit fab22a152c
6 changed files with 18 additions and 16 deletions

View File

@@ -122,6 +122,8 @@ public abstract class SyncEntity extends DestructibleEntity{
time += 1f / spacing * Math.min(Timers.delta(), 1f);
time = Mathf.clamp(time, 0, 2f);
Mathf.lerp2(pos.set(last), target, time);
angle = Mathf.slerpDelta(angle, targetrot, 0.6f);