Drag[en]gine Script Module DragonScript
1.23
|
Behavior instance. More...
Public Member Functions | |
float | calculateTurnHorizontal () |
Calculate turn left right value and reset analog input. More... | |
void | dispose () |
Dispose of instance. More... | |
float | getAnalogTurnHorizontal () |
Analog turn left right. More... | |
float | getAnalogTurnHorizontalSticky () |
Sticky analog turn left right. More... | |
bool | getCanTurn () |
player can turn. More... | |
ECBehaviorPlayerInputTurn | getECBehavior () |
Behavior. More... | |
ECBehaviorLocomotion.Instance | getLocomotion () |
Locomotion behavior or null if absent. More... | |
float | getSpeedTurnHorizontal () |
Turn left right speed in degrees per second. More... | |
bool | getTurnLeft () |
Turn left key is pressed. More... | |
bool | getTurnRight () |
Turn right key is pressed. More... | |
void | init (StubElement stub) |
Initialize element from stub. More... | |
Instance | new (ECBehaviorPlayerInputTurn ecbehavior, BehaviorElement element) |
Create instance. More... | |
void | readFromFile (PersistencyEnvironment env, FileReader reader) |
Read element from file. More... | |
void | reset () |
Reset input. More... | |
void | setAnalogTurnHorizontal (float value) |
Set analog turn left right. More... | |
void | setAnalogTurnHorizontalSticky (float value) |
Set sticky analog turn left right. More... | |
void | setCanTurn (bool canTurn) |
Set if player can turn. More... | |
void | setSpeedTurnHorizontal (float speed) |
Set turn left right speed in degrees per second. More... | |
void | setTurnLeft (bool pressed) |
Set if turn left key is pressed. More... | |
void | setTurnRight (bool pressed) |
Set if turn right key is pressed. More... | |
void | toggleCanTurn () |
Toggle can turn. More... | |
void | toggleTurnLeft () |
Toggle turn left key pressed. More... | |
void | toggleTurnRight () |
Toggle turn right key pressed. More... | |
void | updateLocomotion (float elapsed) |
Update locomotion. More... | |
void | writeToFile (PersistencyEnvironment env, FileWriter writer) |
Write element to file. 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 | 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... | |
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.
float Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.calculateTurnHorizontal | ( | ) |
Calculate turn left right value and reset analog input.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.dispose | ( | ) |
Dispose of instance.
Reimplemented from Dragengine.Scenery.DefaultECBehaviorInstance.
float Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.getAnalogTurnHorizontal | ( | ) |
Analog turn left right.
float Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.getAnalogTurnHorizontalSticky | ( | ) |
Sticky analog turn left right.
bool Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.getCanTurn | ( | ) |
player can turn.
ECBehaviorPlayerInputTurn Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.getECBehavior | ( | ) |
Behavior.
ECBehaviorLocomotion.Instance Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.getLocomotion | ( | ) |
Locomotion behavior or null if absent.
float Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.getSpeedTurnHorizontal | ( | ) |
Turn left right speed in degrees per second.
bool Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.getTurnLeft | ( | ) |
Turn left key is pressed.
bool Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.getTurnRight | ( | ) |
Turn right key is pressed.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.init | ( | StubElement | stub | ) |
Initialize element from stub.
Reimplemented from Dragengine.Scenery.DefaultECBehaviorInstance.
Instance Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.new | ( | ECBehaviorPlayerInputTurn | ecbehavior, |
BehaviorElement | element | ||
) |
Create instance.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.readFromFile | ( | PersistencyEnvironment | env, |
FileReader | reader | ||
) |
Read element from file.
Reimplemented from Dragengine.Scenery.DefaultECBehaviorInstance.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.reset | ( | ) |
Reset input.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.setAnalogTurnHorizontal | ( | float | value | ) |
Set analog turn left right.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.setAnalogTurnHorizontalSticky | ( | float | value | ) |
Set sticky analog turn left right.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.setCanTurn | ( | bool | canTurn | ) |
Set if player can turn.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.setSpeedTurnHorizontal | ( | float | speed | ) |
Set turn left right speed in degrees per second.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.setTurnLeft | ( | bool | pressed | ) |
Set if turn left key is pressed.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.setTurnRight | ( | bool | pressed | ) |
Set if turn right key is pressed.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.toggleCanTurn | ( | ) |
Toggle can turn.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.toggleTurnLeft | ( | ) |
Toggle turn left key pressed.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.toggleTurnRight | ( | ) |
Toggle turn right key pressed.
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.updateLocomotion | ( | float | elapsed | ) |
Update locomotion.
Calls calculateTurnHorizontal() to obtain the turning changes and applies using Locomotion.setTurnHorizontal().
void Dragengine.Scenery.ECBehaviorPlayerInputTurn.Instance.writeToFile | ( | PersistencyEnvironment | env, |
FileWriter | writer | ||
) |
Write element to file.
Reimplemented from Dragengine.Scenery.DefaultECBehaviorInstance.