Programming Question: Multi-Player Poker Game

Discussion in 'ASP .Net' started by Paul, Jan 20, 2010.

  1. Paul

    Paul Guest

    I have a programming task and was wondering if anyone has some thoughts on
    the best way to achieve this.

    I am programming a mulit-user poker game using ASP.Net 3.5 and AJAX. I do
    not want to write a Java applet or any type of standalone program that would
    reside on the user's

    computer. I just want the user to use a browser as the user interface.

    I have 5 users at the table. Each user has their own browser session (i.e.
    they are located on different computers around the world).

    Player 1 is the first player to act. He bets $5.

    My question: How can the other users be notified on Player 1's action?

    Now, my initial reaction is to have a database table that keeps track of the
    hand's current "status" (i.e. who's turn it is to act). I could use an
    UpdatePanel control and a Timer control

    that queries the current status table every second or 2 and display a
    message in the UpdatePanel that would notify all the user's as to whose turn
    it is. I am pretty sure that I could get

    this to work.

    However, this does not seem very elegant nor scalable. Hitting the database
    every second or two for each of the five players doesn't seem very desirable.

    Is there any other technical solution that would be feasible?

    TIA for any assistance or advice you can give me.
     
    Paul, Jan 20, 2010
    #1
    1. Advertising

  2. Paul

    Scott M. Guest

    "Paul" <> wrote in message
    news:...
    >I have a programming task and was wondering if anyone has some thoughts on
    > the best way to achieve this.
    >
    > I am programming a mulit-user poker game using ASP.Net 3.5 and AJAX. I do
    > not want to write a Java applet or any type of standalone program that
    > would
    > reside on the user's
    >
    > computer. I just want the user to use a browser as the user interface.
    >
    > I have 5 users at the table. Each user has their own browser session (i.e.
    > they are located on different computers around the world).
    >
    > Player 1 is the first player to act. He bets $5.
    >
    > My question: How can the other users be notified on Player 1's action?
    >


    Stop right there. You will not be able to accomplish your project without
    some sort of client application installed. The very nature of HTTP (even
    with AJAX) will not allow for messages to be broadcast to other users
    instantaneously.

    > Now, my initial reaction is to have a database table that keeps track of
    > the
    > hand's current "status" (i.e. who's turn it is to act). I could use an
    > UpdatePanel control and a Timer control
    >
    > that queries the current status table every second or 2 and display a
    > message in the UpdatePanel that would notify all the user's as to whose
    > turn
    > it is. I am pretty sure that I could get
    >
    > this to work.
    >
    > However, this does not seem very elegant nor scalable. Hitting the
    > database
    > every second or two for each of the five players doesn't seem very
    > desirable.
    >
    > Is there any other technical solution that would be feasible?


    Why not just do what all online games of this nature do and have a
    client-based game that communicates over the web?

    >
    > TIA for any assistance or advice you can give me.
     
    Scott M., Jan 20, 2010
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Andy

    open source poker code

    Andy, Nov 3, 2005, in forum: Java
    Replies:
    0
    Views:
    5,944
  2. Alias

    Poker Program

    Alias, Apr 3, 2005, in forum: C++
    Replies:
    4
    Views:
    4,600
    Alias
    Apr 9, 2005
  3. Max Kubierschky
    Replies:
    10
    Views:
    1,902
    pabloreda
    Mar 31, 2007
  4. Poker Algorithm.

    , Oct 19, 2008, in forum: C++
    Replies:
    2
    Views:
    2,465
    asm23
    Oct 19, 2008
  5. pt
    Replies:
    5
    Views:
    434
    Anno Siegel
    Feb 9, 2006
Loading...

Share This Page