[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [pbmserv-dev] New guy
On Fri, 24 Jun 2005, Michael Hammond wrote:
> I'm looking at building a PBMServ module, and I'd like any
> suggestions on where to get started. I've looked at some of the code
> files - board2d, game.cpp, etc. and I'm just overwhelmed. Is there a
> good starting point to make sense of all of this stuff?
Don't look at that stuff. Just look at a game such as gomoku as an
example of what to do.
You inherit from board2d, and override a few functions:
GameType : name your game
Init : setup your initial board
PrintBoard or PrintBoardAs : show the board
MakeMove : make a move on the board
IsGameOver : well, is it?
There are a few others you can override to do more advanced things, but
those are where you start.
~ John Williams