Client code for NatTypeDetection.
More...
#include <NatTypeDetectionClient.h>
List of all members.
Detailed Description
See NatTypeDetectionServer.h for algorithm To use, just connect to the server, and call DetectNAT You will get back ID_NAT_TYPE_DETECTION_RESULT with one of the enumerated values of NATTypeDetectionResult found in NATTypeDetectionCommon.h See also http://www.jenkinssoftware.com/raknet/manual/natpunchthrough.html
- See also:
- NatPunchthroughClient
-
NatTypeDetectionServer
Definition at line 37 of file NatTypeDetectionClient.h.
Constructor & Destructor Documentation
| RakNet::NatTypeDetectionClient::NatTypeDetectionClient |
( |
| ) |
|
| virtual RakNet::NatTypeDetectionClient::~NatTypeDetectionClient |
( |
| ) |
[virtual] |
Member Function Documentation
| void RakNet::NatTypeDetectionClient::DetectNATType |
( |
SystemAddress |
_serverAddress | ) |
|
Send the message to the server to detect the nat type Server must be running NatTypeDetectionServer We must already be connected to the server
- Parameters:
-
| [in] | serverAddress | address of the server |
| bool RakNet::NatTypeDetectionClient::IsInProgress |
( |
void |
| ) |
const [protected] |
Called when a connection is dropped because the user called RakPeer::CloseConnection() for a particular system
- Parameters:
-
| [in] | systemAddress | The system whose connection was closed |
| [in] | rakNetGuid | The guid of the specified system |
| [in] | lostConnectionReason | How the connection was closed: manually, connection lost, or notification of disconnection |
Reimplemented from RakNet::PluginInterface2.
OnReceive is called for every packet.
- Parameters:
-
| [in] | packet | the packet that is being returned to the user |
- Returns:
- True to allow the game and other plugins to get this message, false to absorb it
Reimplemented from RakNet::PluginInterface2.
| void RakNet::NatTypeDetectionClient::OnTestPortRestricted |
( |
Packet * |
packet | ) |
[protected] |
| void RakNet::NatTypeDetectionClient::Shutdown |
( |
void |
| ) |
[protected] |
| virtual void RakNet::NatTypeDetectionClient::Update |
( |
void |
| ) |
[virtual] |
Member Data Documentation
The documentation for this class was generated from the following file: