From: Matteo Nastasi (mop) Date: Sun, 30 Sep 2007 09:08:43 +0000 (+0000) Subject: corretto bug della possibilita' di chiamare meno di 61 punti e ripristino del valore... X-Git-Tag: 3.0.0~238 X-Git-Url: http://mop.ddnsfree.com/gitweb/?a=commitdiff_plain;h=0767a34084719171ba57699344939474eec8d061;p=brisk.git corretto bug della possibilita' di chiamare meno di 61 punti e ripristino del valore dei punti corretto dopo che si inserisce un valore non ammesso --- diff --git a/web/index_wr.php b/web/index_wr.php index a7ab655..6c33baf 100644 --- a/web/index_wr.php +++ b/web/index_wr.php @@ -287,14 +287,11 @@ else if ($user->stat == 'table') { $again = FALSE; } else if ($a_card <= 9) { - if ($table->asta_card == 9) { - if ($a_card == 9 && $a_pnt <= 120 && $a_pnt > $table->asta_pnt) - $again = FALSE; - } - else { - if ($a_card >= 0 && $a_card <= 9 && $a_card > $table->asta_card) - $again = FALSE; - } + if ($a_card >= 0 && $a_card < 9 && $a_card > $table->asta_card) + $again = FALSE; + else if ($a_card == 9 && $a_pnt > ($table->asta_pnt >= 61 ? $table->asta_pnt : 60) && $a_pnt <= 120) + $again = FALSE; + if ($again == FALSE) { log_wr($sess, "NUOVI ORZI."); @@ -310,6 +307,11 @@ else if ($user->stat == 'table') { if ($again) { // Qualcosa non andato bene, rifare + $ret = sprintf('gst.st = %d; asta_pnt_set(%d);', $user->step+1, + ($table->asta_pnt > 60 ? $table->asta_pnt + 1 : 61) ); + $user->comm[$user->step % COMM_N] = $ret; + $user->step_inc(); + log_wr($sess, "Ripetere."); } else {