Running listen server and client on one machine
by Nick Sandow · in Torque Game Engine · 11/11/2006 (12:15 am) · 2 replies
I sometimes run a TGE listen server and connect to it with another client on the same machine to test networking stuff.
Just now I tried this in 1.5 install for the first time and couldn't make it happen.
I went back to 1.4 and it works fine there.
In both cases I was sure to check "host multiplayer", and to tell Windows Firewall not to block the listen server when prompted.
Does this work in 1.5?
Any suggestions on troubleshooting this in 1.5?
Just now I tried this in 1.5 install for the first time and couldn't make it happen.
I went back to 1.4 and it works fine there.
In both cases I was sure to check "host multiplayer", and to tell Windows Firewall not to block the listen server when prompted.
Does this work in 1.5?
Any suggestions on troubleshooting this in 1.5?
#2
The basic problem is that I see "No servers found" when I hit the "Query Lan" button. Given that this works fine in 1.4 I thought this was possibly a known problem in 1.5.
Actually I did some more testing, and it seems the problem is with $pref::backgroundSleepTime. In 1.5, this has value 3000 ms. In 1.4 it is something like 25 ms. When it's 3000 I don't think the listen server has a chance to respond to the query packet from the client before the client concludes there are no servers on the LAN. (The listenserver gets put into the background when I start clicking around in the client server gui.)
Sure enough, when I set $pref::backgroundSleepTime to 25 ms in the 1.5 listenserver, my client can see it and all is well.
11/11/2006 (7:55 pm)
Thanks for your reply Stefan.The basic problem is that I see "No servers found" when I hit the "Query Lan" button. Given that this works fine in 1.4 I thought this was possibly a known problem in 1.5.
Actually I did some more testing, and it seems the problem is with $pref::backgroundSleepTime. In 1.5, this has value 3000 ms. In 1.4 it is something like 25 ms. When it's 3000 I don't think the listen server has a chance to respond to the query packet from the client before the client concludes there are no servers on the LAN. (The listenserver gets put into the background when I start clicking around in the client server gui.)
Sure enough, when I set $pref::backgroundSleepTime to 25 ms in the 1.5 listenserver, my client can see it and all is well.
Torque Owner Stefan Lundmark