File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ private static string GetModuleTemplatePath(string version)
50
50
return result . Replace ( VERSION_TAG , version ) ;
51
51
}
52
52
53
- private static string GetProjectPath ( )
53
+ public static string GetProjectPath ( )
54
54
{
55
55
return System . IO . Directory . GetParent ( Application . dataPath ) . FullName ;
56
56
}
@@ -299,7 +299,8 @@ public static void OnMenuItem ()
299
299
if ( Integrations . InstallMaya ( Integrations . MAYA_VERSION , true , false ) )
300
300
{
301
301
string title = string . Format ( "Completed installation of Maya {0} Integration." , Integrations . MAYA_VERSION ) ;
302
- string message = "Please run the following MEL commands to configure auto-loading of the plugin in Maya.\n \n loadPlugin unityOneClickPlugin; pluginInfo -edit -autoload true unityOneClickPlugin;\n " ;
302
+ string commands = string . Format ( "optionVar -stringValue \" UnityProject\" \" {0}\" ; loadPlugin unityOneClickPlugin; pluginInfo -edit -autoload true unityOneClickPlugin;" , Integrations . GetProjectPath ( ) ) ;
303
+ string message = string . Format ( "Please run the following MEL commands to configure auto-loading of the plugin in Maya.\n \n {0}\n " , commands ) ;
303
304
304
305
EditorUtility . DisplayDialog ( title , message , "Ok" ) ;
305
306
Debug . Log ( message ) ;
Original file line number Diff line number Diff line change 36
36
"${UNITY3D_PATH}" -projectPath "${PROJECT_PATH}" -importPackage ${PACKAGE_PATH} -quit
37
37
38
38
# Install Maya2017 Integration
39
- # Use "InstallMaya2017CommandsOnly" to install without UI
40
39
"${UNITY3D_PATH}" -batchMode -projectPath "${PROJECT_PATH}" -executeMethod FbxExporters.Integrations.InstallMaya2017 -quit
41
40
42
41
# Configuring Maya2017 to auto-load integration
45
44
if [ ! -f "${MAYA_PATH}" ]; then
46
45
echo "Maya2017 not installed"
47
46
else
48
- "${MAYA_PATH}" -command "loadPlugin unityOneClickPlugin; pluginInfo -edit -autoload true unityOneClickPlugin; quit;"
47
+ # To configure without user interface prepend the following command: optionVar -intValue \"UnityOneClick_Headless\" 1;
48
+ "${MAYA_PATH}" -command "optionVar -stringValue \"UnityProject\" \"${PROJECT_PATH}\"; loadPlugin unityOneClickPlugin; pluginInfo -edit -autoload true unityOneClickPlugin; quit;"
49
49
fi
50
50
fi
51
51
You can’t perform that action at this time.
0 commit comments