diff pytouhou/game/item.py @ 304:f3099ebf4f61

Update attribute names to reflect the actual interface.
author Thibaut Girka <thib@sitedethib.com>
date Tue, 13 Mar 2012 18:38:14 +0100
parents 3ac8b135592c
children 52d791bb7c32
line wrap: on
line diff
--- a/pytouhou/game/item.py
+++ b/pytouhou/game/item.py
@@ -21,8 +21,8 @@ from pytouhou.utils.interpolator import 
 class Item(object):
     def __init__(self, start_pos, _type, item_type, game, angle=pi/2, player=None, end_pos=None):
         self._game = game
-        self._sprite = item_type.sprite
-        self._removed = False
+        self.sprite = item_type.sprite
+        self.removed = False
         self._type = _type
         self._item_type = item_type
 
@@ -45,7 +45,7 @@ class Item(object):
                 self.speed_interpolator = Interpolator((-2.,), 0,
                                                        (0.,), 60)
 
-        self._sprite.angle = angle
+        self.sprite.angle = angle
 
 
     def autocollect(self, player):
@@ -115,7 +115,7 @@ class Item(object):
             #TODO: display the score.
             player_state.score += score
 
-        self._removed = True
+        self.removed = True
 
 
     def update(self):