Fix SmoothDamp missed type casting for Vector2

This commit is contained in:
Andrej Stojkovikj
2023-09-19 15:48:16 +02:00
committed by GitHub
parent 4e44002259
commit e1f528ec9a

View File

@@ -1001,7 +1001,7 @@ namespace FlaxEngine
float maxChangeSpeed = maxSpeed * smoothTime;
float changeSq = maxChangeSpeed * maxChangeSpeed;
float sqrDist = change_x * change_x + change_y * change_y;
Real sqrDist = change_x * change_x + change_y * change_y;
if (sqrDist > changeSq)
{
var dist = (Real)Math.Sqrt(sqrDist);