summaryrefslogtreecommitdiffstats
path: root/index.php
diff options
context:
space:
mode:
authorArun Persaud <arun@nubati.net>2007-10-29 20:29:42 +0100
committerArun Persaud <arun@nubati.net>2007-10-29 20:29:42 +0100
commit34ca8d684f3515232508f4a581828f5f069c323f (patch)
tree2240edfe6bfd6a643723c4dcd75d83a576c30787 /index.php
parentb85e99a9104db0cb831b198d4db0c00957d2ceba (diff)
downloade-DoKo-34ca8d684f3515232508f4a581828f5f069c323f.tar.gz
e-DoKo-34ca8d684f3515232508f4a581828f5f069c323f.tar.bz2
e-DoKo-34ca8d684f3515232508f4a581828f5f069c323f.zip
BUGFIX: when playing with both schweinchen
they second fox always became the highest trump, even if the two foxes where not on the same hand. Also: every fox led to a comment:"schweinchen". Both fixed now.
Diffstat (limited to 'index.php')
-rw-r--r--index.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/index.php b/index.php
index 538bc81..7d35814 100644
--- a/index.php
+++ b/index.php
@@ -1120,7 +1120,7 @@ else if(myisset("me"))
date_default_timezone_set($zone);
/* check if first schweinchen has been played */
- if($r[0] == 19 || $r[0] == 20 )
+ if( $GAME["schweinchen"] && ($r[0] == 19 || $r[0] == 20) )
$GAME["schweinchen"]++;
/* save card to be able to find the winner of the trick later */
@@ -1230,9 +1230,9 @@ else if(myisset("me"))
$playid = DB_play_card($trickid,$handcardid,$sequence);
/* check for schweinchen */
- if($card == 19 || $card == 20 )
+ if($GAME["schweinchen"] && ($card == 19 || $card == 20) )
{
- $GAME["schweinchen"]++;
+ $GAME["schweinchen"]++; // count how many have been played including this one
if($GAME["schweinchen"]==3 && $RULES["schweinchen"]=="second" )
DB_insert_comment("Schweinchen! ",$playid,$myid);
if($RULES["schweinchen"]=="both" )