Jump to content

  • Log In with Google      Sign In   
  • Create Account

We need your help!

We need 7 developers from Canada and 18 more from Australia to help us complete a research survey.

Support our site by taking a quick sponsored survey and win a chance at a $50 Amazon gift card. Click here to get started!


Monogame and cross platform multiplayer


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
4 replies to this topic

#1 EJH   Members   -  Reputation: 315

Like
0Likes
Like

Posted 07 March 2013 - 12:48 PM

Was looking to port an XNA game over to Monogame to run on Linux / Mac as well. One issue though ... how to do cross platform multiplayer? Currently using Lidgren Network Library but I guess that won't work off Windows. Is there a good way to do cross platform networking?



Sponsor:

#2 Aeramor   Members   -  Reputation: 1414

Like
0Likes
Like

Posted 07 March 2013 - 02:04 PM

Any data being transmitted only needs to be interpreted on both sides, at the end of the day it's just ones and zeros in a particular protocol. As long as they both understand the messages it's not an issue if they are windows, linux or on a potato.

 

If you are asking for a specific library to use, just google it; there are many.


-Aeramor

CTO at Conjecture, Inc.


#3 CC Ricers   Members   -  Reputation: 1482

Like
1Likes
Like

Posted 07 March 2013 - 05:13 PM

Actually, MonoGame does use Lidgren and it is required to include with the framework.


New game in progress: Project SeedWorld

My development blog: Electronic Meteor


#4 blueshogun96   Crossbones+   -  Reputation: 1755

Like
0Likes
Like

Posted 07 March 2013 - 08:56 PM

A really good cross platform networking library (with a very simple API design) that I recommend is Enet.  http://enet.bespin.org/

 

It works on Windows, MacOSX, and Linux of all forms.  It uses a very reliable and stable UDP based network and is more reliable than TCP (from what I hear).  It's also open source and the licence is pretty reasonable.

 

Shogun.


Follow Shogun3D on the official website: http://shogun3d.net

Posted Image Posted Image Posted Image Posted Image

"Yo mama so fat, she can't be frustum culled." - yoshi_lol

"One objection to a “critique of C#” would be that you can’t talk about C# without talking about the whole “.Net experience”. However, one can approach the topic of Hitler without a complete discussion of Nationalist Socialism, so I feel justified." - Steve White.

#5 Xanather   Members   -  Reputation: 753

Like
0Likes
Like

Posted 07 March 2013 - 10:45 PM

Was looking to port an XNA game over to Monogame to run on Linux / Mac as well. One issue though ... how to do cross platform multiplayer? Currently using Lidgren Network Library but I guess that won't work off Windows. Is there a good way to do cross platform networking?

You can use System.Net.Sockets. That namespace is implemented on both Mono and .NET.

 

Sure, it may take a bit longer to develop than using a networking library, but it will be helpful in learning networking, and to be honest its not really that hard once you know how TCP/UDP works and know about the several techniques you can apply to each.

 

System.Net.Sockets even has a slightly higher level socket class for UDP/TCP (TcpClient/UdpClient).


Edited by Xanather, 07 March 2013 - 10:45 PM.





Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS