anchor.diff:        Re_Xferred   = Re_Xferred + 1
         OutData%NStepWave = IntKiBuf( Int_Xferred ) 
         Int_Xferred   = Int_Xferred + 1
  -  IF ( IntKiBuf( Int_Xferred ) == 0 ) THEN  ! PtfmRefxt not allocated
  -    Int_Xferred = Int_Xferred + 1
  -  ELSE
  -    Int_Xferred = Int_Xferred + 1
  -    i1_l = IntKiBuf( Int_Xferred    )
  -    i1_u = IntKiBuf( Int_Xferred + 1)
  -    Int_Xferred = Int_Xferred + 2
  -    IF (ALLOCATED(OutData%PtfmRefxt)) DEALLOCATE(OutData%PtfmRefxt)
  -    ALLOCATE(OutData%PtfmRefxt(i1_l:i1_u),STAT=ErrStat2)
  -    IF (ErrStat2 /= 0) THEN 
  -       CALL SetErrStat(ErrID_Fatal, 'Error allocating OutData%PtfmRefxt.', ErrStat, ErrMsg,RoutineName)
  -       RETURN
  -    END IF
  -    ALLOCATE(mask1(i1_l:i1_u),STAT=ErrStat2)
  -    IF (ErrStat2 /= 0) THEN 
  -       CALL SetErrStat(ErrID_Fatal, 'Error allocating mask1.', ErrStat, ErrMsg,RoutineName)
  -       RETURN
  -    END IF
  -    mask1 = .TRUE. 
  -      IF (SIZE(OutData%PtfmRefxt)>0) OutData%PtfmRefxt = UNPACK(ReKiBuf( Re_Xferred:Re_Xferred+(SIZE(OutData%PtfmRefxt))-1 ), mask1, 0.0_ReKi )
  -      Re_Xferred   = Re_Xferred   + SIZE(OutData%PtfmRefxt)
  -    DEALLOCATE(mask1)
  -  END IF
  -  IF ( IntKiBuf( Int_Xferred ) == 0 ) THEN  ! PtfmRefyt not allocated
  -    Int_Xferred = Int_Xferred + 1
  -  ELSE
  -    Int_Xferred = Int_Xferred + 1
  -    i1_l = IntKiBuf( Int_Xferred    )
  -    i1_u = IntKiBuf( Int_Xferred + 1)
  -    Int_Xferred = Int_Xferred + 2
  -    IF (ALLOCATED(OutData%PtfmRefyt)) DEALLOCATE(OutData%PtfmRefyt)
  -    ALLOCATE(OutData%PtfmRefyt(i1_l:i1_u),STAT=ErrStat2)
  -    IF (ErrStat2 /= 0) THEN 
  -       CALL SetErrStat(ErrID_Fatal, 'Error allocating OutData%PtfmRefyt.', ErrStat, ErrMsg,RoutineName)
  -       RETURN
  -    END IF
  -    ALLOCATE(mask1(i1_l:i1_u),STAT=ErrStat2)
  -    IF (ErrStat2 /= 0) THEN 
  -       CALL SetErrStat(ErrID_Fatal, 'Error allocating mask1.', ErrStat, ErrMsg,RoutineName)
  -       RETURN
  -    END IF
  -    mask1 = .TRUE. 
  -      IF (SIZE(OutData%PtfmRefyt)>0) OutData%PtfmRefyt = UNPACK(ReKiBuf( Re_Xferred:Re_Xferred+(SIZE(OutData%PtfmRefyt))-1 ), mask1, 0.0_ReKi )
  -      Re_Xferred   = Re_Xferred   + SIZE(OutData%PtfmRefyt)
  -    DEALLOCATE(mask1)
  -  END IF
     IF ( IntKiBuf( Int_Xferred ) == 0 ) THEN  ! PtfmRefztRot not allocated
       Int_Xferred = Int_Xferred + 1
     ELSE
  
positive.code: ! 
    ErrStat = ErrID_None
    ErrMsg  = ""
  IF (ALLOCATED(InitInputData%PtfmRefxt)) THEN
    DEALLOCATE(InitInputData%PtfmRefxt)
  ENDIF
  IF (ALLOCATED(InitInputData%PtfmRefyt)) THEN
    DEALLOCATE(InitInputData%PtfmRefyt)
  ENDIF
  IF (ALLOCATED(InitInputData%PtfmRefztRot)) THEN
    DEALLOCATE(InitInputData%PtfmRefztRot)
  ENDIF
  
negative.code:       Re_Xferred   = Re_Xferred   + 1
        IntKiBuf ( Int_Xferred:Int_Xferred+(1)-1 ) = InData%NStepWave
        Int_Xferred   = Int_Xferred   + 1
    IF ( .NOT. ALLOCATED(InData%PtfmRefztRot) ) THEN
      IntKiBuf( Int_Xferred ) = 0
      Int_Xferred = Int_Xferred + 1
  