2025-01-22 16:18:30 +01:00

19 lines
651 B
Python

from lnx.logicnode.lnx_nodes import *
class PulseNode(LnxLogicTreeNode):
"""Sends a signal repeatedly between the given time interval until you stop it.
@input Start: Starts to send the signals
@input Stop: Stops to send the signals
@input Interval: The interval between the signals
"""
bl_idname = 'LNPulseNode'
bl_label = 'Pulse'
lnx_version = 1
def lnx_init(self, context):
self.add_input('LnxNodeSocketAction', 'Start')
self.add_input('LnxNodeSocketAction', 'Stop')
self.add_input('LnxFloatSocket', 'Interval', default_value=0.1)
self.add_output('LnxNodeSocketAction', 'Out')