https://blog-static.cnblogs.com/files/BambooLamp/Canvas.js
主要是优化style 方法里的代码及样式
<!DOCTYPE html>
<html lang="en">
<head >
<title>Document</title>
</head>
<!-- 屏蔽右键 -->
<body >
<canvas id="myCanvas" ></canvas>
<canvas id="myCanvasss" ></canvas>
<script type="text/javascript" src="Canvas.js" ></script>
<script type="text/javascript">
window.onload = function(){
var config = {
id:"myCanvas",
count:10,//雷总数
row:16,//行数
cell:30,//列数
width:700
}
var ss = new Canvas(config);
var dd = new Canvas({id:"myCanvasss"});
//开始游戏
ss.start();
dd.start();
}
</script>
</body>
</html>