Address[0].guidDataType = DPAID_ServiceProvider;
Address[0].dwDataSize = sizeof(GUID);
Address[0].lpData = (LPVOID)&DPSPGUID_TCPIP; // TCP ID
Address[1].guidDataType = DPAID_INet;
Address[1].dwDataSize = lstrlen(IP_address)+1;
Address[1].lpData = IP_address;
Port in DirectPlay ?
Hi,
I'm making a simple online game, and I use Sobeit Void's tutorial as reference. I wonder, what Port does DirectPlay use ? (So I can configure Firewall correctly).
Here's a snippet code of Sobeit's tutorial :
From what I understand, it doesn't use any specific port. It can't use restricted ports(ports used for other specific things) but can otherwise use any open port. If I remember correctly, the only requirement as far as this goes is that the server and client must be connected on the same port on both computers, but I could be wrong on that. Anyway, hope that helps.
-AJ
-AJ
Depending on the version DirectPlay use different ranges of ports and assign them more or less random to your application.
You can find a list there: http://support.microsoft.com/kb/240429/EN-US/
This is one of many reasons why you should not use DirectPlay anymore. If you want to build a multiplayer game use Winsock or a third party library that use Winsock.
You can find a list there: http://support.microsoft.com/kb/240429/EN-US/
This is one of many reasons why you should not use DirectPlay anymore. If you want to build a multiplayer game use Winsock or a third party library that use Winsock.
Guys, it seems that I can't connect the client to server. Before that, when we tested it in intranet(LAN), it worked. However, when we test it on Internet now, it doesn't.
The server used Leased Line connection(they use "tower" to connect to ISP, the speed is 64k, IIRC). Its IP Addresss is 202.xx.xx.xx. From what the ISP told us, they have already disabled firewall.
As for the client, we use modem dialup, the IP Address is 202.xx.xx.xx too. (different ISP)
However, we could connect to the server, if we use internet connection provided by the same ISP.
So, what should I do ? Do I have to change the connection configuration of DirectPlay ?
(Note: I use code from Sobeit's tutorial)
The server used Leased Line connection(they use "tower" to connect to ISP, the speed is 64k, IIRC). Its IP Addresss is 202.xx.xx.xx. From what the ISP told us, they have already disabled firewall.
As for the client, we use modem dialup, the IP Address is 202.xx.xx.xx too. (different ISP)
However, we could connect to the server, if we use internet connection provided by the same ISP.
So, what should I do ? Do I have to change the connection configuration of DirectPlay ?
(Note: I use code from Sobeit's tutorial)
Ah, it already works. It's the ISP which is faulty. After they tinkered the internet connection configuration, it works.
Sorry for bothering you guys.
Sorry for bothering you guys.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement