From: Holger Schemel Date: Fri, 7 Apr 2017 06:42:46 +0000 (+0200) Subject: fixed bug with laser still growing amoeba after it was destroyed by bomb X-Git-Tag: 4.1.0.0~131 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=2895db657f196ef3daae3d210b93315eb815f155;p=rocksndiamonds.git fixed bug with laser still growing amoeba after it was destroyed by bomb --- diff --git a/src/game_mm/mm_game.c b/src/game_mm/mm_game.c index 3a0c60d1..f89e23d8 100644 --- a/src/game_mm/mm_game.c +++ b/src/game_mm/mm_game.c @@ -275,6 +275,9 @@ static void InitLaser() laser.num_beamers = 0; laser.beamer_edge[0] = 0; + laser.dest_element = EL_EMPTY; + laser.wall_mask = 0; + AddLaserEdge(LX, LY); /* set laser starting edge */ pen_ray = GetPixelFromRGB(window, @@ -2181,9 +2184,8 @@ static void Explode_MM(int x, int y, int phase, int mode) { if (Store[x][y] == EL_BOMB) { - laser.num_damages--; DrawLaser(0, DL_LASER_DISABLED); - laser.num_edges = 0; + InitLaser(); Bang_MM(laser.start_edge.x, laser.start_edge.y); Store[x][y] = EL_EMPTY;