(svn r9674) [gamebalance] -Sync: r9322:9420 from trunk gamebalance
authorcelestar
Thu, 19 Apr 2007 14:43:25 +0000
branchgamebalance
changeset 9906 6f41b8713b65
parent 9905 91eca6fdee8d
child 9907 3b068c3a1c74
(svn r9674) [gamebalance] -Sync: r9322:9420 from trunk
configure
projects/openttd.vcproj
projects/openttd_vs80.vcproj
source.list
src/ai/default/default.cpp
src/aircraft_cmd.cpp
src/cargotype.cpp
src/cargotype.h
src/clear_cmd.cpp
src/economy.cpp
src/economy.h
src/genworld_gui.cpp
src/gfx.cpp
src/gfxinit.cpp
src/graph_gui.cpp
src/industry_cmd.cpp
src/intro_gui.cpp
src/landscape.cpp
src/landscape.h
src/lang/brazilian_portuguese.txt
src/lang/danish.txt
src/lang/esperanto.txt
src/lang/estonian.txt
src/lang/finnish.txt
src/lang/french.txt
src/lang/german.txt
src/lang/hungarian.txt
src/lang/italian.txt
src/lang/portuguese.txt
src/lang/simplified_chinese.txt
src/lang/traditional_chinese.txt
src/lang/ukrainian.txt
src/main_gui.cpp
src/misc.cpp
src/misc_gui.cpp
src/namegen.cpp
src/namegen.h
src/network/network.cpp
src/newgrf.cpp
src/newgrf.h
src/newgrf_callbacks.h
src/newgrf_cargo.cpp
src/newgrf_cargo.h
src/newgrf_config.cpp
src/newgrf_config.h
src/newgrf_engine.cpp
src/newgrf_engine.h
src/newgrf_gui.cpp
src/newgrf_house.cpp
src/newgrf_sound.cpp
src/newgrf_sound.h
src/newgrf_spritegroup.cpp
src/newgrf_spritegroup.h
src/newgrf_station.cpp
src/newgrf_text.cpp
src/newgrf_text.h
src/news.h
src/news_gui.cpp
src/npf.cpp
src/npf.h
src/oldloader.cpp
src/oldpool.cpp
src/oldpool.h
src/openttd.cpp
src/openttd.h
src/order_cmd.cpp
src/order_gui.cpp
src/os2.cpp
src/os_timer.cpp
src/pathfind.cpp
src/pathfind.h
src/player.h
src/player_face.h
src/player_gui.cpp
src/players.cpp
src/queue.cpp
src/queue.h
src/rail_cmd.cpp
src/road_cmd.cpp
src/roadveh_cmd.cpp
src/settings.cpp
src/settings.h
src/ship_cmd.cpp
src/smallmap_gui.cpp
src/station_cmd.cpp
src/station_gui.cpp
src/strings.cpp
src/table/build_industry.h
src/table/cargo_const.h
src/table/town_land.h
src/texteff.cpp
src/tgp.cpp
src/town.h
src/town_cmd.cpp
src/train_cmd.cpp
src/train_gui.cpp
src/tree_cmd.cpp
src/tunnelbridge_cmd.cpp
src/unmovable_cmd.cpp
src/variables.h
src/vehicle.cpp
src/vehicle_gui.cpp
--- a/configure	Sun Apr 01 09:38:43 2007 +0000
+++ b/configure	Thu Apr 19 14:43:25 2007 +0000
@@ -3,7 +3,11 @@
 CONFIGURE_EXECUTABLE="$_"
 # On *nix systems those two are equal when ./configure is done
 if [ "$0" != "$CONFIGURE_EXECUTABLE" ]; then
-	CONFIGURE_EXECUTABLE="$CONFIGURE_EXECUTABLE $0"
+	if [ -z "`echo $CONFIGURE_EXECUTABLE | grep make`" ]; then
+		CONFIGURE_EXECUTABLE="$0"
+	else
+		CONFIGURE_EXECUTABLE="$CONFIGURE_EXECUTABLE $0"
+	fi
 fi
 # Find out where configure is (in what dir)
 ROOT_DIR="`dirname $0`"
--- a/projects/openttd.vcproj	Sun Apr 01 09:38:43 2007 +0000
+++ b/projects/openttd.vcproj	Thu Apr 19 14:43:25 2007 +0000
@@ -932,6 +932,9 @@
 				RelativePath=".\..\src\newgrf.cpp">
 			</File>
 			<File
+				RelativePath=".\..\src\newgrf_cargo.cpp">
+			</File>
+			<File
 				RelativePath=".\..\src\newgrf_config.cpp">
 			</File>
 			<File
--- a/projects/openttd_vs80.vcproj	Sun Apr 01 09:38:43 2007 +0000
+++ b/projects/openttd_vs80.vcproj	Thu Apr 19 14:43:25 2007 +0000
@@ -1464,6 +1464,10 @@
 				>
 			</File>
 			<File
+				RelativePath=".\..\src\newgrf_cargo.cpp"
+				>
+			</File>
+			<File
 				RelativePath=".\..\src\newgrf_config.cpp"
 				>
 			</File>
--- a/source.list	Sun Apr 01 09:38:43 2007 +0000
+++ b/source.list	Thu Apr 19 14:43:25 2007 +0000
@@ -281,6 +281,7 @@
 
 # NewGRF
 newgrf.cpp
+newgrf_cargo.cpp
 newgrf_config.cpp
 newgrf_engine.cpp
 newgrf_house.cpp
--- a/src/ai/default/default.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/ai/default/default.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -2461,7 +2461,7 @@
 		bool is_pass = (
 			p->ai.cargo_type == CT_PASSENGERS ||
 			p->ai.cargo_type == CT_MAIL ||
-			(_opt.landscape == LT_NORMAL && p->ai.cargo_type == CT_VALUABLES)
+			(_opt.landscape == LT_TEMPERATE && p->ai.cargo_type == CT_VALUABLES)
 		);
 		Order order;
 
@@ -3203,7 +3203,7 @@
 		bool is_pass = (
 			p->ai.cargo_type == CT_PASSENGERS ||
 			p->ai.cargo_type == CT_MAIL ||
-			(_opt.landscape == LT_NORMAL && p->ai.cargo_type == CT_VALUABLES)
+			(_opt.landscape == LT_TEMPERATE && p->ai.cargo_type == CT_VALUABLES)
 		);
 		Order order;
 
--- a/src/aircraft_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/aircraft_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -30,6 +30,7 @@
 #include "newgrf_sound.h"
 #include "date.h"
 #include "spritecache.h"
+#include "cargotype.h"
 
 /** this maps the terminal to its corresponding state and block flag
  *  currently set for 10 terms, 4 helipads */
@@ -647,7 +648,7 @@
 		v->cargo_cap = pass;
 
 		Vehicle *u = v->next;
-		uint mail = new_cid != CT_PASSENGERS ? 0 : avi->mail_capacity;
+		uint mail = IsCargoInClass(new_cid, CC_PASSENGERS) ? avi->mail_capacity : 0;
 		u->cargo_cap = mail;
 		if (v->cargo_type == new_cid) {
 			v->cargo_count = min(pass, v->cargo_count);
@@ -1407,7 +1408,7 @@
 	if (GB(Random(), 0, 16) > prob) return;
 
 	/* Crash the airplane. Remove all goods stored at the station. */
-	for (uint i = 0; i != NUM_CARGO; i++) {
+	for (CargoID i = 0; i < NUM_CARGO; i++) {
 		st->goods[i].rating = 1;
 		SB(st->goods[i].waiting_acceptance, 0, 12, 0);
 	}
--- a/src/cargotype.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/cargotype.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -12,7 +12,7 @@
 
 #include "table/cargo_const.h"
 
-static CargoSpec _cargo[NUM_CARGO];
+CargoSpec _cargo[NUM_CARGO];
 
 static const byte INVALID_CARGO = 0xFF;
 
@@ -64,6 +64,7 @@
 CargoID GetCargoIDByLabel(CargoLabel cl)
 {
 	for (CargoID c = 0; c < lengthof(_cargo); c++) {
+		if (_cargo[c].bitnum == INVALID_CARGO) continue;
 		if (_cargo[c].label == cl) return c;
 	}
 
--- a/src/cargotype.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/cargotype.h	Thu Apr 19 14:43:25 2007 +0000
@@ -31,7 +31,7 @@
 	bool is_freight;
 	TownEffect town_effect; ///< The effect this cargo type has on towns
 	uint16 multipliertowngrowth;
-	uint8 callbackflags;
+	uint8 callback_mask;
 
 	StringID name;
 	StringID name_plural;
@@ -42,12 +42,14 @@
 	SpriteID sprite;
 
 	uint16 classes;
+	const struct SpriteGroup *group;
 
 	bool IsValid() const;
 };
 
 
 extern uint32 _cargo_mask;
+extern CargoSpec _cargo[NUM_CARGO];
 
 
 /* Set up the default cargo types for the given landscape type */
--- a/src/clear_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/clear_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -16,6 +16,7 @@
 #include "tunnel_map.h"
 #include "bridge_map.h"
 #include "bridge.h"
+#include "landscape.h"
 #include "variables.h"
 #include "table/sprites.h"
 #include "unmovable_map.h"
@@ -621,7 +622,7 @@
 /* convert into snowy tiles */
 static void TileLoopClearAlps(TileIndex tile)
 {
-	int k = GetTileZ(tile) - _opt.snow_line + TILE_HEIGHT;
+	int k = GetTileZ(tile) - GetSnowLine() + TILE_HEIGHT;
 
 	if (k < 0) { // well below the snow line
 		if (!IsClearGround(tile, CLEAR_SNOW)) return;
@@ -668,8 +669,8 @@
 	TileLoopClearHelper(tile);
 
 	switch (_opt.landscape) {
-		case LT_DESERT: TileLoopClearDesert(tile); break;
-		case LT_HILLY:  TileLoopClearAlps(tile);   break;
+		case LT_TROPIC: TileLoopClearDesert(tile); break;
+		case LT_ARCTIC: TileLoopClearAlps(tile);   break;
 	}
 
 	switch (GetClearGround(tile)) {
--- a/src/economy.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/economy.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -967,7 +967,7 @@
 	byte f;
 
 	/* zero the distance if it's the bank and very short transport. */
-	if (_opt.landscape == LT_NORMAL && cs->label == 'VALU' && dist < 10)
+	if (_opt.landscape == LT_TEMPERATE && cs->label == 'VALU' && dist < 10)
 		dist = 0;
 
 	f = 255;
--- a/src/economy.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/economy.h	Thu Apr 19 14:43:25 2007 +0000
@@ -66,6 +66,6 @@
 void DeleteSubsidyWithStation(StationID index);
 
 int32 GetTransportedGoodsIncome(uint num_pieces, uint dist, byte transit_days, CargoID cargo_type);
-uint MoveGoodsToStation(TileIndex tile, int w, int h, int type, uint amount);
+uint MoveGoodsToStation(TileIndex tile, int w, int h, CargoID type, uint amount);
 
 #endif /* ECONOMY_H */
--- a/src/genworld_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/genworld_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -240,7 +240,7 @@
 			SetWindowWidgetDisabledState(w, GLAND_SMOOTHNESS_PULLDOWN, _patches_newgame.land_generator == 0);
 		}
 		/* Disable snowline if not hilly */
-		SetWindowWidgetDisabledState(w, GLAND_SNOW_LEVEL_TEXT, _opt_newgame.landscape != LT_HILLY);
+		SetWindowWidgetDisabledState(w, GLAND_SNOW_LEVEL_TEXT, _opt_newgame.landscape != LT_ARCTIC);
 		/* Disable town, industry and trees in SE */
 		SetWindowWidgetDisabledState(w, GLAND_TOWN_TEXT,         _game_mode == GM_EDITOR);
 		SetWindowWidgetDisabledState(w, GLAND_TOWN_PULLDOWN,     _game_mode == GM_EDITOR);
@@ -251,13 +251,13 @@
 
 		SetWindowWidgetDisabledState(w, GLAND_START_DATE_DOWN, _patches_newgame.starting_year <= MIN_YEAR);
 		SetWindowWidgetDisabledState(w, GLAND_START_DATE_UP,   _patches_newgame.starting_year >= MAX_YEAR);
-		SetWindowWidgetDisabledState(w, GLAND_SNOW_LEVEL_DOWN, _patches_newgame.snow_line_height <= 2 || _opt_newgame.landscape != LT_HILLY);
-		SetWindowWidgetDisabledState(w, GLAND_SNOW_LEVEL_UP,   _patches_newgame.snow_line_height >= 13 || _opt_newgame.landscape != LT_HILLY);
+		SetWindowWidgetDisabledState(w, GLAND_SNOW_LEVEL_DOWN, _patches_newgame.snow_line_height <= 2 || _opt_newgame.landscape != LT_ARCTIC);
+		SetWindowWidgetDisabledState(w, GLAND_SNOW_LEVEL_UP,   _patches_newgame.snow_line_height >= 13 || _opt_newgame.landscape != LT_ARCTIC);
 
-		SetWindowWidgetLoweredState(w, GLAND_TEMPERATE, _opt_newgame.landscape == LT_NORMAL);
-		SetWindowWidgetLoweredState(w, GLAND_ARCTIC,    _opt_newgame.landscape == LT_HILLY);
-		SetWindowWidgetLoweredState(w, GLAND_TROPICAL,  _opt_newgame.landscape == LT_DESERT);
-		SetWindowWidgetLoweredState(w, GLAND_TOYLAND,   _opt_newgame.landscape == LT_CANDY);
+		SetWindowWidgetLoweredState(w, GLAND_TEMPERATE, _opt_newgame.landscape == LT_TEMPERATE);
+		SetWindowWidgetLoweredState(w, GLAND_ARCTIC,    _opt_newgame.landscape == LT_ARCTIC);
+		SetWindowWidgetLoweredState(w, GLAND_TROPICAL,  _opt_newgame.landscape == LT_TROPIC);
+		SetWindowWidgetLoweredState(w, GLAND_TOYLAND,   _opt_newgame.landscape == LT_TOYLAND);
 		DrawWindowWidgets(w);
 
 		y = (mode == GLWP_HEIGHTMAP) ? 22 : 0;
@@ -589,10 +589,10 @@
 		SetWindowWidgetDisabledState(w, CSCEN_FLAT_LAND_HEIGHT_DOWN, _patches_newgame.se_flat_world_height <= 0);
 		SetWindowWidgetDisabledState(w, CSCEN_FLAT_LAND_HEIGHT_UP,   _patches_newgame.se_flat_world_height >= 15);
 
-		SetWindowWidgetLoweredState(w, CSCEN_TEMPERATE, _opt_newgame.landscape == LT_NORMAL);
-		SetWindowWidgetLoweredState(w, CSCEN_ARCTIC,    _opt_newgame.landscape == LT_HILLY);
-		SetWindowWidgetLoweredState(w, CSCEN_TROPICAL,  _opt_newgame.landscape == LT_DESERT);
-		SetWindowWidgetLoweredState(w, CSCEN_TOYLAND,   _opt_newgame.landscape == LT_CANDY);
+		SetWindowWidgetLoweredState(w, CSCEN_TEMPERATE, _opt_newgame.landscape == LT_TEMPERATE);
+		SetWindowWidgetLoweredState(w, CSCEN_ARCTIC,    _opt_newgame.landscape == LT_ARCTIC);
+		SetWindowWidgetLoweredState(w, CSCEN_TROPICAL,  _opt_newgame.landscape == LT_TROPIC);
+		SetWindowWidgetLoweredState(w, CSCEN_TOYLAND,   _opt_newgame.landscape == LT_TOYLAND);
 		DrawWindowWidgets(w);
 
 		DrawStringRightAligned(211, 97, STR_MAPSIZE, 0);
--- a/src/gfx.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/gfx.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1555,7 +1555,7 @@
 	memcpy(old_val, d, c * sizeof(*old_val));
 
 	/* Dark blue water */
-	s = (_opt.landscape == LT_CANDY) ? ev->ac : ev->a;
+	s = (_opt.landscape == LT_TOYLAND) ? ev->ac : ev->a;
 	j = EXTR(320, 5);
 	for (i = 0; i != 5; i++) {
 		*d++ = s[j];
@@ -1564,7 +1564,7 @@
 	}
 
 	/* Glittery water */
-	s = (_opt.landscape == LT_CANDY) ? ev->bc : ev->b;
+	s = (_opt.landscape == LT_TOYLAND) ? ev->bc : ev->b;
 	j = EXTR(128, 15);
 	for (i = 0; i != 5; i++) {
 		*d++ = s[j];
@@ -1624,7 +1624,7 @@
 	/* Animate water for old DOS graphics */
 	if (_use_dos_palette) {
 		/* Dark blue water DOS */
-		s = (_opt.landscape == LT_CANDY) ? ev->ac : ev->a;
+		s = (_opt.landscape == LT_TOYLAND) ? ev->ac : ev->a;
 		j = EXTR(320, 5);
 		for (i = 0; i != 5; i++) {
 			*d++ = s[j];
@@ -1633,7 +1633,7 @@
 		}
 
 		/* Glittery water DOS */
-		s = (_opt.landscape == LT_CANDY) ? ev->bc : ev->b;
+		s = (_opt.landscape == LT_TOYLAND) ? ev->bc : ev->b;
 		j = EXTR(128, 15);
 		for (i = 0; i != 5; i++) {
 			*d++ = s[j];
--- a/src/gfxinit.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/gfxinit.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -357,7 +357,7 @@
 	}
 
 	/* Load additional sprites for climates other than temperate */
-	if (_opt.landscape != LT_NORMAL) {
+	if (_opt.landscape != LT_TEMPERATE) {
 		LoadGrfIndexed(
 			files->landscape[_opt.landscape - 1].filename,
 			_landscape_spriteindexes[_opt.landscape - 1],
--- a/src/graph_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/graph_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -721,7 +721,7 @@
 			gd.x_values_increment = 10;
 
 			uint i = 0;
-			for (CargoID c = 0; c != NUM_CARGO; c++) {
+			for (CargoID c = 0; c < NUM_CARGO; c++) {
 				const CargoSpec *cs = GetCargo(c);
 				if (!cs->IsValid()) continue;
 
@@ -791,7 +791,7 @@
 
 	/* Count the number of active cargo types */
 	uint num_active = 0;
-	for (CargoID c = 0; c != NUM_CARGO; c++) {
+	for (CargoID c = 0; c < NUM_CARGO; c++) {
 		if (GetCargo(c)->IsValid()) num_active++;
 	}
 
--- a/src/industry_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/industry_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -12,6 +12,7 @@
 #include "table/sprites.h"
 #include "map.h"
 #include "tile.h"
+#include "landscape.h"
 #include "viewport.h"
 #include "command.h"
 #include "industry.h"
@@ -813,14 +814,14 @@
 	uint field_type;
 	int type;
 
-	if (_opt.landscape == LT_HILLY) {
-		if (GetTileZ(tile) + TILE_HEIGHT * 2 >= _opt.snow_line)
+	if (_opt.landscape == LT_ARCTIC) {
+		if (GetTileZ(tile) + TILE_HEIGHT * 2 >= GetSnowLine())
 			return;
 	}
 
 	/* determine field size */
 	r = (Random() & 0x303) + 0x404;
-	if (_opt.landscape == LT_HILLY) r += 0x404;
+	if (_opt.landscape == LT_ARCTIC) r += 0x404;
 	size_x = GB(r, 0, 8);
 	size_y = GB(r, 8, 8);
 
@@ -851,7 +852,7 @@
 	END_TILE_LOOP(cur_tile, size_x, size_y, tile)
 
 	type = 3;
-	if (_opt.landscape != LT_HILLY && _opt.landscape != LT_DESERT) {
+	if (_opt.landscape != LT_ARCTIC && _opt.landscape != LT_TROPIC) {
 		type = _plantfarmfield_type[Random() & 0xF];
 	}
 
@@ -1015,8 +1016,8 @@
 
 static bool CheckNewIndustry_Forest(TileIndex tile)
 {
-	if (_opt.landscape == LT_HILLY) {
-		if (GetTileZ(tile) < _opt.snow_line + TILE_HEIGHT * 2U) {
+	if (_opt.landscape == LT_ARCTIC) {
+		if (GetTileZ(tile) < HighestSnowLine() + TILE_HEIGHT * 2U) {
 			_error_message = STR_4831_FOREST_CAN_ONLY_BE_PLANTED;
 			return false;
 		}
@@ -1047,8 +1048,8 @@
 
 static bool CheckNewIndustry_Farm(TileIndex tile)
 {
-	if (_opt.landscape == LT_HILLY) {
-		if (GetTileZ(tile) + TILE_HEIGHT * 2 >= _opt.snow_line) {
+	if (_opt.landscape == LT_ARCTIC) {
+		if (GetTileZ(tile) + TILE_HEIGHT * 2 >= HighestSnowLine()) {
 			_error_message = STR_0239_SITE_UNSUITABLE;
 			return false;
 		}
@@ -1765,7 +1766,7 @@
 
 		case INDUSTRYLIFE_PRODUCTION:
 			/* decrease or increase */
-			if (type == IT_OIL_WELL && _opt.landscape == LT_NORMAL)
+			if (type == IT_OIL_WELL && _opt.landscape == LT_TEMPERATE)
 				only_decrease = true;
 
 			if (only_decrease || CHANCE16(1,3)) {
--- a/src/intro_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/intro_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -55,10 +55,10 @@
 	case WE_CREATE: LowerWindowWidget(w, _opt_newgame.landscape + 8); break;
 
 	case WE_PAINT:
-		SetWindowWidgetLoweredState(w, 8,  _opt_newgame.landscape == LT_NORMAL);
-		SetWindowWidgetLoweredState(w, 9,  _opt_newgame.landscape == LT_HILLY);
-		SetWindowWidgetLoweredState(w, 10, _opt_newgame.landscape == LT_DESERT);
-		SetWindowWidgetLoweredState(w, 11, _opt_newgame.landscape == LT_CANDY);
+		SetWindowWidgetLoweredState(w, 8,  _opt_newgame.landscape == LT_TEMPERATE);
+		SetWindowWidgetLoweredState(w, 9,  _opt_newgame.landscape == LT_ARCTIC);
+		SetWindowWidgetLoweredState(w, 10, _opt_newgame.landscape == LT_TROPIC);
+		SetWindowWidgetLoweredState(w, 11, _opt_newgame.landscape == LT_TOYLAND);
 		SetDParam(0, STR_6801_EASY + _opt_newgame.diff_level);
 		DrawWindowWidgets(w);
 		break;
--- a/src/landscape.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/landscape.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -5,6 +5,7 @@
 #include "bridge_map.h"
 #include "heightmap.h"
 #include "clear_map.h"
+#include "date.h"
 #include "functions.h"
 #include "map.h"
 #include "player.h"
@@ -14,6 +15,7 @@
 #include <stdarg.h>
 #include "viewport.h"
 #include "command.h"
+#include "landscape.h"
 #include "vehicle.h"
 #include "variables.h"
 #include "void_map.h"
@@ -61,6 +63,7 @@
 	SLOPE_NWS, SLOPE_WSE, SLOPE_SEN, SLOPE_ENW
 };
 
+SnowLine *_snow_line = NULL;
 
 uint GetPartialZ(int x, int y, Slope corners)
 {
@@ -302,6 +305,62 @@
 	_tile_type_procs[GetTileType(tile)]->get_tile_desc_proc(tile, td);
 }
 
+/**
+ * Has a snow line table already been loaded.
+ * @return true if the table has been loaded already.
+ */
+bool IsSnowLineSet(void)
+{
+	return _snow_line != NULL;
+}
+
+/**
+ * Set a variable snow line, as loaded from a newgrf file.
+ * @param table the 12 * 32 byte table containing the snowline for each day
+ */
+void SetSnowLine(byte table[SNOW_LINE_MONTHS][SNOW_LINE_DAYS])
+{
+	_snow_line = CallocT<SnowLine>(1);
+	memcpy(_snow_line->table, table, sizeof(_snow_line->table));
+
+	for (uint i = 0; i < SNOW_LINE_MONTHS; i++) {
+		for (uint j = 0; j < SNOW_LINE_DAYS; j++) {
+			_snow_line->highest_value = max(_snow_line->highest_value, table[i][j]);
+		}
+	}
+}
+
+/**
+ * Get the current snow line, either variable or static.
+ * @return the snow line height.
+ */
+byte GetSnowLine(void)
+{
+	if (_snow_line == NULL) return _opt.snow_line;
+
+	YearMonthDay ymd;
+	ConvertDateToYMD(_date, &ymd);
+	return _snow_line->table[ymd.month][ymd.day];
+}
+
+/**
+ * Get the highest possible snow line height, either variable or static.
+ * @return the highest snow line height.
+ */
+byte HighestSnowLine(void)
+{
+	return _snow_line == NULL ? _opt.snow_line : _snow_line->highest_value;
+}
+
+/**
+ * Clear the variable snow line table and free the memory.
+ */
+void ClearSnowLine(void)
+{
+	free(_snow_line);
+	_snow_line = NULL;
+}
+
 /** Clear a piece of landscape
  * @param tile tile to clear
  * @param flags of operation to conduct
@@ -633,15 +692,15 @@
 	uint32 r;
 
 	if (mode == GW_HEIGHTMAP) {
-		SetGeneratingWorldProgress(GWP_LANDSCAPE, (_opt.landscape == LT_DESERT) ? 1 + gwp_desert_amount : 1);
+		SetGeneratingWorldProgress(GWP_LANDSCAPE, (_opt.landscape == LT_TROPIC) ? 1 + gwp_desert_amount : 1);
 		LoadHeightmap(_file_to_saveload.name);
 		IncreaseGeneratingWorldProgress(GWP_LANDSCAPE);
 	} else if (_patches.land_generator == LG_TERRAGENESIS) {
-		SetGeneratingWorldProgress(GWP_LANDSCAPE, (_opt.landscape == LT_DESERT) ? 3 + gwp_desert_amount : 3);
+		SetGeneratingWorldProgress(GWP_LANDSCAPE, (_opt.landscape == LT_TROPIC) ? 3 + gwp_desert_amount : 3);
 		GenerateTerrainPerlin();
 	} else {
 		switch (_opt.landscape) {
-			case LT_HILLY:
+			case LT_ARCTIC:
 				SetGeneratingWorldProgress(GWP_LANDSCAPE, 2);
 
 				for (i = ScaleByMapSize((Random() & 0x7F) + 950); i != 0; --i) {
@@ -657,7 +716,7 @@
 				IncreaseGeneratingWorldProgress(GWP_LANDSCAPE);
 				break;
 
-			case LT_DESERT:
+			case LT_TROPIC:
 				SetGeneratingWorldProgress(GWP_LANDSCAPE, 3 + gwp_desert_amount);
 
 				for (i = ScaleByMapSize((Random() & 0x7F) + 170); i != 0; --i) {
@@ -694,7 +753,7 @@
 
 	ConvertGroundTilesIntoWaterTiles();
 
-	if (_opt.landscape == LT_DESERT) CreateDesertOrRainForest();
+	if (_opt.landscape == LT_TROPIC) CreateDesertOrRainForest();
 }
 
 void OnTick_Town();
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/landscape.h	Thu Apr 19 14:43:25 2007 +0000
@@ -0,0 +1,19 @@
+/* $Id$ */
+
+/** @file landscape.h */
+
+enum {
+	SNOW_LINE_MONTHS = 12,
+	SNOW_LINE_DAYS   = 32,
+};
+
+struct SnowLine {
+	byte table[SNOW_LINE_MONTHS][SNOW_LINE_DAYS];
+	byte highest_value;
+};
+
+bool IsSnowLineSet(void);
+void SetSnowLine(byte table[SNOW_LINE_MONTHS][SNOW_LINE_DAYS]);
+byte GetSnowLine(void);
+byte HighestSnowLine(void);
+void ClearSnowLine(void);
--- a/src/lang/brazilian_portuguese.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/brazilian_portuguese.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -236,7 +236,7 @@
 STR_010A_COPPER_ORE_MINE                                        :{BLACK}{TINYFONT}Mina de Cobre
 STR_010B_FRUIT_PLANTATION                                       :{BLACK}{TINYFONT}Plantação de Frutas
 STR_010C_RUBBER_PLANTATION                                      :{BLACK}{TINYFONT}Plantação de Seringueiras
-STR_010D_WATER_SUPPLY                                           :{BLACK}{TINYFONT}Poço de Ãgua
+STR_010D_WATER_SUPPLY                                           :{BLACK}{TINYFONT}Poço Artesiano
 STR_010E_WATER_TOWER                                            :{BLACK}{TINYFONT}Reservatório
 STR_010F_LUMBER_MILL                                            :{BLACK}{TINYFONT}Serraria
 STR_0110_COTTON_CANDY_FOREST                                    :{BLACK}{TINYFONT}Floresta de Algodão Doce
@@ -1897,7 +1897,7 @@
 STR_483A_INSECT_INFESTATION_CAUSES                              :{BLACK}{BIGFONT}Infestação de insetos causa destruição em {INDUSTRY}!{}Produção diminui em 50%
 STR_483B_CAN_ONLY_BE_POSITIONED                                 :{WHITE}...só pode ser colocado perto das bordas do mapa
 STR_INDUSTRY_PROD_GOUP                                          :{BLACK}{BIGFONT}A produção de {STRING} em {INDUSTRY} aumentou em {COMMA}%!
-STR_INDUSTRY_PROD_GODOWN                                        :{BLACK}{BIGFONT}A produção de {STRING} na {INDUSTRY} diminuiu em {COMMA}%!
+STR_INDUSTRY_PROD_GODOWN                                        :{BLACK}{BIGFONT}A produção de {STRING} em {INDUSTRY} diminuiu em {COMMA}%!
 
 ##id 0x5000
 STR_5000_TRAIN_IN_TUNNEL                                        :{WHITE}Há um trem no túnel
--- a/src/lang/danish.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/danish.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -591,6 +591,7 @@
 STR_0207_ARRIVAL_OF_FIRST_VEHICLE                               :{YELLOW}Ankomst af første køretøj til modstanderens station
 STR_0208_ACCIDENTS_DISASTERS                                    :{YELLOW}Uheld / katastrofer
 STR_0209_COMPANY_INFORMATION                                    :{YELLOW}Selskabsinformation
+STR_NEWS_OPEN_CLOSE                                             :{YELLOW}Ã…bning / lukning af industrier
 STR_020A_ECONOMY_CHANGES                                        :{YELLOW}Økonomiændringer
 STR_020B_ADVICE_INFORMATION_ON_PLAYER                           :{YELLOW}Rådgivning / information om spillerens køretøjer
 STR_020C_NEW_VEHICLES                                           :{YELLOW}Nye køretøjer
@@ -726,6 +727,7 @@
 STR_028D_PLACE_LIGHTHOUSE                                       :{BLACK}Placér fyrtårn
 STR_028E_PLACE_TRANSMITTER                                      :{BLACK}Placér sender
 STR_028F_DEFINE_DESERT_AREA                                     :{BLACK}Definer ørkenområde.{}Hold CTRL nede for at fjerne det
+STR_CREATE_LAKE                                                 :{BLACK}Definer vandområde.{}Lav en kanal, med mindre CTRL-tasten holdes ved havniveau, hvorved omgivelserne oversvømmes i stedet
 STR_0290_DELETE                                                 :{BLACK}Slet
 STR_0291_DELETE_THIS_TOWN_COMPLETELY                            :{BLACK}Slet denne by fuldstændigt
 STR_0292_SAVE_SCENARIO                                          :Gem scenarie
@@ -1041,6 +1043,7 @@
 STR_CONFIG_PATCHES_NONUNIFORM_STATIONS                          :{LTBLUE}Ikke uniforme stationer: {ORANGE}{STRING}
 STR_CONFIG_PATCHES_NEW_PATHFINDING_ALL                          :{LTBLUE}Ny global ruteplanlægger (NPF, tilsidesætter NTP): {ORANGE}{STRING}
 STR_CONFIG_PATCHES_FREIGHT_TRAINS                               :{LTBLUE}Vægtfaktor for fragt for at simulere tunge tog: {ORANGE}{STRING}
+STR_CONFIG_PATCHES_STOP_ON_TOWN_ROAD                            :{LTBLUE}Tillad gennemkørsels-stop på veje ejet af en by: {ORANGE}{STRING}
 
 STR_CONFIG_PATCHES_SMALL_AIRPORTS                               :{LTBLUE}Tillad altid små lufthavne: {ORANGE}{STRING}
 
@@ -1087,6 +1090,11 @@
 STR_CONFIG_PATCHES_LIVERIES_OWN                                 :Eget selskab
 STR_CONFIG_PATCHES_LIVERIES_ALL                                 :Alle selskaber
 STR_CONFIG_PATCHES_PREFER_TEAMCHAT                              :{LTBLUE}Foretræk hold-chat med <ENTER>: {ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLLING                        :{LTBLUE}Rulleknappens funktion: {ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_ZOOM                             :Zoom kort
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLL                           :Rul kort
+STR_CONFIG_PATCHES_SCROLLWHEEL_OFF                              :Slået fra
+STR_CONFIG_PATCHES_SCROLLWHEEL_MULTIPLIER                       :{LTBLUE}Rulleknap-hastighed på kort: {ORANGE}{STRING}
 
 STR_CONFIG_PATCHES_MAX_TRAINS                                   :{LTBLUE}Maks. antal tog per spiller: {ORANGE}{STRING}
 STR_CONFIG_PATCHES_MAX_ROADVEH                                  :{LTBLUE}Maks. antal køretøjer per spiller: {ORANGE}{STRING}
@@ -1205,6 +1213,7 @@
 STR_TREES_RANDOM_TYPE_TIP                                       :{BLACK}Placer træer af tilfældig type
 
 STR_CANT_BUILD_CANALS                                           :{WHITE}Kan ikke bygge en kanal her...
+STR_BUILD_CANALS_TIP                                            :{BLACK}Byg kanaler.
 STR_LANDINFO_CANAL                                              :Kanal
 
 STR_CANT_BUILD_LOCKS                                            :{WHITE}Kan ikke bygge en sluse her...
@@ -1500,8 +1509,8 @@
 STR_0801_COST                                                   :{RED}Pris: {CURRENCY}
 STR_0802_INCOME                                                 :{TINYFONT}{GREEN}Indkomst: {CURRENCY}
 STR_0803_INCOME                                                 :{GREEN}Indkomst: {CURRENCY}
-STR_FEEDER_TINY                                                 :{TINYFONT}{YELLOW}Overfør: {CURRENCY}
-STR_FEEDER                                                      :{YELLOW}Overfør: {CURRENCY}
+STR_FEEDER_TINY                                                 :{TINYFONT}{YELLOW}Overført: {CURRENCY}
+STR_FEEDER                                                      :{YELLOW}Overført: {CURRENCY}
 STR_0805_ESTIMATED_COST                                         :{WHITE}Anslået Pris: {CURRENCY}
 STR_0807_ESTIMATED_INCOME                                       :{WHITE}Anslået Indkomst: {CURRENCY}
 STR_0808_CAN_T_RAISE_LAND_HERE                                  :{WHITE}Kan ikke hæve landet her...
@@ -2762,7 +2771,7 @@
 STR_983C_REFIT_SHIP                                             :{BLACK}Ombyg skibet
 STR_983D_SELECT_TYPE_OF_CARGO_FOR                               :{BLACK}Vælg den slags last skibet skal sejle med
 STR_983E_REFIT_SHIP_TO_CARRY_HIGHLIGHTED                        :{BLACK}Ombyg skibet til den markerede slags last
-STR_983F_SELECT_CARGO_TYPE_TO_CARRY                             :{GOLD}Vælg den lasttype der skal sejles med:
+STR_983F_SELECT_CARGO_TYPE_TO_CARRY                             :{GOLD}Vælg den lasttype der skal transporteres:
 STR_9840_NEW_CAPACITY_COST_OF_REFIT                             :{BLACK}Ny kapacitet: {GOLD}{CARGO}{}{BLACK}Pris for ombyggelse: {GOLD}{CURRENCY}
 STR_9841_CAN_T_REFIT_SHIP                                       :{WHITE}Kan ikke ombygge skib...
 STR_9842_REFITTABLE                                             :(kan ombygges)
@@ -2904,6 +2913,7 @@
 STR_NEWGRF_ERROR_INVALID_PARAMETER                              :Ugyldig parameter for {STRING}: parameter {STRING} ({NUM})
 STR_NEWGRF_ERROR_LOAD_BEFORE                                    :{STRING} skal indlæses før {STRING}.
 STR_NEWGRF_ERROR_LOAD_AFTER                                     :{STRING} skal indlæses efter {STRING}.
+STR_NEWGRF_ERROR_AFTER_TRANSLATED_FILE                          :GRF filen, som den er lavet til at oversætte,
 
 STR_NEWGRF_ADD                                                  :{BLACK}Tilføj
 STR_NEWGRF_ADD_TIP                                              :{BLACK}Tilføj et NewGRF sæt til listen
@@ -3137,3 +3147,4 @@
 
 ########
 
+STR_FEEDER_CARGO_VALUE                                          :{BLACK}Værdi af overført gods: {LTBLUE}{CURRENCY}
--- a/src/lang/esperanto.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/esperanto.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -592,6 +592,7 @@
 STR_0207_ARRIVAL_OF_FIRST_VEHICLE                               :{YELLOW}Unua veturilo atingas konkurantan stacion
 STR_0208_ACCIDENTS_DISASTERS                                    :{YELLOW}Akcidentoj / katastrofoj
 STR_0209_COMPANY_INFORMATION                                    :{YELLOW}Kompaniaj informoj
+STR_NEWS_OPEN_CLOSE                                             :{YELLOW}Malfermo / fermo de industrioj
 STR_020A_ECONOMY_CHANGES                                        :{YELLOW}Ekonomiaj ÅanÄoj
 STR_020B_ADVICE_INFORMATION_ON_PLAYER                           :{YELLOW}Konsiloj / informoj pri propraj veturiloj
 STR_020C_NEW_VEHICLES                                           :{YELLOW}Novaj veturiloj
@@ -727,6 +728,7 @@
 STR_028D_PLACE_LIGHTHOUSE                                       :{BLACK}Metu lumturon
 STR_028E_PLACE_TRANSMITTER                                      :{BLACK}Metu transmitilon
 STR_028F_DEFINE_DESERT_AREA                                     :{BLACK}Difinu dezertan regionon.{}Premu kaj tenu CTRL por forigi Äin
+STR_CREATE_LAKE                                                 :{BLACK}Difinu akvoregionon.{}Faru kanalon, krom se CTRL estas tenata marnivele, kiukaze Äi anstataÅ­e transfluas al la ĉirkaÅ­o
 STR_0290_DELETE                                                 :{BLACK}Forigu
 STR_0291_DELETE_THIS_TOWN_COMPLETELY                            :{BLACK}Plene forigu ĉi tiun urbon
 STR_0292_SAVE_SCENARIO                                          :Konservu scenaron
@@ -1089,6 +1091,11 @@
 STR_CONFIG_PATCHES_LIVERIES_OWN                                 :Propra kompanio
 STR_CONFIG_PATCHES_LIVERIES_ALL                                 :Ĉiuj kompanioj
 STR_CONFIG_PATCHES_PREFER_TEAMCHAT                              :{LTBLUE}Preferu teambabiladon per <ENTER>: {ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLLING                        :{LTBLUE}Funkcio de skrol-rado: {ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_ZOOM                             :Zomi mapon
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLL                           :Skroli mapon
+STR_CONFIG_PATCHES_SCROLLWHEEL_OFF                              :Malaktiva
+STR_CONFIG_PATCHES_SCROLLWHEEL_MULTIPLIER                       :{LTBLUE}Mapskrolrada rapido: {ORANGE}{STRING}
 
 STR_CONFIG_PATCHES_MAX_TRAINS                                   :{LTBLUE}Trajna maksimumo por ĉiu ludanto: {ORANGE}{STRING}
 STR_CONFIG_PATCHES_MAX_ROADVEH                                  :{LTBLUE}Vojveturila maksimumo por ĉiu ludanto: {ORANGE}{STRING}
@@ -1207,6 +1214,7 @@
 STR_TREES_RANDOM_TYPE_TIP                                       :{BLACK}Metu arbojn de hazardaj tipoj
 
 STR_CANT_BUILD_CANALS                                           :{WHITE}Ne povas konstrui kanalojn ĉi tie...
+STR_BUILD_CANALS_TIP                                            :{BLACK}Konstruu kanalojn.
 STR_LANDINFO_CANAL                                              :Kanalo
 
 STR_CANT_BUILD_LOCKS                                            :{WHITE}Ne povas konstrui kluzojn ĉi tie...
--- a/src/lang/estonian.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/estonian.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -380,6 +380,7 @@
 STR_OSNAME_MORPHOS                                              :MorphOS
 STR_OSNAME_AMIGAOS                                              :AmigaOS
 STR_OSNAME_OS2                                                  :OS/2
+STR_OSNAME_SUNOS                                                :SunOS
 
 STR_013B_OWNED_BY                                               :{WHITE}...omanik on {STRING}
 STR_013C_CARGO                                                  :{BLACK}Laadung
@@ -724,6 +725,8 @@
 STR_022A_GENERATE_RANDOM_LAND                                   :{BLACK}Juhusliku kaardi loomine
 STR_022B_RESET_LANDSCAPE                                        :{BLACK}Nulli maastik
 STR_022C_RESET_LANDSCAPE                                        :{WHITE}Nulli maastik
+STR_RESET_LANDSCAPE_TOOLTIP                                     :{BLACK}Eemalda kogu mängija omand kaardilt
+STR_RESET_LANDSCAPE_CONFIRMATION_TEXT                           :{WHITE}Kas oled kindel, et tahad eemaldada kogu mängija omandi?
 STR_022E_LANDSCAPE_GENERATION                                   :{BLACK}Maastiku loomine
 STR_022F_TOWN_GENERATION                                        :{BLACK}Linnade loomine
 STR_0230_INDUSTRY_GENERATION                                    :{BLACK}Tööstuste loomine
@@ -1184,6 +1187,11 @@
 STR_CONFIG_PATCHES_LIVERIES_OWN                                 :Enda firma
 STR_CONFIG_PATCHES_LIVERIES_ALL                                 :Kõik Firmad
 STR_CONFIG_PATCHES_PREFER_TEAMCHAT                              :{LTBLUE}Eelista Meeskonnajututuba <ENTER>i vajutamisega: {ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLLING                        :{LTBLUE}Kerimisratta funktsioon: {ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_ZOOM                             :Suurenda kaarti
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLL                           :Keri kaarti
+STR_CONFIG_PATCHES_SCROLLWHEEL_OFF                              :Väljas
+STR_CONFIG_PATCHES_SCROLLWHEEL_MULTIPLIER                       :{LTBLUE}Kaarti kerimisratta kiirus: {ORANGE}{STRING}
 
 STR_CONFIG_PATCHES_MAX_TRAINS                                   :{LTBLUE}Maks. rongide arv mängija kohta: {ORANGE}{STRING}
 STR_CONFIG_PATCHES_MAX_ROADVEH                                  :{LTBLUE}Suurim maanteesõidukite arv mängija kohta: {ORANGE}{STRING}
@@ -1302,6 +1310,7 @@
 STR_TREES_RANDOM_TYPE_TIP                                       :{BLACK}Istutab suvalisi puid
 
 STR_CANT_BUILD_CANALS                                           :{WHITE}Siia ei saa kanaleid ehitada...
+STR_BUILD_CANALS_TIP                                            :{BLACK}Ehita kanaleid.
 STR_LANDINFO_CANAL                                              :Kanal
 
 STR_CANT_BUILD_LOCKS                                            :{WHITE}Siia ei saa lüüse ehitada...
@@ -1681,6 +1690,7 @@
 STR_1817_ROAD_VEHICLE_DEPOT                                     :Depoo
 STR_1818_ROAD_RAIL_LEVEL_CROSSING                               :Raudtee ülesõit
 STR_CAN_T_REMOVE_BUS_STATION                                    :{WHITE}Bussijaama ei saa eemaldada...
+STR_CAN_T_REMOVE_TRUCK_STATION                                  :{WHITE}Ei saa eemaldada veoauto jaama...
 
 ##id 0x2000
 STR_2000_TOWNS                                                  :{WHITE}Linnad
@@ -2726,6 +2736,10 @@
 STR_TRAIN_NO_POWER                                              :{RED}Vool puudub
 STR_TRAIN_START_NO_CATENARY                                     :Selle raja ahel puudub, rong ei saa sõitu alustada
 
+STR_NEW_VEHICLE_NOW_AVAILABLE                                   :{BLACK}{BIGFONT}Uus {STRING} saadaval!
+STR_NEW_VEHICLE_TYPE                                            :{BLACK}{BIGFONT}{STRING}
+STR_NEW_VEHICLE_NOW_AVAILABLE_WITH_TYPE                         :{BLACK}Uus {STRING} saadaval!  -  {STRING}
+
 ##id 0x9000
 STR_9000_ROAD_VEHICLE_IN_THE_WAY                                :{WHITE}Maanteesõiduk on teel ees
 STR_9001_ROAD_VEHICLES                                          :{WHITE}{COMPANY} - {COMMA} maanteesõiduk{P "" it}
@@ -2986,6 +3000,18 @@
 STR_NEWGRF_MD5SUM                                               :{BLACK}MD5sum: {SILVER}{STRING}
 STR_NEWGRF_CONFIRMATION_TEXT                                    :{YELLOW}Sa oled tegemas muudatusi töötavasse mängu; see võib OpenTTD kokku jooksutada.{}Kas sa oled täielikult veendunud selles?
 
+STR_NEWGRF_ERROR_MSG_INFO                                       :{SILVER}{STRING}
+STR_NEWGRF_ERROR_MSG_WARNING                                    :{RED}Hoiatus: {SILVER}{STRING}
+STR_NEWGRF_ERROR_MSG_ERROR                                      :{RED}Viga: {SILVER}{STRING}
+STR_NEWGRF_ERROR_MSG_FATAL                                      :{RED}Saatuslik viga: {SILVER}{STRING}
+STR_NEWGRF_ERROR_VERSION_NUMBER                                 :{STRING} ei tööta TTDPatch versiooniga OpenTTD väitel.
+STR_NEWGRF_ERROR_DOS_OR_WINDOWS                                 :{STRING} on {STRING} TTD versiooni jaoks.
+STR_NEWGRF_ERROR_UNSET_SWITCH                                   :{STRING} on mõeldud kasutamiseks {STRING}
+STR_NEWGRF_ERROR_INVALID_PARAMETER                              :vigane parameeter {STRING} jaoks: parameeter {STRING} ({NUM})
+STR_NEWGRF_ERROR_LOAD_BEFORE                                    :{STRING} peab olema laetud enne {STRING}.
+STR_NEWGRF_ERROR_LOAD_AFTER                                     :{STRING} peab olema laetud pärast{STRING}.
+STR_NEWGRF_ERROR_AFTER_TRANSLATED_FILE                          :GRF fail, mis tehti tõlkimiseks,
+
 STR_NEWGRF_ADD                                                  :{BLACK}Lisa
 STR_NEWGRF_ADD_TIP                                              :{BLACK}Lisa nimekirja NewGRF fail
 STR_NEWGRF_REMOVE                                               :{BLACK}Eemalda
@@ -3211,4 +3237,11 @@
 STR_MEASURE_LENGTH_HEIGHTDIFF                                   :{BLACK}Pikkus: {NUM}{}Kürguste erinevusj: {NUM} m
 STR_MEASURE_AREA_HEIGHTDIFF                                     :{BLACK}Pindala: {NUM} x {NUM}{}Kõrguste erinevus: {NUM} m
 
+############ Date formatting
+STR_DATE_TINY                                                   :{STRING}-{STRING}-{NUM}
+STR_DATE_SHORT                                                  :{STRING} {NUM}
+STR_DATE_LONG                                                   :{STRING} {STRING} {NUM}
+
 ########
+
+STR_FEEDER_CARGO_VALUE                                          :{BLACK}Kanna Raha: {LTBLUE}{CURRENCY}
--- a/src/lang/finnish.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/finnish.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -47,7 +47,7 @@
 STR_0028_COTTON_CANDY                                           :Hattaraa
 STR_0029_BUBBLES                                                :Kuplia
 STR_002A_TOFFEE                                                 :Toffeeta
-STR_002B_BATTERIES                                              :Pattereita
+STR_002B_BATTERIES                                              :Paristoja
 STR_002C_PLASTIC                                                :Muovia
 STR_002D_FIZZY_DRINKS                                           :Sihijuomaa
 STR_002E                                                        :
@@ -203,7 +203,7 @@
 STR_00EB_ROADS                                                  :{BLACK}{TINYFONT}Tie
 STR_00EC_RAILROADS                                              :{BLACK}{TINYFONT}Rautatie
 STR_00ED_STATIONS_AIRPORTS_DOCKS                                :{BLACK}{TINYFONT}Asemat/lentokentät/satamat
-STR_00EE_BUILDINGS_INDUSTRIES                                   :{BLACK}{TINYFONT}Rakennus
+STR_00EE_BUILDINGS_INDUSTRIES                                   :{BLACK}{TINYFONT}Rakennukset/Teollisuus
 STR_00EF_VEHICLES                                               :{BLACK}{TINYFONT}Liikennevälineet
 STR_00F0_100M                                                   :{BLACK}{TINYFONT}100 m
 STR_00F1_200M                                                   :{BLACK}{TINYFONT}200 m
@@ -280,6 +280,7 @@
 STR_OSNAME_MORPHOS                                              :MorphOS
 STR_OSNAME_AMIGAOS                                              :AmigaOS
 STR_OSNAME_OS2                                                  :OS/2
+STR_OSNAME_SUNOS                                                :SunOS
 
 STR_013B_OWNED_BY                                               :{WHITE}...omistaja: {STRING}
 STR_013C_CARGO                                                  :{BLACK}Rahti
@@ -590,6 +591,7 @@
 STR_0207_ARRIVAL_OF_FIRST_VEHICLE                               :{YELLOW}Ensimmäinen ajoneuvo saapuu kilpailijan asemalle.
 STR_0208_ACCIDENTS_DISASTERS                                    :{YELLOW}Vahingot/onnettomuudet
 STR_0209_COMPANY_INFORMATION                                    :{YELLOW}Yhtiön tiedot
+STR_NEWS_OPEN_CLOSE                                             :{YELLOW}Avaa / tehtaiden sulkemiset
 STR_020A_ECONOMY_CHANGES                                        :{YELLOW}Talouden muutokset
 STR_020B_ADVICE_INFORMATION_ON_PLAYER                           :{YELLOW}Neuvoja/tietoja pelaajan ajoneuvoista
 STR_020C_NEW_VEHICLES                                           :{YELLOW}Uudet ajoneuvot
@@ -725,6 +727,7 @@
 STR_028D_PLACE_LIGHTHOUSE                                       :{BLACK}Sijoita majakka.
 STR_028E_PLACE_TRANSMITTER                                      :{BLACK}Sijoita lähetin.
 STR_028F_DEFINE_DESERT_AREA                                     :{BLACK}Määrittele aavikon alue.{}Paina ja pidä pohjassa CTRL-nappia poistaaksesi aavikkoa.
+STR_CREATE_LAKE                                                 :{BLACK}Määrittele vesialue.{}Tee kanava, paitsi jos CTRL on alaspainettuna merenpinnalla. Tällöin meri laajenee ympäristöön.
 STR_0290_DELETE                                                 :{BLACK}Poista
 STR_0291_DELETE_THIS_TOWN_COMPLETELY                            :{BLACK}Poista tämä kaupunki kokonaan.
 STR_0292_SAVE_SCENARIO                                          :Tallenna skenaario
@@ -740,7 +743,7 @@
 STR_PLAY_HEIGHTMAP                                              :{BLACK}Pelaa korkeuskartta
 STR_PLAY_HEIGHTMAP_HINT                                         :{BLACK}Aloita uusi peli, käyttäen korkeuskarttaa maastona
 STR_QUIT_SCENARIO_QUERY                                         :{YELLOW}Lopetetaanko skenaario?
-STR_029C_QUIT_EDITOR                                            :{WHITE}Sulje muokkain
+STR_029C_QUIT_EDITOR                                            :{WHITE}Sulje editori
 STR_029D_CAN_ONLY_BE_BUILT_IN_TOWNS                             :{WHITE}...voidaan rakentaa vain kaupunkeihin, joissa on yli 1200 asukasta.
 STR_029E_MOVE_THE_STARTING_DATE                                 :{BLACK}Siirrä aloituspäivää vuodella taaksepäin.
 STR_029F_MOVE_THE_STARTING_DATE                                 :{BLACK}Siirrä aloituspäivää vuodella eteenpäin.
@@ -815,12 +818,12 @@
 STR_MEASURING_UNITS_SELECTION                                   :{BLACK}Mittayksiköiden valinta
 STR_02E6_ROAD_VEHICLES                                          :{BLACK}Ajoneuvot
 STR_02E7                                                        :{BLACK}{SKIP}{SKIP}{SKIP}{STRING}
-STR_02E8_SELECT_SIDE_OF_ROAD_FOR                                :{BLACK}Valitse, kummalla puolella tietä ajetaan.
+STR_02E8_SELECT_SIDE_OF_ROAD_FOR                                :{BLACK}Valitse kummalla puolella tietä ajetaan.
 STR_02E9_DRIVE_ON_LEFT                                          :Vasemmalla kaistalla
 STR_02EA_DRIVE_ON_RIGHT                                         :Oikealla kaistalla
 STR_02EB_TOWN_NAMES                                             :{BLACK}Kaupunkien nimet
 STR_02EC                                                        :{BLACK}{SKIP}{SKIP}{SKIP}{SKIP}{STRING}
-STR_02ED_SELECT_STYLE_OF_TOWN_NAMES                             :{BLACK}Valitse tyyli kaupunkien nimille.
+STR_02ED_SELECT_STYLE_OF_TOWN_NAMES                             :{BLACK}Valitse kaupunkien nimien tyyli.
 
 STR_02F4_AUTOSAVE                                               :{BLACK}Automaattitallennus
 STR_02F5                                                        :{BLACK}{SKIP}{SKIP}{SKIP}{SKIP}{SKIP}{STRING}
@@ -828,7 +831,7 @@
 STR_02F7_OFF                                                    :Pois
 STR_02F8_EVERY_3_MONTHS                                         :Joka 3. kuukausi
 STR_02F9_EVERY_6_MONTHS                                         :Joka 6. kuukausi
-STR_02FA_EVERY_12_MONTHS                                        :Joka 12. kuukausi
+STR_02FA_EVERY_12_MONTHS                                        :Kerran vuodessa
 STR_02FB_START_A_NEW_GAME                                       :{BLACK}Aloita uusi peli.
 STR_02FC_LOAD_A_SAVED_GAME                                      :{BLACK}Lataa tallennettu peli.
 STR_02FE_CREATE_A_CUSTOMIZED_GAME                               :{BLACK}Luo oma pelimaailma/skenaario.
@@ -838,7 +841,7 @@
 STR_0302_DISPLAY_DIFFICULTY_OPTIONS                             :{BLACK}Näytä vaikeusasetukset.
 STR_0303_START_A_NEW_GAME_USING                                 :{BLACK}Aloita uusi peli käyttäen omaa skenaariota.
 STR_0304_QUIT                                                   :{BLACK}Sulje
-STR_0305_QUIT_OPENTTD                                           :{BLACK}Sulje "OpenTTD".
+STR_0305_QUIT_OPENTTD                                           :{BLACK}Sulje OpenTTD.
 STR_0307_OPENTTD                                                :{WHITE}OpenTTD {REV}
 STR_030D_CAN_ONLY_BE_BUILT_IN_TOWNS                             :{WHITE}...voidaan rakentaa vain kaupunkeihin.
 STR_030E_SELECT_TEMPERATE_LANDSCAPE                             :{BLACK}Valitse 'lauhkea' ilmasto.
@@ -859,7 +862,7 @@
 STR_0318_CAN_ONLY_BE_BUILT_IN_DESERT                            :{WHITE}...voidaan rakentaa vain aavikkoalueisiin.
 STR_0319_PAUSED                                                 :{YELLOW}* *  TAUKO  *  *
 
-STR_031B_SCREENSHOT_SUCCESSFULLY                                :{WHITE}Kuvankaappaus tallennettu levyllä nimellä '{STRING}'.
+STR_031B_SCREENSHOT_SUCCESSFULLY                                :{WHITE}Kuvakaappaus tallennettu nimellä '{STRING}'.
 STR_031C_SCREENSHOT_FAILED                                      :{WHITE}Kuvakaappaus epäonnistui!
 
 STR_0329_PURCHASE_LAND_FOR_FUTURE                               :{BLACK}Osta maata tulevaa käyttöä varten.
@@ -1087,6 +1090,11 @@
 STR_CONFIG_PATCHES_LIVERIES_OWN                                 :Oma yritys
 STR_CONFIG_PATCHES_LIVERIES_ALL                                 :Kaikki yritykset
 STR_CONFIG_PATCHES_PREFER_TEAMCHAT                              :{LTBLUE}Suosi ryhmäkeskustelua <ENTER> {ORANGE}{STRING} kanssa
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLLING                        :{LTBLUE}Hiiren rullan toiminta: {ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_ZOOM                             :Zoomaa karttaa
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLL                           :Vieritä karttaa
+STR_CONFIG_PATCHES_SCROLLWHEEL_OFF                              :Pois
+STR_CONFIG_PATCHES_SCROLLWHEEL_MULTIPLIER                       :{LTBLUE}Rullan nopeus: {ORANGE}{STRING}
 
 STR_CONFIG_PATCHES_MAX_TRAINS                                   :{LTBLUE}Junia/pelaaja: {ORANGE}{STRING}
 STR_CONFIG_PATCHES_MAX_ROADVEH                                  :{LTBLUE}Ajoneuvoja/pelaaja: {ORANGE}{STRING}
@@ -1205,6 +1213,7 @@
 STR_TREES_RANDOM_TYPE_TIP                                       :{BLACK}Aseta sattumanvaraisia puita
 
 STR_CANT_BUILD_CANALS                                           :{WHITE}Kanaalia ei voi rakentaa tähän...
+STR_BUILD_CANALS_TIP                                            :{BLACK}Rakenna kanavia.
 STR_LANDINFO_CANAL                                              :Kanaali
 
 STR_CANT_BUILD_LOCKS                                            :{WHITE}Sulkua ei voi rakentaa tähän...
@@ -1504,14 +1513,14 @@
 STR_FEEDER                                                      :{YELLOW}Siirrä: {CURRENCY}
 STR_0805_ESTIMATED_COST                                         :{WHITE}Arvioitu kustannus: {CURRENCY}
 STR_0807_ESTIMATED_INCOME                                       :{WHITE}Arvioitu tulo: {CURRENCY}
-STR_0808_CAN_T_RAISE_LAND_HERE                                  :{WHITE}Maata ei voi korottaa...
-STR_0809_CAN_T_LOWER_LAND_HERE                                  :{WHITE}Maata ei voi madaltaa...
+STR_0808_CAN_T_RAISE_LAND_HERE                                  :{WHITE}Maata ei voi korottaa.
+STR_0809_CAN_T_LOWER_LAND_HERE                                  :{WHITE}Maata ei voi laskea.
 STR_080A_ROCKS                                                  :Kalliota
 STR_080B_ROUGH_LAND                                             :Epätasaista maata
 STR_080C_BARE_LAND                                              :Paljasta maata
 STR_080D_GRASS                                                  :Ruohikkoa
 STR_080E_FIELDS                                                 :Peltoja
-STR_080F_SNOW_COVERED_LAND                                      :Lumenpeittämää maata
+STR_080F_SNOW_COVERED_LAND                                      :Lumen peittämää maata
 STR_0810_DESERT                                                 :Aavikkoa
 
 ##id 0x1000
@@ -1528,12 +1537,12 @@
 STR_100B_MONORAIL_CONSTRUCTION                                  :{WHITE}Yksiraiteisen rakentaminen
 STR_100C_MAGLEV_CONSTRUCTION                                    :{WHITE}MagLevin rakentaminen
 STR_100D_SELECT_RAIL_BRIDGE                                     :{WHITE}Valitse rautatiesilta.
-STR_100E_CAN_T_BUILD_TRAIN_DEPOT                                :{WHITE}Veturitallia ei voi rakentaa...
-STR_100F_CAN_T_BUILD_RAILROAD_STATION                           :{WHITE}Rautatieasemaa ei voi rakentaa...
-STR_1010_CAN_T_BUILD_SIGNALS_HERE                               :{WHITE}Opastinta ei voi rakentaa...
-STR_1011_CAN_T_BUILD_RAILROAD_TRACK                             :{WHITE}Rautatietä ei voi rakentaa...
-STR_1012_CAN_T_REMOVE_RAILROAD_TRACK                            :{WHITE}Rautatietä ei voi poistaa tästä...
-STR_1013_CAN_T_REMOVE_SIGNALS_FROM                              :{WHITE}Opastinta ei voi poistaa tästä...
+STR_100E_CAN_T_BUILD_TRAIN_DEPOT                                :{WHITE}Veturitallia ei voi rakentaa.
+STR_100F_CAN_T_BUILD_RAILROAD_STATION                           :{WHITE}Rautatieasemaa ei voi rakentaa.
+STR_1010_CAN_T_BUILD_SIGNALS_HERE                               :{WHITE}Opastinta ei voi rakentaa.
+STR_1011_CAN_T_BUILD_RAILROAD_TRACK                             :{WHITE}Rautatietä ei voi rakentaa.
+STR_1012_CAN_T_REMOVE_RAILROAD_TRACK                            :{WHITE}Rautatietä ei voi poistaa.
+STR_1013_CAN_T_REMOVE_SIGNALS_FROM                              :{WHITE}Opastinta ei voi poistaa tästä.
 STR_1014_TRAIN_DEPOT_ORIENTATION                                :{WHITE}Veturitallin suunta
 STR_1015_RAILROAD_CONSTRUCTION                                  :Rautatien rakentaminen
 STR_TOOLB_ELRAIL_CONSTRUCTION                                   :Sähköradan rakentaminen
@@ -1563,25 +1572,25 @@
 STR_ROAD_WORKS_IN_PROGRESS                                      :{WHITE}Tietyöt ovat käynnissä.
 STR_1802_ROAD_CONSTRUCTION                                      :{WHITE}Tien rakentaminen
 STR_1803_SELECT_ROAD_BRIDGE                                     :{WHITE}Valitse maantiesilta
-STR_1804_CAN_T_BUILD_ROAD_HERE                                  :{WHITE}Tietä ei voi rakentaa...
-STR_1805_CAN_T_REMOVE_ROAD_FROM                                 :{WHITE}Tietä ei voi poistaa tästä...
-STR_1806_ROAD_DEPOT_ORIENTATION                                 :{WHITE}Huoltoaseman suunta
-STR_1807_CAN_T_BUILD_ROAD_VEHICLE                               :{WHITE}Huoltoasemaa ei voi rakentaa...
-STR_1808_CAN_T_BUILD_BUS_STATION                                :{WHITE}Linja-autoasemaa ei voi rakentaa...
-STR_1809_CAN_T_BUILD_TRUCK_STATION                              :{WHITE}Lastauslaituria ei voi rakentaa...
+STR_1804_CAN_T_BUILD_ROAD_HERE                                  :{WHITE}Tietä ei voi rakentaa.
+STR_1805_CAN_T_REMOVE_ROAD_FROM                                 :{WHITE}Tietä ei voi poistaa.
+STR_1806_ROAD_DEPOT_ORIENTATION                                 :{WHITE}Autovarikon suunta
+STR_1807_CAN_T_BUILD_ROAD_VEHICLE                               :{WHITE}Autovarikkoa ei voi rakentaa.
+STR_1808_CAN_T_BUILD_BUS_STATION                                :{WHITE}Linja-autoasemaa ei voi rakentaa.
+STR_1809_CAN_T_BUILD_TRUCK_STATION                              :{WHITE}Lastauslaituria ei voi rakentaa.
 STR_180A_ROAD_CONSTRUCTION                                      :Tien rakentaminen
 STR_180B_BUILD_ROAD_SECTION                                     :{BLACK}Rakenna tieosuus.
-STR_180C_BUILD_ROAD_VEHICLE_DEPOT                               :{BLACK}Rakenna huoltoasema (ajoneuvojen rakentamista ja huoltoa varten)
+STR_180C_BUILD_ROAD_VEHICLE_DEPOT                               :{BLACK}Rakenna autovarikko (ajoneuvojen rakentamista ja huoltoa varten)
 STR_180D_BUILD_BUS_STATION                                      :{BLACK}Rakenna linja-autoasema
 STR_180E_BUILD_TRUCK_LOADING_BAY                                :{BLACK}Rakenna lastauslaituri
 STR_180F_BUILD_ROAD_BRIDGE                                      :{BLACK}Rakenna maantiesilta
 STR_1810_BUILD_ROAD_TUNNEL                                      :{BLACK}Rakenna maantietunneli
 STR_1811_TOGGLE_BUILD_REMOVE_FOR                                :{BLACK}Tien rakentaminen/siirtäminen päälle/pois
-STR_1813_SELECT_ROAD_VEHICLE_DEPOT                              :{BLACK}Valitse huoltoaseman suunta.
+STR_1813_SELECT_ROAD_VEHICLE_DEPOT                              :{BLACK}Valitse autovarikon suunta.
 STR_1814_ROAD                                                   :Tie
 STR_1815_ROAD_WITH_STREETLIGHTS                                 :Tie katuvaloilla
 STR_1816_TREE_LINED_ROAD                                        :Puilla reunustettu tie
-STR_1817_ROAD_VEHICLE_DEPOT                                     :Huoltoasema
+STR_1817_ROAD_VEHICLE_DEPOT                                     :Autovarikko
 STR_1818_ROAD_RAIL_LEVEL_CROSSING                               :Tasoristeys
 STR_CAN_T_REMOVE_BUS_STATION                                    :{WHITE}Linja-autoasemaa ei voida poistaa...
 STR_CAN_T_REMOVE_TRUCK_STATION                                  :{WHITE}Kuorma-auto asemaa ei voida poistaa...
@@ -1593,23 +1602,23 @@
 STR_TOWN_LABEL_TINY_BLACK                                       :{TINYFONT}{BLACK}{TOWN}
 STR_TOWN_LABEL_TINY_WHITE                                       :{TINYFONT}{WHITE}{TOWN}
 STR_2002                                                        :{TINYFONT}{BLACK}{STRING}
-STR_2004_BUILDING_MUST_BE_DEMOLISHED                            :{WHITE}Rakennus täytyy tuhota ensin.
+STR_2004_BUILDING_MUST_BE_DEMOLISHED                            :{WHITE}Rakennus täytyy purkaa ensin.
 STR_2005                                                        :{WHITE}{TOWN}
 STR_2006_POPULATION                                             :{BLACK}Asukasluku: {ORANGE}{COMMA}{BLACK}  Taloja: {ORANGE}{COMMA}
 STR_2007_RENAME_TOWN                                            :Nimeä kaupunki
-STR_2008_CAN_T_RENAME_TOWN                                      :{WHITE}Kaupunkia ei voi uudelleennimetä...
+STR_2008_CAN_T_RENAME_TOWN                                      :{WHITE}Kaupungin nimeä ei voi vaihtaa.
 STR_2009_LOCAL_AUTHORITY_REFUSES                                :{WHITE}{TOWN}: paikallisviranomaiset kieltäytyvät.
-STR_200A_TOWN_NAMES_CLICK_ON_NAME                               :{BLACK}Kaupunkien nimet - napsauta nimeä keskittääksesi päänäkymän kaupunkiin.
-STR_200B_CENTER_THE_MAIN_VIEW_ON                                :{BLACK}Keskitä päänäkymä kaupungin sijaintiin.
+STR_200A_TOWN_NAMES_CLICK_ON_NAME                               :{BLACK}Kaupunkien nimet - kaupungin valitseminen keskittää näkymän.
+STR_200B_CENTER_THE_MAIN_VIEW_ON                                :{BLACK}Keskitä näkymä kaupungkiin.
 STR_200C_CHANGE_TOWN_NAME                                       :{BLACK}Vaihda kaupungin nimeä.
 STR_200D_PASSENGERS_LAST_MONTH_MAX                              :{BLACK}Matkustajia viime kuussa: {ORANGE}{COMMA}{BLACK}  max: {ORANGE}{COMMA}
 STR_200E_MAIL_LAST_MONTH_MAX                                    :{BLACK}Postia viime kuussa: {ORANGE}{COMMA}{BLACK}  max: {ORANGE}{COMMA}
 STR_200F_TALL_OFFICE_BLOCK                                      :Korkea toimistorakennus
 STR_2010_OFFICE_BLOCK                                           :Tomistorakennus
-STR_2011_SMALL_BLOCK_OF_FLATS                                   :Pienasuntokortteli
+STR_2011_SMALL_BLOCK_OF_FLATS                                   :Pientaloalue
 STR_2012_CHURCH                                                 :Kirkko
 STR_2013_LARGE_OFFICE_BLOCK                                     :Suuri toimistorakennus
-STR_2014_TOWN_HOUSES                                            :Kaupungin talot
+STR_2014_TOWN_HOUSES                                            :Kaupungintalot
 STR_2015_HOTEL                                                  :Hotelli
 STR_2016_STATUE                                                 :Patsas
 STR_2017_FOUNTAIN                                               :Suihkulähde
@@ -1627,14 +1636,14 @@
 STR_2023_TRANSPORT_COMPANY_RATINGS                              :{BLACK}Kuljetusyhtiön arvioinnit:
 STR_2024                                                        :{YELLOW}{COMPANY}{PLAYERNAME}: {ORANGE}{STRING}
 STR_2025_SUBSIDIES                                              :{WHITE}Tuet
-STR_2026_SUBSIDIES_ON_OFFER_FOR                                 :{BLACK}Tarjolla olevat tuet:
+STR_2026_SUBSIDIES_ON_OFFER_FOR                                 :{BLACK}Tarjotut tuet:
 STR_2027_FROM_TO                                                :{ORANGE}{STRING} välille {STRING}-{STRING}
 STR_2028_BY                                                     :{YELLOW} ({DATE_SHORT})
 STR_202A_NONE                                                   :{ORANGE}Ei mitään
 STR_202B_SERVICES_ALREADY_SUBSIDISED                            :{BLACK}Käytetyt tuet-
 STR_202C_FROM_TO                                                :{ORANGE}{STRING} välille {STATION}-{STATION}{YELLOW} ({COMPANY}
 STR_202D_UNTIL                                                  :{YELLOW}, {DATE_SHORT} asti)
-STR_202E_OFFER_OF_SUBSIDY_EXPIRED                               :{BLACK}{BIGFONT}Tuki päättynyt:{}{}{STRING} väli {STRING} - {STRING} ei sisällä enää tukia.
+STR_202E_OFFER_OF_SUBSIDY_EXPIRED                               :{BLACK}{BIGFONT}Tuki päättynyt:{}{}{STRING} väli {STRING} - {STRING} ei ole enää tuettu.
 STR_202F_SUBSIDY_WITHDRAWN_SERVICE                              :{BLACK}{BIGFONT}Tuki vedetty pois:{}{}{STRING} kuljetuspalvelu välille {STATION}-{STATION} ei ole enää tuettu.
 STR_2030_SERVICE_SUBSIDY_OFFERED                                :{BLACK}{BIGFONT}Tuki tarjottu:{}{}Ensimmäinen {STRING}kuljetus välillä {STRING} - {STRING} saa vuoden mittaisen tuen paikallisviranomaisilta!
 STR_2031_SERVICE_SUBSIDY_AWARDED                                :{BLACK}{BIGFONT}Tuki myönnetty yhtiölle {COMPANY}!{}{}{STRING}kuljetus välillä {STATION}-{STATION} tuottaa 50{NBSP}% enemmän seuraavan vuoden ajan!
@@ -1642,22 +1651,22 @@
 STR_2033_SERVICE_SUBSIDY_AWARDED                                :{BLACK}{BIGFONT}Tuki myönnetty yhtiölle {COMPANY}!{}{}{STRING}kuljetus välillä {STATION}-{STATION} tuottaa kolminkertaisesti seuraavan vuoden ajan!
 STR_2034_SERVICE_SUBSIDY_AWARDED                                :{BLACK}{BIGFONT}Tuki myönnetty yhtiölle {COMPANY}!{}{}{STRING}kuljetus välillä {STATION}-{STATION} tuottaa nelinkertaisesti seuraavan vuoden ajan!
 STR_2035_LOCAL_AUTHORITY_REFUSES                                :{WHITE}{TOWN}: paikallisviranomaiset eivät salli toisen lentokentän rakentamista tähän kaupunkiin.
-STR_2036_COTTAGES                                               :Mökkiä
-STR_2037_HOUSES                                                 :Taloa
-STR_2038_FLATS                                                  :Asuntoa
-STR_2039_TALL_OFFICE_BLOCK                                      :Korkeata toimistorakennusta
-STR_203A_SHOPS_AND_OFFICES                                      :Kauppaa ja toimistoa
-STR_203B_SHOPS_AND_OFFICES                                      :Kauppaa ja toimistoa
+STR_2036_COTTAGES                                               :Mökkejä
+STR_2037_HOUSES                                                 :Taloja
+STR_2038_FLATS                                                  :Asuntoja
+STR_2039_TALL_OFFICE_BLOCK                                      :Korkeita toimistorakennuksia
+STR_203A_SHOPS_AND_OFFICES                                      :Liikkeitä ja toimistoja
+STR_203B_SHOPS_AND_OFFICES                                      :Liikkeitä ja toimistoja
 STR_203C_THEATER                                                :Teatteri
 STR_203D_STADIUM                                                :Stadion
-STR_203E_OFFICES                                                :Toimistoa
-STR_203F_HOUSES                                                 :Taloa
+STR_203E_OFFICES                                                :Toimistoja
+STR_203F_HOUSES                                                 :Taloja
 STR_2040_CINEMA                                                 :Elokuvateatteri
 STR_2041_SHOPPING_MALL                                          :Kauppakeskus
 STR_2042_DO_IT                                                  :{BLACK}Sijoita
 STR_2043_LIST_OF_THINGS_TO_DO_AT                                :{BLACK}Luettelo kaupungissa tehtävistä asioista - napsauta kohdetta saadaksesi lisätietoja.
 STR_2044_CARRY_OUT_THE_HIGHLIGHTED                              :{BLACK}Suorita valittu toiminto.
-STR_2045_ACTIONS_AVAILABLE                                      :{BLACK}Saatavilla olevat toiminnot:
+STR_2045_ACTIONS_AVAILABLE                                      :{BLACK}Toiminnot:
 STR_2046_SMALL_ADVERTISING_CAMPAIGN                             :Pieni mainoskampanja
 STR_2047_MEDIUM_ADVERTISING_CAMPAIGN                            :Keskikokoinen mainoskampanja
 STR_2048_LARGE_ADVERTISING_CAMPAIGN                             :Suuri mainoskampanja
@@ -1666,9 +1675,9 @@
 STR_204B_FUND_NEW_BUILDINGS                                     :Rahoita uusia rakennuksia
 STR_204C_BUY_EXCLUSIVE_TRANSPORT                                :Osta yksinoikeudet kuljetuksiin
 STR_TOWN_BRIBE_THE_LOCAL_AUTHORITY                              :Lahjo viranomaisia
-STR_204D_INITIATE_A_SMALL_LOCAL                                 :{WHITE}{STRING}{}{YELLOW} Tee aloite pienestä mainoskampanjasta hoikutellaksesi lisää matkustajia ja rahtia kuljetuspalveluihisi.{}  Kustannus: {CURRENCY}
-STR_204E_INITIATE_A_MEDIUM_LOCAL                                :{WHITE}{STRING}{}{YELLOW} Tee aloite keskikokoisesta mainoskampanjasta hoikutellaksesi lisää matkustajia ja rahtia kuljetuspalveluihisi.{}  Kustannus: {CURRENCY}
-STR_204F_INITIATE_A_LARGE_LOCAL                                 :{WHITE}{STRING}{}{YELLOW} Tee aloite suuresta mainoskampanjasta hoikutellaksesi lisää matkustajia ja rahtia kuljetuspalveluihisi.{}  Kustannus: {CURRENCY}
+STR_204D_INITIATE_A_SMALL_LOCAL                                 :{WHITE}{STRING}{}{YELLOW} Käynnistä pieni mainoskampanja hoikutellaksesi lisää matkustajia ja rahtia kuljetuspalveluihisi.{}  Kustannus: {CURRENCY}
+STR_204E_INITIATE_A_MEDIUM_LOCAL                                :{WHITE}{STRING}{}{YELLOW} Käynnistä keskikokoinen mainoskampanja houkutellaksesi lisää matkustajia ja rahtia kuljetuspalveluihisi.{}  Kustannus: {CURRENCY}
+STR_204F_INITIATE_A_LARGE_LOCAL                                 :{WHITE}{STRING}{}{YELLOW}Käynnistä suuri mainoskampanja hoikutellaksesi lisää matkustajia ja rahtia kuljetuspalveluihisi.{}  Kustannus: {CURRENCY}
 STR_2050_FUND_THE_RECONSTRUCTION                                :{WHITE}{STRING}{}{YELLOW} Rahoita kaupungin tieverkon rakentamista. Aiheuttaa huomattavaa häiriötä tieliikenteessä kuuden kuukauden ajan.{}  Kustannus: {CURRENCY}
 STR_2051_BUILD_A_STATUE_IN_HONOR                                :{WHITE}{STRING}{}{YELLOW} Rakenna patsas yhtiösi kunniaksi.{} Kustannus: {CURRENCY}
 STR_2052_FUND_THE_CONSTRUCTION_OF                               :{WHITE}{STRING}{}{YELLOW} Rahoita uusien kaupparakennusten rakentamista kaupungissa.{}  Kustannus: {CURRENCY}
@@ -1692,15 +1701,15 @@
 STR_2800_PLANT_TREES                                            :Istuta puita
 STR_2801_PLACE_SIGN                                             :Aseta kyltti
 STR_2802_TREES                                                  :{WHITE}Puita
-STR_2803_TREE_ALREADY_HERE                                      :{WHITE}...puu on jo tässä.
-STR_2804_SITE_UNSUITABLE                                        :{WHITE}...paikka sopimaton.
-STR_2805_CAN_T_PLANT_TREE_HERE                                  :{WHITE}Puuta ei voi istuttaa...
+STR_2803_TREE_ALREADY_HERE                                      :{WHITE}...tässä on jo puu.
+STR_2804_SITE_UNSUITABLE                                        :{WHITE}...huono paikka.
+STR_2805_CAN_T_PLANT_TREE_HERE                                  :{WHITE}Puuta ei voi istuttaa.
 STR_2806                                                        :{WHITE}{STRING}
 STR_2808_TOO_MANY_SIGNS                                         :{WHITE}...liian monta kylttiä.
-STR_2809_CAN_T_PLACE_SIGN_HERE                                  :{WHITE}Kylttiä ei voi sijoittaa...
+STR_2809_CAN_T_PLACE_SIGN_HERE                                  :{WHITE}Kylttiä ei voi sijoittaa.
 STR_280A_SIGN                                                   :Kyltti
 STR_280B_EDIT_SIGN_TEXT                                         :{WHITE}Muokkaa kyltin tekstiä.
-STR_280C_CAN_T_CHANGE_SIGN_NAME                                 :{WHITE}Kyltin nimeä ei voi muuttaa...
+STR_280C_CAN_T_CHANGE_SIGN_NAME                                 :{WHITE}Kyltin nimeä ei voi muuttaa.
 STR_280D_SELECT_TREE_TYPE_TO_PLANT                              :{BLACK}Valitse istutettava puutyyppi.
 STR_280E_TREES                                                  :Puita
 STR_280F_RAINFOREST                                             :Sademetsää
@@ -1713,19 +1722,19 @@
 STR_3003_NUMBER_OF_TRACKS                                       :{BLACK}Ratojen määrä
 STR_3004_PLATFORM_LENGTH                                        :{BLACK}Asemalaiturin pituus
 STR_3005_TOO_CLOSE_TO_ANOTHER_RAILROAD                          :{WHITE}Liian lähellä toista rautatieasemaa.
-STR_3006_ADJOINS_MORE_THAN_ONE_EXISTING                         :{WHITE}Liitä yhteen useampi kuin yksi olemassaoleva asema/lastausalue.
-STR_3007_TOO_MANY_STATIONS_LOADING                              :{WHITE}Liian monta asemaa/lastausaluetta kaupungissa.
-STR_3008_TOO_MANY_STATIONS_LOADING                              :{WHITE}Liian monta asemaa/lastausaluetta.
+STR_3006_ADJOINS_MORE_THAN_ONE_EXISTING                         :{WHITE}Liitä yhteen useampi asema/lastausalue.
+STR_3007_TOO_MANY_STATIONS_LOADING                              :{WHITE}Liian monta asemaa ja lastausaluetta kaupungissa.
+STR_3008_TOO_MANY_STATIONS_LOADING                              :{WHITE}Liian monta asemaa ja lastausaluetta.
 STR_3008A_TOO_MANY_BUS_STOPS                                    :{WHITE}Liian monta linja-autopysäkkiä.
 STR_3008B_TOO_MANY_TRUCK_STOPS                                  :{WHITE}Liian monta lastauslaituria.
-STR_3009_TOO_CLOSE_TO_ANOTHER_STATION                           :{WHITE}Liian lähellä toista asemaa/lastausaluetta.
+STR_3009_TOO_CLOSE_TO_ANOTHER_STATION                           :{WHITE}Liian lähellä toista asemaa tai lastausaluetta.
 STR_300A_0                                                      :{WHITE}{STATION} {STATIONFEATURES}
 STR_300B_MUST_DEMOLISH_RAILROAD                                 :{WHITE}Rautatieasema pitää tuhota ensin.
 STR_300D_TOO_CLOSE_TO_ANOTHER_AIRPORT                           :{WHITE}Liian lähellä toista lentokenttää.
 STR_300E_MUST_DEMOLISH_AIRPORT_FIRST                            :{WHITE}Lentokenttä pitää tuhota ensin.
 
 STR_3030_RENAME_STATION_LOADING                                 :Nimeä asema/lastausalue
-STR_3031_CAN_T_RENAME_STATION                                   :{WHITE}Asemaa ei voi nimetä uudelleen...
+STR_3031_CAN_T_RENAME_STATION                                   :{WHITE}Asemaa ei voi nimetä uudelleen.
 STR_3032_RATINGS                                                :{BLACK}Arviot
 STR_3033_ACCEPTS                                                :{BLACK}Ottaa vastaan
 STR_3034_LOCAL_RATING_OF_TRANSPORT                              :{BLACK}Paikallinen arvio kuljetuspalvelusta:
@@ -1736,24 +1745,24 @@
 STR_3037_POOR                                                   :Kehno
 STR_3038_MEDIOCRE                                               :Keskinkertainen
 STR_3039_GOOD                                                   :Hyvä
-STR_303A_VERY_GOOD                                              :Oikein hyvä
+STR_303A_VERY_GOOD                                              :Erittäin hyvä
 STR_303B_EXCELLENT                                              :Mainio
 STR_303C_OUTSTANDING                                            :Loistava
 ############ range for rating ends
 
 STR_303D                                                        :{WHITE}{STRING}: {YELLOW}{STRING} ({COMMA}{NBSP}%)
-STR_303E_NO_LONGER_ACCEPTS                                      :{WHITE}{STATION} ei enää ota vastaan {STRING}.
-STR_303F_NO_LONGER_ACCEPTS_OR                                   :{WHITE}{STATION} ei enää ota vastaan {STRING} tai {STRING}.
+STR_303E_NO_LONGER_ACCEPTS                                      :{WHITE}{STATION} ei ota enää vastaan {STRING}.
+STR_303F_NO_LONGER_ACCEPTS_OR                                   :{WHITE}{STATION} ei ota enää vastaan {STRING} tai {STRING}.
 STR_3040_NOW_ACCEPTS                                            :{WHITE}{STATION} ottaa nyt vastaan {STRING}.
 STR_3041_NOW_ACCEPTS_AND                                        :{WHITE}{STATION} ottaa nyt vastaan {STRING} ja {STRING}.
 STR_3042_BUS_STATION_ORIENTATION                                :{WHITE}Linja-autoaseman suunta
 STR_3043_TRUCK_STATION_ORIENT                                   :{WHITE}Lastauslaiturin suunta
-STR_3046_MUST_DEMOLISH_BUS_STATION                              :{WHITE}Linja-autoasema pitää tuhota ensin.
-STR_3047_MUST_DEMOLISH_TRUCK_STATION                            :{WHITE}Lastauslaituri pitää tuhota ensin.
+STR_3046_MUST_DEMOLISH_BUS_STATION                              :{WHITE}Linja-autoasema pitää purkaa ensin.
+STR_3047_MUST_DEMOLISH_TRUCK_STATION                            :{WHITE}Lastauslaituri pitää purkaa ensin.
 STR_3048_STATIONS                                               :{WHITE}{COMPANY} - {COMMA} asema{P "" a}
 STR_3049_0                                                      :{YELLOW}{STATION} {STATIONFEATURES}
 STR_304A_NONE                                                   :{YELLOW}- Ei mitään -
-STR_304B_SITE_UNSUITABLE                                        :{WHITE}...paikka sopimaton.
+STR_304B_SITE_UNSUITABLE                                        :{WHITE}...huono paikka
 STR_304C_TOO_CLOSE_TO_ANOTHER_DOCK                              :{WHITE}Liian lähellä toista satamaa.
 STR_304D_MUST_DEMOLISH_DOCK_FIRST                               :{WHITE}Satama pitää tuhota ensin.
 STR_304E_SELECT_RAILROAD_STATION                                :{BLACK}Valitse rautatieaseman suunta.
@@ -1766,7 +1775,7 @@
 STR_3055_CHANGE_NAME_OF_STATION                                 :{BLACK}Muuta aseman nimi.
 STR_3056_SHOW_LIST_OF_ACCEPTED_CARGO                            :{BLACK}Näytä luettelo vastaanotettavasta rahdista.
 STR_3057_STATION_NAMES_CLICK_ON                                 :{BLACK}Asemien nimet - napsauta nimeä keskittääksesi näkymän asemaan.
-STR_3058_SELECT_SIZE_TYPE_OF_AIRPORT                            :{BLACK}Valitse lentokentän koko/tyyppi.
+STR_3058_SELECT_SIZE_TYPE_OF_AIRPORT                            :{BLACK}Valitse lentokentän koko ja tyyppi.
 STR_305C_0                                                      :{STATION} {STATIONFEATURES}
 STR_STATION_SIGN_TINY                                           :{TINYFONT}{STATION}
 STR_305E_RAILROAD_STATION                                       :Rautatieasema
@@ -1782,7 +1791,7 @@
 STR_3069_BUOY                                                   :Poiju
 STR_306A_BUOY_IN_THE_WAY                                        :{WHITE}...poiju on tiellä.
 STR_306C_STATION_TOO_SPREAD_OUT                                 :{WHITE}...asema liian levittäytynyt.
-STR_306D_NONUNIFORM_STATIONS_DISALLOWED                         :{WHITE}...epäyhdenmukaiset asemat poissa käytöstä.
+STR_306D_NONUNIFORM_STATIONS_DISALLOWED                         :{WHITE}...epäsymmetriset asemat poissa käytöstä.
 STR_USE_CTRL_TO_SELECT_MORE                                     :{BLACK}Pidä CTRL painettuna valitaksesi enemmän kuin yhden tavaran
 
 STR_UNDEFINED                                                   :(määrittelemätön)
@@ -1790,9 +1799,9 @@
 STR_STAT_CLASS_WAYP                                             :Rastit
 
 ##id 0x3800
-STR_3800_SHIP_DEPOT_ORIENTATION                                 :{WHITE}Telakan suunn.
+STR_3800_SHIP_DEPOT_ORIENTATION                                 :{WHITE}Telakan suunta
 STR_3801_MUST_BE_BUILT_ON_WATER                                 :{WHITE}...se pitää rakentaa veteen.
-STR_3802_CAN_T_BUILD_SHIP_DEPOT                                 :{WHITE}Telakkaa ei voi rakentaa...
+STR_3802_CAN_T_BUILD_SHIP_DEPOT                                 :{WHITE}Telakkaa ei voi rakentaa.
 STR_3803_SELECT_SHIP_DEPOT_ORIENTATION                          :{BLACK}Valitse telakan suunta
 STR_3804_WATER                                                  :Vettä
 STR_3805_COAST_OR_RIVERBANK                                     :Rannikko tai joenpenkka
@@ -2629,7 +2638,9 @@
 STR_TRAIN_NO_POWER                                              :{RED}Ei virtaa
 STR_TRAIN_START_NO_CATENARY                                     :Radasta puuttuu "catenary"; junaa ei voi käynnistää
 
+STR_NEW_VEHICLE_NOW_AVAILABLE                                   :{BLACK}{BIGFONT}Uusi {STRING} on nyt saatavilla!
 STR_NEW_VEHICLE_TYPE                                            :{BLACK}{BIGFONT}{STRING}
+STR_NEW_VEHICLE_NOW_AVAILABLE_WITH_TYPE                         :{BLACK}Uusi {STRING} on nyt saatavilla! - {STRING}
 
 ##id 0x9000
 STR_9000_ROAD_VEHICLE_IN_THE_WAY                                :{WHITE}Ajoneuvo tiellä.
@@ -2894,6 +2905,14 @@
 STR_NEWGRF_ERROR_MSG_INFO                                       :{SILVER}{STRING}
 STR_NEWGRF_ERROR_MSG_WARNING                                    :{RED}Varoitus: {SILVER}{STRING}
 STR_NEWGRF_ERROR_MSG_ERROR                                      :{RED}Virhe: {SILVER}{STRING}
+STR_NEWGRF_ERROR_MSG_FATAL                                      :{RED}Virhe: {SILVER}{STRING}
+STR_NEWGRF_ERROR_VERSION_NUMBER                                 :{STRING} ei toimi tämän TTDPatchin version kanssa.
+STR_NEWGRF_ERROR_DOS_OR_WINDOWS                                 :{STRING} on TTD:n {STRING} versiota varten.
+STR_NEWGRF_ERROR_UNSET_SWITCH                                   :{STRING} ja {STRING} on suunniteltu toimimaan yhdessä
+STR_NEWGRF_ERROR_INVALID_PARAMETER                              :Virheellinen parametri: {STRING}: {STRING} ({NUM})
+STR_NEWGRF_ERROR_LOAD_BEFORE                                    :{STRING} tulee ladata ennen kuin {STRING}.
+STR_NEWGRF_ERROR_LOAD_AFTER                                     :{STRING} tulee ladata vasta kun {STRING} on ladattu.
+STR_NEWGRF_ERROR_AFTER_TRANSLATED_FILE                          :GRF-tiedosto jonka se muuntaa
 
 STR_NEWGRF_ADD                                                  :{BLACK}Lisää
 STR_NEWGRF_ADD_TIP                                              :{BLACK}Lisää NewGRF-tiedosto listaan
--- a/src/lang/french.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/french.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -1288,14 +1288,14 @@
 STR_NETWORK_PLAYER_NAME                                         :{BLACK}Nom du joueur:
 STR_NETWORK_ENTER_NAME_TIP                                      :{BLACK}Ceci est le nom avec lequel les autres joueurs pourront vous identifier
 STR_NETWORK_CONNECTION                                          :{BLACK}Connexion :
-STR_NETWORK_CONNECTION_TIP                                      :{BLACK}Choisir entre un jeu Internet ou sur réseau local
+STR_NETWORK_CONNECTION_TIP                                      :{BLACK}Choisir entre un jeu sur Internet ou sur réseau local
 
 STR_NETWORK_START_SERVER                                        :{BLACK}Démarrer le serveur
 STR_NETWORK_START_SERVER_TIP                                    :{BLACK}Démarre son propre serveur
 
 STR_NETWORK_GAME_NAME                                           :{BLACK}Nom
 STR_NETWORK_GAME_NAME_TIP                                       :{BLACK}Nom de la partie
-STR_NETWORK_INFO_ICONS_TIP                                      :{BLACK}Langage, version du serveur, etc.
+STR_NETWORK_INFO_ICONS_TIP                                      :{BLACK}Langue, version du serveur, etc.
 STR_NETWORK_CLICK_GAME_TO_SELECT                                :{BLACK}Cliquer sur une partie de la liste pour la sélectionner
 
 STR_NETWORK_FIND_SERVER                                         :{BLACK}Trouver un serveur
@@ -1342,7 +1342,7 @@
 STR_NETWORK_LAN_INTERNET                                        :LAN / Internet
 STR_NETWORK_INTERNET_ADVERTISE                                  :Internet (publier)
 STR_NETWORK_COMBO2                                              :{BLACK}{SKIP}{SKIP}{SKIP}{SKIP}{SKIP}{SKIP}{SKIP}{SKIP}{SKIP}{STRING}
-STR_NETWORK_0_PLAYERS                                           :0 joueur
+STR_NETWORK_0_PLAYERS                                           :0 joueurs
 STR_NETWORK_1_PLAYERS                                           :1 joueur
 STR_NETWORK_2_PLAYERS                                           :2 joueurs
 STR_NETWORK_3_PLAYERS                                           :3 joueurs
@@ -1413,8 +1413,8 @@
 STR_NETWORK_CONNECTING_SPECIAL_1                                :{BLACK}Rapatriement des infos sur le jeu..
 STR_NETWORK_CONNECTING_SPECIAL_2                                :{BLACK}Rapatriement des infos sur la compagnie..
 ############ End of leave-in-this-order
-STR_NETWORK_CONNECTING_WAITING                                  :{BLACK}{NUM} client{P "" s} avant nous
-STR_NETWORK_CONNECTING_DOWNLOADING                              :{BLACK}{NUM} / {NUM} ko déjà téléchargés
+STR_NETWORK_CONNECTING_WAITING                                  :{BLACK}{NUM} client{P "" s} avant vous
+STR_NETWORK_CONNECTING_DOWNLOADING                              :{BLACK}{NUM} / {NUM} ko téléchargés
 
 STR_NETWORK_DISCONNECT                                          :{BLACK}Déconnecter
 
@@ -1426,7 +1426,7 @@
 STR_NETWORK_ERR_NOTAVAILABLE                                    :{WHITE} Aucun périphérique réseau trouvé ou programme compilé sans ENABLE_NETWORK
 STR_NETWORK_ERR_NOSERVER                                        :{WHITE} Aucune partie réseau n'a été trouvée
 STR_NETWORK_ERR_NOCONNECTION                                    :{WHITE} Le serveur n'a pas répondu à la requête
-STR_NETWORK_ERR_NEWGRF_MISMATCH                                 :{WHITE} Echec de la connexion à cause de NewGRF différents
+STR_NETWORK_ERR_NEWGRF_MISMATCH                                 :{WHITE} Echec de la connexion : NewGRF requis
 STR_NETWORK_ERR_DESYNC                                          :{WHITE} La synchronisation de la partie réseau a échouée.
 STR_NETWORK_ERR_LOSTCONNECTION                                  :{WHITE} La connection de la partie réseau a été perdue.
 STR_NETWORK_ERR_SAVEGAMEERROR                                   :{WHITE} La sauvegarde serveur n'a pas pu être chargée.
@@ -1436,7 +1436,7 @@
 STR_NETWORK_ERR_SERVER_ERROR                                    :{WHITE} Il y a eu une erreur de protocole et la connection est donc fermée.
 STR_NETWORK_ERR_WRONG_REVISION                                  :{WHITE} La révision de ce client ne correspond pas à celle du serveur.
 STR_NETWORK_ERR_WRONG_PASSWORD                                  :{WHITE} Mot de passe incorrect.
-STR_NETWORK_ERR_SERVER_FULL                                     :{WHITE} Le serveur est plein
+STR_NETWORK_ERR_SERVER_FULL                                     :{WHITE} Le serveur est complet
 STR_NETWORK_ERR_SERVER_BANNED                                   :{WHITE} Vous êtes bannis de ce serveur
 STR_NETWORK_ERR_KICKED                                          :{WHITE} Vous avez été exclu de la partie
 STR_NETWORK_ERR_CHEATER                                         :{WHITE} Tricher n'est pas autorisé sur ce serveur
@@ -1448,7 +1448,7 @@
 STR_NETWORK_ERR_CLIENT_SAVEGAME                                 :chargement de la carte impossible
 STR_NETWORK_ERR_CLIENT_CONNECTION_LOST                          :connection perdue
 STR_NETWORK_ERR_CLIENT_PROTOCOL_ERROR                           :erreur de protocole
-STR_NETWORK_ERR_CLIENT_NEWGRF_MISMATCH                          :NewGRF différents
+STR_NETWORK_ERR_CLIENT_NEWGRF_MISMATCH                          :NewGRF requis
 STR_NETWORK_ERR_CLIENT_NOT_AUTHORIZED                           :non autorisé
 STR_NETWORK_ERR_CLIENT_NOT_EXPECTED                             :paquet étrange reçu
 STR_NETWORK_ERR_CLIENT_WRONG_REVISION                           :révision incorrecte
@@ -1723,7 +1723,7 @@
 STR_3003_NUMBER_OF_TRACKS                                       :{BLACK}Nombre de voies
 STR_3004_PLATFORM_LENGTH                                        :{BLACK}Longueur du quai
 STR_3005_TOO_CLOSE_TO_ANOTHER_RAILROAD                          :{WHITE}Trop près d'une autre gare
-STR_3006_ADJOINS_MORE_THAN_ONE_EXISTING                         :{WHITE}Ajouter une ou plusieurs gares
+STR_3006_ADJOINS_MORE_THAN_ONE_EXISTING                         :{WHITE}Adjacent à plus d'une gare à la fois
 STR_3007_TOO_MANY_STATIONS_LOADING                              :{WHITE}Trop de gares dans cette ville
 STR_3008_TOO_MANY_STATIONS_LOADING                              :{WHITE}Trop de gares
 STR_3008A_TOO_MANY_BUS_STOPS                                    :{WHITE}Trop d'arrêts d'autobus
--- a/src/lang/german.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/german.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -728,6 +728,7 @@
 STR_028D_PLACE_LIGHTHOUSE                                       :{BLACK}Leuchtturm errichten
 STR_028E_PLACE_TRANSMITTER                                      :{BLACK}Sender errichten
 STR_028F_DEFINE_DESERT_AREA                                     :{BLACK}Lege Wüstengebiet an.{}STRG drücken zum entfernen
+STR_CREATE_LAKE                                                 :{BLACK}Wasser erzeugen.{}Baut einen Kanal. Bei gedrückter Strg.-Taste wird ein Wasserfeld erzeugt, das umliegendes Land flutet.
 STR_0290_DELETE                                                 :{BLACK}Löschen
 STR_0291_DELETE_THIS_TOWN_COMPLETELY                            :{BLACK}Diese Stadt vollständig löschen
 STR_0292_SAVE_SCENARIO                                          :Szenario speichern
@@ -1090,6 +1091,9 @@
 STR_CONFIG_PATCHES_LIVERIES_OWN                                 :Eigene Firma
 STR_CONFIG_PATCHES_LIVERIES_ALL                                 :Alle Firmen
 STR_CONFIG_PATCHES_PREFER_TEAMCHAT                              :{LTBLUE}Bevorzuge Teamchat mit <ENTER>: {ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_ZOOM                             :Karte vergrößern
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLL                           :Kartenansicht verschieben
+STR_CONFIG_PATCHES_SCROLLWHEEL_OFF                              :Aus
 
 STR_CONFIG_PATCHES_MAX_TRAINS                                   :{LTBLUE}Maximale Anzahl der Züge pro Spieler: {ORANGE}{STRING}
 STR_CONFIG_PATCHES_MAX_ROADVEH                                  :{LTBLUE}Maximale Anzahl der Straßenfahrzeuge pro Spieler: {ORANGE}{STRING}
@@ -1208,6 +1212,7 @@
 STR_TREES_RANDOM_TYPE_TIP                                       :{BLACK}Zufällige Baumart pflanzen
 
 STR_CANT_BUILD_CANALS                                           :{WHITE}Kann hier keinen Kanal bauen...
+STR_BUILD_CANALS_TIP                                            :{BLACK}Kanalbau.
 STR_LANDINFO_CANAL                                              :Kanal
 
 STR_CANT_BUILD_LOCKS                                            :{WHITE}Kann hier keine Schleuse bauen...
--- a/src/lang/hungarian.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/hungarian.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -1159,6 +1159,7 @@
 STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLLING                        :{LTBLUE}Scrollgomb funkció: {ORANGE}{STRING}
 STR_CONFIG_PATCHES_SCROLLWHEEL_ZOOM                             :Térkép nagyítás
 STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLL                           :Térkép mozgatás
+STR_CONFIG_PATCHES_SCROLLWHEEL_OFF                              :Ki
 STR_CONFIG_PATCHES_SCROLLWHEEL_MULTIPLIER                       :{LTBLUE}Scrollgomb sebessége a térképen: {ORANGE}{STRING}
 
 STR_CONFIG_PATCHES_MAX_TRAINS                                   :{LTBLUE}Maximum vonat játékosonként: {ORANGE}{STRING}
--- a/src/lang/italian.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/italian.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -1,7 +1,8 @@
 ##name Italian
-##ownname Italian (IT)
-##isocode it_IT
+##ownname Italiano
+##isocode it
 ##plural 0
+##gender m f
 
 ##id 0x0000
 STR_NULL                                                        :
@@ -33,55 +34,55 @@
 STR_001A_COPPER_ORE                                             :Minerali di Rame
 STR_001B_MAIZE                                                  :Mais
 STR_001C_FRUIT                                                  :Frutta
-STR_001D_DIAMONDS                                               :Diamanti
-STR_001E_FOOD                                                   :Cibo
-STR_001F_PAPER                                                  :Carta
-STR_0020_GOLD                                                   :Oro
-STR_0021_WATER                                                  :Acqua
-STR_0022_WHEAT                                                  :Frumento
-STR_0023_RUBBER                                                 :Gomma
-STR_0024_SUGAR                                                  :Zucchero
-STR_0025_TOYS                                                   :Giocattoli
-STR_0026_CANDY                                                  :Caramelle
-STR_0027_COLA                                                   :Cola
-STR_0028_COTTON_CANDY                                           :Cotone Candito
-STR_0029_BUBBLES                                                :Bolle
-STR_002A_TOFFEE                                                 :Toffee
-STR_002B_BATTERIES                                              :Batterie
-STR_002C_PLASTIC                                                :Plastica
-STR_002D_FIZZY_DRINKS                                           :Bibite Frizzanti
+STR_001D_DIAMONDS                                               :{G=m}Diamanti
+STR_001E_FOOD                                                   :{G=m}Cibo
+STR_001F_PAPER                                                  :{G=f}Carta
+STR_0020_GOLD                                                   :{G=m}Oro
+STR_0021_WATER                                                  :{G=f}Acqua
+STR_0022_WHEAT                                                  :{G=m}Frumento
+STR_0023_RUBBER                                                 :{G=f}Gomma
+STR_0024_SUGAR                                                  :{G=m}Zucchero
+STR_0025_TOYS                                                   :{G=m}Giocattoli
+STR_0026_CANDY                                                  :{G=f}Caramelle
+STR_0027_COLA                                                   :{G=f}Cola
+STR_0028_COTTON_CANDY                                           :{G=m}Cotone Candito
+STR_0029_BUBBLES                                                :{G=f}Bolle
+STR_002A_TOFFEE                                                 :{G=m}Toffee
+STR_002B_BATTERIES                                              :{G=f}Batterie
+STR_002C_PLASTIC                                                :{G=f}Plastica
+STR_002D_FIZZY_DRINKS                                           :{G=f}Bibite Frizzanti
 STR_002E                                                        :
-STR_002F_PASSENGER                                              :Passeggero
-STR_0030_COAL                                                   :Carbone
-STR_0031_MAIL                                                   :Posta
-STR_0032_OIL                                                    :Petrolio
-STR_0033_LIVESTOCK                                              :Bestiame
-STR_0034_GOODS                                                  :Beni
-STR_0035_GRAIN                                                  :Grano
-STR_0036_WOOD                                                   :Legname
-STR_0037_IRON_ORE                                               :Minerale Ferroso
-STR_0038_STEEL                                                  :Acciaio
-STR_0039_VALUABLES                                              :Valori
-STR_003A_COPPER_ORE                                             :Minerale di Rame
-STR_003B_MAIZE                                                  :Mais
-STR_003C_FRUIT                                                  :Frutta
-STR_003D_DIAMOND                                                :Diamante
-STR_003E_FOOD                                                   :Cibo
-STR_003F_PAPER                                                  :Carta
-STR_0040_GOLD                                                   :Oro
-STR_0041_WATER                                                  :Acqua
-STR_0042_WHEAT                                                  :Frumento
-STR_0043_RUBBER                                                 :Gomma
-STR_0044_SUGAR                                                  :Zucchero
-STR_0045_TOY                                                    :Giocattolo
-STR_0046_CANDY                                                  :Caramella
-STR_0047_COLA                                                   :Cola
-STR_0048_COTTON_CANDY                                           :Cotone Candito
-STR_0049_BUBBLE                                                 :Bolla
-STR_004A_TOFFEE                                                 :Toffee
-STR_004B_BATTERY                                                :Batteria
-STR_004C_PLASTIC                                                :Plastica
-STR_004D_FIZZY_DRINK                                            :Bevanda Frizzante
+STR_002F_PASSENGER                                              :{G=m}Passeggero
+STR_0030_COAL                                                   :{G=m}Carbone
+STR_0031_MAIL                                                   :{G=f}Posta
+STR_0032_OIL                                                    :{G=m}Petrolio
+STR_0033_LIVESTOCK                                              :{G=m}Bestiame
+STR_0034_GOODS                                                  :{G=m}Beni
+STR_0035_GRAIN                                                  :{G=m}Grano
+STR_0036_WOOD                                                   :{G=m}Legname
+STR_0037_IRON_ORE                                               :{G=m}Minerale Ferroso
+STR_0038_STEEL                                                  :{G=m}Acciaio
+STR_0039_VALUABLES                                              :{G=m}Valori
+STR_003A_COPPER_ORE                                             :{G=m}Minerale di Rame
+STR_003B_MAIZE                                                  :{G=m}Mais
+STR_003C_FRUIT                                                  :{G=f}Frutta
+STR_003D_DIAMOND                                                :{G=m}Diamante
+STR_003E_FOOD                                                   :{G=m}Cibo
+STR_003F_PAPER                                                  :{G=f}Carta
+STR_0040_GOLD                                                   :{G=m}Oro
+STR_0041_WATER                                                  :{G=f}Acqua
+STR_0042_WHEAT                                                  :{G=m}Frumento
+STR_0043_RUBBER                                                 :{G=f}Gomma
+STR_0044_SUGAR                                                  :{G=m}Zucchero
+STR_0045_TOY                                                    :{G=m}Giocattolo
+STR_0046_CANDY                                                  :{G=f}Caramella
+STR_0047_COLA                                                   :{G=f}Cola
+STR_0048_COTTON_CANDY                                           :{G=m}Cotone Candito
+STR_0049_BUBBLE                                                 :{G=f}Bolla
+STR_004A_TOFFEE                                                 :{G=m}Toffee
+STR_004B_BATTERY                                                :{G=f}Batteria
+STR_004C_PLASTIC                                                :{G=f}Plastica
+STR_004D_FIZZY_DRINK                                            :{G=f}Bevanda Frizzante
 STR_QUANTITY_NOTHING                                            :
 STR_QUANTITY_PASSENGERS                                         :{COMMA} passegger{P o i}
 STR_QUANTITY_COAL                                               :{WEIGHT} di carbone
@@ -399,7 +400,7 @@
 STR_AVAILABLE_TRAINS                                            :{BLACK}Treni Disponibili
 STR_AVAILABLE_ROAD_VEHICLES                                     :{BLACK}Veicoli Disponibili
 STR_AVAILABLE_SHIPS                                             :{BLACK}Navi Disponibili
-STR_AVAILABLE_AIRCRAFT                                          :{BLACK}Available Aircraft
+STR_AVAILABLE_AIRCRAFT                                          :{BLACK}Aerei Disponibili
 STR_AVAILABLE_ENGINES_TIP                                       :{BLACK}Mostra una lista di motrici disponibili per quel tipo di veicolo
 STR_MANAGE_LIST                                                 :{BLACK}Gestisci lista
 STR_MANAGE_LIST_TIP                                             :{BLACK}Manda istruzioni a tutti i veicoli in questa lista
@@ -2913,6 +2914,7 @@
 STR_NEWGRF_ERROR_INVALID_PARAMETER                              :Parametri invalidi per {STRING}: parametri {STRING} ({NUM})
 STR_NEWGRF_ERROR_LOAD_BEFORE                                    :{STRING} deve essere caricato prima di {STRING}.
 STR_NEWGRF_ERROR_LOAD_AFTER                                     :{STRING} deve essere caricato dopo {STRING}.
+STR_NEWGRF_ERROR_AFTER_TRANSLATED_FILE                          :il file GRF se questo era progettato per essere tradotto
 
 STR_NEWGRF_ADD                                                  :{BLACK}Aggiungi
 STR_NEWGRF_ADD_TIP                                              :{BLACK}Aggiungi un file NewGRF alla lista
--- a/src/lang/portuguese.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/portuguese.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -727,6 +727,7 @@
 STR_028D_PLACE_LIGHTHOUSE                                       :{BLACK}Colocar farol
 STR_028E_PLACE_TRANSMITTER                                      :{BLACK}Colocar transmissor
 STR_028F_DEFINE_DESERT_AREA                                     :{BLACK}Definir área de deserto.{}Manter a tecla CTRL pressionada para remover
+STR_CREATE_LAKE                                                 :{BLACK}Definir área de água.{}Construir um canal com a tecla CTRL numa área que não seja a do mar, senão inundar-se-iam as zonas circundantes
 STR_0290_DELETE                                                 :{BLACK}Apagar
 STR_0291_DELETE_THIS_TOWN_COMPLETELY                            :{BLACK}Apagar completamente esta cidade
 STR_0292_SAVE_SCENARIO                                          :Guardar cenário
@@ -1089,6 +1090,11 @@
 STR_CONFIG_PATCHES_LIVERIES_OWN                                 :Própria companhia
 STR_CONFIG_PATCHES_LIVERIES_ALL                                 :Todas as companhias
 STR_CONFIG_PATCHES_PREFER_TEAMCHAT                              :{LTBLUE}Escolher chat de equipa com <ENTER>: {ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLLING                        :{LTBLUE}Função de scrollwheel: {ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_ZOOM                             :Ampliar mapa
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLL                           :Percorrer mapa
+STR_CONFIG_PATCHES_SCROLLWHEEL_OFF                              :Desligado
+STR_CONFIG_PATCHES_SCROLLWHEEL_MULTIPLIER                       :{LTBLUE}Velocidade do scrollwheel no mapa: {ORANGE}{STRING}
 
 STR_CONFIG_PATCHES_MAX_TRAINS                                   :{LTBLUE}Máximo de comboios por jogador: {ORANGE}{STRING}
 STR_CONFIG_PATCHES_MAX_ROADVEH                                  :{LTBLUE}Máximo de veículos de estrada por jogador: {ORANGE}{STRING}
@@ -1207,6 +1213,7 @@
 STR_TREES_RANDOM_TYPE_TIP                                       :{BLACK}Colocar árvores de tipo aleatório
 
 STR_CANT_BUILD_CANALS                                           :{WHITE}Não é possível construir canais aqui...
+STR_BUILD_CANALS_TIP                                            :{BLACK}Construir canais.
 STR_LANDINFO_CANAL                                              :Canal
 
 STR_CANT_BUILD_LOCKS                                            :{WHITE}Não é possível construir diques aqui...
@@ -2906,6 +2913,7 @@
 STR_NEWGRF_ERROR_INVALID_PARAMETER                              :Parâmetro inválido para {STRING}: parâmetro {STRING} ({NUM})
 STR_NEWGRF_ERROR_LOAD_BEFORE                                    :{STRING} deve ser carregado antes de {STRING}.
 STR_NEWGRF_ERROR_LOAD_AFTER                                     :{STRING} deve ser carregado antes de {STRING}.
+STR_NEWGRF_ERROR_AFTER_TRANSLATED_FILE                          :O ficheiro GRF foi desenhado para traduzir
 
 STR_NEWGRF_ADD                                                  :{BLACK}Adicionar
 STR_NEWGRF_ADD_TIP                                              :{BLACK}Adicionar um ficheiro NewGRF à lista
--- a/src/lang/simplified_chinese.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/simplified_chinese.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -591,6 +591,7 @@
 STR_0207_ARRIVAL_OF_FIRST_VEHICLE                               :{YELLOW}对手车站的剪彩仪å¼
 STR_0208_ACCIDENTS_DISASTERS                                    :{YELLOW}事故/ç¾éš¾
 STR_0209_COMPANY_INFORMATION                                    :{YELLOW}å…¬å¸ä¿¡æ¯
+STR_NEWS_OPEN_CLOSE                                             :{YELLOW}å¼€å¯/关闭工业设施
 STR_020A_ECONOMY_CHANGES                                        :{YELLOW}ç»æµŽå˜åŒ–
 STR_020B_ADVICE_INFORMATION_ON_PLAYER                           :{YELLOW}玩家车辆的状况报告
 STR_020C_NEW_VEHICLES                                           :{YELLOW}新的车辆类型
@@ -726,6 +727,7 @@
 STR_028D_PLACE_LIGHTHOUSE                                       :{BLACK}放置ç¯å¡”
 STR_028E_PLACE_TRANSMITTER                                      :{BLACK}放置转播塔
 STR_028F_DEFINE_DESERT_AREA                                     :{BLACK}定义沙漠区域。{}æ‘ä½ CTRL å¯ä»¥åŽ»æŽ‰æ²™æ¼ åŒºåŸŸã€‚
+STR_CREATE_LAKE                                                 :{BLACK}定义水域。{}ä¿®å»ºè¿æ²³ï¼Œä»…在CTRL被按下的情况下ä¸ä¼šåœ¨æµ·å¹³é¢æ·¹æ²¡å‘¨å›´çš„区域。
 STR_0290_DELETE                                                 :{BLACK}删除
 STR_0291_DELETE_THIS_TOWN_COMPLETELY                            :{BLACK}完全删除这座城镇
 STR_0292_SAVE_SCENARIO                                          :ä¿å­˜åœºæ™¯
@@ -1088,6 +1090,11 @@
 STR_CONFIG_PATCHES_LIVERIES_OWN                                 :本公å¸
 STR_CONFIG_PATCHES_LIVERIES_ALL                                 :所有公å¸
 STR_CONFIG_PATCHES_PREFER_TEAMCHAT                              :{LTBLUE}输入 <ENTER> 时与å好的团队交谈:{ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLLING                        :{LTBLUE}鼠标滚轮的作用:{ORANGE}{STRING}
+STR_CONFIG_PATCHES_SCROLLWHEEL_ZOOM                             :缩放地图
+STR_CONFIG_PATCHES_SCROLLWHEEL_SCROLL                           :滚动地图
+STR_CONFIG_PATCHES_SCROLLWHEEL_OFF                              :关闭
+STR_CONFIG_PATCHES_SCROLLWHEEL_MULTIPLIER                       :{LTBLUE}地图滚动速度:{ORANGE}{STRING}
 
 STR_CONFIG_PATCHES_MAX_TRAINS                                   :{LTBLUE}æ¯ä½çŽ©å®¶æœ€å¤§ç«è½¦æ•°é‡ï¼š{ORANGE}{STRING}
 STR_CONFIG_PATCHES_MAX_ROADVEH                                  :{LTBLUE}æ¯ä½çŽ©å®¶æœ€å¤§æ±½è½¦æ•°é‡ï¼š{ORANGE}{STRING}
@@ -1206,6 +1213,7 @@
 STR_TREES_RANDOM_TYPE_TIP                                       :{BLACK}ç§æ¤éšæœºç±»åž‹çš„æ ‘æœ¨
 
 STR_CANT_BUILD_CANALS                                           :{WHITE}ä¸èƒ½åœ¨è¿™é‡Œå…´å»ºè¿æ²³â€¦â€¦
+STR_BUILD_CANALS_TIP                                            :{BLACK}ä¿®å»ºè¿æ²³ã€‚
 STR_LANDINFO_CANAL                                              :è¿æ²³
 
 STR_CANT_BUILD_LOCKS                                            :{WHITE}ä¸èƒ½åœ¨è¿™é‡Œå…´å»ºèˆ¹é—¸â€¦â€¦
@@ -2905,6 +2913,7 @@
 STR_NEWGRF_ERROR_INVALID_PARAMETER                              :{STRING} 傿•°é”™è¯¯ï¼šå‚æ•° {STRING} ({NUM})
 STR_NEWGRF_ERROR_LOAD_BEFORE                                    :{STRING} 必须在 {STRING} å‰åŠ è½½ã€‚
 STR_NEWGRF_ERROR_LOAD_AFTER                                     :{STRING} 必须在 {STRING} åŽåŠ è½½ã€‚
+STR_NEWGRF_ERROR_AFTER_TRANSLATED_FILE                          :GRF 被设计为å¯å¹³ç§»
 
 STR_NEWGRF_ADD                                                  :{BLACK}增加
 STR_NEWGRF_ADD_TIP                                              :{BLACK}å‘列表中增加一个 NewGRF 文件
--- a/src/lang/traditional_chinese.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/traditional_chinese.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -727,6 +727,7 @@
 STR_028D_PLACE_LIGHTHOUSE                                       :{BLACK}建立燈塔
 STR_028E_PLACE_TRANSMITTER                                      :{BLACK}建立發射站
 STR_028F_DEFINE_DESERT_AREA                                     :{BLACK}定義沙漠å€ã€‚{}è«‹æŒ‰ä½ CTRL 移除
+STR_CREATE_LAKE                                                 :{BLACK}劃出湖泊範åœã€‚{}é–‹é‘¿é‹æ²³ã€‚在海平é¢ä¸ŠæŒ‰ CTRL éµå‰‡æœƒæ·¹æ²«é€±é­åœŸåœ°
 STR_0290_DELETE                                                 :{BLACK}刪除
 STR_0291_DELETE_THIS_TOWN_COMPLETELY                            :{BLACK}完全移除這個市鎮
 STR_0292_SAVE_SCENARIO                                          :儲存場景
@@ -1212,6 +1213,7 @@
 STR_TREES_RANDOM_TYPE_TIP                                       :{BLACK}種æ¤éš¨æ©Ÿç¨®é¡žæ¨¹æœ¨
 
 STR_CANT_BUILD_CANALS                                           :{WHITE}ä¸å¯ä»¥åœ¨é€™è£é–‹é‘¿é‹æ²³...
+STR_BUILD_CANALS_TIP                                            :{BLACK}é–‹é‘¿é‹æ²³ã€‚
 STR_LANDINFO_CANAL                                              :鋿²³
 
 STR_CANT_BUILD_LOCKS                                            :{WHITE}ä¸å¯ä»¥åœ¨é€™è£èˆˆå»ºæ°´é–˜...
--- a/src/lang/ukrainian.txt	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/lang/ukrainian.txt	Thu Apr 19 14:43:25 2007 +0000
@@ -597,7 +597,7 @@
 STR_0195_SHOW_VEGETATION_ON_MAP                                 :{BLACK}Показати роÑлинніÑть на карті
 STR_0196_SHOW_LAND_OWNERS_ON_MAP                                :{BLACK}Показати влаÑників землі на карті
 STR_0197_TOGGLE_TOWN_NAMES_ON_OFF                               :{BLACK}Показати назви міÑÑ‚ на карті
-STR_0198_PROFIT_THIS_YEAR_LAST_YEAR                             :{TINYFONT}{BLACK}Прибуток цього року: {CURRENCY} (минулого року: {CURRENCY})
+STR_0198_PROFIT_THIS_YEAR_LAST_YEAR                             :{TINYFONT}{BLACK}Прибуток цього року: {CURRENCY} (торік: {CURRENCY})
 
 ############ range for service numbers starts
 STR_AGE                                                         :{COMMA} р{P ік оки оків} ({COMMA})
@@ -1106,7 +1106,7 @@
 STR_END_OF_SHARED_ORDERS                                        :{SETX 10}- - Кінець наказів - -
 
 STR_TRAIN_IS_LOST                                               :{WHITE}Поїзд {COMMA} заблукав.
-STR_TRAIN_IS_UNPROFITABLE                                       :{WHITE}Поїзд {COMMA} Ð¿Ñ€Ð¸Ð½Ñ–Ñ Ð¿Ñ€Ð¸Ð±ÑƒÑ‚Ð¾Ðº минулого року {CURRENCY}
+STR_TRAIN_IS_UNPROFITABLE                                       :{WHITE}Поїзд {COMMA} торік Ð¿Ñ€Ð¸Ð½Ñ–Ñ Ð¿Ñ€Ð¸Ð±ÑƒÑ‚Ð¾Ðº {CURRENCY}
 STR_EURO_INTRODUCE                                              :{BLACK}{BIGFONT}ЄвропейÑька грошова одиницÑ!{}{}У вашій країні введено євро - єдину валюту Ð´Ð»Ñ Ñ€Ð¾Ð·Ñ€Ð°Ñ…ÑƒÐ½ÐºÑ–Ð²!
 
 # Start of order review system.
@@ -1518,7 +1518,7 @@
 STR_NETWORK_INAUGURATION_YEAR                                   :{SILVER}ЗаÑновано:  {WHITE}{NUM}
 STR_NETWORK_VALUE                                               :{SILVER}ВартіÑть компанії:  {WHITE}{CURRENCY64}
 STR_NETWORK_CURRENT_BALANCE                                     :{SILVER}Поточний баланÑ:  {WHITE}{CURRENCY64}
-STR_NETWORK_LAST_YEARS_INCOME                                   :{SILVER}Прибуток минулого року:  {WHITE}{CURRENCY64}
+STR_NETWORK_LAST_YEARS_INCOME                                   :{SILVER}Прибуток торік:  {WHITE}{CURRENCY64}
 STR_NETWORK_PERFORMANCE                                         :{SILVER}ПродуктивніÑть:  {WHITE}{NUM}
 
 STR_NETWORK_VEHICLES                                            :{SILVER}ТранÑпорт:  {WHITE}{NUM} {TRAIN}, {NUM} {LORRY}, {NUM} {BUS}, {NUM} {PLANE}, {NUM} {SHIP}
@@ -2317,16 +2317,16 @@
 STR_7058_PRESIDENT                                              :{BLACK}{PLAYERNAME}{}(Керівник)
 STR_7059_TRANSPORT_COMPANY_MERGER                               :{BLACK}{BIGFONT}Компанії об'єдналиÑÑ!
 STR_705A_HAS_BEEN_SOLD_TO_FOR                                   :{BLACK}{BIGFONT}{COMPANY} була викуплена {COMPANY} за {CURRENCY}!
-STR_705B_WE_ARE_LOOKING_FOR_A_TRANSPORT                         :{WHITE}Ми шукаємо нового влаÑника нашої компанії.{}{}Ви бажаєте купити {COMPANY} за {CURRENCY}?
+STR_705B_WE_ARE_LOOKING_FOR_A_TRANSPORT                         :{WHITE}Ми шукаємо нового влаÑника нашої компанії.{}{}Чи бажаєте Ви купити {COMPANY} за {CURRENCY}?
 STR_705C_BANKRUPT                                               :{BLACK}{BIGFONT}БÐÐКРУТ!
-STR_705D_HAS_BEEN_CLOSED_DOWN_BY                                :{BLACK}{BIGFONT}{COMPANY} буде закрита кредиторами Ñ– вÑе майно буде продане!
+STR_705D_HAS_BEEN_CLOSED_DOWN_BY                                :{BLACK}{BIGFONT}{COMPANY} була закрита кредиторами Ñ– вÑе майно продане!
 STR_705E_NEW_TRANSPORT_COMPANY_LAUNCHED                         :{BLACK}{BIGFONT}ЗаÑновано нову компанію!
 STR_705F_STARTS_CONSTRUCTION_NEAR                               :{BLACK}{BIGFONT}{COMPANY} починає будівництво Ð±Ñ–Ð»Ñ {TOWN}!
 STR_7060_CAN_T_BUY_COMPANY                                      :{WHITE}Ðеможливо купити компанію...
 STR_7061_CARGO_PAYMENT_RATES                                    :{WHITE}Тарифи на доÑтавку вантажів
 STR_7062_DAYS_IN_TRANSIT                                        :{BLACK}{TINYFONT}Днів у дорозі
 STR_7063_PAYMENT_FOR_DELIVERING                                 :{BLACK}{TINYFONT}Плата за доÑтавку 10 одиниць (або 10,000 літрів) вантажу на відÑтань 20 квадратів
-STR_7064_TOGGLE_GRAPH_FOR_CARGO                                 :{BLACK}Вкл/викл графік типів вантажу
+STR_7064_TOGGLE_GRAPH_FOR_CARGO                                 :{BLACK}Вкл/відкл графік типів вантажу
 STR_7065                                                        :{BLACK}{TINYFONT}{STRING}
 STR_7066_ENGINEER                                               :Інженер
 STR_7067_TRAFFIC_MANAGER                                        :Регулювальник
@@ -2347,7 +2347,7 @@
 STR_COMPANY_PASSWORD_TOOLTIP                                    :{BLACK}Пароль захищає вашу компанію від Ð¿Ñ€Ð¸Ñ”Ð´Ð½Ð°Ð½Ð½Ñ Ñ–Ð½ÑˆÐ¸Ñ… гравців.
 STR_SET_COMPANY_PASSWORD                                        :Ð’ÑÑ‚Ð°Ð½Ð¾Ð²Ð»ÐµÐ½Ð½Ñ Ð¿Ð°Ñ€Ð¾Ð»ÑŽ
 STR_7073_WORLD_RECESSION_FINANCIAL                              :{BIGFONT}{BLACK}Світова економічна криза!{}{}ФінанÑиÑти очікують Ñпад виробництва та попиту!
-STR_7074_RECESSION_OVER_UPTURN_IN                               :{BIGFONT}{BLACK}Криза минула!{}{}Ð—Ð±Ñ–Ð»ÑŒÑˆÐµÐ½Ð½Ñ Ð´Ñ–ÑльноÑті підніме промиÑловіÑть коли економіка ÑтабілізуєтьÑÑ!
+STR_7074_RECESSION_OVER_UPTURN_IN                               :{BIGFONT}{BLACK}Криза минула!{}{}Ð—Ð±Ñ–Ð»ÑŒÑˆÐµÐ½Ð½Ñ Ð²Ð¸Ñ€Ð¾Ð±Ð½Ð¸Ñ†Ñ‚Ð²Ð° внаÑлідок Ñтабілізації економіки надає впевненоÑті підприємÑтвам!
 STR_7075_TOGGLE_LARGE_SMALL_WINDOW                              :{BLACK}Розмір вікна великий/малий
 STR_7076_COMPANY_VALUE                                          :{GOLD}ВартіÑть компанії: {WHITE}{CURRENCY64}
 STR_7077_BUY_25_SHARE_IN_COMPANY                                :{BLACK}Купити 25% акцій компанії
@@ -2780,7 +2780,7 @@
 STR_885D_AGE_RUNNING_COST_YR                                    :{BLACK}Вік: {LTBLUE}{STRING}{BLACK}   ТранÑпортні витрати: {LTBLUE}{CURRENCY}/рік
 STR_VEHICLE_INFO_WEIGHT_POWER_MAX_SPEED                         :{BLACK}Вага: {LTBLUE}{WEIGHT_S}  {BLACK}ПотужніÑть: {LTBLUE}{POWER}{BLACK} МакÑ. швидкіÑть: {LTBLUE}{VELOCITY}
 STR_VEHICLE_INFO_WEIGHT_POWER_MAX_SPEED_MAX_TE                  :{BLACK}Вага: {LTBLUE}{WEIGHT_S} {BLACK}ПотужніÑть: {LTBLUE}{POWER}{BLACK} МакÑ. швидкіÑть: {LTBLUE}{VELOCITY} {BLACK}МакÑ. T.E.: {LTBLUE}{FORCE}
-STR_885F_PROFIT_THIS_YEAR_LAST_YEAR                             :{BLACK}Прибуток: {LTBLUE}{CURRENCY}  (минулого року: {CURRENCY})
+STR_885F_PROFIT_THIS_YEAR_LAST_YEAR                             :{BLACK}Прибуток: {LTBLUE}{CURRENCY}  (торік: {CURRENCY})
 STR_8860_RELIABILITY_BREAKDOWNS                                 :{BLACK}ÐадійніÑть: {LTBLUE}{COMMA}%  {BLACK}Поломок піÑÐ»Ñ Ð¾Ñтаннього техоглÑду: {LTBLUE}{COMMA}
 STR_8861_STOPPED                                                :{RED}Зупинений
 STR_8862_CAN_T_MAKE_TRAIN_PASS_SIGNAL                           :{WHITE}Ðеможливо проїхати Ñигнал - небезпечно...
@@ -3310,4 +3310,4 @@
 
 ########
 
-STR_FEEDER_CARGO_VALUE                                          :{BLACK}Дохід перевезень: {LTBLUE}{CURRENCY}
+STR_FEEDER_CARGO_VALUE                                          :{BLACK}Плата за транÑфер: {LTBLUE}{CURRENCY}
--- a/src/main_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/main_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1211,7 +1211,7 @@
 
 static void EditorTerraformClick_DesertLightHouse(Window *w)
 {
-	HandlePlacePushButton(w, 10, SPR_CURSOR_LIGHTHOUSE, 1, (_opt.landscape == LT_DESERT) ? PlaceProc_DesertArea : PlaceProc_LightHouse);
+	HandlePlacePushButton(w, 10, SPR_CURSOR_LIGHTHOUSE, 1, (_opt.landscape == LT_TROPIC) ? PlaceProc_DesertArea : PlaceProc_LightHouse);
 }
 
 static void EditorTerraformClick_Transmitter(Window *w)
@@ -1275,7 +1275,7 @@
 	switch (e->event) {
 	case WE_CREATE:
 		/* XXX - lighthouse button is widget 10!! Don't forget when changing */
-		w->widget[10].tooltips = (_opt.landscape == LT_DESERT) ? STR_028F_DEFINE_DESERT_AREA : STR_028D_PLACE_LIGHTHOUSE;
+		w->widget[10].tooltips = (_opt.landscape == LT_TROPIC) ? STR_028F_DEFINE_DESERT_AREA : STR_028D_PLACE_LIGHTHOUSE;
 		break;
 
 	case WE_PAINT:
--- a/src/misc.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/misc.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -245,7 +245,7 @@
 {
 	if (only_constants) return;
 
-	for (CargoID i = 0; i != NUM_CARGO; i++) {
+	for (CargoID i = 0; i < NUM_CARGO; i++) {
 		_cargo_payment_rates[i] = GetCargo(i)->initial_payment;
 		_cargo_payment_rates_frac[i] = 0;
 	}
--- a/src/misc_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/misc_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -141,11 +141,10 @@
 	GetString(_landinfo_data[4], STR_01A8_LOCAL_AUTHORITY, lastof(_landinfo_data[4]));
 
 	{
-		int i;
 		char *p = GetString(_landinfo_data[5], STR_01CE_CARGO_ACCEPTED, lastof(_landinfo_data[5]));
 		bool found = false;
 
-		for (i = 0; i < NUM_CARGO; ++i) {
+		for (CargoID i = 0; i < NUM_CARGO; ++i) {
 			if (ac[i] > 0) {
 				/* Add a comma between each item. */
 				if (found) {
@@ -732,11 +731,10 @@
 {
 	char *b = _userstring;
 	bool first = true;
-	int i;
 
 	b = InlineString(b, STR_000D_ACCEPTS);
 
-	for (i = 0; i != NUM_CARGO; i++, mask >>= 1) {
+	for (CargoID i = 0; i < NUM_CARGO; i++, mask >>= 1) {
 		if (b >= lastof(_userstring) - 5) break;
 		if (accepts[i] >= 8 && mask & 1) {
 			if (first) {
--- a/src/namegen.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/namegen.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file namegen.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "debug.h"
@@ -41,21 +43,21 @@
 {
 	int i;
 
-	//null terminates the string for strcat
+	/* null terminates the string for strcat */
 	strecpy(buf, "", last);
 
-	// optional first segment
+	/* optional first segment */
 	i = SeedChanceBias(0, lengthof(name_original_english_1), seed, 50);
 	if (i >= 0)
 		strecat(buf, name_original_english_1[i], last);
 
-	//mandatory middle segments
+	/* mandatory middle segments */
 	strecat(buf, name_original_english_2[SeedChance(4,  lengthof(name_original_english_2), seed)], last);
 	strecat(buf, name_original_english_3[SeedChance(7,  lengthof(name_original_english_3), seed)], last);
 	strecat(buf, name_original_english_4[SeedChance(10, lengthof(name_original_english_4), seed)], last);
 	strecat(buf, name_original_english_5[SeedChance(13, lengthof(name_original_english_5), seed)], last);
 
-	//optional last segment
+	/* optional last segment */
 	i = SeedChanceBias(15, lengthof(name_original_english_6), seed, 60);
 	if (i >= 0)
 		strecat(buf, name_original_english_6[i], last);
@@ -82,10 +84,10 @@
 {
 	int i;
 
-	//null terminates the string for strcat
+	/* null terminates the string for strcat */
 	strecpy(buf, "", last);
 
-	// optional first segment
+	/* optional first segment */
 	i = SeedChanceBias(0, lengthof(name_additional_english_prefix), seed, 50);
 	if (i >= 0)
 		strecat(buf,name_additional_english_prefix[i], last);
@@ -104,7 +106,7 @@
 
 	strecat(buf, name_additional_english_2[SeedChance(14, lengthof(name_additional_english_2), seed)], last);
 
-	//optional last segment
+	/* optional last segment */
 	i = SeedChanceBias(15, lengthof(name_additional_english_3), seed, 60);
 	if (i >= 0)
 		strecat(buf, name_additional_english_3[i], last);
@@ -128,32 +130,32 @@
 	int i, j = 0;
 	strecpy(buf, "", last);
 
-	// Bad, Maria, Gross, ...
+	/* Bad, Maria, Gross, ... */
 	i = SeedChanceBias(0, lengthof(name_austrian_a1), seed, 15);
 	if (i >= 0) strecat(buf, name_austrian_a1[i], last);
 
 	i = SeedChance(4, 6, seed);
 	if (i >= 4) {
-		// Kaisers-kirchen
+		/* Kaisers-kirchen */
 		strecat(buf, name_austrian_a2[SeedChance( 7, lengthof(name_austrian_a2), seed)], last);
 		strecat(buf, name_austrian_a3[SeedChance(13, lengthof(name_austrian_a3), seed)], last);
 	} else if (i >= 2) {
-		// St. Johann
+		/* St. Johann */
 		strecat(buf, name_austrian_a5[SeedChance( 7, lengthof(name_austrian_a5), seed)], last);
 		strecat(buf, name_austrian_a6[SeedChance( 9, lengthof(name_austrian_a6), seed)], last);
 		j = 1; // More likely to have a " an der " or " am "
 	} else {
-		// Zell
+		/* Zell */
 		strecat(buf, name_austrian_a4[SeedChance( 7, lengthof(name_austrian_a4), seed)], last);
 	}
 
 	i = SeedChance(1, 6, seed);
 	if (i >= 4 - j) {
-		// an der Donau (rivers)
+		/* an der Donau (rivers) */
 		strecat(buf, name_austrian_f1[SeedChance(4, lengthof(name_austrian_f1), seed)], last);
 		strecat(buf, name_austrian_f2[SeedChance(5, lengthof(name_austrian_f2), seed)], last);
 	} else if (i >= 2 - j) {
-		// am Dachstein (mountains)
+		/* am Dachstein (mountains) */
 		strecat(buf, name_austrian_b1[SeedChance(4, lengthof(name_austrian_b1), seed)], last);
 		strecat(buf, name_austrian_b2[SeedChance(5, lengthof(name_austrian_b2), seed)], last);
 	}
@@ -166,18 +168,18 @@
 	uint i;
 	uint seed_derivative;
 
-	//null terminates the string for strcat
+	/* null terminates the string for strcat */
 	strecpy(buf, "", last);
 
 	seed_derivative = SeedChance(7, 28, seed);
 
-	//optional prefix
+	/* optional prefix */
 	if (seed_derivative == 12 || seed_derivative == 19) {
 		i = SeedChance(2, lengthof(name_german_pre), seed);
 		strecat(buf,name_german_pre[i], last);
 	}
 
-	// mandatory middle segments including option of hardcoded name
+	/* mandatory middle segments including option of hardcoded name */
 	i = SeedChance(3, lengthof(name_german_real) + lengthof(name_german_1), seed);
 	if (i < lengthof(name_german_real)) {
 		strecat(buf,name_german_real[i], last);
@@ -188,7 +190,7 @@
 		strecat(buf, name_german_2[i], last);
 	}
 
-	// optional suffix
+	/* optional suffix */
 	if (seed_derivative == 24) {
 		i = SeedChance(9,
 			lengthof(name_german_4_an_der) + lengthof(name_german_4_am), seed);
@@ -226,15 +228,15 @@
 {
 	int i;
 
-	//null terminates the string for strcat
+	/* null terminates the string for strcat */
 	strecpy(buf, "", last);
 
-	// optional first segment
+	/* optional first segment */
 	i = SeedChanceBias(0, lengthof(name_swedish_1), seed, 50);
 	if (i >= 0)
 		strecat(buf, name_swedish_1[i], last);
 
-	// mandatory middle segments including option of hardcoded name
+	/* mandatory middle segments including option of hardcoded name */
 	if (SeedChance(4, 5, seed) >= 3) {
 		strecat(buf, name_swedish_2[SeedChance( 7, lengthof(name_swedish_2), seed)], last);
 	} else {
@@ -252,15 +254,15 @@
 {
 	int i;
 
-	//null terminates the string for strcat
+	/* null terminates the string for strcat */
 	strecpy(buf, "", last);
 
-	// optional first segment
+	/* optional first segment */
 	i = SeedChanceBias(0, lengthof(name_dutch_1), seed, 50);
 	if (i >= 0)
 		strecat(buf, name_dutch_1[i], last);
 
-	// mandatory middle segments including option of hardcoded name
+	/* mandatory middle segments including option of hardcoded name */
 	if (SeedChance(6, 9, seed) > 4) {
 		strecat(buf, name_dutch_2[SeedChance( 9, lengthof(name_dutch_2), seed)], last);
 	} else {
@@ -274,16 +276,16 @@
 
 static byte MakeFinnishTownName(char *buf, uint32 seed, const char *last)
 {
-	//null terminates the string for strcat
+	/* null terminates the string for strcat */
 	strecpy(buf, "", last);
 
-	// Select randomly if town name should consists of one or two parts.
+	/* Select randomly if town name should consists of one or two parts. */
 	if (SeedChance(0, 15, seed) >= 10) {
 		strecat(buf, name_finnish_real[SeedChance(2, lengthof(name_finnish_real), seed)], last);
 	} else if (SeedChance(0, 15, seed) >= 5) {
-		// A two-part name by combining one of name_finnish_1 + "la"/"lä"
-		// The reason for not having the contents of name_finnish_{1,2} in the same table is
-		// that the ones in name_finnish_2 are not good for this purpose.
+		/* A two-part name by combining one of name_finnish_1 + "la"/"lä"
+		 * The reason for not having the contents of name_finnish_{1,2} in the same table is
+		 * that the ones in name_finnish_2 are not good for this purpose. */
 		uint sel = SeedChance( 0, lengthof(name_finnish_1), seed);
 		char *end;
 		strecat(buf, name_finnish_1[sel], last);
@@ -298,8 +300,8 @@
 			strecat(buf, "lä", last);
 		}
 	} else {
-		// A two-part name by combining one of name_finnish_{1,2} + name_finnish_3.
-		// Why aren't name_finnish_{1,2} just one table? See above.
+		/* A two-part name by combining one of name_finnish_{1,2} + name_finnish_3.
+		 * Why aren't name_finnish_{1,2} just one table? See above. */
 		uint sel = SeedChance(2,
 			lengthof(name_finnish_1) + lengthof(name_finnish_2), seed);
 		if (sel >= lengthof(name_finnish_1)) {
@@ -318,10 +320,10 @@
 	uint i;
 	uint j;
 
-	//null terminates the string for strcat
+	/* null terminates the string for strcat */
 	strecpy(buf, "", last);
 
-	// optional first segment
+	/* optional first segment */
 	i = SeedChance(0,
 		lengthof(name_polish_2_o) + lengthof(name_polish_2_m) +
 		lengthof(name_polish_2_f) + lengthof(name_polish_2_n),
@@ -374,13 +376,13 @@
 	CzechChoose choose;
 	CzechAllow allow;
 
-	// 1:3 chance to use a real name.
+	/* 1:3 chance to use a real name. */
 	if (SeedModChance(0, 4, seed) == 0) {
 		strecpy(buf, name_czech_real[SeedModChance(4, lengthof(name_czech_real), seed)], last);
 		return 0;
 	}
 
-	// NUL terminates the string for strcat()
+	/* NUL terminates the string for strcat() */
 	strecpy(buf, "", last);
 
 	prob_tails = SeedModChance(2, 32, seed);
@@ -389,12 +391,12 @@
 
 	if (do_prefix) prefix = SeedModChance(5, lengthof(name_czech_adj) * 12, seed) / 12;
 	if (do_suffix) suffix = SeedModChance(7, lengthof(name_czech_suffix), seed);
-	// 3:1 chance 3:1 to use dynamic substantive
+	/* 3:1 chance 3:1 to use dynamic substantive */
 	stem = SeedModChance(9,
 		lengthof(name_czech_subst_full) + 3 * lengthof(name_czech_subst_stem),
 		seed);
 	if (stem < lengthof(name_czech_subst_full)) {
-		// That was easy!
+		/* That was easy! */
 		dynamic_subst = false;
 		gender = name_czech_subst_full[stem].gender;
 		choose = name_czech_subst_full[stem].choose;
@@ -404,7 +406,7 @@
 		int ending_start = -1, ending_stop = -1;
 		int i;
 
-		// Load the substantive
+		/* Load the substantive */
 		dynamic_subst = true;
 		stem -= lengthof(name_czech_subst_full);
 		stem %= lengthof(name_czech_subst_stem);
@@ -412,15 +414,15 @@
 		choose = name_czech_subst_stem[stem].choose;
 		allow = name_czech_subst_stem[stem].allow;
 
-		// Load the postfix (1:1 chance that a postfix will be inserted)
+		/* Load the postfix (1:1 chance that a postfix will be inserted) */
 		postfix = SeedModChance(14, lengthof(name_czech_subst_postfix) * 2, seed);
 
 		if (choose & CZC_POSTFIX) {
-			// Always get a real postfix.
+			/* Always get a real postfix. */
 			postfix %= lengthof(name_czech_subst_postfix);
 		}
 		if (choose & CZC_NOPOSTFIX) {
-			// Always drop a postfix.
+			/* Always drop a postfix. */
 			postfix += lengthof(name_czech_subst_postfix);
 		}
 		if (postfix < lengthof(name_czech_subst_postfix)) {
@@ -429,7 +431,7 @@
 			choose |= CZC_NOPOSTFIX;
 		}
 
-		// Localize the array segment containing a good gender
+		/* Localize the array segment containing a good gender */
 		for (ending = 0; ending < (int) lengthof(name_czech_subst_ending); ending++) {
 			const CzechNameSubst *e = &name_czech_subst_ending[ending];
 
@@ -445,11 +447,11 @@
 			}
 		}
 		if (ending_stop < 0) {
-			// Whoa. All the endings matched.
+			/* Whoa. All the endings matched. */
 			ending_stop = ending - 1;
 		}
 
-		// Make a sequential map of the items with good mask
+		/* Make a sequential map of the items with good mask */
 		i = 0;
 		for (ending = ending_start; ending <= ending_stop; ending++) {
 			const CzechNameSubst *e = &name_czech_subst_ending[ending];
@@ -459,20 +461,20 @@
 		}
 		assert(i > 0);
 
-		// Load the ending
+		/* Load the ending */
 		ending = map[SeedModChance(16, i, seed)];
-		// Override possible CZG_*FREE; this must be a real gender,
-		// otherwise we get overflow when modifying the adjectivum.
+		/* Override possible CZG_*FREE; this must be a real gender,
+		 * otherwise we get overflow when modifying the adjectivum. */
 		gender = name_czech_subst_ending[ending].gender;
 		assert(gender != CZG_FREE && gender != CZG_NFREE);
 	}
 
 	if (do_prefix && (name_czech_adj[prefix].choose & choose) != choose) {
-		// Throw away non-matching prefix.
+		/* Throw away non-matching prefix. */
 		do_prefix = false;
 	}
 
-	// Now finally construct the name
+	/* Now finally construct the name */
 
 	if (do_prefix) {
 		CzechPattern pattern = name_czech_adj[prefix].pattern;
@@ -505,7 +507,7 @@
 			endlen = strlen(endstr);
 			assert(postlen > 0 && endlen > 0);
 
-			// Kill the "avava" and "Jananna"-like cases
+			/* Kill the "avava" and "Jananna"-like cases */
 			if (postlen < 2 || postlen > endlen || (
 						(poststr[1] != 'v' || poststr[1] != endstr[1]) &&
 						poststr[2] != endstr[1])
@@ -514,7 +516,7 @@
 				strecat(buf, poststr, last);
 				buflen = strlen(buf);
 
-				// k-i -> c-i, h-i -> z-i
+				/* k-i -> c-i, h-i -> z-i */
 				if (endstr[0] == 'i') {
 					switch (buf[buflen - 1]) {
 						case 'k': buf[buflen - 1] = 'c'; break;
@@ -553,15 +555,15 @@
 {
 	strecpy(buf, "", last);
 
-	// Use first 4 bit from seed to decide whether or not this town should
-	// have a real name 3/16 chance.  Bit 0-3
+	/* Use first 4 bit from seed to decide whether or not this town should
+	 * have a real name 3/16 chance.  Bit 0-3 */
 	if (SeedChance(0, 15, seed) < 3) {
-		// Use 7bit for the realname table index.  Bit 4-10
+		/* Use 7bit for the realname table index.  Bit 4-10 */
 		strecat(buf, name_norwegian_real[SeedChance(4, lengthof(name_norwegian_real), seed)], last);
 	} else {
-		// Use 7bit for the first fake part.  Bit 4-10
+		/* Use 7bit for the first fake part.  Bit 4-10 */
 		strecat(buf, name_norwegian_1[SeedChance(4, lengthof(name_norwegian_1), seed)], last);
-		// Use 7bit for the last fake part.  Bit 11-17
+		/* Use 7bit for the last fake part.  Bit 11-17 */
 		strecat(buf, name_norwegian_2[SeedChance(11, lengthof(name_norwegian_2), seed)], last);
 	}
 
@@ -572,22 +574,22 @@
 {
 	uint i;
 
-	//null terminates the string for strcat
+	/* null terminates the string for strcat */
 	strecpy(buf, "", last);
 
 	if (SeedChance(12, 15, seed) < 3) {
 		strecat(buf, name_hungarian_real[SeedChance(0, lengthof(name_hungarian_real), seed)], last);
 	} else {
-		// optional first segment
+		/* optional first segment */
 		i = SeedChance(3, lengthof(name_hungarian_1) * 3, seed);
 		if (i < lengthof(name_hungarian_1))
 			strecat(buf, name_hungarian_1[i], last);
 
-		// mandatory middle segments
+		/* mandatory middle segments */
 		strecat(buf, name_hungarian_2[SeedChance(3, lengthof(name_hungarian_2), seed)], last);
 		strecat(buf, name_hungarian_3[SeedChance(6, lengthof(name_hungarian_3), seed)], last);
 
-		// optional last segment
+		/* optional last segment */
 		i = SeedChance(10, lengthof(name_hungarian_4) * 3, seed);
 		if (i < lengthof(name_hungarian_4)) {
 			strecat(buf, name_hungarian_4[i], last);
@@ -607,15 +609,15 @@
 {
 	int i;
 
-	// null terminates the string for strcat
+	/* null terminates the string for strcat */
 	strecpy(buf, "", last);
 
-	// optional first segment
+	/* optional first segment */
 	i = SeedChanceBias(0, lengthof(name_danish_1), seed, 50);
 	if (i >= 0)
 		strecat(buf, name_danish_1[i], last);
 
-	// middle segments removed as this algorithm seems to create much more realistic names
+	/* middle segments removed as this algorithm seems to create much more realistic names */
 	strecat(buf, name_danish_2[SeedChance( 7, lengthof(name_danish_2), seed)], last);
 	strecat(buf, name_danish_3[SeedChance(16, lengthof(name_danish_3), seed)], last);
 
@@ -626,16 +628,16 @@
 {
 	uint i;
 
-	// null terminates the string for strcat
+	/* null terminates the string for strcat */
 	strecpy(buf, "", last);
 
 	if ((i = SeedModChance(0, 5, seed)) == 0) {
 		strecat(buf, name_turkish_prefix[SeedModChance( 2, lengthof(name_turkish_prefix), seed)], last);
 
-		// middle segment
+		/* middle segment */
 		strecat(buf, name_turkish_middle[SeedModChance( 4, lengthof(name_turkish_middle), seed)], last);
 
-		// optional suffix
+		/* optional suffix */
 		if (SeedModChance(0, 7, seed) == 0) {
 			strecat(buf, name_turkish_suffix[SeedModChance( 10, lengthof(name_turkish_suffix), seed)], last);
 		}
@@ -757,30 +759,30 @@
 	MakeCatalanTownName,
 };
 
-// DO WE NEED THIS ANY MORE?
+/* DO WE NEED THIS ANY MORE? */
 #define FIXNUM(x, y, z) (((((x) << 16) / (y)) + 1) << z)
 
 uint32 GetOldTownName(uint32 townnameparts, byte old_town_name_type)
 {
 	switch (old_town_name_type) {
-		case 0: case 3: /* English, American */
+		case 0: case 3: // English, American
 			/* Already OK */
 			return townnameparts;
 
-		case 1: /* French */
+		case 1: // French
 			/* For some reason 86 needs to be subtracted from townnameparts
 			 * 0000 0000 0000 0000 0000 0000 1111 1111 */
 			return FIXNUM(townnameparts - 86, lengthof(name_french_real), 0);
 
-		case 2: /* German */
+		case 2: // German
 			DEBUG(misc, 0, "German Townnames are buggy (%d)", townnameparts);
 			return townnameparts;
 
-		case 4: /* Latin-American */
+		case 4: // Latin-American
 			/* 0000 0000 0000 0000 0000 0000 1111 1111 */
 			return FIXNUM(townnameparts, lengthof(name_spanish_real), 0);
 
-		case 5: /* Silly */
+		case 5: // Silly
 			/* NUM_SILLY_1 - lower 16 bits
 			 * NUM_SILLY_2 - upper 16 bits without leading 1 (first 8 bytes)
 			 * 1000 0000 2222 2222 0000 0000 1111 1111 */
--- a/src/namegen.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/namegen.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file namegen.h */
+
 #ifndef NAMEGEN_H
 #define NAMEGEN_H
 
--- a/src/network/network.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/network/network.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -659,7 +659,7 @@
 
 	if (_network_server) {
 		// We just lost one client :(
-		if (cs->status > STATUS_INACTIVE) _network_game_info.clients_on--;
+		if (cs->status >= STATUS_AUTH) _network_game_info.clients_on--;
 		_network_clients_connected--;
 
 		while ((cs + 1) != DEREF_CLIENT(MAX_CLIENTS) && (cs + 1)->sock != INVALID_SOCKET) {
--- a/src/newgrf.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file newgrf.cpp */
+
 #include "stdafx.h"
 
 #include <stdarg.h>
@@ -27,6 +29,7 @@
 #include "fontcache.h"
 #include "date.h"
 #include "currency.h"
+#include "landscape.h"
 #include "sound.h"
 #include "newgrf_config.h"
 #include "newgrf_house.h"
@@ -74,10 +77,6 @@
 /* Set if there are any newhouses loaded. */
 bool _have_newhouses = false;
 
-/* Default cargo translation table. By default there are 27 possible cargo types */
-static const uint _default_cargo_max = 27;
-static CargoLabel _default_cargo_list[_default_cargo_max];
-
 
 enum GrfDataType {
 	GDT_SOUND,
@@ -238,16 +237,20 @@
  * @param str StringID that we want to have the equivalent in OoenTTD
  * @return the properly adjusted StringID
  */
-static StringID MapGRFStringID(StringID str)
+static StringID MapGRFStringID(uint32 grfid, StringID str)
 {
 	/* 0xD0 and 0xDC stand for all the TextIDs in the range
-	*  of 0xD000 (misc graphics texts) and 0xDC00 (misc persistent texts).
+	 * of 0xD000 (misc graphics texts) and 0xDC00 (misc persistent texts).
 	 * These strings are unique to each grf file, and thus require to be used with the
 	 * grfid in which they are declared */
 	if (GB(str, 8, 8) == 0xD0 || GB(str, 8, 8) == 0xDC) {
-		return GetGRFStringID(_cur_grffile->grfid, str);
+		return GetGRFStringID(grfid, str);
 	}
 
+	/* We have some changes in our cargo strings, resulting in some missing. */
+	if (str >= 0x006E && str <= 0x008D) return str - 0x20;
+	if (str >= 0x008E && str <= 0x00AD) return str - 0x20;
+
 	/* Map building names according to our lang file changes
 	 * 0x200F = Tall Office Block, first house name in the original data, the one that TTDPatch stil uses
 	 * 0x201F = Old houses is the last house name.
@@ -287,7 +290,7 @@
 	bool ret = false;
 
 	switch (prop) {
-		case 0x05: /* Track type */
+		case 0x05: // Track type
 			FOR_EACH_OBJECT {
 				uint8 tracktype = grf_load_byte(&buf);
 
@@ -302,13 +305,13 @@
 			}
 			break;
 
-		case 0x08: /* AI passenger service */
-			/* TODO */
+		case 0x08: // AI passenger service
+			/* @todo missing feature */
 			FOR_EACH_OBJECT grf_load_byte(&buf);
 			ret = true;
 			break;
 
-		case 0x09: /* Speed (1 unit is 1 kmh) */
+		case 0x09: // Speed (1 unit is 1 kmh)
 			FOR_EACH_OBJECT {
 				uint16 speed = grf_load_word(&buf);
 				if (speed == 0xFFFF) speed = 0;
@@ -317,7 +320,7 @@
 			}
 			break;
 
-		case 0x0B: /* Power */
+		case 0x0B: // Power
 			FOR_EACH_OBJECT {
 				uint16 power = grf_load_word(&buf);
 
@@ -328,7 +331,7 @@
 			}
 			break;
 
-		case 0x0D: /* Running cost factor */
+		case 0x0D: // Running cost factor
 			FOR_EACH_OBJECT {
 				uint8 runcostfact = grf_load_byte(&buf);
 
@@ -338,7 +341,7 @@
 			}
 			break;
 
-		case 0x0E: /* Running cost base */
+		case 0x0E: // Running cost base
 			FOR_EACH_OBJECT {
 				uint32 base = grf_load_dword(&buf);
 
@@ -346,7 +349,7 @@
 					case 0x4C30: rvi[i].running_cost_class = 0; break;
 					case 0x4C36: rvi[i].running_cost_class = 1; break;
 					case 0x4C3C: rvi[i].running_cost_class = 2; break;
-					case 0: break; /* Used by wagons */
+					case 0: break; // Used by wagons
 					default:
 						grfmsg(1, "RailVehicleChangeInfo: Unsupported running cost base 0x%04X, ignoring", base);
 						break;
@@ -354,7 +357,7 @@
 			}
 			break;
 
-		case 0x12: /* Sprite ID */
+		case 0x12: // Sprite ID
 			FOR_EACH_OBJECT {
 				uint8 spriteid = grf_load_byte(&buf);
 
@@ -366,7 +369,7 @@
 			}
 			break;
 
-		case 0x13: /* Dual-headed */
+		case 0x13: // Dual-headed
 			FOR_EACH_OBJECT {
 				uint8 dual = grf_load_byte(&buf);
 
@@ -389,11 +392,11 @@
 			}
 			break;
 
-		case 0x14: /* Cargo capacity */
+		case 0x14: // Cargo capacity
 			FOR_EACH_OBJECT rvi[i].capacity = grf_load_byte(&buf);
 			break;
 
-		case 0x15: /* Cargo type */
+		case 0x15: // Cargo type
 			FOR_EACH_OBJECT {
 				uint8 ctype = grf_load_byte(&buf);
 
@@ -406,19 +409,19 @@
 			}
 			break;
 
-		case 0x16: /* Weight */
+		case 0x16: // Weight
 			FOR_EACH_OBJECT SB(rvi[i].weight, 0, 8, grf_load_byte(&buf));
 			break;
 
-		case 0x17: /* Cost factor */
+		case 0x17: // Cost factor
 			FOR_EACH_OBJECT rvi[i].base_cost = grf_load_byte(&buf);
 			break;
 
-		case 0x18: /* AI rank */
+		case 0x18: // AI rank
 			FOR_EACH_OBJECT rvi[i].ai_rank = grf_load_byte(&buf);
 			break;
 
-		case 0x19: /* Engine traction type */
+		case 0x19: // Engine traction type
 			/* What do the individual numbers mean?
 			 * 0x00 .. 0x07: Steam
 			 * 0x08 .. 0x27: Diesel
@@ -448,7 +451,7 @@
 			}
 			break;
 
-		case 0x1A: /* Alter purchase list sort order */
+		case 0x1A: // Alter purchase list sort order
 			FOR_EACH_OBJECT {
 				EngineID pos = grf_load_byte(&buf);
 
@@ -460,40 +463,40 @@
 			}
 			break;
 
-		case 0x1B: /* Powered wagons power bonus */
+		case 0x1B: // Powered wagons power bonus
 			FOR_EACH_OBJECT rvi[i].pow_wag_power = grf_load_word(&buf);
 			break;
 
-		case 0x1C: /* Refit cost */
+		case 0x1C: // Refit cost
 			FOR_EACH_OBJECT ei[i].refit_cost = grf_load_byte(&buf);
 			break;
 
-		case 0x1D: /* Refit cargo */
+		case 0x1D: // Refit cargo
 			FOR_EACH_OBJECT ei[i].refit_mask = grf_load_dword(&buf);
 			break;
 
-		case 0x1E: /* Callback */
+		case 0x1E: // Callback
 			FOR_EACH_OBJECT ei[i].callbackmask = grf_load_byte(&buf);
 			break;
 
-		case 0x1F: /* Tractive effort coefficient */
+		case 0x1F: // Tractive effort coefficient
 			FOR_EACH_OBJECT rvi[i].tractive_effort = grf_load_byte(&buf);
 			break;
 
-		case 0x21: /* Shorter vehicle */
+		case 0x21: // Shorter vehicle
 			FOR_EACH_OBJECT rvi[i].shorten_factor = grf_load_byte(&buf);
 			break;
 
-		case 0x22: /* Visual effect */
-			// see note in engine.h about rvi->visual_effect
+		case 0x22: // Visual effect
+			/* see note in engine.h about rvi->visual_effect */
 			FOR_EACH_OBJECT rvi[i].visual_effect = grf_load_byte(&buf);
 			break;
 
-		case 0x23: /* Powered wagons weight bonus */
+		case 0x23: // Powered wagons weight bonus
 			FOR_EACH_OBJECT rvi[i].pow_wag_weight = grf_load_byte(&buf);
 			break;
 
-		case 0x24: /* High byte of vehicle weight */
+		case 0x24: // High byte of vehicle weight
 			FOR_EACH_OBJECT {
 				byte weight = grf_load_byte(&buf);
 
@@ -505,34 +508,33 @@
 			}
 			break;
 
-		case 0x25: /* User-defined bit mask to set when checking veh. var. 42 */
+		case 0x25: // User-defined bit mask to set when checking veh. var. 42
 			FOR_EACH_OBJECT rvi[i].user_def_data = grf_load_byte(&buf);
 			break;
 
-		case 0x27: /* Miscellaneous flags */
+		case 0x27: // Miscellaneous flags
 			FOR_EACH_OBJECT {
 				ei[i].misc_flags = grf_load_byte(&buf);
 				if (HASBIT(ei[i].misc_flags, EF_USES_2CC)) _have_2cc = true;
 			}
 			break;
 
-		case 0x28: /* Cargo classes allowed */
+		case 0x28: // Cargo classes allowed
 			FOR_EACH_OBJECT cargo_allowed[engine + i] = grf_load_word(&buf);
 			break;
 
-		case 0x29: /* Cargo classes disallowed */
+		case 0x29: // Cargo classes disallowed
 			FOR_EACH_OBJECT cargo_disallowed[engine + i] = grf_load_word(&buf);
 			break;
 
-		case 0x2A: /* Long format introduction date (days since year 0) */
+		case 0x2A: // Long format introduction date (days since year 0)
 			FOR_EACH_OBJECT ei[i].base_intro = grf_load_dword(&buf);
 			break;
 
-		/* TODO */
-		/* Fall-through for unimplemented one byte long properties. */
-		case 0x20: /* Air drag */
-		case 0x26: /* Retire vehicle early */
-			/* TODO */
+		/* @todo air drag and retire vehicle early
+		 * Fall-through for unimplemented one byte long properties. */
+		case 0x20: // Air drag
+		case 0x26: // Retire vehicle early
 			FOR_EACH_OBJECT grf_load_byte(&buf);
 			ret = true;
 			break;
@@ -554,25 +556,26 @@
 	bool ret = false;
 
 	switch (prop) {
-		case 0x08: /* Speed (1 unit is 0.5 kmh) */
+		case 0x08: // Speed (1 unit is 0.5 kmh)
 			FOR_EACH_OBJECT rvi[i].max_speed = grf_load_byte(&buf);
 			break;
 
-		case 0x09: /* Running cost factor */
+		case 0x09: // Running cost factor
 			FOR_EACH_OBJECT rvi[i].running_cost = grf_load_byte(&buf);
 			break;
 
-		case 0x0A: /* Running cost base */
-			/* TODO: I have no idea. --pasky */
+		case 0x0A: // Running cost base
+			/* @todo : I have no idea. --pasky
+			 * I THINK it is used for overriding the base cost of all road vehicle (_price.roadveh_base) --belugas */
 			FOR_EACH_OBJECT grf_load_dword(&buf);
 			ret = true;
 			break;
 
-		case 0x0E: /* Sprite ID */
+		case 0x0E: // Sprite ID
 			FOR_EACH_OBJECT {
 				uint8 spriteid = grf_load_byte(&buf);
 
-				// cars have different custom id in the GRF file
+				/* cars have different custom id in the GRF file */
 				if (spriteid == 0xFF) spriteid = 0xFD;
 
 				if (spriteid < 0xFD) spriteid >>= 1;
@@ -581,11 +584,11 @@
 			}
 			break;
 
-		case 0x0F: /* Cargo capacity */
+		case 0x0F: // Cargo capacity
 			FOR_EACH_OBJECT rvi[i].capacity = grf_load_byte(&buf);
 			break;
 
-		case 0x10: /* Cargo type */
+		case 0x10: // Cargo type
 			FOR_EACH_OBJECT {
 				uint8 cargo = grf_load_byte(&buf);
 
@@ -598,17 +601,17 @@
 			}
 			break;
 
-		case 0x11: /* Cost factor */
+		case 0x11: // Cost factor
 			FOR_EACH_OBJECT rvi[i].base_cost = grf_load_byte(&buf); // ?? is it base_cost?
 			break;
 
-		case 0x12: /* SFX */
+		case 0x12: // SFX
 			FOR_EACH_OBJECT rvi[i].sfx = (SoundFx)grf_load_byte(&buf);
 			break;
 
-		case 0x13: /* Power in 10hp */
-		case 0x14: /* Weight in 1/4 tons */
-		case 0x15: /* Speed in mph*0.8 */
+		case 0x13: // Power in 10hp
+		case 0x14: // Weight in 1/4 tons
+		case 0x15: // Speed in mph*0.8
 			/* TODO: Support for road vehicles realistic power
 			 * computations (called rvpower in TTDPatch) is just
 			 * missing in OTTD yet. --pasky */
@@ -616,41 +619,41 @@
 			ret = true;
 			break;
 
-		case 0x16: /* Cargos available for refitting */
+		case 0x16: // Cargos available for refitting
 			FOR_EACH_OBJECT ei[i].refit_mask = grf_load_dword(&buf);
 			break;
 
-		case 0x17: /* Callback mask */
+		case 0x17: // Callback mask
 			FOR_EACH_OBJECT ei[i].callbackmask = grf_load_byte(&buf);
 			break;
 
-		case 0x1A: /* Refit cost */
+		case 0x1A: // Refit cost
 			FOR_EACH_OBJECT ei[i].refit_cost = grf_load_byte(&buf);
 			break;
 
-		case 0x1C: /* Miscellaneous flags */
+		case 0x1C: // Miscellaneous flags
 			FOR_EACH_OBJECT {
 				ei[i].misc_flags = grf_load_byte(&buf);
 				if (HASBIT(ei[i].misc_flags, EF_USES_2CC)) _have_2cc = true;
 			}
 			break;
 
-		case 0x1D: /* Cargo classes allowed */
+		case 0x1D: // Cargo classes allowed
 			FOR_EACH_OBJECT cargo_allowed[ROAD_ENGINES_INDEX + engine + i] = grf_load_word(&buf);
 			break;
 
-		case 0x1E: /* Cargo classes disallowed */
+		case 0x1E: // Cargo classes disallowed
 			FOR_EACH_OBJECT cargo_disallowed[ROAD_ENGINES_INDEX + engine + i] = grf_load_word(&buf);
 			break;
 
-		case 0x1F: /* Long format introduction date (days since year 0) */
+		case 0x1F: // Long format introduction date (days since year 0)
 			FOR_EACH_OBJECT ei[i].base_intro = grf_load_dword(&buf);
 			break;
 
-		case 0x18: /* Tractive effort */
-		case 0x19: /* Air drag */
-		case 0x1B: /* Retire vehicle early */
-			/* TODO */
+		case 0x18: // Tractive effort
+		case 0x19: // Air drag
+		case 0x1B: // Retire vehicle early
+			/* @todo */
 			FOR_EACH_OBJECT grf_load_byte(&buf);
 			ret = true;
 			break;
@@ -674,11 +677,11 @@
 
 	//printf("e %x prop %x?\n", engine, prop);
 	switch (prop) {
-		case 0x08: /* Sprite ID */
+		case 0x08: // Sprite ID
 			FOR_EACH_OBJECT {
 				uint8 spriteid = grf_load_byte(&buf);
 
-				// ships have different custom id in the GRF file
+				/* ships have different custom id in the GRF file */
 				if (spriteid == 0xFF) spriteid = 0xFD;
 
 				if (spriteid < 0xFD) spriteid >>= 1;
@@ -687,19 +690,19 @@
 			}
 			break;
 
-		case 0x09: /* Refittable */
+		case 0x09: // Refittable
 			FOR_EACH_OBJECT svi[i].refittable = (grf_load_byte(&buf) != 0);
 			break;
 
-		case 0x0A: /* Cost factor */
+		case 0x0A: // Cost factor
 			FOR_EACH_OBJECT svi[i].base_cost = grf_load_byte(&buf); // ?? is it base_cost?
 			break;
 
-		case 0x0B: /* Speed (1 unit is 0.5 kmh) */
+		case 0x0B: // Speed (1 unit is 0.5 kmh)
 			FOR_EACH_OBJECT svi[i].max_speed = grf_load_byte(&buf);
 			break;
 
-		case 0x0C: /* Cargo type */
+		case 0x0C: // Cargo type
 			FOR_EACH_OBJECT {
 				uint8 cargo = grf_load_byte(&buf);
 
@@ -712,53 +715,53 @@
 			}
 			break;
 
-		case 0x0D: /* Cargo capacity */
+		case 0x0D: // Cargo capacity
 			FOR_EACH_OBJECT svi[i].capacity = grf_load_word(&buf);
 			break;
 
-		case 0x0F: /* Running cost factor */
+		case 0x0F: // Running cost factor
 			FOR_EACH_OBJECT svi[i].running_cost = grf_load_byte(&buf);
 			break;
 
-		case 0x10: /* SFX */
+		case 0x10: // SFX
 			FOR_EACH_OBJECT svi[i].sfx = (SoundFx)grf_load_byte(&buf);
 			break;
 
-		case 0x11: /* Cargos available for refitting */
+		case 0x11: // Cargos available for refitting
 			FOR_EACH_OBJECT ei[i].refit_mask = grf_load_dword(&buf);
 			break;
 
-		case 0x12: /* Callback mask */
+		case 0x12: // Callback mask
 			FOR_EACH_OBJECT ei[i].callbackmask = grf_load_byte(&buf);
 			break;
 
-		case 0x13: /* Refit cost */
+		case 0x13: // Refit cost
 			FOR_EACH_OBJECT ei[i].refit_cost = grf_load_byte(&buf);
 			break;
 
-		case 0x17: /* Miscellaneous flags */
+		case 0x17: // Miscellaneous flags
 			FOR_EACH_OBJECT {
 				ei[i].misc_flags = grf_load_byte(&buf);
 				if (HASBIT(ei[i].misc_flags, EF_USES_2CC)) _have_2cc = true;
 			}
 			break;
 
-		case 0x18: /* Cargo classes allowed */
+		case 0x18: // Cargo classes allowed
 			FOR_EACH_OBJECT cargo_allowed[SHIP_ENGINES_INDEX + engine + i] = grf_load_word(&buf);
 			break;
 
-		case 0x19: /* Cargo classes disallowed */
+		case 0x19: // Cargo classes disallowed
 			FOR_EACH_OBJECT cargo_disallowed[SHIP_ENGINES_INDEX + engine + i] = grf_load_word(&buf);
 			break;
 
-		case 0x1A: /* Long format introduction date (days since year 0) */
+		case 0x1A: // Long format introduction date (days since year 0)
 			FOR_EACH_OBJECT ei[i].base_intro = grf_load_dword(&buf);
 			break;
 
-		case 0x14: /* Ocean speed fraction */
-		case 0x15: /* Canal speed fraction */
-		case 0x16: /* Retire vehicle early */
-			/* TODO */
+		case 0x14: // Ocean speed fraction
+		case 0x15: // Canal speed fraction
+		case 0x16: // Retire vehicle early
+			/* @todo */
 			FOR_EACH_OBJECT grf_load_byte(&buf);
 			ret = true;
 			break;
@@ -782,11 +785,11 @@
 
 	//printf("e %x prop %x?\n", engine, prop);
 	switch (prop) {
-		case 0x08: /* Sprite ID */
+		case 0x08: // Sprite ID
 			FOR_EACH_OBJECT {
 				uint8 spriteid = grf_load_byte(&buf);
 
-				// aircraft have different custom id in the GRF file
+				/* aircraft have different custom id in the GRF file */
 				if (spriteid == 0xFF) spriteid = 0xFD;
 
 				if (spriteid < 0xFD) spriteid >>= 1;
@@ -795,7 +798,7 @@
 			}
 			break;
 
-		case 0x09: /* Helicopter */
+		case 0x09: // Helicopter
 			FOR_EACH_OBJECT {
 				if (grf_load_byte(&buf) == 0) {
 					avi[i].subtype = AIR_HELI;
@@ -805,71 +808,71 @@
 			}
 			break;
 
-		case 0x0A: /* Large */
+		case 0x0A: // Large
 			FOR_EACH_OBJECT SB(avi[i].subtype, 1, 1, (grf_load_byte(&buf) != 0 ? 1 : 0)); // AIR_FAST
 			break;
 
-		case 0x0B: /* Cost factor */
+		case 0x0B: // Cost factor
 			FOR_EACH_OBJECT avi[i].base_cost = grf_load_byte(&buf); // ?? is it base_cost?
 			break;
 
-		case 0x0C: /* Speed (1 unit is 8 mph, we translate to 1 unit is 1 km/h) */
+		case 0x0C: // Speed (1 unit is 8 mph, we translate to 1 unit is 1 km/h)
 			FOR_EACH_OBJECT avi[i].max_speed = (grf_load_byte(&buf) * 129) / 10;
 			break;
 
-		case 0x0D: /* Acceleration */
+		case 0x0D: // Acceleration
 			FOR_EACH_OBJECT avi[i].acceleration = (grf_load_byte(&buf) * 129) / 10;
 			break;
 
-		case 0x0E: /* Running cost factor */
+		case 0x0E: // Running cost factor
 			FOR_EACH_OBJECT avi[i].running_cost = grf_load_byte(&buf);
 			break;
 
-		case 0x0F: /* Passenger capacity */
+		case 0x0F: // Passenger capacity
 			FOR_EACH_OBJECT avi[i].passenger_capacity = grf_load_word(&buf);
 			break;
 
-		case 0x11: /* Mail capacity */
+		case 0x11: // Mail capacity
 			FOR_EACH_OBJECT avi[i].mail_capacity = grf_load_byte(&buf);
 			break;
 
-		case 0x12: /* SFX */
+		case 0x12: // SFX
 			FOR_EACH_OBJECT avi[i].sfx = (SoundFx)grf_load_byte(&buf);
 			break;
 
-		case 0x13: /* Cargos available for refitting */
+		case 0x13: // Cargos available for refitting
 			FOR_EACH_OBJECT ei[i].refit_mask = grf_load_dword(&buf);
 			break;
 
-		case 0x14: /* Callback mask */
+		case 0x14: // Callback mask
 			FOR_EACH_OBJECT ei[i].callbackmask = grf_load_byte(&buf);
 			break;
 
-		case 0x15: /* Refit cost */
+		case 0x15: // Refit cost
 			FOR_EACH_OBJECT ei[i].refit_cost = grf_load_byte(&buf);
 			break;
 
-		case 0x17: /* Miscellaneous flags */
+		case 0x17: // Miscellaneous flags
 			FOR_EACH_OBJECT {
 				ei[i].misc_flags = grf_load_byte(&buf);
 				if (HASBIT(ei[i].misc_flags, EF_USES_2CC)) _have_2cc = true;
 			}
 			break;
 
-		case 0x18: /* Cargo classes allowed */
+		case 0x18: // Cargo classes allowed
 			FOR_EACH_OBJECT cargo_allowed[AIRCRAFT_ENGINES_INDEX + engine + i] = grf_load_word(&buf);
 			break;
 
-		case 0x19: /* Cargo classes disallowed */
+		case 0x19: // Cargo classes disallowed
 			FOR_EACH_OBJECT cargo_disallowed[AIRCRAFT_ENGINES_INDEX + engine + i] = grf_load_word(&buf);
 			break;
 
-		case 0x1A: /* Long format introduction date (days since year 0) */
+		case 0x1A: // Long format introduction date (days since year 0)
 			FOR_EACH_OBJECT ei[i].base_intro = grf_load_dword(&buf);
 			break;
 
-		case 0x16: /* Retire vehicle early */
-			/* TODO */
+		case 0x16: // Retire vehicle early
+			/* @todo */
 			FOR_EACH_OBJECT grf_load_byte(&buf);
 			ret = true;
 			break;
@@ -911,7 +914,7 @@
 	}
 
 	switch (prop) {
-		case 0x08: /* Class ID */
+		case 0x08: // Class ID
 			FOR_EACH_OBJECT {
 				/* Property 0x08 is special; it is where the station is allocated */
 				if (statspec[i] == NULL) statspec[i] = CallocT<StationSpec>(1);
@@ -922,7 +925,7 @@
 			}
 			break;
 
-		case 0x09: /* Define sprite layout */
+		case 0x09: // Define sprite layout
 			FOR_EACH_OBJECT {
 				StationSpec *statspec = _cur_grffile->stations[stid + i];
 
@@ -946,7 +949,7 @@
 					while (buf < *bufp + len) {
 						DrawTileSeqStruct *dtss;
 
-						// no relative bounding box support
+						/* no relative bounding box support */
 						dts->seq = ReallocT((DrawTileSeqStruct*)dts->seq, ++seq_count);
 						dtss = (DrawTileSeqStruct*) &dts->seq[seq_count - 1];
 
@@ -979,7 +982,7 @@
 			}
 			break;
 
-		case 0x0A: /* Copy sprite layout */
+		case 0x0A: // Copy sprite layout
 			FOR_EACH_OBJECT {
 				StationSpec *statspec = _cur_grffile->stations[stid + i];
 				byte srcid = grf_load_byte(&buf);
@@ -991,19 +994,19 @@
 			}
 			break;
 
-		case 0x0B: /* Callback mask */
+		case 0x0B: // Callback mask
 			FOR_EACH_OBJECT statspec[i]->callbackmask = grf_load_byte(&buf);
 			break;
 
-		case 0x0C: /* Disallowed number of platforms */
+		case 0x0C: // Disallowed number of platforms
 			FOR_EACH_OBJECT statspec[i]->disallowed_platforms = grf_load_byte(&buf);
 			break;
 
-		case 0x0D: /* Disallowed platform lengths */
+		case 0x0D: // Disallowed platform lengths
 			FOR_EACH_OBJECT statspec[i]->disallowed_lengths = grf_load_byte(&buf);
 			break;
 
-		case 0x0E: /* Define custom layout */
+		case 0x0E: // Define custom layout
 			FOR_EACH_OBJECT {
 				StationSpec *statspec = _cur_grffile->stations[stid + i];
 
@@ -1033,7 +1036,7 @@
 					//debug("p %d > %d ?", number, stat->platforms[l]);
 					if (number > statspec->platforms[l]) {
 						statspec->layouts[l] = ReallocT(statspec->layouts[l], number);
-						// We expect NULL being 0 here, but C99 guarantees that.
+						/* We expect NULL being 0 here, but C99 guarantees that. */
 						memset(statspec->layouts[l] + statspec->platforms[l], 0,
 						       (number - statspec->platforms[l]) * sizeof(**statspec->layouts));
 
@@ -1056,7 +1059,7 @@
 			}
 			break;
 
-		case 0x0F: /* Copy custom layout */
+		case 0x0F: // Copy custom layout
 			FOR_EACH_OBJECT {
 				StationSpec *statspec = _cur_grffile->stations[stid + i];
 				byte srcid = grf_load_byte(&buf);
@@ -1069,41 +1072,41 @@
 			}
 			break;
 
-		case 0x10: /* Little/lots cargo threshold */
+		case 0x10: // Little/lots cargo threshold
 			FOR_EACH_OBJECT statspec[i]->cargo_threshold = grf_load_word(&buf);
 			break;
 
-		case 0x11: /* Pylon placement */
+		case 0x11: // Pylon placement
 			FOR_EACH_OBJECT statspec[i]->pylons = grf_load_byte(&buf);
 			break;
 
-		case 0x12: /* Cargo types for random triggers */
+		case 0x12: // Cargo types for random triggers
 			FOR_EACH_OBJECT statspec[i]->cargo_triggers = grf_load_dword(&buf);
 			break;
 
-		case 0x13: /* General flags */
+		case 0x13: // General flags
 			FOR_EACH_OBJECT statspec[i]->flags = grf_load_byte(&buf);
 			break;
 
-		case 0x14: /* Overhead wire placement */
+		case 0x14: // Overhead wire placement
 			FOR_EACH_OBJECT statspec[i]->wires = grf_load_byte(&buf);
 			break;
 
-		case 0x15: /* Blocked tiles */
+		case 0x15: // Blocked tiles
 			FOR_EACH_OBJECT statspec[i]->blocked = grf_load_byte(&buf);
 			break;
 
-		case 0x16: /* TODO Animation info */
+		case 0x16: // @todo Animation info
 			FOR_EACH_OBJECT grf_load_word(&buf);
 			ret = true;
 			break;
 
-		case 0x17: /* TODO Animation speed */
+		case 0x17: // @todo Animation speed
 			FOR_EACH_OBJECT grf_load_byte(&buf);
 			ret = true;
 			break;
 
-		case 0x18: /* TODO Animation triggers */
+		case 0x18: // @todo Animation triggers
 			FOR_EACH_OBJECT grf_load_word(&buf);
 			ret = true;
 			break;
@@ -1124,27 +1127,27 @@
 	bool ret = false;
 
 	switch (prop) {
-		case 0x08: /* Year of availability */
+		case 0x08: // Year of availability
 			FOR_EACH_OBJECT _bridge[brid + i].avail_year = ORIGINAL_BASE_YEAR + grf_load_byte(&buf);
 			break;
 
-		case 0x09: /* Minimum length */
+		case 0x09: // Minimum length
 			FOR_EACH_OBJECT _bridge[brid + i].min_length = grf_load_byte(&buf);
 			break;
 
-		case 0x0A: /* Maximum length */
+		case 0x0A: // Maximum length
 			FOR_EACH_OBJECT _bridge[brid + i].max_length = grf_load_byte(&buf);
 			break;
 
-		case 0x0B: /* Cost factor */
+		case 0x0B: // Cost factor
 			FOR_EACH_OBJECT _bridge[brid + i].price = grf_load_byte(&buf);
 			break;
 
-		case 0x0C: /* Maximum speed */
+		case 0x0C: // Maximum speed
 			FOR_EACH_OBJECT _bridge[brid + i].speed = grf_load_word(&buf);
 			break;
 
-		case 0x0D: /* Bridge sprite tables */
+		case 0x0D: // Bridge sprite tables
 			FOR_EACH_OBJECT {
 				Bridge *bridge = &_bridge[brid + i];
 				byte tableid = grf_load_byte(&buf);
@@ -1184,11 +1187,11 @@
 			}
 			break;
 
-		case 0x0E: /* Flags; bit 0 - disable far pillars */
+		case 0x0E: // Flags; bit 0 - disable far pillars
 			FOR_EACH_OBJECT _bridge[brid + i].flags = grf_load_byte(&buf);
 			break;
 
-		case 0x0F: /* Long format year of availability (year since year 0) */
+		case 0x0F: // Long format year of availability (year since year 0)
 			FOR_EACH_OBJECT _bridge[brid + i].avail_year = clamp(grf_load_dword(&buf), MIN_YEAR, MAX_YEAR);
 			break;
 
@@ -1256,6 +1259,7 @@
 				housespec[i]->enabled = true;
 				housespec[i]->local_id = hid + i;
 				housespec[i]->substitute_id = subs_id;
+				housespec[i]->grffile = _cur_grffile;
 				housespec[i]->random_colour[0] = 0x04;  // those 4 random colours are the base colour
 				housespec[i]->random_colour[1] = 0x08;  // for all new houses
 				housespec[i]->random_colour[2] = 0x0C;  // they stand for red, blue, orange and green
@@ -1293,21 +1297,19 @@
 			break;
 
 		case 0x0D: // Passenger acceptance
-			FOR_EACH_OBJECT housespec[i]->passenger_acceptance = grf_load_byte(&buf);
-			break;
-
 		case 0x0E: // Mail acceptance
-			FOR_EACH_OBJECT housespec[i]->mail_acceptance = grf_load_byte(&buf);
+			FOR_EACH_OBJECT housespec[i]->cargo_acceptance[prop - 0x0D] = grf_load_byte(&buf);
 			break;
-
-		case 0x0F: // Goods, food or fizzy drinks acceptance
+		case 0x0F: // Goods/candy, food/fizzy drinks acceptance
 			FOR_EACH_OBJECT {
 				int8 goods = grf_load_byte(&buf);
-				if (goods > 0) {
-					housespec[i]->goods_acceptance = goods;
-				} else {
-					housespec[i]->food_acceptance = -goods;
-				}
+
+				/* If value of goods is negative, it means in fact food or, if in toyland, fizzy_drink acceptance.
+				 * Else, we have "standard" 3rd cargo type, goods or candy, for toyland once more */
+				housespec[i]->accepts_cargo[2] = (goods >= 0) ? ((_opt.landscape == LT_TOYLAND) ? CT_CANDY : CT_GOODS) :
+						((_opt.landscape == LT_TOYLAND) ? CT_FIZZY_DRINKS : CT_FOOD);
+
+				housespec[i]->cargo_acceptance[2] = abs(goods); // but we do need positive value here
 			}
 			break;
 
@@ -1320,7 +1322,7 @@
 			break;
 
 		case 0x12: // Building name ID
-			FOR_EACH_OBJECT housespec[i]->building_name = MapGRFStringID(grf_load_word(&buf));
+			FOR_EACH_OBJECT housespec[i]->building_name = MapGRFStringID(_cur_grffile->grfid, grf_load_word(&buf));
 			break;
 
 		case 0x13: // Building availability mask
@@ -1511,6 +1513,22 @@
 			break;
 
 		case 0x10: // 12 * 32 * B Snow line height table
+			if (numinfo > 1 || IsSnowLineSet()) {
+				grfmsg(1, "GlobalVarChangeInfo: The snowline can only be set once (%d)", numinfo);
+			} else if (len < SNOW_LINE_MONTHS * SNOW_LINE_DAYS) {
+				grfmsg(1, "GlobalVarChangeInfo: Not enough entries set in the snowline table (%d)", len);
+			} else {
+				byte table[SNOW_LINE_MONTHS][SNOW_LINE_DAYS];
+
+				for (uint i = 0; i < SNOW_LINE_MONTHS; i++) {
+					for (uint j = 0; j < SNOW_LINE_DAYS; j++) {
+						table[i][j] = grf_load_byte(&buf);
+					}
+				}
+				SetSnowLine(table);
+			}
+			break;
+
 		default:
 			ret = true;
 	}
@@ -1519,6 +1537,129 @@
 	return ret;
 }
 
+static bool CargoChangeInfo(uint cid, int numinfo, int prop, byte **bufp, int len)
+{
+	if (cid + numinfo > NUM_CARGO) {
+		grfmsg(2, "CargoChangeInfo: Cargo type %d out of range (max %d)", cid + numinfo, NUM_CARGO - 1);
+		return false;
+	}
+
+	CargoSpec *cs = &_cargo[cid];
+	byte *buf = *bufp;
+	int i;
+	bool ret = false;
+
+	switch (prop) {
+		case 0x08: /* Bit number of cargo */
+			FOR_EACH_OBJECT {
+				cs[i].bitnum = grf_load_byte(&buf);
+				cs[i].grfid = _cur_grffile->grfid;
+				if (cs->IsValid()) {
+					SETBIT(_cargo_mask, cid + i);
+				} else {
+					CLRBIT(_cargo_mask, cid + i);
+				}
+			}
+			break;
+
+		case 0x09: /* String ID for cargo type name */
+			FOR_EACH_OBJECT cs[i].name = grf_load_word(&buf);
+			break;
+
+		case 0x0A: /* String for cargo name, plural */
+			FOR_EACH_OBJECT cs[i].name_plural = grf_load_word(&buf);
+			break;
+
+		case 0x0B:
+			/* String for units of cargo. This is different in OpenTTD to TTDPatch
+			 * (e.g. 10 tonnes of coal) */
+			FOR_EACH_OBJECT cs[i].units_volume = grf_load_word(&buf);
+			break;
+
+		case 0x0C: /* String for quantity of cargo (e.g. 10 tonnes of coal) */
+			FOR_EACH_OBJECT cs[i].quantifier = grf_load_word(&buf);
+			break;
+
+		case 0x0D: /* String for two letter cargo abbreviation */
+			FOR_EACH_OBJECT cs[i].abbrev = grf_load_word(&buf);
+			break;
+
+		case 0x0E: /* Sprite ID for cargo icon */
+			FOR_EACH_OBJECT cs[i].sprite = grf_load_word(&buf);
+			break;
+
+		case 0x0F: /* Weight of one unit of cargo */
+			FOR_EACH_OBJECT cs[i].weight = grf_load_byte(&buf);
+			break;
+
+		case 0x10: /* Used for payment calculation */
+			FOR_EACH_OBJECT cs[i].transit_days[0] = grf_load_byte(&buf);
+			break;
+
+		case 0x11: /* Used for payment calculation */
+			FOR_EACH_OBJECT cs[i].transit_days[1] = grf_load_byte(&buf);
+			break;
+
+		case 0x12: /* Base cargo price */
+			FOR_EACH_OBJECT cs[i].initial_payment = grf_load_dword(&buf);
+			break;
+
+		case 0x13: /* Colour for station rating bars */
+			FOR_EACH_OBJECT cs[i].rating_colour = grf_load_byte(&buf);
+			break;
+
+		case 0x14: /* Colour for cargo graph */
+			FOR_EACH_OBJECT cs[i].legend_colour = grf_load_byte(&buf);
+			break;
+
+		case 0x15: /* Freight status */
+			FOR_EACH_OBJECT cs[i].is_freight = grf_load_byte(&buf) != 0;
+			break;
+
+		case 0x16: /* Cargo classes */
+			FOR_EACH_OBJECT cs[i].classes = grf_load_word(&buf);
+			break;
+
+		case 0x17: /* Cargo label */
+			FOR_EACH_OBJECT {
+				cs[i].label = grf_load_dword(&buf);
+				cs[i].label = BSWAP32(cs[i].label);
+			}
+			break;
+
+		case 0x18: /* Town growth substitute type */
+			FOR_EACH_OBJECT {
+				uint8 substitute_type = grf_load_byte(&buf);
+				switch (substitute_type) {
+					case 0x00: cs[i].town_effect = TE_PASSENGERS; break;
+					case 0x02: cs[i].town_effect = TE_MAIL; break;
+					case 0x05: cs[i].town_effect = TE_GOODS; break;
+					case 0x09: cs[i].town_effect = TE_WATER; break;
+					case 0x0B: cs[i].town_effect = TE_FOOD; break;
+					default:
+						grfmsg(1, "CargoChangeInfo: Unknown town growth substitute value %d, setting to none.", substitute_type);
+					case 0xFF: cs[i].town_effect = TE_NONE; break;
+				}
+			}
+			break;
+
+		case 0x19: /* Town growth coefficient */
+			FOR_EACH_OBJECT cs[i].multipliertowngrowth = grf_load_word(&buf);
+			break;
+
+		case 0x1A: /* Bitmask of callbacks to use */
+			FOR_EACH_OBJECT cs[i].callback_mask = grf_load_byte(&buf);
+			break;
+
+		default:
+			ret = true;
+	}
+
+	*bufp = buf;
+	return ret;
+}
+
+
 static bool SoundEffectChangeInfo(uint sid, int numinfo, int prop, byte **bufp, int len)
 {
 	byte *buf = *bufp;
@@ -1531,7 +1672,7 @@
 	}
 
 	switch (prop) {
-		case 0x08: /* Relative volume */
+		case 0x08: // Relative volume
 			FOR_EACH_OBJECT {
 				uint sound = sid + i + _cur_grffile->sound_offset - GetNumOriginalSounds();
 
@@ -1543,7 +1684,7 @@
 			}
 			break;
 
-		case 0x09: /* Priority */
+		case 0x09: // Priority
 			FOR_EACH_OBJECT {
 				uint sound = sid + i + _cur_grffile->sound_offset - GetNumOriginalSounds();
 
@@ -1555,7 +1696,7 @@
 			}
 			break;
 
-		case 0x0A: /* Override old sound */
+		case 0x0A: // Override old sound
 			FOR_EACH_OBJECT {
 				uint sound = sid + i + _cur_grffile->sound_offset - GetNumOriginalSounds();
 				uint orig_sound = grf_load_byte(&buf);
@@ -1611,7 +1752,7 @@
 		/* GSF_GLOBALVAR */    GlobalVarChangeInfo,
 		/* GSF_INDUSTRYTILES */NULL,
 		/* GSF_INDUSTRIES */   NULL,
-		/* GSF_CARGOS */       NULL,
+		/* GSF_CARGOS */       NULL, /* Cargo is handled during reservation */
 		/* GSF_SOUNDFX */      SoundEffectChangeInfo,
 	};
 
@@ -1656,27 +1797,27 @@
 			case GSF_AIRCRAFT:
 				/* Common properties for vehicles */
 				switch (prop) {
-					case 0x00: /* Introduction date */
+					case 0x00: // Introduction date
 						FOR_EACH_OBJECT ei[i].base_intro = grf_load_word(&buf) + DAYS_TILL_ORIGINAL_BASE_YEAR;
 						break;
 
-					case 0x02: /* Decay speed */
+					case 0x02: // Decay speed
 						FOR_EACH_OBJECT SB(ei[i].unk2, 0, 7, grf_load_byte(&buf) & 0x7F);
 						break;
 
-					case 0x03: /* Vehicle life */
+					case 0x03: // Vehicle life
 						FOR_EACH_OBJECT ei[i].lifelength = grf_load_byte(&buf);
 						break;
 
-					case 0x04: /* Model life */
+					case 0x04: // Model life
 						FOR_EACH_OBJECT ei[i].base_life = grf_load_byte(&buf);
 						break;
 
-					case 0x06: /* Climates available */
+					case 0x06: // Climates available
 						FOR_EACH_OBJECT ei[i].climates = grf_load_byte(&buf);
 						break;
 
-					case 0x07: /* Loading speed */
+					case 0x07: // Loading speed
 						/* Hyronymus explained me what does
 						 * this mean and insists on having a
 						 * credit ;-). --pasky */
@@ -1753,7 +1894,7 @@
 		switch (feature) {
 			case GSF_GLOBALVAR:
 				switch (prop) {
-					case 0x09: /* Cargo Translation Table */
+					case 0x09: // Cargo Translation Table
 						if (index != 0) {
 							grfmsg(1, "InitChangeInfo: Cargo translation table must start at zero");
 							return;
@@ -1775,6 +1916,35 @@
 	}
 }
 
+/* Action 0x00 (GLS_RESERVE) */
+static void ReserveChangeInfo(byte *buf, int len)
+{
+	byte *bufend = buf + len;
+
+	if (len == 1) {
+		grfmsg(8, "Silently ignoring one-byte special sprite 0x00");
+		return;
+	}
+
+	if (!check_length(len, 6, "InitChangeInfo")) return;
+	buf++;
+	uint8 feature  = grf_load_byte(&buf);
+
+	if (feature != GSF_CARGOS) return;
+
+	uint8 numprops = grf_load_byte(&buf);
+	uint8 numinfo  = grf_load_byte(&buf);
+	uint8 index    = grf_load_byte(&buf);
+
+	while (numprops-- && buf < bufend) {
+		uint8 prop = grf_load_byte(&buf);
+
+		if (CargoChangeInfo(index, numinfo, prop, &buf, bufend - buf)) {
+			grfmsg(2, "FeatureChangeInfo: Ignoring property 0x%02X (not implemented)", prop);
+		}
+	}
+}
+
 #undef FOR_EACH_OBJECT
 
 /**
@@ -1788,8 +1958,8 @@
 
 	group->type = SGT_CALLBACK;
 
-	// Old style callback results have the highest byte 0xFF so signify it is a callback result
-	// New style ones only have the highest bit set (allows 15-bit results, instead of just 8)
+	/* Old style callback results have the highest byte 0xFF so signify it is a callback result
+	 * New style ones only have the highest bit set (allows 15-bit results, instead of just 8) */
 	if ((value >> 8) == 0xFF) {
 		value &= ~0xFF00;
 	} else {
@@ -1920,9 +2090,9 @@
 	uint8 type    = grf_load_byte(&buf);
 
 	if (setid >= _cur_grffile->spritegroups_count) {
-		// Allocate memory for new sprite group references.
+		/* Allocate memory for new sprite group references. */
 		_cur_grffile->spritegroups = ReallocT(_cur_grffile->spritegroups, setid + 1);
-		// Initialise new space to NULL
+		/* Initialise new space to NULL */
 		for (; _cur_grffile->spritegroups_count < (setid + 1); _cur_grffile->spritegroups_count++)
 			_cur_grffile->spritegroups[_cur_grffile->spritegroups_count] = NULL;
 	}
@@ -2047,6 +2217,7 @@
 				case GSF_SHIP:
 				case GSF_AIRCRAFT:
 				case GSF_STATION:
+				case GSF_CARGOS:
 				{
 					byte sprites     = _cur_grffile->spriteset_numents;
 					byte num_loaded  = type;
@@ -2180,14 +2351,35 @@
 	if (feature == GSF_STATION && ctype == 0xFE) return CT_DEFAULT_NA;
 	if (ctype == 0xFF) return CT_PURCHASE;
 
+	if (_cur_grffile->cargo_max == 0) {
+		/* No cargo table, so use bitnum values */
+		if (ctype >= 32) {
+			grfmsg(1, "FeatureMapSpriteGroup: Cargo bitnum %d out of range (max 31), skipping.", ctype);
+			return CT_INVALID;
+		}
+
+		for (CargoID c = 0; c < NUM_CARGO; c++) {
+			const CargoSpec *cs = GetCargo(c);
+			if (!cs->IsValid()) continue;
+
+			if (cs->bitnum == ctype) {
+				grfmsg(6, "FeatureMapSpriteGroup: Cargo bitnum %d mapped to cargo type %d.", ctype, c);
+				return c;
+			}
+		}
+
+		grfmsg(5, "FeatureMapSpriteGroup: Cargo bitnum %d not available in this climate, skipping.", ctype);
+		return CT_INVALID;
+	}
+
 	/* Check if the cargo type is out of bounds of the cargo translation table */
-	if (ctype >= (_cur_grffile->cargo_max == 0 ? _default_cargo_max : _cur_grffile->cargo_max)) {
-		grfmsg(1, "FeatureMapSpriteGroup: Cargo type %d out of range (max %d), skipping.", ctype, (_cur_grffile->cargo_max == 0 ? _default_cargo_max : _cur_grffile->cargo_max) - 1);
+	if (ctype >= _cur_grffile->cargo_max) {
+		grfmsg(1, "FeatureMapSpriteGroup: Cargo type %d out of range (max %d), skipping.", ctype, _cur_grffile->cargo_max - 1);
 		return CT_INVALID;
 	}
 
 	/* Look up the cargo label from the translation table */
-	CargoLabel cl = _cur_grffile->cargo_max == 0 ? _default_cargo_list[ctype] : _cur_grffile->cargo_list[ctype];
+	CargoLabel cl = _cur_grffile->cargo_list[ctype];
 	if (cl == 0) {
 		grfmsg(5, "FeatureMapSpriteGroup: Cargo type %d not available in this climate, skipping.", ctype);
 		return CT_INVALID;
@@ -2203,150 +2395,27 @@
 	return ctype;
 }
 
-/* Action 0x03 */
-static void FeatureMapSpriteGroup(byte *buf, int len)
+
+static void VehicleMapSpriteGroup(byte *buf, byte feature, uint8 idcount, uint8 cidcount, bool wagover)
 {
-	/* <03> <feature> <n-id> <ids>... <num-cid> [<cargo-type> <cid>]... <def-cid>
-	 * id-list    := [<id>] [id-list]
-	 * cargo-list := <cargo-type> <cid> [cargo-list]
-	 *
-	 * B feature       see action 0
-	 * B n-id          bits 0-6: how many IDs this definition applies to
-	 *                 bit 7: if set, this is a wagon override definition (see below)
-	 * B ids           the IDs for which this definition applies
-	 * B num-cid       number of cargo IDs (sprite group IDs) in this definition
-	 *                 can be zero, in that case the def-cid is used always
-	 * B cargo-type    type of this cargo type (e.g. mail=2, wood=7, see below)
-	 * W cid           cargo ID (sprite group ID) for this type of cargo
-	 * W def-cid       default cargo ID (sprite group ID) */
-	/* TODO: Bridges, town houses. */
-	/* TODO: Multiple cargo support could be useful even for trains/cars -
-	 * cargo id 0xff is used for showing images in the build train list. */
-
 	static byte *last_engines;
 	static int last_engines_count;
 
-	if (!check_length(len, 6, "FeatureMapSpriteGroup")) return;
-
-	uint8 feature = buf[1];
-	uint8 idcount = buf[2] & 0x7F;
-	bool wagover = (buf[2] & 0x80) == 0x80;
-
-	if (!check_length(len, 3 + idcount, "FeatureMapSpriteGroup")) return;
-
-	/* If idcount is zero, this is a feature callback */
-	if (idcount == 0) {
-		grfmsg(2, "FeatureMapSpriteGroup: Feature callbacks not implemented yet");
-		return;
-	}
-
-	uint8 cidcount = buf[3 + idcount];
-	if (!check_length(len, 4 + idcount + cidcount * 3, "FeatureMapSpriteGroup")) return;
-
-	grfmsg(6, "FeatureMapSpriteGroup: Feature %d, %d ids, %d cids, wagon override %d",
-			feature, idcount, cidcount, wagover);
-
-	if (feature > GSF_STATION && feature != GSF_TOWNHOUSE) {
-		grfmsg(1, "FeatureMapSpriteGroup: Unsupported feature %d, skipping", feature);
-		return;
-	}
-
-
-	if (feature == GSF_STATION) {
-		// We do things differently for stations.
-
-		for (uint i = 0; i < idcount; i++) {
-			uint8 stid = buf[3 + i];
-			StationSpec *statspec = _cur_grffile->stations[stid];
-			byte *bp = &buf[4 + idcount];
-
-			for (uint c = 0; c < cidcount; c++) {
-				uint8 ctype = grf_load_byte(&bp);
-				uint16 groupid = grf_load_word(&bp);
-
-				if (groupid >= _cur_grffile->spritegroups_count || _cur_grffile->spritegroups[groupid] == NULL) {
-					grfmsg(1, "FeatureMapSpriteGroup: Spriteset 0x%04X out of range 0x%X or empty, skipping",
-					       groupid, _cur_grffile->spritegroups_count);
-					return;
-				}
-
-				ctype = TranslateCargo(feature, ctype);
-				if (ctype == CT_INVALID) continue;
-
-				statspec->spritegroup[ctype] = _cur_grffile->spritegroups[groupid];
-			}
+	if (!wagover) {
+		if (last_engines_count != idcount) {
+			last_engines = ReallocT(last_engines, idcount);
+			last_engines_count = idcount;
 		}
-
-		{
-			byte *bp = buf + 4 + idcount + cidcount * 3;
-			uint16 groupid = grf_load_word(&bp);
-
-			if (groupid >= _cur_grffile->spritegroups_count || _cur_grffile->spritegroups[groupid] == NULL) {
-				grfmsg(1, "FeatureMapSpriteGroup: Spriteset 0x%04X out of range 0x%X or empty, skipping",
-				       groupid, _cur_grffile->spritegroups_count);
-				return;
-			}
-
-			for (uint i = 0; i < idcount; i++) {
-				uint8 stid = buf[3 + i];
-				StationSpec *statspec = _cur_grffile->stations[stid];
-
-				statspec->spritegroup[CT_DEFAULT] = _cur_grffile->spritegroups[groupid];
-				statspec->grfid = _cur_grffile->grfid;
-				statspec->localidx = stid;
-				SetCustomStationSpec(statspec);
-			}
-		}
-		return;
-	} else if (feature == GSF_TOWNHOUSE) {
-		byte *bp = &buf[4 + idcount + cidcount * 3];
-		uint16 groupid = grf_load_word(&bp);
-
-		if (groupid >= _cur_grffile->spritegroups_count || _cur_grffile->spritegroups[groupid] == NULL) {
-			grfmsg(1, "FeatureMapSpriteGroup: Spriteset 0x%04X out of range 0x%X or empty, skipping.",
-			       groupid, _cur_grffile->spritegroups_count);
-			return;
-		}
-
-		for (uint i = 0; i < idcount; i++) {
-			uint8 hid = buf[3 + i];
-			HouseSpec *hs = _cur_grffile->housespec[hid];
-
-			if (hs == NULL) {
-				grfmsg(1, "FeatureMapSpriteGroup: Too many houses defined, skipping");
-				return;
-			}
-
-			hs->spritegroup = _cur_grffile->spritegroups[groupid];
-			hs->grffile = _cur_grffile;
-		}
-		return;
-	}
-
-	// FIXME: Tropicset contains things like:
-	// 03 00 01 19 01 00 00 00 00 - this is missing one 00 at the end,
-	// what should we exactly do with that? --pasky
-
-	if (_cur_grffile->spriteset_start == 0 || _cur_grffile->spritegroups == 0) {
-		grfmsg(1, "FeatureMapSpriteGroup: No sprite set to work on! Skipping");
-		return;
-	}
-
-	if (!wagover && last_engines_count != idcount) {
-		last_engines = ReallocT(last_engines, idcount);
-		last_engines_count = idcount;
-	}
-
-	if (wagover) {
+	} else {
 		if (last_engines_count == 0) {
 			grfmsg(0, "FeatureMapSpriteGroup: WagonOverride: No engine to do override with");
 			return;
 		}
+
 		grfmsg(6, "FeatureMapSpriteGroup: WagonOverride: %u engines, %u wagons",
 				last_engines_count, idcount);
 	}
 
-
 	for (uint i = 0; i < idcount; i++) {
 		uint8 engine_id = buf[3 + i];
 		uint8 engine = engine_id + _vehshifts[feature];
@@ -2367,7 +2436,7 @@
 
 			if (groupid >= _cur_grffile->spritegroups_count || _cur_grffile->spritegroups[groupid] == NULL) {
 				grfmsg(1, "FeatureMapSpriteGroup: Spriteset 0x%04X out of range 0x%X or empty, skipping", groupid, _cur_grffile->spritegroups_count);
-				return;
+				continue;
 			}
 
 			ctype = TranslateCargo(feature, ctype);
@@ -2383,7 +2452,7 @@
 	}
 
 	{
-		byte *bp = buf + 4 + idcount + cidcount * 3;
+		byte *bp = &buf[4 + idcount + cidcount * 3];
 		uint16 groupid = grf_load_word(&bp);
 
 		grfmsg(8, "-- Default group id 0x%04X", groupid);
@@ -2391,19 +2460,20 @@
 		for (uint i = 0; i < idcount; i++) {
 			uint8 engine = buf[3 + i] + _vehshifts[feature];
 
-			// Don't tell me you don't love duplicated code!
+			/* Don't tell me you don't love duplicated code! */
 			if (groupid >= _cur_grffile->spritegroups_count || _cur_grffile->spritegroups[groupid] == NULL) {
-				grfmsg(1, "FeatureMapSpriteGroup: Spriteset 0x%04X out of range 0x%X or empty, skipping", groupid, _cur_grffile->spritegroups_count);
-				return;
+				grfmsg(1, "FeatureMapSpriteGroup: Spriteset 0x%04X out of range 0x%X or empty, skipping",
+				       groupid, _cur_grffile->spritegroups_count);
+				continue;
 			}
 
 			if (wagover) {
 				/* If the ID for this action 3 is the same as the vehicle ID,
-				 * this indicates we have a helicopter rotor override. */
+ * this indicates we have a helicopter rotor override. */
 				if (feature == GSF_AIRCRAFT && engine == last_engines[i]) {
 					SetRotorOverrideSprites(engine, _cur_grffile->spritegroups[groupid]);
 				} else {
-					// TODO: No multiple cargo types per vehicle yet. --pasky
+					/* TODO: No multiple cargo types per vehicle yet. --pasky */
 					SetWagonOverrideSprites(engine, CT_DEFAULT, _cur_grffile->spritegroups[groupid], last_engines, last_engines_count);
 				}
 			} else {
@@ -2415,6 +2485,173 @@
 	}
 }
 
+
+static void StationMapSpriteGroup(byte *buf, uint8 idcount, uint8 cidcount)
+{
+	for (uint i = 0; i < idcount; i++) {
+		uint8 stid = buf[3 + i];
+		StationSpec *statspec = _cur_grffile->stations[stid];
+		byte *bp = &buf[4 + idcount];
+
+		for (uint c = 0; c < cidcount; c++) {
+			uint8 ctype = grf_load_byte(&bp);
+			uint16 groupid = grf_load_word(&bp);
+
+			if (groupid >= _cur_grffile->spritegroups_count || _cur_grffile->spritegroups[groupid] == NULL) {
+				grfmsg(1, "FeatureMapSpriteGroup: Spriteset 0x%04X out of range 0x%X or empty, skipping",
+				       groupid, _cur_grffile->spritegroups_count);
+				continue;
+			}
+
+			ctype = TranslateCargo(GSF_STATION, ctype);
+			if (ctype == CT_INVALID) continue;
+
+			statspec->spritegroup[ctype] = _cur_grffile->spritegroups[groupid];
+		}
+	}
+
+	{
+		byte *bp = &buf[4 + idcount + cidcount * 3];
+		uint16 groupid = grf_load_word(&bp);
+
+		if (groupid >= _cur_grffile->spritegroups_count || _cur_grffile->spritegroups[groupid] == NULL) {
+			grfmsg(1, "FeatureMapSpriteGroup: Spriteset 0x%04X out of range 0x%X or empty, skipping",
+			       groupid, _cur_grffile->spritegroups_count);
+			return;
+		}
+
+		for (uint i = 0; i < idcount; i++) {
+			uint8 stid = buf[3 + i];
+			StationSpec *statspec = _cur_grffile->stations[stid];
+
+			statspec->spritegroup[CT_DEFAULT] = _cur_grffile->spritegroups[groupid];
+			statspec->grfid = _cur_grffile->grfid;
+			statspec->localidx = stid;
+			SetCustomStationSpec(statspec);
+		}
+	}
+}
+
+
+static void TownHouseMapSpriteGroup(byte *buf, uint8 idcount, uint8 cidcount)
+{
+	byte *bp = &buf[4 + idcount + cidcount * 3];
+	uint16 groupid = grf_load_word(&bp);
+
+	if (groupid >= _cur_grffile->spritegroups_count || _cur_grffile->spritegroups[groupid] == NULL) {
+		grfmsg(1, "FeatureMapSpriteGroup: Spriteset 0x%04X out of range 0x%X or empty, skipping.",
+		       groupid, _cur_grffile->spritegroups_count);
+		return;
+	}
+
+	for (uint i = 0; i < idcount; i++) {
+		uint8 hid = buf[3 + i];
+		HouseSpec *hs = _cur_grffile->housespec[hid];
+
+		if (hs == NULL) {
+			grfmsg(1, "FeatureMapSpriteGroup: Too many houses defined, skipping");
+			return;
+		}
+
+		hs->spritegroup = _cur_grffile->spritegroups[groupid];
+	}
+}
+
+
+static void CargoMapSpriteGroup(byte *buf, uint8 idcount, uint8 cidcount)
+{
+	byte *bp = &buf[4 + idcount + cidcount * 3];
+	uint16 groupid = grf_load_word(&bp);
+
+	if (groupid >= _cur_grffile->spritegroups_count || _cur_grffile->spritegroups[groupid] == NULL) {
+		grfmsg(1, "FeatureMapSpriteGroup: Spriteset 0x%04X out of range 0x%X or empty, skipping.",
+		       groupid, _cur_grffile->spritegroups_count);
+		return;
+	}
+
+	for (uint i = 0; i < idcount; i++) {
+		CargoID cid = buf[3 + i];
+
+		if (cid >= NUM_CARGO) {
+			grfmsg(1, "FeatureMapSpriteGroup: Cargo ID %d out of range, skipping");
+			continue;
+		}
+
+		CargoSpec *cs = &_cargo[cid];
+		cs->grfid = _cur_grffile->grfid;
+		cs->group = _cur_grffile->spritegroups[groupid];
+	}
+}
+
+
+/* Action 0x03 */
+static void FeatureMapSpriteGroup(byte *buf, int len)
+{
+	/* <03> <feature> <n-id> <ids>... <num-cid> [<cargo-type> <cid>]... <def-cid>
+	 * id-list    := [<id>] [id-list]
+	 * cargo-list := <cargo-type> <cid> [cargo-list]
+	 *
+	 * B feature       see action 0
+	 * B n-id          bits 0-6: how many IDs this definition applies to
+	 *                 bit 7: if set, this is a wagon override definition (see below)
+	 * B ids           the IDs for which this definition applies
+	 * B num-cid       number of cargo IDs (sprite group IDs) in this definition
+	 *                 can be zero, in that case the def-cid is used always
+	 * B cargo-type    type of this cargo type (e.g. mail=2, wood=7, see below)
+	 * W cid           cargo ID (sprite group ID) for this type of cargo
+	 * W def-cid       default cargo ID (sprite group ID) */
+
+	if (!check_length(len, 6, "FeatureMapSpriteGroup")) return;
+
+	uint8 feature = buf[1];
+	uint8 idcount = buf[2] & 0x7F;
+	bool wagover = (buf[2] & 0x80) == 0x80;
+
+	if (!check_length(len, 3 + idcount, "FeatureMapSpriteGroup")) return;
+
+	/* If idcount is zero, this is a feature callback */
+	if (idcount == 0) {
+		grfmsg(2, "FeatureMapSpriteGroup: Feature callbacks not implemented yet");
+		return;
+	}
+
+	uint8 cidcount = buf[3 + idcount];
+	if (!check_length(len, 4 + idcount + cidcount * 3, "FeatureMapSpriteGroup")) return;
+
+	grfmsg(6, "FeatureMapSpriteGroup: Feature %d, %d ids, %d cids, wagon override %d",
+			feature, idcount, cidcount, wagover);
+
+	if (_cur_grffile->spriteset_start == 0 || _cur_grffile->spritegroups == 0) {
+		grfmsg(1, "FeatureMapSpriteGroup: No sprite set to work on! Skipping");
+		return;
+	}
+
+	switch (feature) {
+		case GSF_TRAIN:
+		case GSF_ROAD:
+		case GSF_SHIP:
+		case GSF_AIRCRAFT:
+			VehicleMapSpriteGroup(buf, feature, idcount, cidcount, wagover);
+			return;
+
+		case GSF_STATION:
+			StationMapSpriteGroup(buf, idcount, cidcount);
+			return;
+
+		case GSF_TOWNHOUSE:
+			TownHouseMapSpriteGroup(buf, idcount, cidcount);
+			return;
+
+		case GSF_CARGOS:
+			CargoMapSpriteGroup(buf, idcount, cidcount);
+			return;
+
+		default:
+			grfmsg(1, "FeatureMapSpriteGroup: Unsupported feature %d, skipping", feature);
+			return;
+	}
+}
+
 /* Action 0x04 */
 static void FeatureNewName(byte *buf, int len)
 {
@@ -2486,7 +2723,7 @@
 				case GSF_TOWNHOUSE:
 				default:
 					switch (GB(id, 8, 8)) {
-						case 0xC4: /* Station class name */
+						case 0xC4: // Station class name
 							if (_cur_grffile->stations == NULL || _cur_grffile->stations[GB(id, 0, 8)] == NULL) {
 								grfmsg(1, "FeatureNewName: Attempt to name undefined station 0x%X, ignoring", GB(id, 0, 8));
 							} else {
@@ -2495,7 +2732,7 @@
 							}
 							break;
 
-						case 0xC5: /* Station name */
+						case 0xC5: // Station name
 							if (_cur_grffile->stations == NULL || _cur_grffile->stations[GB(id, 0, 8)] == NULL) {
 								grfmsg(1, "FeatureNewName: Attempt to name undefined station 0x%X, ignoring", GB(id, 0, 8));
 							} else {
@@ -2503,7 +2740,7 @@
 							}
 							break;
 
-						case 0xC9: { /* House name */
+						case 0xC9: { // House name
 							if (_cur_grffile->housespec == NULL || _cur_grffile->housespec[GB(id, 0, 8)] == NULL) {
 								grfmsg(1, "FeatureNewName: Attempt to name undefined house 0x%X, ignoring.", GB(id, 0, 8));
 							} else {
@@ -2528,14 +2765,14 @@
 				case GSF_BRIDGE :
 					AddGRFString(_cur_spriteid, id, lang, name);
 					switch (GB(id, 8,8)) {
-						case 0xC9: /* House name */
+						case 0xC9: // House name
 						default:
 							grfmsg(7, "FeatureNewName: Unsupported ID (0x%04X)", id);
 					}
 					break;
 
 				case GSF_INDUSTRIES :
-				case 0x48 :   /* for generic strings */
+				case 0x48 :   // for generic strings
 					AddGRFString(_cur_spriteid, id, lang, name);
 					break;
 				default :
@@ -2565,7 +2802,7 @@
 	uint16 num = grf_load_extended(&buf);
 
 	switch (type) {
-		case 0x04: /* Signal graphics */
+		case 0x04: // Signal graphics
 			if (num != 112 && num != 240) {
 				grfmsg(1, "GraphicsNews: Signal graphics sprite count must be 112 or 240, skipping");
 				return;
@@ -2573,7 +2810,7 @@
 			_signal_base = _cur_spriteid;
 			break;
 
-		case 0x05: /* Catenary graphics */
+		case 0x05: // Catenary graphics
 			if (num != 48) {
 				grfmsg(1, "GraphicsNews: Catenary graphics sprite count must be 48, skipping");
 				return;
@@ -2581,7 +2818,7 @@
 			replace = SPR_ELRAIL_BASE + 3;
 			break;
 
-		case 0x06: /* Foundations */
+		case 0x06: // Foundations
 			if (num != 74) {
 				grfmsg(1, "GraphicsNews: Foundation graphics sprite count must be 74, skipping");
 				return;
@@ -2589,7 +2826,7 @@
 			replace = SPR_SLOPES_BASE;
 			break;
 
-		case 0x08: /* Canal graphics */
+		case 0x08: // Canal graphics
 			if (num != 65) {
 				grfmsg(1, "GraphicsNews: Canal graphics sprite count must be 65, skipping");
 				return;
@@ -2597,7 +2834,7 @@
 			replace = SPR_CANALS_BASE + 5;
 			break;
 
-		case 0x0D: /* Coast graphics */
+		case 0x0D: // Coast graphics
 			if (num != 16) {
 				grfmsg(1, "GraphicsNews: Coast graphics sprite count must be 16, skipping");
 				return;
@@ -2626,16 +2863,16 @@
 static uint32 GetParamVal(byte param, uint32 *cond_val)
 {
 	switch (param) {
-		case 0x81: /* current year */
+		case 0x81: // current year
 			return clamp(_cur_year, ORIGINAL_BASE_YEAR, ORIGINAL_MAX_YEAR) - ORIGINAL_BASE_YEAR;
 
-		case 0x83: /* current climate, 0=temp, 1=arctic, 2=trop, 3=toyland */
+		case 0x83: // current climate, 0=temp, 1=arctic, 2=trop, 3=toyland
 			return _opt.landscape;
 
-		case 0x84: /* GRF loading stage */
+		case 0x84: // GRF loading stage
 			return (_cur_stage > GLS_INIT) | ((_cur_stage == GLS_ACTIVATION) << 9);
 
-		case 0x85: /* TTDPatch flags, only for bit tests */
+		case 0x85: // TTDPatch flags, only for bit tests
 			if (cond_val == NULL) {
 				/* Supported in Action 0x07 and 0x09, not 0x0D */
 				return 0;
@@ -2645,13 +2882,13 @@
 				return param_val;
 			}
 
-		case 0x86: /* road traffic side, bit 4 clear=left, set=right */
+		case 0x86: // road traffic side, bit 4 clear=left, set=right
 			return _opt.road_side << 4;
 
-		case 0x88: /* GRF ID check */
+		case 0x88: // GRF ID check
 			return 0;
 
-		case 0x8B: { /* TTDPatch version */
+		case 0x8B: { // TTDPatch version
 			uint major    = 2;
 			uint minor    = 6;
 			uint revision = 0; // special case: 2.0.1 is 2.0.10
@@ -2659,22 +2896,22 @@
 			return (major << 24) | (minor << 20) | (revision << 16) | build;
 		}
 
-		case 0x8D: /* TTD Version, 00=DOS, 01=Windows */
+		case 0x8D: // TTD Version, 00=DOS, 01=Windows
 			return !_use_dos_palette;
 
-		case 0x8E: /* Y-offset for train sprites */
+		case 0x8E: // Y-offset for train sprites
 			return _traininfo_vehicle_pitch;
 
-		case 0x92: /* Game mode */
+		case 0x92: // Game mode
 			return _game_mode;
 
-		case 0x9A: /* Always -1 */
+		case 0x9A: // Always -1
 			return UINT_MAX;
 
-		case 0x9D: /* TTD Platform, 00=TTDPatch, 01=OpenTTD */
+		case 0x9D: // TTD Platform, 00=TTDPatch, 01=OpenTTD
 			return 1;
 
-		case 0x9E: /* Miscellaneous GRF features */
+		case 0x9E: // Miscellaneous GRF features
 			return _misc_grf_features;
 
 		default:
@@ -2822,23 +3059,23 @@
 
 		switch (condtype) {
 			/* Tests 6 to 10 are only for param 0x88, GRFID checks */
-			case 6: /* Is GRFID active? */
+			case 6: // Is GRFID active?
 				result = c->status == GCS_ACTIVATED;
 				break;
 
-			case 7: /* Is GRFID non-active? */
+			case 7: // Is GRFID non-active?
 				result = c->status != GCS_ACTIVATED;
 				break;
 
-			case 8: /* GRFID is not but will be active? */
+			case 8: // GRFID is not but will be active?
 				result = c->status == GCS_INITIALISED;
 				break;
 
-			case 9: /* GRFID is or will be active? */
+			case 9: // GRFID is or will be active?
 				result = c->status == GCS_ACTIVATED || c->status == GCS_INITIALISED;
 				break;
 
-			case 10: /* GRFID is not nor will be active */
+			case 10: // GRFID is not nor will be active
 				/* This is the only condtype that doesn't get ignored if the GRFID is not found */
 				result = c == NULL || c->flags == GCS_DISABLED || c->status == GCS_NOT_FOUND;
 				break;
@@ -2972,7 +3209,7 @@
 	 * B num-sprites   How many sprites are in this set
 	 * W first-sprite  First sprite number to replace */
 
-	buf++; /* skip action byte */
+	buf++; // skip action byte
 	uint8 num_sets = grf_load_byte(&buf);
 
 	for (uint i = 0; i < num_sets; i++) {
@@ -3038,7 +3275,7 @@
 	/* For now we can only show one message per newgrf file. */
 	if (_cur_grfconfig->error != NULL) return;
 
-	buf++; /* Skip the action byte. */
+	buf++; // Skip the action byte.
 	byte severity   = grf_load_byte(&buf);
 	byte lang       = grf_load_byte(&buf);
 	byte message_id = grf_load_byte(&buf);
@@ -3208,10 +3445,10 @@
 					uint16 count   = GB(data, 16, 16);
 
 					switch (feature) {
-						case 0x00: /* Trains */
-						case 0x01: /* Road Vehicles */
-						case 0x02: /* Ships */
-						case 0x03: /* Aircraft */
+						case 0x00: // Trains
+						case 0x01: // Road Vehicles
+						case 0x02: // Ships
+						case 0x03: // Aircraft
 						{
 							uint start = 0;
 							uint size  = 0;
@@ -3262,7 +3499,7 @@
 							break;
 						}
 
-						case 0x08: /* General sprites */
+						case 0x08: // General sprites
 							switch (op) {
 								case 0:
 									/* Check if the allocated sprites will fit below the original sprite limit */
@@ -3356,15 +3593,15 @@
 			}
 			break;
 
-		case 0x07: /* Bitwise AND */
+		case 0x07: // Bitwise AND
 			res = src1 & src2;
 			break;
 
-		case 0x08: /* Bitwise OR */
+		case 0x08: // Bitwise OR
 			res = src1 | src2;
 			break;
 
-		case 0x09: /* Unsigned division */
+		case 0x09: // Unsigned division
 			if (src2 == 0) {
 				res = src1;
 			} else {
@@ -3372,7 +3609,7 @@
 			}
 			break;
 
-		case 0x0A: /* Signed divison */
+		case 0x0A: // Signed divison
 			if (src2 == 0) {
 				res = src1;
 			} else {
@@ -3380,7 +3617,7 @@
 			}
 			break;
 
-		case 0x0B: /* Unsigned modulo */
+		case 0x0B: // Unsigned modulo
 			if (src2 == 0) {
 				res = src1;
 			} else {
@@ -3388,7 +3625,7 @@
 			}
 			break;
 
-		case 0x0C: /* Signed modulo */
+		case 0x0C: // Signed modulo
 			if (src2 == 0) {
 				res = src1;
 			} else {
@@ -3404,7 +3641,7 @@
 			_traininfo_vehicle_pitch = res;
 			break;
 
-		// TODO implement
+		/* @todo implement */
 		case 0x8F: // Rail track type cost factors
 		case 0x93: // Tile refresh offset to left
 		case 0x94: // Tile refresh offset to right
@@ -3415,7 +3652,7 @@
 			grfmsg(7, "ParamSet: Skipping unimplemented target 0x%02X", target);
 			break;
 
-		case 0x9E: /* Miscellaneous GRF features */
+		case 0x9E: // Miscellaneous GRF features
 			_misc_grf_features = res;
 			/* Set train list engine width */
 			_traininfo_vehicle_width = HASBIT(res, 3) ? 32 : 29;
@@ -3609,7 +3846,7 @@
 		uint32 size = grf_load_dword(&buf);
 
 		switch (tag) {
-			case ' tmf': /* 'fmt ' */
+			case ' tmf': // 'fmt '
 				/* Audio format, must be 1 (PCM) */
 				if (grf_load_word(&buf) != 1) {
 					grfmsg(1, "LoadGRFSound: Invalid audio format");
@@ -3625,7 +3862,7 @@
 				for (; size > 16; size--) grf_load_byte(&buf);
 				break;
 
-			case 'atad': /* 'data' */
+			case 'atad': // 'data'
 				se->file_size    = size;
 				se->file_offset  = FioGetPos() - (len - (buf - buf_start)) + 1;
 				se->file_offset |= _file_index << 24;
@@ -3930,15 +4167,15 @@
 {
 	CleanUpStrings();
 
-	// Copy/reset original engine info data
+	/* Copy/reset original engine info data */
 	memcpy(&_engine_info, &orig_engine_info, sizeof(orig_engine_info));
 	memcpy(&_rail_vehicle_info, &orig_rail_vehicle_info, sizeof(orig_rail_vehicle_info));
 	memcpy(&_ship_vehicle_info, &orig_ship_vehicle_info, sizeof(orig_ship_vehicle_info));
 	memcpy(&_aircraft_vehicle_info, &orig_aircraft_vehicle_info, sizeof(orig_aircraft_vehicle_info));
 	memcpy(&_road_vehicle_info, &orig_road_vehicle_info, sizeof(orig_road_vehicle_info));
 
-	// Copy/reset original bridge info data
-	// First, free sprite table data
+	/* Copy/reset original bridge info data
+	 * First, free sprite table data */
 	for (uint i = 0; i < MAX_BRIDGES; i++) {
 		if (_bridge[i].sprite_table != NULL) {
 			for (uint j = 0; j < 7; j++) free(_bridge[i].sprite_table[j]);
@@ -3947,21 +4184,21 @@
 	}
 	memcpy(&_bridge, &orig_bridge, sizeof(_bridge));
 
-	// Reset refit/cargo class data
+	/* Reset refit/cargo class data */
 	memset(&cargo_allowed, 0, sizeof(cargo_allowed));
 	memset(&cargo_disallowed, 0, sizeof(cargo_disallowed));
 
-	// Reset GRM reservations
+	/* Reset GRM reservations */
 	memset(&_grm_engines, 0, sizeof(_grm_engines));
 
-	// Unload sprite group data
+	/* Unload sprite group data */
 	UnloadWagonOverrides();
 	UnloadRotorOverrideSprites();
 	UnloadCustomEngineSprites();
 	UnloadCustomEngineNames();
 	ResetEngineListOrder();
 
-	// Reset price base data
+	/* Reset price base data */
 	// ResetPriceBaseMultipliers();
 
 	/* Reset the curencies array */
@@ -3971,26 +4208,22 @@
 	ResetCustomHouses();
 	ResetHouses();
 
-	// Reset station classes
+	/* Reset station classes */
 	ResetStationClasses();
 	ResetCustomStations();
 
+	/* Reset the snowline table. */
+	ClearSnowLine();
+
 	/* Reset NewGRF files */
 	ResetNewGRF();
 
-	// Add engine type to engine data. This is needed for the refit precalculation.
+	/* Add engine type to engine data. This is needed for the refit precalculation. */
 	AddTypeToEngines();
 
 	/* Set up the default cargo types */
 	SetupCargoForClimate(_opt.landscape);
 
-	/* Generate default cargo translation table */
-	memset(_default_cargo_list, 0, sizeof(_default_cargo_list));
-	for (CargoID c = 0; c != NUM_CARGO; c++) {
-		const CargoSpec *cs = GetCargo(c);
-		if (cs->IsValid()) _default_cargo_list[cs->bitnum] = cs->label;
-	}
-
 	/* Reset misc GRF features and train list display variables */
 	_misc_grf_features = 0;
 	_traininfo_vehicle_pitch = 0;
@@ -4146,14 +4379,14 @@
 		}
 
 		if (cargo_allowed[engine] != 0) {
-			// Build up the list of cargo types from the set cargo classes.
+			/* Build up the list of cargo types from the set cargo classes. */
 			for (CargoID i = 0; i < NUM_CARGO; i++) {
 				const CargoSpec *cs = GetCargo(i);
 				if (cargo_allowed[engine]    & cs->classes) SETBIT(mask,     i);
 				if (cargo_disallowed[engine] & cs->classes) SETBIT(not_mask, i);
 			}
 		} else {
-			// Don't apply default refit mask to wagons or engines with no capacity
+			/* Don't apply default refit mask to wagons or engines with no capacity */
 			if (xor_mask == 0 && (
 						GetEngine(engine)->type != VEH_TRAIN || (
 							RailVehInfo(engine)->capacity != 0 &&
@@ -4235,6 +4468,26 @@
 	}
 }
 
+
+/** Each cargo string needs to be mapped from TTDPatch to OpenTTD string IDs.
+ * This is done after loading so that strings from Action 4 will be mapped
+ * properly. */
+static void MapNewCargoStrings()
+{
+	for (CargoID c = 0; c < NUM_CARGO; c++) {
+		CargoSpec *cs = &_cargo[c];
+		/* Don't map if the cargo is unavailable or not from NewGRF */
+		if (!cs->IsValid() || cs->grfid == 0) continue;
+
+		cs->name         = MapGRFStringID(cs->grfid, cs->name);
+		cs->name_plural  = MapGRFStringID(cs->grfid, cs->name_plural);
+		cs->units_volume = MapGRFStringID(cs->grfid, cs->units_volume);
+		cs->quantifier   = MapGRFStringID(cs->grfid, cs->quantifier);
+		cs->abbrev       = MapGRFStringID(cs->grfid, cs->abbrev);
+	}
+}
+
+
 /* Here we perform initial decoding of some special sprites (as are they
  * described at http://www.ttdpatch.net/src/newgrf.txt, but this is only a very
  * partial implementation yet). */
@@ -4256,26 +4509,26 @@
 	 * is not in memory and scanning the file every time would be too expensive.
 	 * In other stages we skip action 0x10 since it's already dealt with. */
 	static const SpecialSpriteHandler handlers[][GLS_END] = {
-		/* 0x00 */ { NULL,     SafeChangeInfo, NULL,       InitChangeInfo, FeatureChangeInfo, },
-		/* 0x01 */ { NULL,     GRFUnsafe, NULL,            NULL,       NewSpriteSet, },
-		/* 0x02 */ { NULL,     GRFUnsafe, NULL,            NULL,       NewSpriteGroup, },
-		/* 0x03 */ { NULL,     GRFUnsafe, NULL,            NULL,       FeatureMapSpriteGroup, },
-		/* 0x04 */ { NULL,     NULL,      NULL,            NULL,       FeatureNewName, },
-		/* 0x05 */ { NULL,     NULL,      NULL,            NULL,       GraphicsNew, },
-		/* 0x06 */ { NULL,     NULL,      NULL,            CfgApply,   CfgApply, },
-		/* 0x07 */ { NULL,     NULL,      NULL,            NULL,       SkipIf, },
-		/* 0x08 */ { ScanInfo, NULL,      NULL,            GRFInfo,    GRFInfo, },
-		/* 0x09 */ { NULL,     NULL,      NULL,            SkipIf,     SkipIf, },
-		/* 0x0A */ { NULL,     NULL,      NULL,            NULL,       SpriteReplace, },
-		/* 0x0B */ { NULL,     NULL,      NULL,            GRFLoadError, GRFLoadError, },
-		/* 0x0C */ { NULL,     NULL,      NULL,            GRFComment, GRFComment, },
-		/* 0x0D */ { NULL,     SafeParamSet, NULL,         ParamSet,   ParamSet, },
-		/* 0x0E */ { NULL,     SafeGRFInhibit, NULL,       GRFInhibit, GRFInhibit, },
-		/* 0x0F */ { NULL,     NULL,      NULL,            NULL,       NULL, },
-		/* 0x10 */ { NULL,     NULL,      DefineGotoLabel, NULL,       NULL, },
-		/* 0x11 */ { NULL,     GRFUnsafe, NULL,            NULL,       GRFSound, },
-		/* 0x12 */ { NULL,     NULL,      NULL,            NULL,       LoadFontGlyph, },
-		/* 0x13 */ { NULL,     NULL,      NULL,            NULL,       TranslateGRFStrings, },
+		/* 0x00 */ { NULL,     SafeChangeInfo, NULL,       InitChangeInfo, ReserveChangeInfo, FeatureChangeInfo, },
+		/* 0x01 */ { NULL,     GRFUnsafe, NULL,            NULL,           NULL,              NewSpriteSet, },
+		/* 0x02 */ { NULL,     GRFUnsafe, NULL,            NULL,           NULL,              NewSpriteGroup, },
+		/* 0x03 */ { NULL,     GRFUnsafe, NULL,            NULL,           NULL,              FeatureMapSpriteGroup, },
+		/* 0x04 */ { NULL,     NULL,      NULL,            NULL,           NULL,              FeatureNewName, },
+		/* 0x05 */ { NULL,     NULL,      NULL,            NULL,           NULL,              GraphicsNew, },
+		/* 0x06 */ { NULL,     NULL,      NULL,            CfgApply,       NULL,              CfgApply, },
+		/* 0x07 */ { NULL,     NULL,      NULL,            NULL,           SkipIf,            SkipIf, },
+		/* 0x08 */ { ScanInfo, NULL,      NULL,            GRFInfo,        NULL,              GRFInfo, },
+		/* 0x09 */ { NULL,     NULL,      NULL,            SkipIf,         SkipIf,            SkipIf, },
+		/* 0x0A */ { NULL,     NULL,      NULL,            NULL,           NULL,              SpriteReplace, },
+		/* 0x0B */ { NULL,     NULL,      NULL,            GRFLoadError,   GRFLoadError,      GRFLoadError, },
+		/* 0x0C */ { NULL,     NULL,      NULL,            GRFComment,     NULL,              GRFComment, },
+		/* 0x0D */ { NULL,     SafeParamSet, NULL,         ParamSet,       ParamSet,          ParamSet, },
+		/* 0x0E */ { NULL,     SafeGRFInhibit, NULL,       GRFInhibit,     GRFInhibit,        GRFInhibit, },
+		/* 0x0F */ { NULL,     NULL,      NULL,            NULL,           NULL,              NULL, },
+		/* 0x10 */ { NULL,     NULL,      DefineGotoLabel, NULL,           NULL,              NULL, },
+		/* 0x11 */ { NULL,     GRFUnsafe, NULL,            NULL,           NULL,              GRFSound, },
+		/* 0x12 */ { NULL,     NULL,      NULL,            NULL,           NULL,              LoadFontGlyph, },
+		/* 0x13 */ { NULL,     NULL,      NULL,            NULL,           NULL,              TranslateGRFStrings, },
 	};
 
 	byte* buf;
@@ -4410,6 +4663,10 @@
 
 	/* Add all new houses to the house array. */
 	FinaliseHouseArray();
+
+	/* Map cargo strings. This is a separate step because cargos are
+	 * loaded before strings... */
+	MapNewCargoStrings();
 }
 
 void LoadNewGRF(uint load_index, uint file_index)
@@ -4429,7 +4686,7 @@
 		for (GRFConfig *c = _grfconfig; c != NULL; c = c->next) {
 			if (c->status == GCS_DISABLED || c->status == GCS_NOT_FOUND) continue;
 
-			// TODO usererror()
+			/* @todo usererror() */
 			if (!FioCheckFileExists(c->filename)) error("NewGRF file is missing '%s'", c->filename);
 
 			if (stage == GLS_LABELSCAN) InitNewGRFFile(c, _cur_spriteid);
--- a/src/newgrf.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file newgrf.h */
+
 #ifndef NEWGRF_H
 #define NEWGRF_H
 
@@ -14,6 +16,7 @@
 	GLS_SAFETYSCAN,
 	GLS_LABELSCAN,
 	GLS_INIT,
+	GLS_RESERVE,
 	GLS_ACTIVATION,
 	GLS_END,
 };
@@ -60,7 +63,7 @@
 	HouseSpec **housespec;
 
 	uint32 param[0x80];
-	uint param_end; /// one more than the highest set parameter
+	uint param_end;  ///< one more than the highest set parameter
 
 	GRFLabel *label; ///< Pointer to the first label. This is a linked list, not an array.
 
@@ -78,7 +81,7 @@
 
 void LoadNewGRFFile(GRFConfig *config, uint file_index, GrfLoadingStage stage);
 void LoadNewGRF(uint load_index, uint file_index);
-void ReloadNewGRFData(); // in openttd.c
+void ReloadNewGRFData(); // in openttd.cpp
 
 void CDECL grfmsg(int severity, const char *str, ...);
 
--- a/src/newgrf_callbacks.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_callbacks.h	Thu Apr 19 14:43:25 2007 +0000
@@ -99,9 +99,15 @@
 	/* Called to play a special sound effect */
 	CBID_VEHICLE_SOUND_EFFECT       = 0x33,
 
+	/* Called to calculate the income of delivered cargo */
+	CBID_CARGO_PROFIT_CALC          = 0x39,
+
 	/* Called (if appropriate bit in callback mask set) to determine whether a
 	 * town building can be destroyed. */
 	CBID_HOUSE_DENY_DESTRUCTION     = 0x143,
+
+	/* Called to calculate part of a station rating */
+	CBID_CARGO_STATION_RATING_CALC  = 0x145,
 };
 
 /**
@@ -145,6 +151,14 @@
 };
 
 /**
+ * Callback masks for cargos.
+ */
+enum CargoCallbackMask {
+	CBM_CARGO_PROFIT_CALC         = 0,
+	CBM_CARGO_STATION_RATING_CALC = 1,
+};
+
+/**
  * Result of a failed callback.
  */
 enum {
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/newgrf_cargo.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -0,0 +1,93 @@
+/* $Id$ */
+
+#include "stdafx.h"
+#include "openttd.h"
+#include "cargotype.h"
+#include "newgrf.h"
+#include "newgrf_callbacks.h"
+#include "newgrf_spritegroup.h"
+#include "newgrf_cargo.h"
+
+
+static uint32 CargoGetRandomBits(const ResolverObject *object)
+{
+	return 0;
+}
+
+
+static uint32 CargoGetTriggers(const ResolverObject *object)
+{
+	return 0;
+}
+
+
+static void CargoSetTriggers(const ResolverObject *object, int triggers)
+{
+	return;
+}
+
+
+static uint32 CargoGetVariable(const ResolverObject *object, byte variable, byte parameter, bool *available)
+{
+	*available = false;
+	return 0;
+}
+
+
+static const SpriteGroup *CargoResolveReal(const ResolverObject *object, const SpriteGroup *group)
+{
+	/* Cargo action 2s should always have only 1 "loaded" state */
+	if (group->g.real.num_loaded == 0) return NULL;
+
+	return group->g.real.loaded[0];
+}
+
+
+static void NewCargoResolver(ResolverObject *res, const CargoSpec *cs)
+{
+	res->GetRandomBits = &CargoGetRandomBits;
+	res->GetTriggers   = &CargoGetTriggers;
+	res->SetTriggers   = &CargoSetTriggers;
+	res->GetVariable   = &CargoGetVariable;
+	res->ResolveReal   = &CargoResolveReal;
+
+	res->u.cargo.cs = cs;
+
+	res->callback        = 0;
+	res->callback_param1 = 0;
+	res->callback_param2 = 0;
+	res->last_value      = 0;
+	res->trigger         = 0;
+	res->reseed          = 0;
+}
+
+
+SpriteID GetCustomCargoSprite(const CargoSpec *cs)
+{
+	const SpriteGroup *group;
+	ResolverObject object;
+
+	NewCargoResolver(&object, cs);
+
+	group = Resolve(cs->group, &object);
+	if (group == NULL || group->type != SGT_RESULT) return 0;
+
+	return group->g.result.sprite;
+}
+
+
+uint16 GetCargoCallback(uint16 callback, uint32 param1, uint32 param2, const CargoSpec *cs)
+{
+	ResolverObject object;
+	const SpriteGroup *group;
+
+	NewCargoResolver(&object, cs);
+	object.callback = callback;
+	object.callback_param1 = param1;
+	object.callback_param2 = param2;
+
+	group = Resolve(cs->group, &object);
+	if (group == NULL || group->type != SGT_CALLBACK) return CALLBACK_FAILED;
+
+	return group->g.callback.result;
+}
--- a/src/newgrf_cargo.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_cargo.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file newgrf_cargo.h */
+
 #ifndef NEWGRF_CARGO_H
 #define NEWGRF_CARGO_H
 
@@ -19,4 +21,9 @@
 static const CargoID CT_PURCHASE     = NUM_CARGO + 1;
 static const CargoID CT_DEFAULT_NA   = NUM_CARGO + 2;
 
+typedef struct CargoSpec;
+
+SpriteID GetCustomCargoSprite(const CargoSpec *cs);
+uint16 GetCargoCallback(uint16 callback, uint32 param1, uint32 param2, const CargoSpec *cs);
+
 #endif /* NEWGRF_CARGO_H */
--- a/src/newgrf_config.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_config.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file newgfr_config.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "functions.h"
@@ -481,3 +483,4 @@
 };
 
 
+
--- a/src/newgrf_config.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_config.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file newgrf_config.h */
+
 #ifndef NEWGRF_CONFIG_H
 #define NEWGRF_CONFIG_H
 
@@ -80,7 +82,7 @@
 bool FillGRFDetails(GRFConfig *config, bool is_static);
 char *GRFBuildParamList(char *dst, const GRFConfig *c, const char *last);
 
-/* In newgrf_gui.c */
+/* In newgrf_gui.cpp */
 void ShowNewGRFSettings(bool editable, bool show_params, bool exec_changes, GRFConfig **config);
 
 #ifdef ENABLE_NETWORK
--- a/src/newgrf_engine.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_engine.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file newgrf_engine.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "variables.h"
@@ -66,10 +68,10 @@
 	const WagonOverrides *wos = &_engine_wagon_overrides[engine];
 	int i;
 
-	// XXX: This could turn out to be a timesink on profiles. We could
-	// always just dedicate 65535 bytes for an [engine][train] trampoline
-	// for O(1). Or O(logMlogN) and searching binary tree or smt. like
-	// that. --pasky
+	/* XXX: This could turn out to be a timesink on profiles. We could
+	 * always just dedicate 65535 bytes for an [engine][train] trampoline
+	 * for O(1). Or O(logMlogN) and searching binary tree or smt. like
+	 * that. --pasky */
 
 	for (i = 0; i < wos->overrides_count; i++) {
 		const WagonOverride *wo = &wos->overrides[i];
@@ -260,11 +262,11 @@
 			 * to a landing by the hanger of an international airport. */
 			if (amdflag & AMED_SLOWTURN) return AMS_TTDP_FLIGHT_TO_TOWER;
 
-			// The final two conditions apply to helicopters or aircraft.
-			/* Has reached hanger? */
+			/* The final two conditions apply to helicopters or aircraft.
+			 * Has reached hanger? */
 			if (amdflag & AMED_EXACTPOS) return AMS_TTDP_HANGAR;
 
-			// Still moving towards hanger.
+			/* Still moving towards hanger. */
 			return AMS_TTDP_TO_HANGAR;
 
 		case TERM1:
@@ -318,7 +320,7 @@
 
 		case ENDLANDING: // On the runway braking
 			if (amdflag & AMED_BRAKE) return AMS_TTDP_BRAKING;
-			// Landed - moving off runway
+			/* Landed - moving off runway */
 			return AMS_TTDP_TO_INWAY;
 
 		case HELILANDING:
@@ -393,7 +395,7 @@
 		case STARTTAKEOFF: // Accelerating down runway
 		case ENDTAKEOFF:   // Ascent
 		case HELITAKEOFF:
-			// TODO Need to find which terminal (or hanger) we've come from. How?
+			/* @todo Need to find which terminal (or hanger) we've come from. How? */
 			return AMA_TTDP_PAD1_TO_TAKEOFF;
 
 		case FLYING:
@@ -403,7 +405,7 @@
 		case ENDLANDING: // On the runway braking
 		case HELILANDING:
 		case HELIENDLANDING:
-			// TODO Need to check terminal we're landing to. Is it known yet?
+			/* @todo Need to check terminal we're landing to. Is it known yet? */
 			return (v->current_order.type == OT_GOTO_DEPOT) ?
 				AMA_TTDP_LANDING_TO_HANGAR : AMA_TTDP_LANDING_TO_PAD1;
 
@@ -473,12 +475,12 @@
 	if (v == NULL) {
 		/* Vehicle does not exist, so we're in a purchase list */
 		switch (variable) {
-			case 0x43: return _current_player; /* Owner information */
-			case 0x46: return 0;               /* Motion counter */
-			case 0x48: return GetEngine(object->u.vehicle.self_type)->flags; /* Vehicle Type Info */
-			case 0xC4: return clamp(_cur_year, ORIGINAL_BASE_YEAR, ORIGINAL_MAX_YEAR) - ORIGINAL_BASE_YEAR; /* Build year */
-			case 0xDA: return INVALID_VEHICLE; /* Next vehicle */
-			case 0x7F: return GetGRFParameter(object->u.vehicle.self_type, parameter); /* Read GRF parameter */
+			case 0x43: return _current_player; // Owner information
+			case 0x46: return 0;               // Motion counter
+			case 0x48: return GetEngine(object->u.vehicle.self_type)->flags; // Vehicle Type Info
+			case 0xC4: return clamp(_cur_year, ORIGINAL_BASE_YEAR, ORIGINAL_MAX_YEAR) - ORIGINAL_BASE_YEAR; // Build year
+			case 0xDA: return INVALID_VEHICLE; // Next vehicle
+			case 0x7F: return GetGRFParameter(object->u.vehicle.self_type, parameter); // Read GRF parameter
 		}
 
 		*available = false;
@@ -487,8 +489,8 @@
 
 	/* Calculated vehicle parameters */
 	switch (variable) {
-		case 0x40: /* Get length of consist */
-		case 0x41: /* Get length of same consecutive wagons */
+		case 0x40: // Get length of consist
+		case 0x41: // Get length of same consecutive wagons
 			if (v->type != VEH_TRAIN) return 1;
 
 			{
@@ -509,7 +511,7 @@
 				return chain_before | chain_after << 8 | (chain_before + chain_after + (variable == 0x41)) << 16;
 			}
 
-		case 0x42: { /* Consist cargo information */
+		case 0x42: { // Consist cargo information
 			/* XXX Missing support for common refit cycle and property 25 */
 			const Vehicle *u;
 			byte cargo_classes = 0;
@@ -541,15 +543,15 @@
 			return cargo_classes | (common_cargo_type << 8) | (user_def_data << 24);
 		}
 
-		case 0x43: /* Player information */
+		case 0x43: // Player information
 			return v->owner;
 
-		case 0x44: /* Aircraft information */
+		case 0x44: // Aircraft information
 			if (v->type != VEH_AIRCRAFT) return UINT_MAX;
 
 			{
 				const Vehicle *w = v->next;
-				uint16 altitude = v->z_pos - w->z_pos; /* Aircraft height - shadow height */
+				uint16 altitude = v->z_pos - w->z_pos; // Aircraft height - shadow height
 				byte airporttype;
 
 				switch (GetStation(v->u.air.targetairport)->airport_type) {
@@ -571,10 +573,10 @@
 				return (altitude << 8) | airporttype;
 			}
 
-		case 0x46: /* Motion counter */
+		case 0x46: // Motion counter
 			return v->motion_counter;
 
-		case 0x47: { /* Vehicle cargo info */
+		case 0x47: { // Vehicle cargo info
 			/* Format: ccccwwtt
 			 * tt - the cargo type transported by the vehicle,
 			 *     translated if a translation table has been installed.
@@ -586,10 +588,10 @@
 			return (cs->classes << 16) | (cs->weight << 8) | GetEngineGRF(v->engine_type)->cargo_map[v->cargo_type];
 		}
 
-		case 0x48: return GetEngine(v->engine_type)->flags; /* Vehicle Type Info */
+		case 0x48: return GetEngine(v->engine_type)->flags; // Vehicle Type Info
 
 		/* Variables which use the parameter */
-		case 0x60: /* Count consist's engine ID occurance */
+		case 0x60: // Count consist's engine ID occurance
 			if (v->type != VEH_TRAIN) return v->engine_type == parameter;
 
 			{
@@ -600,13 +602,13 @@
 				return count;
 			}
 
-		case 0x7F: return GetGRFParameter(v->engine_type, parameter); /* Read GRF parameter */
+		case 0x7F: return GetGRFParameter(v->engine_type, parameter); // Read GRF parameter
 
 		case 0xFE:
 		case 0xFF: {
 			uint16 modflags = 0;
 
-			/* TODO: There are some other bits that should be implemented:
+			/* @todo: There are some other bits that should be implemented:
 			 *   bit 5: Whether the rail vehicle is powered or not (mostly useful for wagons).
 			 *   bit 6: This is an electrically powered rail vehicle which is running on normal rail.
 			 *   bit 8: (Maybe?) Toggled whenever the train reverses.
@@ -992,7 +994,7 @@
 void TriggerVehicle(Vehicle *v, VehicleTrigger trigger)
 {
 	if (trigger == VEHICLE_TRIGGER_DEPOT) {
-		// store that the vehicle entered a depot this tick
+		/* store that the vehicle entered a depot this tick */
 		VehicleEnteredDepotThisTick(v);
 	}
 
@@ -1020,8 +1022,8 @@
 	return _engine_custom_names[engine] == 0 ? _engine_name_strings[engine] : _engine_custom_names[engine];
 }
 
-// Functions for changing the order of vehicle purchase lists
-// This is currently only implemented for rail vehicles.
+/* Functions for changing the order of vehicle purchase lists
+ * This is currently only implemented for rail vehicles. */
 static EngineID _engine_list_order[NUM_TRAIN_ENGINES];
 static byte _engine_list_position[NUM_TRAIN_ENGINES];
 
@@ -1066,13 +1068,13 @@
 
 	if (engine == target) return;
 
-	// First, remove our ID from the list.
+	/* First, remove our ID from the list. */
 	for (i = 0; i < NUM_TRAIN_ENGINES - 1; i++) {
 		if (_engine_list_order[i] == engine) moving = true;
 		if (moving) _engine_list_order[i] = _engine_list_order[i + 1];
 	}
 
-	// Now, insert it again, before the target engine.
+	/* Now, insert it again, before the target engine. */
 	for (i = NUM_TRAIN_ENGINES - 1; i > 0; i--) {
 		_engine_list_order[i] = _engine_list_order[i - 1];
 		if (_engine_list_order[i] == target) {
@@ -1081,7 +1083,7 @@
 		}
 	}
 
-	// Update the engine list position (a reverse of engine list order)
+	/* Update the engine list position (a reverse of engine list order) */
 	for (i = 0; i < NUM_TRAIN_ENGINES; i++) {
 		_engine_list_position[_engine_list_order[i]] = i;
 	}
--- a/src/newgrf_engine.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_engine.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file newgrf_engine.h */
+
 #ifndef NEWGRF_ENGINE_H
 #define NEWGRF_ENGINE_H
 
@@ -7,9 +9,6 @@
 #include "direction.h"
 #include "newgrf_cargo.h"
 
-/** @file newgrf_engine.h
- */
-
 extern int _traininfo_vehicle_pitch;
 extern int _traininfo_vehicle_width;
 
@@ -38,11 +37,11 @@
 
 enum VehicleTrigger {
 	VEHICLE_TRIGGER_NEW_CARGO     = 1,
-	// Externally triggered only for the first vehicle in chain
+	/* Externally triggered only for the first vehicle in chain */
 	VEHICLE_TRIGGER_DEPOT         = 2,
-	// Externally triggered only for the first vehicle in chain, only if whole chain is empty
+	/* Externally triggered only for the first vehicle in chain, only if whole chain is empty */
 	VEHICLE_TRIGGER_EMPTY         = 4,
-	// Not triggered externally (called for the whole chain if we got NEW_CARGO)
+	/* Not triggered externally (called for the whole chain if we got NEW_CARGO) */
 	VEHICLE_TRIGGER_ANY_NEW_CARGO = 8,
 };
 void TriggerVehicle(Vehicle *veh, VehicleTrigger trigger);
--- a/src/newgrf_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file newgrf_gui.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "functions.h"
@@ -157,7 +159,7 @@
 		case WE_CLICK:
 			switch (e->we.click.widget) {
 				case 3: {
-					// Get row...
+					/* Get row... */
 					const GRFConfig *c;
 					uint i = (e->we.click.pt.y - w->widget[3].top) / 10 + w->vscroll.pos;
 
@@ -167,7 +169,7 @@
 					break;
 				}
 
-				case 6: /* Add selection to list */
+				case 6: // Add selection to list
 					if (WP(w, newgrf_add_d).sel != NULL) {
 						const GRFConfig *src = WP(w, newgrf_add_d).sel;
 						GRFConfig **list;
@@ -196,7 +198,7 @@
 					}
 					break;
 
-				case 7: /* Rescan list */
+				case 7: // Rescan list
 					WP(w, newgrf_add_d).sel = NULL;
 					ScanNewGRFFiles();
 					SetWindowDirty(w);
@@ -376,7 +378,7 @@
 
 		case WE_CLICK:
 			switch (e->we.click.widget) {
-				case SNGRFS_ADD: { /* Add GRF */
+				case SNGRFS_ADD: { // Add GRF
 					GRFConfig **list = WP(w, newgrf_d).list;
 					Window *w;
 
@@ -388,7 +390,7 @@
 					break;
 				}
 
-				case SNGRFS_REMOVE: { /* Remove GRF */
+				case SNGRFS_REMOVE: { // Remove GRF
 					GRFConfig **pc, *c, *newsel;
 
 					/* Choose the next GRF file to be the selected file */
@@ -412,7 +414,7 @@
 					break;
 				}
 
-				case SNGRFS_MOVE_UP: { /* Move GRF up */
+				case SNGRFS_MOVE_UP: { // Move GRF up
 					GRFConfig **pc, *c;
 					if (WP(w, newgrf_d).sel == NULL) break;
 
@@ -428,7 +430,7 @@
 					break;
 				}
 
-				case SNGRFS_MOVE_DOWN: { /* Move GRF down */
+				case SNGRFS_MOVE_DOWN: { // Move GRF down
 					GRFConfig **pc, *c;
 					if (WP(w, newgrf_d).sel == NULL) break;
 
@@ -444,7 +446,7 @@
 					break;
 				}
 
-				case SNGRFS_FILE_LIST: { /* Select a GRF */
+				case SNGRFS_FILE_LIST: { // Select a GRF
 					GRFConfig *c;
 					uint i = (e->we.click.pt.y - w->widget[SNGRFS_FILE_LIST].top) / 14 + w->vscroll.pos;
 
@@ -455,7 +457,7 @@
 					break;
 				}
 
-				case SNGRFS_APPLY_CHANGES: /* Apply changes made to GRF list */
+				case SNGRFS_APPLY_CHANGES: // Apply changes made to GRF list
 					if (WP(w, newgrf_d).execute) {
 						ShowQuery(
 							STR_POPUP_CAUTION_CAPTION,
@@ -468,7 +470,7 @@
 					}
 					break;
 
-				case SNGRFS_SET_PARAMETERS: { /* Edit parameters */
+				case SNGRFS_SET_PARAMETERS: { // Edit parameters
 					char buff[512];
 					if (WP(w, newgrf_d).sel == NULL) break;
 
--- a/src/newgrf_house.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_house.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -8,6 +8,7 @@
 #include "variables.h"
 #include "debug.h"
 #include "viewport.h"
+#include "landscape.h"
 #include "date.h"
 #include "town.h"
 #include "town_map.h"
@@ -251,8 +252,8 @@
 static uint32 GetTerrainType(TileIndex tile)
 {
 	switch (_opt.landscape) {
-		case LT_DESERT: return GetTropicZone(tile) == TROPICZONE_DESERT ? 1 : 2;
-		case LT_HILLY:  return GetTileZ(tile) >= _opt.snow_line ? 4 : 0;
+		case LT_TROPIC: return GetTropicZone(tile) == TROPICZONE_DESERT ? 1 : 2;
+		case LT_ARCTIC: return GetTileZ(tile) >= GetSnowLine() ? 4 : 0;
 		default:        return 0;
 	}
 }
--- a/src/newgrf_sound.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_sound.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file newgrf_sound.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "oldpool.h"
--- a/src/newgrf_sound.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_sound.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file newgrf_sound.h */
+
 #ifndef NEWGRF_SOUND_H
 #define NEWGRF_SOUND_H
 
--- a/src/newgrf_spritegroup.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_spritegroup.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,9 +1,12 @@
 /* $Id$ */
 
+/** @file newgrf_spritegroup.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "variables.h"
 #include "macros.h"
+#include "landscape.h"
 #include "oldpool.h"
 #include "newgrf_callbacks.h"
 #include "newgrf_spritegroup.h"
@@ -91,7 +94,7 @@
 		case 0x1A: return UINT_MAX;
 		case 0x1B: return GB(_display_opt, 0, 6);
 		case 0x1C: return object->last_value;
-		case 0x20: return _opt.landscape == LT_HILLY ? _opt.snow_line : 0xFF;
+		case 0x20: return _opt.landscape == LT_ARCTIC ? GetSnowLine() : 0xFF;
 
 		/* Not a common variable, so evalute the feature specific variables */
 		default: return object->GetVariable(object, variable, parameter, available);
--- a/src/newgrf_spritegroup.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_spritegroup.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file newgrf_spritegroup.h */
+
 #ifndef NEWGRF_SPRITEGROUP_H
 #define NEWGRF_SPRITEGROUP_H
 
@@ -11,12 +13,12 @@
 /* 'Real' sprite groups contain a list of other result or callback sprite
  * groups. */
 struct RealSpriteGroup {
-	// Loaded = in motion, loading = not moving
-	// Each group contains several spritesets, for various loading stages
+	/* Loaded = in motion, loading = not moving
+	 * Each group contains several spritesets, for various loading stages */
 
-	// XXX: For stations the meaning is different - loaded is for stations
-	// with small amount of cargo whilst loading is for stations with a lot
-	// of da stuff.
+	/* XXX: For stations the meaning is different - loaded is for stations
+	 * with small amount of cargo whilst loading is for stations with a lot
+	 * of da stuff. */
 
 	byte num_loaded;       ///< Number of loaded groups
 	byte num_loading;      ///< Number of loading groups
@@ -27,7 +29,7 @@
 /* Shared by deterministic and random groups. */
 enum VarSpriteGroupScope {
 	VSG_SCOPE_SELF,
-	// Engine of consists for vehicles, city for stations.
+	/* Engine of consists for vehicles, city for stations. */
 	VSG_SCOPE_PARENT,
 };
 
@@ -44,20 +46,20 @@
 };
 
 enum DeterministicSpriteGroupAdjustOperation {
-	DSGA_OP_ADD,  // a + b
-	DSGA_OP_SUB,  // a - b
-	DSGA_OP_SMIN, // (signed) min(a, b)
-	DSGA_OP_SMAX, // (signed) max(a, b)
-	DSGA_OP_UMIN, // (unsigned) min(a, b)
-	DSGA_OP_UMAX, // (unsigned) max(a, b)
-	DSGA_OP_SDIV, // (signed) a / b
-	DSGA_OP_SMOD, // (signed) a % b
-	DSGA_OP_UDIV, // (unsigned) a / b
-	DSGA_OP_UMOD, // (unsigned) a & b
-	DSGA_OP_MUL,  // a * b
-	DSGA_OP_AND,  // a & b
-	DSGA_OP_OR,   // a | b
-	DSGA_OP_XOR,  // a ^ b
+	DSGA_OP_ADD,  ///< a + b
+	DSGA_OP_SUB,  ///< a - b
+	DSGA_OP_SMIN, ///< (signed) min(a, b)
+	DSGA_OP_SMAX, ///< (signed) max(a, b)
+	DSGA_OP_UMIN, ///< (unsigned) min(a, b)
+	DSGA_OP_UMAX, ///< (unsigned) max(a, b)
+	DSGA_OP_SDIV, ///< (signed) a / b
+	DSGA_OP_SMOD, ///< (signed) a % b
+	DSGA_OP_UDIV, ///< (unsigned) a / b
+	DSGA_OP_UMOD, ///< (unsigned) a & b
+	DSGA_OP_MUL,  ///< a * b
+	DSGA_OP_AND,  ///< a & b
+	DSGA_OP_OR,   ///< a | b
+	DSGA_OP_XOR,  ///< a ^ b
 };
 
 
@@ -89,7 +91,7 @@
 	DeterministicSpriteGroupAdjust *adjusts;
 	DeterministicSpriteGroupRange *ranges; // Dynamically allocated
 
-	// Dynamically allocated, this is the sole owner
+	/* Dynamically allocated, this is the sole owner */
 	const SpriteGroup *default_group;
 };
 
@@ -99,19 +101,15 @@
 };
 
 struct RandomizedSpriteGroup {
-	// Take this object:
-	VarSpriteGroupScope var_scope;
+	VarSpriteGroupScope var_scope;  ///< Take this object:
 
-	// Check for these triggers:
-	RandomizedSpriteGroupCompareMode cmp_mode;
+	RandomizedSpriteGroupCompareMode cmp_mode; ///< Check for these triggers:
 	byte triggers;
 
-	// Look for this in the per-object randomized bitmask:
-	byte lowest_randbit;
-	byte num_groups; // must be power of 2
+	byte lowest_randbit; ///< Look for this in the per-object randomized bitmask:
+	byte num_groups; ///< must be power of 2
 
-	// Take the group with appropriate index:
-	const SpriteGroup **groups;
+	const SpriteGroup **groups; ///< Take the group with appropriate index:
 };
 
 
@@ -130,7 +128,7 @@
 };
 
 struct TileLayoutSpriteGroup {
-	byte num_sprites; /* Number of sprites in the spriteset, used for loading stages */
+	byte num_sprites; ///< Number of sprites in the spriteset, used for loading stages
 	struct DrawTileSprites *dts;
 };
 
@@ -193,6 +191,9 @@
 			Town *town;
 			HouseID house_id;
 		} house;
+		struct {
+			const struct CargoSpec *cs;
+		} cargo;
 	} u;
 
 	uint32 (*GetRandomBits)(const struct ResolverObject*);
--- a/src/newgrf_station.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_station.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -6,6 +6,7 @@
 #include "openttd.h"
 #include "variables.h"
 #include "functions.h"
+#include "landscape.h"
 #include "debug.h"
 #include "sprite.h"
 #include "table/sprites.h"
@@ -19,6 +20,8 @@
 #include "date.h"
 #include "helpers.hpp"
 #include "cargotype.h"
+#include "town_map.h"
+#include "newgrf_town.h"
 
 static StationClass station_classes[STAT_CLASS_MAX];
 
@@ -42,7 +45,7 @@
 		station_classes[i].spec = NULL;
 	}
 
-	// Set up initial data
+	/* Set up initial data */
 	station_classes[0].id = 'DFLT';
 	station_classes[0].name = STR_STAT_CLASS_DFLT;
 	station_classes[0].stations = 1;
@@ -65,10 +68,10 @@
 {
 	for (StationClassID i = STAT_CLASS_BEGIN; i < STAT_CLASS_MAX; i++) {
 		if (station_classes[i].id == cls) {
-			// ClassID is already allocated, so reuse it.
+			/* ClassID is already allocated, so reuse it. */
 			return i;
 		} else if (station_classes[i].id == 0) {
-			// This class is empty, so allocate it to the ClassID.
+			/* This class is empty, so allocate it to the ClassID. */
 			station_classes[i].id = cls;
 			return i;
 		}
@@ -167,8 +170,8 @@
 	if (station < station_classes[sclass].stations)
 		return station_classes[sclass].spec[station];
 
-	// If the custom station isn't defined any more, then the GRF file
-	// probably was not loaded.
+	/* If the custom station isn't defined any more, then the GRF file
+	 * probably was not loaded. */
 	return NULL;
 }
 
@@ -347,6 +350,22 @@
 	const Station *st = object->u.station.st;
 	TileIndex tile = object->u.station.tile;
 
+	if (object->scope == VSG_SCOPE_PARENT) {
+		/* Pass the request on to the town of the station */
+		Town *t;
+
+		if (st != NULL) {
+			t = st->town;
+		} else if (tile != INVALID_TILE) {
+			t = GetTownByTile(tile);
+		} else {
+			*available = false;
+			return UINT_MAX;
+		}
+
+		return TownGetVariable(variable, parameter, available, t);
+	}
+
 	if (st == NULL) {
 		/* Station does not exist, so we're in a purchase list */
 		switch (variable) {
@@ -354,11 +373,11 @@
 			case 0x41:
 			case 0x46:
 			case 0x47:
-			case 0x49: return 0x2110000;       /* Platforms, tracks & position */
-			case 0x42: return 0;               /* Rail type (XXX Get current type from GUI?) */
-			case 0x43: return _current_player; /* Station owner */
-			case 0x44: return 2;               /* PBS status */
-			case 0xFA: return max(_date - DAYS_TILL_ORIGINAL_BASE_YEAR, 0); /* Build date */
+			case 0x49: return 0x2110000;       // Platforms, tracks & position
+			case 0x42: return 0;               // Rail type (XXX Get current type from GUI?)
+			case 0x43: return _current_player; // Station owner
+			case 0x44: return 2;               // PBS status
+			case 0xFA: return max(_date - DAYS_TILL_ORIGINAL_BASE_YEAR, 0); // Build date
 		}
 
 		*available = false;
@@ -369,16 +388,16 @@
 		/* Calculated station variables */
 		case 0x40: return GetPlatformInfoHelper(tile, false, false, false);
 		case 0x41: return GetPlatformInfoHelper(tile, true,  false, false);
-		case 0x42: /* Terrain and rail type */
-			return ((_opt.landscape == LT_HILLY && GetTileZ(tile) > _opt.snow_line) ? 4 : 0) |
-			       (_opt.landscape == LT_DESERT ? GetTropicZone(tile) : 0) |
+		case 0x42: // Terrain and rail type
+			return ((_opt.landscape == LT_ARCTIC && GetTileZ(tile) > GetSnowLine()) ? 4 : 0) |
+			       (_opt.landscape == LT_TROPIC ? GetTropicZone(tile) : 0) |
 			       (GetRailType(tile) << 8);
-		case 0x43: return st->owner; /* Station owner */
-		case 0x44: return 2;         /* PBS status */
+		case 0x43: return st->owner; // Station owner
+		case 0x44: return 2;         // PBS status
 		case 0x45: return GetRailContinuationInfo(tile);
 		case 0x46: return GetPlatformInfoHelper(tile, false, false, true);
 		case 0x47: return GetPlatformInfoHelper(tile, true,  false, true);
-		case 0x48: { /* Accepted cargo types */
+		case 0x48: { // Accepted cargo types
 			CargoID cargo_type;
 			uint32 value = 0;
 
@@ -556,7 +575,7 @@
 	ResolverObject object;
 
 	NewStationResolver(&object, statspec, st, tile);
-	object.callback_param1 = 1; /* Indicate we are resolving the ground sprite */
+	object.callback_param1 = 1; // Indicate we are resolving the ground sprite
 
 	group = ResolveStation(&object);
 	if (group == NULL || group->type != SGT_RESULT) return 0;
--- a/src/newgrf_text.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_text.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,6 +1,6 @@
 /* $Id$ */
 
-/** @file
+/** @file newgrf_text.cpp
  * Implementation of  Action 04 "universal holder" structure and functions.
  * This file implements a linked-lists of strings,
  * holding everything that the newgrf action 04 will send over to OpenTTD.
@@ -122,7 +122,7 @@
 	{"sv_SE", GRFLX_SWEDISH},
 	{"tr_TR", GRFLX_TURKISH},
 	{"uk_UA", GRFLX_UKRAINIAN},
-	{"gen",   GRFLB_GENERIC}   //this is not iso code, but there has to be something...
+	{"gen",   GRFLB_GENERIC}   ///< this is not iso code, but there has to be something...
 };
 
 
@@ -180,12 +180,12 @@
 
 static uint _num_grf_texts = 0;
 static GRFTextEntry _grf_text[(1 << TABSIZE) * 3];
-static byte _currentLangID = GRFLX_ENGLISH;  //by default, english is used.
+static byte _currentLangID = GRFLX_ENGLISH;  ///< by default, english is used.
 
 
 char *TranslateTTDPatchCodes(const char *str)
 {
-	char *tmp = MallocT<char>(strlen(str) * 10 + 1); /* Allocate space to allow for expansion */
+	char *tmp = MallocT<char>(strlen(str) * 10 + 1); // Allocate space to allow for expansion
 	char *d = tmp;
 	bool unicode = false;
 	WChar c;
@@ -198,7 +198,7 @@
 	}
 
 	for (;;) {
-		const char *tmp = str; /* Used for UTF-8 decoding */
+		const char *tmp = str; // Used for UTF-8 decoding
 
 		c = (byte)*str++;
 		if (c == 0) break;
--- a/src/newgrf_text.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/newgrf_text.h	Thu Apr 19 14:43:25 2007 +0000
@@ -2,7 +2,7 @@
 #ifndef NEWGRF_TEXT_H
 #define NEWGRF_TEXT_H
 
-/** @file
+/** @file newgrf_text.h
  * Header of Action 04 "universal holder" structure and functions
  */
 
--- a/src/news.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/news.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file news.h */
+
 #ifndef NEWS_H
 #define NEWS_H
 
--- a/src/news_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/news_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -64,14 +64,14 @@
 StringID GetNewsStringBankrupcy(const NewsItem *ni);
 
 static DrawNewsCallbackProc * const _draw_news_callback[] = {
-	DrawNewsNewVehicleAvail,  /* DNC_VEHICLEAVAIL */
-	DrawNewsBankrupcy,        /* DNC_BANKRUPCY */
+	DrawNewsNewVehicleAvail,  //< DNC_VEHICLEAVAIL
+	DrawNewsBankrupcy,        //< DNC_BANKRUPCY
 };
 
 extern GetNewsStringCallbackProc * const _get_news_string_callback[];
 GetNewsStringCallbackProc * const _get_news_string_callback[] = {
-	GetNewsStringNewVehicleAvail,  /* DNC_VEHICLEAVAIL */
-	GetNewsStringBankrupcy,        /* DNC_BANKRUPCY */
+	GetNewsStringNewVehicleAvail,  ///< DNC_VEHICLEAVAIL
+	GetNewsStringBankrupcy,        ///< DNC_BANKRUPCY
 };
 
 void InitNewsItemStructs()
@@ -104,7 +104,7 @@
 static void NewsWindowProc(Window *w, WindowEvent *e)
 {
 	switch (e->event) {
-	case WE_CREATE: { /* If chatbar is open at creation time, we need to go above it */
+	case WE_CREATE: { // If chatbar is open at creation time, we need to go above it
 		const Window *w1 = FindWindowById(WC_SEND_NETWORK_MSG, 0);
 		w->message.msg = (w1 != NULL) ? w1->height : 0;
 	} break;
@@ -189,20 +189,20 @@
 
 	case WE_KEYPRESS:
 		if (e->we.keypress.keycode == WKC_SPACE) {
-			// Don't continue.
+			/* Don't continue. */
 			e->we.keypress.cont = false;
 			DeleteWindow(w);
 		}
 		break;
 
-	case WE_MESSAGE: /* The chatbar has notified us that is was either created or closed */
+	case WE_MESSAGE: // The chatbar has notified us that is was either created or closed
 		switch (e->we.message.msg) {
 			case WE_CREATE: w->message.msg = e->we.message.wparam; break;
 			case WE_DESTROY: w->message.msg = 0; break;
 		}
 		break;
 
-	case WE_TICK: { /* Scroll up newsmessages from the bottom in steps of 4 pixels */
+	case WE_TICK: { // Scroll up newsmessages from the bottom in steps of 4 pixels
 		int diff;
 		int y = max(w->top - 4, _screen.height - w->height - 12 - w->message.msg);
 		if (y == w->top) return;
@@ -260,7 +260,7 @@
 
 	if (_game_mode == GM_MENU) return;
 
-	// check the rare case that the oldest (to be overwritten) news item is open
+	/* check the rare case that the oldest (to be overwritten) news item is open */
 	if (_total_news == MAX_NEWS && (_oldest_news == _current_news || _oldest_news == _forced_news))
 		MoveToNextItem();
 
@@ -281,7 +281,8 @@
 	/*DEBUG(misc, 0, "+cur %3d, old %2d, lat %3d, for %3d, tot %2d",
 	  _current_news, _oldest_news, _latest_news, _forced_news, _total_news);*/
 
-	{ /* Add news to _latest_news */
+	/* Add news to _latest_news */
+	{
 		Window *w;
 		NewsItem *ni = &_news_items[_latest_news];
 		memset(ni, 0, sizeof(*ni));
@@ -290,7 +291,7 @@
 		ni->display_mode = (byte)flags;
 		ni->flags = (byte)(flags >> 8);
 
-		// show this news message in color?
+		/* show this news message in color? */
 		if (_cur_year >= _patches.colored_news_year) ni->flags |= NF_INCOLOR;
 
 		ni->type = (byte)(flags >> 16);
@@ -405,7 +406,7 @@
 	SB(_news_display_opt, item * 2, 2, val);
 }
 
-// open up an own newspaper window for the news item
+/* open up an own newspaper window for the news item */
 static void ShowNewspaper(NewsItem *ni)
 {
 	Window *w;
@@ -455,7 +456,7 @@
 	w->flags4 |= WF_DISABLE_VP_SCROLL;
 }
 
-// show news item in the ticker
+/* show news item in the ticker */
 static void ShowTicker(const NewsItem *ni)
 {
 	Window *w;
@@ -468,8 +469,8 @@
 }
 
 
-// Are we ready to show another news item?
-// Only if nothing is in the newsticker and no newspaper is displayed
+/** Are we ready to show another news item?
+ * Only if nothing is in the newsticker and no newspaper is displayed */
 static bool ReadyForNextItem()
 {
 	const Window *w;
@@ -479,15 +480,15 @@
 	if (item >= MAX_NEWS) return true;
 	ni = &_news_items[item];
 
-	// Ticker message
-	// Check if the status bar message is still being displayed?
+	/* Ticker message
+	 * Check if the status bar message is still being displayed? */
 	w = FindWindowById(WC_STATUS_BAR, 0);
 	if (w != NULL && WP(w, const def_d).data_1 > -1280) return false;
 
-	// Newspaper message, decrement duration counter
+	/* Newspaper message, decrement duration counter */
 	if (ni->duration != 0) ni->duration--;
 
-	// neither newsticker nor newspaper are running
+	/* neither newsticker nor newspaper are running */
 	return (ni->duration == 0 || FindWindowById(WC_NEWS_WINDOW, 0) == NULL);
 }
 
@@ -496,18 +497,18 @@
 	DeleteWindowById(WC_NEWS_WINDOW, 0);
 	_forced_news = INVALID_NEWS;
 
-	// if we're not at the last item, then move on
+	/* if we're not at the last item, then move on */
 	if (_current_news != _latest_news) {
 		NewsItem *ni;
 
 		_current_news = (_current_news == INVALID_NEWS) ? _oldest_news : increaseIndex(_current_news);
 		ni = &_news_items[_current_news];
 
-		// check the date, don't show too old items
+		/* check the date, don't show too old items */
 		if (_date - _news_items_age[ni->type] > ni->date) return;
 
 		switch (GetNewsDisplayValue(ni->type)) {
-		case 0: { /* Off - show nothing only a small reminder in the status bar */
+		case 0: { // Off - show nothing only a small reminder in the status bar
 			Window *w = FindWindowById(WC_STATUS_BAR, 0);
 
 			if (w != NULL) {
@@ -517,14 +518,14 @@
 			break;
 		}
 
-		case 1: /* Summary - show ticker, but if forced big, cascade to full */
+		case 1: // Summary - show ticker, but if forced big, cascade to full
 			if (!(ni->flags & NF_FORCE_BIG)) {
 				ShowTicker(ni);
 				break;
 			}
 			/* Fallthrough */
 
-		case 2: /* Full - show newspaper*/
+		case 2: // Full - show newspaper
 			ShowNewspaper(ni);
 			break;
 		}
@@ -533,7 +534,7 @@
 
 void NewsLoop()
 {
-	// no news item yet
+	/* no news item yet */
 	if (_total_news == 0) return;
 
 	if (ReadyForNextItem()) MoveToNextItem();
@@ -544,10 +545,10 @@
 {
 	if (_total_news == 0) return;
 
-	// Delete the news window
+	/* Delete the news window */
 	DeleteWindowById(WC_NEWS_WINDOW, 0);
 
-	// setup forced news item
+	/* setup forced news item */
 	_forced_news = i;
 
 	if (_forced_news != INVALID_NEWS) {
@@ -649,7 +650,7 @@
 		show = min(_total_news, w->vscroll.cap);
 
 		for (p = w->vscroll.pos; p < w->vscroll.pos + show; p++) {
-			// get news in correct order
+			/* get news in correct order */
 			const NewsItem *ni = &_news_items[getNews(p)];
 
 			SetDParam(0, ni->date);
--- a/src/npf.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/npf.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file npf.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "bridge_map.h"
@@ -99,14 +101,14 @@
 	uint x;
 	uint y;
 
-	// we are going the aim for the x coordinate of the closest corner
-	// but if we are between those coordinates, we will aim for our own x coordinate
+	/* we are going the aim for the x coordinate of the closest corner
+	 * but if we are between those coordinates, we will aim for our own x coordinate */
 	x = clamp(TileX(tile), minx, maxx);
 
-	// same for y coordinate, see above comment
+	/* same for y coordinate, see above comment */
 	y = clamp(TileY(tile), miny, maxy);
 
-	// return the tile of our target coordinates
+	/* return the tile of our target coordinates */
 	return TileXY(x, y);
 }
 
@@ -121,7 +123,7 @@
 	TileIndex to = fstd->dest_coords;
 	uint dist;
 
-	// for train-stations, we are going to aim for the closest station tile
+	/* for train-stations, we are going to aim for the closest station tile */
 	if (as->user_data[NPF_TYPE] == TRANSPORT_RAIL && fstd->station_index != INVALID_STATION)
 		to = CalcClosestStationTile(fstd->station_index, from);
 
@@ -173,7 +175,7 @@
 		FindLengthOfTunnelResult flotr;
 		flotr = FindLengthOfTunnel(tile, ReverseDiagDir(exitdir));
 		return flotr.length * NPF_TILE_LENGTH;
-		//TODO: Penalty for tunnels?
+		/* @todo: Penalty for tunnels? */
 	} else {
 		/* We are entering the tunnel, the enter tile is just a
 		 * straight track */
@@ -244,19 +246,19 @@
 
 static int32 NPFWaterPathCost(AyStar* as, AyStarNode* current, OpenListNode* parent)
 {
-	//TileIndex tile = current->tile;
+	/* TileIndex tile = current->tile; */
 	int32 cost = 0;
 	Trackdir trackdir = (Trackdir)current->direction;
 
-	cost = _trackdir_length[trackdir]; /* Should be different for diagonal tracks */
+	cost = _trackdir_length[trackdir]; // Should be different for diagonal tracks
 
 	if (IsBuoyTile(current->tile) && IsDiagonalTrackdir(trackdir))
-		cost += _patches.npf_buoy_penalty; /* A small penalty for going over buoys */
+		cost += _patches.npf_buoy_penalty; // A small penalty for going over buoys
 
 	if (current->direction != NextTrackdir((Trackdir)parent->path.node.direction))
 		cost += _patches.npf_water_curve_penalty;
 
-	/* TODO More penalties? */
+	/* @todo More penalties? */
 
 	return cost;
 }
@@ -385,8 +387,8 @@
 	/* Check for turns */
 	if (current->direction != NextTrackdir((Trackdir)parent->path.node.direction))
 		cost += _patches.npf_rail_curve_penalty;
-	//TODO, with realistic acceleration, also the amount of straight track between
-	//      curves should be taken into account, as this affects the speed limit.
+	/*TODO, with realistic acceleration, also the amount of straight track between
+	 *      curves should be taken into account, as this affects the speed limit. */
 
 	/* Check for reverse in depot */
 	if (IsTileDepotType(tile, TRANSPORT_RAIL) && as->EndNodeCheck(as, &new_node) != AYSTAR_FOUND_END_NODE) {
@@ -484,7 +486,7 @@
 			break;
 	}
 
-	return true; /* no need to check */
+	return true; // no need to check
 }
 
 
@@ -544,7 +546,7 @@
 		/* Find out the exit direction first */
 		if (IsRoadStopTile(src_tile)) {
 			exitdir = GetRoadStopDir(src_tile);
-		} else { /* Train or road depot */
+		} else { // Train or road depot
 			exitdir = GetDepotDirection(src_tile, type);
 		}
 
@@ -610,7 +612,7 @@
 		DiagDirection exitdir;
 		if (IsRoadStopTile(dst_tile)) {
 			exitdir = GetRoadStopDir(dst_tile);
-		} else { /* Road or train depot */
+		} else { // Road or train depot
 			exitdir = GetDepotDirection(dst_tile, type);
 		}
 		/* Find the trackdirs that are available for a depot or station with this
@@ -640,7 +642,7 @@
 		/* Check for oneway signal against us */
 		if (IsTileType(dst_tile, MP_RAILWAY) && GetRailTileType(dst_tile) == RAIL_TILE_SIGNALS) {
 			if (HasSignalOnTrackdir(dst_tile, ReverseTrackdir(dst_trackdir)) && !HasSignalOnTrackdir(dst_tile, dst_trackdir))
-				// if one way signal not pointing towards us, stop going in this direction.
+				/* if one way signal not pointing towards us, stop going in this direction. */
 				break;
 		}
 		{
--- a/src/npf.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/npf.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file npf.h */
+
 #ifndef NPF_H
 #define NPF_H
 
@@ -9,9 +11,9 @@
 #include "vehicle.h"
 #include "tile.h"
 
-//mowing grass
+/* mowing grass */
 enum {
-	NPF_HASH_BITS = 12, /* The size of the hash used in pathfinding. Just changing this value should be sufficient to change the hash size. Should be an even value. */
+	NPF_HASH_BITS = 12, ///< The size of the hash used in pathfinding. Just changing this value should be sufficient to change the hash size. Should be an even value.
 	/* Do no change below values */
 	NPF_HASH_SIZE = 1 << NPF_HASH_BITS,
 	NPF_HASH_HALFBITS = NPF_HASH_BITS / 2,
@@ -35,33 +37,38 @@
 	NPF_INFINITE_PENALTY = 1000 * NPF_TILE_LENGTH
 };
 
-struct NPFFindStationOrTileData { /* Meant to be stored in AyStar.targetdata */
-	TileIndex dest_coords; /* An indication of where the station is, for heuristic purposes, or the target tile */
-	StationID station_index; /* station index we're heading for, or INVALID_STATION when we're heading for a tile */
+/* Meant to be stored in AyStar.targetdata */
+struct NPFFindStationOrTileData {
+	TileIndex dest_coords;   ///< An indication of where the station is, for heuristic purposes, or the target tile
+	StationID station_index; ///< station index we're heading for, or INVALID_STATION when we're heading for a tile
 };
 
-enum { /* Indices into AyStar.userdata[] */
-	NPF_TYPE = 0, /* Contains a TransportTypes value */
-	NPF_OWNER, /* Contains an Owner value */
-	NPF_RAILTYPES, /* Contains a bitmask the compatible RailTypes of the engine when NPF_TYPE == TRANSPORT_RAIL. Unused otherwise. */
+/* Indices into AyStar.userdata[] */
+enum {
+	NPF_TYPE = 0,  ///< Contains a TransportTypes value
+	NPF_OWNER,     ///< Contains an Owner value
+	NPF_RAILTYPES, ///< Contains a bitmask the compatible RailTypes of the engine when NPF_TYPE == TRANSPORT_RAIL. Unused otherwise.
 };
 
-enum { /* Indices into AyStarNode.userdata[] */
-	NPF_TRACKDIR_CHOICE = 0, /* The trackdir chosen to get here */
+/* Indices into AyStarNode.userdata[] */
+enum {
+	NPF_TRACKDIR_CHOICE = 0, ///< The trackdir chosen to get here
 	NPF_NODE_FLAGS,
 };
 
-enum NPFNodeFlag { /* Flags for AyStarNode.userdata[NPF_NODE_FLAGS]. Use NPFGetBit() and NPFGetBit() to use them. */
-	NPF_FLAG_SEEN_SIGNAL, /* Used to mark that a signal was seen on the way, for rail only */
-	NPF_FLAG_REVERSE, /* Used to mark that this node was reached from the second start node, if applicable */
-	NPF_FLAG_LAST_SIGNAL_RED, /* Used to mark that the last signal on this path was red */
+/* Flags for AyStarNode.userdata[NPF_NODE_FLAGS]. Use NPFGetBit() and NPFGetBit() to use them. */
+enum NPFNodeFlag {
+	NPF_FLAG_SEEN_SIGNAL,     ///< Used to mark that a signal was seen on the way, for rail only
+	NPF_FLAG_REVERSE,         ///< Used to mark that this node was reached from the second start node, if applicable
+	NPF_FLAG_LAST_SIGNAL_RED, ///< Used to mark that the last signal on this path was red
 };
 
-struct NPFFoundTargetData { /* Meant to be stored in AyStar.userpath */
-	uint best_bird_dist; /* The best heuristic found. Is 0 if the target was found */
-	uint best_path_dist; /* The shortest path. Is (uint)-1 if no path is found */
-	Trackdir best_trackdir; /* The trackdir that leads to the shortest path/closest birds dist */
-	AyStarNode node; /* The node within the target the search led us to */
+/* Meant to be stored in AyStar.userpath */
+struct NPFFoundTargetData {
+	uint best_bird_dist;    ///< The best heuristic found. Is 0 if the target was found
+	uint best_path_dist;    ///< The shortest path. Is (uint)-1 if no path is found
+	Trackdir best_trackdir; ///< The trackdir that leads to the shortest path/closest birds dist
+	AyStarNode node;        ///< The node within the target the search led us to
 };
 
 /* These functions below are _not_ re-entrant, in favor of speed! */
--- a/src/oldloader.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/oldloader.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file oldloader.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "station_map.h"
@@ -416,11 +418,11 @@
 	OCL_SVAR( OC_UINT16, Town, townnametype ),
 	OCL_SVAR( OC_UINT32, Town, townnameparts ),
 	OCL_SVAR(  OC_UINT8, Town, grow_counter ),
-	OCL_NULL( 1 ),         // sort_index,        no longer in use
-	OCL_NULL( 4 ),         // sign-coordinates,  no longer in use
-	OCL_NULL( 2 ),         // namewidth,         no longer in use
+	OCL_NULL( 1 ),         ///< sort_index,        no longer in use
+	OCL_NULL( 4 ),         ///< sign-coordinates,  no longer in use
+	OCL_NULL( 2 ),         ///< namewidth,         no longer in use
 	OCL_SVAR( OC_UINT16, Town, flags12 ),
-	OCL_NULL( 10 ),        // radius,            no longer in use
+	OCL_NULL( 10 ),        ///< radius,            no longer in use
 
 	OCL_SVAR( OC_UINT16, Town, ratings[0] ),
 	OCL_SVAR( OC_UINT16, Town, ratings[1] ),
@@ -459,7 +461,7 @@
 	OCL_SVAR(  OC_UINT8, Town, road_build_months ),
 	OCL_SVAR(  OC_UINT8, Town, fund_buildings_months ),
 
-	OCL_NULL( 8 ),         // some junk at the end of the record
+	OCL_NULL( 8 ),         ///< some junk at the end of the record
 
 	OCL_END()
 };
@@ -540,7 +542,7 @@
 	OCL_VAR (  OC_INT32,   1, &_old_price ),
 	OCL_VAR ( OC_UINT16,   1, &_old_price_frac ),
 
-	OCL_NULL( 2 ),         // Junk
+	OCL_NULL( 2 ),         ///< Junk
 	OCL_END()
 };
 
@@ -579,19 +581,19 @@
 	OCL_SVAR(   OC_TILE, Station, xy ),
 	OCL_VAR ( OC_UINT32,   1, &_old_town_index ),
 
-	OCL_NULL( 4 ), // bus/lorry tile
+	OCL_NULL( 4 ), ///< bus/lorry tile
 	OCL_SVAR(   OC_TILE, Station, train_tile ),
 	OCL_SVAR(   OC_TILE, Station, airport_tile ),
 	OCL_SVAR(   OC_TILE, Station, dock_tile ),
 
 	OCL_VAR (  OC_UINT8,   1, &_old_platforms ),
 
-	OCL_NULL( 1 ),         // sort-index, no longer in use
-	OCL_NULL( 2 ),         // sign-width, no longer in use
+	OCL_NULL( 1 ),         ///< sort-index, no longer in use
+	OCL_NULL( 2 ),         ///< sign-width, no longer in use
 
 	OCL_VAR ( OC_UINT16,   1, &_old_string_id ),
 
-	OCL_NULL( 4 ),         // sign left/top, no longer in use
+	OCL_NULL( 4 ),         ///< sign left/top, no longer in use
 
 	OCL_SVAR( OC_UINT16, Station, had_vehicle_of_type ),
 
@@ -609,9 +611,9 @@
 	 */
 	OCL_NULL( 4 ),
 	OCL_SVAR( OC_FILE_U16 | OC_VAR_U32, Station, airport_flags ),
-	OCL_NULL( 2 ),         // last_vehicle. now last_vehicle_type
+	OCL_NULL( 2 ),         ///< last_vehicle. now last_vehicle_type
 
-	OCL_NULL( 4 ),         // Junk at end of chunk
+	OCL_NULL( 4 ),         ///< Junk at end of chunk
 
 	OCL_END()
 };
@@ -684,7 +686,7 @@
 	OCL_SVAR( OC_UINT16, Industry, counter ),
 	OCL_SVAR(  OC_UINT8, Industry, was_cargo_delivered ),
 
-	OCL_NULL( 9 ), // Random junk at the end of this chunk
+	OCL_NULL( 9 ), ///< Random junk at the end of this chunk
 
 	OCL_END()
 };
@@ -771,7 +773,7 @@
 	OCL_SVAR(  OC_UINT8, AiBuildRec, direction ),
 	OCL_SVAR(  OC_UINT8, AiBuildRec, cargo ),
 
-	OCL_NULL( 8 ),  // Junk...
+	OCL_NULL( 8 ),  ///< Junk...
 
 	OCL_END()
 };
@@ -791,14 +793,14 @@
 }
 static const OldChunks player_ai_chunk[] = {
 	OCL_SVAR(  OC_UINT8, PlayerAI, state ),
-	OCL_NULL( 1 ),         // Junk
+	OCL_NULL( 1 ),         ///< Junk
 	OCL_SVAR(  OC_UINT8, PlayerAI, state_mode ),
 	OCL_SVAR( OC_UINT16, PlayerAI, state_counter ),
 	OCL_SVAR( OC_UINT16, PlayerAI, timeout_counter ),
 
 	OCL_CHUNK( 4, OldLoadAIBuildRec ),
 
-	OCL_NULL( 20 ),        // More junk
+	OCL_NULL( 20 ),        ///< More junk
 
 	OCL_SVAR(  OC_UINT8, PlayerAI, cargo_type ),
 	OCL_SVAR(  OC_UINT8, PlayerAI, num_wagons ),
@@ -807,9 +809,9 @@
 	OCL_SVAR(  OC_UINT8, PlayerAI, num_loco_to_build ),
 	OCL_SVAR(  OC_UINT8, PlayerAI, num_want_fullload ),
 
-	OCL_NULL( 14 ),        // Oh no more junk :|
+	OCL_NULL( 14 ),        ///< Oh no more junk :|
 
-	OCL_NULL( 2 ),         // Loco-id, not used
+	OCL_NULL( 2 ),         ///< Loco-id, not used
 
 	OCL_SVAR( OC_UINT16, PlayerAI, wagon_list[0] ),
 	OCL_SVAR( OC_UINT16, PlayerAI, wagon_list[1] ),
@@ -936,7 +938,7 @@
 	OCL_SVAR(  OC_UINT8, Player, share_owners[2] ),
 	OCL_SVAR(  OC_UINT8, Player, share_owners[3] ),
 
-	OCL_NULL( 8 ), // junk at end of chunk
+	OCL_NULL( 8 ), ///< junk at end of chunk
 
 	OCL_END()
 };
@@ -998,7 +1000,7 @@
 	OCL_SVAR( OC_UINT16, VehicleRail, crash_anim_pos ),
 	OCL_SVAR(  OC_UINT8, VehicleRail, railtype ),
 
-	OCL_NULL( 5 ), // Junk
+	OCL_NULL( 5 ), ///< Junk
 
 	OCL_END()
 };
@@ -1012,7 +1014,7 @@
 	OCL_SVAR( OC_UINT16, VehicleRoad, crashed_ctr ),
 	OCL_SVAR(  OC_UINT8, VehicleRoad, reverse_ctr ),
 
-	OCL_NULL( 1 ), // Junk
+	OCL_NULL( 1 ), ///< Junk
 
 	OCL_END()
 };
@@ -1020,7 +1022,7 @@
 static const OldChunks vehicle_ship_chunk[] = {
 	OCL_SVAR(  OC_UINT8, VehicleShip, state ),
 
-	OCL_NULL( 9 ), // Junk
+	OCL_NULL( 9 ), ///< Junk
 
 	OCL_END()
 };
@@ -1031,7 +1033,7 @@
 	OCL_SVAR( OC_UINT16, VehicleAir, crashed_counter ),
 	OCL_SVAR(  OC_UINT8, VehicleAir, state ),
 
-	OCL_NULL( 5 ), // Junk
+	OCL_NULL( 5 ), ///< Junk
 
 	OCL_END()
 };
@@ -1049,13 +1051,13 @@
 	OCL_SVAR( OC_UINT16, VehicleDisaster, image_override ),
 	OCL_SVAR( OC_UINT16, VehicleDisaster, unk2 ),
 
-	OCL_NULL( 6 ), // Junk
+	OCL_NULL( 6 ), ///< Junk
 
 	OCL_END()
 };
 
 static const OldChunks vehicle_empty_chunk[] = {
-	OCL_NULL( 10 ), // Junk
+	OCL_NULL( 10 ), ///< Junk
 
 	OCL_END()
 };
@@ -1092,8 +1094,8 @@
 	OCL_SVAR(  OC_UINT8, Vehicle, type ),
 	OCL_SVAR(  OC_UINT8, Vehicle, subtype ),
 
-	OCL_NULL( 2 ),         // Hash, calculated automatically
-	OCL_NULL( 2 ),         // Index, calculated automatically
+	OCL_NULL( 2 ),         ///< Hash, calculated automatically
+	OCL_NULL( 2 ),         ///< Index, calculated automatically
 
 	OCL_VAR ( OC_UINT32,   1, &_old_order_ptr ),
 	OCL_VAR ( OC_UINT16,   1, &_old_order ),
@@ -1122,7 +1124,7 @@
 	OCL_SVAR(   OC_TILE, Vehicle, tile ),
 	OCL_SVAR( OC_UINT16, Vehicle, cur_image ),
 
-	OCL_NULL( 8 ),        // Vehicle sprite box, calculated automatically
+	OCL_NULL( 8 ),        ///< Vehicle sprite box, calculated automatically
 
 	OCL_SVAR( OC_FILE_U16 | OC_VAR_U8, Vehicle, vehstatus ),
 	OCL_SVAR( OC_UINT16, Vehicle, cur_speed ),
@@ -1165,7 +1167,7 @@
 
 	OCL_CHUNK( 1, LoadOldVehicleUnion ),
 
-	OCL_NULL( 20 ), // Junk at end of struct (TTDPatch has some data in it)
+	OCL_NULL( 20 ), ///< Junk at end of struct (TTDPatch has some data in it)
 
 	OCL_END()
 };
@@ -1223,7 +1225,7 @@
 	OCL_SVAR( OC_FILE_U16 | OC_VAR_I32,Sign, y ),
 	OCL_SVAR( OC_FILE_U16 | OC_VAR_I8, Sign, z ),
 
-	OCL_NULL( 6 ),         // Width of sign, no longer in use
+	OCL_NULL( 6 ),         ///< Width of sign, no longer in use
 
 	OCL_END()
 };
@@ -1254,7 +1256,7 @@
 	OCL_SVAR(  OC_UINT8, Engine, preview_player ),
 	OCL_SVAR(  OC_UINT8, Engine, preview_wait ),
 
-	OCL_NULL( 2 ), // Junk
+	OCL_NULL( 2 ), ///< Junk
 
 	OCL_END()
 };
@@ -1387,7 +1389,8 @@
 				AppendStaticGRFConfigs(&_grfconfig);
 			} break;
 
-			case 0x3: { /* TTDPatch version and configuration */
+			/* TTDPatch version and configuration */
+			case 0x3: {
 				uint32 ttdpv = ReadUint32(ls);
 				DEBUG(oldloader, 3, "Game saved with TTDPatch version %d.%d.%d r%d", GB(ttdpv, 24, 8), GB(ttdpv, 20, 4), GB(ttdpv, 16, 4), GB(ttdpv, 0, 16));
 				len -= 4;
@@ -1409,7 +1412,7 @@
 	OCL_ASSERT( 0 ),
 	OCL_VAR ( OC_FILE_U16 | OC_VAR_U32, 1, &_date ),
 	OCL_VAR ( OC_UINT16,   1, &_date_fract ),
-	OCL_NULL( 600 ),            // TextEffects
+	OCL_NULL( 600 ),            ///< TextEffects
 	OCL_VAR ( OC_UINT32,   2, &_random_seeds[0] ),
 
 	OCL_ASSERT( 0x264 ),
@@ -1419,14 +1422,14 @@
 	OCL_ASSERT( 0x4328 ),
 
 	OCL_VAR (   OC_TILE, 256, &_animated_tile_list[0] ),
-	OCL_NULL( 4 ),              // old end-of-order-list-pointer, no longer in use
+	OCL_NULL( 4 ),              ///< old end-of-order-list-pointer, no longer in use
 
 	OCL_CHUNK( 255, LoadOldDepot ),
 	OCL_ASSERT( 0x4B26 ),
 
 	OCL_VAR ( OC_UINT32,   1, &_old_cur_town_ctr ),
-	OCL_NULL( 2 ),              // timer_counter, no longer in use
-	OCL_NULL( 2 ),              // land_code,     no longer in use
+	OCL_NULL( 2 ),              ///< timer_counter, no longer in use
+	OCL_NULL( 2 ),              ///< land_code,     no longer in use
 
 	OCL_VAR ( OC_FILE_U16 | OC_VAR_U8, 1, &_age_cargo_skip_counter ),
 	OCL_VAR ( OC_UINT16,   1, &_tick_counter ),
@@ -1453,7 +1456,7 @@
 
 	OCL_VAR (  OC_UINT8, 32 * 500, &_name_array[0] ),
 
-	OCL_NULL( 0x2000 ),            // Old hash-table, no longer in use
+	OCL_NULL( 0x2000 ),            ///< Old hash-table, no longer in use
 
 	OCL_CHUNK( 40, LoadOldSign ),
 	OCL_CHUNK(256, LoadOldEngine ),
@@ -1473,12 +1476,12 @@
 
 	OCL_VAR ( OC_UINT16,    1, &_disaster_delay ),
 
-	OCL_NULL( 144 ),             // cargo-stuff, calculated in InitializeLandscapeVariables
+	OCL_NULL( 144 ),             ///< cargo-stuff, calculated in InitializeLandscapeVariables
 
 	OCL_VAR ( OC_UINT16,  256, &_engine_name_strings[0] ),
 
-	OCL_NULL( 144 ),             // AI cargo-stuff, calculated in InitializeLandscapeVariables
-	OCL_NULL( 2 ),               // Company indexes of players, no longer in use
+	OCL_NULL( 144 ),             ///< AI cargo-stuff, calculated in InitializeLandscapeVariables
+	OCL_NULL( 2 ),               ///< Company indexes of players, no longer in use
 
 	OCL_VAR ( OC_FILE_U8 | OC_VAR_U16,    1, &_station_tick_ctr ),
 
@@ -1486,8 +1489,8 @@
 	OCL_VAR (  OC_UINT8,    1, &_opt.units ),
 	OCL_VAR ( OC_FILE_U8 | OC_VAR_U32,    1, &_cur_player_tick_index ),
 
-	OCL_NULL( 2 ),               // Date stuff, calculated automatically
-	OCL_NULL( 8 ),               // Player colors, calculated automatically
+	OCL_NULL( 2 ),               ///< Date stuff, calculated automatically
+	OCL_NULL( 8 ),               ///< Player colors, calculated automatically
 
 	OCL_VAR (  OC_UINT8,    1, &_economy.infl_amount ),
 	OCL_VAR (  OC_UINT8,    1, &_economy.infl_amount_pr ),
@@ -1504,11 +1507,11 @@
 	OCL_VAR (  OC_UINT8,    1, &_opt.landscape ),
 	OCL_VAR (  OC_UINT8,    1, &_trees_tick_ctr ),
 
-	OCL_NULL( 1 ),               // Custom vehicle types yes/no, no longer used
+	OCL_NULL( 1 ),               ///< Custom vehicle types yes/no, no longer used
 	OCL_VAR (  OC_UINT8,    1, &_opt.snow_line ),
 
-	OCL_NULL( 32 ),              // new_industry_randtable, no longer used (because of new design)
-	OCL_NULL( 36 ),              // cargo-stuff, calculated in InitializeLandscapeVariables
+	OCL_NULL( 32 ),              ///< new_industry_randtable, no longer used (because of new design)
+	OCL_NULL( 36 ),              ///< cargo-stuff, calculated in InitializeLandscapeVariables
 
 	OCL_ASSERT( 0x77179 ),
 
--- a/src/oldpool.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/oldpool.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file oldpool.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "debug.h"
--- a/src/oldpool.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/oldpool.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file oldpool.h */
+
 #ifndef OLDPOOL_H
 #define OLDPOOL_H
 
--- a/src/openttd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/openttd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file openttd.cpp */
+
 #include "stdafx.h"
 #define VARDEF
 #include "string.h"
@@ -220,17 +222,17 @@
 md_continue_here:;
 			s++;
 			if (*s != 0) {
-				// Found argument, try to locate it in options.
+				/* Found argument, try to locate it in options. */
 				if (*s == ':' || (r = strchr(md->options, *s)) == NULL) {
-					// ERROR!
+					/* ERROR! */
 					return -2;
 				}
 				if (r[1] == ':') {
-					// Item wants an argument. Check if the argument follows, or if it comes as a separate arg.
+					/* Item wants an argument. Check if the argument follows, or if it comes as a separate arg. */
 					if (!*(t = s + 1)) {
-						// It comes as a separate arg. Check if out of args?
+						/* It comes as a separate arg. Check if out of args? */
 						if (--md->numleft < 0 || *(t = *md->argv) == '-') {
-							// Check if item is optional?
+							/* Check if item is optional? */
 							if (r[2] != ':')
 								return -2;
 							md->numleft++;
@@ -248,7 +250,7 @@
 				return *s;
 			}
 		} else {
-			// This is currently not supported.
+			/* This is currently not supported. */
 			return -2;
 		}
 	}
@@ -305,11 +307,11 @@
 	_opt_ptr = &_opt_newgame;
 	ResetGRFConfig(false);
 
-	// Setup main window
+	/* Setup main window */
 	ResetWindowSystem();
 	SetupColorsAndInitialWindow();
 
-	// Generate a world.
+	/* Generate a world. */
 	snprintf(filename, lengthof(filename), "%sopntitle.dat",  _paths.data_dir);
 #if defined SECOND_DATA_DIR
 	if (SaveOrLoad(filename, SL_LOAD) != SL_OK) {
@@ -328,7 +330,7 @@
 	_cursor.fix_at = false;
 	MarkWholeScreenDirty();
 
-	// Play main theme
+	/* Play main theme */
 	if (_music_driver->is_song_playing()) ResetMusic();
 }
 
@@ -362,10 +364,10 @@
 	_dedicated_forks = false;
 	_config_file = NULL;
 
-	// The last param of the following function means this:
-	//   a letter means: it accepts that param (e.g.: -h)
-	//   a ':' behind it means: it need a param (e.g.: -m<driver>)
-	//   a '::' behind it means: it can optional have a param (e.g.: -d<debug>)
+	/* The last param of the following function means this:
+	 *   a letter means: it accepts that param (e.g.: -h)
+	 *   a ':' behind it means: it need a param (e.g.: -m<driver>)
+	 *   a '::' behind it means: it can optional have a param (e.g.: -d<debug>) */
 	optformat = "m:s:v:hD::n::eit:d::r:g::G:c:xl:"
 #if !defined(__MORPHOS__) && !defined(__AMIGA__) && !defined(WIN32)
 		"f"
@@ -438,7 +440,7 @@
 	CheckExternalFiles();
 
 #if defined(UNIX) && !defined(__MORPHOS__)
-	// We must fork here, or we'll end up without some resources we need (like sockets)
+	/* We must fork here, or we'll end up without some resources we need (like sockets) */
 	if (_dedicated_forks)
 		DedicatedFork();
 #endif
@@ -447,7 +449,7 @@
 	CheckConfig();
 	LoadFromHighScore();
 
-	// override config?
+	/* override config? */
 	if (!StrEmpty(musicdriver)) ttd_strlcpy(_ini_musicdriver, musicdriver, sizeof(_ini_musicdriver));
 	if (!StrEmpty(sounddriver)) ttd_strlcpy(_ini_sounddriver, sounddriver, sizeof(_ini_sounddriver));
 	if (!StrEmpty(videodriver)) ttd_strlcpy(_ini_videodriver, videodriver, sizeof(_ini_videodriver));
@@ -461,13 +463,13 @@
 	if (_dedicated_forks && !dedicated) _dedicated_forks = false;
 #endif /* ENABLE_NETWORK */
 
-	// enumerate language files
+	/* enumerate language files */
 	InitializeLanguagePacks();
 
-	// initialize screenshot formats
+	/* initialize screenshot formats */
 	InitializeScreenshotFormats();
 
-	// initialize airport state machines
+	/* initialize airport state machines */
 	InitializeAirports();
 
 	/* initialize all variables that are allocated dynamically */
@@ -476,7 +478,7 @@
 	/* start the AI */
 	AI_Initialize();
 
-	// Sample catalogue
+	/* Sample catalogue */
 	DEBUG(misc, 1, "Loading sound effects...");
 	MxInitialize(11025);
 	SoundInitialize("sample.cat");
@@ -484,7 +486,7 @@
 	/* Initialize FreeType */
 	InitFreeType();
 
-	// This must be done early, since functions use the InvalidateWindow* calls
+	/* This must be done early, since functions use the InvalidateWindow* calls */
 	InitWindowSystem();
 
 	/* Initialize game palette */
@@ -496,7 +498,7 @@
 	LoadDriver(VIDEO_DRIVER, _ini_videodriver); // load video last, to prevent an empty window while sound and music loads
 	_savegame_sort_order = SORT_BY_DATE | SORT_DESCENDING;
 
-	// restore saved music volume
+	/* restore saved music volume */
 	_music_driver->set_volume(msf.music_vol);
 
 	NetworkStartUp(); // initialize network-core
@@ -530,7 +532,7 @@
 		UpdatePatches();
 	}
 
-	// initialize the ingame console
+	/* initialize the ingame console */
 	IConsoleInit();
 	_cursor.in_window = true;
 	InitializeGUI();
@@ -714,7 +716,7 @@
 {
 	_game_mode = GM_NORMAL;
 
-	// invalid type
+	/* invalid type */
 	if (_file_to_saveload.mode == SL_INVALID) {
 		DEBUG(sl, 0, "Savegame is obsolete or invalid format: '%s'", _file_to_saveload.name);
 		ShowErrorMessage(INVALID_STRING_ID, STR_4009_GAME_LOAD_FAILED, 0, 0);
@@ -722,14 +724,14 @@
 		return;
 	}
 
-	// Reinitialize windows
+	/* Reinitialize windows */
 	ResetWindowSystem();
 
 	SetupColorsAndInitialWindow();
 
 	ResetGRFConfig(true);
 
-	// Load game
+	/* Load game */
 	if (SaveOrLoad(_file_to_saveload.name, _file_to_saveload.mode) != SL_OK) {
 		LoadIntroGame();
 		ShowErrorMessage(INVALID_STRING_ID, STR_4009_GAME_LOAD_FAILED, 0, 0);
@@ -739,7 +741,7 @@
 	_opt_ptr->diff = _opt_newgame.diff;
 	_opt.diff_level = _opt_newgame.diff_level;
 
-	// Inititalize data
+	/* Inititalize data */
 	StartupEconomy();
 	StartupPlayers();
 	StartupEngines();
@@ -777,9 +779,9 @@
 void SwitchMode(int new_mode)
 {
 #ifdef ENABLE_NETWORK
-	// If we are saving something, the network stays in his current state
+	/* If we are saving something, the network stays in his current state */
 	if (new_mode != SM_SAVE) {
-		// If the network is active, make it not-active
+		/* If the network is active, make it not-active */
 		if (_networking) {
 			if (_network_server && (new_mode == SM_LOAD || new_mode == SM_NEWGAME)) {
 				NetworkReboot();
@@ -790,13 +792,13 @@
 			}
 		}
 
-		// If we are a server, we restart the server
+		/* If we are a server, we restart the server */
 		if (_is_network_server) {
-			// But not if we are going to the menu
+			/* But not if we are going to the menu */
 			if (new_mode != SM_MENU) {
 				NetworkServerStart();
 			} else {
-				// This client no longer wants to be a network-server
+				/* This client no longer wants to be a network-server */
 				_is_network_server = false;
 			}
 		}
@@ -890,7 +892,7 @@
 	case SM_GENRANDLAND: /* Generate random land within scenario editor */
 		SetLocalPlayer(OWNER_NONE);
 		GenerateWorld(GW_RANDOM, 1 << _patches.map_x, 1 << _patches.map_y);
-		// XXX: set date
+		/* XXX: set date */
 		MarkWholeScreenDirty();
 		break;
 	}
@@ -901,13 +903,13 @@
 }
 
 
-// State controlling game loop.
-// The state must not be changed from anywhere
-// but here.
-// That check is enforced in DoCommand.
+/* State controlling game loop.
+ * The state must not be changed from anywhere
+ * but here.
+ * That check is enforced in DoCommand. */
 void StateGameLoop()
 {
-	// dont execute the state loop during pause
+	/* dont execute the state loop during pause */
 	if (_pause_game) return;
 	if (IsGeneratingWorld()) return;
 
@@ -918,8 +920,8 @@
 		CallWindowTickEvent();
 		NewsLoop();
 	} else {
-		// All these actions has to be done from OWNER_NONE
-		//  for multiplayer compatibility
+		/* All these actions has to be done from OWNER_NONE
+		 *  for multiplayer compatibility */
 		PlayerID p = _current_player;
 		_current_player = OWNER_NONE;
 
@@ -958,12 +960,12 @@
 		SetDParam(2, _date);
 		s = GetString(s, STR_4004, lastof(buf));
 		strecpy(s, ".sav", lastof(buf));
-	} else { /* generate a savegame name and number according to _patches.max_num_autosaves */
+	} else { // generate a savegame name and number according to _patches.max_num_autosaves
 		snprintf(buf, lengthof(buf), "%s%sautosave%d.sav", _paths.autosave_dir, PATHSEP, _autosave_ctr);
 
 		_autosave_ctr++;
 		if (_autosave_ctr >= _patches.max_num_autosaves) {
-			// we reached the limit for numbers of autosaves. We will start over
+			/* we reached the limit for numbers of autosaves. We will start over */
 			_autosave_ctr = 0;
 		}
 	}
@@ -986,21 +988,21 @@
 
 static const int8 scrollamt[16][2] = {
 	{ 0,  0},
-	{-2,  0}, //  1 : left
-	{ 0, -2}, //  2 : up
-	{-2, -1}, //  3 : left + up
-	{ 2,  0}, //  4 : right
-	{ 0,  0}, //  5 : left + right
-	{ 2, -1}, //  6 : right + up
-	{ 0, -2}, //  7 : left + right + up = up
-	{ 0  ,2}, //  8 : down
-	{-2  ,1}, //  9 : down+left
-	{ 0,  0}, // 10 : impossible
-	{-2,  0}, // 11 : left + up + down = left
-	{ 2,  1}, // 12 : down+right
-	{ 0,  2}, // 13 : left + right + down = down
-	{ 0, -2}, // 14 : left + right + up = up
-	{ 0,  0}, // 15 : impossible
+	{-2,  0}, ///<  1 : left
+	{ 0, -2}, ///<  2 : up
+	{-2, -1}, ///<  3 : left + up
+	{ 2,  0}, ///<  4 : right
+	{ 0,  0}, ///<  5 : left + right
+	{ 2, -1}, ///<  6 : right + up
+	{ 0, -2}, ///<  7 : left + right + up = up
+	{ 0  ,2}, ///<  8 : down
+	{-2  ,1}, ///<  9 : down+left
+	{ 0,  0}, ///< 10 : impossible
+	{-2,  0}, ///< 11 : left + up + down = left
+	{ 2,  1}, ///< 12 : down+right
+	{ 0,  2}, ///< 13 : left + right + down = down
+	{ 0, -2}, ///< 14 : left + right + up = up
+	{ 0,  0}, ///< 15 : impossible
 };
 
 static void HandleKeyScrolling()
@@ -1017,20 +1019,20 @@
 
 	if ((message = OTTD_PollThreadEvent()) != 0) ProcessSentMessage(message);
 
-	// autosave game?
+	/* autosave game? */
 	if (_do_autosave) {
 		_do_autosave = false;
 		DoAutosave();
 		RedrawAutosave();
 	}
 
-	// handle scrolling of the main window
+	/* handle scrolling of the main window */
 	HandleKeyScrolling();
 
-	// make a screenshot?
+	/* make a screenshot? */
 	if (IsScreenshotRequested()) ShowScreenshotResult(MakeScreenshot());
 
-	// switch game mode?
+	/* switch game mode? */
 	if (_switch_mode != SM_NONE) {
 		SwitchMode(_switch_mode);
 		_switch_mode = SM_NONE;
@@ -1050,19 +1052,19 @@
 	CursorTick();
 
 #ifdef ENABLE_NETWORK
-	// Check for UDP stuff
+	/* Check for UDP stuff */
 	if (_network_available) NetworkUDPGameLoop();
 
 	if (_networking && !IsGeneratingWorld()) {
-		// Multiplayer
+		/* Multiplayer */
 		NetworkGameLoop();
 	} else {
 		if (_network_reconnect > 0 && --_network_reconnect == 0) {
-			// This means that we want to reconnect to the last host
-			// We do this here, because it means that the network is really closed
+			/* This means that we want to reconnect to the last host
+			 * We do this here, because it means that the network is really closed */
 			NetworkClientConnectGame(_network_last_host, _network_last_port);
 		}
-		// Singleplayer
+		/* Singleplayer */
 		StateGameLoop();
 	}
 #else
@@ -1110,7 +1112,7 @@
 	}
 }
 
-// before savegame version 4, the name of the company determined if it existed
+/* before savegame version 4, the name of the company determined if it existed */
 static void CheckIsPlayerActive()
 {
 	Player *p;
@@ -1120,7 +1122,7 @@
 	}
 }
 
-// since savegame version 4.1, exclusive transport rights are stored at towns
+/* since savegame version 4.1, exclusive transport rights are stored at towns */
 static void UpdateExclusiveRights()
 {
 	Town *t;
@@ -1146,7 +1148,7 @@
 	16, 22, 21,  7, 15,
 	18,  2, 20, };
 
-// since savegame version 4.2 the currencies are arranged differently
+/* since savegame version 4.2 the currencies are arranged differently */
 static void UpdateCurrencies()
 {
 	_opt.currency = convert_currency[_opt.currency];
@@ -1163,7 +1165,7 @@
 	for (i = 0; i < MapSizeX(); ++i) MakeVoid(MapSizeX() * MapMaxY() + i);
 }
 
-// since savegame version 6.0 each sign has an "owner", signs without owner (from old games are set to 255)
+/* since savegame version 6.0 each sign has an "owner", signs without owner (from old games are set to 255) */
 static void UpdateSignOwner()
 {
 	Sign *si;
@@ -1186,16 +1188,16 @@
 	ViewPort *vp;
 	Player *p;
 
-	// in version 2.1 of the savegame, town owner was unified.
+	/* in version 2.1 of the savegame, town owner was unified. */
 	if (CheckSavegameVersionOldStyle(2, 1)) ConvertTownOwner();
 
-	// from version 4.1 of the savegame, exclusive rights are stored at towns
+	/* from version 4.1 of the savegame, exclusive rights are stored at towns */
 	if (CheckSavegameVersionOldStyle(4, 1)) UpdateExclusiveRights();
 
-	// from version 4.2 of the savegame, currencies are in a different order
+	/* from version 4.2 of the savegame, currencies are in a different order */
 	if (CheckSavegameVersionOldStyle(4, 2)) UpdateCurrencies();
 
-	// from version 6.1 of the savegame, signs have an "owner"
+	/* from version 6.1 of the savegame, signs have an "owner" */
 	if (CheckSavegameVersionOldStyle(6, 1)) UpdateSignOwner();
 
 	/* In old version there seems to be a problem that water is owned by
@@ -1210,7 +1212,7 @@
 		}
 	}
 
-	// convert road side to my format.
+	/* convert road side to my format. */
 	if (_opt.road_side) _opt.road_side = 1;
 
 	/* Check if all NewGRFs are present, we are very strict in MP mode */
@@ -1227,7 +1229,7 @@
 	 * must be done before loading sprites as some newgrfs check it */
 	SetDate(_date);
 
-	// Load the sprites
+	/* Load the sprites */
 	GfxLoadSprites();
 	LoadStringWidthTable();
 
@@ -1238,33 +1240,33 @@
 	/* Connect front and rear engines of multiheaded trains */
 	ConnectMultiheadedTrains();
 
-	// reinit the landscape variables (landscape might have changed)
+	/* reinit the landscape variables (landscape might have changed) */
 	InitializeLandscapeVariables(true);
 
-	// Update all vehicles
+	/* Update all vehicles */
 	AfterLoadVehicles();
 
-	// Update all waypoints
+	/* Update all waypoints */
 	if (CheckSavegameVersion(12)) FixOldWaypoints();
 
 	UpdateAllWaypointSigns();
 
-	// in version 2.2 of the savegame, we have new airports
+	/* in version 2.2 of the savegame, we have new airports */
 	if (CheckSavegameVersionOldStyle(2, 2)) UpdateOldAircraft();
 
 	UpdateAllStationVirtCoord();
 
-	// Setup town coords
+	/* Setup town coords */
 	AfterLoadTown();
 	UpdateAllSignVirtCoords();
 
-	// make sure there is a town in the game
+	/* make sure there is a town in the game */
 	if (_game_mode == GM_NORMAL && !ClosestTownFromTile(0, (uint)-1)) {
 		_error_message = STR_NO_TOWN_IN_SCENARIO;
 		return false;
 	}
 
-	// Initialize windows
+	/* Initialize windows */
 	ResetWindowSystem();
 	SetupColorsAndInitialWindow();
 
@@ -1278,17 +1280,17 @@
 	vp->virtual_width = vp->width << vp->zoom;
 	vp->virtual_height = vp->height << vp->zoom;
 
-	// in version 4.1 of the savegame, is_active was introduced to determine
-	// if a player does exist, rather then checking name_1
+	/* in version 4.1 of the savegame, is_active was introduced to determine
+	 * if a player does exist, rather then checking name_1 */
 	if (CheckSavegameVersionOldStyle(4, 1)) CheckIsPlayerActive();
 
-	// the void tiles on the southern border used to belong to a wrong class (pre 4.3).
+	/* the void tiles on the southern border used to belong to a wrong class (pre 4.3). */
 	if (CheckSavegameVersionOldStyle(4, 3)) UpdateVoidTiles();
 
-	// If Load Scenario / New (Scenario) Game is used,
-	//  a player does not exist yet. So create one here.
-	// 1 exeption: network-games. Those can have 0 players
-	//   But this exeption is not true for network_servers!
+	/* If Load Scenario / New (Scenario) Game is used,
+	 *  a player does not exist yet. So create one here.
+	 * 1 exeption: network-games. Those can have 0 players
+	 *   But this exeption is not true for network_servers! */
 	if (!_players[0].is_active && (!_networking || (_networking && _network_server)))
 		DoStartupNewPlayer(false);
 
@@ -1584,15 +1586,15 @@
 					wp->grfid = statspec->grfid;
 					wp->localidx = statspec->localidx;
 				} else {
-					// No custom graphics set, so set to default.
+					/* No custom graphics set, so set to default. */
 					wp->stat_id = 0;
 					wp->grfid = 0;
 					wp->localidx = 0;
 				}
 
-				// Move ground type bits from m2 to m4.
+				/* Move ground type bits from m2 to m4. */
 				_m[wp->xy].m4 = GB(_m[wp->xy].m2, 0, 4);
-				// Store waypoint index in the tile.
+				/* Store waypoint index in the tile. */
 				_m[wp->xy].m2 = wp->index;
 			}
 		}
@@ -1609,15 +1611,15 @@
 			switch (GetTileType(t)) {
 				case MP_RAILWAY:
 					if (HasSignals(t)) {
-						// convert PBS signals to combo-signals
+						/* convert PBS signals to combo-signals */
 						if (HASBIT(_m[t].m2, 2)) SetSignalType(t, SIGTYPE_COMBO);
 
-						// move the signal variant back
+						/* move the signal variant back */
 						SetSignalVariant(t, HASBIT(_m[t].m2, 3) ? SIG_SEMAPHORE : SIG_ELECTRIC);
 						CLRBIT(_m[t].m2, 3);
 					}
 
-					// Clear PBS reservation on track
+					/* Clear PBS reservation on track */
 					if (!IsTileDepotType(t, TRANSPORT_RAIL)) {
 						SB(_m[t].m4, 4, 4, 0);
 					} else {
@@ -1625,13 +1627,11 @@
 					}
 					break;
 
-				case MP_STREET:
-					// Clear PBS reservation on crossing
+				case MP_STREET: /* Clear PBS reservation on crossing */
 					if (IsLevelCrossing(t)) CLRBIT(_m[t].m5, 0);
 					break;
 
-				case MP_STATION:
-					// Clear PBS reservation on station
+				case MP_STATION: /* Clear PBS reservation on station */
 					CLRBIT(_m[t].m3, 6);
 					break;
 
--- a/src/openttd.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/openttd.h	Thu Apr 19 14:43:25 2007 +0000
@@ -183,10 +183,10 @@
 
 /* Landscape types */
 enum {
-	LT_NORMAL     = 0,
-	LT_HILLY      = 1,
-	LT_DESERT     = 2,
-	LT_CANDY      = 3,
+	LT_TEMPERATE  = 0,
+	LT_ARCTIC     = 1,
+	LT_TROPIC     = 2,
+	LT_TOYLAND    = 3,
 
 	NUM_LANDSCAPE = 4,
 };
--- a/src/order_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/order_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file order_cmd.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "order.h"
@@ -455,6 +457,24 @@
 	return 0;
 }
 
+/**
+ * Remove the VehicleList that shows all the vehicles with the same shared
+ *  orders.
+ */
+static void RemoveSharedOrderVehicleList(Vehicle *v)
+{
+	WindowClass window_class = WC_NONE;
+
+	switch (v->type) {
+		default: NOT_REACHED();
+		case VEH_TRAIN:    window_class = WC_TRAINS_LIST;   break;
+		case VEH_ROAD:     window_class = WC_ROADVEH_LIST;  break;
+		case VEH_SHIP:     window_class = WC_SHIPS_LIST;    break;
+		case VEH_AIRCRAFT: window_class = WC_AIRCRAFT_LIST; break;
+	}
+	DeleteWindowById(window_class, (v->orders->index << 16) | (v->type << 11) | VLW_SHARED_ORDERS | v->owner);
+}
+
 /** Delete an order from the orderlist of a vehicle.
  * @param tile unused
  * @param p1 the ID of the vehicle
@@ -489,6 +509,10 @@
 				order = GetVehicleOrder(v, sel_ord + 1);
 				SwapOrders(v->orders, order);
 			} else {
+				/* XXX -- The system currently can't handle a shared-order vehicle list
+				 *  open when there aren't any orders in the list, so close the window
+				 *  in this case. Of course it needs a better fix later */
+				RemoveSharedOrderVehicleList(v);
 				/* Last item, so clean the list */
 				v->orders = NULL;
 			}
@@ -1116,7 +1140,7 @@
 	/* If we have a shared order-list, don't delete the list, but just
 	    remove our pointer */
 	if (IsOrderListShared(v)) {
-		const Vehicle *u = v;
+		Vehicle *u = v;
 
 		v->orders = NULL;
 		v->num_orders = 0;
@@ -1133,6 +1157,10 @@
 		v->prev_shared = NULL;
 		v->next_shared = NULL;
 
+		/* If we are the only one left in the Shared Order Vehicle List,
+		 *  remove it, as we are no longer a Shared Order Vehicle */
+		if (u->prev_shared == NULL && u->next_shared == NULL) RemoveSharedOrderVehicleList(u);
+
 		/* We only need to update this-one, because if there is a third
 		 *  vehicle which shares the same order-list, nothing will change. If
 		 *  this is the last vehicle, the last line of the order-window
@@ -1144,22 +1172,12 @@
 
 	/* Remove the orders */
 	Order *cur = v->orders;
+	/* Delete the vehicle list of shared orders, if any */
+	if (cur != NULL) RemoveSharedOrderVehicleList(v);
 	v->orders = NULL;
 	v->num_orders = 0;
 
 	if (cur != NULL) {
-		/* Delete the vehicle list of shared orders, if any */
-		WindowClass window_class = WC_NONE;
-
-		switch (v->type) {
-			default: NOT_REACHED();
-			case VEH_TRAIN:    window_class = WC_TRAINS_LIST;   break;
-			case VEH_ROAD:     window_class = WC_ROADVEH_LIST;  break;
-			case VEH_SHIP:     window_class = WC_SHIPS_LIST;    break;
-			case VEH_AIRCRAFT: window_class = WC_AIRCRAFT_LIST; break;
-		}
-		DeleteWindowById(window_class, (cur->index << 16) | (v->type << 11) | VLW_SHARED_ORDERS | v->owner);
-
 		cur->FreeChain(); // Free the orders.
 	}
 }
--- a/src/order_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/order_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file order_gui.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "road_map.h"
--- a/src/os2.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/os2.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file os2.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "variables.h"
--- a/src/os_timer.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/os_timer.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file os_timer.cpp */
+
 #include "stdafx.h"
 
 #undef RDTSC_AVAILABLE
--- a/src/pathfind.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/pathfind.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file pathfind.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "bridge_map.h"
@@ -15,7 +17,7 @@
 #include "variables.h"
 #include "depot.h"
 
-// remember which tiles we have already visited so we don't visit them again.
+/* remember which tiles we have already visited so we don't visit them again. */
 static bool TPFSetTileBit(TrackPathFinder *tpf, TileIndex tile, int dir)
 {
 	uint hash, val, offs;
@@ -65,7 +67,7 @@
 			tpf->hash_tile[hash] = PATHFIND_GET_LINK_OFFS(tpf, link);
 
 			link->flags = tpf->hash_head[hash];
-			tpf->hash_head[hash] = 0xFFFF; /* multi link */
+			tpf->hash_head[hash] = 0xFFFF; // multi link
 
 			link->next = 0xFFFF;
 		}
@@ -142,9 +144,9 @@
 
 	assert(tpf->tracktype == TRANSPORT_WATER);
 
-	// This addition will sometimes overflow by a single tile.
-	// The use of TILE_MASK here makes sure that we still point at a valid
-	// tile, and then this tile will be in the sentinel row/col, so GetTileTrackStatus will fail.
+	/* This addition will sometimes overflow by a single tile.
+	 * The use of TILE_MASK here makes sure that we still point at a valid
+	 * tile, and then this tile will be in the sentinel row/col, so GetTileTrackStatus will fail. */
 	tile = TILE_MASK(tile + TileOffsByDiagDir(direction));
 
 	if (++tpf->rd.cur_length > 50)
@@ -160,8 +162,8 @@
 	if ( (bits & (bits - 1)) == 0 ) {
 		/* only one direction */
 		i = 0;
-		while (!(bits&1))
-			i++, bits>>=1;
+		while (!(bits & 1))
+			i++, bits >>= 1;
 
 		rd = tpf->rd;
 		goto continue_here;
@@ -172,7 +174,7 @@
 		if (!(bits & 1)) continue;
 		rd = tpf->rd;
 
-		// Change direction 4 times only
+		/* Change direction 4 times only */
 		if ((byte)i != tpf->rd.pft_var6) {
 			if (++tpf->rd.depth > 4) {
 				tpf->rd = rd;
@@ -189,7 +191,7 @@
 		}
 
 		tpf->rd = rd;
-	} while (++i, bits>>=1);
+	} while (++i, bits >>= 1);
 
 }
 
@@ -284,7 +286,7 @@
 
 	/* Check in case of rail if the owner is the same */
 	if (tpf->tracktype == TRANSPORT_RAIL) {
-		// don't enter train depot from the back
+		/* don't enter train depot from the back */
 		if (IsTileDepotType(tile, TRANSPORT_RAIL) && GetRailDepotDirection(tile) == direction) return;
 
 		if (IsTileType(tile_org, MP_RAILWAY) || IsTileType(tile_org, MP_STATION) || IsTileType(tile_org, MP_TUNNELBRIDGE))
@@ -292,12 +294,12 @@
 				if (GetTileOwner(tile_org) != GetTileOwner(tile)) return;
 	}
 
-	// check if the new tile can be entered from that direction
+	/* check if the new tile can be entered from that direction */
 	if (tpf->tracktype == TRANSPORT_ROAD) {
-		// road stops and depots now have a track (r4419)
-		// don't enter road stop from the back
+		/* road stops and depots now have a track (r4419)
+		 * don't enter road stop from the back */
 		if (IsStandardRoadStopTile(tile) && ReverseDiagDir(GetRoadStopDir(tile)) != direction) return;
-		// don't enter road depot from the back
+		/* don't enter road depot from the back */
 		if (IsTileDepotType(tile, TRANSPORT_ROAD) && ReverseDiagDir(GetRoadDepotDirection(tile)) != direction) return;
 	}
 
@@ -323,7 +325,7 @@
 
 	if ((byte)bits != tpf->var2) {
 		bits &= _tpfmode1_and[direction];
-		bits = bits | (bits>>8);
+		bits = bits | (bits >> 8);
 	}
 	bits &= 0xBF;
 
@@ -333,7 +335,7 @@
 				i = FIND_FIRST_BIT(bits);
 				bits = KILL_FIRST_BIT(bits);
 
-				tpf->the_dir = (Trackdir)((_otherdir_mask[direction] & (byte)(1 << i)) ? (i+8) : i);
+				tpf->the_dir = (Trackdir)((_otherdir_mask[direction] & (byte)(1 << i)) ? (i + 8) : i);
 				rd = tpf->rd;
 
 				if (TPFSetTileBit(tpf, tile, tpf->the_dir) &&
@@ -375,7 +377,7 @@
 		i = FIND_FIRST_BIT(bits);
 		bits = KILL_FIRST_BIT(bits);
 
-		tpf->the_dir = (Trackdir)((_otherdir_mask[direction] & (byte)(1 << i)) ? (i+8) : i);
+		tpf->the_dir = (Trackdir)((_otherdir_mask[direction] & (byte)(1 << i)) ? (i + 8) : i);
 		rd = tpf->rd;
 		if (TPFSetTileBit(tpf, tile, tpf->the_dir) &&
 				!tpf->enum_proc(tile, tpf->userdata, tpf->the_dir, tpf->rd.cur_length, &tpf->rd.pft_var6) ) {
@@ -401,10 +403,10 @@
 	tpf.rd.depth = 0;
 	tpf.rd.pft_var6 = 0;
 
-	tpf.var2 = HASBIT(flags, 15) ? 0x43 : 0xFF; /* 0x8000 */
+	tpf.var2 = HASBIT(flags, 15) ? 0x43 : 0xFF; // 0x8000
 
-	tpf.disable_tile_hash = HASBIT(flags, 12);  /* 0x1000 */
-	tpf.hasbit_13         = HASBIT(flags, 13);  /* 0x2000 */
+	tpf.disable_tile_hash = HASBIT(flags, 12);  // 0x1000
+	tpf.hasbit_13         = HASBIT(flags, 13);  // 0x2000
 
 
 	tpf.tracktype = (TransportType)(flags & 0xFF);
@@ -425,8 +427,8 @@
 
 struct StackedItem {
 	TileIndex tile;
-	uint16 cur_length; // This is the current length to this tile.
-	uint16 priority; // This is the current length + estimated length to the goal.
+	uint16 cur_length; ///< This is the current length to this tile.
+	uint16 priority;   ///< This is the current length + estimated length to the goal.
 	TrackdirByte track;
 	byte depth;
 	byte state;
@@ -461,12 +463,12 @@
 	uint num_links_left;
 
 	uint nstack;
-	StackedItem stack[256]; // priority queue of stacked items
+	StackedItem stack[256];     ///< priority queue of stacked items
 
-	uint16 hash_head[0x400]; // hash heads. 0 means unused. 0xFFFC = length, 0x3 = dir
-	TileIndex hash_tile[0x400]; // tiles. or links.
+	uint16 hash_head[0x400];    ///< hash heads. 0 means unused. 0xFFFC = length, 0x3 = dir
+	TileIndex hash_tile[0x400]; ///< tiles. or links.
 
-	HashLink links[0x400]; // hash links
+	HashLink links[0x400];      ///< hash links
 
 };
 #define NTP_GET_LINK_OFFS(tpf, link) ((byte*)(link) - (byte*)tpf->links)
@@ -474,22 +476,22 @@
 
 #define ARR(i) tpf->stack[(i)-1]
 
-// called after a new element was added in the queue at the last index.
-// move it down to the proper position
+/** called after a new element was added in the queue at the last index.
+ * move it down to the proper position */
 static inline void HeapifyUp(NewTrackPathFinder *tpf)
 {
 	StackedItem si;
 	int i = ++tpf->nstack;
 
 	while (i != 1 && ARR(i).priority < ARR(i>>1).priority) {
-		// the child element is larger than the parent item.
-		// swap the child item and the parent item.
-		si = ARR(i); ARR(i) = ARR(i>>1); ARR(i>>1) = si;
-		i>>=1;
+		/* the child element is larger than the parent item.
+		 * swap the child item and the parent item. */
+		si = ARR(i); ARR(i) = ARR(i >> 1); ARR(i >> 1) = si;
+		i >>= 1;
 	}
 }
 
-// called after the element 0 was eaten. fill it with a new element
+/** called after the element 0 was eaten. fill it with a new element */
 static inline void HeapifyDown(NewTrackPathFinder *tpf)
 {
 	StackedItem si;
@@ -501,27 +503,27 @@
 
 	if (n == 0) return; // heap is empty so nothing to do?
 
-	// copy the last item to index 0. we use it as base for heapify.
-	ARR(1) = ARR(n+1);
+	/* copy the last item to index 0. we use it as base for heapify. */
+	ARR(1) = ARR(n + 1);
 
-	while ((j=i*2) <= n) {
-		// figure out which is smaller of the children.
-		if (j != n && ARR(j).priority > ARR(j+1).priority)
+	while ((j = i * 2) <= n) {
+		/* figure out which is smaller of the children. */
+		if (j != n && ARR(j).priority > ARR(j + 1).priority)
 			j++; // right item is smaller
 
 		assert(i <= n && j <= n);
 		if (ARR(i).priority <= ARR(j).priority)
 			break; // base elem smaller than smallest, done!
 
-		// swap parent with the child
+		/* swap parent with the child */
 		si = ARR(i); ARR(i) = ARR(j); ARR(j) = si;
 		i = j;
 	}
 }
 
-// mark a tile as visited and store the length of the path.
-// if we already had a better path to this tile, return false.
-// otherwise return true.
+/** mark a tile as visited and store the length of the path.
+ * if we already had a better path to this tile, return false.
+ * otherwise return true. */
 static bool NtpVisit(NewTrackPathFinder* tpf, TileIndex tile, DiagDirection dir, uint length)
 {
 	uint hash,head;
@@ -531,7 +533,7 @@
 
 	hash = PATHFIND_HASH_TILE(tile);
 
-	// never visited before?
+	/* never visited before? */
 	if ((head=tpf->hash_head[hash]) == 0) {
 		tpf->hash_tile[hash] = tile;
 		tpf->hash_head[hash] = dir | (length << 2);
@@ -541,15 +543,15 @@
 	if (head != 0xffff) {
 		if (tile == tpf->hash_tile[hash] && (head & 0x3) == (uint)dir) {
 
-			// longer length
+			/* longer length */
 			if (length >= (head >> 2)) return false;
 
 			tpf->hash_head[hash] = dir | (length << 2);
 			return true;
 		}
-		// two tiles with the same hash, need to make a link
-		// allocate a link. if out of links, handle this by returning
-		// that a tile was already visisted.
+		/* two tiles with the same hash, need to make a link
+		 * allocate a link. if out of links, handle this by returning
+		 * that a tile was already visisted. */
 		if (tpf->num_links_left == 0) {
 			DEBUG(ntp, 1, "No links left");
 			return false;
@@ -564,12 +566,12 @@
 		tpf->hash_tile[hash] = NTP_GET_LINK_OFFS(tpf, link);
 
 		link->typelength = tpf->hash_head[hash];
-		tpf->hash_head[hash] = 0xFFFF; /* multi link */
+		tpf->hash_head[hash] = 0xFFFF; // multi link
 		link->next = 0xFFFF;
 	} else {
-		// a linked list of many tiles,
-		// find the one corresponding to the tile, if it exists.
-		// otherwise make a new link
+		/* a linked list of many tiles,
+		 * find the one corresponding to the tile, if it exists.
+		 * otherwise make a new link */
 
 		uint offs = tpf->hash_tile[hash];
 		do {
@@ -623,7 +625,7 @@
 		return length == (head >> 2);
 	}
 
-	// else it's a linked list of many tiles
+	/* else it's a linked list of many tiles */
 	offs = tpf->hash_tile[hash];
 	for (;;) {
 		link = NTP_GET_LINK_PTR(tpf, offs);
@@ -638,21 +640,21 @@
 
 
 static const uint16 _is_upwards_slope[15] = {
-	0, // no tileh
-	(1 << TRACKDIR_X_SW) | (1 << TRACKDIR_Y_NW), // 1
-	(1 << TRACKDIR_X_SW) | (1 << TRACKDIR_Y_SE), // 2
-	(1 << TRACKDIR_X_SW), // 3
-	(1 << TRACKDIR_X_NE) | (1 << TRACKDIR_Y_SE), // 4
-	0, // 5
-	(1 << TRACKDIR_Y_SE), // 6
-	0, // 7
-	(1 << TRACKDIR_X_NE) | (1 << TRACKDIR_Y_NW), // 8,
-	(1 << TRACKDIR_Y_NW), // 9
-	0, //10
-	0, //11,
-	(1 << TRACKDIR_X_NE), //12
-	0, //13
-	0, //14
+	0,                                           ///< no tileh
+	(1 << TRACKDIR_X_SW) | (1 << TRACKDIR_Y_NW), ///< 1
+	(1 << TRACKDIR_X_SW) | (1 << TRACKDIR_Y_SE), ///< 2
+	(1 << TRACKDIR_X_SW),                        ///< 3
+	(1 << TRACKDIR_X_NE) | (1 << TRACKDIR_Y_SE), ///< 4
+	0,                                           ///< 5
+	(1 << TRACKDIR_Y_SE),                        ///< 6
+	0,                                           ///< 7
+	(1 << TRACKDIR_X_NE) | (1 << TRACKDIR_Y_NW), ///< 8,
+	(1 << TRACKDIR_Y_NW),                        ///< 9
+	0,                                           ///< 10
+	0,                                           ///< 11,
+	(1 << TRACKDIR_X_NE),                        ///< 12
+	0,                                           ///< 13
+	0,                                           ///< 14
 };
 
 static uint DistanceMoo(TileIndex t0, TileIndex t1)
@@ -660,27 +662,27 @@
 	const uint dx = delta(TileX(t0), TileX(t1));
 	const uint dy = delta(TileY(t0), TileY(t1));
 
-	const uint straightTracks = 2 * min(dx, dy); /* The number of straight (not full length) tracks */
+	const uint straightTracks = 2 * min(dx, dy); // The number of straight (not full length) tracks
 	/* OPTIMISATION:
 	 * Original: diagTracks = max(dx, dy) - min(dx,dy);
 	 * Proof:
 	 * (dx-dy) - straightTracks  == (min + max) - straightTracks = min + // max - 2 * min = max - min */
-	const uint diagTracks = dx + dy - straightTracks; /* The number of diagonal (full tile length) tracks. */
+	const uint diagTracks = dx + dy - straightTracks; // The number of diagonal (full tile length) tracks.
 
 	return diagTracks*DIAG_FACTOR + straightTracks*STR_FACTOR;
 }
 
-// These has to be small cause the max length of a track
-// is currently limited to 16384
+/* These has to be small cause the max length of a track
+ * is currently limited to 16384 */
 
 static const byte _length_of_track[16] = {
 	DIAG_FACTOR, DIAG_FACTOR, STR_FACTOR, STR_FACTOR, STR_FACTOR, STR_FACTOR, 0, 0,
 	DIAG_FACTOR, DIAG_FACTOR, STR_FACTOR, STR_FACTOR, STR_FACTOR, STR_FACTOR, 0, 0
 };
 
-// new more optimized pathfinder for trains...
-// Tile is the tile the train is at.
-// direction is the tile the train is moving towards.
+/* new more optimized pathfinder for trains...
+ * Tile is the tile the train is at.
+ * direction is the tile the train is moving towards. */
 
 static void NTPEnum(NewTrackPathFinder* tpf, TileIndex tile, DiagDirection direction)
 {
@@ -692,8 +694,8 @@
 
 
 
-	// Need to have a special case for the start.
-	// We shouldn't call the callback for the current tile.
+	/* Need to have a special case for the start.
+	 * We shouldn't call the callback for the current tile. */
 	si.cur_length = 1; // Need to start at 1 cause 0 is a reserved value.
 	si.depth = 0;
 	si.state = 0;
@@ -701,7 +703,7 @@
 	goto start_at;
 
 	for (;;) {
-		// Get the next item to search from from the priority queue
+		/* Get the next item to search from from the priority queue */
 		do {
 			if (tpf->nstack == 0)
 				return; // nothing left? then we're done!
@@ -709,10 +711,10 @@
 			tile = si.tile;
 
 			HeapifyDown(tpf);
-			// Make sure we havn't already visited this tile.
+			/* Make sure we havn't already visited this tile. */
 		} while (!NtpCheck(tpf, tile, _tpf_prev_direction[si.track], si.cur_length));
 
-		// Add the length of this track.
+		/* Add the length of this track. */
 		si.cur_length += _length_of_track[si.track];
 
 callback_and_continue:
@@ -723,8 +725,8 @@
 		direction = _tpf_new_direction[si.track];
 
 start_at:
-		// If the tile is the entry tile of a tunnel, and we're not going out of the tunnel,
-		//   need to find the exit of the tunnel.
+		/* If the tile is the entry tile of a tunnel, and we're not going out of the tunnel,
+		 *   need to find the exit of the tunnel. */
 		if (IsTileType(tile, MP_TUNNELBRIDGE)) {
 			if (IsTunnel(tile)) {
 				if (GetTunnelDirection(tile) != ReverseDiagDir(direction)) {
@@ -733,7 +735,7 @@
 					/* We are not just driving out of the tunnel */
 					if (GetTunnelDirection(tile) != direction ||
 							GetTunnelTransportType(tile) != tpf->tracktype) {
-						// We are not driving into the tunnel, or it is an invalid tunnel
+						/* We are not driving into the tunnel, or it is an invalid tunnel */
 						continue;
 					}
 					if (!HASBIT(tpf->railtypes, GetRailType(tile))) {
@@ -743,15 +745,15 @@
 					flotr = FindLengthOfTunnel(tile, direction);
 					si.cur_length += flotr.length * DIAG_FACTOR;
 					tile = flotr.tile;
-					// tile now points to the exit tile of the tunnel
+					/* tile now points to the exit tile of the tunnel */
 				}
 			} else {
 				TileIndex tile_end;
 				if (GetBridgeRampDirection(tile) != ReverseDiagDir(direction)) {
-					// We are not just leaving the bridge
+					/* We are not just leaving the bridge */
 					if (GetBridgeRampDirection(tile) != direction ||
 							GetBridgeTransportType(tile) != tpf->tracktype) {
-						// Not entering the bridge or not compatible
+						/* Not entering the bridge or not compatible */
 						continue;
 					}
 				}
@@ -761,29 +763,29 @@
 			}
 		}
 
-		// This is a special loop used to go through
-		// a rail net and find the first intersection
+		/* This is a special loop used to go through
+		 * a rail net and find the first intersection */
 		tile_org = tile;
 		for (;;) {
 			assert(direction <= 3);
 			tile += TileOffsByDiagDir(direction);
 
-			// too long search length? bail out.
+			/* too long search length? bail out. */
 			if (si.cur_length >= tpf->maxlength) {
 				DEBUG(ntp, 1, "Cur_length too big");
 				bits = TRACK_BIT_NONE;
 				break;
 			}
 
-			// Not a regular rail tile?
-			// Then we can't use the code below, but revert to more general code.
+			/* Not a regular rail tile?
+			 * Then we can't use the code below, but revert to more general code. */
 			if (!IsTileType(tile, MP_RAILWAY) || !IsPlainRailTile(tile)) {
-				// We found a tile which is not a normal railway tile.
-				// Determine which tracks that exist on this tile.
+				/* We found a tile which is not a normal railway tile.
+				 * Determine which tracks that exist on this tile. */
 				uint32 ts = GetTileTrackStatus(tile, TRANSPORT_RAIL) & _tpfmode1_and[direction];
 				bits = TrackdirBitsToTrackBits((TrackdirBits)(ts & TRACKDIR_BIT_MASK));
 
-				// Check that the tile contains exactly one track
+				/* Check that the tile contains exactly one track */
 				if (bits == 0 || KILL_FIRST_BIT(bits) != 0) break;
 
 				if (!HASBIT(tpf->railtypes, GetRailType(tile))) {
@@ -791,12 +793,12 @@
 					break;
 				}
 
-				///////////////////
-				// If we reach here, the tile has exactly one track.
-				//   tile - index to a tile that is not rail tile, but still straight (with optional signals)
-				//   bits - bitmask of which track that exist on the tile (exactly one bit is set)
-				//   direction - which direction are we moving in?
-				///////////////////
+				/*******************
+				 * If we reach here, the tile has exactly one track.
+				 *   tile - index to a tile that is not rail tile, but still straight (with optional signals)
+				 *   bits - bitmask of which track that exist on the tile (exactly one bit is set)
+				 *   direction - which direction are we moving in?
+				 *******************/
 				si.track = _new_trackdir[FIND_FIRST_BIT(bits)][direction];
 				si.cur_length += _length_of_track[si.track];
 				goto callback_and_continue;
@@ -825,89 +827,89 @@
 
 			si.cur_length += _length_of_track[track];
 
-			// Check if this rail is an upwards slope. If it is, then add a penalty.
-			// Small optimization here.. if (track&7)>1 then it can't be a slope so we avoid calling GetTileSlope
+			/* Check if this rail is an upwards slope. If it is, then add a penalty.
+			 * Small optimization here.. if (track&7)>1 then it can't be a slope so we avoid calling GetTileSlope */
 			if ((track & 7) <= 1 && (_is_upwards_slope[GetTileSlope(tile, NULL)] & (1 << track)) ) {
 				// upwards slope. add some penalty.
-				si.cur_length += 4*DIAG_FACTOR;
+				si.cur_length += 4 * DIAG_FACTOR;
 			}
 
-			// railway tile with signals..?
+			/* railway tile with signals..? */
 			if (HasSignals(tile)) {
 				if (!HasSignalOnTrackdir(tile, track)) {
-					// if one way signal not pointing towards us, stop going in this direction => End of rail segment.
+					/* if one way signal not pointing towards us, stop going in this direction => End of rail segment. */
 					if (HasSignalOnTrackdir(tile, ReverseTrackdir(track))) {
 						bits = TRACK_BIT_NONE;
 						break;
 					}
 				} else if (GetSignalStateByTrackdir(tile, track) == SIGNAL_STATE_GREEN) {
-					// green signal in our direction. either one way or two way.
+					/* green signal in our direction. either one way or two way. */
 					si.state |= 3;
 				} else {
-					// reached a red signal.
+					/* reached a red signal. */
 					if (HasSignalOnTrackdir(tile, ReverseTrackdir(track))) {
-						// two way red signal. unless we passed another green signal on the way,
-						// stop going in this direction => End of rail segment.
-						// this is to prevent us from going into a full platform.
-						if (!(si.state&1)) {
+						/* two way red signal. unless we passed another green signal on the way,
+						 * stop going in this direction => End of rail segment.
+						 * this is to prevent us from going into a full platform. */
+						if (!(si.state & 1)) {
 							bits = TRACK_BIT_NONE;
 							break;
 						}
 					}
 					if (!(si.state & 2)) {
-						// Is this the first signal we see? And it's red... add penalty
-						si.cur_length += 10*DIAG_FACTOR;
+						/* Is this the first signal we see? And it's red... add penalty */
+						si.cur_length += 10 * DIAG_FACTOR;
 						si.state += 2; // remember that we added penalty.
-						// Because we added a penalty, we can't just continue as usual.
-						// Need to get out and let A* do it's job with
-						// possibly finding an even shorter path.
+						/* Because we added a penalty, we can't just continue as usual.
+						 * Need to get out and let A* do it's job with
+						 * possibly finding an even shorter path. */
 						break;
 					}
 				}
 
 				if (tpf->enum_proc(tile, tpf->userdata, si.first_track, si.cur_length))
-					return; /* Don't process this tile any further */
+					return; // Don't process this tile any further
 			}
 
-			// continue with the next track
+			/* continue with the next track */
 			direction = _tpf_new_direction[track];
 
-			// safety check if we're running around chasing our tail... (infinite loop)
+			/* safety check if we're running around chasing our tail... (infinite loop) */
 			if (tile == tile_org) {
 				bits = TRACK_BIT_NONE;
 				break;
 			}
 		}
 
-		// There are no tracks to choose between.
-		// Stop searching in this direction
+		/* There are no tracks to choose between.
+		 * Stop searching in this direction */
 		if (bits == TRACK_BIT_NONE)
 			continue;
 
-		////////////////
-		// We got multiple tracks to choose between (intersection).
-		// Branch the search space into several branches.
-		////////////////
+		/****************
+		 * We got multiple tracks to choose between (intersection).
+		 * Branch the search space into several branches.
+		 ****************/
 
-		// Check if we've already visited this intersection.
-		// If we've already visited it with a better length, then
-		// there's no point in visiting it again.
+		/* Check if we've already visited this intersection.
+		 * If we've already visited it with a better length, then
+		 * there's no point in visiting it again. */
 		if (!NtpVisit(tpf, tile, direction, si.cur_length))
 			continue;
 
-		// Push all possible alternatives that we can reach from here
-		// onto the priority heap.
-		// 'bits' contains the tracks that we can choose between.
+		/* Push all possible alternatives that we can reach from here
+		 * onto the priority heap.
+		 * 'bits' contains the tracks that we can choose between. */
 
-		// First compute the estimated distance to the target.
-		// This is used to implement A*
+		/* First compute the estimated distance to the target.
+		 * This is used to implement A* */
 		estimation = 0;
 		if (tpf->dest != 0)
 			estimation = DistanceMoo(tile, tpf->dest);
 
 		si.depth++;
 		if (si.depth == 0)
-			continue; /* We overflowed our depth. No more searching in this direction. */
+			continue; // We overflowed our depth. No more searching in this direction.
 		si.tile = tile;
 		while (bits != TRACK_BIT_NONE) {
 			Track track = RemoveFirstTrack(&bits);
@@ -915,7 +917,7 @@
 			assert(si.track != 0xFF);
 			si.priority = si.cur_length + estimation;
 
-			// out of stack items, bail out?
+			/* out of stack items, bail out? */
 			if (tpf->nstack >= lengthof(tpf->stack)) {
 				DEBUG(ntp, 1, "Out of stack");
 				break;
@@ -925,9 +927,9 @@
 			HeapifyUp(tpf);
 		};
 
-		// If this is the first intersection, we need to fill the first_track member.
-		// so the code outside knows which path is better.
-		// also randomize the order in which we search through them.
+		/* If this is the first intersection, we need to fill the first_track member.
+		 * so the code outside knows which path is better.
+		 * also randomize the order in which we search through them. */
 		if (si.depth == 1) {
 			assert(tpf->nstack == 1 || tpf->nstack == 2 || tpf->nstack == 3);
 			if (tpf->nstack != 1) {
@@ -944,12 +946,12 @@
 			}
 		}
 
-		// Continue with the next from the queue...
+		/* Continue with the next from the queue... */
 	}
 }
 
 
-// new pathfinder for trains. better and faster.
+/** new pathfinder for trains. better and faster. */
 void NewTrainPathfind(TileIndex tile, TileIndex dest, RailTypeMask railtypes, DiagDirection direction, NTPEnumProc* enum_proc, void* data)
 {
 	NewTrackPathFinder tpf;
--- a/src/pathfind.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/pathfind.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file pathfind.h */
+
 #ifndef PATHFIND_H
 #define PATHFIND_H
 
@@ -60,9 +62,9 @@
 	bool hasbit_13;
 
 	uint16 hash_head[0x400];
-	TileIndex hash_tile[0x400]; /* stores the link index when multi link. */
+	TileIndex hash_tile[0x400];       ///< stores the link index when multi link.
 
-	TrackPathFinderLink links[0x400]; /* hopefully, this is enough. */
+	TrackPathFinderLink links[0x400]; ///< hopefully, this is enough.
 };
 
 void FollowTrack(TileIndex tile, uint16 flags, DiagDirection direction, TPFEnumProc* enum_proc, TPFAfterProc* after_proc, void* data);
--- a/src/player.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/player.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file player.h */
+
 #ifndef PLAYER_H
 #define PLAYER_H
 
@@ -13,7 +15,7 @@
 	int32 income;
 	int32 expenses;
 	int32 delivered_cargo;
-	int32 performance_history; // player score (scale 0-1000)
+	int32 performance_history; ///< player score (scale 0-1000)
 	int64 company_value;
 };
 
@@ -32,8 +34,8 @@
 
 struct PlayerAI {
 	byte state;
-	byte tick;            // Used to determine how often to move
-	uint32 state_counter; // Can hold tile index!
+	byte tick;            ///< Used to determine how often to move
+	uint32 state_counter; ///< Can hold tile index!
 	uint16 timeout_counter;
 
 	byte state_mode;
@@ -59,7 +61,7 @@
 	byte cur_dir_b;
 	byte start_dir_b;
 
-	Vehicle *cur_veh; /* only used by some states */
+	Vehicle *cur_veh; ///< only used by some states
 
 	AiBuildRec src, dst, mid1, mid2;
 
@@ -71,22 +73,22 @@
 };
 
 struct Ai_PathFinderInfo {
-	TileIndex start_tile_tl; // tl = top-left
-	TileIndex start_tile_br; // br = bottom-right
-	TileIndex end_tile_tl;   // tl = top-left
-	TileIndex end_tile_br;   // br = bottom-right
-	byte start_direction;    // 0 to 3 or AI_PATHFINDER_NO_DIRECTION
-	byte end_direction;      // 0 to 3 or AI_PATHFINDER_NO_DIRECTION
+	TileIndex start_tile_tl; ///< tl = top-left
+	TileIndex start_tile_br; ///< br = bottom-right
+	TileIndex end_tile_tl;   ///< tl = top-left
+	TileIndex end_tile_br;   ///< br = bottom-right
+	byte start_direction;    ///< 0 to 3 or AI_PATHFINDER_NO_DIRECTION
+	byte end_direction;      ///< 0 to 3 or AI_PATHFINDER_NO_DIRECTION
 
 	TileIndex route[500];
-	byte route_extra[500];   // Some extra information about the route like bridge/tunnel
+	byte route_extra[500];   ///< Some extra information about the route like bridge/tunnel
 	int route_length;
-	int position;            // Current position in the build-path, needed to build the path
+	int position;            ///< Current position in the build-path, needed to build the path
 
-	bool rail_or_road;       // true = rail, false = road
+	bool rail_or_road;       ///< true = rail, false = road
 };
 
-// The amount of memory reserved for the AI-special-vehicles
+/* The amount of memory reserved for the AI-special-vehicles */
 #define AI_MAX_SPECIAL_VEHICLES 100
 
 struct Ai_SpecialVehicle {
@@ -99,28 +101,28 @@
 	uint tick;
 	uint idle;
 
-	int temp;    // A value used in more than one function, but it just temporary
-	             // The use is pretty simple: with this we can 'think' about stuff
-	             //   in more than one tick, and more than one AI. A static will not
-	             //   do, because they are not saved. This way, the AI is almost human ;)
-	int counter; // For the same reason as temp, we have counter. It can count how
-	             //  long we are trying something, and just abort if it takes too long
+	int temp;    ///< A value used in more than one function, but it just temporary
+	             ///< The use is pretty simple: with this we can 'think' about stuff
+	             ///<   in more than one tick, and more than one AI. A static will not
+	             ///<   do, because they are not saved. This way, the AI is almost human ;)
+	int counter; ///< For the same reason as temp, we have counter. It can count how
+	             ///<  long we are trying something, and just abort if it takes too long
 
-	// Pathfinder stuff
+	/* Pathfinder stuff */
 	Ai_PathFinderInfo path_info;
 	AyStar *pathfinder;
 
-	// Route stuff
+	/* Route stuff */
 
 	CargoID cargo;
-	byte tbt; // train/bus/truck 0/1/2 AI_TRAIN/AI_BUS/AI_TRUCK
+	byte tbt;    ///< train/bus/truck 0/1/2 AI_TRAIN/AI_BUS/AI_TRUCK
 	int new_cost;
 
 	byte action;
 
-	int last_id; // here is stored the last id of the searched city/industry
+	int last_id; ///< here is stored the last id of the searched city/industry
 	Date last_vehiclecheck_date; // Used in CheckVehicle
-	Ai_SpecialVehicle special_vehicles[AI_MAX_SPECIAL_VEHICLES]; // Some vehicles have some special flags
+	Ai_SpecialVehicle special_vehicles[AI_MAX_SPECIAL_VEHICLES]; ///< Some vehicles have some special flags
 
 	TileIndex from_tile;
 	TileIndex to_tile;
@@ -128,19 +130,19 @@
 	byte from_direction;
 	byte to_direction;
 
-	bool from_deliver; // True if this is the station that GIVES cargo
+	bool from_deliver; ///< True if this is the station that GIVES cargo
 	bool to_deliver;
 
 	TileIndex depot_tile;
 	DiagDirectionByte depot_direction;
 
-	byte amount_veh;       // How many vehicles we are going to build in this route
-	byte cur_veh;          // How many vehicles did we bought?
-	VehicleID veh_id;      // Used when bought a vehicle
-	VehicleID veh_main_id; // The ID of the first vehicle, for shared copy
+	byte amount_veh;       ///< How many vehicles we are going to build in this route
+	byte cur_veh;          ///< How many vehicles did we bought?
+	VehicleID veh_id;      ///< Used when bought a vehicle
+	VehicleID veh_main_id; ///< The ID of the first vehicle, for shared copy
 
-	int from_ic;           // ic = industry/city. This is the ID of them
-	byte from_type;        // AI_NO_TYPE/AI_CITY/AI_INDUSTRY
+	int from_ic;           ///< ic = industry/city. This is the ID of them
+	byte from_type;        ///< AI_NO_TYPE/AI_CITY/AI_INDUSTRY
 	int to_ic;
 	byte to_type;
 
@@ -160,7 +162,7 @@
 
 	int32 player_money;
 	int32 current_loan;
-	int64 money64; // internal 64-bit version of the money. the 32-bit field will be clamped to plus minus 2 billion
+	int64 money64; ///< internal 64-bit version of the money. the 32-bit field will be clamped to plus minus 2 billion
 
 	byte player_color;
 	Livery livery[LS_END];
@@ -169,7 +171,7 @@
 	byte block_preview;
 	PlayerByte index;
 
-	uint16 cargo_types; /* which cargo types were transported the last year */
+	uint16 cargo_types; ///< which cargo types were transported the last year
 
 	TileIndex location_of_house;
 	TileIndex last_build_coordinate;
@@ -180,7 +182,7 @@
 	byte num_valid_stat_ent;
 
 	byte quarters_of_bankrupcy;
-	byte bankrupt_asked; // which players were asked about buying it?
+	byte bankrupt_asked; ///< which players were asked about buying it?
 	int16 bankrupt_timeout;
 	int32 bankrupt_value;
 
@@ -192,12 +194,12 @@
 	int64 yearly_expenses[3][13];
 	PlayerEconomyEntry cur_economy;
 	PlayerEconomyEntry old_economy[24];
-	EngineRenewList engine_renew_list; // Defined later
+	EngineRenewList engine_renew_list; ///< Defined later
 	bool engine_renew;
 	bool renew_keep_length;
 	int16 engine_renew_months;
 	uint32 engine_renew_money;
-	uint16 num_engines[TOTAL_NUM_ENGINES]; // caches the number of engines of each type the player owns (no need to save this)
+	uint16 num_engines[TOTAL_NUM_ENGINES]; ///< caches the number of engines of each type the player owns (no need to save this)
 };
 
 uint16 GetDrawStringPlayerColor(PlayerID player);
@@ -214,7 +216,7 @@
 VARDEF PlayerID _current_player;
 
 VARDEF Player _players[MAX_PLAYERS];
-// NOSAVE: can be determined from player structs
+/* NOSAVE: can be determined from player structs */
 VARDEF byte _player_colors[MAX_PLAYERS];
 
 static inline byte ActivePlayerCount()
@@ -284,8 +286,8 @@
 
 struct HighScore {
 	char company[100];
-	StringID title; // NO_SAVE, has troubles with changing string-numbers.
-	uint16 score;   // do NOT change type, will break hs.dat
+	StringID title; ///< NO_SAVE, has troubles with changing string-numbers.
+	uint16 score;   ///< do NOT change type, will break hs.dat
 };
 
 VARDEF HighScore _highscore_table[5][5]; // 4 difficulty-settings (+ network); top 5
--- a/src/player_face.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/player_face.h	Thu Apr 19 14:43:25 2007 +0000
@@ -64,7 +64,7 @@
 	/* PFV_CHIN            */ {  7, 2, {  4,  1,  2,  2 }, { 0x327, 0x327, 0x391, 0x3B1 } },
 	/* PFV_EYEBROWS        */ {  9, 4, { 12, 16, 11, 16 }, { 0x32B, 0x337, 0x39A, 0x3B8 } },
 	/* PFV_MOUSTACHE       */ { 13, 2, {  3,  0,  3,  0 }, { 0x367,     0, 0x397,     0 } }, ///< Depends on PFV_HAS_MOUSTACHE
-	/* PFV_LIPS            */ { 13, 4, { 13, 10,  9,  9 }, { 0x35B, 0x351, 0x3A5, 0x3C8 } }, ///< Depends on !PFV_HAS_MOUSTACHE
+	/* PFV_LIPS            */ { 13, 4, { 12, 10,  9,  9 }, { 0x35B, 0x351, 0x3A5, 0x3C8 } }, ///< Depends on !PFV_HAS_MOUSTACHE
 	/* PFV_NOSE            */ { 17, 3, {  8,  4,  4,  5 }, { 0x349, 0x34C, 0x393, 0x3B3 } }, ///< Depends on !PFV_HAS_MOUSTACHE
 	/* PFV_HAIR            */ { 20, 4, {  9,  5,  5,  4 }, { 0x382, 0x38B, 0x3D4, 0x3D9 } },
 	/* PFV_JACKET          */ { 24, 2, {  3,  3,  3,  3 }, { 0x36B, 0x378, 0x36B, 0x378 } },
--- a/src/player_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/player_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file player_gui.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "table/sprites.h"
@@ -76,7 +78,7 @@
 
 		y = 171;
 
-		// draw max loan aligned to loan below (y += 10)
+		/* draw max loan aligned to loan below (y += 10) */
 		SetDParam64(0, (uint64)_economy.max_loan);
 		DrawString(202, y+10, STR_MAX_LOAN, 0);
 	} else {
@@ -404,12 +406,12 @@
 				}
 
 				case 9:
-				case 10: // First colour dropdown
+				case 10: /* First colour dropdown */
 					ShowColourDropDownMenu(w, 10);
 					break;
 
 				case 11:
-				case 12: // Second colour dropdown
+				case 12: /* Second colour dropdown */
 					ShowColourDropDownMenu(w, 12);
 					break;
 
@@ -761,7 +763,7 @@
 			DrawPlayerVehiclesAmount((PlayerID)w->window_number);
 
 			DrawString(110,48, STR_7006_COLOR_SCHEME, 0);
-			// Draw company-colour bus
+			/* Draw company-colour bus */
 			DrawSprite(SPR_VEH_BUS_SW_VIEW, PLAYER_SPRITE_COLOR(p->index), 215, 49);
 
 			DrawPlayerFace(p->face, p->player_color, 2, 16);
@@ -882,7 +884,7 @@
 		case WE_ON_EDIT_TEXT: {
 			char *b = e->we.edittext.str;
 
-			// empty string is allowed for password
+			/* empty string is allowed for password */
 			if (*b == '\0' && WP(w,def_d).byte_1 != 2) return;
 
 			_cmd_text = b;
@@ -987,7 +989,7 @@
 static void SetupHighScoreEndWindow(Window *w, uint *x, uint *y)
 {
 	uint i;
-	// resize window to "full-screen"
+	/* resize window to "full-screen" */
 	w->width = _screen.width;
 	w->height = _screen.height;
 	w->widget[0].right = w->width - 1;
@@ -1004,7 +1006,7 @@
 
 extern StringID EndGameGetPerformanceTitleFromValue(uint value);
 
-/* End game window shown at the end of the game */
+/** End game window shown at the end of the game */
 static void EndGameWndProc(Window *w, WindowEvent *e)
 {
 	switch (e->event) {
@@ -1106,14 +1108,14 @@
 	EndGameWndProc
 };
 
-/* Show the highscore table for a given difficulty. When called from
+/** Show the highscore table for a given difficulty. When called from
  * endgame ranking is set to the top5 element that was newly added
  * and is thus highlighted */
 void ShowHighscoreTable(int difficulty, int8 ranking)
 {
 	Window *w;
 
-	// pause game to show the chart
+	/* pause game to show the chart */
 	if (!_networking) DoCommandP(0, 1, 0, NULL, CMD_PAUSE);
 
 	/* Close all always on-top windows to get a clean screen */
@@ -1130,7 +1132,7 @@
 	}
 }
 
-/* Show the endgame victory screen in 2050. Update the new highscore
+/** Show the endgame victory screen in 2050. Update the new highscore
  * if it was high enough */
 void ShowEndGameChart()
 {
@@ -1162,7 +1164,7 @@
 			w->window_number = lengthof(_highscore_table) - 1;
 			WP(w, highscore_d).rank = SaveHighScoreValueNetwork();
 		} else {
-			// in single player _local player is always valid
+			/* in single player _local player is always valid */
 			const Player *p = GetPlayer(_local_player);
 			w->window_number = _opt.diff_level;
 			WP(w, highscore_d).rank = SaveHighScoreValue(p);
--- a/src/players.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/players.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -107,6 +107,7 @@
 		SetPlayerFaceBits(pf, PFV_MOUSTACHE,     ge, max(lips, 1U) - 1);
 	} else {
 		if (!HASBIT(ge, GENDER_FEMALE)) {
+			lips = lips * 15 / 16;
 			lips -= 3;
 			if (HASBIT(ge, ETHNICITY_BLACK) && lips > 8) lips = 0;
 		} else {
@@ -218,7 +219,7 @@
 	if (cost != 0) SubtractMoneyFromAnyPlayer(p, cost);
 }
 
-// the player_money field is kept as it is, but money64 contains the actual amount of money.
+/** the player_money field is kept as it is, but money64 contains the actual amount of money. */
 void UpdatePlayerMoney32(Player *p)
 {
 	if (p->money64 < -2000000000) {
@@ -271,7 +272,7 @@
 	if (owner == _current_player) return true;
 	_error_message = STR_013B_OWNED_BY;
 
-	// no need to get the name of the owner unless we're the local player (saves some time)
+	/* no need to get the name of the owner unless we're the local player (saves some time) */
 	if (IsLocalPlayer()) GetNameOfOwner(owner, tile);
 	return false;
 }
@@ -297,7 +298,7 @@
 		strp = t->townnameparts;
 
 verify_name:;
-		// No player must have this name already
+		/* No player must have this name already */
 		FOR_ALL_PLAYERS(pp) {
 			if (pp->name_1 == str && pp->name_2 == strp) goto bad_town_name;
 		}
@@ -344,17 +345,17 @@
 	uint32 r;
 	Player *p;
 
-	// Initialize array
+	/* Initialize array */
 	for (i = 0; i != 16; i++) colors[i] = i;
 
-	// And randomize it
+	/* And randomize it */
 	n = 100;
 	do {
 		r = Random();
 		COLOR_SWAP(GB(r, 0, 4), GB(r, 4, 4));
 	} while (--n);
 
-	// Bubble sort it according to the values in table 1
+	/* Bubble sort it according to the values in table 1 */
 	i = 16;
 	do {
 		for (j = 0; j != 15; j++) {
@@ -364,7 +365,7 @@
 		}
 	} while (--i);
 
-	// Move the colors that look similar to each player's color to the side
+	/* Move the colors that look similar to each player's color to the side */
 	FOR_ALL_PLAYERS(p) if (p->is_active) {
 		pcolor = p->player_color;
 		for (i=0; i!=16; i++) if (colors[i] == pcolor) {
@@ -391,7 +392,7 @@
 		}
 	}
 
-	// Return the first available color
+	/* Return the first available color */
 	for (i = 0;; i++) {
 		if (colors[i] != 0xFF) return colors[i];
 	}
@@ -428,7 +429,7 @@
 static Player *AllocatePlayer()
 {
 	Player *p;
-	// Find a free slot
+	/* Find a free slot */
 	FOR_ALL_PLAYERS(p) {
 		if (!p->is_active) {
 			PlayerID i = p->index;
@@ -456,7 +457,7 @@
 	p = AllocatePlayer();
 	if (p == NULL) return NULL;
 
-	// Make a color
+	/* Make a color */
 	p->player_color = GeneratePlayerColor();
 	ResetPlayerLivery(p);
 	_player_colors[p->index] = p->player_color;
@@ -466,7 +467,7 @@
 	p->money64 = p->player_money = p->current_loan = 100000;
 
 	p->is_ai = is_ai;
-	p->ai.state = 5; /* AIS_WANT_NEW_ROUTE */
+	p->ai.state = 5; // AIS_WANT_NEW_ROUTE
 	p->share_owners[0] = p->share_owners[1] = p->share_owners[2] = p->share_owners[3] = PLAYER_SPECTATOR;
 
 	p->avail_railtypes = GetPlayerRailtypes(p->index);
@@ -496,7 +497,7 @@
 
 void StartupPlayers()
 {
-	// The AI starts like in the setting with +2 month max
+	/* The AI starts like in the setting with +2 month max */
 	_next_competitor_start = _opt.diff.competitor_start_time * 90 * DAY_TICKS + RandomRange(60 * DAY_TICKS) + 1;
 }
 
@@ -505,13 +506,13 @@
 	uint n;
 	Player *p;
 
-	// count number of competitors
+	/* count number of competitors */
 	n = 0;
 	FOR_ALL_PLAYERS(p) {
 		if (p->is_active && p->is_ai) n++;
 	}
 
-	// when there's a lot of computers in game, the probability that a new one starts is lower
+	/* when there's a lot of computers in game, the probability that a new one starts is lower */
 	if (n < (uint)_opt.diff.max_no_competitors &&
 			n < (_network_server ?
 				InteractiveRandomRange(_opt.diff.max_no_competitors + 2) :
@@ -522,7 +523,7 @@
 		DoCommandP(0, 1, 0, NULL, CMD_PLAYER_CTRL);
 	}
 
-	// The next AI starts like the difficulty setting said, with +2 month max
+	/* The next AI starts like the difficulty setting said, with +2 month max */
 	_next_competitor_start = _opt.diff.competitor_start_time * 90 * DAY_TICKS + 1;
 	_next_competitor_start += _network_server ? InteractiveRandomRange(60 * DAY_TICKS) : RandomRange(60 * DAY_TICKS);
 }
@@ -548,7 +549,7 @@
 		MaybeStartNewPlayer();
 }
 
-// index is the next parameter in _decode_parameters to set up
+/** index is the next parameter in _decode_parameters to set up */
 StringID GetPlayerNameString(PlayerID player, uint index)
 {
 	if (IsHumanPlayer(player) && IsValidPlayer(player)) {
@@ -564,7 +565,7 @@
 {
 	Player *p;
 
-	// Copy statistics
+	/* Copy statistics */
 	FOR_ALL_PLAYERS(p) {
 		if (p->is_active) {
 			memmove(&p->yearly_expenses[1], &p->yearly_expenses[0], sizeof(p->yearly_expenses) - sizeof(p->yearly_expenses[0]));
@@ -699,16 +700,16 @@
 				if (!IsEngineIndex(new_engine_type))
 					return CMD_ERROR;
 
-				// check that the new vehicle type is the same as the original one
+				/* check that the new vehicle type is the same as the original one */
 				if (GetEngine(old_engine_type)->type != GetEngine(new_engine_type)->type)
 					return CMD_ERROR;
 
-				// make sure that we do not replace a plane with a helicopter or vise versa
+				/* make sure that we do not replace a plane with a helicopter or vise versa */
 				if (GetEngine(new_engine_type)->type == VEH_AIRCRAFT &&
 						(AircraftVehInfo(old_engine_type)->subtype & AIR_CTOL) != (AircraftVehInfo(new_engine_type)->subtype & AIR_CTOL))
 					return CMD_ERROR;
 
-				// make sure that the player can actually buy the new engine
+				/* make sure that the player can actually buy the new engine */
 				if (!HASBIT(GetEngine(new_engine_type)->player_avail, _current_player))
 					return CMD_ERROR;
 
@@ -945,7 +946,7 @@
 	return _endgame_perf_titles[value];
 }
 
-/* Return true if any cheat has been used, false otherwise */
+/** Return true if any cheat has been used, false otherwise */
 static bool CheatHasBeenUsed()
 {
 	const Cheat* cht = (Cheat*)&_cheats;
@@ -958,7 +959,7 @@
 	return false;
 }
 
-/* Save the highscore for the player */
+/** Save the highscore for the player */
 int8 SaveHighScoreValue(const Player *p)
 {
 	HighScore *hs = _highscore_table[_opt.diff_level];
@@ -971,7 +972,7 @@
 	for (i = 0; i < lengthof(_highscore_table[0]); i++) {
 		/* You are in the TOP5. Move all values one down and save us there */
 		if (hs[i].score <= score) {
-			// move all elements one down starting from the replaced one
+			/* move all elements one down starting from the replaced one */
 			memmove(&hs[i + 1], &hs[i], sizeof(HighScore) * (lengthof(_highscore_table[0]) - i - 1));
 			SetDParam(0, p->president_name_1);
 			SetDParam(1, p->president_name_2);
@@ -987,7 +988,7 @@
 	return -1; // too bad; we did not make it into the top5
 }
 
-/* Sort all players given their performance */
+/** Sort all players given their performance */
 static int CDECL HighScoreSorter(const void *a, const void *b)
 {
 	const Player *pa = *(const Player* const*)a;
@@ -1026,7 +1027,7 @@
 			hs->score = pl[i]->old_economy[0].performance_history;
 			hs->title = EndGameGetPerformanceTitleFromValue(hs->score);
 
-			// get the ranking of the local player
+			/* get the ranking of the local player */
 			if (pl[i]->index == _local_player) player = i;
 		}
 	}
@@ -1035,7 +1036,7 @@
 	return player;
 }
 
-/* Save HighScore table to file */
+/** Save HighScore table to file */
 void SaveToHighScore()
 {
 	FILE *fp = fopen(_highscore_file, "wb");
@@ -1052,14 +1053,14 @@
 				fwrite(&length, sizeof(length), 1, fp); // write away string length
 				fwrite(hs->company, length, 1, fp);
 				fwrite(&hs->score, sizeof(hs->score), 1, fp);
-				fwrite("", 2, 1, fp); /* XXX - placeholder for hs->title, not saved anymore; compatibility */
+				fwrite("", 2, 1, fp); // XXX - placeholder for hs->title, not saved anymore; compatibility
 			}
 		}
 		fclose(fp);
 	}
 }
 
-/* Initialize the highscore table to 0 and if any file exists, load in values */
+/** Initialize the highscore table to 0 and if any file exists, load in values */
 void LoadFromHighScore()
 {
 	FILE *fp = fopen(_highscore_file, "rb");
@@ -1077,7 +1078,7 @@
 
 				fread(hs->company, 1, length, fp);
 				fread(&hs->score, sizeof(hs->score), 1, fp);
-				fseek(fp, 2, SEEK_CUR); /* XXX - placeholder for hs->title, not saved anymore; compatibility */
+				fseek(fp, 2, SEEK_CUR); // XXX - placeholder for hs->title, not saved anymore; compatibility
 				hs->title = EndGameGetPerformanceTitleFromValue(hs->score);
 			}
 		}
@@ -1088,7 +1089,7 @@
 	_patches.ending_year = 2051;
 }
 
-// Save/load of players
+/* Save/load of players */
 static const SaveLoad _player_desc[] = {
 	    SLE_VAR(Player, name_2,          SLE_UINT32),
 	    SLE_VAR(Player, name_1,          SLE_STRINGID),
@@ -1098,7 +1099,7 @@
 
 	    SLE_VAR(Player, face,            SLE_UINT32),
 
-	// money was changed to a 64 bit field in savegame version 1.
+	/* money was changed to a 64 bit field in savegame version 1. */
 	SLE_CONDVAR(Player, money64,               SLE_VAR_I64 | SLE_FILE_I32, 0, 0),
 	SLE_CONDVAR(Player, money64,               SLE_INT64, 1, SL_MAX_VERSION),
 
@@ -1126,14 +1127,14 @@
 	    SLE_VAR(Player, bankrupt_timeout,      SLE_INT16),
 	    SLE_VAR(Player, bankrupt_value,        SLE_INT32),
 
-	// yearly expenses was changed to 64-bit in savegame version 2.
+	/* yearly expenses was changed to 64-bit in savegame version 2. */
 	SLE_CONDARR(Player, yearly_expenses,       SLE_FILE_I32 | SLE_VAR_I64, 3 * 13, 0, 1),
 	SLE_CONDARR(Player, yearly_expenses,       SLE_INT64, 3 * 13,                  2, SL_MAX_VERSION),
 
 	SLE_CONDVAR(Player, is_ai,                 SLE_BOOL, 2, SL_MAX_VERSION),
 	SLE_CONDVAR(Player, is_active,             SLE_BOOL, 4, SL_MAX_VERSION),
 
-	// Engine renewal settings
+	/* Engine renewal settings */
 	SLE_CONDNULL(512, 16, 18),
 	SLE_CONDREF(Player, engine_renew_list,     REF_ENGINE_RENEWS,          19, SL_MAX_VERSION),
 	SLE_CONDVAR(Player, engine_renew,          SLE_BOOL,                   16, SL_MAX_VERSION),
@@ -1141,14 +1142,14 @@
 	SLE_CONDVAR(Player, engine_renew_money,    SLE_UINT32,                 16, SL_MAX_VERSION),
 	SLE_CONDVAR(Player, renew_keep_length,     SLE_BOOL,                    2, SL_MAX_VERSION), // added with 16.1, but was blank since 2
 
-	// reserve extra space in savegame here. (currently 63 bytes)
+	/* reserve extra space in savegame here. (currently 63 bytes) */
 	SLE_CONDNULL(63, 2, SL_MAX_VERSION),
 
 	SLE_END()
 };
 
 static const SaveLoad _player_economy_desc[] = {
-	// these were changed to 64-bit in savegame format 2
+	/* these were changed to 64-bit in savegame format 2 */
 	SLE_CONDVAR(PlayerEconomyEntry, income,              SLE_INT32,                  0, 1),
 	SLE_CONDVAR(PlayerEconomyEntry, expenses,            SLE_INT32,                  0, 1),
 	SLE_CONDVAR(PlayerEconomyEntry, company_value,       SLE_FILE_I32 | SLE_VAR_I64, 0, 1),
@@ -1235,7 +1236,7 @@
 
 	SlObject(p, _player_desc);
 
-	// Write AI?
+	/* Write AI? */
 	if (!IsHumanPlayer(p->index)) {
 		SlObject(&p->ai, _player_ai_desc);
 		for (i = 0; i != p->ai.num_build_rec; i++) {
@@ -1243,15 +1244,15 @@
 		}
 	}
 
-	// Write economy
+	/* Write economy */
 	SlObject(&p->cur_economy, _player_economy_desc);
 
-	// Write old economy entries.
+	/* Write old economy entries. */
 	for (i = 0; i < p->num_valid_stat_ent; i++) {
 		SlObject(&p->old_economy[i], _player_economy_desc);
 	}
 
-	// Write each livery entry.
+	/* Write each livery entry. */
 	for (i = 0; i < LS_END; i++) {
 		SlObject(&p->livery[i], _player_livery_desc);
 	}
--- a/src/queue.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/queue.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file queue.cpp */
+
 #include "stdafx.h"
 #include "openttd.h"
 #include "queue.h"
@@ -91,10 +93,10 @@
 #define BINARY_HEAP_BLOCKSIZE (1 << BINARY_HEAP_BLOCKSIZE_BITS)
 #define BINARY_HEAP_BLOCKSIZE_MASK (BINARY_HEAP_BLOCKSIZE - 1)
 
-// To make our life easy, we make the next define
-//  Because Binary Heaps works with array from 1 to n,
-//  and C with array from 0 to n-1, and we don't like typing
-//  q->data.binaryheap.elements[i - 1] every time, we use this define.
+/* To make our life easy, we make the next define
+ *  Because Binary Heaps works with array from 1 to n,
+ *  and C with array from 0 to n-1, and we don't like typing
+ *  q->data.binaryheap.elements[i - 1] every time, we use this define. */
 #define BIN_HEAP_ARR(i) q->data.binaryheap.elements[((i) - 1) >> BINARY_HEAP_BLOCKSIZE_BITS][((i) - 1) & BINARY_HEAP_BLOCKSIZE_MASK]
 
 static void BinaryHeap_Clear(Queue* q, bool free_values)
@@ -114,7 +116,7 @@
 				/* For every element in the block */
 				if ((q->data.binaryheap.size >> BINARY_HEAP_BLOCKSIZE_BITS) == i &&
 						(q->data.binaryheap.size & BINARY_HEAP_BLOCKSIZE_MASK) == j) {
-					break; /* We're past the last element */
+					break; // We're past the last element
 				}
 				free(q->data.binaryheap.elements[i][j].item);
 			}
@@ -160,13 +162,13 @@
 #endif
 	}
 
-	// Add the item at the end of the array
+	/* Add the item at the end of the array */
 	BIN_HEAP_ARR(q->data.binaryheap.size + 1).priority = priority;
 	BIN_HEAP_ARR(q->data.binaryheap.size + 1).item = item;
 	q->data.binaryheap.size++;
 
-	// Now we are going to check where it belongs. As long as the parent is
-	// bigger, we switch with the parent
+	/* Now we are going to check where it belongs. As long as the parent is
+	 * bigger, we switch with the parent */
 	{
 		BinaryHeapNode temp;
 		int i;
@@ -174,16 +176,16 @@
 
 		i = q->data.binaryheap.size;
 		while (i > 1) {
-			// Get the parent of this object (divide by 2)
+			/* Get the parent of this object (divide by 2) */
 			j = i / 2;
-			// Is the parent bigger then the current, switch them
+			/* Is the parent bigger then the current, switch them */
 			if (BIN_HEAP_ARR(i).priority <= BIN_HEAP_ARR(j).priority) {
 				temp = BIN_HEAP_ARR(j);
 				BIN_HEAP_ARR(j) = BIN_HEAP_ARR(i);
 				BIN_HEAP_ARR(i) = temp;
 				i = j;
 			} else {
-				// It is not, we're done!
+				/* It is not, we're done! */
 				break;
 			}
 		}
@@ -200,20 +202,20 @@
 	printf("[BinaryHeap] Deleting an element. There are %d elements left\n", q->data.binaryheap.size);
 #endif
 
-	// First, we try to find the item..
+	/* First, we try to find the item.. */
 	do {
 		if (BIN_HEAP_ARR(i + 1).item == item) break;
 		i++;
 	} while (i < q->data.binaryheap.size);
-	// We did not find the item, so we return false
+	/* We did not find the item, so we return false */
 	if (i == q->data.binaryheap.size) return false;
 
-	// Now we put the last item over the current item while decreasing the size of the elements
+	/* Now we put the last item over the current item while decreasing the size of the elements */
 	q->data.binaryheap.size--;
 	BIN_HEAP_ARR(i + 1) = BIN_HEAP_ARR(q->data.binaryheap.size + 1);
 
-	// Now the only thing we have to do, is resort it..
-	// On place i there is the item to be sorted.. let's start there
+	/* Now the only thing we have to do, is resort it..
+	 * On place i there is the item to be sorted.. let's start there */
 	{
 		uint j;
 		BinaryHeapNode temp;
@@ -224,25 +226,25 @@
 
 		for (;;) {
 			j = i;
-			// Check if we have 2 childs
+			/* Check if we have 2 childs */
 			if (2 * j + 1 <= q->data.binaryheap.size) {
-				// Is this child smaller than the parent?
+				/* Is this child smaller than the parent? */
 				if (BIN_HEAP_ARR(j).priority >= BIN_HEAP_ARR(2 * j).priority) i = 2 * j;
-				// Yes, we _need_ to use i here, not j, because we want to have the smallest child
-				//  This way we get that straight away!
+				/* Yes, we _need_ to use i here, not j, because we want to have the smallest child
+				 *  This way we get that straight away! */
 				if (BIN_HEAP_ARR(i).priority >= BIN_HEAP_ARR(2 * j + 1).priority) i = 2 * j + 1;
-			// Do we have one child?
+			/* Do we have one child? */
 			} else if (2 * j <= q->data.binaryheap.size) {
 				if (BIN_HEAP_ARR(j).priority >= BIN_HEAP_ARR(2 * j).priority) i = 2 * j;
 			}
 
-			// One of our childs is smaller than we are, switch
+			/* One of our childs is smaller than we are, switch */
 			if (i != j) {
 				temp = BIN_HEAP_ARR(j);
 				BIN_HEAP_ARR(j) = BIN_HEAP_ARR(i);
 				BIN_HEAP_ARR(i) = temp;
 			} else {
-				// None of our childs is smaller, so we stay here.. stop :)
+				/* None of our childs is smaller, so we stay here.. stop :) */
 				break;
 			}
 		}
@@ -261,9 +263,9 @@
 
 	if (q->data.binaryheap.size == 0) return NULL;
 
-	// The best item is always on top, so give that as result
+	/* The best item is always on top, so give that as result */
 	result = BIN_HEAP_ARR(1).item;
-	// And now we should get rid of this item...
+	/* And now we should get rid of this item... */
 	BinaryHeap_Delete(q, BIN_HEAP_ARR(1).item, BIN_HEAP_ARR(1).priority);
 
 	return result;
@@ -279,8 +281,8 @@
 	q->free = BinaryHeap_Free;
 	q->data.binaryheap.max_size = max_size;
 	q->data.binaryheap.size = 0;
-	// We malloc memory in block of BINARY_HEAP_BLOCKSIZE
-	//   It autosizes when it runs out of memory
+	/* We malloc memory in block of BINARY_HEAP_BLOCKSIZE
+	 *   It autosizes when it runs out of memory */
 	q->data.binaryheap.elements = CallocT<BinaryHeapNode*>((max_size - 1) / BINARY_HEAP_BLOCKSIZE + 1);
 	q->data.binaryheap.elements[0] = MallocT<BinaryHeapNode>(BINARY_HEAP_BLOCKSIZE);
 	q->data.binaryheap.blocks = 1;
@@ -428,7 +430,7 @@
 	h->size = 0;
 }
 
-/* Finds the node that that saves this key pair. If it is not
+/** Finds the node that that saves this key pair. If it is not
  * found, returns NULL. If it is found, *prev is set to the
  * node before the one found, or if the node found was the first in the bucket
  * to NULL. If it is not found, *prev is set to the last HashNode in the
@@ -482,7 +484,7 @@
 void* Hash_Delete(Hash* h, uint key1, uint key2)
 {
 	void* result;
-	HashNode* prev; /* Used as output var for below function call */
+	HashNode* prev; // Used as output var for below function call
 	HashNode* node = Hash_FindNode(h, key1, key2, &prev);
 
 	if (node == NULL) {
--- a/src/queue.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/queue.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1,5 +1,7 @@
 /* $Id$ */
 
+/** @file queue.h */
+
 #ifndef QUEUE_H
 #define QUEUE_H
 
@@ -64,14 +66,14 @@
 		struct {
 			uint max_size;
 			uint size;
-			uint blocks; /* The amount of blocks for which space is reserved in elements */
+			uint blocks; ///< The amount of blocks for which space is reserved in elements
 			BinaryHeapNode** elements;
 		} binaryheap;
 	} data;
 };
 
 
-/*
+/**
  * Insertion Sorter
  */
 
@@ -89,7 +91,7 @@
 /* The amount of elements that will be malloc'd at a time */
 #define BINARY_HEAP_BLOCKSIZE_BITS 10
 
-/* Initializes a binary heap and allocates internal memory for maximum of
+/** Initializes a binary heap and allocates internal memory for maximum of
  * max_size elements */
 void init_BinaryHeap(Queue* q, uint max_size);
 
@@ -124,33 +126,33 @@
 
 /* Call these function to manipulate a hash */
 
-/* Deletes the value with the specified key pair from the hash and returns
+/** Deletes the value with the specified key pair from the hash and returns
  * that value. Returns NULL when the value was not present. The value returned
  * is _not_ free()'d! */
 void* Hash_Delete(Hash* h, uint key1, uint key2);
-/* Sets the value associated with the given key pair to the given value.
+/** Sets the value associated with the given key pair to the given value.
  * Returns the old value if the value was replaced, NULL when it was not yet present. */
 void* Hash_Set(Hash* h, uint key1, uint key2, void* value);
-/* Gets the value associated with the given key pair, or NULL when it is not
+/** Gets the value associated with the given key pair, or NULL when it is not
  * present. */
 void* Hash_Get(const Hash* h, uint key1, uint key2);
 
 /* Call these function to create/destroy a hash */
 
-/* Builds a new hash in an existing struct. Make sure that hash() always
+/** Builds a new hash in an existing struct. Make sure that hash() always
  * returns a hash less than num_buckets! Call delete_hash after use */
 void init_Hash(Hash* h, Hash_HashProc* hash, uint num_buckets);
-/*
+/**
  * Deletes the hash and cleans up. Only cleans up memory allocated by new_Hash
  * & friends. If free is true, it will call free() on all the values that
  * are left in the hash.
  */
 void delete_Hash(Hash* h, bool free_values);
-/*
+/**
  * Cleans the hash, but keeps the memory allocated
  */
 void clear_Hash(Hash* h, bool free_values);
-/*
+/**
  * Gets the current size of the Hash
  */
 uint Hash_Size(const Hash* h);
--- a/src/rail_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/rail_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -12,6 +12,7 @@
 #include "table/sprites.h"
 #include "table/strings.h"
 #include "map.h"
+#include "landscape.h"
 #include "tile.h"
 #include "town_map.h"
 #include "tunnel_map.h"
@@ -1299,7 +1300,7 @@
 
 			// adjust ground tile for desert
 			// don't adjust for snow, because snow in depots looks weird
-			if (IsSnowRailGround(ti->tile) && _opt.landscape == LT_DESERT) {
+			if (IsSnowRailGround(ti->tile) && _opt.landscape == LT_TROPIC) {
 				if (image != SPR_FLAT_GRASS_TILE) {
 					image += rti->snow_offset; // tile with tracks
 				} else {
@@ -1743,14 +1744,14 @@
 	RailGroundType new_ground;
 
 	switch (_opt.landscape) {
-		case LT_HILLY:
-			if (GetTileZ(tile) > _opt.snow_line) {
+		case LT_ARCTIC:
+			if (GetTileZ(tile) > GetSnowLine()) {
 				new_ground = RAIL_GROUND_ICE_DESERT;
 				goto set_ground;
 			}
 			break;
 
-		case LT_DESERT:
+		case LT_TROPIC:
 			if (GetTropicZone(tile) == TROPICZONE_DESERT) {
 				new_ground = RAIL_GROUND_ICE_DESERT;
 				goto set_ground;
--- a/src/road_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/road_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -12,6 +12,7 @@
 #include "table/strings.h"
 #include "functions.h"
 #include "map.h"
+#include "landscape.h"
 #include "tile.h"
 #include "town_map.h"
 #include "vehicle.h"
@@ -869,14 +870,14 @@
 static void TileLoop_Road(TileIndex tile)
 {
 	switch (_opt.landscape) {
-		case LT_HILLY:
-			if (IsOnSnow(tile) != (GetTileZ(tile) > _opt.snow_line)) {
+		case LT_ARCTIC:
+			if (IsOnSnow(tile) != (GetTileZ(tile) > GetSnowLine())) {
 				ToggleSnow(tile);
 				MarkTileDirtyByTile(tile);
 			}
 			break;
 
-		case LT_DESERT:
+		case LT_TROPIC:
 			if (GetTropicZone(tile) == TROPICZONE_DESERT && !IsOnDesert(tile)) {
 				ToggleDesert(tile);
 				MarkTileDirtyByTile(tile);
@@ -914,7 +915,7 @@
 
 		{
 			/* Adjust road ground type depending on 'grp' (grp is the distance to the center) */
-			const Roadside* new_rs = (_opt.landscape == LT_CANDY) ? _town_road_types_2[grp] : _town_road_types[grp];
+			const Roadside* new_rs = (_opt.landscape == LT_TOYLAND) ? _town_road_types_2[grp] : _town_road_types[grp];
 			Roadside cur_rs = GetRoadside(tile);
 
 			/* We have our desired type, do nothing */
--- a/src/roadveh_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/roadveh_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -639,7 +639,7 @@
 		InvalidateWindow(WC_VEHICLE_DETAILS, v->index);
 
 		if (!PlayVehicleSound(v, VSE_BREAKDOWN)) {
-			SndPlayVehicleFx((_opt.landscape != LT_CANDY) ?
+			SndPlayVehicleFx((_opt.landscape != LT_TOYLAND) ?
 				SND_0F_VEHICLE_BREAKDOWN : SND_35_COMEDY_BREAKDOWN, v);
 		}
 
--- a/src/settings.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/settings.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -585,8 +585,11 @@
 	}
 	case SDT_ONEOFMANY: {
 		long r = lookup_oneofmany(desc->many, str, -1);
-		if (r != -1) return (void*)r;
-		ShowInfoF("ini: invalid value '%s' for '%s'", str, desc->name);
+		/* if the first attempt of conversion from string to the appropriate value fails,
+		 * look if we have defined a converter from old value to new value. */
+		if (r == -1 && desc->proc_cnvt != NULL) r = desc->proc_cnvt(str);
+		if (r != -1) return (void*)r; //and here goes converted value
+		ShowInfoF("ini: invalid value '%s' for '%s'", str, desc->name); //sorry, we failed
 		return 0;
 	}
 	case SDT_MANYOFMANY: {
@@ -945,15 +948,22 @@
  * If nothing fits you, you can use the GENERAL macros, but it exposes the
  * internal structure somewhat so it needs a little looking. There are _NULL()
  * macros as well, these fill up space so you can add more patches there (in
- * place) and you DON'T have to increase the savegame version. */
+ * place) and you DON'T have to increase the savegame version.
+ *
+ * While reading values from openttd.cfg, some values may not be converted
+ * properly, for any kind of reasons.  In order to allow a process of self-cleaning
+ * mechanism, a callback procedure is made available.  You will have to supply the function, which
+ * will work on a string, one function per patch.  And of course, enable the callback param
+ * on the appropriate macro.
+ */
 
-#define NSD_GENERAL(name, def, cmd, guiflags, min, max, interval, many, str, proc)\
-	{name, (const void*)(def), {cmd}, {guiflags}, min, max, interval, many, str, proc}
+#define NSD_GENERAL(name, def, cmd, guiflags, min, max, interval, many, str, proc, load)\
+	{name, (const void*)(def), {cmd}, {guiflags}, min, max, interval, many, str, proc, load}
 
 /* Macros for various objects to go in the configuration file.
  * This section is for global variables */
 #define SDTG_GENERAL(name, sdt_cmd, sle_cmd, type, flags, guiflags, var, length, def, min, max, interval, full, str, proc, from, to)\
-	{NSD_GENERAL(name, def, sdt_cmd, guiflags, min, max, interval, full, str, proc), SLEG_GENERAL(sle_cmd, var, type | flags, length, from, to)}
+	{NSD_GENERAL(name, def, sdt_cmd, guiflags, min, max, interval, full, str, proc, NULL), SLEG_GENERAL(sle_cmd, var, type | flags, length, from, to)}
 
 #define SDTG_CONDVAR(name, type, flags, guiflags, var, def, min, max, interval, str, proc, from, to)\
 	SDTG_GENERAL(name, SDT_NUMX, SL_VAR, type, flags, guiflags, var, 0, def, min, max, interval, NULL, str, proc, from, to)
@@ -986,58 +996,58 @@
 	SDTG_CONDMMANY(name, type, flags, guiflags, var, def, full, str, proc, 0, SL_MAX_VERSION)
 
 #define SDTG_CONDNULL(length, from, to)\
-	{{"", NULL, {0}, {0}, 0, 0, 0, NULL, STR_NULL, NULL}, SLEG_CONDNULL(length, from, to)}
+	{{"", NULL, {0}, {0}, 0, 0, 0, NULL, STR_NULL, NULL, NULL}, SLEG_CONDNULL(length, from, to)}
 
-#define SDTG_END() {{NULL, NULL, {0}, {0}, 0, 0, 0, NULL, STR_NULL, NULL}, SLEG_END()}
+#define SDTG_END() {{NULL, NULL, {0}, {0}, 0, 0, 0, NULL, STR_NULL, NULL, NULL}, SLEG_END()}
 
 /* Macros for various objects to go in the configuration file.
  * This section is for structures where their various members are saved */
-#define SDT_GENERAL(name, sdt_cmd, sle_cmd, type, flags, guiflags, base, var, length, def, min, max, interval, full, str, proc, from, to)\
-	{NSD_GENERAL(name, def, sdt_cmd, guiflags, min, max, interval, full, str, proc), SLE_GENERAL(sle_cmd, base, var, type | flags, length, from, to)}
+#define SDT_GENERAL(name, sdt_cmd, sle_cmd, type, flags, guiflags, base, var, length, def, min, max, interval, full, str, proc, load, from, to)\
+	{NSD_GENERAL(name, def, sdt_cmd, guiflags, min, max, interval, full, str, proc, load), SLE_GENERAL(sle_cmd, base, var, type | flags, length, from, to)}
 
 #define SDT_CONDVAR(base, var, type, from, to, flags, guiflags, def, min, max, interval, str, proc)\
-	SDT_GENERAL(#var, SDT_NUMX, SL_VAR, type, flags, guiflags, base, var, 1, def, min, max, interval, NULL, str, proc, from, to)
+	SDT_GENERAL(#var, SDT_NUMX, SL_VAR, type, flags, guiflags, base, var, 1, def, min, max, interval, NULL, str, proc, NULL, from, to)
 #define SDT_VAR(base, var, type, flags, guiflags, def, min, max, interval, str, proc)\
 	SDT_CONDVAR(base, var, type, 0, SL_MAX_VERSION, flags, guiflags, def, min, max, interval, str, proc)
 
 #define SDT_CONDBOOL(base, var, from, to, flags, guiflags, def, str, proc)\
-	SDT_GENERAL(#var, SDT_BOOLX, SL_VAR, SLE_BOOL, flags, guiflags, base, var, 1, def, 0, 1, 0, NULL, str, proc, from, to)
+	SDT_GENERAL(#var, SDT_BOOLX, SL_VAR, SLE_BOOL, flags, guiflags, base, var, 1, def, 0, 1, 0, NULL, str, proc, NULL, from, to)
 #define SDT_BOOL(base, var, flags, guiflags, def, str, proc)\
 	SDT_CONDBOOL(base, var, 0, SL_MAX_VERSION, flags, guiflags, def, str, proc)
 
 #define SDT_CONDLIST(base, var, type, from, to, flags, guiflags, def, str, proc)\
-	SDT_GENERAL(#var, SDT_INTLIST, SL_ARR, type, flags, guiflags, base, var, lengthof(((base*)8)->var), def, 0, 0, 0, NULL, str, proc, from, to)
+	SDT_GENERAL(#var, SDT_INTLIST, SL_ARR, type, flags, guiflags, base, var, lengthof(((base*)8)->var), def, 0, 0, 0, NULL, str, proc, NULL, from, to)
 #define SDT_LIST(base, var, type, flags, guiflags, def, str, proc)\
 	SDT_CONDLIST(base, var, type, 0, SL_MAX_VERSION, flags, guiflags, def, str, proc)
 #define SDT_CONDLISTO(base, var, length, type, from, to, flags, guiflags, def, str, proc)\
-	SDT_GENERAL(#var, SDT_INTLIST, SL_ARR, type, flags, guiflags, base, var, length, def, 0, 0, 0, NULL, str, proc, from, to)
+	SDT_GENERAL(#var, SDT_INTLIST, SL_ARR, type, flags, guiflags, base, var, length, def, 0, 0, 0, NULL, str, proc, NULL, from, to)
 
 #define SDT_CONDSTR(base, var, type, from, to, flags, guiflags, def, str, proc)\
-	SDT_GENERAL(#var, SDT_STRING, SL_STR, type, flags, guiflags, base, var, lengthof(((base*)8)->var), def, 0, 0, 0, NULL, str, proc, from, to)
+	SDT_GENERAL(#var, SDT_STRING, SL_STR, type, flags, guiflags, base, var, lengthof(((base*)8)->var), def, 0, 0, 0, NULL, str, proc, NULL, from, to)
 #define SDT_STR(base, var, type, flags, guiflags, def, str, proc)\
 	SDT_CONDSTR(base, var, type, 0, SL_MAX_VERSION, flags, guiflags, def, str, proc)
 #define SDT_CONDSTRO(base, var, length, type, from, to, flags, def, str, proc)\
 	SDT_GENERAL(#var, SDT_STRING, SL_STR, type, flags, 0, base, var, length, def, 0, 0, NULL, str, proc, from, to)
 
 #define SDT_CONDCHR(base, var, from, to, flags, guiflags, def, str, proc)\
-	SDT_GENERAL(#var, SDT_STRING, SL_VAR, SLE_CHAR, flags, guiflags, base, var, 1, def, 0, 0, 0, NULL, str, proc, from, to)
+	SDT_GENERAL(#var, SDT_STRING, SL_VAR, SLE_CHAR, flags, guiflags, base, var, 1, def, 0, 0, 0, NULL, str, proc, NULL, from, to)
 #define SDT_CHR(base, var, flags, guiflags, def, str, proc)\
 	SDT_CONDCHR(base, var, 0, SL_MAX_VERSION, flags, guiflags, def, str, proc)
 
-#define SDT_CONDOMANY(base, var, type, from, to, flags, guiflags, def, max, full, str, proc)\
-	SDT_GENERAL(#var, SDT_ONEOFMANY, SL_VAR, type, flags, guiflags, base, var, 1, def, 0, max, 0, full, str, proc, from, to)
-#define SDT_OMANY(base, var, type, flags, guiflags, def, max, full, str, proc)\
-	SDT_CONDOMANY(base, var, type, 0, SL_MAX_VERSION, flags, guiflags, def, max, full, str, proc)
+#define SDT_CONDOMANY(base, var, type, from, to, flags, guiflags, def, max, full, str, proc, load)\
+	SDT_GENERAL(#var, SDT_ONEOFMANY, SL_VAR, type, flags, guiflags, base, var, 1, def, 0, max, 0, full, str, proc, load, from, to)
+#define SDT_OMANY(base, var, type, flags, guiflags, def, max, full, str, proc, load)\
+	SDT_CONDOMANY(base, var, type, 0, SL_MAX_VERSION, flags, guiflags, def, max, full, str, proc, load)
 
 #define SDT_CONDMMANY(base, var, type, from, to, flags, guiflags, def, full, str, proc)\
-	SDT_GENERAL(#var, SDT_MANYOFMANY, SL_VAR, type, flags, guiflags, base, var, 1, def, 0, 0, 0, full, str, proc, from, to)
+	SDT_GENERAL(#var, SDT_MANYOFMANY, SL_VAR, type, flags, guiflags, base, var, 1, def, 0, 0, 0, full, str, proc, NULL, from, to)
 #define SDT_MMANY(base, var, type, flags, guiflags, def, full, str, proc)\
 	SDT_CONDMMANY(base, var, type, 0, SL_MAX_VERSION, flags, guiflags, def, full, str, proc)
 
 #define SDT_CONDNULL(length, from, to)\
-	{{"", NULL, {0}, {0}, 0, 0, 0, NULL, STR_NULL, NULL}, SLE_CONDNULL(length, from, to)}
+	{{"", NULL, {0}, {0}, 0, 0, 0, NULL, STR_NULL, NULL, NULL}, SLE_CONDNULL(length, from, to)}
 
-#define SDT_END() {{NULL, NULL, {0}, {0}, 0, 0, 0, NULL, STR_NULL, NULL}, SLE_END()}
+#define SDT_END() {{NULL, NULL, {0}, {0}, 0, 0, 0, NULL, STR_NULL, NULL, NULL}, SLE_END()}
 
 /* Shortcuts for macros below. Logically if we don't save the value
  * we also don't sync it in a network game */
@@ -1149,6 +1159,18 @@
 	DoCommandP(0, 2, _patches.autorenew_money, NULL, CMD_SET_AUTOREPLACE);
 	return 0;
 }
+/** Conversion callback for _gameopt_settings.landscape
+ * It converts (or try) between old values and the new ones,
+ * without loosing initial setting  of the user
+ * @param value that was read from config file
+ * @return the "hopefully" converted value
+ */
+static int32 ConvertLandscape(const char *value)
+{
+	/* try with the old values */
+	return lookup_oneofmany("normal|hilly|desert|candy", value, -1);
+}
+
 /* End - Callback Functions */
 
 #ifndef EXTERNAL_PLAYER
@@ -1241,18 +1263,18 @@
 	 * XXX - To save file-space and since values are never bigger than about 10? only
 	 * save the first 16 bits in the savegame. Question is why the values are still int32
 	 * and why not byte for example? */
-	SDT_GENERAL("diff_custom", SDT_INTLIST, SL_ARR, (SLE_FILE_I16 | SLE_VAR_I32), 0, 0, GameOptions, diff, 17, 0, 0, 0, 0, NULL, STR_NULL, NULL,  0, 3),
-	SDT_GENERAL("diff_custom", SDT_INTLIST, SL_ARR, (SLE_FILE_I16 | SLE_VAR_I32), 0, 0, GameOptions, diff, 18, 0, 0, 0, 0, NULL, STR_NULL, NULL,  4, 53),
-	SDT_GENERAL("diff_custom", SDT_INTLIST, SL_ARR, (SLE_FILE_I16 | SLE_VAR_I32), 0, 0, GameOptions, diff, 20, 0, 0, 0, 0, NULL, STR_NULL, NULL, 54, SL_MAX_VERSION),
+	SDT_GENERAL("diff_custom", SDT_INTLIST, SL_ARR, (SLE_FILE_I16 | SLE_VAR_I32), 0, 0, GameOptions, diff, 17, 0, 0, 0, 0, NULL, STR_NULL, NULL, NULL,  0, 3),
+	SDT_GENERAL("diff_custom", SDT_INTLIST, SL_ARR, (SLE_FILE_I16 | SLE_VAR_I32), 0, 0, GameOptions, diff, 18, 0, 0, 0, 0, NULL, STR_NULL, NULL, NULL,  4, 53),
+	SDT_GENERAL("diff_custom", SDT_INTLIST, SL_ARR, (SLE_FILE_I16 | SLE_VAR_I32), 0, 0, GameOptions, diff, 20, 0, 0, 0, 0, NULL, STR_NULL, NULL, NULL, 54, SL_MAX_VERSION),
 	    SDT_VAR(GameOptions, diff_level,SLE_UINT8, 0, 0, 9, 0,  9, 0, STR_NULL, NULL),
-	  SDT_OMANY(GameOptions, currency,  SLE_UINT8, N, 0, 0, CUSTOM_CURRENCY_ID, "GBP|USD|EUR|YEN|ATS|BEF|CHF|CZK|DEM|DKK|ESP|FIM|FRF|GRD|HUF|ISK|ITL|NLG|NOK|PLN|ROL|RUR|SIT|SEK|YTL|SKK|BRR|custom", STR_NULL, NULL),
-	  SDT_OMANY(GameOptions, units,     SLE_UINT8, N, 0, 1,     2, "imperial|metric|si", STR_NULL, NULL),
-	  SDT_OMANY(GameOptions, town_name, SLE_UINT8, 0, 0, 0,    20, "english|french|german|american|latin|silly|swedish|dutch|finnish|polish|slovakish|norwegian|hungarian|austrian|romanian|czech|swiss|danish|turkish|italian|catalan", STR_NULL, NULL),
-	  SDT_OMANY(GameOptions, landscape, SLE_UINT8, 0, 0, 0,     3, "normal|hilly|desert|candy", STR_NULL, NULL),
+	  SDT_OMANY(GameOptions, currency,  SLE_UINT8, N, 0, 0, CUSTOM_CURRENCY_ID, "GBP|USD|EUR|YEN|ATS|BEF|CHF|CZK|DEM|DKK|ESP|FIM|FRF|GRD|HUF|ISK|ITL|NLG|NOK|PLN|ROL|RUR|SIT|SEK|YTL|SKK|BRR|custom", STR_NULL, NULL, NULL),
+	  SDT_OMANY(GameOptions, units,     SLE_UINT8, N, 0, 1,     2, "imperial|metric|si", STR_NULL, NULL, NULL),
+	  SDT_OMANY(GameOptions, town_name, SLE_UINT8, 0, 0, 0,    20, "english|french|german|american|latin|silly|swedish|dutch|finnish|polish|slovakish|norwegian|hungarian|austrian|romanian|czech|swiss|danish|turkish|italian|catalan", STR_NULL, NULL, NULL),
+	  SDT_OMANY(GameOptions, landscape, SLE_UINT8, 0, 0, 0,     3, "temperate|arctic|tropic|toyland", STR_NULL, NULL, ConvertLandscape),
 	    SDT_VAR(GameOptions, snow_line, SLE_UINT8, 0, 0, 1, 0, 56, 0, STR_NULL, NULL),
-	SDT_CONDOMANY(GameOptions,autosave, SLE_UINT8, 0, 22,             N, 0, 0, 0, "", STR_NULL, NULL),
-	SDT_CONDOMANY(GameOptions,autosave, SLE_UINT8,23, SL_MAX_VERSION, S, 0, 1, 4, "off|monthly|quarterly|half year|yearly", STR_NULL, NULL),
-	  SDT_OMANY(GameOptions, road_side, SLE_UINT8, 0, 0, 1,   1, "left|right", STR_NULL, NULL),
+	SDT_CONDOMANY(GameOptions,autosave, SLE_UINT8, 0, 22,             N, 0, 0, 0, "", STR_NULL, NULL, NULL),
+	SDT_CONDOMANY(GameOptions,autosave, SLE_UINT8,23, SL_MAX_VERSION, S, 0, 1, 4, "off|monthly|quarterly|half year|yearly", STR_NULL, NULL, NULL),
+	  SDT_OMANY(GameOptions, road_side, SLE_UINT8, 0, 0, 1,   1, "left|right", STR_NULL, NULL, NULL),
 	    SDT_END()
 };
 
@@ -1357,7 +1379,7 @@
 	 SDT_VAR(Patches, starting_year,    SLE_INT32, 0,NC,  1950, MIN_YEAR, MAX_YEAR, 1, STR_CONFIG_PATCHES_STARTING_YEAR,NULL),
 	 SDT_VAR(Patches, ending_year,      SLE_INT32,0,NC|NO,2051, MIN_YEAR, MAX_YEAR, 1, STR_CONFIG_PATCHES_ENDING_YEAR,  NULL),
 	SDT_BOOL(Patches, smooth_economy,             0, 0,  true,            STR_CONFIG_PATCHES_SMOOTH_ECONOMY,   NULL),
-	SDT_BOOL(Patches, allow_shares,               0, 0,  true,            STR_CONFIG_PATCHES_ALLOW_SHARES,     NULL),
+	SDT_BOOL(Patches, allow_shares,               0, 0, false,            STR_CONFIG_PATCHES_ALLOW_SHARES,     NULL),
 
 	/***************************************************************************/
 	/* AI section of the GUI-configure patches window */
@@ -1475,7 +1497,7 @@
 	/***************************************************************************/
 	/* Terrain genation related patch options */
 	SDT_CONDVAR(Patches,      land_generator,           SLE_UINT8,  30, SL_MAX_VERSION, 0, MS,   1,                   0,    1,               0, STR_CONFIG_PATCHES_LAND_GENERATOR,           NULL),
-	SDT_CONDVAR(Patches,      oil_refinery_limit,       SLE_UINT8,  30, SL_MAX_VERSION, 0, 0,   16,                  12,   48,               0, STR_CONFIG_PATCHES_OIL_REF_EDGE_DISTANCE,    NULL),
+	SDT_CONDVAR(Patches,      oil_refinery_limit,       SLE_UINT8,  30, SL_MAX_VERSION, 0, 0,   32,                  12,   48,               0, STR_CONFIG_PATCHES_OIL_REF_EDGE_DISTANCE,    NULL),
 	SDT_CONDVAR(Patches,      tgen_smoothness,          SLE_UINT8,  30, SL_MAX_VERSION, 0, MS,   1,                   0,    3,               0, STR_CONFIG_PATCHES_ROUGHNESS_OF_TERRAIN,     NULL),
 	SDT_CONDVAR(Patches,      generation_seed,          SLE_UINT32, 30, SL_MAX_VERSION, 0, 0,    GENERATE_NEW_SEED,   0, MAX_UVALUE(uint32), 0, STR_NULL,                                    NULL),
 	SDT_CONDVAR(Patches,      tree_placer,              SLE_UINT8,  30, SL_MAX_VERSION, 0, MS,   2,                   0,    2,               0, STR_CONFIG_PATCHES_TREE_PLACER,              NULL),
--- a/src/settings.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/settings.h	Thu Apr 19 14:43:25 2007 +0000
@@ -44,7 +44,8 @@
 typedef TinyEnumT<SettingGuiFlagLong> SettingGuiFlag;
 
 
-typedef int32 OnChange(int32 var);
+typedef int32 OnChange(int32 var);          ///< callback prototype on data modification
+typedef int32 OnConvert(const char *value); ///< callback prototype for convertion error
 
 struct SettingDescBase {
 	const char *name;       ///< name of the setting. Used in configuration file and for console
@@ -56,6 +57,7 @@
 	const char *many;       ///< ONE/MANY_OF_MANY: string of possible values for this type
 	StringID str;           ///< (translated) string with descriptive text; gui and console
 	OnChange *proc;         ///< callback procedure for when the value is changed
+	OnConvert *proc_cnvt;   ///< callback procedure when loading value mechanism fails
 };
 
 struct SettingDesc {
--- a/src/ship_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/ship_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -208,7 +208,7 @@
 		InvalidateWindow(WC_VEHICLE_DETAILS, v->index);
 
 		if (!PlayVehicleSound(v, VSE_BREAKDOWN)) {
-			SndPlayVehicleFx((_opt.landscape != LT_CANDY) ?
+			SndPlayVehicleFx((_opt.landscape != LT_TOYLAND) ?
 				SND_10_TRAIN_BREAKDOWN : SND_3A_COMEDY_BREAKDOWN_2, v);
 		}
 
--- a/src/smallmap_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/smallmap_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -492,7 +492,7 @@
 
 		case MP_TREES:
 			if (GetTreeGround(tile) == TREE_GROUND_SNOW_DESERT) {
-				bits = (_opt.landscape == LT_HILLY) ? MKCOLOR(0x98575798) : MKCOLOR(0xC25757C2);
+				bits = (_opt.landscape == LT_ARCTIC) ? MKCOLOR(0x98575798) : MKCOLOR(0xC25757C2);
 			} else {
 				bits = MKCOLOR(0x54575754);
 			}
--- a/src/station_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/station_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -250,7 +250,7 @@
 				CountMapSquareAround(tile, MP_TREES, 0) >= 8 ||
 				CountMapSquareAround(tile, MP_INDUSTRY, IT_FOREST) >= 2)
 			) {
-		found = _opt.landscape == LT_DESERT ?
+		found = _opt.landscape == LT_TROPIC ?
 			M(STR_SV_STNAME_FOREST) : M(STR_SV_STNAME_WOODS);
 		goto done;
 	}
@@ -352,7 +352,7 @@
 {
 	uint mask = 0;
 
-	for (uint i = 0; i != NUM_CARGO; i++) {
+	for (CargoID i = 0; i < NUM_CARGO; i++) {
 		if (st->goods[i].waiting_acceptance & 0x8000) mask |= 1 << i;
 	}
 	return mask;
@@ -525,7 +525,7 @@
 	}
 
 	// Adjust in case our station only accepts fewer kinds of goods
-	for (uint i = 0; i != NUM_CARGO; i++) {
+	for (CargoID i = 0; i < NUM_CARGO; i++) {
 		uint amt = min(accepts[i], 15);
 
 		// Make sure the station can accept the goods type.
@@ -2336,7 +2336,7 @@
 	FOR_ALL_STATIONS(st) {
 		if (st->owner == owner &&
 				DistanceManhattan(tile, st->xy) <= radius) {
-			for (uint i = 0; i != NUM_CARGO; i++) {
+			for (CargoID i = 0; i < NUM_CARGO; i++) {
 				GoodsEntry* ge = &st->goods[i];
 
 				if (ge->enroute_from != INVALID_STATION) {
@@ -2347,7 +2347,7 @@
 	}
 }
 
-static void UpdateStationWaiting(Station *st, int type, uint amount)
+static void UpdateStationWaiting(Station *st, CargoID type, uint amount)
 {
 	SB(st->goods[type].waiting_acceptance, 0, 12,
 		min(0xFFF, GB(st->goods[type].waiting_acceptance, 0, 12) + amount)
@@ -2391,7 +2391,7 @@
 }
 
 
-uint MoveGoodsToStation(TileIndex tile, int w, int h, int type, uint amount)
+uint MoveGoodsToStation(TileIndex tile, int w, int h, CargoID type, uint amount)
 {
 	Station* around[8];
 
@@ -2553,7 +2553,7 @@
 	st->facilities = FACIL_AIRPORT | FACIL_DOCK;
 	st->build_date = _date;
 
-	for (uint j = 0; j != NUM_CARGO; j++) {
+	for (CargoID j = 0; j < NUM_CARGO; j++) {
 		st->goods[j].waiting_acceptance = 0;
 		st->goods[j].days_since_pickup = 0;
 		st->goods[j].enroute_from = INVALID_STATION;
@@ -2801,7 +2801,7 @@
 static void SaveLoad_STNS(Station *st)
 {
 	SlObject(st, _station_desc);
-	for (uint i = 0; i != NUM_CARGO; i++) {
+	for (CargoID i = 0; i < NUM_CARGO; i++) {
 		SlObject(&st->goods[i], _goods_desc);
 	}
 
--- a/src/station_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/station_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -364,7 +364,7 @@
 				x = DrawString(xb, y, STR_3049_0, 0) + 5;
 
 				// show cargo waiting and station ratings
-				for (CargoID j = 0; j != NUM_CARGO; j++) {
+				for (CargoID j = 0; j < NUM_CARGO; j++) {
 					uint amount = GB(st->goods[j].waiting_acceptance, 0, 12);
 					if (amount != 0) {
 						StationsWndShowStationRating(x, y, j, amount, st->goods[j].rating);
@@ -667,6 +667,30 @@
 {   WIDGETS_END},
 };
 
+
+static void DrawCargoIcons(CargoID i, uint waiting, int x, int y)
+{
+	uint num = min((waiting + 5) / 10, 23);
+	if (num == 0) return;
+
+	const CargoSpec *cs = GetCargo(i);
+	SpriteID sprite;
+
+	if (cs->sprite == 0xFFFF) {
+		/* A value of 0xFFFF indicates we should draw a custom icon */
+		sprite = GetCustomCargoSprite(cs);
+	} else {
+		sprite = cs->sprite;
+	}
+
+	if (sprite == 0) return;
+
+	do {
+		DrawSprite(sprite, PAL_NONE, x, y);
+		x += 10;
+	} while (--num);
+}
+
 static void DrawStationViewWindow(Window *w)
 {
 	StationID station_id = w->window_number;
@@ -677,7 +701,7 @@
 	StringID str;
 
 	num = 1;
-	for (CargoID i = 0; i != NUM_CARGO; i++) {
+	for (CargoID i = 0; i < NUM_CARGO; i++) {
 		if (GB(st->goods[i].waiting_acceptance, 0, 12) != 0) {
 			num++;
 			if (st->goods[i].enroute_from != station_id) num++;
@@ -701,7 +725,7 @@
 
 	if (--pos < 0) {
 		str = STR_00D0_NOTHING;
-		for (CargoID i = 0; i != NUM_CARGO; i++) {
+		for (CargoID i = 0; i < NUM_CARGO; i++) {
 			if (GB(st->goods[i].waiting_acceptance, 0, 12) != 0) str = STR_EMPTY;
 		}
 		SetDParam(0, str);
@@ -709,22 +733,13 @@
 		y += 10;
 	}
 
-	for (CargoID i = 0; i != NUM_CARGO && pos > -5; i++) {
+	for (CargoID i = 0; i < NUM_CARGO && pos > -5; i++) {
 		uint waiting = GB(st->goods[i].waiting_acceptance, 0, 12);
 		if (waiting == 0) continue;
 
-		num = (waiting + 5) / 10;
-		if (num != 0) {
-			int cur_x = x;
-			num = min(num, 23);
-			do {
-				DrawSprite(GetCargo(i)->sprite, PAL_NONE, cur_x, y);
-				cur_x += 10;
-			} while (--num);
-		}
-
 		if (st->goods[i].enroute_from == station_id) {
 			if (--pos < 0) {
+				DrawCargoIcons(i, waiting, x, y);
 				SetDParam(1, waiting);
 				SetDParam(0, i);
 				DrawStringRightAligned(x + 234, y, STR_0009, 0);
@@ -733,6 +748,7 @@
 		} else {
 			/* enroute */
 			if (--pos < 0) {
+				DrawCargoIcons(i, waiting, x, y);
 				SetDParam(1, waiting);
 				SetDParam(0, i);
 				DrawStringRightAligned(x + 234, y, STR_000A_EN_ROUTE_FROM, 0);
@@ -753,7 +769,7 @@
 
 		b = InlineString(b, STR_000C_ACCEPTS);
 
-		for (CargoID i = 0; i != NUM_CARGO; i++) {
+		for (CargoID i = 0; i < NUM_CARGO; i++) {
 			if (b >= endof(_userstring) - 5 - 1) break;
 			if (st->goods[i].waiting_acceptance & 0x8000) {
 				if (first) {
@@ -776,7 +792,7 @@
 		DrawString(2, 67, STR_3034_LOCAL_RATING_OF_TRANSPORT, 0);
 
 		y = 77;
-		for (CargoID i = 0; i != NUM_CARGO; i++) {
+		for (CargoID i = 0; i < NUM_CARGO; i++) {
 			const CargoSpec *cs = GetCargo(i);
 			if (!cs->IsValid()) continue;
 
--- a/src/strings.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/strings.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -585,9 +585,15 @@
 					}
 
 					default:
-						buff = FormatCommaNumber(buff, GetInt32(&argv), last);
-						buff = strecpy(buff, " ", last);
-						buff = strecpy(buff, GetStringPtr(cargo_str), last);
+						if (cargo_str >= 0xE000 && cargo_str < 0xF800) {
+							/* NewGRF strings from Action 4 use a different format here,
+							 * of e.g. "x tonnes of coal", so process accordingly. */
+							buff = GetStringWithArgs(buff, cargo_str, argv++, last);
+						} else {
+							buff = FormatCommaNumber(buff, GetInt32(&argv), last);
+							buff = strecpy(buff, " ", last);
+							buff = strecpy(buff, GetStringPtr(cargo_str), last);
+						}
 						break;
 				}
 			} break;
@@ -953,7 +959,7 @@
 	const char* const* base;
 	uint num;
 
-	if (_opt_ptr->landscape == LT_CANDY) {
+	if (_opt_ptr->landscape == LT_TOYLAND) {
 		base = _silly_surname_list;
 		num  = lengthof(_silly_surname_list);
 	} else {
@@ -983,7 +989,7 @@
 		buff = strecpy(buff, initial, last);
 	}
 
-	if (_opt_ptr->landscape == LT_CANDY) {
+	if (_opt_ptr->landscape == LT_TOYLAND) {
 		base = _silly_surname_list;
 		num  = lengthof(_silly_surname_list);
 	} else {
@@ -1116,7 +1122,8 @@
 	free(_langpack_offs);
 	_langpack_offs = langpack_offs;
 
-	ttd_strlcpy(_dynlang.curr_file, _dynlang.ent[lang_index].file, lengthof(_dynlang.curr_file));
+	const char *c_file = strrchr(_dynlang.ent[lang_index].file, PATHSEPCHAR) + 1;
+	ttd_strlcpy(_dynlang.curr_file, c_file, lengthof(_dynlang.curr_file));
 
 	_dynlang.curr = lang_index;
 	SetCurrentGrfLangID(_langpack->isocode);
@@ -1165,7 +1172,7 @@
 static bool UniqueLanguageFile(const Language *langs, uint max, const char *language)
 {
 	for (uint i = 0; i < max; i++) {
-		const char *f_name = strrchr(langs[i].file, PATHSEPCHAR);
+		const char *f_name = strrchr(langs[i].file, PATHSEPCHAR) + 1;
 		if (strcmp(f_name, language) == 0) return false; // duplicates
 	}
 
@@ -1268,7 +1275,8 @@
 		/* We are trying to find a default language. The priority is by
 		 * configuration file, local environment and last, if nothing found,
 		 * english. If def equals -1, we have not picked a default language */
-		if (strcmp(dl->ent[dl->num].file, dl->curr_file) == 0) chosen_language = dl->num;
+		const char *lang_file = strrchr(dl->ent[dl->num].file, PATHSEPCHAR) + 1;
+		if (strcmp(lang_file, dl->curr_file) == 0) chosen_language = dl->num;
 
 		if (chosen_language == -1) {
 			if (strcmp (hdr.isocode, "en_GB") == 0) en_GB_fallback    = dl->num;
--- a/src/table/build_industry.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/table/build_industry.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1100,7 +1100,7 @@
 	   IT_POWER_STATION,  IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_COAL,       15, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_NORMAL | 1 << LT_HILLY,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TEMPERATE | 1 << LT_ARCTIC,
 	   STR_4802_COAL_MINE,                     STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4836_NEW_COAL_SEAM_FOUND_AT,   STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1108,7 +1108,7 @@
 	   IT_COAL_MINE,      IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_INVALID,     0, CT_INVALID,       0, 5,
 	   CT_COAL,           CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_NOT_CLOSABLE,              1 << LT_NORMAL | 1 << LT_HILLY,
+	   INDUSTRYLIFE_NOT_CLOSABLE,              1 << LT_TEMPERATE | 1 << LT_ARCTIC,
 	   STR_4803_POWER_STATION,                 STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1116,7 +1116,7 @@
 	   IT_FOREST,         IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_GOODS,       0, CT_INVALID,       0, 5,
 	   CT_WOOD,           CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_NORMAL,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_TEMPERATE,
 	   STR_4804_SAWMILL,                       STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1124,7 +1124,7 @@
 	   IT_SAWMILL,        IT_PAPER_MILL,       IT_INVALID,       CHECK_FOREST,
 	   CT_WOOD,       13, CT_INVALID,       0, 30,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_NORMAL | 1 << LT_HILLY,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TEMPERATE | 1 << LT_ARCTIC,
 	   STR_4805_FOREST,                        STR_482E_NEW_BEING_PLANTED_NEAR,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_483A_INSECT_INFESTATION_CAUSES),
 
@@ -1132,7 +1132,7 @@
 	   IT_OIL_RIG,        IT_INVALID,          IT_INVALID,       CHECK_REFINERY,
 	   CT_GOODS,       0, CT_INVALID,       0, 5,
 	   CT_OIL,            CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_NORMAL | 1 << LT_HILLY | 1 << LT_DESERT,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_TEMPERATE | 1 << LT_ARCTIC | 1 << LT_TROPIC,
 	   STR_4806_OIL_REFINERY,                  STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1140,7 +1140,7 @@
 	   IT_OIL_REFINERY,   IT_INVALID,          IT_INVALID,       CHECK_OIL_RIG,
 	   CT_OIL,        15, CT_PASSENGERS,    2, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_NORMAL,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TEMPERATE,
 	   STR_4807_OIL_RIG,                       STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4837_NEW_OIL_RESERVES_FOUND,   STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1148,7 +1148,7 @@
 	   IT_FARM,           IT_STEEL_MILL,       IT_INVALID,       CHECK_NOTHING,
 	   CT_GOODS,       0, CT_INVALID,       0, 5,
 	   CT_LIVESTOCK,      CT_GRAIN,            CT_STEEL,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_NORMAL,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_TEMPERATE,
 	   STR_4808_FACTORY,                       STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1156,7 +1156,7 @@
 	   IT_PAPER_MILL,     IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_GOODS,       0, CT_INVALID,       0, 5,
 	   CT_PAPER,          CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_HILLY,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_ARCTIC,
 	   STR_4809_PRINTING_WORKS,                STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1164,7 +1164,7 @@
 	   IT_IRON_MINE,      IT_FACTORY,          IT_INVALID,       CHECK_NOTHING,
 	   CT_STEEL,       0, CT_INVALID,       0, 5,
 	   CT_IRON_ORE,       CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_NORMAL,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_TEMPERATE,
 	   STR_480A_STEEL_MILL,                    STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1172,7 +1172,7 @@
 	   IT_FACTORY,        IT_FOOD_PROCESS,     IT_INVALID,       CHECK_FARM,
 	   CT_GRAIN,      10, CT_LIVESTOCK,    10, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_NORMAL | 1 << LT_HILLY,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TEMPERATE | 1 << LT_ARCTIC,
 	   STR_480B_FARM,                          STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4838_IMPROVED_FARMING_METHODS, STR_483A_INSECT_INFESTATION_CAUSES),
 
@@ -1180,7 +1180,7 @@
 	   IT_FACTORY_2,      IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_COPPER_ORE, 10, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_DESERT,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TROPIC,
 	   STR_480C_COPPER_ORE_MINE,               STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1188,7 +1188,7 @@
 	   IT_OIL_REFINERY,   IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_OIL,        12, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_NORMAL | 1 << LT_HILLY | 1 << LT_DESERT,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TEMPERATE | 1 << LT_ARCTIC | 1 << LT_TROPIC,
 	   STR_480D_OIL_WELLS,                     STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4837_NEW_OIL_RESERVES_FOUND,   STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1196,7 +1196,7 @@
 	   IT_BANK_TEMP,      IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_VALUABLES,   6, CT_INVALID,       0, 5,
 	   CT_VALUABLES,      CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_NOT_CLOSABLE,              1 << LT_NORMAL,
+	   INDUSTRYLIFE_NOT_CLOSABLE,              1 << LT_TEMPERATE,
 	   STR_480E_BANK,                          STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1204,7 +1204,7 @@
 	   IT_FRUIT_PLANTATION, IT_FARM,           IT_FARM_2,        CHECK_NOTHING,
 	   CT_FOOD,        0, CT_INVALID,       0, 5,
 	   CT_FRUIT,          CT_MAIZE,            CT_INVALID,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_HILLY | 1 << LT_DESERT,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_ARCTIC | 1 << LT_TROPIC,
 	   STR_480F_FOOD_PROCESSING_PLANT,         STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1212,7 +1212,7 @@
 	   IT_FOREST,         IT_PRINTING_WORKS,   IT_INVALID,       CHECK_NOTHING,
 	   CT_PAPER,       0, CT_INVALID,       0, 5,
 	   CT_WOOD,           CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_HILLY,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_ARCTIC,
 	   STR_4810_PAPER_MILL,                    STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1220,7 +1220,7 @@
 	   IT_BANK_TROPIC_ARCTIC, IT_INVALID,      IT_INVALID,       CHECK_NOTHING,
 	   CT_GOLD,        7, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_DESERT,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TROPIC,
 	   STR_4811_GOLD_MINE,                     STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1228,7 +1228,7 @@
 	   IT_GOLD_MINE,      IT_DIAMOND_MINE,     IT_INVALID,       CHECK_NOTHING,
 	   CT_INVALID,     0, CT_INVALID,       0, 5,
 	   CT_GOLD,           CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_NOT_CLOSABLE,              1 << LT_HILLY | 1 << LT_DESERT,
+	   INDUSTRYLIFE_NOT_CLOSABLE,              1 << LT_ARCTIC | 1 << LT_TROPIC,
 	   STR_4812_BANK,                          STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1236,7 +1236,7 @@
 	   IT_BANK_TROPIC_ARCTIC, IT_INVALID,      IT_INVALID,       CHECK_NOTHING,
 	   CT_DIAMONDS,    7, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_DESERT,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TROPIC,
 	   STR_4813_DIAMOND_MINE,                  STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1244,7 +1244,7 @@
 	   IT_STEEL_MILL,     IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_IRON_ORE,   10, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_NORMAL,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TEMPERATE,
 	   STR_4814_IRON_ORE_MINE,                 STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1252,7 +1252,7 @@
 	   IT_FOOD_PROCESS,   IT_INVALID,          IT_INVALID,       CHECK_PLANTATION,
 	   CT_FRUIT,      10, CT_INVALID,       0, 15,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_DESERT,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TROPIC,
 	   STR_4815_FRUIT_PLANTATION,              STR_482E_NEW_BEING_PLANTED_NEAR,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4838_IMPROVED_FARMING_METHODS, STR_483A_INSECT_INFESTATION_CAUSES),
 
@@ -1260,7 +1260,7 @@
 	   IT_FACTORY_2,      IT_INVALID,          IT_INVALID,       CHECK_PLANTATION,
 	   CT_RUBBER,     10, CT_INVALID,       0, 15,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_DESERT,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TROPIC,
 	   STR_4816_RUBBER_PLANTATION,             STR_482E_NEW_BEING_PLANTED_NEAR,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4838_IMPROVED_FARMING_METHODS, STR_483A_INSECT_INFESTATION_CAUSES),
 
@@ -1268,7 +1268,7 @@
 	   IT_WATER_TOWER,    IT_INVALID,          IT_INVALID,       CHECK_WATER,
 	   CT_WATER,      12, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_DESERT,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TROPIC,
 	   STR_4817_WATER_SUPPLY,                  STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1276,7 +1276,7 @@
 	   IT_WATER_SUPPLY,   IT_INVALID,          IT_INVALID,       CHECK_WATER,
 	   CT_INVALID,     0, CT_INVALID,       0, 5,
 	   CT_WATER,          CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_NOT_CLOSABLE,              1 << LT_DESERT,
+	   INDUSTRYLIFE_NOT_CLOSABLE,              1 << LT_TROPIC,
 	   STR_4818_WATER_TOWER,                   STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1284,7 +1284,7 @@
 	   IT_RUBBER_PLANTATION, IT_COPPER_MINE,   IT_LUMBER_MILL,   CHECK_PLANTATION,
 	   CT_GOODS,       0, CT_INVALID,       0, 5,
 	   CT_RUBBER,         CT_COPPER_ORE,       CT_WOOD,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_DESERT,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_TROPIC,
 	   STR_4819_FACTORY,                       STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1292,7 +1292,7 @@
 	   IT_FOOD_PROCESS,   IT_INVALID,          IT_INVALID,       CHECK_PLANTATION,
 	   CT_MAIZE,      11, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_DESERT,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TROPIC,
 	   STR_481A_FARM,                          STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4838_IMPROVED_FARMING_METHODS, STR_483A_INSECT_INFESTATION_CAUSES),
 
@@ -1300,7 +1300,7 @@
 	   IT_FACTORY_2,      IT_INVALID,          IT_INVALID,       CHECK_LUMBERMILL,
 	   CT_WOOD,        0, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_DESERT,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_TROPIC,
 	   STR_481B_LUMBER_MILL,                   STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4834_LACK_OF_NEARBY_TREES_CAUSES,   STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1308,7 +1308,7 @@
 	   IT_CANDY_FACTORY,  IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_COTTON_CANDY, 13, CT_INVALID,    0, 30,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_CANDY,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TOYLAND,
 	   STR_481C_COTTON_CANDY_FOREST,           STR_482E_NEW_BEING_PLANTED_NEAR,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4838_IMPROVED_FARMING_METHODS, STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1316,7 +1316,7 @@
 	   IT_COTTON_CANDY,   IT_TOFFEE_QUARRY,    IT_SUGAR_MINE,    CHECK_NOTHING,
 	   CT_CANDY,       0, CT_INVALID,       0, 5,
 	   CT_SUGAR,          CT_TOFFEE,           CT_COTTON_CANDY,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_CANDY,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_TOYLAND,
 	   STR_481D_CANDY_FACTORY,                 STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1324,7 +1324,7 @@
 	   IT_TOY_FACTORY,    IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_BATTERIES,  11, CT_INVALID,      0, 30,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_CANDY,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TOYLAND,
 	   STR_481E_BATTERY_FARM,                  STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4838_IMPROVED_FARMING_METHODS, STR_483A_INSECT_INFESTATION_CAUSES),
 
@@ -1332,7 +1332,7 @@
 	   IT_FIZZY_DRINK_FACTORY, IT_INVALID,     IT_INVALID,       CHECK_NOTHING,
 	   CT_COLA,       12, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_CANDY,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TOYLAND,
 	   STR_481F_COLA_WELLS,                    STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1340,7 +1340,7 @@
 	   IT_TOY_FACTORY,    IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_INVALID,     0, CT_INVALID,       0, 5,
 	   CT_TOYS,           CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_NOT_CLOSABLE,              1 << LT_CANDY,
+	   INDUSTRYLIFE_NOT_CLOSABLE,              1 << LT_TOYLAND,
 	   STR_4820_TOY_SHOP,                      STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1348,7 +1348,7 @@
 	   IT_PLASTIC_FOUNTAINS, IT_BATTERY_FARM,  IT_TOY_SHOP,     CHECK_NOTHING,
 	   CT_TOYS,        0, CT_INVALID,       0, 5,
 	   CT_PLASTIC,        CT_BATTERIES,        CT_INVALID,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_CANDY,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_TOYLAND,
 	   STR_4821_TOY_FACTORY,                   STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1356,7 +1356,7 @@
 	   IT_TOY_FACTORY,    IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_PLASTIC,    14, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_CANDY,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TOYLAND,
 	   STR_4822_PLASTIC_FOUNTAINS,             STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1364,7 +1364,7 @@
 	   IT_COLA_WELLS,     IT_BUBBLE_GENERATOR, IT_INVALID,     CHECK_NOTHING,
 	   CT_FIZZY_DRINKS, 0, CT_INVALID,      0, 5,
 	   CT_COLA,           CT_BUBBLES,          CT_INVALID,
-	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_CANDY,
+	   INDUSTRYLIFE_CLOSABLE,                  1 << LT_TOYLAND,
 	   STR_4823_FIZZY_DRINK_FACTORY,           STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4833_SUPPLY_PROBLEMS_CAUSE_TO,      STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1372,7 +1372,7 @@
 	   IT_FIZZY_DRINK_FACTORY, IT_INVALID,     IT_INVALID,       CHECK_BUBBLEGEN,
 	   CT_BUBBLES,    13, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_CANDY,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TOYLAND,
 	   STR_4824_BUBBLE_GENERATOR,              STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1380,7 +1380,7 @@
 	   IT_CANDY_FACTORY,  IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_TOFFEE,     10, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_CANDY,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TOYLAND,
 	   STR_4825_TOFFEE_QUARRY,                 STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 
@@ -1388,7 +1388,7 @@
 	   IT_CANDY_FACTORY,  IT_INVALID,          IT_INVALID,       CHECK_NOTHING,
 	   CT_SUGAR,      11, CT_INVALID,       0, 5,
 	   CT_INVALID,        CT_INVALID,          CT_INVALID,
-	   INDUSTRYLIFE_PRODUCTION,                1 << LT_CANDY,
+	   INDUSTRYLIFE_PRODUCTION,                1 << LT_TOYLAND,
 	   STR_4826_SUGAR_MINE,                    STR_482D_NEW_UNDER_CONSTRUCTION,
 	   STR_4832_ANNOUNCES_IMMINENT_CLOSURE,    STR_4835_INCREASES_PRODUCTION,     STR_4839_PRODUCTION_DOWN_BY_50),
 };
--- a/src/table/cargo_const.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/table/cargo_const.h	Thu Apr 19 14:43:25 2007 +0000
@@ -3,7 +3,7 @@
 /* Table of all default cargo types */
 
 #define MK(bt, label, c, e, f, g, h, fr, te, ks1, ks2, ks3, ks4, ks5, l, m) \
-          {bt, label, 0, c, c, e, f, {g, h}, fr, te, 0, 0, ks1, ks2, ks3, ks4, ks5, l, m}
+          {bt, label, 0, c, c, e, f, {g, h}, fr, te, 0, 0, ks1, ks2, ks3, ks4, ks5, l, m, NULL}
 static const CargoSpec _default_cargo[] = {
 	MK(  0, 'PASS', 152,  1, 3185,  0,  24, false, TE_PASSENGERS,
 		STR_000F_PASSENGERS,     STR_002F_PASSENGER,      STR_PASSENGERS, STR_QUANTITY_PASSENGERS,   STR_ABBREV_PASSENGERS,
--- a/src/table/town_land.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/table/town_land.h	Thu Apr 19 14:43:25 2007 +0000
@@ -1790,361 +1790,474 @@
  * @param bn  building name
  * @param rr  rating decrease if removed
  * @param mg  mail generation multiplier
- * @param pa  passenger acceptance
- * @param ma  mail acceptance
- * @param ga  goods acceptance
- * @param fa  food acceptance
+ * @param ca1 acceptance for 1st CargoID
+ * @param ca2 acceptance for 2nd CargoID
+ * @param ca3 acceptance for 3rd CargoID
  * @param bf  building flags (size, stadium etc...)
  * @param ba  building availability (zone, climate...)
+ * @param cg1 1st CargoID available
+ * @param cg2 2nd CargoID available
+ * @param cg3 3rd CargoID available
  * @see HouseSpec
  */
-#define M(mnd, mxd, p, rc, bn, rr, mg, pa, ma, ga, fa, bf, ba) \
-	{mnd, mxd, p, rc, bn, rr, mg, pa, ma, ga, fa, bf, ba, true, \
+#define M(mnd, mxd, p, rc, bn, rr, mg, ca1, ca2, ca3, bf, ba, cg1, cg2, cg3) \
+	{mnd, mxd, p, rc, bn, rr, mg, {ca1, ca2, ca3}, {cg1, cg2, cg3}, bf, ba, true, \
 	 0, NULL, 0, 0, {0, 0, 0, 0}, 16, NO_EXTRA_FLAG, HOUSE_NO_CLASS, 0, 2, 0, 0, NULL}
 static const HouseSpec _original_house_specs[] = {
 	/**
 	 *                                                              remove_rating_decrease
 	 *                                                               |    mail_generation
-	 *     min_date                                                  |    |    passenger_acceptance
-	 *     |         max_date                                        |    |    |    mail_acceptance
-	 *     |         |    population                                 |    |    |    |    goods_acceptance
-	 *     |         |    |    removal_cost                          |    |    |    |    |    food_acceptance
-	 *     |         |    |    |    building_name                    |    |    |    |    |    |
-	 *     |         |    |    |    |                                |    |    |    |    |    |
-	 *     |         |    |    |    |                                |    |    |    |    |    |
-	 * +-building_flags   |    |    |                                |    |    |    |    |    |
-	 * +-building_availability |    |                                |    |    |    |    |    |
-	 * |   |         |    |    |    |                                |    |    |    |    |    |*/
-	M( 1963, MAX_YEAR, 187, 150, STR_200F_TALL_OFFICE_BLOCK,      140,  70,   8,   3,   4,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5),
-	M( 1957, MAX_YEAR,  85, 140, STR_2010_OFFICE_BLOCK,           130,  55,   8,   3,   4,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON4),
-	M( 1968, MAX_YEAR,  40, 100, STR_2011_SMALL_BLOCK_OF_FLATS,    90,  20,   8,   3,   1,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2),
-	M(    0, MAX_YEAR,   5,  90, STR_2012_CHURCH,                 230,   2,   2,   0,   0,   0,
-	   BUILDING_IS_CHURCH | TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M( 1975, MAX_YEAR, 220, 160, STR_2013_LARGE_OFFICE_BLOCK,     160,  85,  10,   4,   6,   0,
-	   BUILDING_IS_ANIMATED | TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5),
-	M( 1975, MAX_YEAR, 220, 160, STR_2013_LARGE_OFFICE_BLOCK,     160,  85,  10,   4,   6,   0,
-	   BUILDING_IS_ANIMATED | TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE  | HZ_ZON5),
-	M(    0, MAX_YEAR,  30,  80, STR_2014_TOWN_HOUSES,             80,  12,   4,   1,   0,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M( 1959, MAX_YEAR, 140, 180, STR_2015_HOTEL,                  150,  22,   6,   1,   2,   0,
-	   TILE_SIZE_1x2,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON3),
-	M( 1959, MAX_YEAR,   0, 180, STR_2015_HOTEL,                  150,  22,   6,   1,   2,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M( 1945, MAX_YEAR,   0,  65, STR_2016_STATUE,                  40,   0,   2,   0,   0,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4),
-	M( 1945, MAX_YEAR,   0,  65, STR_2017_FOUNTAIN,                40,   0,   2,   0,   0,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5),
-	M(    0, MAX_YEAR,   0,  60, STR_2018_PARK,                    75,   0,   2,   0,   0,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON3),
-	M( 1935, MAX_YEAR,   0,  60, STR_2018_PARK,                    75,   0,   2,   0,   0,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON4),
-	M( 1951, MAX_YEAR, 150, 130, STR_2019_OFFICE_BLOCK,           110,  65,   8,   2,   4,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON4),
-	M( 1930, 1960,      95, 110, STR_201A_SHOPS_AND_OFFICES,      100,  48,   6,   2,   3,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1930, 1960,      95, 105, STR_201A_SHOPS_AND_OFFICES,      100,  48,   6,   2,   3,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1930, 1960,      95, 107, STR_201A_SHOPS_AND_OFFICES,      100,  48,   6,   2,   3,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1977, MAX_YEAR, 130, 200, STR_201B_MODERN_OFFICE_BUILDING, 150,  50,  10,   3,   6,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5),
-	M( 1983, MAX_YEAR,   6, 145, STR_201C_WAREHOUSE,              110,  10,   6,   3,   8,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5),
-	M( 1985, MAX_YEAR, 110, 155, STR_201D_OFFICE_BLOCK,           110,  55,   6,   2,   6,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5),
-	M(    0, MAX_YEAR,  65, 250, STR_201E_STADIUM,                300,   5,   4,   0,   0,   0,
-	   BUILDING_IS_STADIUM | TILE_SIZE_2x2,
-	   HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,   0, 250, STR_201E_STADIUM,                300,   5,   4,   0,   0,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M(    0, MAX_YEAR,   0, 250, STR_201E_STADIUM,                300,   5,   4,   0,   0,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M(    0, MAX_YEAR,   0, 250, STR_201E_STADIUM,                300,   5,   4,   0,   0,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M(    0, 1951,      15,  70, STR_201F_OLD_HOUSES,              75,   6,   3,   1,   0,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON2 | HZ_ZON1),
-	M(    0, 1952,      12,  75, STR_2036_COTTAGES,                75,   7,   3,   1,   0,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON1),
-	M( 1931, MAX_YEAR,  13,  71, STR_2037_HOUSES,                  75,   8,   3,   1,   0,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M( 1935, MAX_YEAR, 100, 135, STR_2038_FLATS,                  100,  35,   7,   2,   2,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1963, MAX_YEAR, 170, 145, STR_2039_TALL_OFFICE_BLOCK,      170,  50,   8,   3,   3,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, 1955,     100, 132, STR_203A_SHOPS_AND_OFFICES,      135,  40,   6,   2,   3,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1973, MAX_YEAR, 180, 155, STR_203B_SHOPS_AND_OFFICES,      180,  64,   8,   3,   3,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON3),
-	M(    0, MAX_YEAR,  35, 220, STR_203C_THEATER,                230,  23,   8,   2,   2,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON4),
-	M( 1958, MAX_YEAR,  65, 250, STR_203D_STADIUM,                300,   5,   4,   0,   0,   0,
-	   BUILDING_IS_STADIUM | TILE_SIZE_2x2,
-	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M( 1958, MAX_YEAR,   0, 250, STR_203D_STADIUM,                300,   5,   4,   0,   0,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M( 1958, MAX_YEAR,   0, 250, STR_203D_STADIUM,                300,   5,   4,   0,   0,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M( 1958, MAX_YEAR,   0, 250, STR_203D_STADIUM,                300,   5,   4,   0,   0,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M( 2000, MAX_YEAR, 140, 170, STR_203E_OFFICES,                250,  65,   8,   3,   2,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4),
-	M(    0, 1960,      15,  70, STR_203F_HOUSES,                  75,   6,   3,   1,   0,   1,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_ZON2 | HZ_ZON1),
-	M(    0, 1960,      15,  70, STR_203F_HOUSES,                  75,   6,   3,   1,   0,   1,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON2 | HZ_ZON1),
-	M( 1945, MAX_YEAR,  35, 210, STR_2040_CINEMA,                 230,  23,   8,   2,   2,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1983, MAX_YEAR, 180, 250, STR_2041_SHOPPING_MALL,          300,   5,   8,   2,   3,   0,
-	   TILE_SIZE_2x2,
-	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 |HZ_ZON2),
-	M( 1983, MAX_YEAR,   0, 250, STR_2041_SHOPPING_MALL,          300,   5,   8,   2,   3,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M( 1983, MAX_YEAR,   0, 250, STR_2041_SHOPPING_MALL,          300,   5,   8,   2,   3,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M( 1983, MAX_YEAR,   0, 250, STR_2041_SHOPPING_MALL,          300,   5,   8,   2,   3,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M(    0, MAX_YEAR,  80, 100, STR_2038_FLATS,                   90,  20,   5,   2,   0,   2,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, MAX_YEAR,  80, 100, STR_2038_FLATS,                   90,  20,   5,   2,   0,   2,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE  | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, MAX_YEAR,  16,  70, STR_203F_HOUSES,                  70,   6,   3,   1,   0,   2,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,  16,  70, STR_203F_HOUSES,                  70,   6,   3,   1,   0,   2,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, 1963,      14,  80, STR_203F_HOUSES,                  70,   6,   3,   1,   0,   2,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, 1963,      14,  80, STR_203F_HOUSES,                  70,   6,   3,   1,   0,   2,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M( 1966, MAX_YEAR, 135, 150, STR_200F_TALL_OFFICE_BLOCK,      120,  60,   8,   3,   4,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4),
-	M( 1966, MAX_YEAR, 135, 150, STR_200F_TALL_OFFICE_BLOCK,      120,  60,   8,   3,   4,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4),
-	M( 1970, MAX_YEAR, 170, 170, STR_200F_TALL_OFFICE_BLOCK,      130,  70,   9,   3,   4,   0,
+	 *     min_date                                                  |    |    1st CargoID acceptance
+	 *     |         max_date                                        |    |    |    2nd CargoID acceptance
+	 *     |         |    population                                 |    |    |    |    3th CargoID acceptance
+	 *     |         |    |    removal_cost                          |    |    |    |    |
+	 *     |         |    |    |    building_name                    |    |    |    |    |
+	 *     |         |    |    |    |                                |    |    |    |    |
+	 *     |         |    |    |    |                                |    |    |    |    |
+	 * +-building_flags   |    |    |                                |    |    |    |    |
+	 * +-building_availability |    |                                |    |    |    |    |
+	 * +-cargoID accepted |    |    |                                |    |    |    |    |
+	 * |   |         |    |    |    |                                |    |    |    |    | */
+	M( 1963, MAX_YEAR, 187, 150, STR_200F_TALL_OFFICE_BLOCK,      140,  70,   8,   3,   4,
 	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4),
-	M( 1970, MAX_YEAR, 170, 170, STR_200F_TALL_OFFICE_BLOCK,      130,  70,   9,   3,   4,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4),
-	M( 1974, MAX_YEAR, 210, 200, STR_200F_TALL_OFFICE_BLOCK,      140,  80,  10,   3,   5,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4),
-	M( 1974, MAX_YEAR, 210, 200, STR_200F_TALL_OFFICE_BLOCK,      140,  80,  10,   3,   5,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4),
-	M(    0, MAX_YEAR,  10,  60, STR_203F_HOUSES,                  60,   5,   2,   1,   0,   1,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_ZON1),
-	M(    0, MAX_YEAR,  10,  60, STR_203F_HOUSES,                  60,   5,   2,   1,   0,   1,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON1),
-	M(    0, MAX_YEAR,  25, 100, STR_201A_SHOPS_AND_OFFICES,       80,  20,   3,   1,   0,   1,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2),
-	M(    0, MAX_YEAR,  25, 100, STR_201A_SHOPS_AND_OFFICES,       80,  20,   3,   1,   0,   1,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2),
-	M(    0, MAX_YEAR,   6,  85, STR_2012_CHURCH,                 230,   2,   2,   0,   0,   0,
-	   BUILDING_IS_CHURCH | TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,   6,  85, STR_2012_CHURCH,                 230,   2,   2,   0,   0,   0,
-	   BUILDING_IS_CHURCH | TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,  17,  80, STR_203F_HOUSES,                  80,   7,   3,   1,   0,   1,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,  17,  80, STR_203F_HOUSES,                  80,   7,   3,   1,   0,   1,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, 1960,      90, 140, STR_201A_SHOPS_AND_OFFICES,      110,  45,   6,   2,   3,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW| HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, 1960,      90, 140, STR_201A_SHOPS_AND_OFFICES,      110,  45,   6,   2,   3,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE| HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1972, MAX_YEAR, 140, 160, STR_2015_HOTEL,                  160,  25,   6,   1,   0,   3,
-	   TILE_SIZE_1x2,
-	   HZ_SUBARTC_BELOW| HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1972, MAX_YEAR,   0, 160, STR_2015_HOTEL,                  160,  25,   6,   1,   2,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M( 1972, MAX_YEAR, 140, 160, STR_2015_HOTEL,                  160,  25,   6,   1,   0,   3,
-	   TILE_SIZE_1x2,
-	   HZ_SUBARTC_ABOVE| HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1972, MAX_YEAR,   0, 160, STR_2015_HOTEL,                  160,  25,   6,   1,   2,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M( 1963, MAX_YEAR, 105, 130, STR_201A_SHOPS_AND_OFFICES,      105,  50,   7,   2,   3,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1963, MAX_YEAR, 105, 130, STR_201A_SHOPS_AND_OFFICES,      105,  50,   7,   2,   3,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE| HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1978, MAX_YEAR, 190, 190, STR_200F_TALL_OFFICE_BLOCK,      135,  75,   9,   3,   4,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4),
-	M( 1978, MAX_YEAR, 190, 190, STR_200F_TALL_OFFICE_BLOCK,      135,  75,   9,   3,   4,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4),
-	M( 1967, MAX_YEAR, 250, 140, STR_200F_TALL_OFFICE_BLOCK,      200,  60,   7,   2,   2,   0,
-	   TILE_SIZE_2x1,
-	   HZ_SUBARTC_BELOW| HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1967, MAX_YEAR,   0, 140, STR_200F_TALL_OFFICE_BLOCK,      200,  60,   7,   2,   2,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M( 1967, MAX_YEAR, 250, 140, STR_200F_TALL_OFFICE_BLOCK,      200,  60,   7,   2,   2,   0,
-	   TILE_SIZE_2x1,
-	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1967, MAX_YEAR,   0, 140, STR_200F_TALL_OFFICE_BLOCK,      200,  60,   7,   2,   2,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M(    0, MAX_YEAR,  16,  80, STR_203F_HOUSES,                  80,   6,   3,   1,   0,   2,
-	   TILE_SIZE_1x1,
-	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2),
-	M(    0, MAX_YEAR,  16,  80, STR_203F_HOUSES,                  80,   6,   3,   1,   0,   2,
-	   TILE_SIZE_1x1,
-	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2),
-	M(    0, MAX_YEAR,  16,  80, STR_203F_HOUSES,                  80,   5,   3,   1,   0,   2,
+	   HZ_TEMP | HZ_ZON5,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //00
+	M( 1957, MAX_YEAR,  85, 140, STR_2010_OFFICE_BLOCK,           130,  55,   8,   3,   4,
 	   TILE_SIZE_1x1,
-	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2),
-	M(    0, MAX_YEAR,   7,  30, STR_203F_HOUSES,                  30,   4,   3,   1,   0,   1,
-	   TILE_SIZE_1x1,
-	   HZ_SUBTROPIC | HZ_ZON1),
-	M(    0, MAX_YEAR,  45, 130, STR_2038_FLATS,                   95,  15,   6,   2,   1,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, MAX_YEAR,   8,  90, STR_2012_CHURCH,                 200,   3,   2,   0,   0,   0,
-	   BUILDING_IS_CHURCH | TILE_SIZE_1x1,
-	   HZ_SUBTROPIC | HZ_ZON4 | HZ_ZON3 | HZ_ZON2),
-	M(    0, MAX_YEAR,  18,  80, STR_203F_HOUSES,                  80,   7,   3,   1,   0,   2,
-	   TILE_SIZE_1x1,
-	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2),
-	M( 1973, MAX_YEAR,  90, 110, STR_2038_FLATS,                   95,  24,   6,   2,   1,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1962, MAX_YEAR, 120, 120, STR_2038_FLATS,                   95,  25,   6,   2,   1,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1984, MAX_YEAR, 250, 190, STR_200F_TALL_OFFICE_BLOCK,      140,  80,   8,   3,   4,   0,
-	   TILE_SIZE_2x1,
-	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4),
-	M( 1984, MAX_YEAR,   0, 190, STR_200F_TALL_OFFICE_BLOCK,      140,  80,   8,   3,   4,   0,
-	   TILE_NO_FLAG,
-	   HZ_SUBTROPIC),
-	M(    0, MAX_YEAR,  80, 110, STR_2038_FLATS,                   95,  23,   6,   2,   1,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M( 1993, MAX_YEAR, 180, 180, STR_200F_TALL_OFFICE_BLOCK,      150,  90,   8,   3,   4,   0,
-	   TILE_SIZE_1x1,
-	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, MAX_YEAR,   8,  90, STR_2012_CHURCH,                 200,   3,   2,   0,   0,   0,
-	   BUILDING_IS_CHURCH | TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,  18,  90, STR_203F_HOUSES,                  90,   5,   6,   2,   2,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,   7,  70, STR_203F_HOUSES,                  50,   3,   3,   1,   1,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,  15,  80, STR_203F_HOUSES,                  75,   6,   3,   1,   2,   0,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //01
+	M( 1968, MAX_YEAR,  40, 100, STR_2011_SMALL_BLOCK_OF_FLATS,    90,  20,   8,   3,   1,
 	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,  17,  80, STR_203F_HOUSES,                  75,   6,   3,   1,   2,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,  19,  80, STR_203F_HOUSES,                  75,   6,   3,   1,   2,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,  21,  80, STR_203F_HOUSES,                  75,   6,   3,   1,   2,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,  75, 160, STR_200F_TALL_OFFICE_BLOCK,      130,  20,   8,   4,   2,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, MAX_YEAR,  35,  90, STR_203F_HOUSES,                  80,   9,   4,   1,   2,   0,
-	   TILE_SIZE_1x2,
-	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,   0,  90, STR_203F_HOUSES,                  80,   0,   4,   1,   2,   0,
-	   TILE_NO_FLAG,
-	   HZ_NOZNS),
-	M(    0, MAX_YEAR,  85, 150, STR_200F_TALL_OFFICE_BLOCK,      130,  18,   8,   4,   2,   0,
+	   HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //02
+	M(    0, MAX_YEAR,   5,  90, STR_2012_CHURCH,                 230,   2,   2,   0,   0,
+	   BUILDING_IS_CHURCH | TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //03
+	M( 1975, MAX_YEAR, 220, 160, STR_2013_LARGE_OFFICE_BLOCK,     160,  85,  10,   4,   6,
+	   BUILDING_IS_ANIMATED | TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //04
+	M( 1975, MAX_YEAR, 220, 160, STR_2013_LARGE_OFFICE_BLOCK,     160,  85,  10,   4,   6,
+	   BUILDING_IS_ANIMATED | TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE  | HZ_ZON5,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //05
+	M(    0, MAX_YEAR,  30,  80, STR_2014_TOWN_HOUSES,             80,  12,   4,   1,   0,
 	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, MAX_YEAR,  11,  60, STR_2059_IGLOO,                   45,   3,   3,   1,   1,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON1),
-	M(    0, MAX_YEAR,  10,  60, STR_205A_TEPEES,                  45,   3,   3,   1,   1,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON1),
-	M(    0, MAX_YEAR,  67, 140, STR_201A_SHOPS_AND_OFFICES,      130,  22,   8,   4,   0,   4,
-	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, MAX_YEAR,  86, 145, STR_201A_SHOPS_AND_OFFICES,      130,  23,   8,   4,   0,   4,
+	   HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //06
+	M( 1959, MAX_YEAR, 140, 180, STR_2015_HOTEL,                  150,  22,   6,   1,   2,
+	   TILE_SIZE_1x2,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //07
+	M( 1959, MAX_YEAR,   0, 180, STR_2015_HOTEL,                  150,  22,   6,   1,   2,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //08
+	M( 1945, MAX_YEAR,   0,  65, STR_2016_STATUE,                  40,   0,   2,   0,   0,
 	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, MAX_YEAR,  95, 165, STR_200F_TALL_OFFICE_BLOCK,      130,  28,   8,   4,   2,   0,
-	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, MAX_YEAR,  30,  90, STR_2016_STATUE,                  70,  10,   4,   1,   2,   0,
+	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //09
+	M( 1945, MAX_YEAR,   0,  65, STR_2017_FOUNTAIN,                40,   0,   2,   0,   0,
 	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3),
-	M(    0, MAX_YEAR,  25,  75, STR_205B_TEAPOT_HOUSE,            65,   8,   3,   1,   2,   0,
+	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //0A
+	M(    0, MAX_YEAR,   0,  60, STR_2018_PARK,                    75,   0,   2,   0,   0,
 	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
-	M(    0, MAX_YEAR,  18,  85, STR_205C_PIGGY_BANK,              95,   7,   3,   2,   0,   4,
+	   HZ_TEMP | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //0B
+	M( 1935, MAX_YEAR,   0,  60, STR_2018_PARK,                    75,   0,   2,   0,   0,
 	   TILE_SIZE_1x1,
-	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1),
+	   HZ_TEMP | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //0C
+	M( 1951, MAX_YEAR, 150, 130, STR_2019_OFFICE_BLOCK,           110,  65,   8,   2,   4,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //0D
+	M( 1930, 1960,      95, 110, STR_201A_SHOPS_AND_OFFICES,      100,  48,   6,   2,   3,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //0E
+	M( 1930, 1960,      95, 105, STR_201A_SHOPS_AND_OFFICES,      100,  48,   6,   2,   3,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //0F
+	M( 1930, 1960,      95, 107, STR_201A_SHOPS_AND_OFFICES,      100,  48,   6,   2,   3,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //10
+	M( 1977, MAX_YEAR, 130, 200, STR_201B_MODERN_OFFICE_BUILDING, 150,  50,  10,   3,   6,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //11
+	M( 1983, MAX_YEAR,   6, 145, STR_201C_WAREHOUSE,              110,  10,   6,   3,   8,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON5,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //12
+	M( 1985, MAX_YEAR, 110, 155, STR_201D_OFFICE_BLOCK,           110,  55,   6,   2,   6,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON5,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //13
+	M(    0, MAX_YEAR,  65, 250, STR_201E_STADIUM,                300,   5,   4,   0,   0,
+	   BUILDING_IS_STADIUM | TILE_SIZE_2x2,
+	   HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //14
+	M(    0, MAX_YEAR,   0, 250, STR_201E_STADIUM,                300,   5,   4,   0,   0,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //15
+	M(    0, MAX_YEAR,   0, 250, STR_201E_STADIUM,                300,   5,   4,   0,   0,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //16
+	M(    0, MAX_YEAR,   0, 250, STR_201E_STADIUM,                300,   5,   4,   0,   0,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //17
+	M(    0, 1951,      15,  70, STR_201F_OLD_HOUSES,              75,   6,   3,   1,   0,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //18
+	M(    0, 1952,      12,  75, STR_2036_COTTAGES,                75,   7,   3,   1,   0,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //19
+	M( 1931, MAX_YEAR,  13,  71, STR_2037_HOUSES,                  75,   8,   3,   1,   0,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //1A
+	M( 1935, MAX_YEAR, 100, 135, STR_2038_FLATS,                  100,  35,   7,   2,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //1B
+	M( 1963, MAX_YEAR, 170, 145, STR_2039_TALL_OFFICE_BLOCK,      170,  50,   8,   3,   3,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //1C
+	M(    0, 1955,     100, 132, STR_203A_SHOPS_AND_OFFICES,      135,  40,   6,   2,   3,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //1D
+	M( 1973, MAX_YEAR, 180, 155, STR_203B_SHOPS_AND_OFFICES,      180,  64,   8,   3,   3,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //1E
+	M(    0, MAX_YEAR,  35, 220, STR_203C_THEATER,                230,  23,   8,   2,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //1F
+	M( 1958, MAX_YEAR,  65, 250, STR_203D_STADIUM,                300,   5,   4,   0,   0,
+	   BUILDING_IS_STADIUM | TILE_SIZE_2x2,
+	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //20
+	M( 1958, MAX_YEAR,   0, 250, STR_203D_STADIUM,                300,   5,   4,   0,   0,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //21
+	M( 1958, MAX_YEAR,   0, 250, STR_203D_STADIUM,                300,   5,   4,   0,   0,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //22
+	M( 1958, MAX_YEAR,   0, 250, STR_203D_STADIUM,                300,   5,   4,   0,   0,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //23
+	M( 2000, MAX_YEAR, 140, 170, STR_203E_OFFICES,                250,  65,   8,   3,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //24
+	M(    0, 1960,      15,  70, STR_203F_HOUSES,                  75,   6,   3,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //25
+	M(    0, 1960,      15,  70, STR_203F_HOUSES,                  75,   6,   3,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //26
+	M( 1945, MAX_YEAR,  35, 210, STR_2040_CINEMA,                 230,  23,   8,   2,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //27
+	M( 1983, MAX_YEAR, 180, 250, STR_2041_SHOPPING_MALL,          300,   5,   8,   2,   3,
+	   TILE_SIZE_2x2,
+	   HZ_TEMP | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 |HZ_ZON2,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //28
+	M( 1983, MAX_YEAR,   0, 250, STR_2041_SHOPPING_MALL,          300,   5,   8,   2,   3,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //29
+	M( 1983, MAX_YEAR,   0, 250, STR_2041_SHOPPING_MALL,          300,   5,   8,   2,   3,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //2A
+	M( 1983, MAX_YEAR,   0, 250, STR_2041_SHOPPING_MALL,          300,   5,   8,   2,   3,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //2B
+	M(    0, MAX_YEAR,  80, 100, STR_2038_FLATS,                   90,  20,   5,   2,   2,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //2C
+	M(    0, MAX_YEAR,  80, 100, STR_2038_FLATS,                   90,  20,   5,   2,   2,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE  | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //2D
+	M(    0, MAX_YEAR,  16,  70, STR_203F_HOUSES,                  70,   6,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //2E
+	M(    0, MAX_YEAR,  16,  70, STR_203F_HOUSES,                  70,   6,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //2F
+	M(    0, 1963,      14,  80, STR_203F_HOUSES,                  70,   6,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //30
+	M(    0, 1963,      14,  80, STR_203F_HOUSES,                  70,   6,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //31
+	M( 1966, MAX_YEAR, 135, 150, STR_200F_TALL_OFFICE_BLOCK,      120,  60,   8,   3,   4,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //32
+	M( 1966, MAX_YEAR, 135, 150, STR_200F_TALL_OFFICE_BLOCK,      120,  60,   8,   3,   4,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //33
+	M( 1970, MAX_YEAR, 170, 170, STR_200F_TALL_OFFICE_BLOCK,      130,  70,   9,   3,   4,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //34
+	M( 1970, MAX_YEAR, 170, 170, STR_200F_TALL_OFFICE_BLOCK,      130,  70,   9,   3,   4,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //35
+	M( 1974, MAX_YEAR, 210, 200, STR_200F_TALL_OFFICE_BLOCK,      140,  80,  10,   3,   5,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //36
+	M( 1974, MAX_YEAR, 210, 200, STR_200F_TALL_OFFICE_BLOCK,      140,  80,  10,   3,   5,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //37
+	M(    0, MAX_YEAR,  10,  60, STR_203F_HOUSES,                  60,   5,   2,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //38
+	M(    0, MAX_YEAR,  10,  60, STR_203F_HOUSES,                  60,   5,   2,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //39
+	M(    0, MAX_YEAR,  25, 100, STR_201A_SHOPS_AND_OFFICES,       80,  20,   3,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //3A
+	M(    0, MAX_YEAR,  25, 100, STR_201A_SHOPS_AND_OFFICES,       80,  20,   3,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //3B
+	M(    0, MAX_YEAR,   6,  85, STR_2012_CHURCH,                 230,   2,   2,   0,   0,
+	   BUILDING_IS_CHURCH | TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //3C
+	M(    0, MAX_YEAR,   6,  85, STR_2012_CHURCH,                 230,   2,   2,   0,   0,
+	   BUILDING_IS_CHURCH | TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //3D
+	M(    0, MAX_YEAR,  17,  80, STR_203F_HOUSES,                  80,   7,   3,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //3E
+	M(    0, MAX_YEAR,  17,  80, STR_203F_HOUSES,                  80,   7,   3,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //3F
+	M(    0, 1960,      90, 140, STR_201A_SHOPS_AND_OFFICES,      110,  45,   6,   2,   3,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW| HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //40
+	M(    0, 1960,      90, 140, STR_201A_SHOPS_AND_OFFICES,      110,  45,   6,   2,   3,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE| HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //41
+	M( 1972, MAX_YEAR, 140, 160, STR_2015_HOTEL,                  160,  25,   6,   1,   3,
+	   TILE_SIZE_1x2,
+	   HZ_SUBARTC_BELOW| HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //42
+	M( 1972, MAX_YEAR,   0, 160, STR_2015_HOTEL,                  160,  25,   6,   1,   2,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //43
+	M( 1972, MAX_YEAR, 140, 160, STR_2015_HOTEL,                  160,  25,   6,   1,   3,
+	   TILE_SIZE_1x2,
+	   HZ_SUBARTC_ABOVE| HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //44
+	M( 1972, MAX_YEAR,   0, 160, STR_2015_HOTEL,                  160,  25,   6,   1,   2,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //45
+	M( 1963, MAX_YEAR, 105, 130, STR_201A_SHOPS_AND_OFFICES,      105,  50,   7,   2,   3,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //46
+	M( 1963, MAX_YEAR, 105, 130, STR_201A_SHOPS_AND_OFFICES,      105,  50,   7,   2,   3,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE| HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //47
+	M( 1978, MAX_YEAR, 190, 190, STR_200F_TALL_OFFICE_BLOCK,      135,  75,   9,   3,   4,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_BELOW | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //48
+	M( 1978, MAX_YEAR, 190, 190, STR_200F_TALL_OFFICE_BLOCK,      135,  75,   9,   3,   4,
+	   TILE_SIZE_1x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //49
+	M( 1967, MAX_YEAR, 250, 140, STR_200F_TALL_OFFICE_BLOCK,      200,  60,   7,   2,   2,
+	   TILE_SIZE_2x1,
+	   HZ_SUBARTC_BELOW| HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //4A
+	M( 1967, MAX_YEAR,   0, 140, STR_200F_TALL_OFFICE_BLOCK,      200,  60,   7,   2,   2,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //4B
+	M( 1967, MAX_YEAR, 250, 140, STR_200F_TALL_OFFICE_BLOCK,      200,  60,   7,   2,   2,
+	   TILE_SIZE_2x1,
+	   HZ_SUBARTC_ABOVE | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //4C
+	M( 1967, MAX_YEAR,   0, 140, STR_200F_TALL_OFFICE_BLOCK,      200,  60,   7,   2,   2,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //4D
+	M(    0, MAX_YEAR,  16,  80, STR_203F_HOUSES,                  80,   6,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //4E
+	M(    0, MAX_YEAR,  16,  80, STR_203F_HOUSES,                  80,   6,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //4F
+	M(    0, MAX_YEAR,  16,  80, STR_203F_HOUSES,                  80,   5,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //50
+	M(    0, MAX_YEAR,   7,  30, STR_203F_HOUSES,                  30,   4,   3,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBTROPIC | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //51
+	M(    0, MAX_YEAR,  45, 130, STR_2038_FLATS,                   95,  15,   6,   2,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //52
+	M(    0, MAX_YEAR,   8,  90, STR_2012_CHURCH,                 200,   3,   2,   0,   0,
+	   BUILDING_IS_CHURCH | TILE_SIZE_1x1,
+	   HZ_SUBTROPIC | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //53
+	M(    0, MAX_YEAR,  18,  80, STR_203F_HOUSES,                  80,   7,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2,
+	   CT_PASSENGERS, CT_MAIL, CT_FOOD), //54
+	M( 1973, MAX_YEAR,  90, 110, STR_2038_FLATS,                   95,  24,   6,   2,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //55
+	M( 1962, MAX_YEAR, 120, 120, STR_2038_FLATS,                   95,  25,   6,   2,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //56
+	M( 1984, MAX_YEAR, 250, 190, STR_200F_TALL_OFFICE_BLOCK,      140,  80,   8,   3,   4,
+	   TILE_SIZE_2x1,
+	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //57
+	M( 1984, MAX_YEAR,   0, 190, STR_200F_TALL_OFFICE_BLOCK,      140,  80,   8,   3,   4,
+	   TILE_NO_FLAG,
+	   HZ_SUBTROPIC,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //58
+	M(    0, MAX_YEAR,  80, 110, STR_2038_FLATS,                   95,  23,   6,   2,   1,
+	   TILE_SIZE_1x1,
+	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //59
+	M( 1993, MAX_YEAR, 180, 180, STR_200F_TALL_OFFICE_BLOCK,      150,  90,   8,   3,   4,
+	   TILE_SIZE_1x1,
+	   HZ_SUBTROPIC | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_GOODS), //5A
+	M(    0, MAX_YEAR,   8,  90, STR_2012_CHURCH,                 200,   3,   2,   0,   0,
+	   BUILDING_IS_CHURCH | TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //5B
+	M(    0, MAX_YEAR,  18,  90, STR_203F_HOUSES,                  90,   5,   6,   2,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //5C
+	M(    0, MAX_YEAR,   7,  70, STR_203F_HOUSES,                  50,   3,   3,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //5D
+	M(    0, MAX_YEAR,  15,  80, STR_203F_HOUSES,                  75,   6,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //5E
+	M(    0, MAX_YEAR,  17,  80, STR_203F_HOUSES,                  75,   6,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //5F
+	M(    0, MAX_YEAR,  19,  80, STR_203F_HOUSES,                  75,   6,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //60
+	M(    0, MAX_YEAR,  21,  80, STR_203F_HOUSES,                  75,   6,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //61
+	M(    0, MAX_YEAR,  75, 160, STR_200F_TALL_OFFICE_BLOCK,      130,  20,   8,   4,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //62
+	M(    0, MAX_YEAR,  35,  90, STR_203F_HOUSES,                  80,   9,   4,   1,   2,
+	   TILE_SIZE_1x2,
+	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //63
+	M(    0, MAX_YEAR,   0,  90, STR_203F_HOUSES,                  80,   0,   4,   1,   2,
+	   TILE_NO_FLAG,
+	   HZ_NOZNS,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //64
+	M(    0, MAX_YEAR,  85, 150, STR_200F_TALL_OFFICE_BLOCK,      130,  18,   8,   4,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //65
+	M(    0, MAX_YEAR,  11,  60, STR_2059_IGLOO,                   45,   3,   3,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //66
+	M(    0, MAX_YEAR,  10,  60, STR_205A_TEPEES,                  45,   3,   3,   1,   1,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //67
+	M(    0, MAX_YEAR,  67, 140, STR_201A_SHOPS_AND_OFFICES,      130,  22,   8,   4,   4,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_FIZZY_DRINKS), //68
+	M(    0, MAX_YEAR,  86, 145, STR_201A_SHOPS_AND_OFFICES,      130,  23,   8,   4,   4,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_FIZZY_DRINKS), //69
+	M(    0, MAX_YEAR,  95, 165, STR_200F_TALL_OFFICE_BLOCK,      130,  28,   8,   4,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //6A
+	M(    0, MAX_YEAR,  30,  90, STR_2016_STATUE,                  70,  10,   4,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //6B
+	M(    0, MAX_YEAR,  25,  75, STR_205B_TEAPOT_HOUSE,            65,   8,   3,   1,   2,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_CANDY), //6C
+	M(    0, MAX_YEAR,  18,  85, STR_205C_PIGGY_BANK,              95,   7,   3,   2,   4,
+	   TILE_SIZE_1x1,
+	   HZ_TOYLND | HZ_ZON5 | HZ_ZON4 | HZ_ZON3 | HZ_ZON2 | HZ_ZON1,
+	   CT_PASSENGERS, CT_MAIL, CT_FIZZY_DRINKS), //6D
 };
 #undef M
 assert_compile(lengthof(_original_house_specs) == NEW_HOUSE_OFFSET);
--- a/src/texteff.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/texteff.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -145,15 +145,27 @@
 			}
 		}
 
+		int x      = _textmsg_box.x;
+		int y      = _screen.height - _textmsg_box.y - _textmsg_box.height;
+		int width  = _textmsg_box.width;
+		int height = _textmsg_box.height;
+		if (y < 0) {
+			height = max(height + y, min(_textmsg_box.height, _screen.height));
+			y = 0;
+		}
+		if (x + width >= _screen.width) {
+			width = _screen.width - x;
+		}
+
 		_textmessage_visible = false;
 		/* Put our 'shot' back to the screen */
 		memcpy_pitch(
-			_screen.dst_ptr + _textmsg_box.x + (_screen.height - _textmsg_box.y - _textmsg_box.height) * _screen.pitch,
+			_screen.dst_ptr + x + y * _screen.pitch,
 			_textmessage_backup,
-			_textmsg_box.width, _textmsg_box.height, _textmsg_box.width, _screen.pitch);
+			width, height, _textmsg_box.width, _screen.pitch);
 
 		/* And make sure it is updated next time */
-		_video_driver->make_dirty(_textmsg_box.x, _screen.height - _textmsg_box.y - _textmsg_box.height, _textmsg_box.width, _textmsg_box.height);
+		_video_driver->make_dirty(x, y, width, height);
 
 		_textmessage_dirty = true;
 	}
@@ -186,8 +198,6 @@
 /* Draw the textmessage-box */
 void DrawTextMessage()
 {
-	uint y, count;
-
 	if (!_textmessage_dirty) return;
 
 	/* First undraw if needed */
@@ -196,14 +206,25 @@
 	if (_iconsole_mode == ICONSOLE_FULL) return;
 
 	/* Check if we have anything to draw at all */
-	count = GetTextMessageCount();
+	uint count = GetTextMessageCount();
 	if (count == 0) return;
 
+	int x      = _textmsg_box.x;
+	int y      = _screen.height - _textmsg_box.y - _textmsg_box.height;
+	int width  = _textmsg_box.width;
+	int height = _textmsg_box.height;
+	if (y < 0) {
+		height = max(height + y, min(_textmsg_box.height, _screen.height));
+		y = 0;
+	}
+	if (x + width >= _screen.width) {
+		width = _screen.width - x;
+	}
 	/* Make a copy of the screen as it is before painting (for undraw) */
 	memcpy_pitch(
 		_textmessage_backup,
-		_screen.dst_ptr + _textmsg_box.x + (_screen.height - _textmsg_box.y - _textmsg_box.height) * _screen.pitch,
-		_textmsg_box.width, _textmsg_box.height, _screen.pitch, _textmsg_box.width);
+		_screen.dst_ptr + x + y * _screen.pitch,
+		width, height, _screen.pitch, _textmsg_box.width);
 
 	_cur_dpi = &_screen; // switch to _screen painting
 
@@ -217,12 +238,12 @@
 		);
 
 	/* Paint the messages starting with the lowest at the bottom */
-	for (y = 13; count-- != 0; y += 13) {
+	for (uint y = 13; count-- != 0; y += 13) {
 		DoDrawString(_textmsg_list[count].message, _textmsg_box.x + 3, _screen.height - _textmsg_box.y - y + 1, _textmsg_list[count].color);
  	}
 
 	/* Make sure the data is updated next flush */
-	_video_driver->make_dirty(_textmsg_box.x, _screen.height - _textmsg_box.y - _textmsg_box.height, _textmsg_box.width, _textmsg_box.height);
+	_video_driver->make_dirty(x, y, width, height);
 
 	_textmessage_visible = true;
 	_textmessage_dirty = false;
--- a/src/tgp.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/tgp.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -398,8 +398,8 @@
 		fheight = (double)(*h - h_min) / (double)(h_max - h_min);
 		/* Apply sine transform depending on landscape type */
 		switch(_opt.landscape) {
-			case LT_CANDY:
-			case LT_NORMAL:
+			case LT_TOYLAND:
+			case LT_TEMPERATE:
 				/* Move and scale 0..1 into -1..+1 */
 				fheight = 2 * fheight - 1;
 				/* Sine transform */
@@ -408,7 +408,7 @@
 				fheight = 0.5 * (fheight + 1);
 				break;
 
-			case LT_HILLY:
+			case LT_ARCTIC:
 				{
 					/* Arctic terrain needs special height distribution.
 					 * Redistribute heights to have more tiles at highest (75%..100%) range */
@@ -429,7 +429,7 @@
 				}
 				break;
 
-			case LT_DESERT:
+			case LT_TROPIC:
 				{
 					/* Desert terrain needs special height distribution.
 					 * Half of tiles should be at lowest (0..25%) heights */
--- a/src/town.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/town.h	Thu Apr 19 14:43:25 2007 +0000
@@ -225,10 +225,8 @@
 	StringID building_name;            ///< building name
 	uint16 remove_rating_decrease;     ///< rating decrease if removed
 	byte mail_generation;              ///< mail generation multiplier (tile based, as the acceptances below)
-	byte passenger_acceptance;         ///< passenger acceptance, given in 1/8th unit, max is 8, as the 3 next properies
-	byte mail_acceptance;              ///< mail acceptance
-	byte goods_acceptance;             ///< good acceptance
-	byte food_acceptance;              ///< food (or fizzy drink) acceptance
+	byte cargo_acceptance[3];          ///< acceptance level for the cargo slots
+	CargoID accepts_cargo[3];          ///< 3 input cargo slots
 	BuildingFlags building_flags;      ///< some flags that describe the house (size, stadium etc...)
 	HouseZones building_availability;  ///< where can it be built (climates, zones)
 	bool enabled;                      ///< the house is still avaible (by default, true.newgrf can disable it, though)
--- a/src/town_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/town_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -11,6 +11,7 @@
 #include "table/strings.h"
 #include "table/sprites.h"
 #include "map.h"
+#include "landscape.h"
 #include "tile.h"
 #include "town_map.h"
 #include "tunnel_map.h"
@@ -128,8 +129,15 @@
 	HouseID house_id = GetHouseType(ti->tile);
 
 	if (house_id >= NEW_HOUSE_OFFSET) {
-		DrawNewHouseTile(ti, house_id);
-		return;
+		/* Houses don't necessarily need new graphics. If they don't have a
+		 * spritegroup associated with them, then the sprite for the substitute
+		 * house id is drawn instead. */
+		if (GetHouseSpecs(house_id)->spritegroup != NULL) {
+			DrawNewHouseTile(ti, house_id);
+			return;
+		} else {
+			house_id = GetHouseSpecs(house_id)->substitute_id;
+		}
 	}
 
 	/* Retrieve pointer to the draw town tile struct */
@@ -401,10 +409,7 @@
 {
 	HouseSpec *hs = GetHouseSpecs(GetHouseType(tile));
 
-	ac[CT_PASSENGERS] = hs->passenger_acceptance;
-	ac[CT_MAIL]       = hs->mail_acceptance;
-	ac[CT_GOODS]      = hs->goods_acceptance;
-	ac[CT_FOOD]       = hs->food_acceptance;
+	for (uint8 i = 0; i < 3; i++) ac[hs->accepts_cargo[i]] = hs->cargo_acceptance[i];
 }
 
 static void GetTileDesc_Town(TileIndex tile, TileDesc *td)
@@ -1222,7 +1227,7 @@
 		uint rad = t->GetRadiusGroup(tile);
 
 		int land = _opt.landscape;
-		if (land == LT_HILLY && z >= _opt.snow_line) land = -1;
+		if (land == LT_ARCTIC && z >= _opt.snow_line) land = -1;
 
 		bitmask = (1 << rad) + (1 << (land + 12));
 	}
@@ -1578,9 +1583,7 @@
 		// set all close by station ratings to 0
 		FOR_ALL_STATIONS(st) {
 			if (st->town == t && st->owner == _current_player) {
-				uint i;
-
-				for (i = 0; i != NUM_CARGO; i++) st->goods[i].rating = 0;
+				for (CargoID i = 0; i < NUM_CARGO; i++) st->goods[i].rating = 0;
 			}
 		}
 
@@ -1691,10 +1694,10 @@
 		m = _grow_count_values[min(n, 5) - 1];
 	}
 
-	if (_opt.landscape == LT_HILLY) {
-		if (TilePixelHeight(t->xy) >= _opt.snow_line && t->act_food == 0 && t->population > 90)
+	if (_opt.landscape == LT_ARCTIC) {
+		if (TilePixelHeight(t->xy) >= GetSnowLine() && t->act_food == 0 && t->population > 90)
 			return;
-	} else if (_opt.landscape == LT_DESERT) {
+	} else if (_opt.landscape == LT_TROPIC) {
 		if (GetTropicZone(t->xy) == TROPICZONE_DESERT && (t->act_food==0 || t->act_water==0) && t->population > 60)
 			return;
 	}
--- a/src/train_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/train_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -3214,7 +3214,7 @@
 		InvalidateWindow(WC_VEHICLE_DETAILS, v->index);
 
 		if (!PlayVehicleSound(v, VSE_BREAKDOWN)) {
-			SndPlayVehicleFx((_opt.landscape != LT_CANDY) ?
+			SndPlayVehicleFx((_opt.landscape != LT_TOYLAND) ?
 				SND_10_TRAIN_BREAKDOWN : SND_3A_COMEDY_BREAKDOWN_2, v);
 		}
 
--- a/src/train_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/train_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -371,7 +371,6 @@
 	const Vehicle *u;
 	AcceptedCargo act_cargo;
 	AcceptedCargo max_cargo;
-	uint i;
 	int num;
 	int x;
 	int y;
@@ -380,7 +379,7 @@
 	num = 0;
 	u = v = GetVehicle(w->window_number);
 	if (det_tab == 3) { // Total cargo tab
-		for (i = 0; i < lengthof(act_cargo); i++) {
+		for (CargoID i = 0; i < lengthof(act_cargo); i++) {
 			act_cargo[i] = 0;
 			max_cargo[i] = 0;
 		}
@@ -393,7 +392,7 @@
 		/* Set scroll-amount seperately from counting, as to not compute num double
 		 * for more carriages of the same type
 		 */
-		for (i = 0; i != NUM_CARGO; i++) {
+		for (CargoID i = 0; i < NUM_CARGO; i++) {
 			if (max_cargo[i] > 0) num++; // only count carriages that the train has
 		}
 		num++; // needs one more because first line is description string
@@ -492,7 +491,7 @@
 	} else {
 		// draw total cargo tab
 		DrawString(x, y + 2, STR_013F_TOTAL_CAPACITY_TEXT, 0);
-		for (i = 0; i != NUM_CARGO; i++) {
+		for (CargoID i = 0; i < NUM_CARGO; i++) {
 			if (max_cargo[i] > 0 && --sel < 0 && sel > -w->vscroll.cap) {
 				y += 14;
 				SetDParam(0, i);            // {CARGO} #1
--- a/src/tree_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/tree_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -9,6 +9,7 @@
 #include "table/tree_land.h"
 #include "functions.h"
 #include "map.h"
+#include "landscape.h"
 #include "tile.h"
 #include "tree_map.h"
 #include "viewport.h"
@@ -27,13 +28,13 @@
 static TreeType GetRandomTreeType(TileIndex tile, uint seed)
 {
 	switch (_opt.landscape) {
-		case LT_NORMAL:
+		case LT_TEMPERATE:
 			return (TreeType)(seed * TREE_COUNT_TEMPERATE / 256 + TREE_TEMPERATE);
 
-		case LT_HILLY:
+		case LT_ARCTIC:
 			return (TreeType)(seed * TREE_COUNT_SUB_ARCTIC / 256 + TREE_SUB_ARCTIC);
 
-		case LT_DESERT:
+		case LT_TROPIC:
 			switch (GetTropicZone(tile)) {
 				case TROPICZONE_INVALID: return (TreeType)(seed * TREE_COUNT_SUB_TROPICAL / 256 + TREE_SUB_TROPICAL);
 				case TROPICZONE_DESERT:  return (TreeType)((seed > 12) ? TREE_INVALID : TREE_CACTUS);
@@ -53,7 +54,7 @@
 		MakeTree(tile, tree, GB(r, 22, 2), min(GB(r, 16, 3), 6), TREE_GROUND_GRASS, 0);
 
 		// above snowline?
-		if (_opt.landscape == LT_HILLY && GetTileZ(tile) > _opt.snow_line) {
+		if (_opt.landscape == LT_ARCTIC && GetTileZ(tile) > GetSnowLine()) {
 			SetTreeGroundDensity(tile, TREE_GROUND_SNOW_DESERT, 3);
 			SetTreeCounter(tile, (TreeGround)GB(r, 24, 3));
 		} else {
@@ -150,7 +151,7 @@
 			j = GetTileZ(tile) / TILE_HEIGHT * 2;
 			while (j--) {
 				/* Above snowline more trees! */
-				if (_opt.landscape == LT_HILLY && ht > _opt.snow_line) {
+				if (_opt.landscape == LT_ARCTIC && ht > GetSnowLine()) {
 					PlaceTreeAtSameHeight(tile, ht);
 					PlaceTreeAtSameHeight(tile, ht);
 				};
@@ -161,7 +162,7 @@
 	} while (--i);
 
 	/* place extra trees at rainforest area */
-	if (_opt.landscape == LT_DESERT) {
+	if (_opt.landscape == LT_TROPIC) {
 		i = ScaleByMapSize(15000);
 
 		do {
@@ -186,16 +187,16 @@
 
 	if (_patches.tree_placer == TP_NONE) return;
 
-	if (_opt.landscape != LT_CANDY) PlaceMoreTrees();
+	if (_opt.landscape != LT_TOYLAND) PlaceMoreTrees();
 
 	switch (_patches.tree_placer) {
-		case TP_ORIGINAL: i = _opt.landscape == LT_HILLY ? 15 : 6; break;
-		case TP_IMPROVED: i = _opt.landscape == LT_HILLY ?  4 : 2; break;
+		case TP_ORIGINAL: i = _opt.landscape == LT_ARCTIC ? 15 : 6; break;
+		case TP_IMPROVED: i = _opt.landscape == LT_ARCTIC ?  4 : 2; break;
 		default: NOT_REACHED(); return;
 	}
 
 	total = ScaleByMapSize(1000);
-	if (_opt.landscape == LT_DESERT) total += ScaleByMapSize(15000);
+	if (_opt.landscape == LT_TROPIC) total += ScaleByMapSize(15000);
 	total *= i;
 	SetGeneratingWorldProgress(GWP_TREE, total);
 
@@ -496,7 +497,7 @@
 
 static void TileLoopTreesAlps(TileIndex tile)
 {
-	int k = GetTileZ(tile) - _opt.snow_line + TILE_HEIGHT;
+	int k = GetTileZ(tile) - GetSnowLine() + TILE_HEIGHT;
 
 	if (k < 0) {
 		if (GetTreeGround(tile) != TREE_GROUND_SNOW_DESERT) return;
@@ -523,8 +524,8 @@
 static void TileLoop_Trees(TileIndex tile)
 {
 	switch (_opt.landscape) {
-		case LT_DESERT: TileLoopTreesDesert(tile); break;
-		case LT_HILLY:  TileLoopTreesAlps(tile);   break;
+		case LT_TROPIC: TileLoopTreesDesert(tile); break;
+		case LT_ARCTIC: TileLoopTreesAlps(tile);   break;
 	}
 
 	TileLoopClearHelper(tile);
@@ -537,7 +538,7 @@
 
 	switch (GetTreeGrowth(tile)) {
 		case 3: /* regular sized tree */
-			if (_opt.landscape == LT_DESERT &&
+			if (_opt.landscape == LT_TROPIC &&
 					GetTreeType(tile) != TREE_CACTUS &&
 					GetTropicZone(tile) == TROPICZONE_DESERT) {
 				AddTreeGrowth(tile, 1);
@@ -612,7 +613,7 @@
 	TreeType tree;
 
 	/* place a tree at a random rainforest spot */
-	if (_opt.landscape == LT_DESERT &&
+	if (_opt.landscape == LT_TROPIC &&
 			(r = Random(), tile = RandomTileSeed(r), GetTropicZone(tile) == TROPICZONE_RAINFOREST) &&
 			IsTileType(tile, MP_CLEAR) &&
 			!IsBridgeAbove(tile) &&
--- a/src/tunnelbridge_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/tunnelbridge_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -14,6 +14,7 @@
 #include "table/strings.h"
 #include "functions.h"
 #include "map.h"
+#include "landscape.h"
 #include "tile.h"
 #include "tunnel_map.h"
 #include "unmovable_map.h"
@@ -1177,8 +1178,8 @@
 {
 	bool snow_or_desert = IsTunnelTile(tile) ? HasTunnelSnowOrDesert(tile) : HasBridgeSnowOrDesert(tile);
 	switch (_opt.landscape) {
-		case LT_HILLY:
-			if (snow_or_desert != (GetTileZ(tile) > _opt.snow_line)) {
+		case LT_ARCTIC:
+			if (snow_or_desert != (GetTileZ(tile) > GetSnowLine())) {
 				if (IsTunnelTile(tile)) {
 					SetTunnelSnowOrDesert(tile, !snow_or_desert);
 				} else {
@@ -1188,7 +1189,7 @@
 			}
 			break;
 
-		case LT_DESERT:
+		case LT_TROPIC:
 			if (GetTropicZone(tile) == TROPICZONE_DESERT && !snow_or_desert) {
 				if (IsTunnelTile(tile)) {
 					SetTunnelSnowOrDesert(tile, true);
--- a/src/unmovable_cmd.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/unmovable_cmd.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -345,7 +345,7 @@
 	uint maxx;
 	uint maxy;
 
-	if (_opt.landscape == LT_CANDY) return;
+	if (_opt.landscape == LT_TOYLAND) return;
 
 	/* add radio tower */
 	i = ScaleByMapSize(1000);
@@ -363,7 +363,7 @@
 		}
 	} while (--i);
 
-	if (_opt.landscape == LT_DESERT) return;
+	if (_opt.landscape == LT_TROPIC) return;
 
 	/* add lighthouses */
 	i = li;
--- a/src/variables.h	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/variables.h	Thu Apr 19 14:43:25 2007 +0000
@@ -321,7 +321,7 @@
 struct DynamicLanguages {
 	int num;                         ///< Number of languages
 	int curr;                        ///< Currently selected language index
-	char curr_file[MAX_PATH];        ///< Currently selected language file (needed for saving the filename of the loaded language
+	char curr_file[MAX_PATH];        ///< Currently selected language file name without path (needed for saving the filename of the loaded language).
 	StringID dropdown[MAX_LANG + 1]; ///< List of languages in the settings gui
 	Language ent[MAX_LANG];          ///< Information about the languages
 };
--- a/src/vehicle.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/vehicle.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -772,7 +772,7 @@
 	uint32 refit_mask = EngInfo(engine_type)->refit_mask;
 
 	if (refit_mask != 0) {
-		for (CargoID cid = CT_PASSENGERS; cid < NUM_CARGO; cid++) {
+		for (CargoID cid = 0; cid < NUM_CARGO; cid++) {
 			if (HASBIT(refit_mask, cid)) return cid;
 		}
 	}
--- a/src/vehicle_gui.cpp	Sun Apr 01 09:38:43 2007 +0000
+++ b/src/vehicle_gui.cpp	Thu Apr 19 14:43:25 2007 +0000
@@ -209,7 +209,7 @@
 		if (u->cargo_cap == 0) continue;
 
 		/* Loop through all cargos in the refit mask */
-		for (CargoID cid = 0; cid != NUM_CARGO && num_lines < max_lines; cid++) {
+		for (CargoID cid = 0; cid < NUM_CARGO && num_lines < max_lines; cid++) {
 			/* Skip cargo type if it's not listed */
 			if (!HASBIT(cmask, cid)) continue;
 
@@ -616,14 +616,13 @@
 	AcceptedCargo cargoa;
 	AcceptedCargo cargob;
 	int r = 0;
-	int i;
 
 	memset(cargoa, 0, sizeof(cargoa));
 	memset(cargob, 0, sizeof(cargob));
 	for (v = va; v != NULL; v = v->next) cargoa[v->cargo_type] += v->cargo_cap;
 	for (v = vb; v != NULL; v = v->next) cargob[v->cargo_type] += v->cargo_cap;
 
-	for (i = 0; i < NUM_CARGO; i++) {
+	for (CargoID i = 0; i < NUM_CARGO; i++) {
 		r = cargoa[i] - cargob[i];
 		if (r != 0) break;
 	}