Fix NETCODE_DISABLED builds. We should probably rename Net_GetPackets() to something else, because it does other required things.

git-svn-id: https://svn.eduke32.com/eduke32@7295 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2018-12-15 22:33:15 +00:00
parent 22ad4221d9
commit 8447e3392d
2 changed files with 34 additions and 34 deletions

View file

@ -76,6 +76,37 @@ void faketimerhandler(void)
}
#endif
void Net_GetPackets(void)
{
timerUpdate();
MUSIC_Update();
S_Cleanup();
G_HandleSpecialKeys();
#ifndef NETCODE_DISABLE
if (g_netDisconnect)
{
Net_Disconnect();
g_netDisconnect = 0;
if (g_gameQuit)
G_GameExit(" ");
return;
}
if (g_netServer)
{
Net_HandleClientPackets();
}
else if (g_netClient)
{
Net_HandleServerPackets();
}
#endif
}
// (the rest of the file)
#ifndef NETCODE_DISABLE
@ -4764,35 +4795,6 @@ void Net_AddWorldToInitialSnapshot()
Net_AddWorldToSnapshot(&g_mapStartState);
}
void Net_GetPackets(void)
{
timerUpdate();
MUSIC_Update();
S_Cleanup();
G_HandleSpecialKeys();
if (g_netDisconnect)
{
Net_Disconnect();
g_netDisconnect = 0;
if (g_gameQuit)
G_GameExit(" ");
return;
}
if (g_netServer)
{
Net_HandleClientPackets();
}
else if (g_netClient)
{
Net_HandleServerPackets();
}
}
void Net_SendClientInfo(void)
{
int32_t i, l;

View file

@ -298,8 +298,6 @@ void Net_WaitForInitialSnapshot();
// note: don't include faketimerhandler in this
#define Net_GetPackets(...) ((void)0)
#define Net_Connect(...) ((void)0)
#define Net_SendClientInfo(...) ((void)0)