X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=cl_main.c;h=30b275604c1db4386e04fe46e530bd9582c24a7f;hb=142ec9e43c5bd046ce3a33e822167373bf244d21;hp=122111e23be02e1a3951585fec3fb750f7b150eb;hpb=c65b6faa99d227bcd00107311acfb66a95be02c6;p=xonotic%2Fdarkplaces.git diff --git a/cl_main.c b/cl_main.c index 122111e2..30b27560 100644 --- a/cl_main.c +++ b/cl_main.c @@ -197,6 +197,7 @@ void CL_Disconnect (void) NET_SendUnreliableMessage (cls.netcon, &cls.message); SZ_Clear (&cls.message); NET_Close (cls.netcon); + cls.state = ca_disconnected; // prevent this code from executing again during Host_ShutdownServer // if running a local server, shut it down if (sv.active) Host_ShutdownServer(false); @@ -227,7 +228,7 @@ Host should be either "local" or a net address to be passed on void CL_EstablishConnection (char *host) { sizebuf_t buf; - byte data[128]; + qbyte data[128]; buf.maxsize = 128; buf.cursize = 0; @@ -594,7 +595,7 @@ static void CL_RelinkNetworkEntities() glowcolor = ent->state_current.glowcolor; if (glowsize) { - byte *tempcolor = (byte *)&d_8to24table[glowcolor]; + qbyte *tempcolor = (qbyte *)&d_8to24table[glowcolor]; dlightcolor[0] += glowsize * tempcolor[0] * (1.0f / 255.0f); dlightcolor[1] += glowsize * tempcolor[1] * (1.0f / 255.0f); dlightcolor[2] += glowsize * tempcolor[2] * (1.0f / 255.0f); @@ -830,9 +831,13 @@ void CL_SendCmd (void) // get basic movement from keyboard CL_BaseMove (&cmd); + IN_PreMove(); // OS independent code + // allow mice or other external controllers to add to the move IN_Move (&cmd); + IN_PostMove(); // OS independent code + // send the unreliable message CL_SendMove (&cmd); }