add multi-rules management
[brisk.git] / web / briskin5 / Obj / rules_no_draw.phh
1 <?php
2 /*
3  *  brisk - rules_no_draw.phh
4  *
5  *  Copyright (C) 2017 Matteo Nastasi
6  *                          mailto: nastasi@alternativeoutput.it
7  *                                  matteo.nastasi@milug.org
8  *                          web: http://www.alternativeoutput.it
9  *
10  * This program is free software; you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation; either version 2 of the License, or
13  * (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful, but
16  * WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABLILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18  * General Public License for more details. You should have received a
19  * copy of the GNU General Public License along with this program; if
20  * not, write to the Free Software Foundation, Inc, 59 Temple Place -
21  * Suite 330, Boston, MA 02111-1307, USA.
22  *
23  */
24
25 require_once("briskin5.phh");
26 require_once("rules_base.phh");
27
28 class Rules_no_draw extends Rules_old_rules {
29     function __construct($table)
30     {
31         parent::__construct($table);
32     }
33
34     static function game_result($asta_pnt, $pnt)
35     {
36         if ($pnt >= $asta_pnt)
37             return (1);
38         else
39             return (-1);
40     }
41
42 } // class Rules_no_draw
43
44 ?>