0.0.12 - The big rewrite
This release comes with 3 major changes:
- Rewrite of the reliability/fragmentation protocol, it should handle any bandwidth.
- Split of renet and the transport layer. Now it's possible to use other transport protocols.
- Configuration simplification
Most of the public API has stayed the same. With the split of the transport layer, you now need to create and update it separately from renet
, but the setup is still very similar (renet comes with a default transport layer using renetcode
). A lot of the work for this release was done in the internal fragmentation/reliability protocol, now it should handle any bandwidth. Also, you don't need a special configuration when sending bigger messages, the fragmentation is better and is done per message now.
Renet
Added ⭐
- Added
NetcodeServer
andNetcodeClient
all the network transport logic has been moved to these structs.- You can check the documentation, examples, or demos to see how these new structs are used.
Changed 🛠️
- Replaced
RenetConnectionConfig
withConnectionConfig
, this new configuration has been greatly simplified. You only need to specify how many bytes you can use per update tick and the channels configuration (ChannelConfiguration
). - Rework of
ChannelConfiguration
, only 3 fields now:channel_id
,max_memory_usage_bytes
, andsend_type
. RenetServer::new
andRenetClient::new
now only hasConnectionConfig
as argument.- Renamed
RenetServer::is_client_connected
tois_connected
. NetworkInfo
hasbytes_sent_per_second
andbytes_received_per_second
instead ofsent_kbps
andreceived_kbps
.
Removed 🔥
- Removed
send_packets
fromRenetServer
andRenetClient
, this is now done by the transport layer. - Removed
can_send_message
, this could cause some bad practices of checking before sending messages. If you cannot send a message you should change the channels configurations.
Rechannel
Rechannel has been deprecrated, all its logic has been moved inside renet.
Bevy Renet
Added ⭐
- Added new Plugins for the transport layer:
NetcodeServerPlugin
andNetcodeClientPlugin
. - Client disconnects when the app closes.
- Server disconnects all clients when the app closes.
Changed 🛠️
- Removed the
clear_events
options, you can achieve the same functionality by adding the Events yourself before the Plugin.