Package: gnome-hearts
Version: 0.1.3-3
Tags: patch
Severity: wishlist

When playing under the Omnibus or Omnibus alternative ruleset, taking
all the cards results in a score of -16, rather than the expected -36.

I made a patch that corrects this problem, located at hearts.c.
The bug was originally reported in Ubuntu
diff -Nur gnome-hearts-0.1.3/src/hearts.c gnome-hearts-0.1.3.new/src/hearts.c
--- gnome-hearts-0.1.3/src/hearts.c	2007-05-23 08:45:12.000000000 +0200
+++ gnome-hearts-0.1.3.new/src/hearts.c	2007-05-23 08:45:12.000000000 +0200
@@ -260,9 +260,11 @@
 		for (i = 0; i < 4; i++)
 		{
 			/* update the scores */
-			if (player[i]->point_cards == 14) /* shot the moon? */
+			if (player[i]->point_cards == 14 && player[i]->score_round == 26) /* shot the moon? */
 				player[i]->score_total -= player[i]->score_round;
-			else
+			else if (player[i]->point_cards == 14 && player[i]->score_round == 16) /* shot the moon with bonus? */
+				player[i]->score_total -= 36;
+			else				
 				player[i]->score_total += player[i]->score_round;
 
 			player[i]->score_round = 0;

Reply via email to