- Refactored worldmap a bit to reuse GameObject from the rest of the game
[supertux.git] / src / level.cpp
index ae81a34..e9f8ccd 100644 (file)
 #include <memory>
 #include <stdexcept>
 
-#include "app/globals.h"
-#include "app/setup.h"
 #include "video/screen.h"
 #include "lisp/parser.h"
 #include "lisp/lisp.h"
 #include "lisp/list_iterator.h"
 #include "lisp/writer.h"
 #include "level.h"
-#include "math/physic.h"
+#include "physic.h"
 #include "sector.h"
 #include "tile.h"
 #include "resources.h"
+#include "file_system.h"
 #include "object/gameobjs.h"
 #include "object/camera.h"
 #include "object/tilemap.h"
@@ -52,7 +51,7 @@
 using namespace std;
 
 Level::Level()
-  : name("noname"), author("Mr. X"), timelimit(500)
+  : name("noname"), author("Mr. X")
 {
 }
 
@@ -93,8 +92,6 @@ Level::load(const std::string& filepath)
         iter.value()->get(name);
       } else if(token == "author") {
         iter.value()->get(author);
-      } else if(token == "time") {
-        iter.value()->get(timelimit);
       } else if(token == "sector") {
         Sector* sector = new Sector;
         sector->parse(*(iter.lisp()));
@@ -117,7 +114,6 @@ Level::load_old_format(const lisp::Lisp& reader)
 {
   reader.get("name", name);
   reader.get("author", author);
-  reader.get("time", timelimit);
 
   Sector* sector = new Sector;
   sector->parse_old_format(reader);
@@ -143,7 +139,6 @@ Level::save(const std::string& filename)
 
   writer->write_string("name", name, true);
   writer->write_string("author", author);
-  writer->write_int("time", timelimit);
 
   for(Sectors::iterator i = sectors.begin(); i != sectors.end(); ++i) {
     Sector* sector = *i;