User Tools

Site Tools


dragengine:modules:dragonscript:behavior_touchsensor

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
dragengine:modules:dragonscript:behavior_touchsensor [2026/10/09 16:36] – dragonlorddragengine:modules:dragonscript:behavior_touchsensor [2026/11/20 16:51] (current) – [touchSensor.set] dragonlord
Line 116: Line 116:
  
 ^Parameter^Value^Description^ ^Parameter^Value^Description^
 +|collisionFilter.filter.set|string|Set named [[gamedev:collisionfiltering|collision filter]] filter mask bit.|
 +|collisionFilter.filter.clear|string|Clear named [[gamedev:collisionfiltering|collision filter]] filter mask bit.|
 |enabled|''true'', ''false''|Enable touch sensor| |enabled|''true'', ''false''|Enable touch sensor|
  
Line 122: Line 124:
 <action name='touchSensor.set'> <action name='touchSensor.set'>
   <parameter name='enabled'>true</parameter>   <parameter name='enabled'>true</parameter>
 +</action>
 +</code>
 +
 +===== 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='touchSensor.update'>
 +  <parameter name='touching.runEvent'>effect.jump</parameter>
 </action> </action>
 </code> </code>
Line 184: Line 200:
 ===== touchSensor.entered ===== ===== touchSensor.entered =====
  
-Element entered touch sensor.+Element entered touch sensor. Element is send as event parameter. Use [[behavior_statemachine#eventelementupdate|eventParameter.update]] or [[behavior_statemachine#eventelementcheck|eventParameter.check]] to work with the element.
  
 ===== touchSensor.left ===== ===== touchSensor.left =====
  
-Element left touch sensor.+Element left touch sensor. Element is send as event parameter. Use [[behavior_statemachine#eventelementupdate|eventParameter.update]] or [[behavior_statemachine#eventelementcheck|eventParameter.check]] to work with the element.
  
 ====== Required Behaviors ====== ====== Required Behaviors ======
dragengine/modules/dragonscript/behavior_touchsensor.1791563819.txt.gz · Last modified: by dragonlord