Not logged inGosu Forums
Forum back to Help Search Register Login
Up Topic Gosu / Gosu Exchange / Multiplayer Ruby game possible with UDPSocket?
- - By arrow Date 2013-04-07 14:18 Edited 2013-04-07 20:49
I'm trying to create a P2P mesh network for my game with a server sharing the diffrent clients with each other. The game I want to create is a real time action game, and I thought it would be cool with multiplayer functionality. I'm currently experimenting with ruby's UDPSocket and I've successfully send data over LAN and over the internet with Hamachi. Though Hamachi works there's a limit of 5 clients for each network and I would like something where the setup isn't as much of a hassle for the user.

It's the first time I'm trying to do something like this so I'm completely unexperienced. I know a little of rails and sinatra development but not really much of server setup. I've done a bit of research but I still don't quite understand what needs to be done. So I have to create a port forward/tunnel on the clients?

Possible solutions?
-net ssh in ruby or ssh gateway
-OpenSSH (mac, linux, cygwin)
-OpenVPN (mac, windows)
-tinc-vpn (mac, linux, cygwin)
-LogMeIn Hamachi (mac, windows, linux)
-tunngle (windows only)

when I run ifconfig I can see ham0, the Hamachi network interface with my public hamachi ip "". Is it possible to setup something like this without Hamachi? It's only possible to send data to it if people are in my hamachi network and the UDP port made available by Hamachi is 17771.

  ether 7a:79:00:00:00:00
  inet netmask 0xff000000 broadcast
  inet6 fe80::7879:ff:fe00:0%ham0 prefixlen 64 scopeid 0x6
  inet6 2620:9b::195c:d217 prefixlen 96
  open (pid 68260)

In addition, as for security matters, currently I'm not worried about game cheating possibilities. It's just that I don't make any security breaches by exposing the users computer or something.
Parent - - By Dahrkael Date 2013-04-07 15:58
why dont you use the udp sockets directly throught Internet instead of tunneling?
Parent - - By arrow Date 2013-04-07 16:00
As I said I'm not very experienced with any of this. Do you have any recommendations on what I could read up on?
Parent - - By Spooner Date 2013-04-07 18:22
I'd recommend looking at the rEnet gem, which wraps the Enet networking library which is designed specifically for this purpose.
Parent - By arrow Date 2013-04-07 18:32
Thanks I'll look into it.
Parent - By erisdiscord Date 2013-04-07 21:36
I wish the ENet people (person?) would publish, like, a formal description of the actual protocol and algorithms used so that there can be more than one implementation. The reference implementation's API is kind of…not that great. :\
Parent - By arrow Date 2013-04-07 23:34
Hm, I installed ENet and rENet. I was trying to setup a basic server and connection without success. Then I found and tried to run the rENet example without success.
Parent - By arrow Date 2013-04-14 20:34 Edited 2013-04-15 10:07
Up Topic Gosu / Gosu Exchange / Multiplayer Ruby game possible with UDPSocket?

Powered by mwForum 2.29.7 © 1999-2015 Markus Wichitill