Merge branch 'master' into jgrpp

# Conflicts:
#	CMakeLists.txt
#	cmake/CompileFlags.cmake
#	src/bridge_gui.cpp
#	src/saveload/afterload.cpp
#	src/saveload/saveload.cpp
#	src/saveload/saveload.h
#	src/saveload/town_sl.cpp
#	src/screenshot.cpp
#	src/screenshot.h
#	src/toolbar_gui.cpp
#	src/town.h
#	src/town_cmd.cpp
This commit is contained in:
Jonathan G Rennison
2020-06-30 21:43:04 +01:00
45 changed files with 222 additions and 371 deletions

View File

@@ -15,7 +15,6 @@
#include "subsidy_type.h"
#include "newgrf_storage.h"
#include "cargotype.h"
#include "tilematrix_type.hpp"
#include "openttd.h"
#include "table/strings.h"
#include "company_func.h"
@@ -29,8 +28,6 @@ struct BuildingCounts {
T class_count[HOUSE_CLASS_MAX];
};
typedef TileMatrix<CargoTypes, 4> AcceptanceMatrix;
static const uint CUSTOM_TOWN_NUMBER_DIFFICULTY = 4; ///< value for custom town number in difficulty settings
static const uint CUSTOM_TOWN_MAX_NUMBER = 5000; ///< this is the maximum number of towns a user can specify in customisation
@@ -89,10 +86,6 @@ struct Town : TownPool::PoolItem<&_town_pool> {
inline byte GetPercentTransported(CargoID cid) const { return this->supplied[cid].old_act * 256 / (this->supplied[cid].old_max + 1); }
/* Cargo production and acceptance stats. */
CargoTypes cargo_produced; ///< Bitmap of all cargoes produced by houses in this town.
AcceptanceMatrix cargo_accepted; ///< Bitmap of cargoes accepted by houses for each 4*4 (really 12*12) map square of the town.
CargoTypes cargo_accepted_total; ///< NOSAVE: Bitmap of all cargoes accepted by houses in this town.
StationList stations_near; ///< NOSAVE: List of nearby stations.
uint16 time_until_rebuild; ///< time until we rebuild a house
@@ -233,9 +226,6 @@ void ResetHouses();
void ClearTownHouse(Town *t, TileIndex tile);
void UpdateTownMaxPass(Town *t);
void UpdateTownRadius(Town *t);
void UpdateTownCargoes(Town *t);
void UpdateTownCargoTotal(Town *t);
void UpdateTownCargoBitmap();
CommandCost CheckIfAuthorityAllowsNewStation(TileIndex tile, DoCommandFlag flags);
Town *ClosestTownFromTile(TileIndex tile, uint threshold);
void ChangeTownRating(Town *t, int add, int max, DoCommandFlag flags);
@@ -344,8 +334,6 @@ static inline uint16 TownTicksToGameTicks(uint16 ticks) {
}
extern CargoTypes _town_cargoes_accepted;
RoadType GetTownRoadType(const Town *t);
#endif /* TOWN_H */