Hello everyone !
I was developping a server when I got a bug. sf::IpAddress::getPublicAddress always return 0.0.0.0.
So, I tried to make a minimal working example and it still do the same :
#include <iostream>
#include "SFML/Network.hpp"
int main()
{
std::cout << sf::IpAddress::getLocalAddress() << std::endl;
std::cout << sf::IpAddress::getPublicAddress() << std::endl;
return 0;
}
This is what it prints:
192.168.1.64
0.0.0.0
Anyone know if I'm doing something wrong ?
I'm using VS 2019 under Windows 10. I'm using SFML 2.5.1 for VC++15 with static linking
Thanks in advance