Noobhub - Free Opensource Multiplayer And Network Messaging For Coronasdk

hey @coolromin,

this should be no problem.

As you created the first lobby,

hub = noobhub.new({ server = “127.0.0.1”; port = 1337; }); 

you can do it again, like

hub2 = noobhub.new({ server = “127.0.0.1”; port = 1337; }); 

hub3 = noobhub.new({ server = “127.0.0.1”; port = 1337; }); 

etc. But subscribe each one of them to different channel  (see the hub:subscribe() method)

I just started to learn noobhub… and do you have any sample code or documentation about lobby/matchmaking/dynamic rooms, etc.?

It seems hard to understand for me now. All I know is that the client can subscribe to certain channels and send/receive notifications. But how is this subscribe/notification method applied for these multiplayer features?

Hi,

I’m using noobHub with corona sdk on my local server and it works fine,
but when I put the server online (to my free openshift account) I can’t connect the client application to it.

On the server side I have to set up the ip and port like this:

var port = process.env.OPENSHIFT_NODEJS_PORT || 1337;
var ip = process.env.OPENSHIFT_NODEJS_IP  || 0;

server.listen(port, ip);

I tried several options in my corona application, but no luck:

ws://my-server.rhcloud.com, port: 80

http://my-server.rhcloud.com, port: 80

my-server.rhcloud.com, port: 80

How could I connect the client to the online server?

You need to find out contents of process.env.OPENSHIFT_NODEJS_PORT and process.env.OPENSHIFT_NODEJS_IP

and connect client to those.

My friend had success with Noobhub and similar cloud environment (cloud9 to be specific). So you beter consult with Openshift documentation or ask support.

Personally I recommend getting cheap VPS (couple of bucks per month), or for development just use the server from demo project. Thats my public test server (here:  https://raw.githubusercontent.com/Overtorment/NoobHub/master/client/lua-corona/main.lua   )

Cheers!

Thanks for the answer!

After a lot of searching, testing and asking around I think the VPS would be the best option.

Which VPS provider do you suggest for a nodejs websocket application (noobHub server)?

Here’s one option: http://www.develephant.net/noobhub-multiplayer-server-for-corona-sdk-in-5-minutes/

Cheers

Digitalocean’s droplets looks promising, I will try that.

Thanks!

Hi @overtorment 

I want to create a chat app and i am wondering how to connect to more then 1 channel at the same time?

For example let’s say i am connected to the main-lobby channel and i can chat with everyone but what if at the same time i want to be able to chat with indvidual players as well by creating and connecting to private channels while keeping the connection to the main-lobby channel?

Hope you will answer this!!

 

hey @coolromin,

this should be no problem.

As you created the first lobby,

hub = noobhub.new({ server = “127.0.0.1”; port = 1337; }); 

you can do it again, like

hub2 = noobhub.new({ server = “127.0.0.1”; port = 1337; }); 

hub3 = noobhub.new({ server = “127.0.0.1”; port = 1337; }); 

etc. But subscribe each one of them to different channel  (see the hub:subscribe() method)

I just started to learn noobhub… and do you have any sample code or documentation about lobby/matchmaking/dynamic rooms, etc.?

It seems hard to understand for me now. All I know is that the client can subscribe to certain channels and send/receive notifications. But how is this subscribe/notification method applied for these multiplayer features?

Hey I want to send image via separate channel using node.js in corona SDK(using Noobhub).

Can any one suggest me the code for both side client as well as server side.

Thanks in advance

please im a developer from africa. i keep seeing uk and us servers .please is there a chance for me to use noobhub from africa

Hi,

I’m using noobHub with corona sdk on my local server and it works fine,
but when I put the server online (to my free openshift account) I can’t connect the client application to it.

On the server side I have to set up the ip and port like this:

var port = process.env.OPENSHIFT_NODEJS_PORT || 1337;
var ip = process.env.OPENSHIFT_NODEJS_IP  || 0;

server.listen(port, ip);

I tried several options in my corona application, but no luck:

ws://my-server.rhcloud.com, port: 80

http://my-server.rhcloud.com, port: 80

my-server.rhcloud.com, port: 80

How could I connect the client to the online server?

You need to find out contents of process.env.OPENSHIFT_NODEJS_PORT and process.env.OPENSHIFT_NODEJS_IP

and connect client to those.

My friend had success with Noobhub and similar cloud environment (cloud9 to be specific). So you beter consult with Openshift documentation or ask support.

Personally I recommend getting cheap VPS (couple of bucks per month), or for development just use the server from demo project. Thats my public test server (here:  https://raw.githubusercontent.com/Overtorment/NoobHub/master/client/lua-corona/main.lua   )

Cheers!

Where can I find good tutorials on this

Thanks for the answer!

After a lot of searching, testing and asking around I think the VPS would be the best option.

Which VPS provider do you suggest for a nodejs websocket application (noobHub server)?

Here’s one option: http://www.develephant.net/noobhub-multiplayer-server-for-corona-sdk-in-5-minutes/

Cheers

Digitalocean’s droplets looks promising, I will try that.

Thanks!