Add simple command interface

This commit is contained in:
Lion Kortlepel
2021-11-28 23:45:03 +01:00
parent 1e0ab6bbb3
commit 768d0466f4
6 changed files with 109 additions and 17 deletions

View File

@@ -77,6 +77,9 @@ void TLuaEngine::operator()() {
// event loop
auto Before = std::chrono::high_resolution_clock::now();
while (!mShutdown) {
if (mLuaStates.size() == 0) {
std::this_thread::sleep_for(std::chrono::seconds(500));
}
{ // Timed Events Scope
std::unique_lock Lock(mTimedEventsMutex);
for (auto& Timer : mTimedEvents) {