Files
LNXSDK/leenkx/blender/lnx/logicnode/scene/LN_get_collection.py

21 lines
659 B
Python

from lnx.logicnode.lnx_nodes import *
class GetGroupNode(LnxLogicTreeNode):
"""Searches for a collection of objects with the given name and
outputs the collection's objects as an array, if found.
@seeNode Collection"""
bl_idname = 'LNGetGroupNode'
bl_label = 'Get Collection'
lnx_section = 'collection'
lnx_version = 2
def lnx_init(self, context):
self.add_input('LnxStringSocket', 'Name')
self.add_output('LnxNodeSocketArray', 'Objects')
self.add_output('LnxIntSocket', 'Length')
def get_replacement_node(self, node_tree: bpy.types.NodeTree):
return NodeReplacement.Identity(self)