MCPcopy Create free account
hub / github.com/OpenLoco/OpenLoco / importCargoStats

Function importCargoStats

src/OpenLoco/src/S5/S5Station.cpp:51–65  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

49 }
50
51 static OpenLoco::StationCargoStats importCargoStats(const S5::StationCargoStats& src)
52 {
53 OpenLoco::StationCargoStats dst{};
54 dst.quantity = src.quantity;
55 dst.origin = static_cast<StationId>(src.origin);
56 dst.flags = static_cast<StationCargoStatsFlags>(src.flags);
57 dst.age = src.age;
58 dst.rating = src.rating;
59 dst.enrouteAge = src.enrouteAge;
60 dst.vehicleSpeed = Speed16{ src.vehicleSpeed };
61 dst.vehicleAge = src.vehicleAge;
62 dst.industryId = static_cast<IndustryId>(src.industryId);
63 dst.densityPerTile = src.densityPerTile;
64 return dst;
65 }
66
67 OpenLoco::Station importStation(const S5::Station& src)
68 {

Callers 1

importStationFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected