quantum-space-buddies/QSB/Animation/Player/AnimFloatParam.cs
Mister_Nebula 3523f3b806 AAA
2021-04-26 14:30:21 +01:00

18 lines
344 B
C#

using UnityEngine;
namespace QSB.Animation.Player
{
public class AnimFloatParam
{
public float Current { get; private set; }
public float Target { get; set; }
private float _velocity;
public float Smooth(float smoothTime)
{
Current = Mathf.SmoothDamp(Current, Target, ref _velocity, smoothTime);
return Current;
}
}
}