(svn r1321) -Fix: Revision 1302 partly solved the problem and created an other.
authortruelight
Sat, 01 Jan 2005 19:18:48 +0000
changeset 840 79b6733ddbab
parent 839 62e15965a3d8
child 841 8f0a68c6f43b
(svn r1321) -Fix: Revision 1302 partly solved the problem and created an other.
Should now really be solved.. now only MP_WATER is owned by OWNER_WATER
landscape.c
ttd.c
--- a/landscape.c	Sat Jan 01 16:34:54 2005 +0000
+++ b/landscape.c	Sat Jan 01 19:18:48 2005 +0000
@@ -483,12 +483,12 @@
 	uint map_size = MapSize();
 	int i;
 
-	memset(_map_owner, OWNER_WATER, map_size);
+	memset(_map_owner, OWNER_NONE, map_size);
 	memset(_map2, 0, map_size * sizeof(uint16));
 	memset(_map3_lo, 0, map_size);
 	memset(_map3_hi, 0, map_size);
 	memset(_map_extra_bits, 0, map_size / 4);
-	memset(_map_type_and_height, MP_WATER << 4, map_size);
+	memset(_map_type_and_height, MP_CLEAR << 4, map_size);
 
 	for(i=0; i!=TILES_Y-1; i++)
 		memset(_map_type_and_height + i*TILES_X, 0, TILES_X-1);
--- a/ttd.c	Sat Jan 01 16:34:54 2005 +0000
+++ b/ttd.c	Sat Jan 01 19:18:48 2005 +0000
@@ -1241,6 +1241,8 @@
 		BEGIN_TILE_LOOP(tile_cur, w, h, tile)
 			if (IS_TILETYPE(tile_cur, MP_WATER) && _map_owner[tile_cur] != OWNER_WATER)
 				_map_owner[tile_cur] = OWNER_WATER;
+			if (!IS_TILETYPE(tile_cur, MP_WATER) && _map_owner[tile_cur] == OWNER_WATER)
+				_map_owner[tile_cur] = OWNER_NONE;
 		END_TILE_LOOP(tile_cur, w, h, tile)
 	}