Hackish serum placement offset.
authorSimon Cross <hodgestar@gmail.com>
Fri, 4 Mar 2016 22:49:21 +0000 (00:49 +0200)
committerSimon Cross <hodgestar@gmail.com>
Fri, 4 Mar 2016 22:49:21 +0000 (00:49 +0200)
koperkapel/scenes/roach_management.py

index f960a5e18eccbf8d6a4d9f340ab614248459fb3a..e206e102d8a9d7563b174be0e513451aa76463c2 100644 (file)
@@ -16,6 +16,7 @@ TOOLBAR_MID_Y = HEIGHT * 1 // 2
 VEHICLE_MID_X = WIDTH * 3 // 8
 VEHICLE_MID_Y = HEIGHT * 1 // 2
 BUTTON_INSET = (20, 20)
+SERUM_OFFSET = (0, 20)
 
 
 def inset_button(pos, d):
@@ -71,7 +72,10 @@ class RoachesScene(Scene):
         self._inventory_pos %= len(serums)
         serum_actor = self._serums.add(
             big_serums.assemble(serums[self._inventory_pos]))
-        serum_actor.pos = self._inventory_pad.center
+        inv_pad_centre = self._inventory_pad.center
+        serum_actor.pos = (
+            inv_pad_centre[0] + SERUM_OFFSET[0],
+            inv_pad_centre[1] + SERUM_OFFSET[1])
 
     def _init_pads(self):
         self._roach_pad = self._pads.add(