[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-bugs-dist
Subject:    [Bug 131587] "cannot win this game" message just after start of mod3
From:       Inge Wallin <inge () lysator ! liu ! se>
Date:       2006-09-07 20:58:47
Message-ID: 20060907205847.24410.qmail () ktown ! kde ! org
[Download RAW message or body]

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
         
http://bugs.kde.org/show_bug.cgi?id=131587         
inge lysator liu se changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED



------- Additional Comments From inge lysator liu se  2006-09-07 22:58 -------
SVN commit 581887 by ingwa:

Fix bug 131587: "cannot win this game" message just after start of mod3 game

 - Check for aces in the store and not only for empty places.

BUGS: 131587



 M  +6 -0      CHANGES  
 M  +3 -2      mod3.cpp  


--- branches/KDE/3.5/kdegames/kpat/CHANGES #581886:581887
 @ -1,5 +1,11  @
 2005-06-25 Inge Wallin <inge lysator liu se>
 
+        Fix bug 131587: "cannot win this game" message just after
+                         start of mod3 game
+        - Check for ace at the store in addition to empty
+
+2005-06-25 Inge Wallin <inge lysator liu se>
+
         Code cleaning
         - Rename Card::Value  --> Card::Rank
         - Rename Card::Suites --> Card::Suit
--- branches/KDE/3.5/kdegames/kpat/mod3.cpp #581886:581887
 @ -187,9 +187,10  @
 
     bool nextTest=false;
 
-    // If there is an empty stack below, the game is not lost.
+    // If there is an empty stack or an ace below, the game is not lost.
     for (col=0; col < 8; col++){
-        if (stack[3][col]->isEmpty())
+        if (stack[3][col]->isEmpty()
+	    || stack[3][col]->at(0)->rank() == Card::Ace)
             return false;
     }
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic