From 34ca8d684f3515232508f4a581828f5f069c323f Mon Sep 17 00:00:00 2001 From: Arun Persaud Date: Mon, 29 Oct 2007 20:29:42 +0100 Subject: [PATCH] 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. --- index.php | 6 +++--- 1 file 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" ) -- 2.25.1