summary refs log tree commit diff stats
path: root/src/script_system.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/script_system.h')
-rw-r--r--src/script_system.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/script_system.h b/src/script_system.h index 2d099e3..18850b3 100644 --- a/src/script_system.h +++ b/src/script_system.h
@@ -4,6 +4,7 @@
4#include <sol/sol.hpp> 4#include <sol/sol.hpp>
5#include <memory> 5#include <memory>
6#include <set> 6#include <set>
7#include <list>
7#include <string> 8#include <string>
8#include "system.h" 9#include "system.h"
9 10
@@ -24,9 +25,14 @@ public:
24 25
25private: 26private:
26 27
28 struct Script {
29 std::unique_ptr<sol::thread> runner;
30 std::unique_ptr<sol::coroutine> callable;
31 };
32
27 Game& game_; 33 Game& game_;
28 sol::state engine_; 34 sol::state engine_;
29 std::unique_ptr<sol::coroutine> callable_; 35 std::list<Script> scripts_;
30 std::set<std::string> loadedScripts_; 36 std::set<std::string> loadedScripts_;
31}; 37};
32 38