Valheim

Valheim

Lag and desync in multiplayer
I have big lags and desynchronization in Ashlands biom in multiplayer. We play with a friend. So there is only 2 players on the server. But mobs frequently teleporting, dissapearing. We play on the hardcore and most of the time you is one hit to be dead. It irritatles a lot.

So my setup is RTX 4080, 10700 cpu, and I tried both dedicated service client, game client to host the server. And all the time is the same. Sometimes we have bigger laggs sometimes smaller.

I have good fps 80-90 on 4k so I do not think is computer issue as well.

Playing in other bioms is OK, so I am confident there is the game issue. I and my friend both have 100 Mbit and 300 Mbit internet, I have no problems playing Dota 2 and have ping 15ms. Also we have the same issue on our base, because of 24000 instances I think (yep, our base is two huge castles). But what the point of building such big things if it becomes unplayeble but it is another story.
Last edited by WHAT COUNTRY BITCH YOU FROM; Jun 16, 2024 @ 8:38am
< >
Showing 1-3 of 3 comments
MaCarBre Jun 17, 2024 @ 2:03am 
Originally posted by WHAT COUNTRY ♥♥♥♥♥ YOU FROM:
The most common problems are related to buffer bloat, using mods, or playing on a PC with below minimum system specs.
- Mods can have various bugs and in general increase the demand on the amount of data that needs to be send in Valheim.
- Even when playing in multiplayer, Valheim physic calculation are done on client side. This is done to offset the load from the server to the client. This however means that the client is responsible for both performing calculations and sending the data to other players. If one client has problems, they will cause problems for everyone else also. A client is responsible for performing calculation for netObjects when they arrive first in the zone, or if they are the last one to interact with particular objects (such as boat storage).
- Perform the buffer bloat test to see if you connection is a problem; https://www.waveform.com/tools/bufferbloat
Here's an example where the buffer bloat caused network issues in Valheim, and the OP fixing it by replacing their faulty Ethernet cable extender.
Before[i.imgur.com] and
After[i.imgur.com]
If anyone in the team gets a a bad rating on this test, they will individually have to do some investigating on what's causing buffer bloat. Valheim is more sensitive to it that most other games.
- Try disabling crossplay before starting your server. This is especially important if only of the teammates are behind CGNAT (do this test: https://tomchen.github.io/symmetric-nat-test/). Nobody should use a VPN while playing either.
- Perform /ping test in the Valheim chat to see if anyone has an unstable ping. Test when everything is ok and when things are bad. Switch from WiFi to wired Ethernet connection to your router.

Ashlands is a biome is which more data is sent when playing in multiplayer, so if anything listed previously isn't in order, more issues will manifest themselves in Ashlands. You should be able to play with 3 players without problems if all 3 have a stable connection, without modifying anything. For 4-5 players and playing in Ashlands, you can try the following tweak[jamesachambers.com] that many players reported being useful for them. It's not officially supported, and goes into category of modifying the game. The tweak has to be done every time the Valheim updates. It has a potential to crash certain routers.
First I need to thank you for your answer with such details and links.

As for my gaming device is almost top hardware. My friend's is not bad as well. My internet is cable 300/50 mbit ethernet cable. Friend's 100/100 mbit ethernet cable. We are not using wi-fi playing Valheim.

I tested my connection and its
BUFFERBLOAT GRADE A.
And I have almost top hardware.

- I have only mods on inteface and thats it, may be I can try disable them, but I do not think they can somehow affect connection.

- Crossplay disabled;

- CGNAT tested: "You are behind a Normal NAT";

- ping in valheim 10ms

- as for server I tried to host dedicated server in steam, and from client, we have laggs for both.

- we are playing in 2 only, and mobs teleporting, may be something with ones connection. Because as your said we started to face problems in Ashlands. And also on our base where we have two huge castles with stone walls around.

About this tweak it the one thing left I can try.
MaCarBre Jun 20, 2024 @ 3:39pm 
Download and upload speed alone doesn't mean much in Valheim. It's all about buffer bloat. Definitely tell your friend to perform the same test. You setup is good. Other person has to test their ping also, especially you both should test it when issues are happening.

How did you setup the dedicated server?

Additional things you can try:
- both of your, lower the steam browser pings per minute in Steam settings → in game → set them from 5000 to 250.
- both of you launch valheim from valheim.exe instead from steam library
- both of you, connect to the server exclusively by using IP:port of the server
- both of you, disable IPv6 on your ethernet network adapted on windows: https://networking.grok.lsu.edu/article.aspx?articleid=17573
Last edited by MaCarBre; Jun 20, 2024 @ 3:41pm
< >
Showing 1-3 of 3 comments
Per page: 1530 50

Date Posted: Jun 16, 2024 @ 8:30am
Posts: 3