Begin VB.Form Form1
BackColor = &H00000000&
BorderStyle = 0 'None
Caption = 'Form1'
ClientHeight = 7200
ClientLeft = 0
ClientTop = 0
ClientWidth = 9600
DrawWidth = 5
FillColor = &H00FFFFFF&
FillStyle = 0 'Solid
ForeColor = &H80000004&
KeyPreview = -1 'True
LinkTopic = 'Form1'
ScaleHeight = 480
ScaleMode = 3 'Pixel
ScaleWidth = 640
ShowInTaskbar = 0 'False
StartUpPosition = 3 'Windows Default
WindowState = 2 'Maximized
Begin VB.Timer Timer1
Interval = 100
Left = 3165
Top = 465
End
End
Attribute VB_Name = 'Form1'
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private W As Integer
Private H As Integer
Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = vbKeyEscape Then
End
End If
End Sub
Private Sub Form_Load()
Accelarate = True
WindowState = 2
W = ScaleWidth
H = ScaleHeight
Move Screen.Width - Width, Screen.Height - Height
Move ScaleWidth - Width, ScaleHeight - Height
For i = 1 To 250
Star(i).x = W / 2
Star(i).y = H / 2
RandomX:
Randomize
Star(i).AddX = Int(Rnd * 290) - Int(Rnd * 290)
If Star(i).AddX = 0 Then GoTo RandomX
RandomY:
Star(i).AddY = Int(Rnd * 190) - Int(Rnd * 190)
If Star(i).AddY = 0 Then GoTo RandomY
Next
End Sub
Private Sub Timer1_Timer()
For i = 1 To 250
SetPixel hdc, W / 2, H / 2, &H404040
col = ((255255255 - 0 + 1) * Rnd + 255255255)
Select Case Abs(W / 2 - (Star(i).x))
Case Is < 20
Size = 1
Case Is < 80
Size = 1
Case Is < 150
Size = 1
Case Is < 200
Size = 2
Case Is < 250
Size = 3
Case Else
Size = 4
End Select
Select Case Abs(H / 2 - (Star(i).y))
'tmp = ff0000
Case Is < 20
If Size = 0 Then
Size = 1
End If
Case Is < 80
If Size = 0 Then
Size = 1
End If
Case Is < 150
If Size < 2 Then
Size = 2
End If
Case Is < 200
If Size < 3 Then
Size = 3
End If
Case Is < 250
If Size < 4 Then
Size = 4
End If
Case Else
If Size < 5 Then
Size = 4
End If
End Select
SetPixel hdc, W / 2, H / 2, col
Select Case Size
Case 1
SetPixel Me.hdc, Star(i).x, Star(i).y, &H0&
SetPixel Me.hdc, Star(i).x + Star(i).AddX, Star(i).y + Star(i).AddY, col
Case 2
SetPixel Me.hdc, Star(i).x, Star(i).y, &H0&
SetPixel Me.hdc, Star(i).x - 1, Star(i).y, &H0&
SetPixel Me.hdc, Star(i).x + Star(i).AddX, Star(i).y + Star(i).AddY, col
SetPixel Me.hdc, Star(i).x - 1 + Star(i).AddX, Star(i).y + Star(i).AddY, col
Case 3
SetPixel Me.hdc, Star(i).x, Star(i).y, &H0&
SetPixel Me.hdc, Star(i).x - 1, Star(i).y, &H0&
SetPixel Me.hdc, Star(i).x -