Lobby System.

Lobby System

The HighRoad Engine implements a complete lobby management solution, whether it’s for local players or players playing online via Unity’s UNET Networking HLAPI.

Local mode

Local Lobby TinyCars scene

Local mode allows you to easily setup a 1 to 4 players lobby. The lobby parameters must be specified on the LocalLobbyManager’s inspector that will be in charge of managing players, them joining the game, what choices they make and when they’re ready to play.

LocalLobby inspector
LocalLobby inspector
  • Lobby Parameters : Type here the name of the scene containing the Local Lobby.
  • Vehicle Configuration : Drag and drop here the prefabs of the vehicles that will be selectable by the player. Each prefab must have a VehicleInformation component.
  • Tracks Configuration : This double array contains the name of each track (the name of the scene) as well as the sprite associated to that track.

Online mode

The Online mode is based on Unity’s UNET classes and extends the NetworkLobbyManager class to allow for a full, easier to extend experience. To setup UNET, please check out the Network documentation.

OnlineLobby Aphex scene

GUI management is also included in the asset for all possible situations: matchmaking, direct connection, players joining a server, state display, vehicle choices, selected track.

OnlineLobby Aphex inspector

Most properties come from Unity’s NetworkManager. HighRoad Engine’s needed specific values are:

  • LobbyScene : the name of the scene containing the OnlineLobby
  • GUI : a reference to the GUI object (the one with the OnlineLobbyUI component)
  • Vehicle Configuration : Drag and drop here the prefabs of the vehicles that will be selectable by the player. Each prefab must have a VehicleInformation and a NetworkIdentity components.
  • Tracks Configuration : This double array contains the name of each track (the name of the scene) as well as the sprite associated to that track.