From: Holger Schemel Date: Sun, 22 Jan 2023 23:27:36 +0000 (+0100) Subject: fixed bug with re-scanning laser when rotating teleporter in MM engine X-Git-Tag: 4.3.5.0~31 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=6d26e1e4259343003f378829a3f18ee5f7e7cdcd;p=rocksndiamonds.git fixed bug with re-scanning laser when rotating teleporter in MM engine The "fix" in commit 1b2237c9 fixed some old problems with handling teleporter elements, but caused new problems with overheating which should not happen. This change seems to fix both cases. --- diff --git a/src/game_mm/mm_game.c b/src/game_mm/mm_game.c index 8583a9a7..20e27068 100644 --- a/src/game_mm/mm_game.c +++ b/src/game_mm/mm_game.c @@ -3060,8 +3060,6 @@ void RotateMirror(int x, int y, int button) IS_POLAR(Tile[x][y]) || IS_POLAR_CROSS(Tile[x][y])) && x == ELX && y == ELY) { - check = 0; - if (IS_BEAMER(Tile[x][y])) { #if 0 @@ -3069,12 +3067,13 @@ void RotateMirror(int x, int y, int button) LX, LY, laser.beamer_edge, laser.beamer[1].num); #endif -#if 0 - laser.num_edges--; -#endif + if (check == 1) + laser.num_edges--; } ScanLaser(); + + check = 0; } if (check == 2)