From d9341fd1b98b39b641f1ab0d216cbc0daedcc67f Mon Sep 17 00:00:00 2001 From: s_alexander Date: Mon, 29 Jun 2009 01:43:51 +0000 Subject: fixed bug #88 fixed bug, that under some circumstances you got line bonus even with no input https://www.assembla.com/spaces/usdx/tickets/88-get-sometimes-10-points-linebonus-even-with-no-input git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@1839 b956fd51-792f-4845-bead-9b4dfca2ff2c --- src/screens/UScreenSing.pas | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/screens/UScreenSing.pas') diff --git a/src/screens/UScreenSing.pas b/src/screens/UScreenSing.pas index ae75c74d..9dd25cd1 100644 --- a/src/screens/UScreenSing.pas +++ b/src/screens/UScreenSing.pas @@ -899,9 +899,9 @@ begin LineScore := CurrentScore - CurrentPlayer.ScoreLast; // determine LinePerfection - // Note: the "+2" extra points are a little bonus so the player does not + // Note: the "-2" extra points are a little bonus so the player does not // have to be that perfect to reach the bonus steps. - LinePerfection := (LineScore + 2) / MaxLineScore; + LinePerfection := LineScore / (MaxLineScore - 2); // clamp LinePerfection to range [0..1] if (LinePerfection < 0) then -- cgit v1.2.3