Motivation
Writing code in lua-enet introduces a lot of boilerplate code that obfuscates your game code. Your game code becomes tied to your networking code, and it becomes difficult to reuse code between the client and server. sock tries to remedy this by taking on the task of serializing and sending data for you. It enables you to focus on the network code that matters.

Feedback needed
sock.lua is still a work in progress, but is already able to be used in games. However, there is a long way to go before it could be considered "complete."

How can this library be made more useful to you?

How can the documentation be improved?

[/b]
If you have comments, or need help, leave a reply here or send me a message on #love. Thanks.

Last edited by Ikroth on Sat Dec 17, 2016 10:13 pm, edited 1 time in total.

Wow, this looks really well put together and like a valid alternative to lube.
Shame that I can't give any deep feedback, but from what I see on the surface and the documentation you did a really good job!

Hat's off. Definitely a use. This could make my networking problem solved. It follows my naming conventions and tidy as heck (especially the doc), just the way I like it. No feedback from a newbie of networking stuff, but surely it's a great job from you!

Right now, I'm working on support for custom serialization functions, so you're not forced to use bitser if you don't want to. You can probably expect to see it in the docs within a week or so.

The documentation still lacks some information, i.e. examples, usage info. There's also no information on how to use "data formats" (my own term, might change.) It's a cool feature that potentially saves a lot of bandwidth. Now, I just need to write my own Lua doc tool so I don't have to use LDoc anymore .

So, i just took this awesome library out for a spin.
One thing that i didn't know and took me some time to figure out: the server always receives an event, the data AND the peer that sent it.
So, if you want to send information specifically to a peer, you must use the peer the server receives on event trigger. It is pretty damn obvious now, but complete beginners to networking may have troubles.

I'll see if i can fix the ugly code around my simple "box moving" example with this lib and then share it here if people so wish.

Other than that, i suppose all "security" checks are done by the lib already no? So we only have to determine if the data received is valid or not to prevent cheating and so on...

Not sure if i was clear, say so if not. Otherwise, amazing library! Will definitely use it.

Don't check my github! It contains thousands of lines of spaghetti code in many different languages cool software! https://github.com/Sulunia