src/settings_type.h
author rubidium
Sun, 25 May 2008 22:36:44 +0000
changeset 9358 2e1e4d2f71dd
parent 9354 845e07db4549
child 9359 3a8554ac1cb8
permissions -rw-r--r--
(svn r13255) -Codechange: move _opt to _settings.
2186
db48cf29b983 (svn r2701) Insert Id tags into all source files
tron
parents: 2154
diff changeset
     1
/* $Id$ */
db48cf29b983 (svn r2701) Insert Id tags into all source files
tron
parents: 2154
diff changeset
     2
8208
3d0590aa2124 (svn r11771) -Codechange: split settings.h into better separated headers.
rubidium
parents: 8151
diff changeset
     3
/** @file settings_type.h Types related to global configuration settings. */
6423
8e10e79e0fd1 (svn r9559) -Documentation: doxygen and comment changes: 'U' and 'V' now. Almost done. Yeah. I know, I've already said that...
belugas
parents: 6344
diff changeset
     4
8208
3d0590aa2124 (svn r11771) -Codechange: split settings.h into better separated headers.
rubidium
parents: 8151
diff changeset
     5
#ifndef SETTINGS_TYPE_H
3d0590aa2124 (svn r11771) -Codechange: split settings.h into better separated headers.
rubidium
parents: 8151
diff changeset
     6
#define SETTINGS_TYPE_H
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
     7
8140
0d0d8c94f84b (svn r11702) -Codechange: move all date related stuff to date*.
rubidium
parents: 8138
diff changeset
     8
#include "date_type.h"
8213
7bdd7593eb9b (svn r11776) -Codechange: more header splittings to reduce the dependencies.
rubidium
parents: 8208
diff changeset
     9
#include "town_type.h"
9126
5648d696456b (svn r12986) -Codechange: move the landscape and transport related types from openttd.h to their own headers.
rubidium
parents: 9070
diff changeset
    10
