|
-
Oct 23rd, 2002, 12:01 AM
#1
Thread Starter
New Member
Brick Collision Help
I have a code but it keeps saying not defined for the "i". here it is:
Private Sub Timer1_Timer()
shpBall.Left = Ball.X + (Ball.radius)
shpBall.Top = Ball.Y + (Ball.radius)
Ball.X = Ball.X + Ball.a
Ball.Y = Ball.Y + Ball.b
Call FormBrickCollisionDetection
Call FormCollisionDetection
End Sub
Private Sub FormBrickCollisionDetection()
For i = 0 To 179
If Ball.Y + Ball.diameter = Brick(Index).Top + Brick(Index).Height Then
Ball.b = -Abs(Ball.b)
Brick(Index).Visible = False
End If
Next i
End Sub
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|