diff --git a/blender/arm/logicnode/object/LN_get_object_by_uid.py b/blender/arm/logicnode/object/LN_get_object_by_uid.py new file mode 100644 index 00000000..02f92510 --- /dev/null +++ b/blender/arm/logicnode/object/LN_get_object_by_uid.py @@ -0,0 +1,16 @@ +import bpy + +from arm.logicnode.arm_nodes import * + + +class GetObjectByUidNode(ArmLogicTreeNode): + """Searches for a object that with this uid in the current active scene and returns it.""" + + bl_idname = 'LNGetObjectByUidNode' + bl_label = 'Get Object By Uid' + arm_version = 1 + + def arm_init(self, context): + self.add_input('ArmIntSocket', 'Uid') + + self.add_output('ArmNodeSocketObject', 'Object') diff --git a/blender/arm/logicnode/object/LN_get_object_uid.py b/blender/arm/logicnode/object/LN_get_object_uid.py new file mode 100644 index 00000000..ba54651c --- /dev/null +++ b/blender/arm/logicnode/object/LN_get_object_uid.py @@ -0,0 +1,13 @@ +from arm.logicnode.arm_nodes import * + +class GetUidNode(ArmLogicTreeNode): + """Returns the uid of the given object.""" + bl_idname = 'LNGetUidNode' + bl_label = 'Get Object Uid' + arm_section = 'props' + arm_version = 1 + + def arm_init(self, context): + self.add_input('ArmNodeSocketObject', 'Object') + + self.add_output('ArmIntSocket', 'Uid')