Removed vertical flipping drawing hacks.
[supertux.git] / src / world.cpp
index 0c28cb0..98b1ed5 100644 (file)
@@ -43,6 +43,7 @@ Surface* img_distro[4];
 World* World::current_ = 0;
 
 World::World(const std::string& filename, int level_nr)
+  : level(0), tux(0), background(0), camera(0)
 {
   // FIXME: Move this to action and draw and everywhere else where the
   // world calls child functions
@@ -96,7 +97,7 @@ World::apply_bonuses()
       // fall through
                                                                                 
     case PlayerStatus::GROWUP_BONUS:
-      tux->grow();
+      tux->grow(false);
       break;
     }
 }
@@ -109,6 +110,8 @@ World::~World()
   }
 
   delete level;
+
+  current_ = 0;
 }
 
 void
@@ -197,8 +200,7 @@ World::draw()
 void
 World::action(float elapsed_time)
 {
-  tux->check_bounds(*camera,
-      level->back_scrolling, (bool)level->hor_autoscroll_speed);
+  tux->check_bounds(*camera);
     
   /* update objects (don't use iterators here, because the list might change
    * during the iteration)