Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Is there a way to make a constant lerp() distance moved? [Solved]

Asked by
zor_os 70
5 years ago
Edited 5 years ago

So i'm making a part move by using lerp() but the problem is that it's a % of the distance so the smaller the distance the slower the speed. So is there a way to make a constant distance or to change the movement interval based on how far the distance is? Sorry i'm in the process of learning lerp() but there isn't much information I can find about it.

Thanks to vulkarin for helping me

0
is looking into magnitude the right direction or is there a better way? zor_os 70 — 5y
1
Maybe what you could do is detect magnitude first to see how far the parts are and then change the % based on the magnitude Vulkarin 581 — 5y
0
Ok thanks it works just had to find the longest path length and divide it by the current path length(HighestMag / Current Mag)*0.01/speed zor_os 70 — 5y
0
Very nice Vulkarin 581 — 5y

Answer this question