seed r27 - trunk/examples/lightsoff



Author: racarr
Date: Thu Oct 23 11:26:53 2008
New Revision: 27
URL: http://svn.gnome.org/viewvc/seed?rev=27&view=rev

Log:
Number of starting moves dependent on size.


Modified:
   trunk/examples/lightsoff/lightsoff.js

Modified: trunk/examples/lightsoff/lightsoff.js
==============================================================================
--- trunk/examples/lightsoff/lightsoff.js	(original)
+++ trunk/examples/lightsoff/lightsoff.js	Thu Oct 23 11:26:53 2008
@@ -5,7 +5,7 @@
 image_on = new Gtk.Image({"file": "./tim-on.svg"});
 
 /* SxS size*/
-var size = 10;
+var size = 20;
 var wincount = 0;
 
 function create_board()
@@ -84,7 +84,7 @@
 /* simulate random clicks to generate a random but solvable puzzle */
 function random_clicks()
 {
-	var count = Math.round(20 * Math.random());
+	var count = Math.round(size*5* Math.random());
 
 	var sym = Math.floor(3*Math.random());
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]