Multiplayer Poker
-
hi, i am working on multiplayer online poker. since this is the first time i am doing this kind of thing, i am not sure that i have a good approach. can u tell me your opinion and way this is usually done? i have a asp.net web service on server wich holds information, data and state of games. on client i have Silverlight poker wich is connecting on server every 2 seconds to get current situation via "GameSituation" object. i am afraid of those "2 seconds". if there will be 20 000 players online, is this 2 seconds from each player too much to handle? is this right approach in programming multiplayer games or it can be done like: server waits for client, client contact server, server send info ("GameSituation" object in my case) to all clients in game? is client "hearth loop" good or evil?
-
hi, i am working on multiplayer online poker. since this is the first time i am doing this kind of thing, i am not sure that i have a good approach. can u tell me your opinion and way this is usually done? i have a asp.net web service on server wich holds information, data and state of games. on client i have Silverlight poker wich is connecting on server every 2 seconds to get current situation via "GameSituation" object. i am afraid of those "2 seconds". if there will be 20 000 players online, is this 2 seconds from each player too much to handle? is this right approach in programming multiplayer games or it can be done like: server waits for client, client contact server, server send info ("GameSituation" object in my case) to all clients in game? is client "hearth loop" good or evil?
Polling is sometimes necessary. However, here are a few ideas to help you avoid it or minimize its impact:
- Create a duplex service so client 1 sends info to the server and the server sends that info to client 2. I'm not sure if a duplex service uses polling under the hood, but if it doesn't then this could be what you're looking for.
- Find a way to have client 1 talk directly to client 2 without using the server as an intermediary. You'll definitely need the server to hook them up, but once they are in communication they can in theory keep communicating without a server intermediary. I am not sure if Silverlight prevents client to client communication (this will require some research on your part).
- Rather than poll with a constant time gap, decide on a minimum (say, 1 second) and a maximum (say, 10 seconds). The server will keep track of how many connections their are and inform the clients how often they can poll. As more clients are added, the server will increase the time gap between polling.
- Add more servers. Assuming you will be charging money for this, as it becomes more popular you should be able to afford more servers.
- Host it on the cloud. Rather than use your own servers, let Amazon or some other company that manages servers for you do all the work. Pay for more cloud space/time as your clients increase.
Somebody in an online forum wrote:
INTJs never really joke. They make a point. The joke is just a gift wrapper.
-
hi, i am working on multiplayer online poker. since this is the first time i am doing this kind of thing, i am not sure that i have a good approach. can u tell me your opinion and way this is usually done? i have a asp.net web service on server wich holds information, data and state of games. on client i have Silverlight poker wich is connecting on server every 2 seconds to get current situation via "GameSituation" object. i am afraid of those "2 seconds". if there will be 20 000 players online, is this 2 seconds from each player too much to handle? is this right approach in programming multiplayer games or it can be done like: server waits for client, client contact server, server send info ("GameSituation" object in my case) to all clients in game? is client "hearth loop" good or evil?
I would suggest examining this article, [^] I used this style when creating a Battleship style online game.