Skip to content

Commit b26709b

Browse files
committed
fail if trying to install max plugin on an unsupported platform
1 parent 25c8ad7 commit b26709b

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Assets/FbxExporters/Editor/InstallIntegration.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -439,6 +439,11 @@ private static string GetInstallScript(){
439439
}
440440

441441
public static int InstallMaxPlugin(){
442+
if (Application.platform != RuntimePlatform.WindowsEditor) {
443+
Debug.LogError ("The 3DsMax Unity plugin is Windows only, please try installing a Maya plugin instead");
444+
return -1;
445+
}
446+
442447
var maxExe = GetMaxExe ();
443448
var installScript = GetInstallScript ();
444449

@@ -457,13 +462,8 @@ public static int InstallMaxPlugin(){
457462
myProcess.StartInfo.CreateNoWindow = true;
458463
myProcess.StartInfo.UseShellExecute = false;
459464

460-
#if UNITY_EDITOR_OSX
461-
throw new NotImplementedException();
462-
#elif UNITY_EDITOR_LINUX
463-
throw new NotImplementedException();
464-
#else // UNITY_EDITOR_WINDOWS
465465
myProcess.StartInfo.Arguments = string.Format("-q -silent -mxs \"{0}\"", installScript);
466-
#endif
466+
467467
myProcess.EnableRaisingEvents = true;
468468
myProcess.Start();
469469
myProcess.WaitForExit();

0 commit comments

Comments
 (0)