Replaced Ref and RefCounter with std::shared_ptr<>
[supertux.git] / src / badguy / goldbomb.cpp
index 67c8002..87000f7 100644 (file)
@@ -160,8 +160,8 @@ GoldBomb::kill_fall()
 
   if(is_valid()) {
     remove_me();
-    Sector::current()->add_object(new Explosion(get_bbox().get_middle()));
-    Sector::current()->add_object(new CoinExplode(get_pos() + Vector (0, -40)));
+    Sector::current()->add_object(std::make_shared<Explosion>(get_bbox().get_middle()));
+    Sector::current()->add_object(std::make_shared<CoinExplode>(get_pos() + Vector (0, -40)));
   }
 
   run_dead_script();