Sun Apr 17 15:47:43 EST 2005

Ok, had to get spawning working first... thats done.
Now:
    light.
    ai's.
    movement.

Given the contest theme, maybe ill work in lights. :) happily, a lot
of it is already there.


Ok, so objects can be light sources.
  Object light sources contain:
    light_strength={ (dx,dy):str, ... }



=========================================================================

Sun Apr 17 12:10:38 EST 2005

Movement. Ok. How are we going to do this?

Objects need to be given destinations and work out how to get there. Hmm.
If have a obj.move_path=[] which contains a list of adjacent squares
(including diagionals) on how to get somewhere.

So, when we obj.move_to( x,y ), the object asks the map for a path and
stores that in obj.move_path. The movement routines then take it
square by square from there.

Right, so we have a 'MOVE' event queued periodically (every
1/move_rate seconds) which updates the units pos based on the 

Object:
      .move_to(x,y)    # sets .move_path, queues a EVENT_MOVE
      .move_path=[]    # generated from above
      .move_dest=(dx,dy) # popped of the .move_path
      .move_rate= number of .1 move impulses per second? (queues events?)


=========================================================================

Sat'day design stuff
--------------------


Idea:
----
Aliens/spacehulk type game where player has to light an area for
things to 'shoot/fight'.

Top down view. 2d. tile based (well duh, given my learning of pygame).

things I need to code
---------------------
  * a game object
    - contains everything really

  * an 'thing factory' object
?   - loads in 'thing' images,configs etc
    - 'rotate'/flip images for more variation <flr><fud><r4>
      (by config file desc?)

  * a 'map' object
X   - loads map shape and key from file
X   - uses 'thing factory' to make tile array
    ? random generator?

  * Thing (PARENTCLASS)
    - properties
      + blocks_los ==> loss loss (as %?)
      + blocks_move ==> move cost (-ve = blocked)
      + needs_decorator_event
      + needs_event
x   - event_next=time
x   - event_list=( (time, type, args), ...)
x     + needs brains (cpu time)
      + add/del image_overlay
        * image_overlay: on_fire, blood_splat,
    - event_decorator_next= time
    - event_decorator_list= ( (time,type,args), )
      Not updated when not displayed ?
      + switch images

  * Thing_is_tile
x   tiles that make up the map?
x   map/perm: floor, wall, door,
    - images (link to 'thing factory'?
      + animation?
x   - light_sources=( val:obj )
x   - light
x   - list of things's that are on this square (decorations, everything?)

  * Thing_needs_brains (PARENTCLASS)
    - brain()
      function to control them

  * Thing_is_static(Thing_needs_brains)
    unmoving things?
    destroyable: furnature, spawn points, doors, turrets, marine buildings

  * Thing_is_active(Thing_needs_brains)
    (players, turrates, lights, aliens, etc)


TODO:
  * precalculated 'sight' circle with dependacy on various hexes.
  * precalc map line of site out to N squares.

Thingies.
===============
Game
+---> map
      +---> Tile
+---> ThingFactory

