This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| dragengine:modules:dragonscript:behavior_touchsensor [2026/10/09 23:23] – dragonlord | dragengine:modules:dragonscript:behavior_touchsensor [2026/11/20 16:51] (current) – [touchSensor.set] dragonlord | ||
|---|---|---|---|
| Line 124: | Line 124: | ||
| <action name=' | <action name=' | ||
| < | < | ||
| + | </ | ||
| + | </ | ||
| + | |||
| + | ===== touchSensor.update ===== | ||
| + | |||
| + | Update touch sensor. | ||
| + | |||
| + | ^Parameter^Value^Description^ | ||
| + | |touching.runEvent|string|Run state machine event on all touching elements supporting [[behavior_statemachine|ECBehaviorStateMachine]]| | ||
| + | |||
| + | This is an example of using this action: | ||
| + | <code xml> | ||
| + | <action name=' | ||
| + | < | ||
| </ | </ | ||
| </ | </ | ||
| Line 136: | Line 150: | ||
| |count.less|integer|Count of touching elements is less than integer value| | |count.less|integer|Count of touching elements is less than integer value| | ||
| |count.greater|integer|Count of touching elements is greater than integer value| | |count.greater|integer|Count of touching elements is greater than integer value| | ||
| - | |eventElement.flags.set|string|Event BehaviorElement has [[behavior_btsmflags|ECBehaviorBTSMFlags]] with named flag set. Use only inside '' | ||
| - | |eventElement.flags.clear|string|Event BehaviorElement has [[behavior_btsmflags|ECBehaviorBTSMFlags]] with named flag cleared. Use only inside '' | ||
| |player|'' | |player|'' | ||
| |wait| |If present action returns BTResult.running instead of BTResult.failed to wait until the checks are all fulfilled| | |wait| |If present action returns BTResult.running instead of BTResult.failed to wait until the checks are all fulfilled| | ||
| Line 165: | Line 177: | ||
| |touchSensor.count.greater|integer|Count of touching elements is greater than integer value| | |touchSensor.count.greater|integer|Count of touching elements is greater than integer value| | ||
| |touchSensor.player|'' | |touchSensor.player|'' | ||
| - | |touchSensor.eventElement.flags.set|string|Event BehaviorElement has [[behavior_btsmflags|ECBehaviorBTSMFlags]] with named flag set. Use only inside '' | ||
| - | |touchSensor.eventElement.flags.clear|string|Event BehaviorElement has [[behavior_btsmflags|ECBehaviorBTSMFlags]] with named flag cleared. Use only inside '' | ||
| This is an example of using this condition: | This is an example of using this condition: | ||
| Line 190: | Line 200: | ||
| ===== touchSensor.entered ===== | ===== touchSensor.entered ===== | ||
| - | Element entered touch sensor. Element is send as event parameter. | + | Element entered touch sensor. Element is send as event parameter. Use [[behavior_statemachine# |
| ===== touchSensor.left ===== | ===== touchSensor.left ===== | ||
| - | Element left touch sensor. Element is send as event parameter. | + | Element left touch sensor. Element is send as event parameter. Use [[behavior_statemachine# |
| ====== Required Behaviors ====== | ====== Required Behaviors ====== | ||