[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [pbmserv-dev] New guy
game.cpp is where most of the logic is.
If you are just starting into that code, I would suggest reading with a
good debugger.
~ John Williams
On Mon, 27 Jun 2005, Michael Hammond wrote:
> Read what code? Game.cpp?
>
> Mike
>
> -----Original Message-----
> From: owner-pbmserv-dev@gamerz.net [mailto:owner-pbmserv-dev@gamerz.net] On
> Behalf Of John Williams
> Sent: Monday, June 27, 2005 4:00 PM
> To: pbmserv-dev@gamerz.net
> Subject: RE: [pbmserv-dev] New guy
>
> It's all part of the magic.
>
> Well, actually there is a bunch of usernames, passwords, and various filey
> bits involved, but you will have to read the code if you want to make sure
> it is doing the right thing.
>
> ~ John Williams
>
>
> On Mon, 27 Jun 2005, Michael Hammond wrote:
>
> > How does the server tell if the sender is the person whose turn it is?
> >
> > Mike
> >
> > -----Original Message-----
> > From: owner-pbmserv-dev@gamerz.net [mailto:owner-pbmserv-dev@gamerz.net]
> On
> > Behalf Of John Williams
> > Sent: Monday, June 27, 2005 2:13 PM
> > To: pbmserv-dev@gamerz.net
> > Subject: RE: [pbmserv-dev] New guy
> >
> > On Mon, 27 Jun 2005, Michael Hammond wrote:
> >
> > > I see apps referring to an array called 'moves', but I can't figure out
> > > where that's coming from. Where is that declared?
> >
> > In one of the classes you inherit from. You can look at old moves or find
> > out what move it currently is (moves.Count()). But most games shouldn't
> > care.
> >
> > > Can anybody walk me through a typical move processing sequence? I'm
> > trying
> > > to wrap my brain around what happens in what order. First, the e-mail
> > shows
> > > up in the PBMServ inbox. Last, the PBMServ sends the response to the
> > > sender. What happens in the middle?
> >
> > Well, first there is some sendmail and perl magic which happens, but let's
> > skip all that. Eventually a command like the following is run:
> >
> > gomoku move 101 hal ibm g8
> >
> > When you successfully compile gomoku.* you should get an executable called
> > "gomoku", which you can use for testing from the command line. (Actually
> > you might need to tweak sendmail.cpp if it is still hardcoded to use
> > /usr/sbin/sendmail: replace "/usr/sbin/sendmail" with "/bin/cat" and the
> > board will be send to STDOUT.)
> >
> > So, anyway, you run the gomoku executable with the same arguments you
> > would have put on the subject line, and the flow is vaguely like this:
> >
> > magic happens...
> > Gomoku::MakeMove("g8") is called.
> > it uses GetAt() and PutAt() to alter the board.
> > Gomoku::IsGameOver is called.
> > ...more magic happens...
> > Gomoku::PrintBoard is called for each player.
> >
> > ~ John Williams
> >
> >
> >
> > To unsubscribe, send a message to esquire@gamerz.net with
> > unsubscribe pbmserv-dev@gamerz.net
> > as the BODY of the message. The SUBJECT is ignored.
> >
> >
> > To unsubscribe, send a message to esquire@gamerz.net with
> > unsubscribe pbmserv-dev@gamerz.net
> > as the BODY of the message. The SUBJECT is ignored.
> >
>
>
> To unsubscribe, send a message to esquire@gamerz.net with
> unsubscribe pbmserv-dev@gamerz.net
> as the BODY of the message. The SUBJECT is ignored.
>
>
>
> To unsubscribe, send a message to esquire@gamerz.net with
> unsubscribe pbmserv-dev@gamerz.net
> as the BODY of the message. The SUBJECT is ignored.
>