X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fobject_factory.cpp;h=5335140591183e14d87feeebe271f4d373830c56;hb=d4b281559d45406a5d07cf04d89142cdeb90b114;hp=0b6916961ddcf3258bd3a270dde5b073a72ac537;hpb=a113d3bd1feddd510e3b2852b0d42522735eee40;p=supertux.git diff --git a/src/object_factory.cpp b/src/object_factory.cpp index 0b6916961..533514059 100644 --- a/src/object_factory.cpp +++ b/src/object_factory.cpp @@ -25,6 +25,7 @@ #include "lisp/lisp.hpp" #include "lisp/parser.hpp" #include "object_factory.hpp" +#include "math/vector.hpp" Factories* object_factories = 0; @@ -48,6 +49,8 @@ GameObject* create_object(const std::string& name, const Vector& pos) << " (y " << pos.y << "))"; lisp::Parser parser; - std::auto_ptr lisp (parser.parse(lisptext)); - return create_object(name, *lisp); + const lisp::Lisp* lisp = parser.parse(lisptext, "create_object"); + GameObject* object = create_object(name, *lisp); + + return object; }