LNXSDK/leenkx/blender/lnx/logicnode/object/LN_get_distance.py
2025-01-22 16:18:30 +01:00

17 lines
566 B
Python

from lnx.logicnode.lnx_nodes import *
class GetDistanceNode(LnxLogicTreeNode):
"""Returns the euclidian distance between the two given objects.
@see For distance between two locations, use the `Distance` operator
in the *[`Vector Math`](#vector-math)* node."""
bl_idname = 'LNGetDistanceNode'
bl_label = 'Get Distance'
lnx_version = 1
def lnx_init(self, context):
self.add_input('LnxNodeSocketObject', 'Object')
self.add_input('LnxNodeSocketObject', 'Object')
self.add_output('LnxFloatSocket', 'Distance')