Advertisement

How do you handle a Client that is also the Server?

Started by December 18, 2002 12:59 AM
2 comments, last by Teknofreek 22 years, 1 month ago
I''m sure there are 10 ways til Sunday to handle this scenario, but I''m just kinda curious if there are any preferred or tried-and-true methods that anyone knows of or have used to handle a single app that is both the Server and a Client at the same time? -John
- John
I think you could have your application connect to itself. Just specify localhost [127.0.0.1] as the IP address you want to connect to.

Having the client and server in one application can be quite handy for single player games. Check out Michael Abrash''s article on Quake''s client-server architecture here.
Advertisement
Thanks for the link, I''ll check it out

-John
- John
What do you mean a client and a server? A process can listen on port X and connect to a remote server on port X.

Kuphryn

This topic is closed to new replies.

Advertisement