Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

[noob] Idea behind a multiplayer rpg

Discussion in 'Multiplayer' started by Wurtstulle, Jun 20, 2016.

  1. Wurtstulle

    Wurtstulle

    Joined:
    Dec 3, 2013
    Posts:
    1
    Hey Unity-Com!
    This is my first post here after I read my first Unity book.
    I just saw a lot of multiplayer Tutorials and sample Projects, but what I need is the understanding of the following question.

    At the moment I got a first sample Project running. (basic loot&level rpg)
    I also got Enemys and of course a AI for them.

    When I now want to make this game online playable, does the Server need to take this funcionality fully over?
    At my current understanding most online games work like the game actualy runs on the Server and the Client just gets for example where the Enemys position is at this moment.

    But can I create a "Server" programm which doesnt renders a game but still calculates the AI (and sends position to all clients) ?


    Hope someone of you can bring a little Light in here :D
    Have a nice week, Wurststulle
     
  2. Severos

    Severos

    Joined:
    Oct 2, 2015
    Posts:
    181
    Fully possible, take a look at headless mode build.
     
    Wurtstulle and Whippets like this.
  3. AntonBertelsen

    AntonBertelsen

    Joined:
    Oct 13, 2014
    Posts:
    37
    http://noobtuts.com/unity/unet-server-hosting

    This explains how to run a headless game instance on a Linux server.

    It's a very good idea to have the server run all the calculations, since cheating becomes very easy otherwise. In fact you should assume that every single input sent to the server is a hacked message. - This is very advanced though, and not necessarily something you have to worry about right away.

    If you want more information on this topic, I highly recommend these resources, although they assume that you already have a degree of knowledge about multiplayer games:


    Best of luck with your game. I would recommend that rather than integrating the concepts described in the sources above, you begin with a simple more simple network structure, where the client simply sends his position to the server, and the server sends that position to all the clients, as well as AI and other serverside calculations.
     
    Wurtstulle likes this.