armory/blender/arm/logicnode/animation/LN_animation_state.py
2020-09-08 21:16:20 +02:00

18 lines
590 B
Python

import bpy
from bpy.props import *
from bpy.types import Node, NodeSocket
from arm.logicnode.arm_nodes import *
class AnimationStateNode(ArmLogicTreeNode):
'''Animation state node'''
bl_idname = 'LNAnimationStateNode'
bl_label = 'Animation State'
bl_icon = 'NONE'
def init(self, context):
self.inputs.new('ArmNodeSocketObject', 'Object')
self.outputs.new('NodeSocketBool', 'Is Playing')
self.outputs.new('NodeSocketString', 'Action')
self.outputs.new('NodeSocketInt', 'Frame')
add_node(AnimationStateNode, category=MODULE_AS_CATEGORY)