Page 3 of 3

Re: Cannot build NATCompleteServer using CMake

Posted: Tue Jan 30, 2018 12:27 am
by mantracker
Luke1410 wrote:If the logs you provided there are accurate then it seems as if you entered the wrong GUID of the listening client when setting up the "other client". The Listening client reported its GUID to be: 67555774598987172

According to the log in the "other client" you entered: 1076360901365999200

Regarding your questions:
Yes the samples should in principle all run out of the box. Any issue using them as they are should be considered a bug.
Note however that by default the NATCompleteClient only has the NATPunchthrough case enabled. That's why it reports the UPNPFramework and NATTypeDetectionFramework failed. But these should not be necessary for the testing purpose in your case anyway, so it's all fine from that side.

Hey Luke:

Thanks so much for your help! I finally got it working. I kept on thinking that the GUID I was supposed to enter was the server one, and not the listening client's GUID, which is the reason why I said I had to change the code a bit where I exposed the GUID.

Things that were not straightforward to me (perhaps other users as well):
1. You need 2 clients, listening client and some other client. I knew that NAT punch uses 1 relay server and 2 clients, but I thought just having 1 client and 1 server should at least connect.
2. The GUID is confusing. I had no idea it was supposed to be the listening client

With the sample working, I will continue to try to integrate and learn the project. To give you a bit of a background, our team is creating an Unreal Engine 4 P2P game. We are trying to integrate SLikeNet as a NAT Punch solution into Unreal Engine 4. This is going to be a big challenge as there is almost no documentation or guide on how to do this. We are aware that Steam used libjingle to create Steamworks and integrated into UE4 to offer NAT Punch. We are trying to do something similar.

I definitely will need more help perhaps soon on this. I'll definitely ask again if I need more help.

Thanks so much for your help! There is no way I could do this without your diligently working through my problems with me :)

Re: Cannot build NATCompleteServer using CMake

Posted: Wed Jan 31, 2018 6:23 pm
by Luke1410
I'm glad all is working for you now and wish you good luck with your project. Don't hesitate to post any further questions/issues you might run into.

Re: Cannot build NATCompleteServer using CMake

Posted: Sun Mar 18, 2018 1:44 am
by Luke1410
SLikeNet 0.1.1 which contains the fix for case #172 (compile error of NATCompleteServer) has just been released.