diff gamelib/buildings.py @ 423:97dd557504a2

Override make methods for simplifiable objects.
author Simon Cross <hodgestar@gmail.com>
date Sat, 21 Nov 2009 15:39:49 +0000
parents 8f012ef1f64f
children a356e57529ea
line wrap: on
line diff
--- a/gamelib/buildings.py	Sat Nov 21 15:35:23 2009 +0000
+++ b/gamelib/buildings.py	Sat Nov 21 15:39:49 2009 +0000
@@ -118,6 +118,11 @@
         # Create the building somewhere far off screen
         Sprite.__init__(self, self.images['fixed']['day'], (-1000, -1000))
 
+    def make(cls):
+        """Override default Simplifiable object creation."""
+        return cls((0, 0))
+    make = classmethod(make)
+
     def _set_images(self):
         self.images = {'fixed': {
             'day': imagecache.load_image(self.IMAGE),