Client

Client Class

The Client class is used for access to the Client connected to a Sansar.Simulation.AgentPrivate.

Syntax

[Sansar.Script.Interface]
public class Client : Sansar.Script.InstanceInterface

Remarks

This class is also used for receiving input events from a client.

Requirements

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

Members

See Also: Inherited members from Sansar.Script.InstanceInterface.

Public Properties

[read-only]
 
AgentInfo AgentInfo . Returns the Sansar.Simulation.AgentInfo for this instance.
[read-only]
 
IsValid bool . Whether or not this interface is valid. (Inherited from Sansar.Script.InstanceInterface.)
[read-only]
 
UI UI . Returns the Sansar.Simulation.UI for this instance.

Public Methods

 
SendChat (string)
Sends a string message to the Client.
 
SubscribeToCommand (string, Action<CommandData>, Action<Sansar.Script.CancelData>, bool) : Sansar.Script.IEventSubscription
Subscribes to Command Events.
 
SubscribeToCommand (string, CommandAction, Action<CommandData>, Action<Sansar.Script.CancelData>, bool) : Sansar.Script.IEventSubscription
Subscribes to Command Events.
 
TeleportToLocation (string, string)
Teleports the personaHandle to the locationHandle.
override
ToString () : string
A string representation of this object.

Member Details

AgentInfo Property

Returns the Sansar.Simulation.AgentInfo for this instance.

Syntax

[get: Sansar.Script.Interface]
public AgentInfo AgentInfo { get; }

Value

The Sansar.Simulation.AgentInfo for this instance

Remarks

The Sansar.Simulation.AgentInfo holds information about an agent.

Requirements

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

SendChat Method

Sends a string message to the Client.

Syntax

[Sansar.Script.Interface]
public void SendChat (string message)

Parameters

message
The message to send.

Remarks

Messages may be throttled and ignored.

Requirements

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

SubscribeToCommand Method

Subscribes to Command Events.

Syntax

[Sansar.Script.Interface]
public Sansar.Script.IEventSubscription SubscribeToCommand (string Command, Action<CommandData> callback, Action<Sansar.Script.CancelData> canceled, bool persistent)

See Also

Parameters

Command
The command which occurred.
callback
Callback which is executed when the event completes.
canceled
Callback which is executed when the subscription is canceled.
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

SubscribeToCommand Method

Subscribes to Command Events.

Syntax

[Sansar.Script.Interface]
public Sansar.Script.IEventSubscription SubscribeToCommand (string Command, CommandAction Action, Action<CommandData> callback, Action<Sansar.Script.CancelData> canceled, bool persistent)

See Also

Parameters

Command
The command which occurred.
Action
The action which occurred.
callback
Callback which is executed when the event completes.
canceled
Callback which is executed when the subscription is canceled.
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

TeleportToLocation Method

Teleports the personaHandle to the locationHandle.

Syntax

[Sansar.Script.Interface]
public void TeleportToLocation (string avatarId, string locationHandle)

Parameters

avatarId
The SceneInfo.AvatarId to teleport.
locationHandle
The SceneInfo.LocationHandle of the destination.

Remarks

Teleports may be throttled.

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 string ToString ()

Returns

A string representation of this object.

Remarks

The format of this string may change between releases.

Requirements

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

UI Property

Returns the Sansar.Simulation.UI for this instance.

Syntax

[get: Sansar.Script.Interface]
public UI UI { get; }

Value

The Sansar.Simulation.UI for this instance

Remarks

The Sansar.Simulation.UI for this instance.

Requirements

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


Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

0 Comments

Article is closed for comments.