Snowman enhancements: dead-script is passed to snowball, fireballs only kill body...
[supertux.git] / src / badguy / snowball.cpp
index 92769c7..3e286cc 100644 (file)
@@ -25,10 +25,11 @@ SnowBall::SnowBall(const Reader& reader)
   walk_speed = 80;
 }
 
-SnowBall::SnowBall(const Vector& pos, Direction d)
+SnowBall::SnowBall(const Vector& pos, Direction d, std::string script)
   : WalkingBadguy(pos, d, "images/creatures/snowball/snowball.sprite", "left", "right")
 {
   walk_speed = 80;
+  dead_script = script;
 }
 
 bool
@@ -39,6 +40,4 @@ SnowBall::collision_squished(GameObject& object)
   return true;
 }
 
-IMPLEMENT_FACTORY(SnowBall, "snowball");
-
 /* EOF */