Last night, I was able to obtain a device IP in testing. This may inspire me to clean up the library I was working on. It’s still not a perfect solution, and I make no guarantees…just wanted to let you know. [import]uid: 21712 topic_id: 15542 reply_id: 58885[/import]
Nice man! I haven’t tested it on two different Mac machines but when I start two simulators on the same machine I start the host and start the join. The host then goes to the send message screen and the joined one times out. When I then click send message it sends to it self. I will maybe test it on two machines later today
[import]uid: 24111 topic_id: 15542 reply_id: 58887[/import]
Yeah, it works solely by IP…so it’d need to be two separate devices/machines. I know my disclaimers are getting old by now, but I can’t say with certainty that this is the best way to implement this stuff. My “final” version will still be missing crucial functionality. …but hopefully by making it more complete, it’ll be a good start for someone to take it and add what’s missing. Anyway, I’ll let you know if I get any further with it. [import]uid: 21712 topic_id: 15542 reply_id: 58927[/import]
Just tested on two mac machines with the simulator and can’t get it working [import]uid: 24111 topic_id: 15542 reply_id: 58935[/import]
Tested my latest copy (which is a little newer than the repo) on an iPhone/Mac…and an iPhone/iPad. Both worked. I’ll let you know when I’ve got something better working, though. [import]uid: 21712 topic_id: 15542 reply_id: 58936[/import]
Can’t wait to get this working!
[import]uid: 24111 topic_id: 15542 reply_id: 59096[/import]
Any updates on this, just tried your old version out and it works pretty well! Was intrigued to see what your newer version works like 
[import]uid: 97707 topic_id: 15542 reply_id: 65938[/import]
Sorry, haven’t had a chance to look at this yet. I’ve got some early testing with the IP fix I had, so I may implement that into the code. However, all I’m working toward here is a working proof of concept…not so much a production-ready plugin. Not yet, at least. hehe Perhaps I’ll try to get that minor fix in place so that the code is at least a little better. Then, maybe someone will be able to use it to make something worthwhile. hehe
Thanks for the kind words, though. [import]uid: 21712 topic_id: 15542 reply_id: 66329[/import]
Hello,
We are interested in making a third party tool that will make local mutliplayer over Wi-fi easy to implement. Our previous tool Corona Ultimote makes use of Lua’s networking abilities to automatically find and connect to the simulator on the computer without the user typing in any IPs or ports, everything is handled automatically. Given that there is enough interest from the community for such a product we will push it high on our development priority list.
Some of the features we are planning to include are:
- Complete user IP/port encapsulation. The user will not need to know how to use ipconfig to play your game.
- Speed: Multiple networking protocols (TCP/UDP) to accommodate high and low latency networks
- Ease of use: send what you want to send and be notified what you received with an event, let the software take care of the network traffic details
- Flexibility: Ability to host more than one game on a network allowing you to make a game lobby type of system. Perhaps we can implement this as well if there is interest.
- One touch multiplayer: the program will automatically find any games and set up a client/server for each phone.
- Drop in play: players can join games already in progress.
Let us know if you are interested in such a product.
Thanks,
M.Y. Developers [import]uid: 55057 topic_id: 15542 reply_id: 74440[/import]
Yeah, I saw the networking code in Ultimote and figured it’d be perfect for this. Sounds great. Let me know if there’s anything I could do to help. [import]uid: 21712 topic_id: 15542 reply_id: 74446[/import]
I would love just to be able to connect two devices on the same local network. If I just see the other iOS-device name (Example: John’s iPhone) and be able to click on it to connect.
@TheOddLinguist: Where can I get the Ultimote Network Code? [import]uid: 24111 topic_id: 15542 reply_id: 74449[/import]
Alright. Here is how we are thinking of implementing it. In your code you will have a multiplayer menu and it will present the user with one of 2 options. He can either host or he can look for games. The host will broadcast his iphone name and the client device will look for broadcasts and report them to your code as custom events so you can add them to a list of options. Next, the Client will choose one of those hosts on the network to connect to. Then you can send and receive whatever data packets you wish. We plan to use UDP for speed but you can assign certain packets with higher priority to receive confirmation it gets through.
is this workflow suitable for you and your project?
Thanks,
M.Y. Developers
-as for the Ultimote code you can get it from our website
http://www.mygamedevelopers.com/Corona-Ultimote.html
toward the bottom there is a zip file you can download. [import]uid: 55057 topic_id: 15542 reply_id: 74451[/import]
It’s excellent for my future projects!
[import]uid: 24111 topic_id: 15542 reply_id: 74452[/import]
@M.Y.developers HI! Your plans are very exciting! that would be very useful for our game! please let me know when you finished Bluetooth and local WIFI connect!
[import]uid: 74676 topic_id: 15542 reply_id: 75682[/import]
Hello Sun.Jiaje,
We are working hard on it. So far we have
-Automatic network discovery
-Client/server handshaking
-Ability to run multiple server/clients on the same network
-Basic UDP send/receive functionality between connected clients.
We still have left to implement the following until release
-ACKs (acknowledgments) for verification
-Flow control (to prevent flooding the network)
-File transfers (for maps, etc using TCP or UDP)
Since Corona does not yet support bluetooth, things will have to be done over wifi. And we saw your new game on the forums. It looks very nice, congratz!
Thanks,
M.Y. Developers [import]uid: 55057 topic_id: 15542 reply_id: 75832[/import]
Hi M.Y.Developers,
Nice to know the progress!
Thank you very much for your efforts on this library, and took a look at our game 
[import]uid: 74676 topic_id: 15542 reply_id: 75947[/import]
Hello Sun Jiajie,
Thanks for your interest! We will answer your email questions here so that everyone can see them.
game will have many rats, bullets, vfx on screen, all these things have to be sync on both devices
Most multiplayer gaming literature suggest 14 packets/second as a good rate for a fast paced multiplayer game. However, your framerate may be 30 or even 60 fps and this would present some problems that you need to consider. If your game is deterministic then you can just stream commands to each game instance. If you do this then you will need to synchronize random seeds and joining in the middle of the game may not be possible.
Another solution is to run the game on the server and stream the game state to the clients. In effect the clients will be “dumb terminals” and their only job is to draw the game screen and send commands to the server. The advantage of this is your game will never go out of sync. However, with 14 FPS you will need to develop some sort of client-side prediction (ie dead reckoning) to get smooth playback, but this is how most FPS games are done these days.
Your solution will probably be something in the middle. Client side prediciton is easy if you are using the physics engine, all you have to do is send velocities of the objects and that should be a good approximation. You may need to occasionally send the entire game state (positions too) to take into account for floating point error (b/c Lua only uses floating point numbers)
still have no idea about how to achieve bluetooth and internet connection, do you have suggestion?
For bluetooth we will just have to wait for Ansca to implement that. As soon as they do we will work on getting it to work over bluetooth. Internet however will be more difficult to accomplish. Unless you want a servers around the world you will probably want some sort of peer-peer type connection, but this itself presents synchronization issues. Internet connectivity is on our list but this will be a little bit down the road.
Update on the progress
Features left to implement
-Flow Control
-File Transfers
-Custom Events
-Documentation/website/examples
Thanks for your questions,
M.Y. Developers [import]uid: 55057 topic_id: 15542 reply_id: 76046[/import]
@M.Y.developers Thank you very much! your advice is really useful!
@oskwish let’s wait until Corona implement bluetooth first…
[import]uid: 74676 topic_id: 15542 reply_id: 76301[/import]
Still very interested in this.
Thanks for the updates and cannot wait for it!
Any ETA you can let slip?
[import]uid: 97707 topic_id: 15542 reply_id: 77306[/import]
Hello All,
Yes the ETA is today! We have been working hard to give you a quality product and a clear and concise documentation. We will launch in a few hours or so :). We will let you know on this thread and start another thread on the third party tool forum.
Thank you for your interest,
M.Y. Developers [import]uid: 55057 topic_id: 15542 reply_id: 77353[/import]