1
0
mirror of https://github.com/rwengine/openrw.git synced 2024-11-07 19:32:49 +01:00
openrw/rwgame/states/LoadingState.hpp

27 lines
522 B
C++
Raw Normal View History

#ifndef LOADINGSTATE_HPP
2014-06-06 13:18:32 +02:00
#define LOADINGSTATE_HPP
#include "StateManager.hpp"
2014-06-06 13:18:32 +02:00
#include <functional>
2014-06-06 13:18:32 +02:00
2016-09-09 22:13:20 +02:00
class LoadingState : public State {
std::function<void(void)> complete;
2016-09-09 22:13:20 +02:00
2014-06-06 13:18:32 +02:00
public:
LoadingState(RWGame* game, const std::function<void(void)>& callback);
2016-09-09 22:13:20 +02:00
void enter() override;
2014-06-06 13:18:32 +02:00
void exit() override;
2014-06-06 13:18:32 +02:00
void tick(float dt) override;
2014-06-06 13:18:32 +02:00
void draw(GameRenderer* r) override;
bool shouldWorldUpdate() override;
void handleEvent(const SDL_Event& event) override;
2014-06-06 13:18:32 +02:00
};
2016-09-09 22:13:20 +02:00
#endif // LOADINGSTATE_HPP