@@ -118,8 +118,14 @@ public override void OnInspectorGUI() {
118
118
119
119
// check that the path is valid and references the maya executable
120
120
if ( ! string . IsNullOrEmpty ( mayaPath ) ) {
121
+ // get the directory of the executable
121
122
var md = Directory . GetParent ( mayaPath ) ;
122
- if ( md . Parent . Name . ToLower ( ) . StartsWith ( "mayalt" ) ) {
123
+ // UNI-29074 TODO: add Maya LT support
124
+ // Check that the executable is not in a MayaLT directory (thus being MayaLT instead of Maya executable).
125
+ // On Mac path resembles: /Applications/Autodesk/mayaLT2018/Maya.app
126
+ // On Windows path resembles: C:\Program Files\Autodesk\MayaLT2018\bin\maya.exe
127
+ // Therefore check both executable folder (for Mac) and its parent (for Windows)
128
+ if ( md . Name . ToLower ( ) . StartsWith ( "mayalt" ) || md . Parent . Name . ToLower ( ) . StartsWith ( "mayalt" ) ) {
123
129
Debug . LogError ( string . Format ( "Unity Integration does not support Maya LT: \" {0}\" " , md . FullName ) ) ;
124
130
exportSettings . selectedMayaApp = oldValue ;
125
131
return ;
@@ -303,6 +309,7 @@ private static void FindMayaInstalls() {
303
309
if ( ! product . StartsWith ( "maya" , StringComparison . InvariantCultureIgnoreCase ) ) {
304
310
continue ;
305
311
}
312
+ // UNI-29074 TODO: add Maya LT support
306
313
// Reject MayaLT -- it doesn't have plugins.
307
314
if ( product . StartsWith ( "mayalt" , StringComparison . InvariantCultureIgnoreCase ) ) {
308
315
continue ;
@@ -388,6 +395,13 @@ public static void AddMayaOption(string newOption){
388
395
}
389
396
// get the version
390
397
var version = AskMayaVersion ( newOption ) ;
398
+
399
+ // UNI-29074 TODO: add Maya LT support
400
+ // make sure this is not Maya LT
401
+ if ( version . ToLower ( ) . StartsWith ( "lt" ) ) {
402
+ Debug . LogError ( string . Format ( "Unity Integration does not support Maya LT: \" {0}\" " , newOption ) ) ;
403
+ return ;
404
+ }
391
405
instance . mayaOptionNames . Add ( GetUniqueName ( "Maya " + version ) ) ;
392
406
mayaOptionPaths . Add ( newOption ) ;
393
407
instance . selectedMayaApp = mayaOptionPaths . Count - 1 ;
0 commit comments