@@ -401,7 +401,8 @@ protected override bool DisableTransferAnim {
401
401
get {
402
402
// don't transfer animation if we are exporting more than one hierarchy, the timeline clips from
403
403
// a playable director, or if only the model is being exported
404
- return ToExport == null || ToExport . Length > 1 || IsPlayableDirector || SettingsObject . ModelAnimIncludeOption == ExportSettings . Include . Model ;
404
+ // if we are on the timeline then export length can be more than 1
405
+ return ToExport == null || ToExport . Length == 0 || ( ! IsTimelineAnim && ToExport . Length > 1 ) || IsPlayableDirector || SettingsObject . ModelAnimIncludeOption == ExportSettings . Include . Model ;
405
406
}
406
407
}
407
408
@@ -453,14 +454,15 @@ protected override ExportOptionsSettingsSerializeBase SettingsObject
453
454
public static void Init ( IEnumerable < UnityEngine . Object > toExport , string filename = "" , bool isTimelineAnim = false , bool isPlayableDirector = false )
454
455
{
455
456
ExportModelEditorWindow window = CreateWindow < ExportModelEditorWindow > ( ) ;
457
+ window . IsTimelineAnim = isTimelineAnim ;
458
+ window . IsPlayableDirector = isPlayableDirector ;
459
+
456
460
int numObjects = window . SetGameObjectsToExport ( toExport ) ;
457
461
if ( string . IsNullOrEmpty ( filename ) ) {
458
462
filename = window . GetFilenameFromObjects ( ) ;
459
463
}
460
464
window . InitializeWindow ( filename ) ;
461
- window . IsTimelineAnim = isTimelineAnim ;
462
465
window . SingleHierarchyExport = ( numObjects == 1 ) ;
463
- window . IsPlayableDirector = isPlayableDirector ;
464
466
window . Show ( ) ;
465
467
}
466
468
@@ -471,7 +473,8 @@ protected int SetGameObjectsToExport(IEnumerable<UnityEngine.Object> toExport){
471
473
TransferAnimationDest = null ;
472
474
473
475
// if only one object selected, set transfer source/dest to this object
474
- if ( ToExport . Length == 1 ) {
476
+ if ( ToExport . Length == 1 || ( IsTimelineAnim && ToExport . Length > 0 ) ) {
477
+ Debug . Log ( "here" ) ;
475
478
var go = ModelExporter . GetGameObject ( ToExport [ 0 ] ) ;
476
479
if ( go ) {
477
480
TransferAnimationSource = go . transform ;
0 commit comments