SFML community forums
Help => Network => Topic started by: Shimajda on April 13, 2010, 03:20:29 pm
-
I have another problem :)
Cant get SocketTCP::Connect to work under VisualStudio2008.
After linking program startsup and when he call Connect function i have something like that:
http://zapodaj.net/0f0481fada1e.png.html
Continue button sems to be endless loop.
Heres my code (VS Win32 Console App project):
#include "stdafx.h"
#include <SFML/Network.hpp>
int _tmain(int argc, _TCHAR* argv[])
{
sf::SocketTCP Client;
if (Client.Connect(4567, "192.168.0.2") != sf::Socket::Done)
{
// Error...
}
return 0;
}
SFML 1.6 for VisualStudio2008 (static)
-
I have no problem with this code. Make sure that you're not using release libraries in debug mode.
-
Im using sfml-network-s.lib only.
I have two releases and for mingw connect works.
-
You must use sfml-network-s-d.lib in debug mode.
-
Thanks again :D
Ive linked -s-d to Debug config, and -s to Relase config. Both are working.