Corona® AutoLAN- Public Internet Multiplayer Support Beta! Join Now!

@Revaerie,
Thank you for clarifying things! Your help is much appreciated. How are things going with your game?

@Gary Duke,
No problem. Yes it is just one php script that you can run on your own server. In fact, we encourage this for the reasons Revaerie mentioned. Please let us know if you have any other concerns. There are functions to redirect AutoLAN to use your own matchmaker server. You can do it like this:

server:setMatchmakerURL("www.mywebsite.com", 54613) --54613 is the port on the php script.  

or alternativley you can just look for the code snippet

socket.dns.toip("rijl-al-awwa.dreamhost.com")  

and change it to your own URL

@Satheesh,
Glad you got things working! As long as you were able to get packets flowing you are in good shape.
>Provided I know the ip address and port of the other device beforehand, is it possible to connect the two without the Matchmaker server?
This will only work if the two devices are not behind a NAT (router.) You cannot know the port for certain beforehand because the router will assign that on its own. Most routers will try to preserve the ports but might not be able to if there are two applications on different machines trying to use the same port for instance. And then there is the NAT that just randomly assigns ports. This is why we need a a matchmaker server. There is a good article that explains all this if you are curious:
http://www.brynosaurus.com/pub/net/p2pnat/
This was one of the sources we used to get familiar with everything.

Thanks Everyone,
M.Y. Developers [import]uid: 55057 topic_id: 19917 reply_id: 90161[/import]

@Satheesh

When I first tested AutoLAN without the matchmaker server (just on my router) I had to enable “allow connections between devices” on my router. Maybe you need to do that as well. [import]uid: 88712 topic_id: 19917 reply_id: 90165[/import]

@M.Y.developers I actually stumbled upon that link before I bought Autolan… but felt too lazy to read through the entire thing so I resorted to AutoLan :smiley: :smiley: will read it now :slight_smile:

@holger thanks! will try it out! [import]uid: 64174 topic_id: 19917 reply_id: 90168[/import]

Suddenly devices in different networks wont connect anymore…
They were working perfectly till some 3 or 4 hours back. I am not even able to run the Simple Multiplayer Ping Pong application anymore… I just keep getting “server timeout”.
But if the devices are in the same network, they work well… What happened?

And on a side note, I think it would be a good idea if you guys have a separate section in the forums for Autolan. [import]uid: 64174 topic_id: 19917 reply_id: 90372[/import]

Thanks Revaerie! Very cool video and very cool game. Thank you for sharing your experience with LAN and online. I cannot wait to play with those features. unfortunately I have been swamped with the day job! cannot wait to go back to Corona dev…I miss it:)

Just wanted to say thanks for the video.

Mo [import]uid: 49236 topic_id: 19917 reply_id: 90391[/import]

Hey M.Y., all,

I put together a quick video that demos my experience with AutoLAN, and shows how I’m using it in my upcoming game. If you’re using or thinking about using AutoLAN you might be interested to check it out.

http://www.youtube.com/watch?v=l8xIeQXpRbg

Enjoy :slight_smile: [import]uid: 87138 topic_id: 19917 reply_id: 90363[/import]

Hello Revaerie,

Thanks for putting up your game! It looks amazing. Its nice to see that things are working smoothly for you. Thank you for introducing AutoLAN in your video and talking about all the features you used. Any release date for your game?

Thanks,
M.Y. Developers [import]uid: 55057 topic_id: 19917 reply_id: 90403[/import]

Hello Satheesh,

It seems our server was reset so the php script was not running at the time. The problem is now fixed. We would really like to have our own forum section. We have placed a request for being on the third party tools list. Hopefully it will go through soon.

Thanks,
M.Y. Developers [import]uid: 55057 topic_id: 19917 reply_id: 90412[/import]

Hello Mo,

We have not heard from you in a while. Hope things are going well for you. We have not forgotten about your profiler requests. Hopefully by the time you come back to Corona dev we will have some more useful stuff for you.

Thanks,
M.Y. Developers [import]uid: 55057 topic_id: 19917 reply_id: 90413[/import]

yeah works now!
I must say, great work guys. Works perfectly.
Really awesome. Gonna use Autolan for my next game :slight_smile:

One small request.
Is it possible to detect if a device’s internet connection is slow? [import]uid: 64174 topic_id: 19917 reply_id: 90421[/import]

Hello Satheesh,

Thanks for the comments!

Is it possible to detect if a device’s internet connection is slow?

You can use the corona apis to determine if the device is on a cellular or wifi network. We have an undocumented function that can tell you the round trip time (aka ping) between the two devices. You can use it like this:

client:autoRTT()  

Currently it just prints the ping on the console but if you need it for something we can create apis to make this available.

Thanks,
M.Y. Developers [import]uid: 55057 topic_id: 19917 reply_id: 90563[/import]

Hello Beta Testers,

