1 #ifndef HEADER_LEVELLOADING_H
2 #define HEADER_LEVELLOADING_H
3 
4 class RoomAccess;
5 
6 #include "NoCopy.h"
7 
8 #include <string>
9 
10 /**
11  * Game loading.
12  */
13 class LevelLoading : public NoCopy {
14     private:
15         static const int SPEED_REPLAY = 1;
16 
17         bool m_paused;
18         bool m_replayMode;
19         int m_loadSpeed;
20         std::string m_loadedMoves;
21         RoomAccess *m_access;
22     public:
23         LevelLoading(RoomAccess *access);
setLoadSpeed(int loadSpeed)24         void setLoadSpeed(int loadSpeed) { m_loadSpeed = loadSpeed; }
25         void reset();
26         void loadGame(const std::string &moves);
27         void loadReplay(const std::string &moves);
togglePause()28         void togglePause() { m_paused = !m_paused; }
isPaused()29         bool isPaused() const { return m_paused; }
30 
31         bool isLoading() const;
32         void nextLoadAction();
33 };
34 
35 #endif
36