Releases: TigersUniverse/Nexport
Upgrade kcp2k
This release upgrades kcp2k to attempt to fix random freezing issues.
New Deserialize
This release adds a new public Deserialize method that will allow you to deserialize with a type parameter, instead of a Generic type.
Here is an example of usage
// Assume data is filled with a message
byte[] data = GetData();
Type myKnownType = typeof(MyMessage);
object dynamicMyMessage = Msg.Deserialize(data, myKnownType);
Message Improvements
This release adds all sorts of improvements to how messages work!
Removal of MessageId
The previously required MessageId property is now no longer required! Here's what a new message can look like
[Msg]
public class MyCoolMessage
{
[MsgKey(1)] public string Name;
[MsgKey(2)] public int Age;
}
New Compression
Instead of the old system of either compression was on or off, you can now enable compression for specific messages! Simply add the MsgCompress(int level)
attribute, as demonstrated below
[Msg]
[MsgCompress(16)]
public class MyCoolMessage
{
[MsgKey(1)] public string Name;
[MsgKey(2)] public int Age;
}
For compression levels, please read the zstd manual
New Compression Algorithm
On top of the change of how we compress, we also changed what algorithm we compress with. We switched from MessagePack's LZ4 to Meta's Zstandard, because it is described as a "fast lossless compression algorithm, targeting real-time compression scenarios at zlib-level and better compression ratios." This is exactly what games should be using for compression, especially if there's large amounts of data being transported. You can read this article for a comparison of all compression algorithms.
Bug Fixes
Simple bug fix for a lot of issues related to messages and Unity. Binaries are no longer bundled.
🐛 Bug Fixes
Hey guys, simple bug fix release here. Net Framework builds are now located in Nexport.zip/48build
and Net Core builds are now located in Nexport.zip/70build
folders.
Changes:
- Renamed libs to both be
Neport.dll
to fix reference issues between framework4 and netcore solutions.48build
for net framework70build
for net core
- Fixed bug where ValidateMessage could be null
- Be sure to send your validate message until you are validated
- This will be implemented internally soon
- Be sure to send your validate message until you are validated
- Made Create give an option to Close when Stop is invoked, and an option to get a closing message
- Can be useful for safe multithreading
🖥️ .NET 7.0 Support
This release includes a .NET7 build!
Please download Nexport.48.dll
for .NET Framework v4.8
or
download Nexport.70.dll
for .NET 7.0
🛰️ Add LiteNetLib Transport
Added LiteNetLib as a Transport. This now gives user a TCP, KCP, and UDP transport option.
Changes:
- Added LiteNetLib as a Transport
- A Reliable UDP Library for C#
- Updated Copyright Year
- Fixed typo between commits
First Release! 🎉
See the README.md for more details!