Drag[en]gine Script Module DragonScript
1.21
|
Behavior instance. More...
Public Member Functions | |
void | clear () |
Stop hit scans clearing results as if nothing is hit. More... | |
void | dispose () |
Dispose of composeable instance. More... | |
void | forEachTest (Block ablock) |
Visit collision tests using block. More... | |
String | getBone () |
Test bone. More... | |
ECBehaviorCollider.Instance | getCollider () |
Collider behavior. More... | |
CollisionFilter | getCollisionFilter () |
Collision filter. More... | |
ECBehaviorComponent.Instance | getComponent () |
Collider behavior or null if not used. More... | |
Vector | getDirection () |
Normalized test direction. More... | |
ECBehaviorHitScan | getECBehavior () |
Behavior. More... | |
Quaternion | getOrientation () |
Test orientation. More... | |
Vector | getOrigin () |
Test origin. More... | |
float | getRange () |
Test range. More... | |
ColliderCollisionTest | getTestAt (int index) |
Collision test at index. More... | |
int | getTestCount () |
Count of collision tests. More... | |
void | init (StubElement stub) |
Initialize element from stub. More... | |
Instance | new (ECBehaviorHitScan ecbehavior, BehaviorElement element) |
Create element. More... | |
void | resetTestDirections () |
Set direction of all tests to viewMatrix * direction * range. More... | |
void | setBone (String bone) |
Set test bone. More... | |
void | setCollisionFilter (CollisionFilter collisionFilter) |
Set collision filter. More... | |
void | setDirection (Vector direction) |
Set normalized test direction. More... | |
void | setOrientation (Quaternion orientation) |
Set test orientation. More... | |
void | setOrigin (Vector origin) |
Set test origin. More... | |
void | setRange (float range) |
Set test range. More... | |
void | start () |
Start a single collision test. More... | |
void | start (int count) |
Start collision tests. More... | |
void | startCircular (int count, float angle) |
Start collision tests arranging them in a circular pattern. More... | |
void | startCone (int count, float angle) |
Start collision tests arranging them randomly in a small cone cap. More... | |
void | startRectangular (int count, float angleX, float angleY) |
Start collision tests arranging them randomly across a small sphere segment. More... | |
void | startRectangularUniform (int countX, int countY, float angleX, float angleY) |
Start collision tests arranging them evenly across a small sphere segment. More... | |
void | stop () |
Stop hit scans. More... | |
Public Member Functions inherited from Dragengine.Scenery.DefaultECBehaviorInstance | |
void | addToGameWorld () |
Add element to game world. More... | |
void | attachToParent (Element parent) |
Attach element to object set by the mapper in the IGDE World Editor. More... | |
void | enterFrame () |
Frame update started. More... | |
void | geometryChanged () |
Position or orientation changed. More... | |
BehaviorElement | getElement () |
Behavior element to apply behavior to. More... | |
int | getInstanceIndex () |
Behavior instance index. More... | |
DefaultECBehaviorInstance | new (BehaviorElement element) |
Create default composeable instance. More... | |
void | postThink (float elapsed) |
Post thinking after physics processing is finished. More... | |
void | readFromFile (PersistencyEnvironment env, FileReader reader) |
Read behavior instance from file. More... | |
void | removeFromGameWorld () |
Remove element from game world. More... | |
bool | requiresEnterFrame () |
Behavior instance requires enterFrame() to be called. More... | |
bool | requiresThink () |
Behavior instance requires think() to be called. More... | |
void | stateChanged () |
State changed (visble, touchable). More... | |
void | think (float elapsed) |
Think about what to do for the next frame update. More... | |
void | writeToFile (PersistencyEnvironment env, FileWriter writer) |
Write behavior instance to file. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from Dragengine.Scenery.DefaultECBehaviorInstance | |
void | setRequiresEnterFrame (bool required) |
Set if behavior instance requires enterFrame() to be called. More... | |
void | setRequiresThink (bool required) |
Set if behavior instance requires think() to be called. More... | |
Behavior instance.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.clear | ( | ) |
Stop hit scans clearing results as if nothing is hit.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.dispose | ( | ) |
Dispose of composeable instance.
Reimplemented from Dragengine.Scenery.DefaultECBehaviorInstance.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.forEachTest | ( | Block | ablock | ) |
Visit collision tests using block.
Block receives ColliderCollisionTest as argument.
String Dragengine.Scenery.ECBehaviorHitScan.Instance.getBone | ( | ) |
Test bone.
ECBehaviorCollider.Instance Dragengine.Scenery.ECBehaviorHitScan.Instance.getCollider | ( | ) |
Collider behavior.
CollisionFilter Dragengine.Scenery.ECBehaviorHitScan.Instance.getCollisionFilter | ( | ) |
Collision filter.
ECBehaviorComponent.Instance Dragengine.Scenery.ECBehaviorHitScan.Instance.getComponent | ( | ) |
Collider behavior or null if not used.
Vector Dragengine.Scenery.ECBehaviorHitScan.Instance.getDirection | ( | ) |
Normalized test direction.
ECBehaviorHitScan Dragengine.Scenery.ECBehaviorHitScan.Instance.getECBehavior | ( | ) |
Behavior.
Quaternion Dragengine.Scenery.ECBehaviorHitScan.Instance.getOrientation | ( | ) |
Test orientation.
Vector Dragengine.Scenery.ECBehaviorHitScan.Instance.getOrigin | ( | ) |
Test origin.
float Dragengine.Scenery.ECBehaviorHitScan.Instance.getRange | ( | ) |
Test range.
ColliderCollisionTest Dragengine.Scenery.ECBehaviorHitScan.Instance.getTestAt | ( | int | index | ) |
Collision test at index.
int Dragengine.Scenery.ECBehaviorHitScan.Instance.getTestCount | ( | ) |
Count of collision tests.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.init | ( | StubElement | stub | ) |
Initialize element from stub.
Reimplemented from Dragengine.Scenery.DefaultECBehaviorInstance.
Instance Dragengine.Scenery.ECBehaviorHitScan.Instance.new | ( | ECBehaviorHitScan | ecbehavior, |
BehaviorElement | element | ||
) |
Create element.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.resetTestDirections | ( | ) |
Set direction of all tests to viewMatrix * direction * range.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.setBone | ( | String | bone | ) |
Set test bone.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.setCollisionFilter | ( | CollisionFilter | collisionFilter | ) |
Set collision filter.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.setDirection | ( | Vector | direction | ) |
Set normalized test direction.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.setOrientation | ( | Quaternion | orientation | ) |
Set test orientation.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.setOrigin | ( | Vector | origin | ) |
Set test origin.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.setRange | ( | float | range | ) |
Set test range.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.start | ( | ) |
Start a single collision test.
After call returns one collision tests is attached to the collider and ready to run using the last configuration used.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.start | ( | int | count | ) |
Start collision tests.
After call returns the given number of collision tests are attached to the collider and ready to run using the last configuration used.
void Dragengine.Scenery.ECBehaviorHitScan.Instance.startCircular | ( | int | count, |
float | angle | ||
) |
Start collision tests arranging them in a circular pattern.
After call returns the given number of collision tests are attached to the collider and ready to run using the last configuration used.
angle | Opening angle in degrees (angle across diameter). |
void Dragengine.Scenery.ECBehaviorHitScan.Instance.startCone | ( | int | count, |
float | angle | ||
) |
Start collision tests arranging them randomly in a small cone cap.
After call returns the given number of collision tests are attached to the collider and ready to run using the last configuration used.
This method can be used for weapons with multiple projectiles like buck shots.
angle | Opening angle in degrees (angle across diameter). |
void Dragengine.Scenery.ECBehaviorHitScan.Instance.startRectangular | ( | int | count, |
float | angleX, | ||
float | angleY | ||
) |
Start collision tests arranging them randomly across a small sphere segment.
After call returns the given number of collision tests are attached to the collider and ready to run using the last configuration used.
The segment has a rectangular shape. This method can be used for weapons with rectangular spreads like a duckbill modification.
angleX | Horizontal opening angle in degrees (angle across width). |
angleY | Vertical opening angle in degrees (angle across height). |
void Dragengine.Scenery.ECBehaviorHitScan.Instance.startRectangularUniform | ( | int | countX, |
int | countY, | ||
float | angleX, | ||
float | angleY | ||
) |
Start collision tests arranging them evenly across a small sphere segment.
After call returns the given number of collision tests are attached to the collider and ready to run using the last configuration used.
The segment has a rectangular shape. This method can be used for testing actor visibility by using the actor height and size.
countX | Count of columns. |
countY | Count of rows. |
angleX | Horizontal opening angle in degrees (angle across width). |
angleY | Vertical opening angle in degrees (angle across height). |
void Dragengine.Scenery.ECBehaviorHitScan.Instance.stop | ( | ) |
Stop hit scans.