Applied patch from Ryan:
authorRicardo Cruz <rick2@aeiou.pt>
Sat, 17 Apr 2004 12:00:31 +0000 (12:00 +0000)
committerRicardo Cruz <rick2@aeiou.pt>
Sat, 17 Apr 2004 12:00:31 +0000 (12:00 +0000)

This patch causes badguys to be killed when they run into an exploding bomb
or get hit by stalactite (as suggested by Ricardo).


SVN-Revision: 540

src/badguy.cpp

index 4c30fe6..2f79405 100644 (file)
@@ -973,6 +973,27 @@ BadGuy::collision(void *p_c_object, int c_object, CollisionType type)
           pbad_c->kill_me();
           kill_me();
         }
+
+      /* Kill badguys that run into exploding bomb */
+      else if (kind == BAD_BOMB && dying == DYING_NOT)
+      {
+        if (pbad_c->kind == BAD_MRBOMB)
+        {
+          // FIXME: this is where other MrBombs *should* explode istead of dying
+          pbad_c->kill_me(); 
+        }
+        else if (pbad_c->kind != BAD_BOMB)
+        {
+          pbad_c->kill_me();
+        }
+      }
+
+      /* Kill any badguys that get hit by stalactite */
+      else if (kind == BAD_STALACTITE && dying == DYING_NOT)
+      {
+        pbad_c->kill_me();
+      }
+      
       break;
     }
 }