Thank you for trying out AutoLAN Internet! We have reviewed everyones problems and comments and we have decided to implement some key changes:

  1. In cases where NAT punchthrough does not work we will add the option of piping the connection through your server. This will always work since your server is not behind a NAT. The latency will obviously be more than a direct p2p connection but so far this will not be a problem for most applications of AutoLAN. We will have an option of turning this feature off from the php script in case you do not want to overload your server. NAT punchthrough can fail for a number of reasons, especially under multiple layers of NAT.
  2. Add a TCP connection to the existing UDP connection. This will fix some issues with transferring files.

Regards,
M.Y. Developers
[import]uid: 55057 topic_id: 19917 reply_id: 90568[/import]

@lemsim Glad you liked it, and I hope you can find some time again soon :slight_smile:

@M.Y., Looking forward to these updates, they sound like some good improvements to the software!

I’m hoping to submit my game to Apple sometime this month. The plan is to include multiplayer in the 1.1 release shortly thereafter - I want to perfect the lobby system and hopefully implement a basic elo system beforehand. With a little luck maybe I can even build up a little user base in that time so there’s people around to play :smiley: [import]uid: 87138 topic_id: 19917 reply_id: 90661[/import]

Where is this discount code that’s mentioned here? [import]uid: 295 topic_id: 19917 reply_id: 91162[/import]

Starting to get done with implementing local wifi multiplayer for my game now. Just wondering about one thing and that is if the application get suspended, say a call comes in or something like that. Normally my game would just pause then and one could continue afterwards, but now things will disconnect. So is there a way to keep the connection alive between server and client? Or reconnect?

Any help here would be great :slight_smile: else its really fun to work with this and Im getting loads of ideas for games and features in existing games so thanks for that again :slight_smile: [import]uid: 17969 topic_id: 19917 reply_id: 91228[/import]

@Revaerie,
Sounds great! Let us know we will be sure to buy it.

@tokyodan
We sent you a dropbox invite. Did you receive it?

@borgb
One solution we can do is perhaps set the timeout value to a long time so that the systems do not disconnect. Even better is to send a message to the server informing it that the client is about to go into standby. Is there any event that gets fired off when the application is about to get suspended? We can see about adding on this functionality.

Thanks,
M.Y. Developers [import]uid: 55057 topic_id: 19917 reply_id: 91352[/import]

@M.Y.developers
if there could be a function for when a client or server goes into supsend it would be great. Not sure if its a big issue, one can always just say that the game will exit to menu if anyone does this :slight_smile:

Another way is to send a message to all so everyone gets paused and maybe have a timer or option to kick inactive player. if its the server then I guess its abit different.

I will see if I can find a solution. There is alot to take into consideration when doing multiplayer compared to single device :slight_smile: I will probably take the easy way out now and see if one can make it more user friendly in the future.

Thanks!
[import]uid: 17969 topic_id: 19917 reply_id: 91426[/import]

“borgb wrote: There is alot to take into consideration when doing multiplayer compared to single device :)”

I don’t think it would offend anyone if that was in Bold type or even ALL caps for that matter…LOL! [import]uid: 106779 topic_id: 19917 reply_id: 91528[/import]

M.Y., I’ve been playing with autolan from the dropbox invite.

I’ve been trying to come up with a combination of functions to do a clean dump of the “client” so I can initiate a totally new one.

It seems when client:disconnect() is called followed by calling makeClient(), it appears I end up with 2 clients which causes the sim to timeout/crash?

I found client:disconnect() followed by client:autoConnect() seems to solve the problem, of disconnecting/reconnecting to the same server.

I believe, haven’t tried it yet, when I disconnect and then go onto another server, which will have a unique param applicationName, I’m going to have to call makeClient() again to get the unique applicationName saved/registered.

Any help on completely destroying/dumping the old client before initiating a new one would be helpful. I wouldn’t be surprised if the answer is staring me in the face and I don’t see it since my eyes are a bit blurry from chasing typos latenight. :slight_smile:

edit:
Thinking more about it this morning, I probably need a way to completely destroy/dump the server also, as makeServer() can easily be called again later when needed.

The ability to call endServer() and endClient() is really what I need.

I haven’t made my autolan purchase yet, but certainly will be. It’s well, amazing! You already know that though…

Thanks, Nail

[import]uid: 106779 topic_id: 19917 reply_id: 91420[/import]

@Nail,
Sorry about the delay. Sure there is a way to gracefully stop the client and server. We think there should be no reason you would need to totally stop and reload the library from scratch. All you would need to do is:

client:disconnect()  
client:stop()  

This will effectively stop the client and you can restart it in a state it was initially loaded. Same code for the server too.

@Borgb,
Thanks for your input. We will take that into consideration. The question is when the user wishes to put the application in the background how much time is given to let everyone know the game is about to be paused? Will there be enough time to get an acknowledgement? What if the packet gets lost? These are important topics to consider and the solution may be rather complex but we will keep it in mind.

And we cannot agree with you more about your observation on multiplayer gaming. Its challenging but well worth it!

Thanks,
M.Y. Developers
[import]uid: 55057 topic_id: 19917 reply_id: 91827[/import]