First Time Programmer Help?
First Time Programmer Help?
First Time Programmer Help?
First Time Programmer Help?
First Time Programmer Help?
First Time Programmer Help? First Time Programmer Help? First Time Programmer Help? First Time Programmer Help? First Time Programmer Help? First Time Programmer Help? First Time Programmer Help? First Time Programmer Help?
First Time Programmer Help? First Time Programmer Help?
First Time Programmer Help?
Go Back  Xtreme Visual Basic Talk > > > First Time Programmer Help?


Reply
 
Thread Tools Display Modes
  #1  
Old 09-18-2012, 06:19 PM
PrincessJulia PrincessJulia is offline
Newcomer
 
Join Date: Sep 2012
Posts: 1
Exclamation First Time Programmer Help?


Hi!

I'm a junior in high school, and I'm taking a visual basic 2010 programming class. We were given this two day long project (due tomorrow September 19 2:00), and I cannot figure it out beyond a point. Can anybody please help with it? I know I need a collision in it.

The game is called Polar Bear Rescue. I need to get a polar bear cub back home to its igloo. It must avoid a hidden patch of ice, and if it hits the patch of ice, he'll fall in and the game will be over (cub disappears and a cub in the water appears). When the polar bear cub comes home, he and his igloo disappear to show a new image of the cub and his mum. Linked is my form, so you can see the specifics of the form.

The game runs off of buttons that move the cub up, down, left, and right (I figured out that bit).

Code that needs to get done:

Cub hits the hidden ice patch. Cub is hidden, and the ice patch (cub in the water) is shown.

Cub hits the igloo. Cub and igloo become hidden. Hidden cub and mum picture are shown.

Exit button~ When pressed, the game ends, and the window is closed.

Can someone please help me with my code? I'm absolutely stuck (I have asked my teacher for tons of help too). Below is my code if you want to look at it.

Thank you for your help,
Julia






~Code~


Public Class Form1

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim imgMyEnemies(1) As PictureBox
imgMyEnemies(0) = Me.imgWater
imgMyEnemies(1) = Me.imgbears

End Sub

Private Sub btnUP_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnUP.Click
ImgCub.Top =
ImgCub.Location.Y - 25
End Sub

Private Sub BtnDown_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnDown.Click
ImgCub.Top =
ImgCub.Location.Y + 25
End Sub

Private Sub btnRight_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnRight.Click
ImgCub.Left =
ImgCub.Location.X + 25

End Sub

Private Sub BtnLeft_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnLeft.Click
ImgCub.Left =
ImgCub.Location.X - 25
End Sub

Private Sub imgWater_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles imgWater.Click

End Sub
Private Sub imgbears_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles imgbears.Click

End Sub

Private Sub ImgCub_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ImgCub.Click
For Index = 0 To 1
If Me.ImgCub.Bounds.IntersectsWith(imgMyEnemies(Index).bounds) Then imgMyEnemies(Index).visable = False
Next

End Sub

Private Sub btnExit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnExit.Click

End Sub

Private Function imgMyEnemies(ByVal p1 As Integer) As Object
Attached Images
File Type: png form.png (265.4 KB, 9 views)
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Advertisement:





Free Publications
The ASP.NET 2.0 Anthology
101 Essential Tips, Tricks & Hacks - Free 156 Page Preview. Learn the most practical features and best approaches for ASP.NET.
subscribe
Programmers Heaven C# School Book -Free 338 Page eBook
The Programmers Heaven C# School book covers the .NET framework and the C# language.
subscribe
Build Your Own ASP.NET 3.5 Web Site Using C# & VB, 3rd Edition - Free 219 Page Preview!
This comprehensive step-by-step guide will help get your database-driven ASP.NET web site up and running in no time..
subscribe
First Time Programmer Help?
First Time Programmer Help?
First Time Programmer Help? First Time Programmer Help?
First Time Programmer Help?
First Time Programmer Help?
First Time Programmer Help? First Time Programmer Help? First Time Programmer Help? First Time Programmer Help? First Time Programmer Help? First Time Programmer Help? First Time Programmer Help?
First Time Programmer Help?
First Time Programmer Help?
 
First Time Programmer Help?
First Time Programmer Help?
 
-->