added evaluate() method for all non-scripting nodes, made evaluateChildren() recursive
git-svn-id: svn://anubis/fart/branches/scene-file-scripting@338 7f9b0f55-74a9-4bce-be96-3c2cd072584d
This commit is contained in:
1 parent
793c7afb2d
commit
f36c1fa60f
2 files changed
+197
-17
No files matched your search
+3
-3
@@ -21,12 +21,12 @@ void Scene::load(const char * filename)
|
||||
refptr<Node> node = parse(filename, scope);
|
||||
if ( ! node.isNull() )
|
||||
{
|
||||
refptr<Node> dummy = new Node();
|
||||
/* evaluate any scripting nodes in the node tree */
|
||||
node->evaluate(dummy);
|
||||
refptr<Node> processed_scene = node->evaluate();
|
||||
node->evaluateChildren(processed_scene);
|
||||
|
||||
/* now we have a new node tree under 'dummy' with no scripting nodes */
|
||||
processScene(dummy->getChildren()[0]);
|
||||
processScene(processed_scene);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user