none
Don't know how to design my program RRS feed

  • Question

  • Hello,

    I was a VB6 coder for years, and now work mostly in PHP. I want to build an application but I don't know how to go about doing so.

    It will be a multi-user quiz-type of application in a GUI format (kind of like a Jeopardy! computer game). Here is a high-level view of the functionality:

    On the client side, users will sign in (the request will be verified by the server app and MySQL db on the server), make selections (such as difficulty levels, question categories, and single or 2-player). Then, they'll play the game, either by themselves or against another player who is located elsewhere, by clicking on 1 of 4 possible answers to each question. The first player to click on one of the 4 possible answer buttons will either get it correct or incorrect. Each question will have a point value assigned by the difficulty level of the question. The player who clicked second (or not at all) will not be able to answer the question, but will be able to instantly see that the other player tried to answer the question and if they were successful or not. And so on...

    On the server side, the program will verify the user's name and password through MySQL. There will be multiple instances of the game running because n number of players could play n number of games. It will randomly generate a set of questions for each game. It will notify both players if the question was answered correctly or not, showing both users the correct answer. It will have to govern the game by knowing that if the first player is answering a question, the second player can't be allowed to answer. After each question, each client will be able to see in real time what their score is vs the other player's score, and then the next question begins. It will write the final score to the MySQL database and send information to each client, saying who won and lost, and what their scores were.

    My Questions:

    1. Would the client app and server app both have to be developed in the same programming language? For example, could the client side be developed in C#, and the server side be developed in Netbeans C++?
    2. What language would be best for developing the client and the server app? (Sockets are involved, if that matters in selecting a language)
    3. If the server app is created in a .net language (i.e., C# or VB.net), could it reside on a Linux server?
    Thank you!
    Thursday, May 5, 2011 5:09 PM

Answers

  • 1)

    No.  Connect whatever you like to whatever you like via http or sockets.

    2)

    Whichever language you're best at.  Personally I think you'd be mad to choose C++ over C# because it's way harder to work in, but some people prefer low level languages. Why would you choose sockets over http?

    3)

    Linux is not a great choice if you want to work in something which is designed for windows.  There's mono but I reckon you'd do better sticking to php and a soap service.

     

    Personally I'm a microsoft orientated developer ( surprise ).

    So I'd write this application in silverlight for the client and use wcf ria to connect to the database. No Linux. 

    • Marked as answer by Code71 Saturday, May 7, 2011 11:31 PM
    Saturday, May 7, 2011 3:32 PM

All replies

  • Is this the wrong forum for this type of question? Thanks!
    Friday, May 6, 2011 6:39 PM
  • 1)

    No.  Connect whatever you like to whatever you like via http or sockets.

    2)

    Whichever language you're best at.  Personally I think you'd be mad to choose C++ over C# because it's way harder to work in, but some people prefer low level languages. Why would you choose sockets over http?

    3)

    Linux is not a great choice if you want to work in something which is designed for windows.  There's mono but I reckon you'd do better sticking to php and a soap service.

     

    Personally I'm a microsoft orientated developer ( surprise ).

    So I'd write this application in silverlight for the client and use wcf ria to connect to the database. No Linux. 

    • Marked as answer by Code71 Saturday, May 7, 2011 11:31 PM
    Saturday, May 7, 2011 3:32 PM
  • Thanks Andy...I appreciate your insight and advice!
    Saturday, May 7, 2011 11:32 PM
  • Happy to help mate.

    Note that there's currently some doubt as to whether mono will continue to be developed or indeed supported now Novell have been taken over.

     

    Monday, May 9, 2011 8:34 AM
  • Ok, I'll go with C# for the client and the server apps.

    As for the Sockets vs SOAP...I'm not sure which one to choose. Here's what I do know:

    • The transmission from client to server, and from server to client, needs to be encrypted
    • The client app will not be a web page; it will be a GUI made from C#
    • Speed is important. Going back to the Jeopardy! example, players would have to know in real time whether or not they clicked the answer first, and so on...
    • The server app needs to be highly scalable. There could be many players (some single player, some 2-player), all connecting to the server app.

    Any recommendations?

     

    Monday, May 9, 2011 11:44 PM
  • WCF RIA.

    Seriously.

    Silverlight and WCF RIA are a good match for this sort of thing.

    http://channel9.msdn.com/events/MIX/MIX10/CL09

     

    Or some sort of http based transport unless all your users will be on the same network as the server.

    Hence if your answer must be sockets or SOAP then SOAP.

    Scale by using a web farm of multiple servers.

    Until you start getting HUGE numbers of users but you can hire a technical architect of your own  then.

     

    Silverlight will make your app look cooler and responsive whilst probably reducing the load on the web server.

    You could hae got both the questions and answers at once onto the client but (obviously) not as secure that way.

    Tuesday, May 10, 2011 9:46 AM
  • Much thanks!
    Wednesday, May 11, 2011 12:54 AM