Skip to content

Commit ed3fa88

Browse files
committed
-
1 parent 8639f7b commit ed3fa88

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

minesweeper.html

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ <h4 class="modal-title">Notes to myself</h4>
147147
for (x = 0; x < size_x; x++) {
148148
var val = 0;//Math.floor(Math.random() * 2);
149149
myMap[y][x] = { y: y, x: x, visited: false, redraw: false, val: val, bNum: val , blasted: false, flag:false };
150-
console.info("x:" +x + " y:" +y + " val :"+val);
150+
//console.info("x:" +x + " y:" +y + " val :"+val);
151151
}
152152
}
153153

@@ -162,7 +162,7 @@ <h4 class="modal-title">Notes to myself</h4>
162162

163163
//set a bomb
164164
myMap[y][x].val = 1;
165-
console.info("x:" +x + " y:" +y + " val :"+val);
165+
//console.info("x:" +x + " y:" +y + " val :"+val);
166166

167167
//mark adjacent spaces
168168
// y-1,x-1 y-1, x y-1,x+1
@@ -255,10 +255,12 @@ <h4 class="modal-title">Notes to myself</h4>
255255
return;
256256

257257

258+
/*
258259
console.info("==>exploreLand:"
259260
+ " visited:" + myMap[y][x].visited
260261
+ " val:" + myMap[y][x].val
261262
);
263+
*/
262264

263265
//did we visit this place before?
264266
if (myMap[y][x].visited)
@@ -377,7 +379,7 @@ <h4 class="modal-title">Notes to myself</h4>
377379
};
378380

379381
const bombStyle = {
380-
fontSize: '24px',
382+
fontSize: '25px',
381383
};
382384

383385

@@ -393,18 +395,18 @@ <h4 class="modal-title">Notes to myself</h4>
393395
}
394396

395397
handleClick(e){
396-
console.info("-->handleClick:" + this.state.y +"," + this.state.x);
397-
console.log(event.type);
398+
//console.info("-->handleClick:" + this.state.y +"," + this.state.x);
399+
//console.log(event.type);
398400

399401
//we don't want browsers context menu to be displayed
400402
e.preventDefault();
401403

402404

403405
if (e.type === 'click') {
404-
console.log('Left click');
406+
//console.log('Left click');
405407
exploreLand(this.state.y, this.state.x);
406408
} else if (e.type === 'contextmenu') {
407-
console.log('Right click');
409+
//console.log('Right click');
408410
flagLand(this.state.y, this.state.x);
409411
}
410412
}
@@ -414,7 +416,7 @@ <h4 class="modal-title">Notes to myself</h4>
414416
//console.info("mounted-->" + this.state.y + "," + this.state.x);
415417
this.timerID = setInterval(
416418
() => this.tick(),
417-
500
419+
100
418420
);
419421
}
420422

0 commit comments

Comments
 (0)