Jump to content

  • Log In with Google      Sign In   
  • Create Account


Networking Book


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
5 replies to this topic

#1 Heg   Members   -  Reputation: 173

Like
0Likes
Like

Posted 16 August 2012 - 12:26 AM

Hey guys,

I programmed a Bomberman Clone that is playable over a network. This currently works well enough in a LAN, but not online. I have read a lot of topics about networking and would like to read even more in form of a book. I am currently owning 'Best of Game Programming Gems' and that book has a section about networking as well. Unfortunetly the book covers only real-time strategy games. My game is a little bit different from that.

Is there a good read for reducing latency effects in action games, possibly FPS or something like that? Maybe the 'Game Programming Gems' series covers the topic in another book as well.

Thanks in advance

Sponsor:

#2 savail   Members   -  Reputation: 324

Like
1Likes
Like

Posted 16 August 2012 - 11:45 AM

http://gafferongames.com/networking-for-game-programmers/ - here's a good tutorial on programming network for action, fps etc games using UDP. It's written by a real pro but I find it a bit hard to fully understand it. You need advanced c++ knowledge and some experience with winsock imho.

#3 Heg   Members   -  Reputation: 173

Like
0Likes
Like

Posted 17 August 2012 - 12:49 AM

Thanks mate, I will have a look into that. I hope I am able to understand it ;)

If someone else still knows a good book, I would appreciate it. I like reading different sources :)

#4 Heg   Members   -  Reputation: 173

Like
0Likes
Like

Posted 17 August 2012 - 03:14 AM

I read a little bit of the tutorial already and it is pretty good. It gives good intel on how to build my network architecture with UDP.

Unfortunately the tutorial stops at client-side prediction. I have a pretty good idea what client-side prediciton is about and I think I will be able to implement that into my game with help of the tutorial. However the part about latency compensation is missing, and so does it in other tutorials that I found so far :(

Does somebody know a good ressource for latency compensation?

#5 0BZEN   Crossbones+   -  Reputation: 2002

Like
1Likes
Like

Posted 19 August 2012 - 04:54 PM

That's the latency compensation used for CS:S, and probably a lot of other games. It's not explained in great details, but the idea is relatively simple.

Another thing you will want to read about is entity interpolation and replication. Which is also very briefly covered there.

My recommended 10'ish super-action-network-game components :
- Matchmaking (advertising, listing sessions, player ranking and matching, join queues, parties, arbitration, public / private key security and encryption, player presence, invites...).
- Connection layer (managing / accepting / keep-alive / closing client connections, routing communications, NAT punch-through, maybe even forwading strategies if you are thinking of a peer-to-peer star topology).
- Communication protocol (UDP socket, what your packets are made of).
- Messaging / RPC (a way to send / broadcast / parse / handle messages / commands / requests, in-order, reliably, efficiently).
- Serialisation / deserialisation (a way to write basic atomic data / aggregated objects into bitstreams / bytestreams).
- Entity state replication (how the server informs clients about object creation, updates, destructions in the world).
- Time keeping (to have a relatively accurate way to synchronise and keep in sync game clocks between all the machines).
- Client prediction (to mask round-trip latency of local player updates on the client, while preserving authoritative server control).
- Lag compensation (to level the playing field, and reduce the need for clients to 'lead' targets).
- Flow control (How to avoid choking your bandwidth, avoid traffic spikes, prioritise entity updates, message queues, monitor bandwidth usage, ect...).

A lot of that stuff is readily available, Gaffer's got a few of these covered in a simple way. Sometimes can get complicated very quickly though, especially if you move on to p2p gaming.

Edited by papalazaru, 19 August 2012 - 05:18 PM.

Everything is better with Metal.


#6 Heg   Members   -  Reputation: 173

Like
0Likes
Like

Posted 22 August 2012 - 07:05 AM

Thanks for the post papalazaru, really helpful.

I´ll start with the networking part in the beginning of september, since I don´t have time for it at the moment. I will make sure to ask you guys again, if I should need additional help :-P

Edited by Heg, 22 August 2012 - 07:06 AM.





Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS