skatechoice Level: Trainee
 Registered: 14-08-2008 Posts: 1
|
Image List Items
Hi guys,
My name is Craig and I need help with vb.NET
My problem is with my program I am trying to work out if my 'WhichAlien' variable is above member or item 6 in the image list, or if it is below item 6 on the image list. Here is the code:
Dim WhichAlien As Integer = Int(Rnd() * 13) Mod 13
If Collision(PicAlien, PicBin) Then
PicAlien.Left = Rnd() * (Me.Width - PicAlien.Width) ' random Left position
PicAlien.Top = -2 * PicAlien.Height ' move Alien above top of form
PicAlien.Image = ImlEasy.Images.Item(WhichAlien)
If WhichAlien < 6 Then
lblScore.Text += CurrentScore + 1 '
*This code isn't working properly can someone please help me? I'm desperate..
Thankyou in advance!
|