Reordered HFS discovery to resolve issues where the paths would not update when a user upgrades their version of Houdini.
@@ -546,25 +546,18 @@ initializePlugin(MObject obj)
"houdiniEngineCreateUI", "houdiniEngineDeleteUI");
CHECK_MSTATUS_AND_RETURN_IT(status);
- MString hapilLocation = optionVars.hapilLocation.get();
+ MString hapilLocation = "";
bool hapilValid = false;
- if (hapilLocation.length() > 0)
- {
- hapilValid = hapilLocationIsValid(hapilLocation);
- }
- else
- {
MGlobal::executeCommand("source \"houdiniEngineUtils.mel\";");
MString hfsPath = MGlobal::executeCommandStringResult("houdiniEngine_getHfsPath(false)");
- MString hapilPath = "";
if (hfsPath.length() > 0)
{
optionVars.hfsLocation.set(hfsPath);
- hapilPath = MGlobal::executeCommandStringResult("houdiniEngine_getHapilPath(false, houdiniEngine_getHfsPath(false))");
+ MString hapilPath = MGlobal::executeCommandStringResult("houdiniEngine_getHapilPath(false, houdiniEngine_getHfsPath(false))");
if (hapilPath.length() > 0)
{
@@ -577,7 +570,6 @@ initializePlugin(MObject obj)
}
}
}
- }
if (hapilValid)
{
