Legacy Documentation: Version 5.4
LanguageEnglish
  • C#
  • JS

Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

NetworkLobbyManager.lobbyPlayerPrefab

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Sumbission failed

For some reason your suggested change could not be submitted. Please try again in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

public var lobbyPlayerPrefab: Networking.NetworkLobbyPlayer;
public Networking.NetworkLobbyPlayer lobbyPlayerPrefab;

Description

This is the prefab of the player to be created in the LobbyScene.

This prefab must have a NetworkLobbyPlayer component on it.

In the lobby scene, this will be the active player object, but in other scenes while the game is running, this will be replaced by a player object created from the GamePlayerPrefab. But once returned to the lobby scene this will again become the active player object.

This can be used to store user data that persists for the lifetime of the session, such as color choices or weapon choices.