fix for adding asset to a no-history mesh
@@ -244,7 +244,7 @@ houdiniEngine_addHistory(string $assetNode)
// need to previous input from this asset if it's not the same as the current one
- houdiniEngine_setHistoryAttr($inputAttr, $objects, $components);
+ houdiniEngine_connectHistory($inputAttr, $objects, $components);
// if we can insert into history
// remove output geo, connect input geo's mesh input to inputGeometry
@@ -258,7 +258,7 @@ houdiniEngine_addHistory(string $assetNode)
}
global proc int
-houdiniEngine_setHistoryAttr(string $inputAttr, string $objects[], string $components[])
+houdiniEngine_connectHistory(string $inputAttr, string $objects[], string $components[])
{
// Make Sure we have exactly one valid input object
string $validObjects[];
@@ -309,6 +309,7 @@ houdiniEngine_setHistoryAttr(string $inputAttr, string $objects[], string $compo
return 0;
}
int $upstreamIsAsset = 0;
+ if($upstreamNode != "") {
if(`nodeType $upstreamNode` == "houdiniAsset") {
print "ok, it's a different asset\n";
$upstreamIsAsset = 1;
@@ -349,6 +350,7 @@ houdiniEngine_setHistoryAttr(string $inputAttr, string $objects[], string $compo
// the attrs to connect should be the ones for direct connection of node ids
}
}
+ }
// if there is no upstream history
// then we need a copy of the original mesh, so we sync
