def draw_temp_segment_with_reaching_hands(self):
    """Draw temporary segment to visually assist in connecting sockets.

    This draws a line from 'socket a' (the socket from where the line
    segment will be defined) to the cursor.

    If there's a nearby compatible socket, we also draw a line from the
    cursor to that socket or close to it (depending on how close it is).
    When this is the case, hand icons are drawn as well to indicate when
    the socket is close enough to establish a connection or not
    """
    ### reference values/objecs locally for quicker/easier access

    sa = self.socket_a

    sa_center = sa.rect.center

    mp = self.magnet_point

    ### try obtaining a segment between the center of socket a and the
    ### magnet point which is clipped to the screen

    try:
        start, end = clip_segment(sa_center, mp)

    ### if we don't success, just pass

    except ValueError:
        pass

    ### otherwise, draw the temporary line

    else:

        sbc = self.socket_b_candidate
        sb = self.socket_b


        if sbc:

            ##
            sbc_center = sbc.rect.center

            ## lines

            draw_line(SCREEN, sa.line_color, start, mp, 3)

            midpoint = Vector2(sbc_center).lerp(mp, self.percentage_to_mouse)

            draw_line(SCREEN, sbc.line_color, sbc_center, midpoint, 3)

            ## hand from socket

            open_hand_surf = RELATIVE_POS_TO_OPEN_HAND[

                (
                    mp[0] < sbc_center[0],
                    mp[1] < sbc_center[1],
                )

            ]

            HAND_RECT.center = midpoint

            blit_on_screen(open_hand_surf, HAND_RECT)

            ### hand near mouse

            opposite_hand = OPEN_HAND_TO_ITS_OPPOSITE[open_hand_surf]

            HAND_RECT.center = mp
            blit_on_screen(opposite_hand, HAND_RECT)

        ### if there's a socket b, we draw an outline around
        ### it as well (where the magnet point is located),
        ### then draw the temporary line;
        ###
        ### we always use the color of the socket which is
        ### the output socket;

        elif sb:

            ###

            is_output_socket = isinstance(sb, OutputSocket)

            color = (

                sb.line_color
                if is_output_socket

                else sa.line_color

            )

            ###
            sb_center = sb.rect.center
            ###

            draw_line(SCREEN, color, start, mp, 3)
            draw_line(SCREEN, color, mp, sb_center, 3)

            ### hand from socket

            rel_pos = (
                mp[0] < sb_center[0],
                mp[1] < sb_center[1],
            )

            closed_hand_surf = RELATIVE_POS_TO_CLOSED_HAND[rel_pos]

            HAND_RECT.center = mp + RELATIVE_POS_TO_CLOSED_HAND_OFFSET[rel_pos] 

            blit_on_screen(closed_hand_surf, HAND_RECT)

            ### hand near mouse

            opposite_hand = CLOSED_HAND_TO_ITS_OPPOSITE[closed_hand_surf]

            HAND_RECT.center = mp

            blit_on_screen(opposite_hand, HAND_RECT)

        ### if there's no socket b, though, we just draw a line,
        ### using the color of socket a

        else:

            draw_line(SCREEN, sa.line_color, start, end, 3)

            open_hand_surf = RELATIVE_POS_TO_OPEN_HAND[

                (
                    sa_center[0] < mp[0],
                    sa_center[1] < mp[1],
                )

            ]

            HAND_RECT.center = mp
            opposite_hand = OPEN_HAND_TO_ITS_OPPOSITE[open_hand_surf]
            blit_on_screen(opposite_hand, HAND_RECT)
Draw temporary segment to visually assist in connecting sockets.

    This draws a line from 'socket a' (the socket from where the line
    segment will be defined) to the cursor.

    If there's a nearby compatible socket, we also draw a line from the
    cursor to that socket or close to it (depending on how close it is).
    When this is the case, hand icons are drawn as well to indicate when
    the socket is close enough to establish a connection or not
    
nodezator/graphman/socketparenthood/draw/connectionassist.py