# HG changeset patch # User Neil Muller # Date 1336850923 -7200 # Node ID 19aae2b701d146e6c90dee36affad2ad6b2793ec # Parent 69941f04f1c048565a4c7fb377abcb1cf8b18059 More layout tweaking diff -r 69941f04f1c0 -r 19aae2b701d1 data/images/equip_grey.png Binary file data/images/equip_grey.png has changed diff -r 69941f04f1c0 -r 19aae2b701d1 data/images/mission_selected.png Binary file data/images/mission_selected.png has changed diff -r 69941f04f1c0 -r 19aae2b701d1 data/images/science_down.png Binary file data/images/science_down.png has changed diff -r 69941f04f1c0 -r 19aae2b701d1 data/images/science_normal.png Binary file data/images/science_normal.png has changed diff -r 69941f04f1c0 -r 19aae2b701d1 gamelib/gamegui.py --- a/gamelib/gamegui.py Sat May 12 21:07:51 2012 +0200 +++ b/gamelib/gamegui.py Sat May 12 21:28:43 2012 +0200 @@ -167,6 +167,7 @@ class MissionWidget(BigButton): WIDTH = 260 + HEIGHT = 48 BG_IMAGE_NORMAL = image.load(filepath('images/science_normal.png')) BG_IMAGE_DOWN = image.load(filepath('images/science_down.png')) @@ -235,6 +236,7 @@ class EquipWidget(BigButton): WIDTH = 260 + HEIGHT = 48 BG_IMAGE_NORMAL = image.load(filepath('images/science_normal.png')) BG_IMAGE_DOWN = image.load(filepath('images/science_down.png')) @@ -289,23 +291,23 @@ self.add_child(cancel) reset = ResetButton(self, 'Clear inventory') self.add_child(reset) - title = TextBox((170, 20, 370, 50), "Choose equipment for %s" + title = TextBox((170, 10, 370, 50), "Choose equipment for %s" % mission.NAME, font_medium, (255, 255, 255)) self.add_child(title) - self.description = TextBox((10, 70, 790, 20), + self.description = TextBox((10, 60, 790, 20), mission.get_description(), font_medium, (255, 255, 255)) self.add_child(self.description) self.parent = parent self.game = game - self.money = ValueLabel((10, self.description.rect.height + 75), + self.money = ValueLabel((10, self.description.rect.height + 57), 'Money') self.money.set_value(self.game.money) - self.minions = ValueLabel((310, self.description.rect.height + 75), + self.minions = ValueLabel((310, self.description.rect.height + 57), 'Minions Assigned') self.minions.set_value(self.parent.minions) self.add_child(self.money) self.add_child(self.minions) - inventory = TextLabel((10, self.description.rect.height + 90, 400, 20), + inventory = TextLabel((10, self.description.rect.height + 75, 400, 20), 'Current Inventory', font_medium, (255, 255, 255)) self.add_child(inventory) self._equip = [] @@ -348,7 +350,7 @@ self._equip = [] x = 0 y = max(250, 130 + self.description.rect.height + - 20 * len(self._inventory) // 3) + 18 * len(self._inventory) // 3) available = self.game.get_available_equipment() for equip in sorted(self.game.get_all_equipment(), key=lambda x: x.NAME): @@ -360,7 +362,7 @@ x += widget.WIDTH + 10 if x >= WIDTH: x = 0 - y += 65 + y += 45 def buy(self, equip): self.game.money -= equip.COST