summaryrefslogtreecommitdiff
path: root/game/vehicles/vehicle.h
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2021-03-06 19:44:58 +0000
committerDan Goodliffe <dan@randomdan.homeip.net>2021-03-06 19:44:58 +0000
commite118b1f5d8071460e3a9d4d731c6d69221f785dc (patch)
tree64ea6b1761afba27d36319648e78ddd457670ff8 /game/vehicles/vehicle.h
parentIntroduce the Train concept as a literal collection of rail vehicles (diff)
downloadilt-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.h16
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);