--- a/src/town_cmd.cpp Wed Jun 13 11:00:24 2007 +0000
+++ b/src/town_cmd.cpp Wed Jun 13 11:17:30 2007 +0000
@@ -247,9 +247,9 @@
static void MarkTownSignDirty(Town *t)
{
MarkAllViewportsDirty(
- t->sign.left-6,
- t->sign.top-3,
- t->sign.left+t->sign.width_1*4+12,
+ t->sign.left - 6,
+ t->sign.top - 3,
+ t->sign.left + t->sign.width_1 * 4 + 12,
t->sign.top + 45
);
}
@@ -525,10 +525,10 @@
no_slope:
/* Tile has no slope
* Disallow the road if any neighboring tile has a road. */
- if (HASBIT(GetTownRoadMask(TILE_ADD(tile, ToTileIndexDiff(_roadblock_tileadd[dir+1]))), dir^2) ||
- HASBIT(GetTownRoadMask(TILE_ADD(tile, ToTileIndexDiff(_roadblock_tileadd[dir+3]))), dir^2) ||
- HASBIT(GetTownRoadMask(TILE_ADD(tile, ToTileIndexDiff(_roadblock_tileadd[dir+1]) + ToTileIndexDiff(_roadblock_tileadd[dir+2]))), dir) ||
- HASBIT(GetTownRoadMask(TILE_ADD(tile, ToTileIndexDiff(_roadblock_tileadd[dir+3]) + ToTileIndexDiff(_roadblock_tileadd[dir+2]))), dir))
+ if (HASBIT(GetTownRoadMask(TILE_ADD(tile, ToTileIndexDiff(_roadblock_tileadd[dir + 1]))), dir ^ 2) ||
+ HASBIT(GetTownRoadMask(TILE_ADD(tile, ToTileIndexDiff(_roadblock_tileadd[dir + 3]))), dir ^ 2) ||
+ HASBIT(GetTownRoadMask(TILE_ADD(tile, ToTileIndexDiff(_roadblock_tileadd[dir + 1]) + ToTileIndexDiff(_roadblock_tileadd[dir + 2]))), dir) ||
+ HASBIT(GetTownRoadMask(TILE_ADD(tile, ToTileIndexDiff(_roadblock_tileadd[dir + 3]) + ToTileIndexDiff(_roadblock_tileadd[dir + 2]))), dir))
return false;
/* Otherwise allow */
@@ -639,7 +639,7 @@
}
rcmd = (RoadBits)((1 << a) + (1 << b));
- } else if (block < 5 && !HASBIT(mask,block^2)) {
+ } else if (block < 5 && !HASBIT(mask, block ^ 2)) {
/* Continue building on a partial road.
* Always OK. */
_grow_town_result = 0;
@@ -766,7 +766,7 @@
/* Select a random bit from the blockmask, walk a step
* and continue the search from there. */
- do block = Random() & 3; while (!HASBIT(mask,block));
+ do block = Random() & 3; while (!HASBIT(mask, block));
tile += ToTileIndexDiff(_roadblock_tileadd[block]);
if (IsTileType(tile, MP_STREET)) {