From 776f3462c2244634ccddc22a5473916d6439872c Mon Sep 17 00:00:00 2001 From: Gregory Brown Date: Sat, 21 Apr 2012 07:23:47 -0400 Subject: [PATCH] Fix another missed spot in the UI --- lib/blind/ui/game_presenter.rb | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/blind/ui/game_presenter.rb b/lib/blind/ui/game_presenter.rb index 0629637..0ef40d4 100644 --- a/lib/blind/ui/game_presenter.rb +++ b/lib/blind/ui/game_presenter.rb @@ -23,11 +23,12 @@ def move(x,y) def detect_danger_zone if in_danger_zone - min = Blind::World::DANGER_ZONE_RANGE.min - max = Blind::World::DANGER_ZONE_RANGE.max + # FIXME: Remove these hard-coded values + min = 100 + max = 120 sounds[:siren].volume = - ((world.distance(world.center_position) - min) / max.to_f) * 100 + ((world.distance(world.center_point) - min) / max.to_f) * 100 else sounds[:siren].volume = 0 end