3 ms·
If you mean the networking architecture, that seems indeed like an oversimplification. AFAIK lockstep synchronization isn't a good networking strategy, and most
by jstimpfle 4y ago
If you mean the networking architecture, that seems indeed like an oversimplification. AFAIK lockstep synchronization isn't a good networking strategy, and most games netcode will do have some prediction and rollback components.
- taneq 4y agoYou're conflating game logic with engine logic here - whatever hijinks the engine pulls to make things seem seamless (prediction / replay etc.) is (or at least SHOULD be) orthogonal to the game logic. In game logic terms all games are turn based because there are no infinitely fast computers. The turns just happen at your game's tick rate which might be pretty quick.
- DarylZero 4y agoEven with an infinitely fast client computer, the server shouldn't accept infinite ticks from one player before processing ticks from another.
- squeaky-clean 4y agoIf one player is lagging, this would lag every other player. It also allows an easy "freeze the world" hack if the malicious player blocks their network connection for the game.
- jstimpfle 4y agoWhere did I make a distinction between engines and game logic? How can you say I conflated anything? Anyway. I only have unfinished attempts at low-latency netcode and rollback, so can't say I'm speaking from solid experience. But I would doubt that engines implement rollback netcode for you. Essentially the game needs to be structured in a way to accomodate storage of game state as snapshots. And it needs to decide how to incorporate messages that arrive late.
- jayd16 4y agoAgain you're conflating netcode with game rules. The players don't know of any rollbacks. That's not part of the game, just the implementation of the client. The comment was that (surprisingly) all games are single threaded and feel very turn based. Even real-time games.
- jstimpfle 4y agoThis was not about players. It's about the implementation. I also don't know what you mean by "games are single threaded and feel very turn based". Games are usually not single threaded (insofar as most games run on multiple OS threads). If you want to say they feel single threaded, then it might be because the screen emits one frame after another, and you can influence the next frame by your action? But I don't know how that is an interesting insight and it doesn't seem to have anything to do with how games stay in sync. You might have something interesting to say, but I wasn't able to learn anything from your post. Add to that the slightly accusing tone of it ("again conflating") I can't help but be annoyed.
- jayd16 4y agoMost game logic is indeed single threaded and most multiplayer games are single thread authoritative. Because the logic is single threaded it can feel turn based because it has to handle things in a time sliced way.
- jstimpfle 4y agoThe game logic doesn't have to be single threaded but it should be deterministic I guess. But anyway, this is like the most basic insight and doesn't touch what I said at all. It does not explain how games stay in sync, unless you go back to shitty 90's lockstep netcode. As I said in my first comment.
- squeaky-clean 4y ago> The turns just happen at your game's tick rate which might be pretty quick. Except because of latency, it's like taking turns when you may be ahead of other players in turns or behind other players and the game does rollbacks to make the turns make sense once they've all arrived and how many turns ahead/behind you are is also dynamic. It ends up having a very real affect on the actual game mechanics. In CS:GO a player peaking out from an obstacle has the advantage over the player waiting for them to pop out. https://on-winning.com/csgo-beginners-guide-peeking/ https://on-winning.com/csgo-beginners-guide-peeking/