The Cluster class handles interactions with in game objects.
public class Cluster : Sansar.Script.InstanceInterfaceMembers at a glance
| Kind | Members |
|---|---|
| Properties | ClusterId · ObjectPrivateCount |
| Methods | Destroy · GetObjectPrivate · GetObjectPrivates · ToString |
Properties
ClusterId
public ClusterId ClusterId { get; }Returns the Id of this cluster.
ObjectPrivateCount
public uint ObjectPrivateCount { get; }The current number of objects in this cluster.
Methods
Destroy
public void Destroy()Destroys this cluster.
[System.Obsolete("Deprecated. Use the Action<> overload", false)]
public ulong Destroy(
Sansar.Script.ScriptBase.OperationComplete handler
)Destroys this cluster.
| Parameter | Type | Description |
|---|---|---|
handler | Sansar.Script.ScriptBase.OperationComplete | Handler to be called when the event completes. |
Returns: ulong — The internal event id for the completion event.
public void Destroy(
Action<Sansar.Script.OperationCompleteEvent> handler
)Destroys this cluster.
| Parameter | Type | Description |
|---|---|---|
handler | Action<Sansar.Script.OperationCompleteEvent> | Handler to be called when the event completes. |
GetObjectPrivate
public ObjectPrivate GetObjectPrivate(uint index)Retrieves a Sansar.Simulation.ObjectPrivate by index.
| Parameter | Type | Description |
|---|---|---|
index | uint | Index of the Sansar.Simulation.ObjectPrivate to retrieve. |
Returns: ObjectPrivate — The Sansar.Simulation.ObjectPrivate at that index or null.
GetObjectPrivates
public IEnumerable<ObjectPrivate> GetObjectPrivates()Enumerable for GetObjectPrivate
Returns: IEnumerable<ObjectPrivate> — Enumerable for GetObjectPrivate
Remarks
The resulting enumerable may be invalidated if the underlying collection changes.
ToString
public override string ToString()A string representation of this object.
Returns: string — A string representation of this object.
Remarks
The format of this string may change between releases.
Generated from the Sansar 47.10.0 client ScriptApi snapshot.