File diff r26193:4bc7915a2156 → r26194:f7347205838e
src/settings_type.h
Show inline comments
 
@@ -78,12 +78,13 @@ struct DifficultySettings {
 
	byte   industry_density;                 ///< The industry density. @see IndustryDensity
 
	uint32 max_loan;                         ///< the maximum initial loan
 
	byte   initial_interest;                 ///< amount of interest (to pay over the loan)
 
	byte   vehicle_costs;                    ///< amount of money spent on vehicle running cost
 
	byte   competitor_speed;                 ///< the speed at which the AI builds
 
	byte   vehicle_breakdowns;               ///< likelihood of vehicles breaking down
 
	uint32 vehicle_breakdown_scaler;         ///< likelihood of vehicles breaking down REDUX
 
	byte   subsidy_multiplier;               ///< payment multiplier for subsidized deliveries
 
	uint16 subsidy_duration;                 ///< duration of subsidies
 
	byte   construction_cost;                ///< how expensive is building
 
	byte   terrain_type;                     ///< the mountainousness of the landscape
 
	byte   quantity_sea_lakes;               ///< the amount of seas/lakes
 
	bool   economy;                          ///< how volatile is the economy
 
@@ -135,12 +136,13 @@ struct GUISettings {
 
	bool   threaded_saves;                   ///< should we do threaded saves?
 
	bool   keep_all_autosave;                ///< name the autosave in a different way
 
	bool   autosave_on_exit;                 ///< save an autosave when you quit the game, but do not ask "Do you really want to quit?"
 
	bool   autosave_on_network_disconnect;   ///< save an autosave when you get disconnected from a network game with an error?
 
	uint8  date_format_in_default_names;     ///< should the default savegame/screenshot name use long dates (31th Dec 2008), short dates (31-12-2008) or ISO dates (2008-12-31)
 
	byte   max_num_autosaves;                ///< controls how many autosavegames are made before the game starts to overwrite (names them 0 to max_num_autosaves - 1)
 
	bool   colour_based_on_town_rating;      ///< colour code the town name based on rating?
 
	bool   population_in_label;              ///< show the population of a town in its label?
 
	uint8  right_mouse_btn_emulation;        ///< should we emulate right mouse clicking?
 
	uint8  scrollwheel_scrolling;            ///< scrolling using the scroll wheel?
 
	uint8  scrollwheel_multiplier;           ///< how much 'wheel' per incoming event from the OS?
 
	bool   timetable_arrival_departure;      ///< show arrivals and departures in vehicle timetables
 
	bool   right_mouse_wnd_close;            ///< close window with right click
 
@@ -189,12 +191,14 @@ struct GUISettings {
 
	bool   ai_developer_tools;               ///< activate AI developer tools
 
	bool   scenario_developer;               ///< activate scenario developer: allow modifying NewGRFs in an existing game
 
	uint8  settings_restriction_mode;        ///< selected restriction mode in adv. settings GUI. @see RestrictionMode
 
	bool   newgrf_show_old_versions;         ///< whether to show old versions in the NewGRF list
 
	uint8  newgrf_default_palette;           ///< default palette to use for NewGRFs without action 14 palette information
 

	
 
	bool   load_legacy_patchpack_savedata;   ///< whether or not to handle legacy patchpack savedata from version 5.x
 

	
 
	/**
 
	 * Returns true when the user has sufficient privileges to edit newgrfs on a running game
 
	 * @return whether the user has sufficient privileges to edit newgrfs in an existing game
 
	 */
 
	bool UserIsAllowedToChangeNewGRFs() const
 
	{
 
@@ -295,12 +299,13 @@ struct NetworkSettings {
 
	uint8       max_clients;                              ///< maximum amount of clients
 
	Year        restart_game_year;                        ///< year the server restarts
 
	uint8       min_active_clients;                       ///< minimum amount of active clients to unpause the game
 
	bool        reload_cfg;                               ///< reload the config file before restarting
 
	std::string last_joined;                              ///< Last joined server
 
	bool        no_http_content_downloads;                ///< do not do content downloads over HTTP
 
	bool   save_password;                                 ///< If password file is used
 
	UseRelayService use_relay_service;                        ///< Use relay service?
 
};
 

	
 
/** Settings related to the creation of games. */
 
struct GameCreationSettings {
 
	uint32 generation_seed;                  ///< noise seed for world generation
 
@@ -351,12 +356,14 @@ struct ConstructionSettings {
 
	uint32 terraform_per_64k_frames;         ///< how many tile heights may, over a long period, be terraformed per 65536 frames?
 
	uint16 terraform_frame_burst;            ///< how many tile heights may, over a short period, be terraformed?
 
	uint32 clear_per_64k_frames;             ///< how many tiles may, over a long period, be cleared per 65536 frames?
 
	uint16 clear_frame_burst;                ///< how many tiles may, over a short period, be cleared?
 
	uint32 tree_per_64k_frames;              ///< how many trees may, over a long period, be planted per 65536 frames?
 
	uint16 tree_frame_burst;                 ///< how many trees may, over a short period, be planted?
 

	
 
	uint8 name_stations_based_on_industries;  ///< ttr patchpack: name stations based on nearby industries?
 
};
 

	
 
/** Settings related to the AI. */
 
struct AISettings {
 
	bool   ai_in_multiplayer;                ///< so we allow AIs in multiplayer
 
	bool   ai_disable_veh_train;             ///< disable types for AI
 
@@ -491,18 +498,21 @@ struct VehicleSettings {
 
	uint8  freight_trains;                   ///< value to multiply the weight of cargo by
 
	bool   dynamic_engines;                  ///< enable dynamic allocation of engine data
 
	bool   never_expire_vehicles;            ///< never expire vehicles
 
	byte   extend_vehicle_life;              ///< extend vehicle life by this many years
 
	byte   road_side;                        ///< the side of the road vehicles drive on
 
	uint8  plane_crashes;                    ///< number of plane crashes, 0 = none, 1 = reduced, 2 = normal
 
	uint8  plane_range_multiplier;           ///< ttr patchpack: range multiplier
 
	bool   improved_breakdowns;		 ///< different types, chances and serverities of breakdowns
 
};
 

	
 
/** Settings related to the economy. */
 
struct EconomySettings {
 
	bool   inflation;                        ///< disable inflation
 
	bool   bribe;                            ///< enable bribing the local authority
 
	bool   bribe_risky;                      ///< ttr patchpack: whether or not there is a risk of being caught while bribing
 
	EconomyType type;                        ///< economy type (original/smooth/frozen)
 
	bool   allow_shares;                     ///< allow the buying/selling of shares
 
	uint8  min_years_for_shares;             ///< minimum age of a company for it to trade shares
 
	uint8  feeder_payment_share;             ///< percentage of leg payment to virtually pay in feeder systems
 
	byte   dist_local_authority;             ///< distance for town local authority, default 20
 
	bool   exclusive_rights;                 ///< allow buying exclusive rights
 
@@ -519,12 +529,34 @@ struct EconomySettings {
 
	bool   allow_town_roads;                 ///< towns are allowed to build roads (always allowed when generating world / in SE)
 
	TownFounding found_town;                 ///< town founding.
 
	bool   station_noise_level;              ///< build new airports when the town noise level is still within accepted limits
 
	uint16 town_noise_population[3];         ///< population to base decision on noise evaluation (@see town_council_tolerance)
 
	bool   allow_town_level_crossings;       ///< towns are allowed to build level crossings
 
	bool   infrastructure_maintenance;       ///< enable monthly maintenance fee for owner infrastructure
 
	uint16 infrastructure_base_cost_rail;    ///< ttr patchpack: rail infrastructure cost base price
 
	uint16 infrastructure_base_cost_road;    ///< ttr patchpack: road infrastructure cost base price
 
	uint16 infrastructure_base_cost_water;   ///< ttr patchpack: water infrastructure cost base price
 
	uint16 infrastructure_base_cost_air;     ///< ttr patchpack: air infrastructure cost base price
 
	uint16 infrastructure_base_cost_station; ///< ttr patchpack: station infrastructure cost base price
 
	uint8  daylength_multiplier;             ///< ttr patchpack: day length multiplier
 
	uint8  town_growth_multiplier;           ///< ttr patchpack: town growth multiplier
 
	uint16 running_cost_multiplier_rail;     ///< ttr patchpack: rail running cost multiplier
 
	uint16 running_cost_multiplier_road;     ///< ttr patchpack: road running cost multiplier
 
	uint16 running_cost_multiplier_water;    ///< ttr patchpack: water running cost multiplier
 
	uint16 running_cost_multiplier_air;      ///< ttr patchpack: air running cost multiplier
 
	uint16 dilapidation_max_amount;          ///< ttr patchpack: maximum amount of dilapidation allowed at station
 
	uint16 dilapidation_increase;            ///< ttr patchpack: amount of dilapidation to add on ratings update if station is overcrowded
 
	uint16 dilapidation_decrease;            ///< ttr patchpack: amount of dilapidation to remove on ratings update if station is not overcrowded
 
	uint16 dilapidation_pop_rail;            ///< ttr patchpack: amount of pop allowed at rail station before it is considered dilapidated
 
	uint16 dilapidation_pop_road;            ///< ttr patchpack: amount of pop allowed at road station before it is considered dilapidated
 
	uint16 dilapidation_pop_water;           ///< ttr patchpack: amount of pop allowed at water station before it is considered dilapidated
 
	uint16 dilapidation_pop_air;             ///< ttr patchpack: amount of pop allowed at air station before it is considered dilapidated
 
	uint32 dilapidation_fine_rail;           ///< ttr patchpack: monthly fine per dilapidation point at rail stations
 
	uint32 dilapidation_fine_road;           ///< ttr patchpack: monthly fine per dilapidation point at road stations
 
	uint32 dilapidation_fine_water;          ///< ttr patchpack: monthly fine per dilapidation point at water stations
 
	uint32 dilapidation_fine_air;            ///< ttr patchpack: monthly fine per dilapidation point at air stations
 
};
 

	
 
struct LinkGraphSettings {
 
	uint16 recalc_time;                     ///< time (in days) for recalculating each link graph component.
 
	uint16 recalc_interval;                 ///< time (in days) between subsequent checks for link graphs to be calculated.
 
	DistributionType distribution_pax;      ///< distribution type for passengers