Click or drag to resize

LobbyManager Methods

The GameLiftManagerLobbyManager type exposes the following members.

Methods
  NameDescription
Private methodActionConnectToServer
Connects this user to a GameLift sever
Private methodAddErrorText
Adds text to the error text, allowing the user to know if an error occurred during connection
Public methodAddPlayerToMatch
Adds a player to the match
Private methodAddPotentialSession
Adds a potential game session to the available session screen as a button to select and thus join with
Public methodAllowReadyUp
Allows users to ready up
Private methodAutoConnect
When the servers are down, this function will ping them every 30 seconds until a connection can occur.
Private methodChangeInteractablility
Allows a button's interactability to be changed on the main Unity thread
Private methodCheckPorts
Looks for an available port for the android device to use by attempting a connection to it
Private methodCheckUsernameAvailability
Checks if the username the user entered is currently being used by another user. If it is - then they are prompted to enter a different username. If not, they can then host or find a session to join.
Private methodChooseToFindSessions
Sets the UI panel to the available sessions screen, destroys any old matches found, and searches for new matches
Private methodChooseToHostSession
Sets the UI panel to the HostMenu screen
Private methodConnectToServer
Connects to a GameLift server
Private methodDestroyMatchOptions
Destroys any match options locally so that they are not repeated to the user
Private methodFindAvailableUDPPort
Finds an available UDP port on the user's end to receive UDP messages on. It should be noted that this function cannot be called on Android, and therefore, only 1 port is available on Android, the default UDP port of 33400. If this port is not available, then that Android device will not be able to receive UDP messages, which ASL does not currently send anyways.
Private methodGetAvailableScenes
Gets the available scenes that the user can host. Due to limitations on Unity's end, this function is only useful if it is being called inside the editor. In order to see your scene when running an EXE version, you must edit the AvailableScenes dropdown menu to include (or exclude) the scenes you want.
Public methodGoBack
Goes back to the last UI screen and cleans anything up that may have happened on the current UI screen
Private methodHostSession
Triggers the HostLambda function, allowing a user to host a game session
Private methodInitilizeUIElements
Initializes all of the UI elements that will be used in the lobby scene
Private methodInvokeHostLambda
Hosts a game via a lambda function for the user
Private methodInvokeJoinSessionLambda
Invokes the join session lambda function that allows this user to a join a selected game session
Private methodInvokeLockSessionLambda
Invokes the lambda function that locks the game session
Private methodInvokeQuickConnectLambda
Invokes the QuickConnect lambda function which looks for a game, if none found, then creates a game for the user. Allowing them to bypass the host/search for game method
Private methodInvokeSearchForSessionsLambda
Invokes the lambda function that searches for available game sessions
Private methodInvokeUsernameLambda
Checks if the username the user entered is currently in any game sessions and if so, does not allow that username to be used again. By default, this lambda function will also set the desired active instances of the fleet being used to 1. It will do this regardless if the instance is already at 1 or if its at 0. This is because after no users after 30 minutes, the instance auto scales down to 0.
Public methodJoinSelectedMatch
Join the currently selected match
Private methodJoinSession
Joins a game session
Public methodLockSession
Locks the game session, preventing any other users from joining it
Public methodPlayerJoinedMatch
Is called when a player joins the match
Private methodQuickConnectMatch
Reduces the number of screens a user has to go through in order to connect to a match
Private methodReadyUp
Indicates that the user is ready for the first scene to being loading
Private methodRemoveErrorText
Clears any error text
Public methodReset
Private methodSearchForSessions
Triggers the search for available game sessions lambda function
Private methodSeePreviousUIScreen
Returns to the previous UI screen, triggered by hitting the back button
Private methodSetCorrectUIPanel
Sets the UI panel to be displayed to the user
Private methodSetGameName
Sets the game name to be displayed to users
Private methodSetQuickConnectFlag
Changes the value of the QuickConnect flag
Public methodStart
This function starts the scene by assigning all UI elements and is manually called by GameLiftManager's Start function as this class is not a MonoBehavior class and can't be.
Private methodStartAutoConnect
Used to start the auto connect coroutine
Public methodUpdateChatLog
Updates the chat log based on the message received
Private methodUpdateConnectionStatusText
Updates the connection status text based on the current connection status
Public methodUpdateLobbyScreen
Updates the lobby screen to show any new players
Private methodUpdateNewComer
Is called to update any new comers of who this user is
Private methodUpdateOtherUsers
Updates other users of this user's presence in the lobby
Private methodUpdateUsername
Updates the username of the user based on the username they selected
Top
See Also