Class MyDetectedEntityInfo
Describes detected entity info
Inheritance
Namespace: Sandbox.ModAPI.Ingame
Assembly: Sandbox.Common.dll
Syntax
public sealed class MyDetectedEntityInfo : ValueType
Constructors
MyDetectedEntityInfo(Int64, String, MyDetectedEntityType, Nullable<Vector3D>, MatrixD, Vector3, MyRelationsBetweenPlayerAndBlock, BoundingBoxD, Int64)
Implements MyDetectedEntityInfo constructor
Declaration
public MyDetectedEntityInfo(long entityId, string name, MyDetectedEntityType type, Nullable<Vector3D> hitPosition, MatrixD orientation, Vector3 velocity, MyRelationsBetweenPlayerAndBlock relationship, BoundingBoxD boundingBox, long timeStamp)
Parameters
Type | Name | Description |
---|---|---|
System. |
entityId | entity id |
System. |
name | name |
My |
type | type |
System. |
hitPosition | hit position |
Matrix |
orientation | orientation |
Vector3 | velocity | velocity |
My |
relationship | relationship |
Bounding |
boundingBox | bounding box |
System. |
timeStamp | time stamp |
Fields
BoundingBox
The entity's world-aligned bounding box
Declaration
public readonly BoundingBoxD BoundingBox
Field Value
Type | Description |
---|---|
Bounding |
EntityId
The entity's EntityId
Declaration
public readonly long EntityId
Field Value
Type | Description |
---|---|
System. |
HitPosition
Position where the raycast hit the entity. (can be null if the sensor didn't use a raycast)
Declaration
public readonly Nullable<Vector3D> HitPosition
Field Value
Type | Description |
---|---|
System. |
Name
The entity's display name if it is friendly, or a generic descriptor if it is not
Declaration
public readonly string Name
Field Value
Type | Description |
---|---|
System. |
Orientation
The entity's absolute orientation at the time it was detected
Declaration
public readonly MatrixD Orientation
Field Value
Type | Description |
---|---|
Matrix |
Relationship
Relationship between the entity and the owner of the sensor
Declaration
public readonly MyRelationsBetweenPlayerAndBlock Relationship
Field Value
Type | Description |
---|---|
My |
TimeStamp
Time when the entity was detected. This field counts milliseconds, compensated for simspeed
Declaration
public readonly long TimeStamp
Field Value
Type | Description |
---|---|
System. |
Type
Enum describing the type of entity
Declaration
public readonly MyDetectedEntityType Type
Field Value
Type | Description |
---|---|
My |
Velocity
The entity's absolute velocity at the time it was detected
Declaration
public readonly Vector3 Velocity
Field Value
Type | Description |
---|---|
Vector3 |
Properties
Position
The entity's position (center of the Bounding Box)
Declaration
public Vector3D Position { get; }
Property Value
Type | Description |
---|---|
Vector3D |
Methods
IsEmpty()
Determines if this structure is empty; meaning it does not contain any meaningful data
Declaration
public bool IsEmpty()
Returns
Type | Description |
---|---|
System. |