What is the 2nd parameter of wait?

& how can I get it without calling wait()?

print(select(2,wait()))
print(os.time())
print(tick())
print(workspace.DistributedGameTime)

they are all different

I think it’s the time since the Roblox instance has been running(?), even from the start of opening studio but idk
I can’t seem to find the documentation : /

some feature request relating to this No documentation on wait(x)'s result - #5 by Ozzypig

It matches this in studio: elapsedtime(). It should match it in a client/server as well. In addition, outside of studio, I think time() and elapsedTime() are the same. I’ll leave the testing to you :slight_smile:

2 Likes

no testing from me, just going to trust you <3

edit:
if game isn’t running (just in studio), time() returns 0, elapsed time still returns a value

edit2: i see you said outside of studio

xd

1 Like

Trusting me is very dangerous in my opinion xD

I did some testing:
elapsedtime() is always the same as select(2, wait()) in studio, on servers, and on clients.
time() is always the same as select(2, wait()) on servers, but not in studio since it is 0 and not on clients since it begins counting when the local data model starts instead of when the server data model starts

edit: oops, time isn’t the same as elapsedtime in studio, as we both mentioned above. Didn’t I say something about trusting me?

1 Like

its okay because we both knew
plus, you caught it yourself
I did almost miss the edit though XD