add assert, lower main loop sleep interval to 20ms. CL_NetSession is buggy, goes into deadlock due to missing mutex
--- a/src/proto2/Engine.cc Sun Nov 09 22:05:53 2008 +0000
+++ b/src/proto2/Engine.cc Mon Nov 10 01:29:43 2008 +0000
@@ -39,7 +39,7 @@
// if I can't find some better way to do this in ClanLib by next thursday, then it f*%!ing sucks
// ideally, we should be able to have a main loop that does timed waits on I/O, fufilling some set of timers
// but as far as I can tell, ClanLib doesn't have anything like that
- CL_System::sleep(100);
+ CL_System::sleep(20);
}
}
--- a/src/proto2/NetworkClient.cc Sun Nov 09 22:05:53 2008 +0000
+++ b/src/proto2/NetworkClient.cc Mon Nov 10 01:29:43 2008 +0000
@@ -121,7 +121,7 @@
Engine::log(INFO, "client_player.on_position") << "obj=" << obj << ", pos=" << pos;
- updatePosition(pos);
+ assert(updatePosition(pos));
}
NetworkClientRemotePlayer::NetworkClientRemotePlayer (NetworkClient &client, CL_NetObject_Client &obj, Coordinate initial_position) :