User Data

User Class

The User class handles interactions user logins and logoffs.

Syntax

Member Details

AddUser Field

For subscribing to events for users entering the scene

Syntax

public static readonly stringarrow-up-right AddUser

Remarks

Requirements

Namespace: Sansar.Simulation Assembly: Sansar.Simulation (in Sansar.Simulation.dll) Assembly Versions: 1.1.0.0


RemoveUser Field

For subscribing to events for users leaving the scene

Syntax

public static readonly stringarrow-up-right RemoveUser

Remarks

Requirements

Namespace: Sansar.Simulation Assembly: Sansar.Simulation (in Sansar.Simulation.dll) Assembly Versions: 1.1.0.0


Subscribe Method

Subscribes to User Events.

Syntax

[Sansar.Script.Interface] [System.Obsolete("Use subscription callbacks of type Action<Sansar.Simulation.UserData>", false)] public voidarrow-up-right Subscribe (stringarrow-up-right Action, User.SubscriptionHandlerarrow-up-right callback, boolarrow-up-right persistent)

Parameters

Action

string action of the event: AddUser, RemoveUser

callback

Callback which is executed when the event completes.

persistent

Optional, set to false to unsubscribe after one event.

Remarks

Requirements

Namespace: Sansar.Simulation Assembly: Sansar.Simulation (in Sansar.Simulation.dll) Assembly Versions: 1.1.0.0


Subscribe Method

Subscribes to User Events.

Syntax

See Also

Parameters

Action

string action of the event: AddUser, RemoveUser

callback

Callback which is executed when the event completes.

persistent

Optional, set to false to unsubscribe after one event.

Returns

An Sansar.Script.IEventSubscription that can be used to cancel the subscription.

Remarks

Requirements

Namespace: Sansar.Simulation Assembly: Sansar.Simulation (in Sansar.Simulation.dll) Assembly Versions: 1.1.0.0


Subscribe Method

Subscribes to User Events.

Syntax

Parameters

Action

string action of the event: AddUser, RemoveUser

User

Sansar.Script.SessionId for the user.

callback

Callback which is executed when the event completes.

persistent

Optional, set to false to unsubscribe after one event.

Remarks

Requirements

Namespace: Sansar.Simulation Assembly: Sansar.Simulation (in Sansar.Simulation.dll) Assembly Versions: 1.1.0.0


Subscribe Method

Subscribes to User Events.

Syntax

See Also

Parameters

Action

string action of the event: AddUser, RemoveUser

User

Sansar.Script.SessionId for the user.

callback

Callback which is executed when the event completes.

persistent

Optional, set to false to unsubscribe after one event.

Returns

An Sansar.Script.IEventSubscription that can be used to cancel the subscription.

Remarks

Requirements

Namespace: Sansar.Simulation Assembly: Sansar.Simulation (in Sansar.Simulation.dll) Assembly Versions: 1.1.0.0


User.SubscriptionHandler Delegate

Subscribe to receive events when users enter or leave the experience, or change their chat name.

Syntax

[Sansar.Script.Interface] [System.Obsolete("Use subscription callbacks of type Action<Sansar.Simulation.UserData>", false)] public delegate voidarrow-up-right User.SubscriptionHandler (stringarrow-up-right Action, Sansar.Script.SessionIdarrow-up-right User, stringarrow-up-right Data)

Parameters

Action

string action of the event: AddUser, RemoveUser

User

Sansar.Script.SessionId for the user.

Data

Deprecated.

Remarks

Requirements

Namespace: Sansar.Simulation Assembly: Sansar.Simulation (in Sansar.Simulation.dll) Assembly Versions: 1.1.0.0

UserData Class

Subscribe to receive events when users enter or leave the experience.

Syntax

Member Details

Action Property

string action of the event: AddUser, RemoveUser

Syntax

[get: Sansar.Script.Interface] public stringarrow-up-right Action { get; }

Value

Remarks

Requirements

Namespace: Sansar.Simulation Assembly: Sansar.Simulation (in Sansar.Simulation.dll) Assembly Versions: 1.1.0.0


Data Property

Deprecated.

Syntax

[get: Sansar.Script.Interface] public stringarrow-up-right Data { get; }

Value

Remarks

Requirements

Namespace: Sansar.Simulation Assembly: Sansar.Simulation (in Sansar.Simulation.dll) Assembly Versions: 1.1.0.0


ToString Method

A string representation of this object.

Syntax

[Sansar.Script.Interface] public override stringarrow-up-right ToString ()

Returns

A string representation of this object.

Remarks

Requirements

Namespace: Sansar.Simulation Assembly: Sansar.Simulation (in Sansar.Simulation.dll) Assembly Versions: 1.1.0.0


User Property

Sansar.Script.SessionId for the user.

Syntax

Value

Remarks

Requirements

Namespace: Sansar.Simulation Assembly: Sansar.Simulation (in Sansar.Simulation.dll) Assembly Versions: 1.1.0.0


Last updated