Search Unity

[Released] Master Server Kit: create your own UNET-based dedicated server

Discussion in 'Assets and Asset Store' started by gamevanilla, Oct 14, 2016.

Thread Status:
Not open for further replies.
  1. cwxxc3

    cwxxc3

    Joined:
    Feb 1, 2017
    Posts:
    23
    Hi,
    I have a few questions about this asset. I have a unet game that has it's own logic, loads and saves from it's own database. Will this asset help me create a server lobby for my game, so players can launch it and then select each server. I don't need any authentication when they open the game. Does it work by launching the server select scene and then loads my game in another scene? Is this asset for me?

    A few more questions since I didn't see a demo anywhere:
    1. I have a max number of players that I want on all clients. In my game's network manager it has it as it's max. Does this asset have a message that shows lobby is full?
    2.Is there a way to name each server? Or show it's ping?
    3. Can players create games on a headless dedicated server and have the game registered on the master server?
    4. Are there any functions to control players on the server? Like kick or ban certain players?
    5. if my game is open-world so there is no start or end, players can join any time, this will work with this asset?
    6. Does this work on unity 2018? Is building in IL2CPP supported?
     
    Last edited: Dec 24, 2018
  2. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    The easiest way to think about the kit is as a replacement of Unity Services that runs on a dedicated server of your own. It provides equivalent lobby functionality with additional player authentication and player data storage features (that you are not required to use).

    There is a global maximum number of players and a room-specific maximum number of players.

    Not built-in.

    If the dedicated server is the one you control, then yes. The kit does not allow players hosting the servers themselves.

    Not built-in.

    Yes; the kit supports both room-based and world-based games.

    It works just fine on the latest version of Unity 2018.2 (2018.2.20 at the time of this writing). With Unity 2018.3 being the first official version of the engine that marks UNET as deprecated, we do not officially support it.

    Regarding IL2CPP support, I am out of the office until next year so cannot readily test this myself. I will update this post once I'm back.
     
  3. cwxxc3

    cwxxc3

    Joined:
    Feb 1, 2017
    Posts:
    23
    Interesting. So is it possible for me to host separate headless servers and then link them up to the master server? I'm thinking what csgo or tf2 does with their servers. And you said the kit doesn't allow players hosting their own servers themselves, but my game has the host act as the server where clients connect. Is there an easy work around so my players can register their server on the master server then after run it headless? So there's a link to their server ip and doesn't get removed once the player closes their client
     
  4. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    Yes.

    The kit is completely focused on your game being server-authoritative (rather than having a host player): there are a number of spawned game server instances that your players will connect to as clients. Not sure how feasible it would be to work around that, but it will definitely imply additional work on your end.
     
  5. cwxxc3

    cwxxc3

    Joined:
    Feb 1, 2017
    Posts:
    23
    my game is server-authoritive. each player can host a server of the game and clients can join. I'm interested in using so people can host servers and then have a list of online servers that are hosted. But If I can host separate headless servers and then link them up, it shouldn't be too hard for players to add their servers to the master server
     
  6. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    Cannot really answer how hard it would be because it is not a use case I have covered myself.
     
  7. GamerRob

    GamerRob

    Joined:
    Oct 7, 2018
    Posts:
    19
    is the chat on this just from the clients to the server for support or can logged in users talk to all other logged in users?
     
  8. Paradoks

    Paradoks

    Joined:
    Oct 13, 2009
    Posts:
    436
    With the uNet being deprecated, has someone tried to make MSK work with Mirror ?
     
  9. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    In the lobby, all users can talk between each other. In a game room, all the players in the room can talk between each other.
     
  10. Smurfj3

    Smurfj3

    Joined:
    Feb 15, 2015
    Posts:
    4
    Hello, first off I want to say that this is an awesome asset well worth the money. But I do have some questions regarding the GameServer.exe, I understand how the master server, zone server and gameserver work however I am kind of lost on how to start coding my client because I have no clue on how to communicate between client and Gameserver.exe.

    On the ClientApi I see the option "Use Network Manager", does that mean I can use Unet functions in my scripts and will the client then automatically communicate with the gameserver. I am not sure on how to even update player position to the server and have the server update all the clients.

    My thought was to create a network manager on the gameserver and on the client and then somehow make it work. I am super confused :D

    ----------
    edited because spelling
     
    Last edited: Jan 10, 2019
  11. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    Thank you!

    Please use the official contact form at our website for support questions; this thread is for announcements and pre-purchase questions only.
     
  12. mosheep

    mosheep

    Joined:
    Apr 27, 2016
    Posts:
    1
    Hi Gamevanilla i try so many times but after i import only core folder to my ccg project option to build servers do not appear in top of unity, and when i import all package my game not build in build game client i don't know what i can do
    can you help-me?
     
  13. GamerRob

    GamerRob

    Joined:
    Oct 7, 2018
    Posts:
    19
    Hey...... I am trying to figure out how difficult it would be to take your demo and just adopt it to my game. From what I see if your authentification and matchmaking, this looks fine for my game. I looked at your doc and it seems to assume I have either already implimented the unity matchmaker service or I am starting from scratch. I have a client server game that runs on a local server using networkmanager/UNET.... is there a guide that tells me what I need to hit in your demo to get it to launch my gameserver instead of your sample and my client instead of your sample and just use the matchmaking and authentification in the demo as is?

    I think the "Integrating Master Server Kit with a game using the Network Manager component" is what I need ..... if I make these changes in the demo and basically add my server as the offline scene and my client as the online scene, will this allow the demo to launch my server and client in place of the dummy server/client it launches now?
     
    Last edited: Jan 15, 2019
  14. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    Please use the official contact form at our website for support questions; this thread is for announcements and pre-purchase questions only.
     
  15. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    Not exactly. On the server side, you will use the provided game server scene as the offline scene and the game scene as the online scene. On the client side, you will use the provided lobby scene as the offline scene and the game scene as the online scene.

    As long as your game is written with this complete separation between the server and the client in mind, everything should just work. You can confirm this by starting a UNET server locally (for example, with the Network Manager HUD) and connecting a few independent clients to it. That is exactly what the kit does once a game server instance is spawned.
     
  16. GamerRob

    GamerRob

    Joined:
    Oct 7, 2018
    Posts:
    19
    Yeah.... my game runs this way.... that is how I run it now. (Launch a standalone server and then multiple clients)..... I did what you said above (mixed with your online docs) and it seems to be working.... It now launches my game instead of the bland demo screens. Had a few build issues (did not build my game in with the client scene first time) but figured these out and got it to work. thanks. Looks like a great asset. Worth the $50 to save lots of time.
     
    Last edited: Jan 16, 2019
    gamevanilla likes this.
  17. jamesleakos

    jamesleakos

    Joined:
    Mar 8, 2018
    Posts:
    5
    Hi there! I'm thinking about purchasing this and the CCG Kit - how will these be affected by UNET deprecation?
     
  18. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    Thank you for your interest! I honestly do not know, because there is no official alternative as of yet. But it is definitely on my mind.
     
  19. banksazero

    banksazero

    Joined:
    May 8, 2015
    Posts:
    77
    Hi there
    If I nearly not know anything about network (I learned some from forge , Unet)
    how much tutorial you have for this asset?
    my target is creating a authoritative server (from forge I'm not sure how to do server logic)
    All of I know is just concept

    my game need basic component like
    login (facebook guest IG ID)
    Lobby for(1-1 2-2 ) player
    Database(Mysql)
    matchmaking
    turnbase game


    Do you have discord channel ?
     
  20. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    You will definitely need a knowledge of multiplayer programming in order to use the kit. You can find the documentation here.
     
  21. jamesleakos

    jamesleakos

    Joined:
    Mar 8, 2018
    Posts:
    5
    Thanks for the reply. I'm going to go ahead and get them, they seem like fantastic assets and poking around more I see that you've received a ton of great feedback, not only for the assets but for customer support. Do you think you'll try to make these products work with future Unity Multiplayer, once it becomes more clear what that will be?
     
  22. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    Thank you! Hopefully yes.
     
  23. banksazero

    banksazero

    Joined:
    May 8, 2015
    Posts:
    77
    what will happen if UNET deprecated
    from FAQ you told us this kit use with UNET or not ?
     
  24. banksazero

    banksazero

    Joined:
    May 8, 2015
    Posts:
    77
    Let me ask a little bit

    Is your asset can do list below?

    Authoritative server
    login (facebook guest IG ID)
    Lobby for(1-1 2-2 ) player
    Database(Mysql)
    matchmaking
    chat (lobby , in game and direct message)

    Do you have any show case
     
  25. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    There is no demo, but the asset can do all of the things in your list except for the login with Facebook. Again, you will need to be familiar with UNET in order to implement the multiplayer logic of your game in a server-authoritative way; the kit is game-agnostic and exclusively focused on the backend features.
     
  26. hottabych

    hottabych

    Joined:
    Apr 18, 2015
    Posts:
    107
  27. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    No, the kit works with UNET. You are the second person to ask about Mirror so far; generally speaking, if there is more interest, just let me know!
     
    Weblox likes this.
  28. Prodigga

    Prodigga

    Joined:
    Apr 13, 2011
    Posts:
    1,123
    +1 for more interest

    Also, the asset description says it has dynamic game server spawning. What does this mean, exactly? Ideally it would mean it automatically spins up (for example) EC2 instances as demand rises, etc. I'm guessing this is not what it means though? If it isn't what that means, what is the recommended Pipeline for something like this if we use your asset?
     
    Last edited: Mar 4, 2019
  29. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    It means that game server instances are dynamically spawned based on new games being requested by players. There is no concept of load balancing in the kit, as it is not tied to any specific service provider. You would need to build that kind of functionality on top of the kit.
     
  30. Weblox

    Weblox

    Joined:
    Apr 11, 2016
    Posts:
    277
    + 1 for Mirror Support here! :p
     
    hottabych likes this.
  31. elasto

    elasto

    Joined:
    Mar 20, 2014
    Posts:
    18
    +1 for Mirror support.

    (Since your project comes with full source code and Mirror is designed as a like-for-like replacement for UNET I imagine it wouldn't be hard for anyone downloading it to transition it themselves though.)
     
  32. IEdge

    IEdge

    Joined:
    Mar 25, 2017
    Posts:
    51
    + 1 for Mirror Support :rolleyes:

    whatever... while, I suggest you add #pragma warning disable 0618 to scripts.
     
    Last edited: Mar 11, 2019
  33. LenarVakhitov

    LenarVakhitov

    Joined:
    Mar 21, 2018
    Posts:
    3
    Help me please. In my game I use Master Server Kit asset and Mirror, and I have problems when I try to insert a player’s prefab into the Master Server Network Manager component (This is a component of the Master Server Kit asset), I get an error stating that there is no Network Identity component in the player’s prefab, in fact there exists. I think that the reason for this error is that the Master Server Network Manager component works well only with the Network Identity component from UNET, and it cannot detect the Network Identity component from the Mirror. How can I fix it ??
     

    Attached Files:

  34. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    The kit does not provide support for Mirror. Having said that, please use our official contact form for support questions. Thank you!
     
  35. vertexcolor

    vertexcolor

    Joined:
    Mar 11, 2013
    Posts:
    18
    +1 for mirror support ;)
     
    Vortavasail likes this.
  36. buc

    buc

    Joined:
    Apr 22, 2015
    Posts:
    123
    After reading the asset description and the docs I'm not sure about this:

    Can you retrieve a list of servers as you may know it from steam?
    If yes, which information is included (ip, server-name, map-name, I've already read that the ping can't be shown, at least out of the box).
    Does it have a functionality to replicate it's data to other master-servers? So in case one server is down the game can get the data from other servers.

    As for mirror:
    - mirror is activly developed
    - there are some heavy weight developers involved
    - it's not isolated but used by the devs in their own real projects, so the feedback of the needs are great
    - so mirror is something I would definitely count with
     
    Last edited: Apr 18, 2019
  37. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    These are not built into the kit.
     
  38. buc

    buc

    Joined:
    Apr 22, 2015
    Posts:
    123
    So it autoconnects to the first game server which matches? It is hard to get an idea about it, because there is only 1 single screenshot.
     
  39. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    You can find more information about the general concepts of the kit here. The default setup is to have a single master server and as many zone servers as needed. Zone servers are responsible for spawning the actual game server instances based on players requesting new games. When a player searches for existing games, he will get a list of all the registered game servers matching the filter criteria. The default information per game server includes things like the server's unique id, name, size, room properties, etc.

    More advanced features like load balancing and server replication, which depend more on the actual stack the server is deployed to, are not included in the kit but can always be added on top of it.
     
  40. Ghetaldus

    Ghetaldus

    Joined:
    Jul 15, 2017
    Posts:
    46
    +1 for Mirror support.
     
  41. errorsevendev

    errorsevendev

    Joined:
    Sep 29, 2016
    Posts:
    8
    Love MSK!
    I have 1 issue though that I cannot figure out.
    My game on some devices takes a while to load the game scene, so sometimes on this device by the time the player has loaded the scene the gameserver has disconnected them and they are directed back to the lobby scene..
    is there a timeout setting somewhere for this?

    This happens also where other players are already playing so it is not "CloseWhenEmptyService()".

    Thanks
     
    Last edited: May 13, 2019
  42. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    Please use our official contact form for support questions. Thank you!
     
  43. hottabych

    hottabych

    Joined:
    Apr 18, 2015
    Posts:
    107
    It must be not so difficult to support Mirror, because it's basically the UNet fork maintained by community. To port UNet project to Mirror you should swap all the UNet components to the same Mirror components, and change the line "using UnityEngine.Networking;" to "using Mirror;" in all networking scripts. You can use #ifdef MIRROR to check if Mirror is installed in the project. Not tested it tho.
     
  44. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    That is actually not the case, as Mirror removes several classes used heavily by the kit.
     
  45. Cowboy_Jow

    Cowboy_Jow

    Joined:
    Jan 12, 2014
    Posts:
    20
    I am getting this error. I don't get this if i switch the scripting runtime version to .net 3.5 equivalent. is there a way i can get this to work with .net 4.x equivalent?
    upload_2019-6-23_18-58-37.png
     
  46. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    Please use our official contact form for support questions. Thank you!
     
  47. Cowboy_Jow

    Cowboy_Jow

    Joined:
    Jan 12, 2014
    Posts:
    20
    Does this use unity's transport layer? if not would it be difficult to implement?
     
  48. gamevanilla

    gamevanilla

    Joined:
    Dec 28, 2015
    Posts:
    968
    It does not; it mainly uses UNET network messages. I am not personally familiar with the transport layer, so cannot answer how difficult it would be.
     
  49. iLawn

    iLawn

    Joined:
    Apr 16, 2013
    Posts:
    16
    +1 for Mirror support
     
    Gabo_campitelli likes this.
  50. Gabo_campitelli

    Gabo_campitelli

    Joined:
    Oct 17, 2012
    Posts:
    426
    I was just about to ask about Mirror support. I guess it's not compatible?
     
Thread Status:
Not open for further replies.