• Smoothly interpolate a number from x toward y in a spring-like manner using the dt to maintain frame rate independent movement.

    Parameters

    • x: number

      Current point.

    • y: number

      Target point.

    • lambda: number

      A higher lambda value will make the movement more sudden, and a lower value will make the movement more gradual.

    • dt: number

      Delta time in seconds.

    Returns number