It returns the new position, velocity of a spring at the given current position, velocity after the given dt has passed. The current position is the first argument and the current velocity is the third argument.
local p = 0;
local v = 0;
local DURATION = 4;
local DT = 1/60;
for i = 1, (DURATION/DT) do
p, v = game.TweenService:SmoothDamp(p, 4, v, 1, math.huge, DT);
print(p, v);
end
The default values for maxSpeed and dt are also missing.
It looks to me that the return value is a tuple of only two values: the new position, and the new velocity calculated from the operation.
It also appears that while the default value for maxSpeed is indeed math.huge like in your script, the default value for dt is the framerate for the context which TweenService:SmoothDamp is running in, giving variable values between the server and client.
I don’t have permission to change set default variables, so I’ll include that in a comment alongside a link to your post here for credit.
Also, in the future feel free to make any necessary changes to the documentation as it’s open sourced. I’m sure Ignis and the other devs would love for as many people as possible to contribute.