Description
The NetworkMode.Never
field is a member of the NetworkMode
enumeration in the Sandbox API. It specifies that a GameObject
should never be networked. This means that the object will not be synchronized across the network and will only exist locally on the client where it was created.
Usage
Use NetworkMode.Never
when you want a GameObject
to remain local to the client and not be affected by network synchronization. This is useful for objects that do not need to be shared with other clients, such as local UI elements or client-specific effects.
Example
// Example of setting a GameObject's network mode to Never
GameObject myLocalObject = new GameObject();
myLocalObject.NetworkMode = NetworkMode.Never;
// This object will not be networked and will only exist on the local client.