Class NetworkSceneManager
This manages the scenes across the network.
You can only change the scene using the server.
On the client, it deals with the scene change packets.
When a client joins the server, it will always join into the active scene.
If building a party game, ensure the main scene is the lobby.
Inheritance
NetworkSceneManager
Assembly: FNNLib.dll
Syntax
public static class NetworkSceneManager
Properties
|
Improve this Doc
View Source
loadedSceneCount
Declaration
public static int loadedSceneCount { get; }
Property Value
|
Improve this Doc
View Source
mainSceneCount
Declaration
public static int mainSceneCount { get; }
Property Value
Methods
|
Improve this Doc
View Source
GetNetScene(Scene)
Declaration
public static NetworkScene GetNetScene(Scene scene)
Parameters
| Type |
Name |
Description |
| Scene |
scene |
|
Returns
|
Improve this Doc
View Source
GetNetScene(UInt32)
Declaration
public static NetworkScene GetNetScene(uint netID = 0U)
Parameters
| Type |
Name |
Description |
| UInt32 |
netID |
|
Returns
|
Improve this Doc
View Source
GetSceneNetID(Scene)
Declaration
public static uint GetSceneNetID(Scene scene)
Parameters
| Type |
Name |
Description |
| Scene |
scene |
|
Returns
|
Improve this Doc
View Source
LoadScene(String, LoadSceneMode, LoadSceneMode, List<UInt64>)
Declaration
public static NetworkScene LoadScene(string sceneName, LoadSceneMode serverMode = null, LoadSceneMode clientMode = null, List<ulong> clientsToLoadFor = null)
Parameters
| Type |
Name |
Description |
| String |
sceneName |
The scene name.
|
| LoadSceneMode |
serverMode |
The mode to load with on the server.
|
| LoadSceneMode |
clientMode |
he mode to load with on the client.
|
| List<UInt64> |
clientsToLoadFor |
The clients to load the scene for, or null for all clients.
|
Returns
|
Improve this Doc
View Source
LoadSceneOnClient(UInt64, UInt32)
Tell a client to load a scene that already exists on the server
Declaration
public static void LoadSceneOnClient(ulong clientID, uint networkID)
Parameters
|
Improve this Doc
View Source
LoadSceneOnClients(List<UInt64>, UInt32)
Tells a list of clients to load a scene that already exists on the server
Declaration
public static void LoadSceneOnClients(List<ulong> clientIDs, uint networkID)
Parameters
|
Improve this Doc
View Source
MoveNetworkObjectToScene(NetworkIdentity, NetworkScene)
Declaration
public static void MoveNetworkObjectToScene(NetworkIdentity identity, NetworkScene scene)
Parameters
|
Improve this Doc
View Source
MoveNetworkObjectToScene(NetworkIdentity, UInt32)
Declaration
public static void MoveNetworkObjectToScene(NetworkIdentity identity, uint sceneNetworkID)
Parameters
|
Improve this Doc
View Source
UnloadSceneAsync(UInt32, UInt32)
Unload a subscene, redirecting any present clients to the fallback scene.
Declaration
public static AsyncOperation UnloadSceneAsync(uint netID, uint fallbackScene)
Parameters
Returns
| Type |
Description |
| AsyncOperation |
|