Game Development Community

Cross Platform TNLTest Problem

by David Wyand · in Torque Game Engine · 01/12/2005 (2:44 pm) · 3 replies

Greetings!

Should the TNLTest application (from the OpenTNL CVS Head a day ago) work across platforms out of the box?

I've got two Windows computers (WinXP Pro SP1 and Win98SE) and one Mac OSX computer (OSX 10.3.7). The two Windows machines have no problem seeing each other with one as the server and the other as a client. However, the Mac will not talk to the Window server after connecting, nor will a Windows client talk to the Mac as a server once connected.

Here's the log from my WinXP machine as the server (number on the left are in seconds, and 192.168.0.3 is the Mac computer which was manually restarted as a client at 71463.578):

71438.843: ------ TNL Test Game (Windows) Log File ------
71438.859: Winsock initialization succeeded.
71438.859: Socket created - bound to address: IP:Any:2301
71438.859: UDP receive buffer size set to 32768.
71438.859: UDP send buffer size set to 32768.
71438.859: UDP socket non-blocking IO set.  UDP socket initialized.
71438.906: Created a client...
71439.093: IP:Broadcast:28999 - sending ping.
71440.765: Destroyed a client...
71440.765: Socket created - bound to address: IP:Any:28999
71440.765: UDP receive buffer size set to 32768.
71440.765: UDP send buffer size set to 32768.
71440.765: UDP socket non-blocking IO set.  UDP socket initialized.
71440.812: Created a server...
71445.843: IP:192.168.0.3:49219 - received ping.
71445.843: IP:192.168.0.3:49219 - sending ping response.
71446.218: Timer: secretSubKeyGen Elapsed: 41.4825 ms
71446.218: IP:192.168.0.3:49219 - client connected.
71463.578: IP:192.168.0.3:49219 - client connection terminated - reason 3.
71463.671: IP:192.168.0.3:49220 - received ping.
71463.671: IP:192.168.0.3:49220 - sending ping response.
71463.906: Timer: secretSubKeyGen Elapsed: 44.9892 ms
71463.921: IP:192.168.0.3:49220 - client connected.
71477.000: IP:192.168.0.3:49220 - client connection terminated - reason 5.
71477.000: Destroyed a server...

And here's the log from my Mac acting as a client (192.168.0.2 is the WinXP computer, and the client was restarted from the menu option at 19.737):

0.170000: ------ TNL Test Game (OSX) Log File ------
0.171000: Socket created - bound to address: IP:Any:49219
0.171000: UDP receive buffer size set to 32768.
0.171000: UDP send buffer size set to 32768.
0.171000: UDP socket non-blocking IO set.  UDP socket initialized.
0.235000: Created a client...
2.001000: IP:Broadcast:28999 - sending ping.
2.021000: IP:192.168.0.2:28999 - received ping response.
2.021000: Connecting to server: IP:192.168.0.2:28999
2.095000: Timer: secretSubKeyGen Elapsed: 53 ms
2.331000: Client puzzle solved in 290 ms.
2.381000: IP:192.168.0.2:28999 - connected to server.
6.749000: posting new position (0.7075, 0.1575) to server
13.380000: posting new position (0.1175, 0.2575) to server
19.737000: IP:192.168.0.2:28999 - server connection terminated - reason 5.
19.738000: Destroyed a client...
19.738000: Socket created - bound to address: IP:Any:49220
19.738000: UDP receive buffer size set to 32768.
19.738000: UDP send buffer size set to 32768.
19.738000: UDP socket non-blocking IO set.  UDP socket initialized.
19.793000: Created a client...
19.839000: IP:Broadcast:28999 - sending ping.
19.841000: IP:192.168.0.2:28999 - received ping response.
19.841000: Connecting to server: IP:192.168.0.2:28999
19.914000: Timer: secretSubKeyGen Elapsed: 52 ms
20.027000: Client puzzle solved in 166 ms.
20.101000: IP:192.168.0.2:28999 - connected to server.
24.171000: posting new position (0.5975, 0.85) to server

As you may see, I try the Mac connection twice, which appears to work. However, after the connection is made the client and server appear to no longer converse.

I'll continue to look into this, but was wondering if anyone has had this problem or can confirm that the TNLTest application does indeed work across multiple platforms.

Thanks!

- LightWave Dave

About the author

A long time Associate of the GarageGames' community and author of the Torque 3D Game Development Cookbook. Buy it today from Packt Publishing!


#1
01/15/2005 (10:16 am)
I need to update the CVS head with the latest TNL from Zap -- there was an endian bug in the encryption layer that may be interefering with TNLTest -- but then it looks like encryption is off for your test.

Hmm...
#2
01/15/2005 (10:51 am)
Greetings Mark!

Any help is appreciated and I'll try out your changes once they're in the CVS Head. I'm just using the stock TNLTest on both the PC and Mac other than my adding a LogConsumer to dump to a file, so perhaps you guys could test it in the office.

Oh, BTW, there were a couple of changes that I had to make to the MyOpenGLView.mm file on the Mac to allow it to compile. It wasn't referencing the TNL namespace so it required putting TNL:: in front of the appropriate definitions. I could send you the file if you'd like.

- LightWave Dave
#3
01/22/2005 (10:22 am)
I'm currently out of the country, so I will get on it as soon as I get back (2 weeks). That would be great if you'd send me the fixed view source.

Thanks from Mexico :)
- Mark