Modifications to network packets?

Talk about multiplayer ZDoom games here.
Forum rules
Image
Post Reply
User avatar
LanHikariDS
Posts: 179
Joined: Tue Aug 04, 2015 11:30 pm
Location: Playing in the snow

Modifications to network packets?

Post by LanHikariDS »

Through some experimentation, I've learned that ZDoom typically uses a minimalistic approach to multiplayer packets, essentially just streaming live Demo files for the other player's movement, which is susceptible to desyncs in certain environments. For vanilla Doom, and possibly ZDoom in it's early days, I could understand this being used, as it's great for low-speed internet connections that were common around that time, and worked for the primitive engine. Is there any way to have ZDoom sync up players' X/Y coordinates every few tics, instead of streaming their button inputs, to iron out some of these desyncs? If not, are there any other source ports that use this method? I have a neat Cooperative map idea that desyncs commonly with the 'Demo Streaming' method.
User avatar
edward850
Posts: 5886
Joined: Tue Jul 19, 2005 9:06 pm
Location: New Zealand
Contact:

Re: Modifications to network packets?

Post by edward850 »

LanHikariDS wrote:Through some experimentation, I've learned that ZDoom typically uses a minimalistic approach to multiplayer packets,
Or you could have checked the Doom wiki or just asked. That was a waste of time, wasn't it?
LanHikariDS wrote:essentially just streaming live Demo files for the other player's movement, which is susceptible to desyncs in certain environments.
Not exactly. They are only susceptible in an environment that isn't designed for the data, just like demos (also calling it streamed demos is somewhat off point but whatever). As long as you design the environment to be deterministic, which Doom is, then everything is good to go. So incidentally this means you can play the most seemingly random mod for hours on end with absolutely no issues, as the data is already informationally correct.
LanHikariDS wrote:For vanilla Doom, and possibly ZDoom in it's early days, I could understand this being used, as it's great for low-speed internet connections that were common around that time, and worked for the primitive engine.
For ZDoom nowadays it's still needed, as object state changes can range at an easy 100 bytes-per-object. Incidentally, the cost of customization means you need to store and transfer the data somehow, and ZDoom outgrew any possibility of that changing.
LanHikariDS wrote:Is there any way to have ZDoom sync up players' X/Y coordinates every few tics, instead of streaming their button inputs, to iron out some of these desyncs? If not, are there any other source ports that use this method? I have a neat Cooperative map idea that desyncs commonly with the 'Demo Streaming' method.
Then you're simply not making a Doom compliant map. No, you can't resync the player positions because the data is most certainly not only reliant on that, however your bigger issue is that's not simply how Doom is designed to start with. Breaking things deliberately just leaves you with a broken thing. Design smarter, not faster.
User avatar
LanHikariDS
Posts: 179
Joined: Tue Aug 04, 2015 11:30 pm
Location: Playing in the snow

Re: Modifications to network packets?

Post by LanHikariDS »

edward850 wrote: Or you could have checked the Doom wiki or just asked. That was a waste of time, wasn't it?
But where's the fun in that? Besides, I wasn't explicitly trying to find out how it's netcode works, I just did while testing a concept map I made.
edward850 wrote: They are only susceptible in an environment that isn't designed for the data, just like demos (also calling it streamed demos is somewhat off point but whatever). As long as you design the environment to be deterministic, which Doom is, then everything is good to go. So incidentally this means you can play the most seemingly random mod for hours on end with absolutely no issues, as the data is already informationally correct.
By 'Environment', I meant 'Situation', my mistake.
As for calling it a streamed demo, it may not be EXACT, but it really sums up what even the Wiki says
edward850 wrote: For ZDoom nowadays it's still needed
Not exactly. Networking in gaming has evolved, and just simply relaying keyboard inputs isn't the way it has to be done anymore. Games can transmit more to other peers than was possible in 1993. Back then, it made more sense to have as little sent over the network, as the internet was still in it's infancy. Now, we could use a more modern model, where what one player transmits can be more than, "I moved in this path", for the other player's game to say "So, you picked up this and this."
edward850 wrote: Then you're simply not making a Doom compliant map.
Probably not, but that won't stop me from trying.
User avatar
edward850
Posts: 5886
Joined: Tue Jul 19, 2005 9:06 pm
Location: New Zealand
Contact:

Re: Modifications to network packets?

Post by edward850 »

LanHikariDS wrote:Not exactly. Networking in gaming has evolved, and just simply relaying keyboard inputs isn't the way it has to be done anymore. Games can transmit more to other peers than was possible in 1993. Back then, it made more sense to have as little sent over the network, as the internet was still in it's infancy. Now, we could use a more modern model, where what one player transmits can be more than, "I moved in this path", for the other player's game to say "So, you picked up this and this."
You kind of need to read why I said that instead of just pulling something out of nothing that completely missed the point. Yes of course I know a different engine can do things differently. It's kind of my job to know that. Please re-read:
For ZDoom nowadays it's still needed, as object state changes can range at an easy 100 bytes-per-object. Incidentally, the cost of customization means you need to store and transfer the data somehow, and ZDoom outgrew any possibility of that changing.
Specifically, it's 100 on average. It can be 600 at most for actors alone. and that' needs to be of every actor on the map as all are active at once. And with ZDoom's unique list-of-lists-of-lists object storage situation (inventory is just one gigantic object chain), it's almost impossible to track what needs to be contained in what without constant reserialization. Tic-selective rendering interpolation also introduces its own unique challenges for object deltas.
User avatar
LanHikariDS
Posts: 179
Joined: Tue Aug 04, 2015 11:30 pm
Location: Playing in the snow

Re: Modifications to network packets?

Post by LanHikariDS »

Okay, fine *Doesn't care enough to argue*
User avatar
NeuralStunner
 
 
Posts: 12325
Joined: Tue Jul 21, 2009 12:04 pm
Preferred Pronouns: He/Him
Graphics Processor: nVidia with Vulkan support
Location: capital N, capital S, no space
Contact:

Re: Modifications to network packets?

Post by NeuralStunner »

Then this thread is really pointless, isn't it? :?
User avatar
wildweasel
Posts: 21706
Joined: Tue Jul 15, 2003 7:33 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): A lot of them
Graphics Processor: Not Listed
Contact:

Re: Modifications to network packets?

Post by wildweasel »

NeuralStunner wrote:Then this thread is really pointless, isn't it? :?
About as much as this post.
Post Reply

Return to “Networking”