@@ -6,33 +6,42 @@ namespace FbxExporters.EditorTools
6
6
[ CustomEditor ( typeof ( ExportModelSettings ) ) ]
7
7
public class ExportModelSettingsEditor : UnityEditor . Editor
8
8
{
9
- private const float LabelWidth = 144 ;
9
+ private const float LabelWidth = 175 ;
10
10
private const float FieldOffset = 18 ;
11
11
12
12
public override void OnInspectorGUI ( )
13
13
{
14
14
var exportSettings = ( ( ExportModelSettings ) target ) . info ;
15
15
16
+ EditorGUIUtility . labelWidth = LabelWidth ;
17
+
16
18
GUILayout . BeginHorizontal ( ) ;
17
- EditorGUILayout . LabelField ( new GUIContent ( "Export Format: " , "Export the FBX file in the standard binary format." +
19
+ EditorGUILayout . LabelField ( new GUIContent ( "Export Format" , "Export the FBX file in the standard binary format." +
18
20
" Select ASCII to export the FBX file in ASCII format." ) , GUILayout . Width ( LabelWidth - FieldOffset ) ) ;
19
21
exportSettings . exportFormat = ( ExportModelSettingsSerialize . ExportFormat ) EditorGUILayout . Popup ( ( int ) exportSettings . exportFormat , new string [ ] { "ASCII" , "Binary" } ) ;
20
22
GUILayout . EndHorizontal ( ) ;
21
23
22
24
GUILayout . BeginHorizontal ( ) ;
23
- EditorGUILayout . LabelField ( new GUIContent ( "Include: " , "Select whether to export models, animation or both." ) , GUILayout . Width ( LabelWidth - FieldOffset ) ) ;
25
+ EditorGUILayout . LabelField ( new GUIContent ( "Include" , "Select whether to export models, animation or both." ) , GUILayout . Width ( LabelWidth - FieldOffset ) ) ;
24
26
exportSettings . include = ( ExportModelSettingsSerialize . Include ) EditorGUILayout . Popup ( ( int ) exportSettings . include , new string [ ] { "Model(s) Only" , "Animation Only" , "Model(s) + Animation" } ) ;
25
27
GUILayout . EndHorizontal ( ) ;
26
28
27
29
GUILayout . BeginHorizontal ( ) ;
28
- EditorGUILayout . LabelField ( new GUIContent ( "LOD level: " , "Select which LOD to export." ) , GUILayout . Width ( LabelWidth - FieldOffset ) ) ;
30
+ EditorGUILayout . LabelField ( new GUIContent ( "LOD level" , "Select which LOD to export." ) , GUILayout . Width ( LabelWidth - FieldOffset ) ) ;
29
31
exportSettings . lodLevel = ( ExportSettings . LODExportType ) EditorGUILayout . Popup ( ( int ) exportSettings . lodLevel , new string [ ] { "All" , "Highest" , "Lowest" } ) ;
30
32
GUILayout . EndHorizontal ( ) ;
31
33
32
34
GUILayout . BeginHorizontal ( ) ;
33
- EditorGUILayout . LabelField ( new GUIContent ( "Object(s) Position: " , "Select an option for exporting object's transform." ) , GUILayout . Width ( LabelWidth - FieldOffset ) ) ;
35
+ EditorGUILayout . LabelField ( new GUIContent ( "Object(s) Position" , "Select an option for exporting object's transform." ) , GUILayout . Width ( LabelWidth - FieldOffset ) ) ;
34
36
exportSettings . objectPosition = ( ExportModelSettingsSerialize . ObjectPosition ) EditorGUILayout . Popup ( ( int ) exportSettings . objectPosition , new string [ ] { "Local Centered" , "World Absolute" , "Local Pivot" } ) ;
35
37
GUILayout . EndHorizontal ( ) ;
38
+
39
+ GUILayout . BeginHorizontal ( ) ;
40
+ EditorGUILayout . LabelField ( new GUIContent ( "Transfer Root Motion To" , "Select bone to transfer root motion animation to." ) , GUILayout . Width ( LabelWidth - FieldOffset ) ) ;
41
+ EditorGUILayout . Popup ( 0 , new string [ ] { "<None>" } ) ;
42
+ GUILayout . EndHorizontal ( ) ;
43
+
44
+ exportSettings . animatedSkinnedMesh = EditorGUILayout . Toggle ( "Animated Skinned Mesh" , exportSettings . animatedSkinnedMesh ) ;
36
45
}
37
46
}
38
47
0 commit comments