diff gamelib/buildings.py @ 505:3ed6c011106d

Switch to classmethod decorators.
author Simon Cross <hodgestar@gmail.com>
date Thu, 26 Nov 2009 22:34:58 +0000
parents b74b3a37cf1d
children 50d6c68ce267
line wrap: on
line diff
--- a/gamelib/buildings.py	Thu Nov 26 22:28:22 2009 +0000
+++ b/gamelib/buildings.py	Thu Nov 26 22:34:58 2009 +0000
@@ -130,18 +130,18 @@
         # Create the building somewhere far off screen
         Sprite.__init__(self, self.images['fixed']['day'], (-1000, -1000))
 
+    @classmethod
     def make(cls):
         """Override default Simplifiable object creation."""
         return cls((0, 0))
-    make = classmethod(make)
 
+    @classmethod
     def unsimplify(cls, *args, **kwargs):
         """Override default Simplifiable unsimplification."""
         obj = super(Building, cls).unsimplify(*args, **kwargs)
         obj._set_main_image()
         obj.update_occupant_count()
         return obj
-    unsimplify = classmethod(unsimplify)
 
     def _set_images(self):
         self.images = {'fixed': {