ref: bcc08f6457f4bd4c42823ce28b955fad0857c8f9
parent: 67c11dcca7654b94adc9fc91b5a98b0b374d6b32
author: Marc-Alexandre Espiaut <marcalexandre@member.fsf.org>
date: Tue Jun 5 09:26:32 EDT 2018
Removing obsolete development code from rt_net.c
--- a/rott/rt_net.c
+++ b/rott/rt_net.c
@@ -320,14 +320,6 @@
server=consoleplayer^1;
}
}
-#if 0
-#if (DEVELOPMENT == 1)
- if (IsServer)
- ComError("I am the server\n");
- ComError("consoleplayer=%ld\n",consoleplayer);
- ComError("server=%ld mynumber=%ld\n",server,consoleplayer);
-#endif
-#endif
}
@@ -446,9 +438,6 @@
void ShutdownClientControls ( void )
{
int i;
-#if (DEVELOPMENT == 1)
- SoftError ("LARGEST time difference=%ld\n",largesttime);
-#endif
controlupdatestarted=0;
for (i=0; i<numplayers; i++)
{
@@ -569,11 +558,6 @@
}
}
-
-#if (DEVELOPMENT == 1)
-// ComError("StartupClientControls: GetTicCount()=%ld oldtime=%ld controlupdatetime=%ld\n",GetTicCount(),oldtime,controlupdatetime);
-#endif
-
if ((demoplayback==false) && (standalone==false))
{
if (modemgame==true)
@@ -749,12 +733,10 @@
// take out
if (modemgame==true)
{
-//#if (DEVELOPMENT == 1)
if (PanicPressed==true)
{
Error("Game Aborted. Scroll Lock pressed\n");
}
-//#endif
if (Keyboard[sc_Insert] && Keyboard[sc_Q])
Error("Game Aborted. Insert->Q pressed\n");
}
@@ -797,9 +779,6 @@
if (badpacket==0)
{
ProcessPacket(&ROTTpacket[0], rottcom->remotenode);
-#if (DEVELOPMENT == 1)
-// ComError("CheckForPacket: from=%ld\n",rottcom->remotenode);
-#endif
}
else
RequestPacket (LastCommandTime[rottcom->remotenode]+controldivisor, rottcom->remotenode, controldivisor);
@@ -989,10 +968,6 @@
if (modemgame==true)
SendPacket (pkt, server);
-#if (DEVELOPMENT == 1)
-// ComError("packet sent: realtime=%ld time=%ld type=%ld dest=%ld\n",GetTicCount(),pkt->time,pkt->type,server);
-#endif
-
controlupdatetime+=controldivisor;
waminot();
}
@@ -1142,9 +1117,6 @@
ComError("SendPacket:Problems\n");
else
WritePacket(pkt,GetPacketSize(pkt),dest);
-#if (DEVELOPMENT == 1)
-// ComError( "SendPacket: time=%ld dest=%ld\n",((MoveType *)pkt)->time,dest);
-#endif
}
//****************************************************************************
@@ -1995,12 +1967,6 @@
COM_RequestType request;
int i;
-
-#if (DEVELOPMENT == 1)
- if (modemgame==false)
- Error("Called Request Packet outside of modem game\n");
-#endif
-
request.type=COM_REQUEST;
request.time=time;
request.numpackets=numpackets/controldivisor;
@@ -2033,10 +1999,6 @@
// send out the packet
WritePacket (&request, GetPacketSize(&request), dest);
-
-#if (DEVELOPMENT == 1)
-// ComError( "BADPKT, request sent at %ld lgt=%ld dest=%ld\n",GetTicCount(),time,dest);
-#endif
}
//****************************************************************************
@@ -2373,9 +2335,6 @@
while(1)
{
ProcessServer();
-#if (DEVELOPMENT == 1)
- Z_CheckHeap();
-#endif
CalcTics();
if (restartgame==true)
break;
@@ -2677,22 +2636,6 @@
if (demoplayback||demorecord) {
SoftError(" dmx=%4x dmy=%4x da=%4x time=%5d\n",pstate->dmomx,pstate->dmomy,pstate->angle>>11,oldpolltime);
}
-#if 0
-#if (DEVELOPMENT == 1)
- if ((modemgame==true) || (demoplayback==true) || (demorecord==true))
- {
- ComError( "player#%2ld\n",player);
- ComError( "momx = %6ld\n", PLAYER[player]->momentumx);
- ComError( "momy = %6ld\n", PLAYER[player]->momentumy);
- ComError( " x = %6ld\n", PLAYER[player]->x);
- ComError( " y = %6ld\n", PLAYER[player]->y);
- ComError( " z = %6ld\n", PLAYER[player]->z);
- ComError( " a = %6ld\n", PLAYER[player]->angle);
- if (pstate->buttonstate[bt_attack])
- ComError( "FIRING\n");
- }
-#endif
-#endif
}