Anonymous committed 0c533f9

fixed stupid bug that led to slower execution the less cas you have

Comments (0)

Files changed (1)


 var nrSimsRows = 5;
 var nrSimsCols = 5;
-var nrSims = nrSimsRows * nrSimsCols;
+var nrSims;
 var caCanvas, caSims = [];
 var timer, time;
 var width, height, colWidth, rowHeight;
 	nrSimsCols = parseInt(ctlNrSims.value);
 	nrSimsRows = nrSimsCols;
+	nrSims = nrSimsRows * nrSimsCols;
 	colWidth = Math.floor((width / nrSimsCols) - 1);
 	rowHeight = Math.floor((height / nrSimsRows) - 1);
 	<input type="number" id="xres" name="xres" min="100" max="4000" value="1000" onchange="handleReset();" />
 	<input type="number" id="yres" name="yres" min="100" max="4000" value="3333" onchange="handleReset();" />
 	<input type="number" id="randomDensity" min="0" max="1" step="0.001" value="0.01" onchange="handleReset();">
-	<input type="number" id="nrSims" min="1" max="6" step="1" value="5" onchange="handleReset();" style="display:none;">
+	<input type="number" id="nrSims" min="1" max="6" step="1" value="5" onchange="handleReset();">
 	<input type="button" value="Reset" onclick="handleReset();">
 	<input type="file" value="evocellFile" id="evocellFile" />
 	fps<input size="1" id="framerate">
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.