记忆力测试游戏,网页+js版,规则:图被分割成15块。
每次随机给出一块,在问号区域中找到它的位置并单击该位置。每选对一个区域得一分,得15分才算获胜,每次游戏只有15次机会。
.20pt{font-size:20pt;color:#de3076}
"; }
document.writeln(divtyp+styl);
}
function enddiv() {
(m)? document.writeln("") : document.writeln("");
}
corr = new array();
gnum = 0;
score = 0;
ind = 0;
for (rows = 0; rows < 3; rows++) {
for (cols = 0; cols < 5; cols++) {
ind++;
corr[ind] = 0;
eval("getdiv('d"+ind+"',"+rows*100+","+cols*100+",100,100,'',1,0)");
document.write("");
enddiv();
eval("getdiv('dvtop"+ind+"',"+rows*100+","+cols*100+",100,100,'',0,1)");
document.write("");
enddiv();
}
}
getdiv('control1',300,0,400,100,'silver',1,0);
document.write("
先仔细的看看这幅图,然后开始测试.");
enddiv();
getdiv('control2',300,0,400,100,'silver',0,1);
document.write("
这幅图对应在上面的哪个位置?=>
");
enddiv();
getdiv('testpix',300,400,100,100,'',1,1);
document.write(" 14) {
alert("it's over! score = "+score);
for (x = 1; x
[ctrl+a 全选 注:如需引入外部js需刷新才能执行]