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

27 lines
919 B
Python

from lnx.logicnode.lnx_nodes import *
class EvaluateRootMotionNode(LnxLogicTreeNode):
"""Calculates the root motion bone in an armature object."""
bl_idname = 'LNEvaluateRootMotionNode'
bl_label = 'Evaluate Root Motion'
lnx_version = 1
property0: HaxeEnumProperty(
'property0',
items = [('X', 'X', 'X'),
('Y', 'Y', 'Y'),
('Z', 'Z', 'Z')],
name='', default='Y')
def lnx_init(self, context):
self.add_input('LnxNodeSocketAction', 'Reset')
self.add_input('LnxNodeSocketObject', 'Object')
self.add_input('LnxNodeSocketAnimTree', 'Action')
self.add_input('LnxStringSocket', 'Bone')
self.add_output('LnxNodeSocketAnimTree', 'Result')
def draw_buttons(self, context, layout):
layout.label(text='Root Motion Lock axis:')
layout.prop(self, 'property0')