- _action.execute();
-
- for(vector<Node*>::iterator child = _children.begin(); child != _children.end(); ++child){
- (*child)->execute(_action.effects());
- }
+
+ _executed = true;
+ int value = _action->execute();
+ _effects = _action->effects(value);
+
+ cerr << "Got returnvalue: " << value << ", number of effects: " << _effects.size() << endl;
+
+}
+
+const std::vector<Node*>& Node::children() const{
+ return _children;
+}
+StartNode::StartNode(const Literals& init){
+ EffectsMap initial;
+ initial[0] = init;
+ _action = new Action("start",Preconditions(),"", initial);