From 171a18b9465c9e299d552fdedec31882a257e1c2 Mon Sep 17 00:00:00 2001 From: Jake Howard Date: Wed, 6 May 2015 09:50:48 +0100 Subject: [PATCH] added style and error checking --- GUI.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/GUI.py b/GUI.py index 47336e6..b51bc1f 100644 --- a/GUI.py +++ b/GUI.py @@ -27,7 +27,7 @@ class Main_Window: self.exit_button.bind('', self.close) - Style().configure("Menu.TButton", font=("Lucida", 25 )) + Style().configure("Menu.TButton", font=("Lucida", 25)) Style().configure("Quit.TButton", font=("Lucida", 15)) logging.info("GUI Generated.") @@ -35,7 +35,9 @@ class Main_Window: def play_game(self, event): logging.info("Game Started.") self.master.withdraw() - game.initialise(self.master, None) + exit_code = game.initialise(self.master, None) + if exit_code == "player collision": + self.title["text"] = "You Lost, Try Again?" def close(self, event): logging.critical("Closing Main Window.")