I'm creating a floating menu for window control and realized I couldn't use any of the "window under cursor" functions of BTT as the floating menu blocks the window. Result is that the function targets the active window instead.
I managed to find a workaround by hiding the menu before the command and inserting a 0.1s delay to wait for the floating menu to hide.