SBServerGetPublicAddress
Returns the external address of the SBServer, if any. For users behind a NAT or firewall, this is the address of the outermost NAT or firewall layer.
- char * SBServerGetPublicAddress(
- SBServer server );
Routine | Required Header | Distribution |
---|---|---|
SBServerGetPublicAddress | <sb_serverbrowsing.h> | SDKZIP |
Return Value
The public address of the SBServer, in string or integer form.
Parameters
- server
- [in] A valid SBServer object.
Remarks
When a client machine is behind a NAT or Firewall device, communication must go through the public address. The public address of the SBServer is the address of the outermost Firewall or NAT device.
The SBServer object may be obtained during the SBCallback from ServerBrowserUpdate, or by calling ServerBrowserGetServer. An SBServer object will only exist for servers in the list. IP addresses removed from the server list will not have an SBServer object associated.
Section Reference: Gamespy Server Browsing SDK
See Also: ServerBrowserNew, ServerBrowserUpdate, ServerBrowserGetServer