High Network Latency Exist On Build but not in Editor!?

after a month recently I got a build and see that I have so much network latency on client. But after some testing I started to feel like crazy.

  1. Network latency only exist on builds, and not in editor.
  2. I don’t use dedicated server.
  3. Played on LAN.

Now crazy part starting…

  1. I go back with git and re-build old versions, and I faced with latency. (in before there was no)
  2. I even tried my old builds that I saved. They also have latency now.
  3. I sent the builds to a friend, he tested LAN, and he also has the same kind of latency (I sent latest build)
  4. I tried it on my old computer (windows 10) and again, had latency.
  5. I don’t use DNS, VPN, or anything.
  6. Maybe some internet problem related with country but we tested on LAN so that would not make sense I guess?

What may cause?

One time I tried network emulation tools, and enabled lag on editor, my settings like this right now. I don’t have any config file that sets as well.

Network Debugging

I don’t have so much knowledge about network debugging, so any suggestion to debug that situation would be appreciated.

Thanks in advance for any help, advice or suggestions

How bad is it?

20ms or so could be considered normal for lan, depending on how your replicating things this could have a large volume of traffic that is trying to get through… in the case of two machines on the same lan there both going through the same router/switch so theres at least one potential bottleneck, say you have gigabit ethernet thats “only” 500mb per machine, likely not the probelm but something to consider

None of the laggy network testing features of the editor will get packed into a packaged game… theyll always run at the best they can

So the problem likely comes down to replication, is your player movement just fine but other things seem to lag?

Are there too many RPCs marked as reliable that may not be necessary?

First thing id do, to narrow it down that is, is make another project add some basic multiplayer stuff and see if that lags in any way, that would tell you its the network and not the game

2nd thing id do is make a copy of your project and see what happens when you disable loads of stuff to see if its just too much traffic type of deal

3rd thing id do is come back here and show some kinda video of you playing a segment of the game beacuse depending on how its lagging we may be able to identify alot of stuff to help out

Unreals server model is such that the server is the authority ( it has the one true copy of the world ) the clients join and create the world from their local copy of the world then get any changes from replication

Then clients may send changes to the server that can then be replicated from the server to other clients

These are just some general statments to help you out as i cant tell you anything specific at least myself without seeing more

Thanks for reply, I tried the suggestions, however lag still continues and it’s even make no sense. To be honest I feel like this is not latency issue but maybe something different, because I have 14 ping.

I noticed that my bullet projectiles are not getting created on client. (server spawn a projectile and since it moves so fast it take some time to created in client, and maybe it’s destroyed before getting created. However this was not a problem before)

Second I see on dropping items, it acts very weird.

If you have access to two machines try it that way, when your playing in two edditor windows it only focuses one of them at full fps, the others often appear slightly like a slide show… this can be somewhat overcome by finding the setting thats called something like “run each pie window as its own process”

So if you can test with your friend is probably the best way to see if its actually a problem or just unreal trying to run two games at once…

You can notice this happening sometimes outside of unreal as well, if your watching fullscreen netflix or youtube and a game that your playing sometimes the video seems to be behind a bit or skip some frames

1 Like

Bro you saved my life… It’s just as you say two different computer running solved the problem (also in steam connection). Thanks a lot!

Told ya as soon as theres a video it reveals a whole lot more :sweat_smile:

Welcome to the fourms btw, dont forget to mark as answer as well :stuck_out_tongue: its what some of us are here for