More tile juggling.
authorJeremy Thurgood <firxen@gmail.com>
Fri, 16 May 2014 12:35:09 +0000 (14:35 +0200)
committerJeremy Thurgood <firxen@gmail.com>
Fri, 16 May 2014 12:35:09 +0000 (14:35 +0200)
naja/actions.py
naja/constants.py
naja/widgets/tile.py

index d6c4532c68c6b5367faaf6a20a27c4d8c5bbaae4..cf916b9280126f879baf157444806432645702c2 100644 (file)
@@ -8,7 +8,7 @@ class LocationAction(object):
     """
 
     TEXT = None
-    GLYPHS = ()
+    GLYPHS = (ACTION_GLYPHS.NOTHING,)
     MSB_GLYPH = None
 
     def __init__(self, required_bits, **data):
@@ -61,7 +61,6 @@ class LocationAction(object):
 
 class DoNothing(LocationAction):
     TEXT = "No effect."
-    GLYPHS = (ACTION_GLYPHS.NOTHING,)
 
     def perform_action(self, board, location):
         pass
index dfc9e505fc55299402451f97162f103df1f7e1e6..ca1394b8bce2a8c2ae37edbb527bc40a634b086c 100644 (file)
@@ -61,7 +61,6 @@ PLAYER_DEFAULTS = AttrDict({
 
 # Game size constants
 TILE_SIZE = (96, 96)
-# LOCK_HEIGHT = 48
 LOCK_HEIGHT = 32
 BOARD_SIZE = (5 * TILE_SIZE[0], 5 * TILE_SIZE[1])
 BIT_SIZE = (5 * TILE_SIZE[0], (SCREEN[1] - 5 * TILE_SIZE[1]) // 2)
index be02a3555eeda9cae7ed6193740835a783354cc6..93078a586df3cc90adc1327e59bafd5dff5ac22b 100644 (file)
@@ -83,11 +83,6 @@ class TileWidget(Widget):
         else:
             img_name = img_name.replace('.png', '_small.png')
             x_offset = 4
-            if y_offset >= TILE_SIZE[1] // 2:
-                # FIXME: Hack'ish
-                # Bump the lock down by some hand-tuned factor
-                # to not overlap with the robot
-                y_offset += LOCK_HEIGHT // 2 - 4
         img = resources.get_image(img_name, transforms=(EIGHT_BIT,))
         self.surface.blit(img, (x_offset, y_offset))
         return x_offset + img.get_width() + 2