Fixed design problem: Thread objects can now be created in any context.

Sender thread output queue is now limited.
Server thread now terminates correctly.
Now cloning packets when sending them to multiple recipients.
Fixed one thread issue - GameStart still needs to be made thread safe.
This commit is contained in:
lotodore
2007-03-20 11:56:30 +00:00
parent 53c4af95c8
commit 804c7eaaa2
12 changed files with 160 additions and 55 deletions
+3 -2
View File
@@ -121,9 +121,10 @@ ServerRecvStateStartGame::Process(ServerRecvThread &server)
{
boost::shared_ptr<NetPacket> answer(new NetPacketGameStart);
server.SendToAllClients(answer);
server.SendToAllPlayers(answer);
Thread::Msleep(100);
return MSG_SOCK_INIT_DONE;
return MSG_SOCK_INTERNAL_PENDING;
}
//-----------------------------------------------------------------------------