Page 1 of 3

Noobhub - opensource multiplayer library for LÖVE

Posted: Sat Jan 11, 2014 9:20 pm
by Overtorment
Hi guys, here's the Publish/Subscribe network library I've built.
It was originally made for CoronaSDK, but I discovered it works perfectly in LÖVE with minimum porting.

Here it is: https://github.com/Overtorment/NoobHub

It is super-simple, perfect for network games (realtime and turn-based) or any other network
appliances you can think of.
It is already battle tested and proven stable in production, as CoronaSDK developers already developed dozens of apps using Noobhub, some of them being chart leaders.

I've put a demo project for LÖVE SDK as well, so you can just grab it as an example and bring multiplayer to your own games!

Short features list:
* Connections are routed through socket server with minimum latency, ideal for action games.
* Simple interface. Publish/subscribe paradigm in action.
* Server written on blazing fast Nodejs.
* Socket connections, works great through any NAT (local area network), messages delivery is reliable and fast.

Repo includes server code (so you can use your own server) and lua client. You can test on my server, credentials are in the repo!
Hope you guys will find it usefull, have fun!
If you are having issues Ill be glad to help, just post to this thread!

PS. If anyone didnt get it, again, this is FREE and OPENSOURCE, as opposed to paid services like pubnub.com or pusher.com
PPS. Spent one evening messing with LÖVE assembling demo project for Noobhub.. and I love it!
PPPS. If you like Noobhub, give it a star on Github!

Re: Noobhub - opensource multiplayer library for LÖVE

Posted: Sat Jan 11, 2014 9:33 pm
by Overtorment
Oh, forgot to post code examples.

INITIALIZE

Code: Select all

    hub = noobhub.new({ server = "your_server"; port = 1337; }); 
SUBSCRIBE TO A CHANNEL AND RECEIVE CALLBACKS WHEN NEW JSON MESSAGES ARRIVE

Code: Select all

   hub:subscribe({
      channel = "hello-world";  
        callback = function(message)

            if(message.action == "ping")   then 
                print("Pong!")
            end;

        end;
    });
SAY SOMETHING TO EVERYBODY ON THE CHANNEL

Code: Select all

    hub:publish({
        message = {
            action  =  "ping",
            timestamp = system.getTimer()
        }
    });

Re: Noobhub - opensource multiplayer library for LÖVE

Posted: Fri May 23, 2014 11:15 am
by Overtorment
Hello guys, Im a bit surprised that almost nobody of Love community uses this library.
Is there anyone here building multiplayer games?

Re: Noobhub - opensource multiplayer library for LÖVE

Posted: Fri May 23, 2014 11:57 am
by T-Bone
Overtorment wrote:Hello guys, Im a bit surprised that almost nobody of Love community uses this library.
Is there anyone here building multiplayer games?
I'd say multiplayer games in löve are quite rare. And most of them just use luasocket directly. But having libraries like this is nice, it can significantly reduce dev time for many projects.

Re: Noobhub - opensource multiplayer library for LÖVE

Posted: Fri May 23, 2014 2:20 pm
by jjmafiae
License?

Re: Noobhub - opensource multiplayer library for LÖVE

Posted: Fri May 23, 2014 2:30 pm
by Overtorment
WTFPL :awesome:

Re: Noobhub - opensource multiplayer library for LÖVE

Posted: Fri May 23, 2014 5:42 pm
by Karai17
You would probably be better off posting this in the Projects subforum to gain more attention.

Re: Noobhub - opensource multiplayer library for LÖVE

Posted: Wed May 28, 2014 10:53 am
by Overtorment
Is there an admin in this thread? Can it plz get moved to Projects subforum..?

Re: Noobhub - opensource multiplayer library for LÖVE

Posted: Wed May 28, 2014 4:14 pm
by Karai17
Send a pm to bartbes

Re: Noobhub - opensource multiplayer library for LÖVE

Posted: Fri May 30, 2014 8:58 am
by Overtorment
wooohoooo its done :crazy: