Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Must return a value between 0 and 1
- // time: the current elapsed time since the tween started
- // duration: the total duration of the tween
- // overshootOrAmplitude: ignore this
- // period: ignore this
- public float CustomLinearEase(float time, float duration, float overshootOrAmplitude, float period)
- {
- return time / duration;
- }
- void CreateTweenWithCustomEase(Transform t)
- {
- // This will create a tween with a linear ease
- t.DOMoveX(1, 2).SetEase(CustomLinearEase);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement