# HG changeset patch # User Simon Cross # Date 1328969872 -7200 # Node ID 356795038b875d9387a96d4383ad5fe9858a285c # Parent ccc26c23d2c17f4c1c74bf693d05bd27a10c2158 Remove a couple of uses os DEBUG. diff -r ccc26c23d2c1 -r 356795038b87 gamelib/scenes/bridge.py --- a/gamelib/scenes/bridge.py Sat Feb 11 16:04:45 2012 +0200 +++ b/gamelib/scenes/bridge.py Sat Feb 11 16:17:52 2012 +0200 @@ -13,10 +13,6 @@ InteractImage, InteractAnimated, GenericDescThing) -# XXX: Need a way to get at the constants. -from pyntnclick.constants import GameConstants -DEBUG = GameConstants().debug - from gamelib.scenes.game_constants import PLAYER_ID from gamelib.scenes.game_widgets import Door, BaseCamera, make_jim_dialog @@ -454,8 +450,8 @@ def __init__(self, number, rect, ai_blocked): super(DestNavPageLine, self).__init__() self.name = 'bridge_comp.nav_line%s' % number - if DEBUG: - self._interact_hilight_color = Color(THECOLORS.keys()[number]) + # set debugging higlight color for when DEBUG is on. + self._interact_hilight_color = Color(THECOLORS.keys()[number]) r = Rect(rect) self.interacts = {} self.interacts['line'] = InteractNoImage(r.x, r.y, r.w, r.h) diff -r ccc26c23d2c1 -r 356795038b87 pyntnclick/scenewidgets.py --- a/pyntnclick/scenewidgets.py Sat Feb 11 16:04:45 2012 +0200 +++ b/pyntnclick/scenewidgets.py Sat Feb 11 16:17:52 2012 +0200 @@ -10,10 +10,6 @@ from pyntnclick.state import Thing from pyntnclick.widgets import BoomLabel -# XXX: Need a way to get at the constants. -from pyntnclick.constants import GameConstants -DEBUG = GameConstants().debug - class Interact(object): @@ -141,9 +137,8 @@ self.interacts = { 'description': InteractRectUnion(areas) } - if DEBUG: - # Individual colors to make debugging easier - self._interact_hilight_color = Color(THECOLORS.keys()[number]) + # Individual colors to make debugging easier + self._interact_hilight_color = Color(THECOLORS.keys()[number]) def get_description(self): return self.description