s&box docs

public class Sandbox.GameObject.NetworkAccessor

Constructors

Showing 1 constructors

Methods

Showing 13 methods

public bool AssignOwnership(Sandbox.Connection channel)

Set the owner of this object to the specified `Sandbox.Connection`. Note: whether you can assign ownership of this object depends on the `Sandbox.GameObject.NetworkAccessor.OwnerTransfer` of this networked object.

Exceptions

ExceptionCondition
ArgumentNullException`channel` cannot be null. To clear owner, use `Sandbox.GameObject.NetworkAccessor.DropOwnership` instead.

public bool ClearInterpolation()

public bool DisableInterpolation()Obsolete

Disable interpolation for the networked object's transform. Obsolete: 09/12/2025

Obsolete: Use Interpolation Property

public bool DropOwnership()

Stop being the owner of this object. Will clear the owner so the object becomes controlled by the server, and owned by no-one. Note: whether you can drop ownership of this object depends on the `Sandbox.GameObject.NetworkAccessor.OwnerTransfer` of this networked object.

public bool EnableInterpolation()Obsolete

Enable interpolation for the networked object's transform. Obsolete: 09/12/2025

Obsolete: Use Interpolation Property

public bool SetOrphanedMode(Sandbox.NetworkOrphaned action)

Set what happens to this networked object when the owner disconnects.

public bool SetOwnerTransfer(Sandbox.OwnerTransfer option)

Set who can control ownership of this networked object. Only the current owner can change this.

public bool TakeOwnership()

Become the network owner of this object. Note: whether you can take ownership of this object depends on the `Sandbox.GameObject.NetworkAccessor.OwnerTransfer` of this networked object.

Properties

Showing 14 properties

public bool Sandbox.GameObject.NetworkAccessor.AlwaysTransmit { get; set; }

Determines whether updates for this networked object are always transmitted to clients. Otherwise, they are only transmitted when the object is determined as visible to each client.

public Sandbox.NetworkFlags Sandbox.GameObject.NetworkAccessor.Flags { get; set; }

Network flags which describe the behavior of this networked object. Can only be changed by the host after the networked object has been spawned.

public bool Sandbox.GameObject.NetworkAccessor.Interpolation { get; set; }

Whether the networked object's transform is interpolated.

public bool Sandbox.GameObject.NetworkAccessor.IsProxy { get; set; }

Is this object a network proxy? A network proxy is a network object that is not being simulated on the local pc. This means it's either owned by no-one and is being simulated by the host or owned by another client.

public Sandbox.Connection Sandbox.GameObject.NetworkAccessor.Owner { get; set; }

Try to get the connection that owns this object. This can and will return null if we don't have information for this connection.

public Sandbox.Connection Sandbox.GameObject.NetworkAccessor.OwnerConnection { get; set; }Obsolete

Try to get the connection that owns this object. This can and will return null if we don't have information for this connection.

Obsolete: Moved to Owner

Metadata

FieldValue
Namespaceglobal
Typeclass
AssemblySandbox.Engine
Doc IDT:Sandbox.GameObject.NetworkAccessor

On this page

Constructorspublic NetworkAccessor(Sandbox.GameObject o)Methodspublic System.Boolean AssignOwnership(Sandbox.Connection channel)public System.Boolean ClearInterpolation()public System.Boolean DisableInterpolation()public System.Boolean DropOwnership()public System.Boolean EnableInterpolation()public System.Void Refresh()public System.Void Refresh(Sandbox.Component component)public System.Void Refresh(Sandbox.GameObject descendent)public System.Boolean SetOrphanedMode(Sandbox.NetworkOrphaned action)public System.Boolean SetOwnerTransfer(Sandbox.OwnerTransfer option)public System.Boolean Spawn()public System.Boolean Spawn(Sandbox.Connection owner)public System.Boolean TakeOwnership()Propertiespublic System.Boolean Sandbox.GameObject.NetworkAccessor.Active { get; set; }public System.Boolean Sandbox.GameObject.NetworkAccessor.AlwaysTransmit { get; set; }public System.Guid Sandbox.GameObject.NetworkAccessor.CreatorId { get; set; }public Sandbox.NetworkFlags Sandbox.GameObject.NetworkAccessor.Flags { get; set; }public System.Boolean Sandbox.GameObject.NetworkAccessor.Interpolation { get; set; }public System.Boolean Sandbox.GameObject.NetworkAccessor.IsCreator { get; set; }public System.Boolean Sandbox.GameObject.NetworkAccessor.IsOwner { get; set; }public System.Boolean Sandbox.GameObject.NetworkAccessor.IsProxy { get; set; }public Sandbox.NetworkOrphaned Sandbox.GameObject.NetworkAccessor.NetworkOrphaned { get; set; }public Sandbox.Connection Sandbox.GameObject.NetworkAccessor.Owner { get; set; }public Sandbox.Connection Sandbox.GameObject.NetworkAccessor.OwnerConnection { get; set; }public System.Guid Sandbox.GameObject.NetworkAccessor.OwnerId { get; set; }public Sandbox.OwnerTransfer Sandbox.GameObject.NetworkAccessor.OwnerTransfer { get; set; }public Sandbox.GameObject Sandbox.GameObject.NetworkAccessor.RootGameObject { get; set; }Metadata