14 lines
		
	
	
		
			519 B
		
	
	
	
		
			Python
		
	
	
	
	
	
			
		
		
	
	
			14 lines
		
	
	
		
			519 B
		
	
	
	
		
			Python
		
	
	
	
	
	
from lnx.logicnode.lnx_nodes import *
 | 
						|
 | 
						|
class ArrayGetPreviousNextNode(LnxLogicTreeNode):
 | 
						|
    """Returns the previous or next value to be retrieve by looping the array according to the boolean condition."""
 | 
						|
    bl_idname = 'LNArrayGetPreviousNextNode'
 | 
						|
    bl_label = 'Array Get Previous/Next'
 | 
						|
    lnx_version = 1
 | 
						|
 | 
						|
    def lnx_init(self, context):
 | 
						|
        self.add_input('LnxNodeSocketArray', 'Array')
 | 
						|
        self.add_input('LnxBoolSocket', 'Previous: 0 / Next: 1')
 | 
						|
 | 
						|
        self.add_output('LnxDynamicSocket', 'Value')
 |