[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[pbmserv-dev] about matches for games



This is directed at Richard but others might like to respond.
Hello, I was riding the bus the other day and realized how simple
it could be to rewrite a game like backgammon in order to allow
match play.  Basically, what one could do is just allow a parameter
in the challenge line that would signal how many games are in the
match.  Then at the end of one game, just start another with the
same board number.  The game file would hold the number of games
that have been won by each player and when a player wins the match
the "game" is over and a winner is declared.  You see, when one game
is won, the program would *not* return a positive return value for
the IsGameOver() routine but instead would do something like this:
it would erase all the previous moves[] array and set a match[] array
in the game file and would basically start the game over with the one
exception that match[] now is updated.  The program would continue to
do this until the match is won.  
CONS: the players would not get credit for individual games within 
a match.  the previous games would disappear from record.  this method
would require additional programming for each game program. 
one game would need to be finished before the next game could start.
I am not sure how an "undo" would handle this.
PROS: we could play matches! :-)

Richard, is this something I should consider trying for bg or do you
want a more general method for all games that the individual programmers
would not have to worry about.  (Do all games fit for match play?)
I have thought about it, and I do not want to try to change the base
source modules, its too daunting a task. :-)   I'll leave that up to
you and other more experienced programmers.  :-)

--
 Douglas Zander            | 
 dzander@solaria.sol.net   | 
 Milwaukee, Wisconsin, USA |