C# and Unity

More sophisticated networking when using Unity

Unity uses RakNet version 3.731, which should also be network compatible with 3.732. In order to use RakNet with Unity, you do not have to download RakNet or sign a license agreement, as Unity ships RakNet integrated into the binary code already.

If you want more sophisticated networking, such as being able to run your own server, more efficient network communication for an MMO, or to otherwise modify or extend the networking of Unity you can use RakNet version 4.x, which has C# support. Unity allows you to write game code in C#, therefore you would be able to use write your own network code using RakNet directly and have full access to its feature set.

Unity users do not have access RakNet 4.x. So it is necessary to contact us for a license when planning to make this upgrade.

Version 4 improvements over RakNet bundled with Unity

- Support for C# via SWIG
- Support for XBOX / PS3 / Windows Phone 8 / Windows Store 8
- Faster autopatcher
- NAT punchthrough now more likely to work, and we host it for you
- Hosted master server http://masterserver2.raknet.com/
- IPV6 support
- Better congestion control
- Better HTTP support
- TeamManager class, to automatically manage players across teams
- StatisticsHistory class
- HTTP Based lobby3 system, supporting leaderboards, achievements, friends, clans, etc.

See Also

Index SWIG Tutorial