diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2021-03-06 19:44:58 +0000 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2021-03-06 19:44:58 +0000 |
commit | e118b1f5d8071460e3a9d4d731c6d69221f785dc (patch) | |
tree | 64ea6b1761afba27d36319648e78ddd457670ff8 /game/vehicles/vehicle.h | |
parent | Introduce the Train concept as a literal collection of rail vehicles (diff) | |
download | ilt-e118b1f5d8071460e3a9d4d731c6d69221f785dc.tar.bz2 ilt-e118b1f5d8071460e3a9d4d731c6d69221f785dc.tar.xz ilt-e118b1f5d8071460e3a9d4d731c6d69221f785dc.zip |
Carve up the mess in game/vehicles
Diffstat (limited to 'game/vehicles/vehicle.h')
-rw-r--r-- | game/vehicles/vehicle.h | 16 |
1 files changed, 1 insertions, 15 deletions
diff --git a/game/vehicles/vehicle.h b/game/vehicles/vehicle.h index 89a6901..659821f 100644 --- a/game/vehicles/vehicle.h +++ b/game/vehicles/vehicle.h @@ -1,28 +1,14 @@ #ifndef VEHICLE_H #define VEHICLE_H +#include "linkHistory.h" #include <game/network/link.h> #include <game/worldobject.h> #include <gfx/renderable.h> #include <memory> -#include <utility> -#include <vector> class Location; -class LinkHistory { -public: - using WEntry = std::pair<LinkWPtr, unsigned char /*dir*/>; - using Entry = std::pair<LinkCPtr, unsigned char /*dir*/>; - Entry add(const LinkWPtr &, unsigned char); - [[nodiscard]] Entry getCurrent() const; - [[nodiscard]] Entry getAt(float, float *) const; - -private: - std::vector<WEntry> links; - float totalLen {0.F}; -}; - class Vehicle : public WorldObject, public Renderable { public: explicit Vehicle(const LinkPtr & link, float linkDist = 0); |