Ignore:
Timestamp:
09/03/13 19:47:24 (8 years ago)
Author:
Stefano Rivera <stefano@…>
Branch:
default
Phase:
public
Message:

Overlay notes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • nagslang/level.py

    r168 r191  
    3030        self._exterior = False
    3131        self._glue = go.PuzzleGlue()
    32         self._drawables = []
     32        self.drawables = []
     33        self.overlay_drawables = []
    3334        self._game_objects = []
    3435        self._enemies = []
     
    7273        elif issubclass(cls, go.GameObject):
    7374            gobj = cls(space, *args)
    74             self._drawables.append(gobj)
     75            self.drawables.append(gobj)
     76            if gobj.overlay:
     77                self.overlay_drawables.append(gobj.overlay)
    7578        else:
    7679            raise TypeError(
     
    8487        if issubclass(cls, go.GameObject):
    8588            gobj = cls(space, *args)
    86             self._drawables.append(gobj)
     89            self.drawables.append(gobj)
    8790        else:
    8891            raise TypeError(
     
    130133    def get_walls(self):
    131134        return self.polygons.values()
    132 
    133     def get_drawables(self):
    134         return self._drawables
    135135
    136136    def _draw_walls(self):
Note: See TracChangeset for help on using the changeset viewer.