29 lines
		
	
	
		
			904 B
		
	
	
	
		
			Python
		
	
	
	
	
	
			
		
		
	
	
			29 lines
		
	
	
		
			904 B
		
	
	
	
		
			Python
		
	
	
	
	
	
from lnx.logicnode.lnx_nodes import *
 | 
						|
 | 
						|
 | 
						|
class CreateTorrentNode(LnxLogicTreeNode):
 | 
						|
    """Create Torrent"""
 | 
						|
    bl_idname = 'LNCreateTorrentNode'
 | 
						|
    bl_label = 'Create Torrent'
 | 
						|
    bl_description = 'Create a torrent file from the network'
 | 
						|
    lnx_category = 'Leenkx'
 | 
						|
    lnx_version = 1
 | 
						|
 | 
						|
    def __init__(self, *args, **kwargs):
 | 
						|
        super(CreateTorrentNode, self).__init__(*args, **kwargs)
 | 
						|
        array_nodes[str(id(self))] = self
 | 
						|
 | 
						|
 | 
						|
    def lnx_init(self, context):
 | 
						|
        self.add_input('LnxNodeSocketAction', 'In')
 | 
						|
        self.add_input('LnxDynamicSocket', 'Connection')
 | 
						|
        self.add_input('LnxDynamicSocket', 'Data')
 | 
						|
 | 
						|
        self.add_output('LnxNodeSocketAction', 'Out')
 | 
						|
        self.add_output('LnxDynamicSocket', 'Torrent')
 | 
						|
        self.add_output('LnxNodeSocketAction', 'Done')
 | 
						|
 | 
						|
 | 
						|
def register():
 | 
						|
    add_category('Leenkx', icon='ORIENTATION_CURSOR')
 | 
						|
    CreateTorrentNode.on_register() |