mirror of
https://github.com/BeamMP/BeamMP-Server.git
synced 2026-04-23 08:27:06 +00:00
Report errors on WaitForAll
This commit is contained in:
@@ -65,7 +65,7 @@ void TLuaEngine::operator()() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (Res->Error) {
|
if (Res->Error) {
|
||||||
beammp_lua_error(Res->ErrorMessage);
|
beammp_lua_error(Res->Function + ": " + Res->ErrorMessage);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -139,6 +139,9 @@ void TLuaEngine::WaitForAll(std::vector<std::shared_ptr<TLuaResult>>& Results) {
|
|||||||
while (!Result->Ready) {
|
while (!Result->Ready) {
|
||||||
std::this_thread::sleep_for(std::chrono::milliseconds(10));
|
std::this_thread::sleep_for(std::chrono::milliseconds(10));
|
||||||
}
|
}
|
||||||
|
if (Result->Error) {
|
||||||
|
beammp_lua_error(Result->Function + ": " + Result->ErrorMessage);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -331,8 +331,6 @@ void TNetwork::Authentication(const TConnection& ClientConnection) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
LuaAPI::MP::Engine->ReportErrors(Futures);
|
|
||||||
|
|
||||||
if (mServer.ClientCount() < size_t(Application::Settings.MaxPlayers)) {
|
if (mServer.ClientCount() < size_t(Application::Settings.MaxPlayers)) {
|
||||||
beammp_info("Identification success");
|
beammp_info("Identification success");
|
||||||
mServer.InsertClient(Client);
|
mServer.InsertClient(Client);
|
||||||
|
|||||||
Reference in New Issue
Block a user