Hacker News new | ask | show | jobs
by Hamcha 982 days ago
What are you guys using for multiplayer? I tried the cold chicken and had crazy high input lag. Also in general it seems like the input systems is crazy bad in the other demos as well, panning with the mouse feels super choppy. Also why don't you load all the resources ahead of time? The Second Life-ish pop-ins and stutters really ruin the experience.

Running Vivaldi and Brave on a RTX3090 btw

3 comments

It's built on top of WebTransport, which is also quite new. But yeah, we're also seeing the input lag issue here and we're on it, will be fixed soon!

When it comes to loading resources ahead of time: this is something devs can choose per-game (i.e. show loading screen or not), but yeah you might be right that it would be better for the examples we have to show a loading screen instead.

It seems like the latency is due to all the games being coded to only enact state change upon server message (à la League of Legends aka "no netcode at all")

Since it would be up to the individual gamedev to implement their own client prediction, I don't think you can really "fix" the lag issue on a platform level unless you provide a system for automatic prediction and synchronization of arbitrary user-coded behavior, like Overwatch's StateScript framework: https://www.youtube.com/watch?v=5jP0z7Atww4

It looks like they're using WebTransport: https://developer.mozilla.org/en-US/docs/Web/API/WebTranspor...
Also getting pretty brutal input lag, sometimes up to a second between mouse move and panning.
It takes a full network RTT to the server before your mouse input actually updates the client camera.
Yeah, it's part of the problem, but that would normally only give you ~60 - 100 ms lag (at least if you're on a decent connection, close-ish to the server). But we're experiencing another bug where WebTransport doesn't get a chance to send/receive data when the framerate is < 60fps (because the thread is starved), which makes it much worse than that. We're aware of it and working on it. This is the core issue: https://github.com/w3c/webtransport/issues/543
> but that would normally only give you ~60 - 100 ms lag

60 ms is already borderline even for conscious discernment of transactional state changes.

For self locomotion feedback that is a huge value. And for proprioceptive signals like mouse input it is absolutely astronomical.

Oh yeah, absolutely agree, we're not stopping at 60 ms. Client side prediction is planned (see Philpax answer https://news.ycombinator.com/item?id=37767359 and our netcode roadmap: https://github.com/AmbientRun/Ambient/issues/671).
This is IMO a pretty good reference example for making a framework-based solution that can be reused by non-coders:

https://www.youtube.com/watch?v=5jP0z7Atww4