LuaYard/LuaYard.cpp
Kiritow f1ef4bfc9d 独立事件循环
将事件循环从Window类移动到Top Level.
2019-08-10 21:36:35 +08:00

21 lines
347 B
C++

#include <iostream>
#include <string>
#include "LuaEngine.h"
using namespace std;
int main()
{
do {
LuaVM L;
InitEngine(L);
cout << "<ENGINE> Started." << endl;
if (luaL_dofile(L, "code/init.lua"))
{
cout << lua_tostring(L, -1) << endl;
}
StartEngine(L);
cout << "<ENGINE> Stopped." << endl;
} while (0);
StopEngine();
}