summaryrefslogtreecommitdiff
path: root/src/cargopacket.h
diff options
context:
space:
mode:
authorPatric Stout <truebrain@openttd.org>2021-06-06 16:03:56 +0200
committerPatric Stout <github@truebrain.nl>2021-06-14 21:58:05 +0200
commit4e4720f2178c9e0faf7233e55bec71e6ae19f9ad (patch)
treeaf474483110fca7fd7c617e052d1d381991e1179 /src/cargopacket.h
parent4600d289b5d12389137d36e57bfda09c26ed6caf (diff)
downloadopenttd-4e4720f2178c9e0faf7233e55bec71e6ae19f9ad.tar.xz
Codechange: remove the special station/vehicle code from SaveLoad
With the new SLEG_STRUCT it is much easier to embed a struct in a struct, where the sub-struct has limitations on when it is being used. This makes both the code easier to read (less magic) and avoids the SaveLoad needing to know all these things about Stations and Vehicles.
Diffstat (limited to 'src/cargopacket.h')
-rw-r--r--src/cargopacket.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cargopacket.h b/src/cargopacket.h
index abb8d98c2..a5166e959 100644
--- a/src/cargopacket.h
+++ b/src/cargopacket.h
@@ -305,8 +305,8 @@ public:
friend class StationCargoList;
/** The super class ought to know what it's doing. */
friend class CargoList<VehicleCargoList, CargoPacketList>;
- /** The vehicles have a cargo list (and we want that saved). */
- friend SaveLoadTable GetVehicleDescription(VehicleType vt);
+ /* So we can use private/protected variables in the saveload code */
+ friend class SlVehicleCommon;
friend class CargoShift;
friend class CargoTransfer;