Fix 908ee729: Inverted condition prevented actually writing data to files. (#12941)
[openttd-github.git] / src / saveload / compat / settings_sl_compat.h
blob37005b98e26c0414c361c0922e16e534438c3d6a
1 /*
2 * This file is part of OpenTTD.
3 * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
4 * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
5 * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
6 */
8 /** @file settings_sl_compat.h Loading of settings chunks before table headers were added. */
10 #ifndef SAVELOAD_COMPAT_SETTINGS_H
11 #define SAVELOAD_COMPAT_SETTINGS_H
13 #include "../saveload.h"
15 /** Original field order for _gameopt. */
16 const SaveLoadCompat _gameopt_sl_compat[] = {
17 SLC_VAR("diff_custom"),
18 SLC_VAR("diff_level"),
19 SLC_VAR("locale.currency"),
20 SLC_VAR("units"),
21 SLC_VAR("game_creation.town_name"),
22 SLC_VAR("game_creation.landscape"),
23 SLC_VAR("game_creation.snow_line_height"),
24 SLC_NULL(1, SLV_22, SLV_165),
25 SLC_NULL(1, SL_MIN_VERSION, SLV_23),
26 SLC_VAR("vehicle.road_side"),
29 /** Original field order for _settings. */
30 const SaveLoadCompat _settings_sl_compat[] = {
31 SLC_VAR("difficulty.max_no_competitors"),
32 SLC_NULL(1, SLV_97, SLV_110),
33 SLC_VAR("difficulty.number_towns"),
34 SLC_VAR("difficulty.industry_density"),
35 SLC_VAR("difficulty.max_loan"),
36 SLC_VAR("difficulty.initial_interest"),
37 SLC_VAR("difficulty.vehicle_costs"),
38 SLC_VAR("difficulty.competitor_speed"),
39 SLC_NULL(1, SLV_97, SLV_110),
40 SLC_VAR("difficulty.vehicle_breakdowns"),
41 SLC_VAR("difficulty.subsidy_multiplier"),
42 SLC_VAR("difficulty.subsidy_duration"),
43 SLC_VAR("difficulty.construction_cost"),
44 SLC_VAR("difficulty.terrain_type"),
45 SLC_VAR("difficulty.quantity_sea_lakes"),
46 SLC_VAR("difficulty.economy"),
47 SLC_VAR("difficulty.line_reverse_mode"),
48 SLC_VAR("difficulty.disasters"),
49 SLC_VAR("difficulty.town_council_tolerance"),
50 SLC_VAR("diff_level"),
51 SLC_VAR("game_creation.town_name"),
52 SLC_VAR("game_creation.landscape"),
53 SLC_NULL(1, SLV_97, SLV_164),
54 SLC_VAR("vehicle.road_side"),
55 SLC_VAR("construction.map_height_limit"),
56 SLC_VAR("game_creation.heightmap_height"),
57 SLC_VAR("construction.build_on_slopes"),
58 SLC_VAR("construction.command_pause_level"),
59 SLC_VAR("construction.terraform_per_64k_frames"),
60 SLC_VAR("construction.terraform_frame_burst"),
61 SLC_VAR("construction.clear_per_64k_frames"),
62 SLC_VAR("construction.clear_frame_burst"),
63 SLC_VAR("construction.tree_per_64k_frames"),
64 SLC_VAR("construction.tree_frame_burst"),
65 SLC_VAR("construction.autoslope"),
66 SLC_VAR("construction.extra_dynamite"),
67 SLC_VAR("construction.max_bridge_length"),
68 SLC_VAR("construction.max_bridge_height"),
69 SLC_VAR("construction.max_tunnel_length"),
70 SLC_NULL(1, SL_MIN_VERSION, SLV_159),
71 SLC_VAR("construction.train_signal_side"),
72 SLC_VAR("station.never_expire_airports"),
73 SLC_VAR("economy.town_layout"),
74 SLC_VAR("economy.allow_town_roads"),
75 SLC_VAR("economy.found_town"),
76 SLC_VAR("economy.allow_town_level_crossings"),
77 SLC_VAR("economy.town_cargogen_mode"),
78 SLC_VAR("linkgraph.recalc_interval"),
79 SLC_VAR("linkgraph.recalc_time"),
80 SLC_VAR("linkgraph.distribution_pax"),
81 SLC_VAR("linkgraph.distribution_mail"),
82 SLC_VAR("linkgraph.distribution_armoured"),
83 SLC_VAR("linkgraph.distribution_default"),
84 SLC_VAR("linkgraph.accuracy"),
85 SLC_VAR("linkgraph.demand_distance"),
86 SLC_VAR("linkgraph.demand_size"),
87 SLC_VAR("linkgraph.short_path_saturation"),
88 SLC_VAR("vehicle.train_acceleration_model"),
89 SLC_VAR("vehicle.roadveh_acceleration_model"),
90 SLC_VAR("vehicle.train_slope_steepness"),
91 SLC_VAR("vehicle.roadveh_slope_steepness"),
92 SLC_VAR("pf.forbid_90_deg"),
93 SLC_VAR("vehicle.max_train_length"),
94 SLC_NULL(1, SL_MIN_VERSION, SLV_159),
95 SLC_VAR("vehicle.smoke_amount"),
96 SLC_NULL(1, SL_MIN_VERSION, SLV_159),
97 SLC_VAR("pf.roadveh_queue"),
98 SLC_NULL(1, SL_MIN_VERSION, SLV_87),
99 SLC_NULL(3, SLV_28, SLV_87),
100 SLC_NULL(3, SLV_87, SLV_TABLE_CHUNKS),
101 SLC_VAR("vehicle.never_expire_vehicles"),
102 SLC_VAR("vehicle.max_trains"),
103 SLC_VAR("vehicle.max_roadveh"),
104 SLC_VAR("vehicle.max_aircraft"),
105 SLC_VAR("vehicle.max_ships"),
106 SLC_VAR("vehicle.servint_ispercent"),
107 SLC_VAR("vehicle.servint_trains"),
108 SLC_VAR("vehicle.servint_roadveh"),
109 SLC_VAR("vehicle.servint_ships"),
110 SLC_VAR("vehicle.servint_aircraft"),
111 SLC_VAR("order.no_servicing_if_no_breakdowns"),
112 SLC_VAR("vehicle.wagon_speed_limits"),
113 SLC_VAR("vehicle.disable_elrails"),
114 SLC_VAR("vehicle.freight_trains"),
115 SLC_NULL(1, SLV_67, SLV_159),
116 SLC_VAR("vehicle.plane_speed"),
117 SLC_VAR("vehicle.dynamic_engines"),
118 SLC_VAR("vehicle.plane_crashes"),
119 SLC_NULL(1, SL_MIN_VERSION, SLV_159),
120 SLC_VAR("gui.sg_full_load_any"),
121 SLC_VAR("order.improved_load"),
122 SLC_VAR("order.selectgoods"),
123 SLC_VAR("gui.sg_new_nonstop"),
124 SLC_NULL(1, SL_MIN_VERSION, SLV_159),
125 SLC_VAR("station.station_spread"),
126 SLC_VAR("order.serviceathelipad"),
127 SLC_VAR("station.modified_catchment"),
128 SLC_VAR("station.serve_neutral_industries"),
129 SLC_VAR("order.gradual_loading"),
130 SLC_VAR("construction.road_stop_on_town_road"),
131 SLC_VAR("construction.road_stop_on_competitor_road"),
132 SLC_VAR("station.adjacent_stations"),
133 SLC_VAR("economy.station_noise_level"),
134 SLC_VAR("station.distant_join_stations"),
135 SLC_VAR("economy.inflation"),
136 SLC_VAR("construction.raw_industry_construction"),
137 SLC_VAR("construction.industry_platform"),
138 SLC_VAR("economy.multiple_industry_per_town"),
139 SLC_NULL(1, SL_MIN_VERSION, SLV_141),
140 SLC_VAR("economy.bribe"),
141 SLC_VAR("economy.exclusive_rights"),
142 SLC_VAR("economy.fund_buildings"),
143 SLC_VAR("economy.fund_roads"),
144 SLC_VAR("economy.give_money"),
145 SLC_VAR("game_creation.snow_line_height"),
146 SLC_VAR("game_creation.snow_coverage"),
147 SLC_VAR("game_creation.desert_coverage"),
148 SLC_NULL(4, SL_MIN_VERSION, SLV_144),
149 SLC_VAR("game_creation.starting_year"),
150 SLC_NULL(4, SL_MIN_VERSION, SLV_105),
151 SLC_VAR("game_creation.ending_year"),
152 SLC_VAR("economy.type"),
153 SLC_NULL(1, SL_MIN_VERSION, SLV_TABLE_CHUNKS),
154 SLC_NULL(1, SLV_TRADING_AGE, SLV_TABLE_CHUNKS),
155 SLC_VAR("economy.feeder_payment_share"),
156 SLC_VAR("economy.town_growth_rate"),
157 SLC_VAR("economy.larger_towns"),
158 SLC_VAR("economy.initial_city_size"),
159 SLC_VAR("economy.mod_road_rebuild"),
160 SLC_NULL(1, SL_MIN_VERSION, SLV_107),
161 SLC_NULL(1, SLV_178, SLV_TABLE_CHUNKS),
162 SLC_VAR("ai.ai_in_multiplayer"),
163 SLC_VAR("ai.ai_disable_veh_train"),
164 SLC_VAR("ai.ai_disable_veh_roadveh"),
165 SLC_VAR("ai.ai_disable_veh_aircraft"),
166 SLC_VAR("ai.ai_disable_veh_ship"),
167 SLC_VAR("script.script_max_opcode_till_suspend"),
168 SLC_VAR("script.script_max_memory_megabytes"),
169 SLC_VAR("vehicle.extend_vehicle_life"),
170 SLC_VAR("economy.dist_local_authority"),
171 SLC_VAR("pf.reverse_at_signals"),
172 SLC_VAR("pf.wait_oneway_signal"),
173 SLC_VAR("pf.wait_twoway_signal"),
174 SLC_VAR("economy.town_noise_population[0]"),
175 SLC_VAR("economy.town_noise_population[1]"),
176 SLC_VAR("economy.town_noise_population[2]"),
177 SLC_VAR("economy.infrastructure_maintenance"),
178 SLC_VAR("pf.wait_for_pbs_path"),
179 SLC_VAR("pf.reserve_paths"),
180 SLC_VAR("pf.path_backoff_interval"),
181 SLC_NULL(3, SL_MIN_VERSION, SLV_REMOVE_OPF),
182 SLC_NULL(32, SL_MIN_VERSION, SLV_TABLE_CHUNKS),
183 SLC_NULL(8, SLV_100, SLV_TABLE_CHUNKS),
184 SLC_NULL(16, SL_MIN_VERSION, SLV_TABLE_CHUNKS),
185 SLC_NULL(4, SLV_47, SLV_TABLE_CHUNKS),
186 SLC_NULL(8, SLV_130, SLV_TABLE_CHUNKS),
187 SLC_NULL(4, SLV_131, SLV_TABLE_CHUNKS),
188 SLC_VAR("pf.yapf.disable_node_optimization"),
189 SLC_VAR("pf.yapf.max_search_nodes"),
190 SLC_VAR("pf.yapf.rail_firstred_twoway_eol"),
191 SLC_VAR("pf.yapf.rail_firstred_penalty"),
192 SLC_VAR("pf.yapf.rail_firstred_exit_penalty"),
193 SLC_VAR("pf.yapf.rail_lastred_penalty"),
194 SLC_VAR("pf.yapf.rail_lastred_exit_penalty"),
195 SLC_VAR("pf.yapf.rail_station_penalty"),
196 SLC_VAR("pf.yapf.rail_slope_penalty"),
197 SLC_VAR("pf.yapf.rail_curve45_penalty"),
198 SLC_VAR("pf.yapf.rail_curve90_penalty"),
199 SLC_VAR("pf.yapf.rail_depot_reverse_penalty"),
200 SLC_VAR("pf.yapf.rail_crossing_penalty"),
201 SLC_VAR("pf.yapf.rail_look_ahead_max_signals"),
202 SLC_VAR("pf.yapf.rail_look_ahead_signal_p0"),
203 SLC_VAR("pf.yapf.rail_look_ahead_signal_p1"),
204 SLC_VAR("pf.yapf.rail_look_ahead_signal_p2"),
205 SLC_VAR("pf.yapf.rail_pbs_cross_penalty"),
206 SLC_VAR("pf.yapf.rail_pbs_station_penalty"),
207 SLC_VAR("pf.yapf.rail_pbs_signal_back_penalty"),
208 SLC_VAR("pf.yapf.rail_doubleslip_penalty"),
209 SLC_VAR("pf.yapf.rail_longer_platform_penalty"),
210 SLC_VAR("pf.yapf.rail_longer_platform_per_tile_penalty"),
211 SLC_VAR("pf.yapf.rail_shorter_platform_penalty"),
212 SLC_VAR("pf.yapf.rail_shorter_platform_per_tile_penalty"),
213 SLC_VAR("pf.yapf.road_slope_penalty"),
214 SLC_VAR("pf.yapf.road_curve_penalty"),
215 SLC_VAR("pf.yapf.road_crossing_penalty"),
216 SLC_VAR("pf.yapf.road_stop_penalty"),
217 SLC_VAR("pf.yapf.road_stop_occupied_penalty"),
218 SLC_VAR("pf.yapf.road_stop_bay_occupied_penalty"),
219 SLC_VAR("pf.yapf.maximum_go_to_depot_penalty"),
220 SLC_VAR("pf.yapf.ship_curve45_penalty"),
221 SLC_VAR("pf.yapf.ship_curve90_penalty"),
222 SLC_VAR("game_creation.land_generator"),
223 SLC_VAR("game_creation.oil_refinery_limit"),
224 SLC_VAR("game_creation.tgen_smoothness"),
225 SLC_VAR("game_creation.variety"),
226 SLC_VAR("game_creation.generation_seed"),
227 SLC_VAR("game_creation.tree_placer"),
228 SLC_VAR("construction.freeform_edges"),
229 SLC_VAR("game_creation.water_borders"),
230 SLC_VAR("game_creation.custom_town_number"),
231 SLC_VAR("construction.extra_tree_placement"),
232 SLC_VAR("game_creation.custom_terrain_type"),
233 SLC_VAR("game_creation.custom_sea_level"),
234 SLC_VAR("game_creation.min_river_length"),
235 SLC_VAR("game_creation.river_route_random"),
236 SLC_VAR("game_creation.amount_of_rivers"),
237 SLC_VAR("locale.currency"),
238 SLC_VAR("units"),
239 SLC_VAR("locale.units_velocity"),
240 SLC_VAR("locale.units_power"),
241 SLC_VAR("locale.units_weight"),
242 SLC_VAR("locale.units_volume"),
243 SLC_VAR("locale.units_force"),
244 SLC_VAR("locale.units_height"),
245 SLC_VAR("locale.digit_group_separator"),
246 SLC_VAR("locale.digit_group_separator_currency"),
247 SLC_VAR("locale.digit_decimal_separator"),
250 #endif /* SAVELOAD_COMPAT_SETTINGS_H */