Expand description

RakNet Protocol implementation by Rust.

Raknet is a reliable udp transport protocol that is generally used for communication between game clients and servers, and is used by Minecraft Bedrock Edtion for underlying communication.

Raknet protocol supports various reliability options, and has better transmission performance than TCP in unstable network environments. This project is an incomplete implementation of the protocol by reverse engineering.

Requires Tokio 1.x asynchronous runtime support.

Reference : http://www.jenkinssoftware.com/raknet/manual/index.html

This project is not affiliated with Jenkins Software LLC nor RakNet.

Features

  • Async
  • MIT License
  • Pure Rust implementation
  • Fast Retransmission
  • Selective Retransmission (TCP/Full Retransmission)
  • Non-delayed ACK (TCP/Delayed ACK)
  • RTO Not Doubled (TCP/RTO Doubled)
  • Linux/Windows/Mac/BSD support
  • Compatible with Minecraft 1.18.x

Get Started

[dependencies]
rust-raknet = "*"

Reliability

  • unreliable
  • unreliable sequenced
  • reliable
  • reliable ordered
  • reliable sequenced

Macros

Print Raknet Debug Log
Print Raknet Error Log
Print Raknet Info Log

Structs

Implementation of Raknet Server.
Raknet socket wrapper with local and remote.

Enums

Enumeration type options for Raknet transport reliability

Functions

A switch to print Raknet logs 8 bit flag (00000000) enable print debug log = 1[00000001] enable print error log = 2[00000010] enable print info log = 4[00000100] enable print debug && error = 3[00000011]