OpenTTD Source: src/saveload/compat/town_sl_compat.h Source File

OpenTTD Source 14.1

town_sl_compat.h
Go to the documentation of this file.
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 */
7
10 #ifndef SAVELOAD_COMPAT_TOWN_H
11 #define SAVELOAD_COMPAT_TOWN_H
12
13 #include "../saveload.h"
14
16 const SaveLoadCompat _town_supplied_sl_compat[] = {
17 SLC_VAR("old_max"),
18 SLC_VAR("new_max"),
19 SLC_VAR("old_act"),
20 SLC_VAR("new_act"),
21 };
22
24 const SaveLoadCompat _town_received_sl_compat[] = {
25 SLC_VAR("old_max"),
26 SLC_VAR("new_max"),
27 SLC_VAR("old_act"),
28 SLC_VAR("new_act"),
29 };
30
32 const SaveLoadCompat _town_acceptance_matrix_sl_compat[] = {
33 SLC_VAR("area.tile"),
34 SLC_VAR("area.w"),
35 SLC_VAR("area.h"),
36 };
37
39 const SaveLoadCompat _town_sl_compat[] = {
40 SLC_VAR("xy"),
41 SLC_NULL(2, SL_MIN_VERSION, SLV_3),
42 SLC_NULL(4, SLV_3, SLV_85),
43 SLC_NULL(2, SL_MIN_VERSION, SLV_92),
44 SLC_VAR("townnamegrfid"),
45 SLC_VAR("townnametype"),
46 SLC_VAR("townnameparts"),
47 SLC_VAR("name"),
48 SLC_VAR("flags"),
49 SLC_VAR("statues"),
50 SLC_NULL(1, SL_MIN_VERSION, SLV_2),
51 SLC_VAR("have_ratings"),
52 SLC_VAR("ratings"),
53 SLC_VAR("unwanted"),
54 SLC_VAR("supplied[CT_PASSENGERS].old_max"),
55 SLC_VAR("supplied[CT_MAIL].old_max"),
56 SLC_VAR("supplied[CT_PASSENGERS].new_max"),
57 SLC_VAR("supplied[CT_MAIL].new_max"),
58 SLC_VAR("supplied[CT_PASSENGERS].old_act"),
59 SLC_VAR("supplied[CT_MAIL].old_act"),
60 SLC_VAR("supplied[CT_PASSENGERS].new_act"),
61 SLC_VAR("supplied[CT_MAIL].new_act"),
62 SLC_NULL(2, SL_MIN_VERSION, SLV_164),
63 SLC_VAR("received[TE_FOOD].old_act"),
64 SLC_VAR("received[TE_WATER].old_act"),
65 SLC_VAR("received[TE_FOOD].new_act"),
66 SLC_VAR("received[TE_WATER].new_act"),
67 SLC_VAR("goal"),
68 SLC_VAR("text"),
69 SLC_VAR("time_until_rebuild"),
70 SLC_VAR("grow_counter"),
71 SLC_VAR("growth_rate"),
72 SLC_VAR("fund_buildings_months"),
73 SLC_VAR("road_build_months"),
74 SLC_VAR("exclusivity"),
75 SLC_VAR("exclusive_counter"),
76 SLC_VAR("larger_town"),
77 SLC_VAR("layout"),
78 SLC_VAR("psa_list"),
79 SLC_NULL(4, SLV_166, SLV_EXTEND_CARGOTYPES),
80 SLC_NULL(8, SLV_EXTEND_CARGOTYPES, SLV_REMOVE_TOWN_CARGO_CACHE),
81 SLC_NULL(30, SLV_2, SLV_REMOVE_TOWN_CARGO_CACHE),
82 SLC_VAR("supplied"),
83 SLC_VAR("received"),
84 SLC_VAR("acceptance_matrix"),
85 };
86
87 #endif /* SAVELOAD_COMPAT_TOWN_H */
SLC_VAR
#define SLC_VAR(name)
Field name where the real SaveLoad can be located.
Definition: saveload.h:1188
SL_MIN_VERSION
@ SL_MIN_VERSION
First savegame version.
Definition: saveload.h:31
_town_acceptance_matrix_sl_compat
const SaveLoadCompat _town_acceptance_matrix_sl_compat[]
Original field order for SlTownAcceptanceMatrix.
Definition: town_sl_compat.h:32
SLV_85
@ SLV_85
85 11874
Definition: saveload.h:145
SLV_166
@ SLV_166
166 23415
Definition: saveload.h:242
_town_supplied_sl_compat
const SaveLoadCompat _town_supplied_sl_compat[]
Original field order for SlTownSupplied.
Definition: town_sl_compat.h:16
SLV_164
@ SLV_164
164 23290
Definition: saveload.h:239
SLV_92
@ SLV_92
92 12381 0.6.x
Definition: saveload.h:153
_town_sl_compat
const SaveLoadCompat _town_sl_compat[]
Original field order for town_desc.
Definition: town_sl_compat.h:39
SLC_NULL
#define SLC_NULL(length, from, to)
Empty space in every savegame version.
Definition: saveload.h:1196
_town_received_sl_compat
const SaveLoadCompat _town_received_sl_compat[]
Original field order for SlTownReceived.
Definition: town_sl_compat.h:24
SaveLoadCompat
SaveLoad information for backwards compatibility.
Definition: saveload.h:718
SLV_3
@ SLV_3
3.x lost
Definition: saveload.h:36
SLV_2
@ SLV_2
2.0 0.3.0 2.1 0.3.1, 0.3.2
Definition: saveload.h:34
SLV_REMOVE_TOWN_CARGO_CACHE
@ SLV_REMOVE_TOWN_CARGO_CACHE
219 PR#8258 Remove town cargo acceptance and production caches.
Definition: saveload.h:306
SLV_EXTEND_CARGOTYPES
@ SLV_EXTEND_CARGOTYPES
199 PR#6802 Extend cargotypes to 64
Definition: saveload.h:282