Game Development Stack Exchange is a question and answer site for professional and independent game developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm working on a simple round&web-based multiplayer game. The idea of the game is very simple: The players get an array of audio files which they listen to and write the transcripts for in 5 minutes. the player who sends in the most right transcripts gets the most points. its fairly simple and i was able to implement it locally. at the moment i have the .php file which lets me do all this but only in single player. what i'm trying to say is that whenever a player logs him/herself in, the page is loaded anew. what i want to do is to start the game from the server everytime 3-5 players log themselves in, so that the players can play at the same time and their results can be compared at the end of the round.

the thing is, i don't know how to start with this session or server/client model for a multiplayer game. i have read that php isn't ideal for web based multiplayer games because real time data exchange could be problematic, but since that is not really the case here i don't think that should be a major problem. i googled my problem but i have failed to find a solution. any help or advice would be much appreciated. cheers.

edit: is a node.js server what i'm looking for here?

share|improve this question
all that i can fine via google was with but i don't really need it do i? i mean there should not be any real time interaction, the players should only start at the same moment and get the same array. – Revangelis Jan 20 '13 at 12:12
up vote 1 down vote accepted is precisely what you want. If you want to start a tad simpler, you could use ajax and an timeout to poll the server every 30 seconds or whatever time period to get a response concerning other players around. So really either take the active approach with socket "The server has just told me someone joined, someone answered, etc" or the passive ajax approach "Let me ask the server if anything has happened."

share|improve this answer
thanks a lot. one small question, could i use websockets node instead of – Revangelis Jan 20 '13 at 21:05
Oh, absolutely, which implementation you use doesn't matter, although has some nice fallback options (using flash to mimic sockets all the way down to doing the aforementioned ajax polling) so it's a fairly complete package – user25397 Jan 20 '13 at 21:17

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.