armory/blender/arm/logicnode/physics/LN_has_contact.py

15 lines
526 B
Python
Raw Normal View History

2017-04-08 00:34:45 +02:00
from arm.logicnode.arm_nodes import *
class HasContactNode(ArmLogicTreeNode):
2020-10-05 19:55:56 +02:00
"""Returns whether the given rigid body has contact with another given rigid body."""
2017-04-08 00:34:45 +02:00
bl_idname = 'LNHasContactNode'
bl_label = 'Has Contact'
2020-10-27 19:44:37 +01:00
arm_section = 'contact'
arm_version = 1
2017-04-08 00:34:45 +02:00
def init(self, context):
super(HasContactNode, self).init(context)
2020-10-05 19:55:56 +02:00
self.add_input('ArmNodeSocketObject', 'RB 1')
self.add_input('ArmNodeSocketObject', 'RB 2')
2020-09-20 20:10:01 +02:00
self.add_output('NodeSocketBool', 'Has Contact')