Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

For a round clock timer, how should I code this on client or the server?

For it to be the safest and most efficient without down the game, should I code it all on the server then update everyone's clock(Player Gui) individually from the server via a for loop?

Or should the server have a uniform clock value that's constantly changing, and the client updates it's own gui every second by communicating with the server?

2 comments

3

have an int value in replicated storage, change it on the server and get it on the client

0

The king, wouldn't that be bad because leaving the int value in replicated storage could leave it open for hackers?

1 answer

✓ Accepted answer

There is nothing "unsafe" for a clock timer. There is no point of having the server update the time for all the clients, this would just make the game impress less due to inconsistent changing of the time.

You can simply just have the server send the countdown number to the client and make the client do a for loop from the given number to 0. Then once x seconds has passed, get the server to update the clients again with new information.

(Don't make the server do unnecessary stuff is what I tell myself.)

This discussion is preserved as it was. New answers, comments, and votes are closed.