X-Git-Url: https://git.nubati.net/cgi-bin/gitweb.cgi?p=e-DoKo.git;a=blobdiff_plain;f=include%2Fgame.php;h=02d6f9658c222e43e4e7de1c769382632d75b2cb;hp=eb66a987157c6bcd98ddbcf57f0ce343e7e7fcca;hb=9597b99442a783621315839880966d68a2fd460f;hpb=8550cac6f9bedbd9219d898f7b3de731bf1cb2b2 diff --git a/include/game.php b/include/game.php index eb66a98..02d6f96 100644 --- a/include/game.php +++ b/include/game.php @@ -43,7 +43,9 @@ if(!$myid) global $GAME,$RULES,$CARDS; -/* get some information from the DB */ +/************************************** + * get some information from the DB + **************************************/ $gameid = DB_get_gameid_by_hash($me); $myname = DB_get_name('hash',$me); $mystatus = DB_get_status_by_hash($me); @@ -79,6 +81,9 @@ if( $gamestatus == 'pre' ) { /* always need to use Schweinchen to figure out for example who has poverty */ $ok=1; + /* unless the gametype is set and we know that we are in poverty were schweinchen is not valid */ + if( in_array( $gametype,array('poverty','dpoverty') )) + $ok=0; } else { @@ -114,11 +119,8 @@ if($ok) */ set_gametype('normal'); -/* put everyting in a form */ -echo "
\n"; +/********************************* + * suggest next game + *********************************/ + $gamestatus = DB_get_game_status_by_gameid($gameid); if($mystatus=='gameover' && ($gamestatus =='gameover' || $gamestatus =='cancel-nines' || $gamestatus =='cancel-trump') &&