Inverted control flow, engine as library
This commit is contained in:
@@ -4,9 +4,10 @@
|
||||
|
||||
#include "luaconsole.hpp"
|
||||
#include "world.hpp"
|
||||
#include "drivenengine.hpp"
|
||||
#include <memory>
|
||||
|
||||
class TextGame {
|
||||
class TextGame : public DrivenEngine {
|
||||
private:
|
||||
using StringVec = LuaConsole::StringVec;
|
||||
std::unique_ptr<World> world_;
|
||||
@@ -27,7 +28,8 @@ private:
|
||||
|
||||
void check_redirects();
|
||||
public:
|
||||
void run();
|
||||
virtual void init();
|
||||
virtual void update();
|
||||
};
|
||||
|
||||
#endif // TEXTGAME_HPP
|
||||
|
||||
Reference in New Issue
Block a user