From 1c4eb5a346617664721948fe28d075fbd9922231 Mon Sep 17 00:00:00 2001 From: "jason@long.name" Date: Sun, 11 Aug 2013 04:07:07 +0000 Subject: [PATCH] engine bugfix: when downgrading full res to little houses, preserve pwrbit This fixes the bug where a powered RES zone will temporarily flash "no power" when it downgrades from full to partial. git-svn-id: https://micropolis.googlecode.com/svn/trunk/micropolis-java@780 d9718cc8-9f43-0410-858b-315f434eb58c --- src/micropolisj/engine/MapScanner.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/micropolisj/engine/MapScanner.java b/src/micropolisj/engine/MapScanner.java index 883badc..1e89cd4 100644 --- a/src/micropolisj/engine/MapScanner.java +++ b/src/micropolisj/engine/MapScanner.java @@ -1149,7 +1149,8 @@ class MapScanner { // downgrade from full-size zone to 8 little houses - city.setTile(xpos, ypos, (char)(FREEZ | BULLBIT)); + int pwrBit = (cchr & PWRBIT); + city.setTile(xpos, ypos, (char)(FREEZ | BULLBIT | pwrBit)); for (int x = xpos-1; x <= xpos+1; x++) { for (int y = ypos-1; y <= ypos+1; y++)