summaryrefslogtreecommitdiff
path: root/Editor/EditorMain.cpp
diff options
context:
space:
mode:
authorchai <chaifix@163.com>2021-10-25 23:29:21 +0800
committerchai <chaifix@163.com>2021-10-25 23:29:21 +0800
commit7ecf913256fb396e3027aac3318d996a716a52ef (patch)
tree4540835c881a63b665e2a692bf30115fd29e8bb0 /Editor/EditorMain.cpp
parent0816cd70ca1a213b6ed872bcf3c0bf0912473722 (diff)
+ job system
Diffstat (limited to 'Editor/EditorMain.cpp')
-rw-r--r--Editor/EditorMain.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/Editor/EditorMain.cpp b/Editor/EditorMain.cpp
index 555867a..5f16d63 100644
--- a/Editor/EditorMain.cpp
+++ b/Editor/EditorMain.cpp
@@ -7,6 +7,7 @@
#include "Runtime/Graphics/OpenGL.h"
#include "Editor/Scripting/EditorScripting.h"
#include "Editor/Win/Win.h"
+#include "Runtime/Threading/Thread.h"
using namespace LuaBind;
@@ -21,6 +22,7 @@ void InitLuaState(LuaBind::VM& vm)
vm.OpenLibs();
LuaBind::onRegisterNativeClass = LuaHelper::OnRegisterNativeClass;
+ LuaBind::onErrorOccured = ErrorHandle;
if (!SetupGameLabEditorScripting(vm.GetMainThread()))
{
@@ -33,7 +35,7 @@ void InitLuaState(LuaBind::VM& vm)
Win::SetDllSearchDirectory(workingDir);
LuaBind::State state = vm.GetMainState();
- state.DoFile("./boot.lua", ErrorHandle);
+ state.DoFile("./boot.lua");
}
#ifdef GAMELAB_DEBUG
@@ -42,6 +44,9 @@ int main()
int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrev, LPSTR szCmdLine, int sw)
#endif
{
+ WorkThread thread;
+ thread.Resume();
+
WindowUtil::RegisterClasses();
LuaBind::VM vm;