diff options
Diffstat (limited to 'game/vehicles/railVehicle.h')
-rw-r--r-- | game/vehicles/railVehicle.h | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/game/vehicles/railVehicle.h b/game/vehicles/railVehicle.h new file mode 100644 index 0000000..a089f1d --- /dev/null +++ b/game/vehicles/railVehicle.h @@ -0,0 +1,29 @@ +#ifndef RAILVEHICLE_H +#define RAILVEHICLE_H + +#include "gfx/renderable.h" +#include "railVehicleClass.h" +#include <array> +#include <location.hpp> +#include <memory> +#include <utility> + +class Shader; + +class Train; +class RailVehicle : public Renderable { +public: + explicit RailVehicle(RailVehicleClassPtr rvc) : rvClass {std::move(rvc)} { } + + void move(const Train *, float & trailBy); + + void render(const Shader & shader) const override; + + Location location; + + RailVehicleClassPtr rvClass; + std::array<Location, 2> bogies; +}; +using RailVehiclePtr = std::unique_ptr<RailVehicle>; + +#endif |