@@ -175,7 +175,7 @@ proc importFile(string $filePathStr){
175
175
}
176
176
177
177
if($nameWithoutExt != ""){
178
- storeAttribute($unityExportSet, $UnityFbxNamespaceAttr, $nameWithoutExt);
178
+ storeAttribute($unityExportSet, $UnityFbxNamespaceAttr, `namespaceInfo -an $nameWithoutExt` );
179
179
}
180
180
181
181
if (setExists($unityExportSet) == true){
@@ -282,6 +282,7 @@ proc exportSet(string $unitySet, int $exportAnim){
282
282
global string $UnityFbxFileNameAttr;
283
283
global string $UnityFbxAnimFilePathAttr;
284
284
global string $UnityFbxAnimFileNameAttr;
285
+ global string $UnityFbxNamespaceAttr;
285
286
286
287
string $unitySetContents[] = `listConnections $unitySet`;
287
288
@@ -308,12 +309,13 @@ proc exportSet(string $unitySet, int $exportAnim){
308
309
$nameAttr = $UnityFbxAnimFileNameAttr;
309
310
}
310
311
311
- $unity_fbx_file_path = getAttribute($unitySet, $pathAttr);
312
- $unity_fbx_file_name = getAttribute($unitySet, $nameAttr);
312
+ string $unity_fbx_file_path = getAttribute($unitySet, $pathAttr);
313
+ string $unity_fbx_file_name = getAttribute($unitySet, $nameAttr);
314
+ string $unity_fbx_namespace = getAttribute($unitySet, $UnityFbxNamespaceAttr);
313
315
314
316
$strCmd = "";
315
317
if ($unity_fbx_file_path != "" && $unity_fbx_file_name != ""){
316
- $strCmd = "file -force -options \"\" -typ \"FBX export\" -pr -es \"" + $unity_fbx_file_path + "/" + $unity_fbx_file_name + " \"";
318
+ $strCmd = `format -s $unity_fbx_namespace -s $unity_fbx_file_path -s $unity_fbx_file_name "file -force -options \"\" -typ \"FBX export\" -relativeNamespace \"^1s\" -es \"^2s/^3s \""` ;
317
319
eval $strCmd;
318
320
}
319
321
0 commit comments