menu_bookDocumentation

IGameObjectNetworkEvents: StartControl, StopControl, and NetworkOwnerChanged Callbacks

calendar_today May 4, 2026 schedule ~1 min read person patrickjr verified 50

IGameObjectNetworkEvents: Ownership Change Callbacks

Implement IGameObjectNetworkEvents on a component to receive callbacks when network ownership of the parent GameObject changes.

Interface Methods

CSHARP
public interface IGameObjectNetworkEvents : ISceneEvent<IGameObjectNetworkEvents>
{
    // Called when the owner changes (any direction)
    void NetworkOwnerChanged( Connection newOwner, Connection previousOwner ) { }

    // We have become the controller — no longer a proxy
    void StartControl() { }

    // We have become a proxy — someone else controls this
    void StopControl() { }
}

Usage

CSHARP
public class MyComponent : Component, IGameObjectNetworkEvents
{
    void IGameObjectNetworkEvents.StartControl()
    {
        // We now own this object — enable local simulation
        Log.Info( "I am now in control" );
    }

    void IGameObjectNetworkEvents.StopControl()
    {
        // We lost control — disable local simulation
        Log.Info( "I am now a proxy" );
    }

    void IGameObjectNetworkEvents.NetworkOwnerChanged( Connection newOwner, Connection previousOwner )
    {
        Log.Info( $"Owner changed from {previousOwner?.DisplayName} to {newOwner?.DisplayName}" );
    }
}

When StartControl / StopControl Fire

IsProxy

Component.IsProxy (and GameObject.IsProxy) returns true when the local client does not own the object. Use this to skip local simulation on proxies.
Was this helpful?