[Divunal-devel] Changes to twisted.reality.NCU,V,P

Glyph Lefkowitz glyph@divunal.com
Sat, 19 Jun 1999 12:00:54 -0400 (EDT)


Some of you were wondering in the past how to "make the game do verbs".
Well, now you can call d.subject().execute("go north"); and the player
will go north (or get up from the chair that they're in, or whatever...)

James, Mike: this function is declared void, it is not intended to return
success or failure, since those terms are all but meaningless in the
context of TR -- if you are going to be writing any AI code, please write
a new class (twisted.reality.AI extends Player for example) and add hooks
so that people can load modules to interpret calls to hears(), discover
information about their current focus, etc...

This is the way real people process input and output from the game, so I
think that it's the correct way to architecture it.  If you really need
some set of verbs to indicate success or failure, you'd probably have to
set some property on the Player itself (d.subject()) so the code can look
at it later.

  "Reality ... is just software.   |  Glyph Lefkowitz
   The hacker is our savior."      |  Code Gardener
   -- The New York Times           |  Twisted Matrix Enterprises