Fix camera position being able to become NaN with classic controls
To reproduce, hold A for about a second, then release A and press D in the same frame.
This commit is contained in:
@@ -126,7 +126,7 @@ public class ClassicCameraController implements CameraController {
|
||||
|
||||
lastCall = Sys.getTime();
|
||||
|
||||
if(direction == null || motion < THRESHOLD) {
|
||||
if(direction == null || direction.lengthSquared() == 0 || motion < THRESHOLD) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user