Entity3D ClassDelta Engine Documentation
Base entity for 3D objects. Usually used in Meshes or Models, both normally Actors. View code on GitHub
Inheritance Hierarchy

System Object
  DeltaEngine.Entities Entity
    DeltaEngine.Entities DrawableEntity
      DeltaEngine.Rendering3D Entity3D
        DeltaEngine.Rendering3D Billboard
        DeltaEngine.Rendering3D HierarchyEntity3D
        DeltaEngine.Rendering3D.Shapes Circle3D
        DeltaEngine.Rendering3D.Shapes Grid3D
        DeltaEngine.Rendering3D.Shapes Line3D

Namespace: DeltaEngine.Rendering3D
Assembly: DeltaEngine.Rendering3D (in DeltaEngine.Rendering3D.dll) Version: 1.1.1.0 (1.1.1)
Syntax

public class Entity3D : DrawableEntity

The Entity3D type exposes the following members.

Constructors

  NameDescription
Public methodEntity3D(Vector3D)
Initializes a new instance of the Entity3D class
Public methodEntity3D(Vector3D, Quaternion)
Initializes a new instance of the Entity3D class
Top
Methods

  NameDescription
Public methodAdd T  (Overrides DrawableEntity Add T (T).)
Public methodAddTag (Inherited from Entity.)
Public methodClearTags (Inherited from Entity.)
Public methodContains T  (Overrides Entity Contains T  .)
Public methodContainsBehavior T  (Inherited from Entity.)
Public methodContainsTag (Inherited from Entity.)
Protected methodDeactivate (Inherited from Entity.)
Public methodDispose (Inherited from Entity.)
Public methodGet T  (Overrides DrawableEntity Get T  .)
Protected methodGetActiveBehaviors (Inherited from Entity.)
Protected methodGetComponentsForSaving (Overrides Entity GetComponentsForSaving .)
Protected methodGetDrawBehaviors (Inherited from DrawableEntity.)
Public methodGetInterpolatedArray T  (Inherited from DrawableEntity.)
Public methodGetInterpolatedList T  (Inherited from DrawableEntity.)
Public methodGetOrDefault T  (Inherited from Entity.)
Public methodGetTags (Inherited from Entity.)
Protected methodNextUpdateStarted (Overrides DrawableEntity NextUpdateStarted .)
Public methodOnDraw T  (Inherited from DrawableEntity.)
Protected methodOnOrientationChanged
Protected methodOnPositionChanged
Protected methodOnScaleChanged
Public methodRemove T  (Inherited from Entity.)
Public methodRemoveTag (Inherited from Entity.)
Public methodSet (Overrides DrawableEntity Set(Object).)
Public methodSetComponents (Inherited from Entity.)
Public methodSetWithoutInterpolation T  (Overrides DrawableEntity SetWithoutInterpolation T (T).)
Public methodStart T  (Inherited from Entity.)
Public methodStop T  (Inherited from Entity.)
Public methodToggleVisibility (Inherited from DrawableEntity.)
Public methodToString (Inherited from Entity.)
Top
Fields

  NameDescription
Protected fieldcomponents (Inherited from Entity.)
Protected fieldlastOrientation
Protected fieldlastPosition
Protected fieldlastTickLerpComponents
Each element can either be a Lerp, a Lerp List or an array of Lerp objects. View code on GitHub
(Inherited from DrawableEntity.)
Top
Properties

  NameDescription
Public propertyIsActive (Inherited from DrawableEntity.)
Public propertyIsPauseable (Inherited from Entity.)
Public propertyIsVisible (Inherited from DrawableEntity.)
Public propertyNumberOfComponents (Inherited from Entity.)
Public propertyOrientation
Public propertyPosition
Public propertyRenderLayer (Inherited from DrawableEntity.)
Public propertyScale
Public propertyUpdatePriority (Inherited from Entity.)
Top
Remarks

Tests: DeltaEngine.Rendering3D.Tests.Entity3DTests
Examples

10 unit tests call DeltaEngine.Rendering3D.Entity3D
[Test, CloseAfterFirstFrame]
public void CreateEntity3D()
{
    var entity = new Entity3D(Vector3D.Zero);
    entity.Add(Rectangle.One);
    Assert.AreEqual(Vector3D.Zero, entity.Position);
    Assert.AreEqual(Quaternion.Identity, entity.Orientation);
    Assert.IsTrue(entity.IsVisible);
    Assert.AreEqual(4, entity.GetComponentsForSaving().Count);
}
[Test, CloseAfterFirstFrame]
public void CreateEntity3DPositionAndOrientation()
{
    var position = new Vector3D(10.0f, -3.0f, 27.0f);
    var orientation = Quaternion.Identity;
    var entity = new Entity3D(position, orientation);
    Assert.AreEqual(position, entity.Position);
    Assert.AreEqual(orientation, entity.Orientation);
}
[Test, CloseAfterFirstFrame]
public void SetAndGetEntity3DComponentsDirectly()
{
    var entity = new Entity3D(Vector3D.Zero);
    entity.Set(Vector3D.One);
    Assert.AreEqual(Vector3D.One, entity.Get<Vector3D>());
    entity.Set(Quaternion.Identity);
    Assert.AreEqual(Quaternion.Identity, entity.Get<Quaternion>());
}
See Also