I am needing some assistance with retrieving hangers from the path of piping. I have develop a graph that does what I am expecting only when the pipe is either perfectly horizontal or perfectly vertical. The graph falls apart when piping that is drawn at an angle is introduced. My current method is to get the bounding box of the hangers and pipe then use bounding box intersects to attempt to identify what hangers are associated to a particular pipe. See image and attached graph. I fear this is not the proper approach. I would greatly appreciate any guidance or assistance anyone is willing to offer. For convienienace I have attached a link to an example file I am using to develop the script.
HangersAlongPipe-v5.dyn (26.8 KB)