Updated packet handling

Added "game in progress" message for players trying to join late.  Improved "unknown host" packet logging to only log when truly unknown. Correctly abort network window so game can process fatal errors instead of hanging on waiting to connect. Unexpected disconnects in lobby now correctly update the state of the game.
This commit is contained in:
Boondorl 2024-11-05 15:29:57 -05:00 committed by Ricardo Luís Vaz Silva
commit 3f4513c571
8 changed files with 64 additions and 11 deletions

View file

@ -64,6 +64,12 @@ bool NetStartWindow::RunMessageLoop(bool (*newtimer_callback)(void*), void* newu
return Instance->exitreason;
}
void NetStartWindow::NetClose()
{
if (Instance != nullptr)
Instance->OnClose();
}
NetStartWindow::NetStartWindow() : Widget(nullptr, WidgetType::Window)
{
SetWindowBackground(Colorf::fromRgba8(51, 51, 51));