Search Unity

  1. Get all the Unite Berlin 2018 news on the blog.
    Dismiss Notice
  2. Unity 2018.2 has arrived! Read about it here.
    Dismiss Notice
  3. We're looking for your feedback on the platforms you use and how you use them. Let us know!
    Dismiss Notice
  4. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  5. Improve your Unity skills with a certified instructor in a private, interactive classroom. Learn more.
    Dismiss Notice
  6. ARCore is out of developer preview! Read about it here.
    Dismiss Notice
  7. Magic Leap’s Lumin SDK Technical Preview for Unity lets you get started creating content for Magic Leap One™. Find more information on our blog!
    Dismiss Notice
  8. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

Singleplayer vs Multiplayer

Discussion in 'Connected Games' started by joshcamas, Mar 13, 2018.

  1. joshcamas

    joshcamas

    Joined:
    Jun 16, 2017
    Posts:
    279
    I'm just starting to look into the networking systems into Unity, and I have a question.

    When the player is in "singleplayer mode", is the easiest way to manage this just to still have a network manager and everything, but just have only a server/client (host) and no remote clients? That sounds logical to me at least.

    Thanks!

    Josh
     
  2. Joe-Censored

    Joe-Censored

    Joined:
    Mar 26, 2013
    Posts:
    3,026
    Yeah unfortunately UNET's HLAPI doesn't have a built in single player mode. What you said is an idea others have suggested in other threads to work around the lack of that feature.
     
  3. joshcamas

    joshcamas

    Joined:
    Jun 16, 2017
    Posts:
    279
    Woah... That's actually really crazy...
    But okay, I'll look around :) thank you
     
  4. Joe-Censored

    Joe-Censored

    Joined:
    Mar 26, 2013
    Posts:
    3,026
    I remember reading that Photon has a single player mode. Don't quote me on it, but it may be worth taking a look.
     
  5. Munchy2007

    Munchy2007

    Joined:
    Jun 16, 2013
    Posts:
    826
    It does, and you don't need to make any changes to your game to account for single player vs multiplayer, it's very handy. In single player mode, all network commands, RPCs etc. succeed even without an internet connection active.
     
  6. LaneFox

    LaneFox

    Joined:
    Jun 29, 2011
    Posts:
    5,918
    Can you switch from single to multi on the fly?
     
  7. Munchy2007

    Munchy2007

    Joined:
    Jun 16, 2013
    Posts:
    826
    I believe you have to select single/multi player when not in a room i.e. you haven't started a session, but you might want to check the docs to confirm that.