MessagePack for Serialization

Hi,

I am trying to use MessagePack (https://msgpack.org/index.html) for serialization rather than json

I am using Lua & Unity. Any one had experience using MessagePack with Lua ? and do you recommend using it.

@Mohammed What MessagePack library do you want to use with Lua? The official one linked on the MessagePack website appears to be broken now.

Why do you want to use MessagePack? Do you have a specific game protocol you still want to create?

@novabyte
I had some issues with TinyJson (Nakama.TinyJson Parsing High Numbers Problem)
So I was reading about methods to serialize data and MessagePack had a lot of benefits like speed, performance & data size
So I checked it

There are two options for Lua on the site
I tried


but I had some issues on line 148

local length = #elements // 2

Also tried the below link and encountered some problems

I know this is not an issue related directly to Nakama but I though maybe someone used it and can share his knowledge. Also, maybe a good solution to be considered along with TinyJson.

@novabyte
for


its for Lua 5.3 & Nakama uses 5.1 that’s way // floor division is not recognized & string.pack & so on