I'm looking for any network layers that are available to add to my game, either free or with fair pricing for indie games.

By network layers I mean some sort of library which I can interface with, that I will be able to send messages to and receive messages from, and it will handle all the low-level information by itself.

I'm especially looking for:

  • High quality libraries that understand and deal with complex things such as network congestion.
  • Scalable libraries, that will allow me to have a lot of players playing together.
  • Preferably a peer-to-peer solution, and not a server based one.
  • Preferably a library that has binding for high-level languages (such as Java or C#).

An example of what I'm looking for is Grapple, but I know there are other libraries available.

  • \$\begingroup\$ Although a very helpful topic, this question is probably not suited to the stackexchange format, as it's really asking for a feature comparison of various libraries and thus an open-ended discussion. \$\endgroup\$ – Cameron Fredman Feb 16 '13 at 23:17

I feel the need to add ENet to this list. Granted, it does not come with bindings to other languages, but given that it's written in C, creating bindings for it is trivial.

I've found ENet to be robust, well-written, and scalable, and handles peer-to-peer gaming very well.


We were using RakNet for a while and enjoyed it, and got positive review from other studios using it. http://www.jenkinssoftware.com/

The nice thing about RakNet is that it's cross platform for the most part, so if you're looking to enter the console space, it's a good possibility.

  • \$\begingroup\$ I like how it's free for indy games \$\endgroup\$ – Oak Jul 16 '10 at 6:44
  • \$\begingroup\$ I've also used RakNet, and it's pretty nice. It's not perfect, but the samples are good, you have full access to the source, and the Indie license is very forgiving. \$\endgroup\$ – Logan Kincaid Jul 17 '10 at 3:07

I chose Zoidcom (C++) because it is well-designed and has excellent documentation + examples:

The Zoidcom network library is a high-level, UDP based networking library providing features for automatic replication of gameobjects and synchronization of their states over a network connection in a highly bandwidth efficient manner. This is achieved by multiplexing and demultiplexing object information from and into bitstreams, which make it easily possible to avoid sending redundant data. Bools only take one single bit, integers and floats are stripped down to as many bits as needed.

A great deal of the tedious work that appears when attempting to develop an efficient network protocol is handled by Zoidcom, e.g. deciding when to send which data to which client, how to get it efficiently and reliably through the line, what to do when data gets lost and a lot more.

Some open source games made using Zoidcom:


Zoidcom is freely available for noncommercial use and will stay so. Commercial and shareware licenses are available on request, official licence announcement will be made available with release 1.0.


If C# isn't a problem, you could check out Lidgren. Currently in it's 3rd generation, it features (among other things):

  • MIT License
  • Peer-to-Peer (NetClient/NetServer are based on NetPeer)
  • Lag simulation
  • Packet encryption
  • Very efficient (buffers reused for zero garbage)
  • Active and responsive developer!

Since you mentioned Java I'd suggest to look into JGN (http://forum.captiveimagination.com/index.php/board,4.0.html), I've never really used it personally but I've heard good things about it on the JME forum. Documentation seems to be scarce though.


Not the answer you're looking for? Browse other questions tagged or ask your own question.