Re: OO and game design questions
- From: Martin Gregorie <martin@xxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 20 Oct 2010 01:07:11 +0000 (UTC)
On Tue, 19 Oct 2010 19:49:20 -0400, Dave Angel wrote:
Thanks, that is what I was trying to say. In the same sense thatI think a 'place' (to generalise it) is quite a small object in any case.
emptying a list makes it quite small, if it's a general purpose object,
you just want to remove all the attributes.
All it needs to contain is a few lists:
- a list of exits, which in some implementations might be simply
references to other places, but might usefully be objects with
two sides, each having an appearance and a link to the place
where that side appears.
- a list of fixed objects which only serve to describe the place.
- a list of mobile objects that actors can pick up and move
- a list of actors who happen to be there.
plus a describePlace() method and add(), remove() and getItem() methods
for each list. It may be possible to use a single list for all types of
object, in which case the object itself would be very small indeed.
--
martin@ | Martin Gregorie
gregorie. | Essex, UK
org |
.
- References:
- OO and game design questions
- From: dex
- Re: OO and game design questions
- From: Carl Banks
- Re: OO and game design questions
- From: dex
- Re: OO and game design questions
- From: Carl Banks
- Re: OO and game design questions
- From: dex
- Re: OO and game design questions
- From: Dave Angel
- OO and game design questions
- Prev by Date: Re: get python bit version as in (32 or 64)
- Next by Date: Code smells: too many parameters, too many attributes (was: pylint -- should I just ignore it sometimes?)
- Previous by thread: Re: OO and game design questions
- Next by thread: Re: OO and game design questions
- Index(es):
Relevant Pages
|