ScenePrivate Class
Interface for Scripts that are part of a Scene. A more complete and less limited API than Sansar.Simulation.ScenePublic
Syntax
[Sansar.Script.Interface]
public class ScenePrivate : Sansar.Script.InstanceInterface
public class ScenePrivate : Sansar.Script.InstanceInterface
Remarks
The ScenePrivate class provides services relating to the Scene.
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
Members
See Also: Inherited members from Sansar.Script.InstanceInterface.
Public Fields
static readonly
|
GravityMaximum | float . The maximum gravity magnitude in m/s^2, which is equal to 49.05 or 5 G's. |
static readonly
|
GravityMinimum | float . The minimum allowed gravity magnitude in m/s^2, which is equal to zero. |
static readonly
|
MaximumCastRayResults | int . The maximum number of results returned from a ., . or . call. Anything over this will be truncated. |
static readonly
|
MinimumCastRadius | float . The minimum radius for a . call or minimum half extents for .. Any value smaller than this will use . instead. |
Public Properties
[read-only] | AgentCount | uint . The number of agents in the Scene. |
[read-only] | Chat | Chat . Gets the Chat interface for this Scene |
[read-only] | DefaultGravity | float . The default gravity magnitude in the scene in m/s^2, which is equal to 9.81 or 1 G. |
[read-only] | HttpClient | HttpClient . Gets the HttpClient for this Scene |
[read-only] | IsValid | bool . Whether or not this interface is valid. (Inherited from Sansar.Script.InstanceInterface.) |
[read-only] | SceneInfo | SceneInfo . Gets the SceneInfo for this Scene |
[read-only] | User | User . Gets the User interface for this Scene |
Public Methods
CastBox (Sansar.Vector, Sansar.Vector, Sansar.Vector) : RayCastHit[]
Casts a box from start to end and returns an array of collisions along the path. |
||
CastBox (Sansar.Vector, Sansar.Quaternion, Sansar.Vector, Sansar.Vector) : RayCastHit[]
Casts a box from start to end and returns an array of collisions along the path. |
||
CastBox (Sansar.Vector, Sansar.Vector, Sansar.Vector, int) : RayCastHit[]
Casts a box from start to end and returns an array of collisions along the path. |
||
CastBox (Sansar.Vector, Sansar.Quaternion, Sansar.Vector, Sansar.Vector, int) : RayCastHit[]
Casts a box from start to end and returns an array of collisions along the path. |
||
CastCapsule (Sansar.Vector, Sansar.Vector, float, Sansar.Vector, Sansar.Vector) : RayCastHit[]
Casts a capsule from start to end and returns an array of collisions along the path. |
||
CastCapsule (Sansar.Vector, Sansar.Vector, float, Sansar.Quaternion, Sansar.Vector, Sansar.Vector) : RayCastHit[]
Casts a capsule from start to end and returns an array of collisions along the path. |
||
CastCapsule (Sansar.Vector, Sansar.Vector, float, Sansar.Vector, Sansar.Vector, int) : RayCastHit[]
Casts a capsule from start to end and returns an array of collisions along the path. |
||
CastCapsule (Sansar.Vector, Sansar.Vector, float, Sansar.Quaternion, Sansar.Vector, Sansar.Vector, int) : RayCastHit[]
Casts a capsule from start to end and returns an array of collisions along the path. |
||
CastRay (Sansar.Vector, Sansar.Vector) : RayCastHit[]
Casts a ray from start to end and returns an array of collisions along the path. |
||
CastRay (Sansar.Vector, Sansar.Vector, int) : RayCastHit[]
Casts a ray from start to end and returns an array of collisions along the path. |
||
CastSphere (float, Sansar.Vector, Sansar.Vector) : RayCastHit[]
Casts a sphere from start to end and returns an array of collisions along the path. |
||
CastSphere (float, Sansar.Vector, Sansar.Vector, int) : RayCastHit[]
Casts a sphere from start to end and returns an array of collisions along the path. |
||
CreateCluster (ClusterResource, Sansar.Vector, Sansar.Quaternion, Sansar.Vector) : ulong
Creates a new cluster and adds it to the Scene. |
||
CreateCluster (ClusterResource, Sansar.Vector, Sansar.Quaternion, Sansar.Vector, ScenePrivate.CreateClusterHandler) : ulong
Creates a new cluster and adds it to the Scene. |
||
CreateCluster (ClusterResource, Sansar.Vector, Sansar.Quaternion, Sansar.Vector, Action<ScenePrivate.CreateClusterData>)
Creates a new cluster and adds it to the Scene. |
||
FindAgent (Sansar.Script.ObjectId) : AgentPrivate
Looks up an Agent associated with the given object id. |
||
FindAgent (Sansar.Script.SessionId) : AgentPrivate
Looks up an Agent associated with the given session id if they are in the scene. |
||
FindAgent (Guid) : AgentPrivate
Looks up an Agent associated with the given persona id, if they are in the scene. |
||
FindObject (Sansar.Script.ObjectId) : ObjectPrivate
Looks up a Object associated with the given object id. |
||
FindReflective<TInterface> (string) : IEnumerable<TInterface>
Looks up Reflective objects in the scene that match the interface type by class name. |
||
FindScript (Sansar.Script.ScriptId) : object
Looks up the script object associated with the given scriptId |
||
GetAgent (uint) : AgentPrivate
Get an Sansar.Simulation.AgentPrivate for a specific agent in the Scene. |
||
GetAgents () : IEnumerable<AgentPrivate>
Returns the current list of Agents in the Scene. |
||
GetBoxClosestPoints (Sansar.Vector, Sansar.Vector, float) : RayCastHit[]
Extends a box with the given half extents the maximum distance and returns any hits. |
||
GetBoxClosestPoints (Sansar.Vector, Sansar.Vector, Sansar.Quaternion, float) : RayCastHit[]
Extends a box with the given half extents the maximum distance and returns any hits. |
||
GetBoxClosestPoints (Sansar.Vector, Sansar.Vector, float, int) : RayCastHit[]
Extends a box with the given half extents the maximum distance and returns any hits. |
||
GetBoxClosestPoints (Sansar.Vector, Sansar.Vector, Sansar.Quaternion, float, int) : RayCastHit[]
Extends a box with the given half extents the maximum distance and returns any hits. |
||
GetCapsuleClosestPoints (Sansar.Vector, Sansar.Vector, float, Sansar.Vector, float) : RayCastHit[]
Extends a capsule with the given parameters the maximum distance and returns any hits. |
||
GetCapsuleClosestPoints (Sansar.Vector, Sansar.Vector, float, Sansar.Vector, Sansar.Quaternion, float) : RayCastHit[]
Extends a capsule with the given parameters the maximum distance and returns any hits. |
||
GetCapsuleClosestPoints (Sansar.Vector, Sansar.Vector, float, Sansar.Vector, float, int) : RayCastHit[]
Extends a capsule with the given parameters the maximum distance and returns any hits. |
||
GetCapsuleClosestPoints (Sansar.Vector, Sansar.Vector, float, Sansar.Vector, Sansar.Quaternion, float, int) : RayCastHit[]
Extends a capsule with the given parameters the maximum distance and returns any hits. |
||
GetGravity () : float
Gets the scene's current acceleration of gravity in m/s^2. |
||
GetPortalCreatorName (Sansar.Script.ObjectId) : string
The name of the user who created the specified portal. |
||
GetPortalDescription (Sansar.Script.ObjectId) : string
Description for the specified portal. |
||
GetPortalUri (Sansar.Script.ObjectId) : string
URI destination for the specified portal. |
||
GetSphereClosestPoints (float, Sansar.Vector, float) : RayCastHit[]
Extends a sphere with the given radius the maximum distance and returns any hits. |
||
GetSphereClosestPoints (float, Sansar.Vector, float, int) : RayCastHit[]
Extends a sphere with the given radius the maximum distance and returns any hits. |
||
OverrideAudioStream (string)
Overrides source of web audio streams. |
||
OverrideAudioStream (string, Action<Sansar.Script.OperationCompleteEvent>)
Overrides source of web audio streams. |
||
OverrideMediaSource (string)
Sets stream channel source. |
||
OverrideMediaSource (string, int, int)
Overrides source of media surfaces. |
||
OverrideMediaSource (string, int, int, Action<Sansar.Script.OperationCompleteEvent>)
Overrides source of media surfaces. |
||
PerformMediaAction (MediaAction)
Performs a specific action on the current media surface. |
||
PerformMediaAction (MediaAction, Action<Sansar.Script.OperationCompleteEvent>)
Performs a specific action on the current media surface. |
||
PlaySound (SoundResource, PlaySettings) : PlayHandle
Play sound to direct output. |
||
PlaySoundAtPosition (SoundResource, Sansar.Vector, PlaySettings) : PlayHandle
Play sound at specified position. |
||
PlayStream (StreamChannel, float) : PlayHandle
Play web audio stream to direct output. |
||
PlayStreamAtPosition (StreamChannel, Sansar.Vector, float) : PlayHandle
Play web audio stream at specified position. |
||
ResetScene ()
Restarts the Scene. |
||
SetGravity (float)
Sets the scene's current gravity acceleration in m/s^2. |
||
SetGravity (float, Sansar.Script.ScriptBase.OperationComplete) : ulong
Sets the scene's current gravity acceleration in m/s^2. |
||
SetGravity (float, Action<Sansar.Script.OperationCompleteEvent>)
Sets the scene's current gravity acceleration in m/s^2. |
||
SetMegaphone (AgentPrivate, bool)
Sets the megaphone status of the user. |
||
SetMegaphone (AgentPrivate, bool, Action<Sansar.Script.OperationCompleteEvent>)
Sets the megaphone status of the user. |
||
override
|
ToString () : string
A string representation of this object. |
|
VoiceBroadcastStart (AgentPrivate)
Start broadcasting agent's voice to the voice broadcast channel. |
||
VoiceBroadcastStop (AgentPrivate)
Stop broadcasting agent's voice to voice broadcast channel. |
||
VoiceBroadcastStopAll ()
Stop broadcasting all voices to voice broadcast channel. |
Member Details
AgentCount Property
The number of agents in the Scene.Syntax
[get: Sansar.Script.Interface]
public uint AgentCount { get; }Value
Unsigned integer count of the number of agents in the Scene.Remarks
This number changes when agents join and part.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastBox Method
Casts a box from start to end and returns an array of collisions along the path.Syntax
[Sansar.Script.Interface]
public RayCastHit[] CastBox (Sansar.Vector halfExtents, Sansar.Vector start, Sansar.Vector end)Parameters
- halfExtents
- The x,y,z distance from the center of the box to the corresponding face.
- start
- The initial point of the query.
- end
- The end point of the query.
Returns
Documentation for this section has not yet been entered.Remarks
If all 3 dimensions are less than ScenePrivate.MinimumCastRadius the call will be forwarded to . instead. maxHits defaults to 1 if unspecified and will return only the nearest hit.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastBox Method
Casts a box from start to end and returns an array of collisions along the path.Syntax
[Sansar.Script.Interface]
public RayCastHit[] CastBox (Sansar.Vector halfExtents, Sansar.Quaternion orientation, Sansar.Vector start, Sansar.Vector end)Parameters
- halfExtents
- The x,y,z distance from the center of the box to the corresponding face.
- orientation
- The orientation of the query shape.
- start
- The initial point of the query.
- end
- The end point of the query.
Returns
Documentation for this section has not yet been entered.Remarks
If all 3 dimensions are less than ScenePrivate.MinimumCastRadius the call will be forwarded to . instead.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastBox Method
Casts a box from start to end and returns an array of collisions along the path.Syntax
[Sansar.Script.Interface]
public RayCastHit[] CastBox (Sansar.Vector halfExtents, Sansar.Vector start, Sansar.Vector end, int maxHits)Parameters
- halfExtents
- The x,y,z distance from the center of the box to the corresponding face.
- start
- The initial point of the query.
- end
- The end point of the query.
- maxHits
- Limit the number of results returned.
Returns
Documentation for this section has not yet been entered.Remarks
If all 3 dimensions are less than ScenePrivate.MinimumCastRadius the call will be forwarded to . instead. maxHits defaults to 1 if unspecified and will return only the nearest hit.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastBox Method
Casts a box from start to end and returns an array of collisions along the path.Syntax
[Sansar.Script.Interface]
public RayCastHit[] CastBox (Sansar.Vector halfExtents, Sansar.Quaternion orientation, Sansar.Vector start, Sansar.Vector end, int maxHits)Parameters
- halfExtents
- The x,y,z distance from the center of the box to the corresponding face.
- orientation
- The orientation of the query shape.
- start
- The initial point of the query.
- end
- The end point of the query.
- maxHits
- Limit the number of results returned.
Returns
Documentation for this section has not yet been entered.Remarks
If all 3 dimensions are less than ScenePrivate.MinimumCastRadius the call will be forwarded to . instead.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastCapsule Method
Casts a capsule from start to end and returns an array of collisions along the path.Syntax
[Sansar.Script.Interface]
public RayCastHit[] CastCapsule (Sansar.Vector capsuleStart, Sansar.Vector capsuleEnd, float capsuleRadius, Sansar.Vector start, Sansar.Vector end)Parameters
- capsuleStart
- The base point of the capsule.
- capsuleEnd
- The end point of the capsule.
- capsuleRadius
- The radius of the capsule to query.
- start
- The initial point of the query.
- end
- The end point of the query.
Returns
Documentation for this section has not yet been entered.Remarks
If the radius and capsule length are less than ScenePrivate.MinimumCastRadius the call will be forwarded to . instead.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastCapsule Method
Casts a capsule from start to end and returns an array of collisions along the path.Syntax
[Sansar.Script.Interface]
public RayCastHit[] CastCapsule (Sansar.Vector capsuleStart, Sansar.Vector capsuleEnd, float capsuleRadius, Sansar.Quaternion orientation, Sansar.Vector start, Sansar.Vector end)Parameters
- capsuleStart
- The base point of the capsule.
- capsuleEnd
- The end point of the capsule.
- capsuleRadius
- The radius of the capsule to query.
- orientation
- The orientation of the query shape.
- start
- The initial point of the query.
- end
- The end point of the query.
Returns
Documentation for this section has not yet been entered.Remarks
If the radius and capsule length are less than ScenePrivate.MinimumCastRadius the call will be forwarded to . instead.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastCapsule Method
Casts a capsule from start to end and returns an array of collisions along the path.Syntax
[Sansar.Script.Interface]
public RayCastHit[] CastCapsule (Sansar.Vector capsuleStart, Sansar.Vector capsuleEnd, float capsuleRadius, Sansar.Vector start, Sansar.Vector end, int maxHits)Parameters
- capsuleStart
- The base point of the capsule.
- capsuleEnd
- The end point of the capsule.
- capsuleRadius
- The radius of the capsule to query.
- start
- The initial point of the query.
- end
- The end point of the query.
- maxHits
- Limit the number of results returned.
Returns
Documentation for this section has not yet been entered.Remarks
If the radius and capsule length are less than ScenePrivate.MinimumCastRadius the call will be forwarded to . instead.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastCapsule Method
Casts a capsule from start to end and returns an array of collisions along the path.Syntax
[Sansar.Script.Interface]
public RayCastHit[] CastCapsule (Sansar.Vector capsuleStart, Sansar.Vector capsuleEnd, float capsuleRadius, Sansar.Quaternion orientation, Sansar.Vector start, Sansar.Vector end, int maxHits)Parameters
- capsuleStart
- The base point of the capsule.
- capsuleEnd
- The end point of the capsule.
- capsuleRadius
- The radius of the capsule to query.
- orientation
- The orientation of the query shape.
- start
- The initial point of the query.
- end
- The end point of the query.
- maxHits
- Limit the number of results returned.
Returns
Documentation for this section has not yet been entered.Remarks
If the radius and capsule length are less than ScenePrivate.MinimumCastRadius the call will be forwarded to . instead.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastRay Method
Casts a ray from start to end and returns an array of collisions along the path.Syntax
Parameters
- start
- The initial point of the query.
- end
- The end point of the query.
Returns
An array of hit results, ordered from nearest to furthest. If the cast did not hit anything the array will be empty.Remarks
maxHits defaults to 1 if unspecified and will return only the nearest hit.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastRay Method
Casts a ray from start to end and returns an array of collisions along the path.Syntax
[Sansar.Script.Interface]
public RayCastHit[] CastRay (Sansar.Vector start, Sansar.Vector end, int maxHits)Parameters
- start
- The initial point of the query.
- end
- The end point of the query.
- maxHits
- Limit the number of results returned.
Returns
An array of hit results, ordered from nearest to furthest. If the cast did not hit anything the array will be empty.Remarks
maxHits defaults to 1 if unspecified and will return only the nearest hit.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastSphere Method
Casts a sphere from start to end and returns an array of collisions along the path.Syntax
[Sansar.Script.Interface]
public RayCastHit[] CastSphere (float radius, Sansar.Vector start, Sansar.Vector end)Parameters
- radius
- The radius of the sphere.
- start
- The initial point of the query.
- end
- The end point of the query.
Returns
An array of hit results, ordered from nearest to furthest. If the cast did not hit anything the array will be empty.Remarks
If the radius is less than ScenePrivate.MinimumCastRadius the call will be forwarded to ScenePrivate.CastRay(Sansar.Vector, Sansar.Vector, int) instead. maxHits defaults to 1 if unspecified and will return only the nearest hit.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CastSphere Method
Casts a sphere from start to end and returns an array of collisions along the path.Syntax
[Sansar.Script.Interface]
public RayCastHit[] CastSphere (float radius, Sansar.Vector start, Sansar.Vector end, int maxHits)Parameters
- radius
- The radius of the sphere.
- start
- The initial point of the query.
- end
- The end point of the query.
- maxHits
- Limit the number of results returned.
Returns
An array of hit results, ordered from nearest to furthest. If the cast did not hit anything the array will be empty.Remarks
If the radius is less than ScenePrivate.MinimumCastRadius the call will be forwarded to ScenePrivate.CastRay(Sansar.Vector, Sansar.Vector, int) instead. maxHits defaults to 1 if unspecified and will return only the nearest hit.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
Chat Property
Gets the Chat interface for this SceneSyntax
[get: Sansar.Script.Interface]
public Chat Chat { get; }Value
The Chat ApiRemarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CreateCluster Method
Creates a new cluster and adds it to the Scene.Syntax
[Sansar.Script.Interface]
public ulong CreateCluster (ClusterResource asset, Sansar.Vector position, Sansar.Quaternion rotation, Sansar.Vector initialVelocity)Parameters
- asset
- Asset identifier to create.
- position
- Mono.Simd.Vector4f for the initial position.
- rotation
- Mono.Simd.Vector4f for the initial rotation.
- initialVelocity
- Mono.Simd.Vector4f for the initial velocity.
Returns
The internal event id for the completion event.Remarks
The new object may start simulating before the event is triggered.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CreateCluster Method
Creates a new cluster and adds it to the Scene.Syntax
[Sansar.Script.Interface]
[System.Obsolete("Deprecated. Use the Action<> overload", false)]
public ulong CreateCluster (ClusterResource asset, Sansar.Vector position, Sansar.Quaternion rotation, Sansar.Vector initialVelocity, ScenePrivate.CreateClusterHandler handler)Parameters
- asset
- Asset identifier to create.
- position
- Mono.Simd.Vector4f for the initial position.
- rotation
- Mono.Simd.Vector4f for the initial rotation.
- initialVelocity
- Mono.Simd.Vector4f for the initial velocity.
- handler
- Handler to be called when the event completes.
Returns
The internal event id for the completion event.Remarks
The new object may start simulating before the event is triggered.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
CreateCluster Method
Creates a new cluster and adds it to the Scene.Syntax
[Sansar.Script.Interface]
public void CreateCluster (ClusterResource asset, Sansar.Vector position, Sansar.Quaternion rotation, Sansar.Vector initialVelocity, Action<ScenePrivate.CreateClusterData> handler)Parameters
- asset
- Asset identifier to create.
- position
- Mono.Simd.Vector4f for the initial position.
- rotation
- Mono.Simd.Vector4f for the initial rotation.
- initialVelocity
- Mono.Simd.Vector4f for the initial velocity.
- handler
- Handler to be called when the event completes.
Returns
The internal event id for the completion event.Remarks
The new object may start simulating before the event is triggered.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
DefaultGravity Property
The default gravity magnitude in the scene in m/s^2, which is equal to 9.81 or 1 G.Syntax
[get: Sansar.Script.Interface]
public float DefaultGravity { get; }Value
The default scene gravity magnitude.Remarks
The direction of the gravity vector is constant.See GravityExample.cs in the Examples folder for more details.Example
C# Example float sansarGravity = ScenePrivate.DefaultGravity; // Get default gravity in m/s^2Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
FindAgent Method
Looks up an Agent associated with the given object id.Syntax
Parameters
- objectId
- The object to find.
Returns
The agent, or null if an agent cannot be found with that id.Remarks
Agents may leave at any time.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
FindAgent Method
Looks up an Agent associated with the given session id if they are in the scene.Syntax
Parameters
- sessionId
- The session id of the agent to find.
Returns
The agent, or null if an agent cannot be found with that id in the scene.Remarks
Agents may leave at any time. Attempting to use an Agent or AgentInfo interface for an agent no longer in the scene will throw a NullReferenceException.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
FindAgent Method
Looks up an Agent associated with the given persona id, if they are in the scene.Syntax
Parameters
- personaId
- The object to find.
Returns
The agent, or null if an agent cannot be found with that id in the scene.Remarks
Agents may leave at any time. Attempting to use an Agent or AgentInfo interface for an agent no longer in the scene will throw a NullReferenceException.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
FindObject Method
Looks up a Object associated with the given object id.Syntax
Parameters
- objectId
- The object to find.
Returns
The ObjectPrivate, or null if a Object cannot be found with that id.Remarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
FindReflective<TInterface> Generic Method
Looks up Reflective objects in the scene that match the interface type by class name.Syntax
[Sansar.Script.Interface]
[Sansar.Script.NonReflective]
[System.Runtime.CompilerServices.IteratorStateMachine(typeof(Sansar.Simulation.ScenePrivate/<FindReflective>d__116`1))]
public IEnumerable<TInterface> FindReflective<TInterface> (string name)
where TInterface : classType Parameters
- TInterface
- The interface type to find.
Parameters
- name
- The type name of the object's class to find.
Returns
An IEnumerable which contains all objects of the given type name that match the given interface.Remarks
The name given corresponds to the Type.FullName of the object. Multiple scripts may define unrelated types of the same name, but only registered objects that match the interface of TInterface will be returned.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
FindScript Method
Looks up the script object associated with the given scriptIdSyntax
Parameters
- scriptId
- The scriptId of the object to find.
Returns
The script object, or null if an script cannot be found with that id in the scene.Remarks
Objects and their associated scripts may be removed the scene at any time.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetAgent Method
Get an Sansar.Simulation.AgentPrivate for a specific agent in the Scene.Syntax
Parameters
- index
- The index of the agent to get.
Returns
Returns null if the index is larger than the number of agents in the Scene, or if the agent is not fully loaded.Remarks
Agents may appear at different indices as they join and part.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetAgents Method
Returns the current list of Agents in the Scene.Syntax
[Sansar.Script.Interface]
public IEnumerable<AgentPrivate> GetAgents ()Returns
The current list of agents in the SceneRemarks
Documentation for this section has not yet been entered.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetBoxClosestPoints Method
Extends a box with the given half extents the maximum distance and returns any hits.Syntax
[Sansar.Script.Interface]
public RayCastHit[] GetBoxClosestPoints (Sansar.Vector halfExtents, Sansar.Vector origin, float maximumDistance)Parameters
- halfExtents
- The x,y,z distance from the center of the box to the corresponding face.
- origin
- The center of the query.
- maximumDistance
- the maximum distance from the origin to check.
Returns
Documentation for this section has not yet been entered.Remarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetBoxClosestPoints Method
Extends a box with the given half extents the maximum distance and returns any hits.Syntax
[Sansar.Script.Interface]
public RayCastHit[] GetBoxClosestPoints (Sansar.Vector halfExtents, Sansar.Vector origin, Sansar.Quaternion orientation, float maximumDistance)Parameters
- halfExtents
- The x,y,z distance from the center of the box to the corresponding face.
- origin
- The center of the query.
- orientation
- The orientation of the query shape.
- maximumDistance
- the maximum distance from the origin to check.
Returns
An array of hit results, ordered from nearest to furthest. If the cast did not hit anything the array will be empty.Remarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetBoxClosestPoints Method
Extends a box with the given half extents the maximum distance and returns any hits.Syntax
[Sansar.Script.Interface]
public RayCastHit[] GetBoxClosestPoints (Sansar.Vector halfExtents, Sansar.Vector origin, float maximumDistance, int maxHits)Parameters
- halfExtents
- The x,y,z distance from the center of the box to the corresponding face.
- origin
- The center of the query.
- maximumDistance
- the maximum distance from the origin to check.
- maxHits
- Limit the number of results returned.
Returns
Documentation for this section has not yet been entered.Remarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetBoxClosestPoints Method
Extends a box with the given half extents the maximum distance and returns any hits.Syntax
[Sansar.Script.Interface]
public RayCastHit[] GetBoxClosestPoints (Sansar.Vector halfExtents, Sansar.Vector origin, Sansar.Quaternion orientation, float maximumDistance, int maxHits)Parameters
- halfExtents
- The x,y,z distance from the center of the box to the corresponding face.
- origin
- The center of the query.
- orientation
- The orientation of the query shape.
- maximumDistance
- the maximum distance from the origin to check.
- maxHits
- Limit the number of results returned.
Returns
An array of hit results, ordered from nearest to furthest. If the cast did not hit anything the array will be empty.Remarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetCapsuleClosestPoints Method
Extends a capsule with the given parameters the maximum distance and returns any hits.Syntax
[Sansar.Script.Interface]
public RayCastHit[] GetCapsuleClosestPoints (Sansar.Vector capsuleStart, Sansar.Vector capsuleEnd, float capsuleRadius, Sansar.Vector origin, float maximumDistance)Parameters
- capsuleStart
- The base point of the capsule.
- capsuleEnd
- The end point of the capsule.
- capsuleRadius
- The radius of the capsule to query.
- origin
- The base of the capsule.
- maximumDistance
- the maximum distance from the origin to check.
Returns
Documentation for this section has not yet been entered.Remarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetCapsuleClosestPoints Method
Extends a capsule with the given parameters the maximum distance and returns any hits.Syntax
[Sansar.Script.Interface]
public RayCastHit[] GetCapsuleClosestPoints (Sansar.Vector capsuleStart, Sansar.Vector capsuleEnd, float capsuleRadius, Sansar.Vector origin, Sansar.Quaternion orientation, float maximumDistance)Parameters
- capsuleStart
- The base point of the capsule.
- capsuleEnd
- The end point of the capsule.
- capsuleRadius
- The radius of the capsule to query.
- origin
- The base of the capsule.
- orientation
- The orientation of the query shape.
- maximumDistance
- the maximum distance from the origin to check.
Returns
Documentation for this section has not yet been entered.Remarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetCapsuleClosestPoints Method
Extends a capsule with the given parameters the maximum distance and returns any hits.Syntax
[Sansar.Script.Interface]
public RayCastHit[] GetCapsuleClosestPoints (Sansar.Vector capsuleStart, Sansar.Vector capsuleEnd, float capsuleRadius, Sansar.Vector origin, float maximumDistance, int maxHits)Parameters
- capsuleStart
- The base point of the capsule.
- capsuleEnd
- The end point of the capsule.
- capsuleRadius
- The radius of the capsule to query.
- origin
- The base of the capsule.
- maximumDistance
- the maximum distance from the origin to check.
- maxHits
- Limit the number of results returned.
Returns
Documentation for this section has not yet been entered.Remarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetCapsuleClosestPoints Method
Extends a capsule with the given parameters the maximum distance and returns any hits.Syntax
[Sansar.Script.Interface]
public RayCastHit[] GetCapsuleClosestPoints (Sansar.Vector capsuleStart, Sansar.Vector capsuleEnd, float capsuleRadius, Sansar.Vector origin, Sansar.Quaternion orientation, float maximumDistance, int maxHits)Parameters
- capsuleStart
- The base point of the capsule.
- capsuleEnd
- The end point of the capsule.
- capsuleRadius
- The radius of the capsule to query.
- origin
- The base of the capsule.
- orientation
- The orientation of the query shape.
- maximumDistance
- the maximum distance from the origin to check.
- maxHits
- Limit the number of results returned.
Returns
Documentation for this section has not yet been entered.Remarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetGravity Method
Gets the scene's current acceleration of gravity in m/s^2.Syntax
[Sansar.Script.Interface]
public float GetGravity ()Returns
Number indicating the magnitude of gravity in the scene.Remarks
The default gravity for the scene is ScenePrivate.DefaultGravitySee GravityExample.cs in the Examples folder for more details.Example
C# Example float currentGravity = ScenePrivate.GetGravity(); // Get the current scene gravity in m/s^2Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetPortalCreatorName Method
The name of the user who created the specified portal.Syntax
Parameters
- objectId
- Documentation for this section has not yet been entered.
Returns
StringRemarks
User who created the portal.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetPortalDescription Method
Description for the specified portal.Syntax
Parameters
- objectId
- Documentation for this section has not yet been entered.
Returns
StringRemarks
The description of the portal.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetPortalUri Method
URI destination for the specified portal.Syntax
Parameters
- objectId
- Documentation for this section has not yet been entered.
Returns
StringRemarks
The URI of the destination of the portal.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetSphereClosestPoints Method
Extends a sphere with the given radius the maximum distance and returns any hits.Syntax
[Sansar.Script.Interface]
public RayCastHit[] GetSphereClosestPoints (float radius, Sansar.Vector origin, float maximumDistance)Parameters
- radius
- The radius of the sphere to query.
- origin
- The center of the query.
- maximumDistance
- the maximum distance from the origin to check.
Returns
Documentation for this section has not yet been entered.Remarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GetSphereClosestPoints Method
Extends a sphere with the given radius the maximum distance and returns any hits.Syntax
[Sansar.Script.Interface]
public RayCastHit[] GetSphereClosestPoints (float radius, Sansar.Vector origin, float maximumDistance, int maxHits)Parameters
- radius
- The radius of the sphere to query.
- origin
- The center of the query.
- maximumDistance
- the maximum distance from the origin to check.
- maxHits
- Limit the number of results returned.
Returns
Documentation for this section has not yet been entered.Remarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GravityMaximum Field
The maximum gravity magnitude in m/s^2, which is equal to 49.05 or 5 G's.Syntax
public static readonly float GravityMaximumRemarks
A value greater than this will clamp to this value.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
GravityMinimum Field
The minimum allowed gravity magnitude in m/s^2, which is equal to zero.Syntax
public static readonly float GravityMinimumRemarks
A value less than this will clamp to this value.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
HttpClient Property
Gets the HttpClient for this SceneSyntax
[get: Sansar.Script.Interface]
public HttpClient HttpClient { get; }Value
The HttpClient ApiRemarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
MaximumCastRayResults Field
Syntax
public static readonly int MaximumCastRayResultsRemarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
MinimumCastRadius Field
The minimum radius for a . call or minimum half extents for .. Any value smaller than this will use . instead.Syntax
public static readonly float MinimumCastRadiusRemarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
OverrideAudioStream Method
Overrides source of web audio streams.Syntax
Parameters
- url
- URL to use.
Remarks
Applies to all agents in this scene. NOTE: this may cause a few seconds of silence while restarting the stream. To avoid silence, assign URLs in your SceneSettings instead, which will pre-load them.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
OverrideAudioStream Method
Overrides source of web audio streams.Syntax
[Sansar.Script.Interface]
public void OverrideAudioStream (string url, Action<Sansar.Script.OperationCompleteEvent> handler)Parameters
- url
- URL to use.
- handler
- Handler to be called when the event completes.
Remarks
Applies to all agents in this scene. NOTE: this may cause a few seconds of silence while restarting the stream. To avoid silence, assign URLs in your SceneSettings instead, which will pre-load them.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
OverrideMediaSource Method
Sets stream channel source.Syntax
Parameters
- url
- URL to use.
Remarks
Documentation for this section has not yet been entered.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
OverrideMediaSource Method
Overrides source of media surfaces.Syntax
[Sansar.Script.Interface]
public void OverrideMediaSource (string url, int mediaWidth, int mediaHeight)Parameters
- url
- URL to use.
- mediaWidth
- (cMediaChannel only) source width.
- mediaHeight
- (cMediaChannel only) source height.
Remarks
Applies to all agents in this scene. NOTE: this will cause a few seconds of silence while restarting starting the stream. To avoid silence, assign URLs in your SceneSettings instead, which will pre-load them.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
OverrideMediaSource Method
Overrides source of media surfaces.Syntax
[Sansar.Script.Interface]
public void OverrideMediaSource (string url, int mediaWidth, int mediaHeight, Action<Sansar.Script.OperationCompleteEvent> handler)Parameters
- url
- URL to use.
- mediaWidth
- (cMediaChannel only) source width.
- mediaHeight
- (cMediaChannel only) source height.
- handler
- Handler to be called when the event completes.
Remarks
Applies to all agents in this scene. NOTE: this will cause a few seconds of silence while restarting the stream. To avoid silence, assign URLs in your SceneSettings instead, which will pre-load them.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
PerformMediaAction Method
Performs a specific action on the current media surface.Syntax
Parameters
- action
- The action to perform.
Remarks
Applies to this agent only.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
PerformMediaAction Method
Performs a specific action on the current media surface.Syntax
[Sansar.Script.Interface]
public void PerformMediaAction (MediaAction action, Action<Sansar.Script.OperationCompleteEvent> handler)Parameters
- action
- The action to perform.
- handler
- Handler to be called when the event completes.
Remarks
Applies to all agents currently in the scene.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
PlaySound Method
Play sound to direct output.Syntax
[Sansar.Script.Interface]
public PlayHandle PlaySound (SoundResource soundResource, PlaySettings playSettings)Parameters
- soundResource
- The sound resource to play.
- playSettings
- The play parameters.
Returns
The play handle for controlling playback.Remarks
Plays for all agents in this scene.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
PlaySoundAtPosition Method
Play sound at specified position.Syntax
[Sansar.Script.Interface]
public PlayHandle PlaySoundAtPosition (SoundResource soundResource, Sansar.Vector position, PlaySettings playSettings)Parameters
- soundResource
- The sound resource to play.
- position
- The absolute position.
- playSettings
- The play parameters.
Returns
The play handle for controlling playback.Remarks
Plays for all agents in this scene. By setting an absolute position, the location of this sound will be static. If you want the sound to move, you must play the sound on an audio component and move the audio component.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
PlayStream Method
Play web audio stream to direct output.Syntax
Parameters
- streamChannel
- Channel of the audio stream to play.
- loudness
- Relative loudness in dB.
Returns
The play handle for controlling playback.Remarks
Plays for all agents in this scene.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
PlayStreamAtPosition Method
Play web audio stream at specified position.Syntax
[Sansar.Script.Interface]
public PlayHandle PlayStreamAtPosition (StreamChannel streamChannel, Sansar.Vector position, float loudness)Parameters
- streamChannel
- Channel of the audio stream to play.
- position
- The absolute position.
- loudness
- Relative loudness in dB.
Returns
The play handle for controlling playback.Remarks
Plays for all agents in this scene. By setting an absolute position, the location of this sound will be static. If you want the sound to move, you must play the sound on an audio component and move the audio component.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
ResetScene Method
Restarts the Scene.Syntax
[Sansar.Script.Interface(Restricted=true)]
public void ResetScene ()Remarks
All clients will be momentarily disconnected.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
SceneInfo Property
Gets the SceneInfo for this SceneSyntax
[get: Sansar.Script.Interface]
public SceneInfo SceneInfo { get; }Value
The full SceneInfo ApiRemarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
SetGravity Method
Sets the scene's current gravity acceleration in m/s^2.Syntax
Parameters
- scale
- The gravity magnitude.
Returns
The return value is an internal event id which can be passed to Sansar.Script.ScriptBase.WaitFor from a coroutine for synchronous behavior.Remarks
Set to ScenePrivate.DefaultGravity to return to the default. The valid range is from ScenePrivate.GravityMinimum to ScenePrivate.GravityMaximum. The direction cannot be changed.See GravityExample.cs in the Examples folder for more details.Example
C# Example ScenePrivate.SetGravity(1.622f); // Set the scene to moon gravityRequirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
SetGravity Method
Sets the scene's current gravity acceleration in m/s^2.Syntax
[Sansar.Script.Interface]
[System.Obsolete("Deprecated. Use the Action<> overload", false)]
public ulong SetGravity (float scale, Sansar.Script.ScriptBase.OperationComplete handler)Parameters
- scale
- The gravity magnitude.
- handler
- Handler to be called when the event completes.
Returns
The return value is an internal event id which can be passed to Sansar.Script.ScriptBase.WaitFor from a coroutine for synchronous behavior.Remarks
Set to ScenePrivate.DefaultGravity to return to the default. The valid range is from ScenePrivate.GravityMinimum to ScenePrivate.GravityMaximum. The direction cannot be changed.See GravityExample.cs in the Examples folder for more details.Example
C# Example ScenePrivate.SetGravity(1.622f); // Set the scene to moon gravityRequirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
SetGravity Method
Sets the scene's current gravity acceleration in m/s^2.Syntax
[Sansar.Script.Interface]
public void SetGravity (float scale, Action<Sansar.Script.OperationCompleteEvent> handler)Parameters
- scale
- The gravity magnitude.
- handler
- Handler to be called when the event completes.
Returns
The return value is an internal event id which can be passed to Sansar.Script.ScriptBase.WaitFor from a coroutine for synchronous behavior.Remarks
Set to ScenePrivate.DefaultGravity to return to the default. The valid range is from ScenePrivate.GravityMinimum to ScenePrivate.GravityMaximum. The direction cannot be changed.See GravityExample.cs in the Examples folder for more details.Example
C# Example ScenePrivate.SetGravity(1.622f); // Set the scene to moon gravityRequirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
SetMegaphone Method
Sets the megaphone status of the user.Syntax
Parameters
- agent
- Agent to broadcast.
- enable
- If true, user's voice will be heard by everyone in the scene. If false, user's voice will be spatialized normally.
Remarks
Documentation for this section has not yet been entered.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
SetMegaphone Method
Sets the megaphone status of the user.Syntax
[Sansar.Script.Interface]
public void SetMegaphone (AgentPrivate agent, bool enable, Action<Sansar.Script.OperationCompleteEvent> handler)Parameters
- agent
- Agent to broadcast.
- enable
- If true, user's voice will be heard by everyone in the scene. If false, user's voice will be spatialized normally.
- handler
- Handler to be called when the event completes.
Remarks
Documentation for this section has not yet been entered.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
User Property
Gets the User interface for this SceneSyntax
[get: Sansar.Script.Interface]
public User User { get; }Value
The User ApiRemarks
Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
VoiceBroadcastStart Method
Start broadcasting agent's voice to the voice broadcast channel.Syntax
[Sansar.Script.Interface]
[System.Obsolete("Deprecated. use ScenePrivate.SetMegaphone(agent, true) instead", false)]
public void VoiceBroadcastStart (AgentPrivate agent)Parameters
- agent
- Agent to broadcast.
Remarks
Plays for all agents in this scene.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
VoiceBroadcastStop Method
Stop broadcasting agent's voice to voice broadcast channel.Syntax
[Sansar.Script.Interface]
[System.Obsolete("Deprecated. use ScenePrivate.SetMegaphone(agent, false) instead", false)]
public void VoiceBroadcastStop (AgentPrivate agent)Parameters
- agent
- Agent to stop broadcasting.
Remarks
Stops for all agents in this scene.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
VoiceBroadcastStopAll Method
Stop broadcasting all voices to voice broadcast channel.Syntax
[Sansar.Script.Interface]
[System.Obsolete("Deprecated. use AgentPrivate.SetMegaphone(false) instead", false)]
public void VoiceBroadcastStopAll ()Remarks
Stops for all agents in this scene.Requirements
Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0
0 Comments