from lnx.logicnode.lnx_nodes import *

class GetVelocityNode(LnxLogicTreeNode):
    """Returns the world velocity of the given rigid body."""
    bl_idname = 'LNGetVelocityNode'
    bl_label = 'Get RB Velocity'
    lnx_version = 1

    def lnx_init(self, context):
        self.add_input('LnxNodeSocketObject', 'RB')
        self.add_input('LnxBoolSocket', 'Linear On Local Axis')
        self.add_input('LnxBoolSocket', 'Angular On Local Axis')

        self.add_output('LnxVectorSocket', 'Linear')
        self.add_output('LnxVectorSocket', 'Angular')