#include "transport_type.h"
3900
2c84ed52709d (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents: 3890
diff changeset
    11
9334
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    12
enum {
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    13
	GAME_DIFFICULTY_AI_NUMBER,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    14
	GAME_DIFFICULTY_AI_STARTTIME,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    15
	GAME_DIFFICULTY_TOWN_NUMBER,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    16
	GAME_DIFFICULTY_INDUSTRIE_NUMBER,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    17
	GAME_DIFFICULTY_MAX_LOAN,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    18
	GAME_DIFFICULTY_INITIAL_INTEREST,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    19
	GAME_DIFFICULTY_VEHICLE_COST,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    20
	GAME_DIFFICULTY_AI_SPEED,
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    21
	GAME_DIFFICULTY_AI_INTELLIGENCE,       ///< no longer in use
9334
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    22
	GAME_DIFFICULTY_VEHICLES_BREAKDOWN,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    23
	GAME_DIFFICULTY_SUBSIDY_MULTIPLIER,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    24
	GAME_DIFFICULTY_CONSTRUCTION_COST,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    25
	GAME_DIFFICULTY_TYPE_TERRAIN,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    26
	GAME_DIFFICULTY_SEALAKE_NUMBER,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    27
	GAME_DIFFICULTY_ECONOMY,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    28
	GAME_DIFFICULTY_LINE_REVERSEMODE,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    29
	GAME_DIFFICULTY_DISASTERS,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    30
	GAME_DIFFICULTY_TOWNCOUNCIL_TOLERANCE, ///< minimum required town ratings to be allowed to demolish stuff
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    31
	GAME_DIFFICULTY_NUM,
28ac6c8e0795 (svn r13226) -Feature: Allow to have more than only two airports per town. The number of airports is now controlled by the noise each of them generates, the distance from town's center and how tolerant the town is.
belugas
parents: 9126
diff changeset
    32
};
8268
5027ad5e70a0 (svn r11832) -Codechange: get rid of (quite) some VARDEFs.
rubidium
parents: 8213
diff changeset
    33
5027ad5e70a0 (svn r11832) -Codechange: get rid of (quite) some VARDEFs.
rubidium
parents: 8213
diff changeset
    34
/** Specific type for Game Difficulty to ease changing the type */
5027ad5e70a0 (svn r11832) -Codechange: get rid of (quite) some VARDEFs.
rubidium
parents: 8213
diff changeset
    35
typedef uint16 GDType;
9358
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    36
/** Settings related to the difficulty of the game */
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    37
struct DifficultySettings {
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    38
	GDType max_no_competitors;               ///< the number of competitors (AIs)
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    39
	GDType competitor_start_time;            ///< how long to wait for the first competitors (AIs)
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    40
	GDType number_towns;                     ///< the amount of towns
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    41
	GDType number_industries;                ///< the amount of industries
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    42
	GDType max_loan;                         ///< the maximum initial loan
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    43
	GDType initial_interest;                 ///< amount of interest (to pay over the loan)
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    44
	GDType vehicle_costs;                    ///< amount of money spent on vehicle running cost
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    45
	GDType competitor_speed;                 ///< the speed at which the AI builds
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    46
	GDType competitor_intelligence;          ///< the competior's (AI) intelligence
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    47
	GDType vehicle_breakdowns;               ///< likelihood of vehicles breaking down
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    48
	GDType subsidy_multiplier;               ///< amount of subsidy
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    49
	GDType construction_cost;                ///< how expensive is building
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    50
	GDType terrain_type;                     ///< the mountainousness of the landscape
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    51
	GDType quantity_sea_lakes;               ///< the amount of seas/lakes
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    52
	GDType economy;                          ///< how volatile is the economy
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    53
	GDType line_reverse_mode;                ///< reversing at stations or not
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    54
	GDType disasters;                        ///< are disasters enabled
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    55
	GDType town_council_tolerance;           ///< minimum required town ratings to be allowed to demolish stuff
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    56
	GDType diff_level;                       ///< the difficulty level
8268
5027ad5e70a0 (svn r11832) -Codechange: get rid of (quite) some VARDEFs.
rubidium
parents: 8213
diff changeset
    57
};
5027ad5e70a0 (svn r11832) -Codechange: get rid of (quite) some VARDEFs.
rubidium
parents: 8213
diff changeset
    58
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    59
/** Settings related to the GUI and other stuff that is not saved in the savegame. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    60
struct GUISettings {
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    61
	bool   vehicle_speed;                    ///< show vehicle speed
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    62
	bool   sg_full_load_any;                 ///< new full load calculation, any cargo must be full read from pre v93 savegames
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    63
	bool   lost_train_warn;                  ///< if a train can't find its destination, show a warning
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    64
	uint8  order_review_system;              ///< perform order reviews on vehicles
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    65
	bool   train_income_warn;                ///< if train is generating little income, show a warning
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    66
	bool   status_long_date;                 ///< always show long date in status bar
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    67
	bool   show_finances;                    ///< show finances at end of year
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    68
	bool   sg_new_nonstop;                   ///< ttdpatch compatible nonstop handling read from pre v93 savegames
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    69
	bool   new_nonstop;                      ///< ttdpatch compatible nonstop handling
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    70
	bool   autoscroll;                       ///< scroll when moving mouse to the edge
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    71
	byte   errmsg_duration;                  ///< duration of error message
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    72
	bool   link_terraform_toolbar;           ///< display terraform toolbar when displaying rail, road, water and airport toolbars
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    73
	bool   reverse_scroll;                   ///< right-Click-Scrolling scrolls in the opposite direction
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    74
	bool   smooth_scroll;                    ///< smooth scroll viewports
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    75
	bool   measure_tooltip;                  ///< show a permanent tooltip when dragging tools
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    76
	byte   liveries;                         ///< options for displaying company liveries, 0=none, 1=self, 2=all
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    77
	bool   prefer_teamchat;                  ///< choose the chat message target with <ENTER>, true=all players, false=your team
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    78
	uint8  advanced_vehicle_list;            ///< use the "advanced" vehicle list
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    79
	uint8  loading_indicators;               ///< show loading indicators
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    80
	uint8  default_rail_type;                ///< the default rail type for the rail GUI
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    81
	uint8  toolbar_pos;                      ///< position of toolbars, 0=left, 1=center, 2=right
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    82
	uint8  window_snap_radius;               ///< windows snap at each other if closer than this
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    83
	bool   always_build_infrastructure;      ///< always allow building of infrastructure, even when you do not have the vehicles for it
9358
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
    84
	byte   autosave;                         ///< how often should we do autosaves?
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    85
	bool   keep_all_autosave;                ///< name the autosave in a different way
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    86
	bool   autosave_on_exit;                 ///< save an autosave when you quit the game, but do not ask "Do you really want to quit?"
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    87
	byte   max_num_autosaves;                ///< controls how many autosavegames are made before the game starts to overwrite (names them 0 to max_num_autosaves - 1)
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    88
	bool   population_in_label;              ///< show the population of a town in his label?
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    89
	uint8  right_mouse_btn_emulation;        ///< should we emulate right mouse clicking?
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    90
	uint8  scrollwheel_scrolling;            ///< scrolling using the scroll wheel?
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    91
	uint8  scrollwheel_multiplier;           ///< how much 'wheel' per incoming event from the OS?
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    92
	bool   pause_on_newgame;                 ///< whether to start new games paused or not
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    93
	bool   enable_signal_gui;                ///< show the signal GUI when the signal button is pressed
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    94
	Year   ending_year;                      ///< end of the game (just show highscore)
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    95
	Year   colored_news_year;                ///< when does newspaper become colored?
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    96
	bool   timetable_in_ticks;               ///< whether to show the timetable in ticks rather than days
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    97
	bool   bridge_pillars;                   ///< show bridge pillars for high bridges
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    98
	bool   auto_euro;                        ///< automatically switch to euro in 2002
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
    99
	byte   drag_signals_density;             ///< many signals density
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   100
	Year   semaphore_build_before;           ///< build semaphore signals automatically before this year
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   101
	bool   autorenew;                        ///< should autorenew be enabled for new companies?
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   102
	int16  autorenew_months;                 ///< how many months from EOL of vehicles should autorenew trigger for new companies?
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   103
	int32  autorenew_money;                  ///< how much money before autorenewing for new companies?
9358
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
   104
	byte   currency;                         ///< currency we currently use
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
   105
	byte   units;                            ///< unit system we show everything
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   106
};
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   107
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   108
/** Settings related to the creation of games. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   109
struct GameCreationSettings {
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   110
	uint32 generation_seed;                  ///< noise seed for world generation
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   111
	Year   starting_year;                    ///< starting date
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   112
	uint8  map_x;                            ///< X size of map
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   113
	uint8  map_y;                            ///< Y size of map
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   114
	byte   land_generator;                   ///< the landscape generator
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   115
	byte   oil_refinery_limit;               ///< distance oil refineries allowed from map edge
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   116
	byte   snow_line_height;                 ///< a number 0-15 that configured snow line height
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   117
	byte   tgen_smoothness;                  ///< how rough is the terrain from 0-3
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   118
	byte   tree_placer;                      ///< the tree placer algorithm
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   119
	byte   heightmap_rotation;               ///< rotation director for the heightmap
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   120
	byte   se_flat_world_height;             ///< land height a flat world gets in SE
9358
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
   121
	byte   town_name;                        ///< the town name generator used for town names
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
   122
	byte   landscape;                        ///< the landscape we're currently in
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
   123
	byte   snow_line;                        ///< the snowline level in this game
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   124
};
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   125
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   126
/** Settings related to construction in-game */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   127
struct ConstructionSettings {
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   128
	bool   build_on_slopes;                  ///< allow building on slopes
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   129
	bool   autoslope;                        ///< allow terraforming under things
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   130
	bool   longbridges;                      ///< allow 100 tile long bridges
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   131
	bool   signal_side;                      ///< show signals on right side
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   132
	bool   extra_dynamite;                   ///< extra dynamite
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   133
	bool   road_stop_on_town_road;           ///< allow building of drive-through road stops on town owned roads
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   134
	uint8  raw_industry_construction;        ///< type of (raw) industry construction (none, "normal", prospecting)
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   135
};
8464
84733620d05e (svn r12034) -Codechange: A bit of code style cleaning, regarding comments.
belugas
parents: 8268
diff changeset
   136
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   137
/** Settings related to the AI. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   138
struct AISettings {
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   139
	bool   ainew_active;                     ///< is the new AI active?
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   140
	bool   ai_in_multiplayer;                ///< so we allow AIs in multiplayer
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   141
	bool   ai_disable_veh_train;             ///< disable types for AI
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   142
	bool   ai_disable_veh_roadveh;           ///< disable types for AI
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   143
	bool   ai_disable_veh_aircraft;          ///< disable types for AI
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   144
	bool   ai_disable_veh_ship;              ///< disable types for AI
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   145
};
8464
84733620d05e (svn r12034) -Codechange: A bit of code style cleaning, regarding comments.
belugas
parents: 8268
diff changeset
   146
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   147
/** Settings related to the old pathfinder. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   148
struct OPFSettings {
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   149
	uint16 pf_maxlength;                     ///< maximum length when searching for a train route for new pathfinder
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   150
	byte   pf_maxdepth;                      ///< maximum recursion depth when searching for a train route for new pathfinder
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   151
};
1218
c6a624956ac6 (svn r1722) -Feature: Bigger maps - anyone?
tron
parents: 1178
diff changeset
   152
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   153
/** Settings related to the new pathfinder. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   154
struct NPFSettings {
1700
e1fe3446d013 (svn r2204) - Add: [NPF] NPF now has a maximum number of nodes it will search. The default value is 5000 for now, which is an educated guess. Probably needs some finetuning. Hopefully this "feature" can be removed later on, when more sophisticated means of limiting the pathfinder have been implemented. This should make ships and larger networks playable for now, though.
matthijs
parents: 1688
diff changeset
   155
	/**
4549
106ed18a7675 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4387
diff changeset
   156
	 * The maximum amount of search nodes a single NPF run should take. This
106ed18a7675 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4387
diff changeset
   157
	 * limit should make sure performance stays at acceptable levels at the cost
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   158
	 * of not being perfect anymore.
4549
106ed18a7675 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4387
diff changeset
   159
	 */
1700
e1fe3446d013 (svn r2204) - Add: [NPF] NPF now has a maximum number of nodes it will search. The default value is 5000 for now, which is an educated guess. Probably needs some finetuning. Hopefully this "feature" can be removed later on, when more sophisticated means of limiting the pathfinder have been implemented. This should make ships and larger networks playable for now, though.
matthijs
parents: 1688
diff changeset
   160
	uint32 npf_max_search_nodes;
e1fe3446d013 (svn r2204) - Add: [NPF] NPF now has a maximum number of nodes it will search. The default value is 5000 for now, which is an educated guess. Probably needs some finetuning. Hopefully this "feature" can be removed later on, when more sophisticated means of limiting the pathfinder have been implemented. This should make ships and larger networks playable for now, though.
matthijs
parents: 1688
diff changeset
   161
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   162
	uint32 npf_rail_firstred_penalty;        ///< the penalty for when the first signal is red (and it is not an exit or combo signal)
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   163
	uint32 npf_rail_firstred_exit_penalty;   ///< the penalty for when the first signal is red (and it is an exit or combo signal)
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   164
	uint32 npf_rail_lastred_penalty;         ///< the penalty for when the last signal is red
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   165
	uint32 npf_rail_station_penalty;         ///< the penalty for station tiles
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   166
	uint32 npf_rail_slope_penalty;           ///< the penalty for sloping upwards
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   167
	uint32 npf_rail_curve_penalty;           ///< the penalty for curves
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   168
	uint32 npf_rail_depot_reverse_penalty;   ///< the penalty for reversing in depots
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   169
	uint32 npf_buoy_penalty;                 ///< the penalty for going over (through) a buoy
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   170
	uint32 npf_water_curve_penalty;          ///< the penalty for curves
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   171
	uint32 npf_road_curve_penalty;           ///< the penalty for curves
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   172
	uint32 npf_crossing_penalty;             ///< the penalty for level crossings
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   173
	uint32 npf_road_drive_through_penalty;   ///< the penalty for going through a drive-through road stop
6248
e4a2ed7e5613 (svn r9051) -Codechange: typedef [enum|struct] Y {} X; -> [enum|struct] X {};
rubidium
parents: 6091
diff changeset
   174
};
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   175
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   176
/** Settings related to the yet another pathfinder. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   177
struct YAPFSettings {
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   178
	bool   disable_node_optimization;        ///< whether to use exit-dir instead of trackdir in node key
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   179
	uint32 max_search_nodes;                 ///< stop path-finding when this number of nodes visited
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   180
	bool   ship_use_yapf;                    ///< use YAPF for ships
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   181
	bool   road_use_yapf;                    ///< use YAPF for road
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   182
	bool   rail_use_yapf;                    ///< use YAPF for rail
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   183
	uint32 road_slope_penalty;               ///< penalty for up-hill slope
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   184
	uint32 road_curve_penalty;               ///< penalty for curves
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   185
	uint32 road_crossing_penalty;            ///< penalty for level crossing
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   186
	uint32 road_stop_penalty;                ///< penalty for going through a drive-through road stop
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   187
	bool   rail_firstred_twoway_eol;         ///< treat first red two-way signal as dead end
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   188
	uint32 rail_firstred_penalty;            ///< penalty for first red signal
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   189
	uint32 rail_firstred_exit_penalty;       ///< penalty for first red exit signal
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   190
	uint32 rail_lastred_penalty;             ///< penalty for last red signal
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   191
	uint32 rail_lastred_exit_penalty;        ///< penalty for last red exit signal
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   192
	uint32 rail_station_penalty;             ///< penalty for non-target station tile
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   193
	uint32 rail_slope_penalty;               ///< penalty for up-hill slope
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   194
	uint32 rail_curve45_penalty;             ///< penalty for curve
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   195
	uint32 rail_curve90_penalty;             ///< penalty for 90-deg curve
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   196
	uint32 rail_depot_reverse_penalty;       ///< penalty for reversing in the depot
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   197
	uint32 rail_crossing_penalty;            ///< penalty for level crossing
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   198
	uint32 rail_look_ahead_max_signals;      ///< max. number of signals taken into consideration in look-ahead load balancer
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   199
	int32  rail_look_ahead_signal_p0;        ///< constant in polynomial penalty function
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   200
	int32  rail_look_ahead_signal_p1;        ///< constant in polynomial penalty function
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   201
	int32  rail_look_ahead_signal_p2;        ///< constant in polynomial penalty function
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   202
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   203
	uint32 rail_longer_platform_penalty;           ///< penalty for longer  station platform than train
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   204
	uint32 rail_longer_platform_per_tile_penalty;  ///< penalty for longer  station platform than train (per tile)
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   205
	uint32 rail_shorter_platform_penalty;          ///< penalty for shorter station platform than train
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   206
	uint32 rail_shorter_platform_per_tile_penalty; ///< penalty for shorter station platform than train (per tile)
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   207
};
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   208
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   209
/** Settings related to all pathfinders. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   210
struct PathfinderSettings {
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   211
	uint8  pathfinder_for_trains;            ///< the pathfinder to use for trains
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   212
	uint8  pathfinder_for_roadvehs;          ///< the pathfinder to use for roadvehicles
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   213
	uint8  pathfinder_for_ships;             ///< the pathfinder to use for ships
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   214
	bool   new_pathfinding_all;              ///< use the newest pathfinding algorithm for all
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   215
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   216
	bool   roadveh_queue;                    ///< buggy road vehicle queueing
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   217
	bool   forbid_90_deg;                    ///< forbid trains to make 90 deg turns
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   218
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   219
	byte   wait_oneway_signal;               ///< waitingtime in days before a oneway signal
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   220
	byte   wait_twoway_signal;               ///< waitingtime in days before a twoway signal
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   221
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   222
	OPFSettings  opf;                        ///< pathfinder settings for the old pathfinder
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   223
	NPFSettings  npf;                        ///< pathfinder settings for the new pathfinder
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   224
	YAPFSettings yapf;                       ///< pathfinder settings for the yet another pathfinder
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   225
};
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   226
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   227
/** Settings related to orders. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   228
struct OrderSettings {
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   229
	bool   improved_load;                    ///< improved loading algorithm
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   230
	bool   gradual_loading;                  ///< load vehicles gradually
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   231
	bool   selectgoods;                      ///< only send the goods to station if a train has been there
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   232
	bool   gotodepot;                        ///< allow goto depot in orders
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   233
	bool   no_servicing_if_no_breakdowns;    ///< dont send vehicles to depot when breakdowns are disabled
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   234
	bool   timetabling;                      ///< whether to allow timetabling
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   235
	bool   serviceathelipad;                 ///< service helicopters at helipads automatically (no need to send to depot)
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   236
};
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   237
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   238
/** Settings related to vehicles. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   239
struct VehicleSettings {
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   240
	bool   mammoth_trains;                   ///< allow very long trains
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   241
	bool   realistic_acceleration;           ///< realistic acceleration for trains
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   242
	bool   wagon_speed_limits;               ///< enable wagon speed limits
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   243
	bool   disable_elrails;                  ///< when true, the elrails are disabled
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   244
	UnitID max_trains;                       ///< max trains in game per player
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   245
	UnitID max_roadveh;                      ///< max trucks in game per player
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   246
	UnitID max_aircraft;                     ///< max planes in game per player
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   247
	UnitID max_ships;                        ///< max ships in game per player
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   248
	bool   servint_ispercent;                ///< service intervals are in percents
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   249
	uint16 servint_trains;                   ///< service interval for trains
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   250
	uint16 servint_roadveh;                  ///< service interval for road vehicles
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   251
	uint16 servint_aircraft;                 ///< service interval for aircraft
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   252
	uint16 servint_ships;                    ///< service interval for ships
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   253
	uint8  plane_speed;                      ///< divisor for speed of aircraft
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   254
	uint8  freight_trains;                   ///< value to multiply the weight of cargo by
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   255
	bool   dynamic_engines;                  ///< enable dynamic allocation of engine data
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   256
	bool   never_expire_vehicles;            ///< never expire vehicles
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   257
	byte   extend_vehicle_life;              ///< extend vehicle life by this many years
9358
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
   258
	byte   road_side;                        ///< the side of the road vehicles drive on
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   259
};
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   260
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   261
/** Settings related to the economy. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   262
struct EconomySettings {
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   263
	bool   inflation;                        ///< disable inflation
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   264
	bool   bribe;                            ///< enable bribing the local authority
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   265
	bool   smooth_economy;                   ///< smooth economy
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   266
	bool   allow_shares;                     ///< allow the buying/selling of shares
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   267
	byte   dist_local_authority;             ///< distance for town local authority, default 20
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   268
	bool   exclusive_rights;                 ///< allow buying exclusive rights
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   269
	bool   give_money;                       ///< allow giving other players money
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   270
	bool   mod_road_rebuild;                 ///< roadworks remove unneccesary RoadBits
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   271
	bool   multiple_industry_per_town;       ///< allow many industries of the same type per town
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   272
	bool   same_industry_close;              ///< allow same type industries to be built close to each other
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   273
	uint8  town_growth_rate;                 ///< town growth rate
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   274
	uint8  larger_towns;                     ///< the number of cities to build. These start off larger and grow twice as fast
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   275
	uint8  initial_city_size;                ///< multiplier for the initial size of the cities compared to towns
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   276
	TownLayoutByte town_layout;              ///< select town layout
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   277
	bool   station_noise_level;              ///< build new airports when the town noise level is still within accepted limits
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   278
	uint16 town_noise_population[3];         ///< population to base decision on noise evaluation (@see town_council_tolerance)
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   279
};
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   280
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   281
/** Settings related to stations. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   282
struct StationSettings {
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   283
	bool   modified_catchment;               ///< different-size catchment areas
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   284
	bool   join_stations;                    ///< allow joining of train stations
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   285
	bool   nonuniform_stations;              ///< allow nonuniform train stations
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   286
	bool   adjacent_stations;                ///< allow stations to be built directly adjacent to other stations
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   287
	bool   always_small_airport;             ///< always allow small airports
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   288
	byte   station_spread;                   ///< amount a station may spread
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   289
};
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   290
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   291
/** All settings together. */
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   292
struct Settings {
9358
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
   293
	DifficultySettings   difficulty;         ///< settings related to the difficulty
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   294
	GUISettings          gui;                ///< settings related to the GUI
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   295
	GameCreationSettings game_creation;      ///< settings used during the creation of a game (map)
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   296
	ConstructionSettings construction;       ///< construction of things in-game
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   297
	AISettings           ai;                 ///< what may the AI do?
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   298
	PathfinderSettings   pf;                 ///< settings for all pathfinders
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   299
	OrderSettings        order;              ///< settings related to orders
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   300
	VehicleSettings      vehicle;            ///< options for vehicles
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   301
	EconomySettings      economy;            ///< settings to change the economy
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   302
	StationSettings      station;            ///< settings related to station management
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   303
};
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   304
9358
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
   305
/** The current settings. */
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   306
extern Settings _settings;
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   307
9358
2e1e4d2f71dd (svn r13255) -Codechange: move _opt to _settings.
rubidium
parents: 9354
diff changeset
   308
/** The settings values that are used for new games and/or modified in config file */
9354
845e07db4549 (svn r13251) -Codechange: rename _patches to _settings as that is more logic.
rubidium
parents: 9346
diff changeset
   309
extern Settings _settings_newgame;
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   310
8208
3d0590aa2124 (svn r11771) -Codechange: split settings.h into better separated headers.
rubidium
parents: 8151
diff changeset
   311
#endif /* SETTINGS_TYPE_H */