Also export non-root shapes

--HG--
branch : develop
This commit is contained in:
kaetemi 2014-12-12 21:17:13 +01:00
parent 5346da559e
commit eb2f4555b1
2 changed files with 64 additions and 68 deletions

View file

@ -187,6 +187,8 @@ fn haveCoarseMesh node =
return false return false
) )
fn getRoot node = if isvalidnode node.parent then getRoot node.parent else node
fn runNelMaxExportSub inputMaxFile retryCount = fn runNelMaxExportSub inputMaxFile retryCount =
( (
tagThisFile = false tagThisFile = false
@ -272,12 +274,9 @@ fn runNelMaxExportSub inputMaxFile retryCount =
-- For each node -- For each node
for node in array_node do for node in array_node do
(
-- It is root ?
if (node.parent == undefined) then
( (
-- Is not a skeleton ? -- Is not a skeleton ?
if (node.name != "Bip01") then if (((substring node.name 1 3) != "Bip") and ((substring (getRoot node).name 1 3) != "Bip")) then
( (
-- Can be exported ? -- Can be exported ?
if (isToBeExported node == true) then if (isToBeExported node == true) then
@ -325,7 +324,6 @@ fn runNelMaxExportSub inputMaxFile retryCount =
) )
) )
) )
)
-- Export default animations -- Export default animations

View file

@ -253,6 +253,8 @@ fn haveCoarseMesh node =
return false return false
) )
fn getRoot node = if isvalidnode node.parent then getRoot node.parent else node
fn runNelMaxExportSub inputMaxFile retryCount = fn runNelMaxExportSub inputMaxFile retryCount =
( (
tagThisFile = false tagThisFile = false
@ -338,12 +340,9 @@ fn runNelMaxExportSub inputMaxFile retryCount =
-- For each node -- For each node
for node in array_node do for node in array_node do
(
-- It is root ?
if (node.parent == undefined) then
( (
-- Is not a skeleton ? -- Is not a skeleton ?
if (node.name != "Bip01") then if (((substring node.name 1 3) != "Bip") and ((substring (getRoot node).name 1 3) != "Bip")) then
( (
-- Can be exported ? -- Can be exported ?
if (isToBeExported node == true) then if (isToBeExported node == true) then
@ -391,7 +390,6 @@ fn runNelMaxExportSub inputMaxFile retryCount =
) )
) )
) )
)
-- Export default animations -- Export default animations