Should I update this timer every 0.01 seconds or have the clients setup their own loops?

So I’m creating a timer display for my game and it seemed like it would be a bad idea to be updating every single client on the server every 0.01 seconds just to update the elapsedTime, when I can maybe just send a remote once and then have the clients setup their own and then when the one on the server is done I tell all the clients theres should end too??

function event:Timer()
	self.timer = true
	while self.timer do
		self.elapsedTime += 0.01
		local formattedTime = string.format("%.2f", self.elapsedTime)

You can just have the server tell the client when to start and the client can just count on its own. You can also add another one where the server tells the client to stop counting.

1 Like

Yeah see this is what I was thinking would be just better, thanks Im gonna do this!

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.