@@ -4385,7 +4385,7 @@ def unload(self,file='project.yaml'):
43854385 for pt in self .platformTypes :
43864386 if 'fairleads' in pt :
43874387 for f ,fl in enumerate (pt ['fairleads' ]):
4388- if 'headings' in pt [ 'fairleads' ]:
4388+ if 'headings' in fl :
43894389 for head in fl ['headings' ]:
43904390 # get rotation matrix of heading
43914391 R = rotationMatrix (0 ,0 ,np .radians (90 - head ))
@@ -4398,7 +4398,7 @@ def unload(self,file='project.yaml'):
43984398 pt ['fairleads' ] = []
43994399 if 'JTubes' in pt :
44004400 for f ,fl in enumerate (pt ['JTubes' ]):
4401- if 'headings' in pt [ 'JTubes' ] :
4401+ if 'headings' in fl :
44024402 for head in fl ['headings' ]:
44034403 # get rotation matrix of heading
44044404 R = rotationMatrix (0 ,0 ,np .radians (90 - head ))
@@ -4425,11 +4425,12 @@ def unload(self,file='project.yaml'):
44254425 # for att in pf.attachments.values()
44264426 # if isinstance(att['obj'], Fairlead)
44274427 # ]
4428- pf_info = {'rFair' : pf .rFair ,
4429- 'zFair' : pf .zFair ,
4430- 'type' : pf .entity ,
4428+ pf_info = {'type' : pf .entity ,
44314429 'fairleads' :fairleads ,
44324430 'JTubes' :jtubes }
4431+ if not fairleads :
4432+ pf_info ['rFair' ] = pf .rFair
4433+ pf_info ['zFair' ] = pf .zFair
44334434
44344435 # update the platform type/add to platform types list if
44354436 # no type providd or pf_info different from any platformTypes
@@ -4719,8 +4720,8 @@ def unload(self,file='project.yaml'):
47194720 burial = None
47204721 jA = None
47214722 jB = None
4722- jtubesA = [att ['obj' ]. id for att in endA .attachments .values () if isinstance (att ['obj' ], Jtube )]
4723- jtubesB = [att ['obj' ]. id for att in endB .attachments .values () if isinstance (att ['obj' ], Jtube )]
4723+ jtubesA = [att ['obj' ] for att in endA .attachments .values () if isinstance (att ['obj' ], Jtube )]
4724+ jtubesB = [att ['obj' ] for att in endB .attachments .values () if isinstance (att ['obj' ], Jtube )]
47244725
47254726 for kk ,sub in enumerate (cab .subcomponents ):
47264727 currentConfig = {}
@@ -4764,7 +4765,7 @@ def unload(self,file='project.yaml'):
47644765
47654766
47664767 elif isinstance (sub ,DynamicCable ):
4767- jtube = [att . id for att in sub .attached_to if isinstance (att ,Jtube )]
4768+ jtube = [att for att in sub .attached_to if isinstance (att ,Jtube )]
47684769 # grab index of fairlead list from end B
47694770
47704771 for jj in jtube :
0 commit comments