Mercurial > rinkhals
diff gamelib/animal.py @ 201:fe1e9c18d4d7
layering bugfix; indoor chickens now use normal chicken icons
author | Adrianna Pińska <adrianna.pinska@gmail.com> |
---|---|
date | Fri, 04 Sep 2009 20:16:51 +0000 |
parents | 67d10f7e0159 |
children | 962934b8c7dc |
line wrap: on
line diff
--- a/gamelib/animal.py Fri Sep 04 19:51:19 2009 +0000 +++ b/gamelib/animal.py Fri Sep 04 20:16:51 2009 +0000 @@ -94,9 +94,10 @@ layers.sort(key=lambda l: l[2]) - self.image_left = layers[0][0] - self.image_right = layers[0][1] - for l in layers[1:]: + # these always go on the bottom so that other layers don't get overwritten + self.image_left = self._image_left.copy() + self.image_right = self._image_right.copy() + for l in layers: self.image_left.blit(l[0], (0,0)) self.image_right.blit(l[1], (0,0))