Improved lerp interpolation
This commit is contained in:
@ -44,4 +44,4 @@ func _process(delta):
|
||||
if abs(distance - position.z) < 0.01:
|
||||
return
|
||||
|
||||
position.z = lerpf(position.z, distance, zoom_interpolation * delta)
|
||||
position.z = Math.dampf(position.z, distance, zoom_interpolation * delta)
|
||||
|
@ -8,7 +8,7 @@ func _process(delta):
|
||||
return
|
||||
|
||||
if interpolate:
|
||||
position = lerp(position, Global.player.position, speed * delta)
|
||||
position = Math.damp(position, Global.player.position, speed * delta)
|
||||
else:
|
||||
position = Global.player.position
|
||||
|
||||
|
Reference in New Issue
Block a user