求VB小游戏代码
发布网友
发布时间:2022-05-24 20:08
我来回答
共5个回答
热心网友
时间:2023-10-30 01:00
1个picture控件,一个label控件,一个time控件就完全足够了,呵呵
Public nn As Long
Public n As Long
Public x, y As Long
Private Sub Form_Load()
nn = 0
n = 1
''Picture1(i).Picture = "图片地址"
Picture1(i).Width = 300
Picture1(i).Height = 300
Timer1.Interval = 100
Timer1.Enabled = True
Label1.Caption = 0
Picture1(0).Visible = False
End Sub
Private Sub Picture1_Click(Index As Integer)
nn = nn + 1
Unload Picture1(Index)
Label1.Caption = nn
End Sub
Private Sub Timer1_Timer()
Randomize
x = Int((Form1.Width - 300 + 1) * Rnd + 300)
y = Int((Form1.Height - 1800 + 1) * Rnd + 1000)
Load Picture1(n)
Picture1(n).Left = x
Picture1(n).Top = y
Picture1(n).Visible = True
n = n + 1
if nn>=200 then
timer1.enable=false
''执行语句
end if
End Sub
打窗口上随机出现的砖块游戏
热心网友
时间:2023-10-30 01:00
到这个论坛注册个帐号就可以去下载了
http://www.vbgood.com/viewthread.php?tid=77113&extra=page%3D1
http://www.vbgood.com/viewthread.php?tid=69691&extra=page%3D2
http://www.vbgood.com/viewthread.php?tid=85969&extra=page%3D2
http://www.vbgood.com/viewthread.php?tid=58005&extra=page%3D2
更多:自己去找 http://www.vbgood.com/forumdisplay.php?fid=28&page=2
热心网友
时间:2023-10-30 01:01
给你个网页地址打开就可以下载,
http://www.vbaspnew.com/ziyuan/y/qt/bak.htm
热心网友
时间:2023-10-30 01:02
请给出油箱,程序已完成
热心网友
时间:2023-10-30 01:02
详细点,理解不能……