diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2023-03-04 15:12:30 +0000 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2023-03-04 15:12:30 +0000 |
commit | c8ecaaddeee46900540e24e096f86306e77493f7 (patch) | |
tree | 9343198cebf2d0c17638b21704d0f39973b9c321 /game/vehicles/railVehicleClass.cpp | |
parent | RailVehicleClass texture might be null (diff) | |
download | ilt-c8ecaaddeee46900540e24e096f86306e77493f7.tar.bz2 ilt-c8ecaaddeee46900540e24e096f86306e77493f7.tar.xz ilt-c8ecaaddeee46900540e24e096f86306e77493f7.zip |
Load length, wheelBase and maxSpeed RailVehicleClass properties from XML
Adjusts bogie position to appear correct according to wheelBase
Diffstat (limited to 'game/vehicles/railVehicleClass.cpp')
-rw-r--r-- | game/vehicles/railVehicleClass.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/game/vehicles/railVehicleClass.cpp b/game/vehicles/railVehicleClass.cpp index c0740cc..90a06bd 100644 --- a/game/vehicles/railVehicleClass.cpp +++ b/game/vehicles/railVehicleClass.cpp @@ -44,7 +44,8 @@ RailVehicleClass::RailVehicleClass() { } bool RailVehicleClass::persist(Persistence::PersistenceStore & store) { - return STORE_TYPE && STORE_MEMBER(maxSpeed) && STORE_NAME_HELPER("bogie", bogies, Asset::MeshArrayConstruct) + return STORE_TYPE && STORE_MEMBER(length) && STORE_MEMBER(wheelBase) && STORE_MEMBER(maxSpeed) + && STORE_NAME_HELPER("bogie", bogies, Asset::MeshArrayConstruct) && STORE_HELPER(bodyMesh, Asset::MeshConstruct) && Asset::persist(store); } |