Cannot connect to master server with Realtime C++ SDK
Hi,
I was following the demo project on Realtime C++ SDK and I created a new project to try build one from scratch.
However, when starting, the program doesn't seems to be able to connect.
The debug info only shows:
2018-12-24 16:42:52,451 INFO peerbase.cpp ExitGames::Photon::Internal::PeerBase::connect() 128 address: ns.exitgames.com:5058
I've check and made sure that all pre-defined macros are the same as the demo.
I know the network is not the issue since the demo projects are working fine.
I'm not sure if I've correctly included all the external libraries though. The program compiles and runs fine, but it misses 2 External Dependencies when I compared it with the demo project: conio.h and fcntl.h.
I've also tried to leave the program there for a while. Nothing changes except the output of VS shows that 4 threads has exits:
“The thread 0x4048 has exited with code 0 (0x0).
The thread 0x434c has exited with code 0 (0x0).
The thread 0x39dc has exited with code 0 (0x0).
The thread 0x43f8 has exited with code 0 (0x0).”
I'm using VS 2017 on a windows 7.
Can anyone help me with this?
I was following the demo project on Realtime C++ SDK and I created a new project to try build one from scratch.
However, when starting, the program doesn't seems to be able to connect.
The debug info only shows:
2018-12-24 16:42:52,451 INFO peerbase.cpp ExitGames::Photon::Internal::PeerBase::connect() 128 address: ns.exitgames.com:5058
I've check and made sure that all pre-defined macros are the same as the demo.
I know the network is not the issue since the demo projects are working fine.
I'm not sure if I've correctly included all the external libraries though. The program compiles and runs fine, but it misses 2 External Dependencies when I compared it with the demo project: conio.h and fcntl.h.
I've also tried to leave the program there for a while. Nothing changes except the output of VS shows that 4 threads has exits:
“The thread 0x4048 has exited with code 0 (0x0).
The thread 0x434c has exited with code 0 (0x0).
The thread 0x39dc has exited with code 0 (0x0).
The thread 0x43f8 has exited with code 0 (0x0).”
I'm using VS 2017 on a windows 7.
Can anyone help me with this?
0
Best Answer
-
Hi @Fire1nRain.
Have you figured this out by now or do you still have issues to get your project to connect?
From the info that you have provided your setup sounds correct, so the connection problems must be caused by something that you have not mentioned.
Have you verified that your code calls Client::service() regularly (like i.e. once every 100ms)? This is a critical requirement and you won't even be able to connect to the Photon servers otherwise.5
Answers
-
Hi @Fire1nRain.
Have you figured this out by now or do you still have issues to get your project to connect?
From the info that you have provided your setup sounds correct, so the connection problems must be caused by something that you have not mentioned.
Have you verified that your code calls Client::service() regularly (like i.e. once every 100ms)? This is a critical requirement and you won't even be able to connect to the Photon servers otherwise.5 -
Hi, @Kaiserludi Yes, it was because I forgot to call Client::service().0