Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Multi-Player for Dummies?

Discussion in 'Multiplayer' started by BigBack, Mar 17, 2009.

  1. BigBack

    BigBack

    Joined:
    Aug 12, 2008
    Posts:
    18
    Can anyone please provide a newbie tutorial for implementing a multi-player mode? Like I mean a real newbie tutorial. Starting with the basics of setting up a public/commercial web server.

    If I am publishing my game online with my own web server do I need to install anything on my server? I don't have root access to my web server. If you need root access which I don't have are there any suggested web hosting companies setup for unity multiplayer publishing?

    From a work flow point of view is it best practice to design the multi player parts at the beginning? Or can I focus on the core game and level design and add that after?

    Does the multiplayer functionality contain the user registration, Login and data save/maintenace out of the box?

    Thank you in advance for your help.

    Cheers,
    Jeremy
     
  2. Dreamora

    Dreamora

    Joined:
    Apr 5, 2008
    Posts:
    26,601
    There are no tutorials on the networking.
    A very good starting point thought is the Network Section in the documentation which explains a lot + the network example from the resource page which give you something practical to experiment with.

    Networking is no beginner topic.
     
  3. BigBack

    BigBack

    Joined:
    Aug 12, 2008
    Posts:
    18
    Hi Dreamora

    I completely understand that networking is no beginner topic. I found the networking example online after I had posted my topic so I will have a look at that and see what I might learn.

    Having said all of that a simple 101 overview of what a developer has to do to get Unity working on a web server would be nice.

    Also if anyone does know of any web server setups or hosting companies that are configured for Unity I would appreciate the links.

    Cheers,
    Jeremy
     
  4. HiggyB

    HiggyB

    Unity Product Evangelist

    Joined:
    Dec 8, 2006
    Posts:
    6,183
    But there is a full-source example project:

    Networking Example

    Not the same as a tutorial but it's something to get the OP (BigBack) started.
     
  5. BigBack

    BigBack

    Joined:
    Aug 12, 2008
    Posts:
    18
    Hi Tom

    Yes I found the networking example literally moments after I made my plea for help.

    I have the example working off of my server now which is great! Some oddities are happening though. If I start the server, my buddy could join in and we could play. But if he started the server on his end, I could not connect. Odd indeed. Firefox and Internet Explorer mix. Anyways this oddity aside it proves that the multiplayer networking works without having to install separate web server networking software which addresses some of my questions above.

    It seems that the Unity3D multiplayer works right out of the box with only scripting required in authoring? Am I out to lunch here?

    I must admit that I am a bit giddy right now LOL!

    Now the real fun begins. Customizing the multiplayer game play and workflow that I need.

    By the way did you ever get the email I sent you a couple of weeks ago?

    I didn't need sleep tonight anyways...

    Cheers,
    Jeremy
     
  6. zumwalt

    zumwalt

    Joined:
    Apr 18, 2007
    Posts:
    2,279
    Just remember, native Unity networking is only setup for a single server with multiple clients. Anything beyond that is all in your hands.
     
  7. foolish-frost

    foolish-frost

    Joined:
    Mar 18, 2009
    Posts:
    169
    Uh, I hate to be a bother, But I did the following:

    I compiled the Car racing demo. (windows)

    I ran two copies of the game, on the same machine, and had one run as a server.

    Ran the other and told it to find the server with default values.

    Annnd, nothing happened and they did not find each other.

    So, I copied over the car race demo to another computer, and tried to connect them that way, telling one to act as a server, and the other to connect to the IP addy of the server computer,

    Nada.

    I take it I'm supposed to do something else?


    By the way, nice system you have here. Very clean development. Never seen anything that just works as well as this does.
     
  8. foolish-frost

    foolish-frost

    Joined:
    Mar 18, 2009
    Posts:
    169
    Ahhh. Got it.

    I have to override the port to the SERVER port. The default settings are pointing away.

    See. I CAN learn.