From: Ingo Ruhnke Date: Wed, 28 Apr 2004 20:34:24 +0000 (+0000) Subject: - memleak fix for my last patch X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=da7faeddfb10376f75e8dfa59a70ad71a8d81518;p=supertux.git - memleak fix for my last patch - iceflower/growup crash fix (well, maybe) SVN-Revision: 819 --- diff --git a/src/special.cpp b/src/special.cpp index b1136c7bd..4ae5fcd43 100644 --- a/src/special.cpp +++ b/src/special.cpp @@ -333,12 +333,6 @@ Upgrade::collision(void* p_c_object, int c_object, CollisionType type) pplayer->size = BIG; pplayer->base.height = 64; pplayer->base.y -= 32; - if(collision_object_map(pplayer->base)) - { - pplayer->base.height = 32; - pplayer->base.y += 32; - pplayer->duck = true; - } } else if (kind == UPGRADE_ICEFLOWER) { diff --git a/src/world.cpp b/src/world.cpp index 7ec7eacdf..1c1875686 100644 --- a/src/world.cpp +++ b/src/world.cpp @@ -105,6 +105,22 @@ World::~World() for (ParticleSystems::iterator i = particle_systems.begin(); i != particle_systems.end(); ++i) delete *i; + + for (std::vector::iterator i = bouncy_distros.begin(); + i != bouncy_distros.end(); ++i) + delete *i; + + for (std::vector::iterator i = broken_bricks.begin(); + i != broken_bricks.end(); ++i) + delete *i; + + for (std::vector::iterator i = bouncy_bricks.begin(); + i != bouncy_bricks.end(); ++i) + delete *i; + + for (std::vector::iterator i = floating_scores.begin(); + i != floating_scores.end(); ++i) + delete *i; delete level; }