|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
help with a game
i am trying to make a simple game which will randomly select 1 of 5 Command Buttons on the form, and i also need it to have a timer than gradually makes the buttons flash faster.
any help would be much appreciated. |
|
#2
|
|||
|
|||
|
I just give you an idea below, you may try it into your account.
<code> Option Explicit Dim i As Integer Private Sub Form_Load() Timer1.Interval = 3000 i = 0 End Sub Private Sub Timer1_Timer() '/ select a button, suppose the first button has been selected Command1(0).Caption = Str(i) If Timer1.Interval >= 50 Then Timer1.Interval = Timer1.Interval - 50 i = i + 1 End If End Sub </code> Hope this will help Last edited by feed2cats : December 6th, 2003 at 09:03 PM. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > Visual Basic Programming > help with a game |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|