Drag[en]gine Script Module DragonScript 1.35
Loading...
Searching...
No Matches
Dragengine.Scenery.ECComposeAttachResource Class Reference

Composable attachable resource for element class. More...

Inheritance diagram for Dragengine.Scenery.ECComposeAttachResource:

Public Member Functions

void attach (Collider collider, Object resource, StubElement stub)
 Attach resource to collider using stub.
DMatrix attachMatrix (StubElement stub)
 Attach matrix for static positioning of resources.
ECPString getBone ()
 Name of bone to attach to null if not used.
ECPVector getOrientation ()
 Attach orientation.
ECPVector getPosition ()
 Attach position.
String getPrefix ()
 Property prefix.
ECComposeAttachResource new (ElementClass ownerClass)
 Create composable element class.
ECComposeAttachResource new (ElementClass ownerClass, String prefix)
 Create composable element class.

Public Attributes

ECPString pBone
ECPVector pPosition
String pPrefix

Detailed Description

Composable attachable resource for element class.

Provides attachable resource support to element class without subclassing from a specific class. Multiple instances of ECComposeAttachResource can be used by using a property prefix. Supports attaching static or at a specific bone.

Member Function Documentation

◆ attach()

void Dragengine.Scenery.ECComposeAttachResource.attach ( Collider collider,
Object resource,
StubElement stub )

Attach resource to collider using stub.

Collider or resource can be null in which case nothing is done. If bone is not empty string collider has to be castable to ColliderRig.

The following object types can be attached:

Referenced by attachMatrix().

◆ attachMatrix()

DMatrix Dragengine.Scenery.ECComposeAttachResource.attachMatrix ( StubElement stub)

Attach matrix for static positioning of resources.

Version
1.35

References attach(), attachMatrix(), pBone, and pPosition.

Referenced by attachMatrix().

◆ getBone()

ECPString Dragengine.Scenery.ECComposeAttachResource.getBone ( )

Name of bone to attach to null if not used.

References getPosition(), and pPosition.

Referenced by getPrefix().

◆ getOrientation()

ECPVector Dragengine.Scenery.ECComposeAttachResource.getOrientation ( )

Attach orientation.

Referenced by getPrefix().

◆ getPosition()

ECPVector Dragengine.Scenery.ECComposeAttachResource.getPosition ( )

Attach position.

References pBone, and pPrefix.

Referenced by getBone().

◆ getPrefix()

String Dragengine.Scenery.ECComposeAttachResource.getPrefix ( )

Property prefix.

References getBone(), getOrientation(), getPrefix(), pBone, and pPrefix.

Referenced by getPrefix().

◆ new() [1/2]

ECComposeAttachResource Dragengine.Scenery.ECComposeAttachResource.new ( ElementClass ownerClass)

Create composable element class.

Adds all properties to ownerClass. If you do not want a property to be configurable using XML subclassing use ownerClass.removeProperty() to remove them.

References new().

Referenced by new(), and new().

◆ new() [2/2]

ECComposeAttachResource Dragengine.Scenery.ECComposeAttachResource.new ( ElementClass ownerClass,
String prefix )

Create composable element class.

Adds all properties to ownerClass. If you do not want a property to be configurable using XML subclassing use ownerClass.removeProperty() to remove them. Properties are prefixed using prefix to allow multiple instances of this class to be used. If not empty prefix is typically of the form 'name.' which results for example in a property named 'name.position'.

References new(), and pPosition.

Member Data Documentation

◆ pBone

ECPString Dragengine.Scenery.ECComposeAttachResource.pBone

◆ pPosition

ECPVector Dragengine.Scenery.ECComposeAttachResource.pPosition

Referenced by attachMatrix(), getBone(), and new().

◆ pPrefix

String Dragengine.Scenery.ECComposeAttachResource.pPrefix

Referenced by getPosition(), and getPrefix().


The documentation for this class was generated from the following file: