Files
LNXSDK/leenkx/blender/lnx/logicnode/navmesh/LN_crowd_set_location.py

22 lines
779 B
Python
Raw Normal View History

from lnx.logicnode.lnx_nodes import *
class CrowdSetLocationNode(LnxLogicTreeNode):
"""Makes a NavCrowd agent go to location.
@input In: Start teleport.
@input Object: The object to navigate. Object must have `NavCrowd` trait applied.
@input Location: Closest point on the navmesh to navigate to.
"""
bl_idname = 'LNCrowdSetLocationNode'
bl_label = 'Crowd Set Location'
lnx_section = 'crowd'
lnx_version = 1
def lnx_init(self, context):
self.add_input('LnxNodeSocketAction', 'In')
self.add_input('LnxStringSocket', 'NavMeshId', default_value = 'NavMesh')
self.add_input('LnxNodeSocketObject', 'Object')
self.add_input('LnxVectorSocket', 'Location')
self.add_output('LnxNodeSocketAction', 'Out')