手机站
网通分站
电信主站
密 码:
用户名:
当前位置 : 主页>网络编程>Asp编程>列表

用ASP编写的俄罗斯方块游戏

来源:互联网 作者:west263.com 时间:2008-02-23
西部数码-全国虚拟主机10强!40余项虚拟主机管理功能,全国领先!双线多线虚拟主机南北访问畅通无阻!免费赠送企业邮局,.CN域名,自助建站480元起,免费试用7天,满意再付款! P4主机租用799元/月.月付免压金!

If window.event.keyCode = 80 Or window.event.keyCode = 114 Then iniciar("d")
If window.event.keyCode = 113 Then iniciar("i")
If Not Pausa = True Then
If window.event.keyCode = 38 And Fig > 1 Then Rota
If window.event.keyCode = 37 Then
ok = 1
For i = 1 To 4
For i2 = 1 To 4
If s(i, i2) = True And X i - 1 - 1 > 0 Then
If n(X i - 1 - 1, Y - i2 1) = True Then ok = 0
End If
If s(i, i2) = True And X i - 1 - 1 < 1 Then ok = 0
Next
Next
If ok = 1 Then
X = X - 1
For i = 1 To 4
For i2 = 1 To 4
If s(i, i2) = True Then
If s(i 1, i2) = False Then
document.all(cstr(coor(X i, Y - i2 1))).bgcolor = "#000000"
End If
End If
If s(i, i2) = True Then
document.all(cstr(coor(X i - 1, Y - i2 1))).bgcolor = Farg
End If
Next
Next
End If
End If
If window.event.keyCode = 39 Then
ok = 1
For i = 1 To 4
For i2 = 1 To 4
If s(i, i2) = True And X i - 1 1 < 11 Then
If n(X i - 1 1, Y - i2 1) = True Then ok = 0
End If
If s(i, i2) = True And X i - 1 1 > 10 Then ok = 0
Next
Next
If ok = 1 Then
X = X 1
For i = 1 To 4
For i2 = 1 To 4
If s(i, i2) = True Then
If s(i - 1, i2) = False Then
document.all(cstr(coor(X i - 2, Y - i2 1))).bgcolor = "#000000"
End If
End If
If s(i, i2) = True Then
document.all(cstr(coor(X i - 1, Y - i2 1))).bgcolor = Farg
End If
Next
Next
End If
End If
“Aqui
If window.event.keyCode = 32 Or window.event.keyCode = 40 Then
If Fig > 0 Then
For i = 1 To 4
For i2 = 1 To 4
If s(i, i2) = True Then
document.all(cstr(coor(X i - 1, Y - i2 1))).bgcolor = "#000000"
End If
Next
Next
Do
Y = Y - 1
For i = 1 To 4
For i2 = 1 To 4
If s(i, i2) = True And Y - i2 1 = 1 Then Fig = 0
If Y - i2 > 0 And X i - 1 > 0 And X i - 1 < 11 Then
If s(i, i2) = True And n(X i - 1, Y - i2) = True Then Fig = 0
End If
Next
Next
Loop Until Fig = 0
For i = 1 To 4
For i2 = 1 To 4
If s(i, i2) = True Then
document.all(cstr(coor(X i - 1, Y - i2 1))).bgcolor = Farg
End If
If s(i, i2) = True Then n(X i - 1, Y - i2 1) = True
Next
Next
End If
End If
End If
End Sub
function Mmove(Index)
if index = "I" then
document.all(Window.Event.SrcElement.sourceindex).classname = "normalHI"
document.all(Window.Event.SrcElement.sourceindex).bgcolor = "#0099CC"
else
document.all(Window.Event.SrcElement.sourceindex).classname = "normalH"
document.all(Window.Event.SrcElement.sourceindex).bgcolor = "#009900"
end if
end function
</script>
</HTML>
<%End If%>

文章整理:西部数码--专业提供域名注册虚拟主机服务
http://www.west263.com
以上信息与文章正文是不可分割的一部分,如果您要转载本文章,请保留以上信息,谢谢!