31
TNet 3 Support / Re: Gameserver Ping doesnt work?
« on: January 05, 2015, 01:12:03 PM »
Yes, but if i try to ping UDP, i get no answer, too.
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
The ping is because I never added the handling for it to the UDP lobby server. Open TNUdpLobbyClient.cs, line 121 (inside the 'case' statement of the ProcessPacket function) and add the handling for the Ping packet:You mean the TNUdpLobbyServer.cs, right? Because, i cant find any case statement on TNUdpLobbyClient.cs.
case Packet.RequestPing: { BeginSend(Packet.ResponsePing); EndSend(ip); break; }
Note that you should also modify the TNGameClient's Ping() function on line 655:I added this line, but i dont receive any ping from the external GameServer.
public void Ping (IPEndPoint udpEndPoint, OnPing callback) { onPing = callback; mPingTime = DateTime.Now.Ticks / 10000; // <-- this was missing BeginSend(Packet.RequestPing); EndSend(udpEndPoint); }