unreal.MultiUserSubsystem

class unreal.MultiUserSubsystem(outer: Object | None = None, name: Name | str = 'None')

Bases: EngineSubsystem

Multi User Subsystem

C++ Source:

  • Plugin: MultiUserClient

  • Module: MultiUserClientLibrary

  • File: MultiUserSubsystem.h

Editor Properties: (see get_editor_property/set_editor_property)

  • on_session_client_changed (OnSessionClientChanged): [Read-Write] Invoked when information about a client changes while the local editor instance is in a session. For example: other clients joining and leaving the session.

  • on_session_connected (OnSessionConnected): [Read-Write] Invoked when the local editor instance has joined a session.

  • on_session_disconnected (OnSessionDisconnected): [Read-Write] Invoked when the local editor instanced has left a session.

get_local_client_id() Guid or None

If connected to a session, gets the endpoint identifiers of client corresponding to the local editor instance.

Returns:

Whether OutClientId contains a valid identifiers.

out_client_id (Guid):

Return type:

Guid or None

get_remote_client_ids() Array[Guid] or None

If connected to a session, gets the endpoint identifiers of all remote clients.

Returns:

Whether OutRemoteClientIds contains the remote client endpoint identifiers.

out_remote_client_ids (Array[Guid]):

Return type:

Array[Guid] or None

is_connected_to_session() bool

Returns true if we are currently in a session.

Return type:

bool

property on_session_client_changed: OnSessionClientChanged

[Read-Write] Invoked when information about a client changes while the local editor instance is in a session. For example: other clients joining and leaving the session.

Type:

(OnSessionClientChanged)

property on_session_connected: OnSessionConnected

[Read-Write] Invoked when the local editor instance has joined a session.

Type:

(OnSessionConnected)

property on_session_disconnected: OnSessionDisconnected

[Read-Write] Invoked when the local editor instanced has left a session.

Type:

(OnSessionDisconnected)

register_custom_event_handler(event_type, event_handler) bool

Register an event handler for the given type. Only one handler per type is allowed. You should register your handler on session connected and remove the handler when the session disconnects.

Parameters:
Returns:

true if the type handler was accepted.

Return type:

bool

unregister_custom_event_handler(event_type) bool

Unregister an event handler for the given type.

Parameters:

event_type (Struct) – The struct type that we support handling.

Returns:

true if the type handler was successfully unregistered.

Return type:

bool