1 #ifndef CORE_SYSTEMS_FLIGHT_HPP
2 #define CORE_SYSTEMS_FLIGHT_HPP
4 #include <BLIB/Cameras/2D/Affectors/CameraShake.hpp>
5 #include <BLIB/Engine/System.hpp>
6 #include <BLIB/Tilemap/Position.hpp>
21 class Flight :
public bl::engine::System {
86 bl::cam::c2d::CameraShake* cameraShake;
87 bl::tmap::Position startPos;
88 bl::tmap::Position* playerPos;
89 component::Renderable* playerAnim;
90 bl::tmap::Position destination;
92 glm::vec2 unitVelocity;
100 void movePlayer(
float dt);
101 void rotatePlayer(bl::tmap::Direction dir);
103 virtual void init(bl::engine::Engine&)
override;
104 virtual void update(std::mutex&,
float dt,
float,
float,
float)
override;
Core classes and functionality for both the editor and game.
Special system to manage player flight between their current location and a town.
bool startFlight(unsigned int destSpawn)
Starts flight to the given spawn.
Flight(Systems &systems)
Construct a new Flight system.
bool flying() const
Returns whether or not the player is currently flying.
virtual ~Flight()=default
Destroys the system.
Owns all primary systems and a reference to the engine.