Help with creating custom nodes with logic nodes plugin

I’m using upbge 0.2.5b and I am trying to add breaking to the add physics constraint node. I am pretty new to python and all help is appreciated. My current code is:

import bpy
import bge_netlogic
NLParameterSocket = bge_netlogic.basicnodes.NLParameterSocket
NLParameterNode = bge_netlogic.basicnodes.NLParameterNode
NLIntegerFieldSocket = bge_netlogic.basicnodes.NLIntegerFieldSocket


class CustomPhysicsNode(bpy.types.Node, NLParameterNode):
    bl_idname = "CustomPhysics"
    bl_label = "Custom Physics Constraint"

   
    def init(self, context):
        NLActionNode.init(self, context)
        self.inputs.new(NLConditionSocket.bl_idname, "Condition")
        self.inputs.new(NLGameObjectSocket.bl_idname, "Target")
        self.inputs.new(NLGameObjectSocket.bl_idname, "Child Object")
        self.inputs.new(NLQuotedStringFieldSocket.bl_idname, 'Name')
        self.inputs.new(NLConstraintTypeSocket.bl_idname, "")
        self.inputs.new(NLBooleanSocket.bl_idname, 'Use World Space')
        self.inputs.new(NLVec3FieldSocket.bl_idname, 'Pivot')
        self.inputs.new(NLBooleanSocket.bl_idname, 'Limit Axis')
        self.inputs.new(NLVec3FieldSocket.bl_idname, 'Axis Limits')
        self.inputs.new(NLBooleanSocket.bl_idname, 'Linked Collision')
        self.inputs.new(NLBooleanSocket.bl_idname, 'Use Breaking')
        self.inputs.new(NLFloatFieldSocket.bl_idname, 'Breaking Power')
        self.inputs[-1].value = True
        self.outputs.new(NLConditionSocket.bl_idname, 'Done')
        
        self.condition = None
        self.target = None
        self.child = None
        self.name = None
        self.constraint = None
        self.use_world = None
        self.pivot = None
        self.use_limit = None
        self.axis_limits = None
        self.linked_col = None
        self.use_breaking = None
        self.breaking_power = None
        self.done = None
        self.OUT = LogicNetworkSubCell(self, self.get_done)

    def get_done(self):
        return self.done
    def get_input_sockets_field_names(self):
         return ["condition", "target", "child", "name", "constraint", 'use_world', "pivot", 'use_limit', "axis_limits", "linked_col", "use_breaking", "breaking_power"]
    def get_output_socket_varnames(self):
         return ["OUT"]
    def evaluate(self):
        self.done = False
        condition = self.get_parameter_value(self.condition)
        if not condition:
            return
        target = self.get_parameter_value(self.target)
        if none_or_invalid(target):
            return
        child = self.get_parameter_value(self.child)
        if none_or_invalid(child):
            return
        name = self.get_parameter_value(self.name)
        if none_or_invalid(name):
            return
        constraint = self.get_parameter_value(self.constraint)
        if none_or_invalid(constraint):
            return
        pivot = self.get_parameter_value(self.pivot)
        if none_or_invalid(pivot):
            return
        use_limit = self.get_parameter_value(self.use_limit)
        if none_or_invalid(use_limit):
            return
        use_world = self.get_parameter_value(self.use_world)
        if none_or_invalid(use_world):
            return
        axis_limits = self.get_parameter_value(self.axis_limits)
        if none_or_invalid(axis_limits):
            return
        linked_col = self.get_parameter_value(self.linked_col)
        if none_or_invalid(linked_col):
            return
        self._set_ready()
        flag = 0 if linked_col else 128
        if use_world:
            pivot.x -= target.localPosition.x
            pivot.y -= target.localPosition.y
            pivot.z -= target.localPosition.z
        if use_limit:
            target[name] = bge.constraints.createConstraint(
                target.getPhysicsId(),
                child.getPhysicsId(),
                constraint,
                pivot_x=pivot.x,
                pivot_y=pivot.y,
                pivot_z=pivot.z,
                axis_x=axis_limits.x,
                axis_y=axis_limits.y,
                axis_z=axis_limits.z,
                flag=flag
            )
        else:
            target[name] = bge.constraints.createConstraint(
                target.getPhysicsId(),
                child.getPhysicsId(),
                constraint,
                pivot_x=pivot.x,
                pivot_y=pivot.y,
                pivot_z=pivot.z,
                flag=flag
            )
        if use_breaking:
          target[name].breakingThreshold = breaking_power
        self.done = True


bge_netlogic.register_nodes("Objects", CustomPhysicsNode)

I am trying to modify the code I found in the netlogic folder, which was split between two files.

The node got registered successfully, but none of the inputs or outputs are visible.

Hi, if I understood you correctly, you want to achieve the behavior of an object as an articulation of a solid body and at the same time you use the bpy module - I will disappoint you this will not work in versions upbge 0.2.5 - I also tried to use bpy to create and replace graphics nodes during the game and in the game it did not work but it worked after exiting the game but this is not what was needed - few answers here on blenderartist, including the administration, say - bpy module is not for the game, there is a bge module and python modules for the game if you want to create solid body hinges you need to look at how it works in a solid body limiter. The API also contains enough information for you to make these hinges on the fly in the game between different objects - https://upbge.org/api/info_quickstart.html#/documentation/docs/v0.2.5/api/bge.constraints.html this link from API upbge 0.2.5 for use physics constraint help you understand how solution you problem

This was based on the example custom parameter node, which worked to create a custom node. However, I decided to switch from logic nodes to python and I got what I wanted. But it still would be nice to have documentation on how to create custom nodes for the logic nodes plugin.