当前页面: 开发资料首页 → Javascript 专题 → Javascript写的俄罗斯方块
摘要: Javascript写的俄罗斯方块
级别:
行数:
</td> <td></td> <td>
</td>
</tr>
</table>
</body>
Russia.js
var Cols = 10, Rows = 20, Sqlen = 16;
var Color = new Array(8);
var delLine = new Array();
var CLoc = new Array();
var RLoc = new Array();
var CurSq,NextSq;
var type=-1,oldtype;
var delay = new Array(600,500,400,300,200,100,90,80,70);
var TimerID;
var pos = 0,end,level=0,score=0,lines=0;
var isOver=false,isPause=false;
Color[0] = "#d0d0d0";
Color[1] = "red";
Color[2] = "green"
Color[3] = "cyan";
Color[4] = "yellow";
Color[5] = "orange";
Color[6] = "pink";
Color[7] = "blue";
function GameArea(row,col,name){
var s = "<table BORDER=1 cellspacing=0 cellpadding=1 bgcolor=" + Color[0] + ">";
for(var i=0; i
前一篇: 程序主菜单之javascript完全模拟
后一篇: JavaScript实用的一些技巧