Multi player tracking ...

Posted on 2003-02-23
Medium Priority
Last Modified: 2010-04-17
I am writing a simple game (for fun) which is suppose to be a multi-player one. I have totally no idea how can I obtain information from the multi players? I wanna start with a simple LAN environment. Do I have to identify each player from his/her IP? How can I capture the information? I am using VB6. Any help with sample would be GREAT :D
Question by:ndroo
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2

Expert Comment

ID: 8002633
I would recommend using a client-server model.
A player will first need to register using a username (and optional a password, if you require security).

First the user connects to the game-server and if the user has already a username (/password combination) if not a new one can be registered on the server.

The server has a connection to all the players using TCP/IP (or what ever protocol you require). You only have to remember which connection is leading to which user so thats how you identify users when playing the game.

If you only require to identify users while playing you only need to know which connection is leading to which user


Author Comment

ID: 8002721
thanx for ur comment skunkah. however, my plan is to have the system run 'transparently' (without anything to do with a server). this means, any of the players (client) will be choosen to 'host' the current game information. this way, other players PC will have to read those info from that particular PC. it will be a very simple game, whereby each player takes turn to play some cards. the only information so far i think is needed, is whose turn it is to play, and the current score.

Accepted Solution

skunkah earned 1500 total points
ID: 8002874
About the identification, you could use the IP address to identify the users but you could also as I said use username (and password if you require that) to identify a user.

If you want to identify users during the game you don't really have to do anything, as I said you only have to know who is on which connection.

I would recommend to hold the scores in an array which holds the number of connections + 1 scores. The +1 is for the player that's hosting the game.

Turns will also be tracked by the server and if it's a players turn it will simply send over the connection which turn it is .. also in this case don't forget to give the hosting party a turn :)


Expert Comment

ID: 9447574
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
Post your closing recommendations!  No comment means you don't care.

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Entering a date in Microsoft Access can be tricky. A typo can cause month and day to be shuffled, entering the day only causes an error, as does entering, say, day 31 in June. This article shows how an inputmask supported by code can help the user a…
Computer science students often experience many of the same frustrations when going through their engineering courses. This article presents seven tips I found useful when completing a bachelors and masters degree in computing which I believe may he…
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question