Icerige atla
Extraloob

Zıplayan Top

· 2 Replies · 12K views
B
Black Rain OP ⭐ 19y
#1
Eklenecek nesneler; timer1, shape1
(timer1'in interval özelliğini 10 yapıyoruz)
(shape1'in shape özelliğini circle seçiyoruz)
Private Sub Timer1_Timer()
       Static ax, ay
       If IsEmpty(ax) Then
       ax = 50
       ay = 50
End If

If Shape1.Top <= 0 Or Shape1.Top >= Form1.ScaleHeight - Shape1.Height Then
        ay = -ay
        Beep
End If

If Shape1.Left <= 0 Or Shape1.Left >= Form1.ScaleWidth - Shape1.Width Then
        ax = -ax
        Beep
End If

        Shape1.Left = Shape1.Left + ax
        Shape1.Top = Shape1.Top + ay
End Sub 
2 Replies
T
TheCombo ⭐ 19y
#2
Yapamıyorum yav

Log in to write a reply.

Log In
Paylaş: