[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdegames/kpat/patsolve
From: Stephan Kulow <coolo () kde ! org>
Date: 2008-06-28 14:34:12
Message-ID: 1214663652.794989.15776.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 825526 by coolo:
little massage to make the first 10 games winnable in 30MB
M +7 -5 gypsy.cpp
M +1 -1 gypsy.h
--- trunk/KDE/kdegames/kpat/patsolve/gypsy.cpp #825525:825526
@@ -9,6 +9,7 @@
#include <kdebug.h>
#include <sys/types.h>
#include <stdarg.h>
+#include <algorithm>
#include "../gypsy.h"
#include "../pile.h"
#include "../deck.h"
@@ -377,7 +378,7 @@
}
if ( o > -1 )
continue;
- mp->pri = params[1];
+ mp->pri = ( int )std::min( 127., params[1] + double( l ) * params[5] / 10 );
}
n++;
mp++;
@@ -437,10 +438,11 @@
char buffer[10];
params[0] = 3;
params[1] = 3;
- params[2] = 41;
- params[3] = 20;
- params[4] = 0;
- for ( int i = 1; i <= 5; i++ )
+ params[2] = 44;
+ params[3] = 19;
+ params[4] = 5;
+ params[5] = 10;
+ for ( int i = 1; i <= 6; i++ )
{
sprintf( buffer, "DECK%d", i );
char *env = getenv( buffer );
--- trunk/KDE/kdegames/kpat/patsolve/gypsy.h #825525:825526
@@ -28,7 +28,7 @@
const Gypsy *deal;
int deck, outs;
- int params[5];
+ int params[6];
};
#endif
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic