   Online Chat in C++... ftp or is there a better way?
  I'm writing a very simple text-based strategy game; the most difficult part will be sending and receiving int variables and strings online.I need to send several variables (which I can have written to a file...if that helps) to another person inside the program.Are there any simple ways to connect players together so the program can send the string every time cin.get() is activated and post everything received (or read from a file every few seconds or something)?I was thinking about doing this via ftp.  Will this be fast enough for a real-time online game, or is only the connection time long?Any suggestions would be greatly appreciated![Edited by - cppmonkey on December 29, 2007 9:53:56 AM]
  ^^That was me. :)Couldn't remember my old username/password so I made a new account, which I guess the server didn't like too much.   ;  You should check out Windows Socket API. Basicly from what I know (I havn't done much networking myself) you will create a server application and a client application. The server App will be allways running and then the users of your application (the people who are chatting) will have the client app. When a client app is opened it connects to the computer that is running the server application on a certain port which the server is listening on.When the client application sends a message it sends it to the server application, which then uses the data to figure out what to do, then sends the result back to all the clients that are connected.   ;  cNoob is correct, use sockets.I'm using a library called EzSocket ( http://ezsocket.sourceforge.net/ ) in the game I'm working on now. Using it isn't too bad, you might want to take a look.   ;  Thanks so much for the help!  I'll look into ezsocket.*edit: I'm having trouble compiling the library on windows... I'm in cmd prompt, did the cd to ezsocket step and I ran fixming.bat.  There isn't a "make" or "make install" included with my version though (and as far as I can tell, it's the only one).   Not really sure what to do next because I still can't run makefile and makefile.mgw.[Edited by - nibbuler on December 29, 2007 6:45:07 PM];  make is a common *NIX utility. Well, it's a build system really. It's ubiquitous, so on Windows, you either have to use a windows port, or cross your fingers and hope VC++'s nmake works. Learning to get the make system working might a good experience for a C++ intermediate, as you will have to start relying on third party libraries.[ Off topic: You could also try asio. It's in boost now, I believe. As with many other boost libraries, it's header only (no library to compile). Given that it's a boost type library, it makes full use of C++ features, and is high quality. ]First step to help: Are you using Visual C++ or MingW?   ;  Should've included that before.  VC++ :)I'll check out asio right now.   ;  I'm trying to compile makefile.msc now for the asio example.It's telling me: Fatal Error... can't open include file 'boost\config.hpp' no such file or directory... Which is a lie because I'm looking at the file right now and it's where it should be.  This is while its compiling client.cpp.  I've followed all the instructions to the T.Sigh.   ;  Rather learn winsock, that should prove better for you, it isn't very difficult anyway, just look around here, especially in the neyworking forum.   ;  From the Asio website: "There is no need to build any of the Boost libraries to use most of asio (the non-Boost version), and only the header files are required."You might be surprised, but much of Boost is header only. No code to compiler first. The same is true of Asio.Make sure you get Boost as well.   