Class NetworkServer
Inherited Members
UnitySingleton<NetworkServer>.ShouldNotDestroyOnLoad
UnitySingleton<NetworkServer>.Instance
UnitySingleton<NetworkServer>.OnDestroy()
Namespace: Xareus.Scenarios.Network.Unity
Assembly: Xareus.Scenarios.Unity.dll
Syntax
public class NetworkServer : UnitySingleton<NetworkServer>
Fields
OverridePort
Use this to override the serverPort before the server is created
Declaration
public static int OverridePort
Field Value
Type | Description |
---|---|
int |
serverPort
The port used by the server
Declaration
public int serverPort
Field Value
Type | Description |
---|---|
int |
Methods
Dispose()
Declaration
public void Dispose()
Dispose(bool)
Declaration
protected virtual void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
bool | disposing |
IsReady()
Is the secen network manager ready to be used?
Declaration
public bool IsReady()
Returns
Type | Description |
---|---|
bool |
|
OnApplicationQuit()
When Unity quits, it destroys objects in a random order. In principle, a Singleton is only destroyed when application quits. If any script calls Instance after it have been destroyed, it will create a buggy ghost object that will stay on the Editor scene even after stopping playing the Application. Really bad! So, this was made to be sure we're not creating that buggy ghost object.
Declaration
public override void OnApplicationQuit()
Overrides
Hybrid.Tools.UnitySingleton<Xareus.Scenarios.Network.Unity.NetworkServer>.OnApplicationQuit()