Remote Event Delay (Server -> Client and back)

I’m making a game, but when I fire a remote event to equip a pet, I fire a remote event back to the client to signify the player’s data changed, but it’s delayed (I can’t tell if it’s the server → client or client → server that’s delayed or both).

1 Like

You could try to print the timestamps if it is noticeable. Another option would be to let the player continue on immediately and have some other indicator once the request has successfully gone through.

The problem is that since it’s in equip button like in simulator games, it is a noticeable delay.

To cover the delay, you could aesthetically equip the item locally without any game-changing modifications until the item is added from the server…

1 Like

That fixes that specific problem, but what about other things? I’m making a tapping game and when the user taps, it takes like 2 - 3 seconds for it to register. Do I register & calculate the multiplier on the client and update it there until the server registers it, or is there another way? Because some things for multipliers I can’t access on the client, I lock them behind the server.

Hackers aren’t exactly something you can stop with this type of game. To deal with autoclickers, maybe send the amount of clicks since the last second every second or something. Do everything client side, just handle the important numbers server side.

I’m not trying to stop hackers, I already can do that. I’m trying to figure out the delay as asked in my original question.

Welcome to the world of networking. Nothing is going to be instant, so it is best to get your requests out first and then later have code run based on what was sent out.

1 Like

I understand that, however I just want to know what I can do to make it look like there is no delay for taps, equip/unequipping etc. There must be a way, how do other games have it instant?

If you use 2 devices and watch someone equip a pet, it isn’t instant. You equip a temporary pet until the server gets back to you that the real one has been created so you can delete the temporary.

It’s not instant, but not a 2 - 3 second delay like how mine is. Either way, what about currency? That needs to be updated and for the most part it’s almost instant in other games. (Without leaderstats)

If you look at the leaderboards for other clicker games, they don’t instantly update. I would recommend going with the rate limited approach by just updating every user’s amount every second.