ObjectPublic

ObjectPublic Class

The ObjectPublic class is a more limited subset of the Sansar.Simulation.ObjectPrivate API for use by other scripts in the scene.

Syntax

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

Exceptions

Type Reason
NullReferenceException Thrown when using an ObjectPublic for an object which is no longer in the scene.

Remarks

Sansar.Simulation.ObjectPrivate has wider access than ObjectPublic. Objects may be removed from the scene at any time. Attempting to use an ObjectPublic interface for an object 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

Members

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

Public Properties

[read-only]
 
ForwardVector Sansar.Vector . The forward vector of the ObjectPublic in the world frame.
[read-only]
 
InitialPosition Sansar.Vector . The position of the ObjectPublic in world frame before simulation started.
[read-only]
 
InitialRotation Sansar.Quaternion . The rotation of the ObjectPublic in world frame before simulation started.
[read-only]
 
IsValid bool . Whether or not this interface is valid. (Inherited from Sansar.Script.InstanceInterface.)
[read-only]
 
Name string . This ObjectPublic name, as specified in the editor.
[read-only]
 
ObjectId Sansar.Script.ObjectId . This ObjectPublic Id. Unique to this Scene.
[read-only]
 
Position Sansar.Vector . The current position of the ObjectPublic in world frame.
[read-only]
 
RightVector Sansar.Vector . The right vector of the ObjectPublic in the world frame.
[read-only]
 
Rotation Sansar.Quaternion . The current rotation of the ObjectPublic in the world frame.
[read-only]
 
UpVector Sansar.Vector . The up vector of the ObjectPublic in the world frame.

Public Methods

override
ToString () : string
A string representation of this object.

Member Details

ForwardVector Property

The forward vector of the ObjectPublic in the world frame.

Syntax

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

Value

A normalized vector.

Remarks

 

Requirements

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

InitialPosition Property

The position of the ObjectPublic in world frame before simulation started.

Syntax

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

Value

Remarks

 

Requirements

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

InitialRotation Property

The rotation of the ObjectPublic in world frame before simulation started.

Syntax

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

Value

Remarks

 

Requirements

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

Name Property

This ObjectPublic name, as specified in the editor.

Syntax

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

Value

Remarks

 

Requirements

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

ObjectId Property

This ObjectPublic Id. Unique to this Scene.

Syntax

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

Value

Remarks

 

Requirements

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

Position Property

The current position of the ObjectPublic in world frame.

Syntax

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

Value

Remarks

 

Requirements

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

RightVector Property

The right vector of the ObjectPublic in the world frame.

Syntax

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

Value

A normalized vector.

Remarks

 

Requirements

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

Rotation Property

The current rotation of the ObjectPublic in the world frame.

Syntax

[get: Sansar.Script.Interface]
public Sansar.Quaternion Rotation { 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 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

UpVector Property

The up vector of the ObjectPublic in the world frame.

Syntax

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

Value

A normalized vector.

Remarks

 

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.