From 2c61e2c67b333c6693a0f3418bb19cb37bb57999 Mon Sep 17 00:00:00 2001 From: Brian Bosak Date: Fri, 9 Aug 2013 13:23:37 -0500 Subject: [PATCH] Added IDWMaster_Loop for running code on main thraed --- host.c | 3 ++- idwmaster_gameroom.c | 2 ++ idwmaster_gameroom.h | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/host.c b/host.c index a54067af..3828c8b0 100644 --- a/host.c +++ b/host.c @@ -763,7 +763,8 @@ void Host_Main(void) // be undersleeping due to select() detecting a new packet if (sv.active && !svs.threaded) NetConn_ServerFrame(); - + //TODO: IDW main loop + IDWMaster_Loop(); Curl_Run(); // check for commands typed to the host diff --git a/idwmaster_gameroom.c b/idwmaster_gameroom.c index c892e4df..1710892c 100644 --- a/idwmaster_gameroom.c +++ b/idwmaster_gameroom.c @@ -50,7 +50,9 @@ static void TCPConnect(const char* hostname, int port, void(*connectDgate)(int)) memcpy(ptr->hostname,hostname,strlen(hostname)+1); Thread_CreateThread(callback,ptr); } +void IDWMaster_Loop() { +} static void msgloop(int sock) { unsigned char buffer[2048]; while(recv(sock,buffer,sizeof(buffer),0)>0) { diff --git a/idwmaster_gameroom.h b/idwmaster_gameroom.h index d5a837b6..131400f3 100644 --- a/idwmaster_gameroom.h +++ b/idwmaster_gameroom.h @@ -8,7 +8,7 @@ #ifndef IDWMASTER_GAMEROOM_H_ #define IDWMASTER_GAMEROOM_H_ void IDWMaster_Init(); - +void IDWMaster_Loop(); #endif /* IDWMASTER_GAMEROOM_H_ */ -- 2.39.2