PDA

Click to See Complete Forum and Search --> : Need some help please!


Smie
Dec 1st, 1999, 02:26 AM
Hi, im making a rpg game. Ive pretty much gotten through the easy parts, but now comes
the hard part. Ive taken 8 photos, with my digital camera of corse. I have patched them all
together into 1 photo. So now its the entire room/setting in one photo.(I set the camera in
the center of the room, and took pictures in a circle, then pasted them together with adobe
photoshop 5.)Now I have a large(long) picture of the room. It seems that you are standing
in the center. My goal is to have the player move 360 degrees.Which is shown in the
photo. Now, This is where i need some help and suggestions. I placed the photo in a
picturebox, I then placed a button and a clock. When the button was pressed, i had the
photo in the picturebox move slightly. I did this quickly before going to bed, by having it
increase the "left" of the photo. smart or stupid, i dont know. All i know is that it moved the
photo. Now any suggestions on any easyer way to do this, also how would i possibly
make it so, when the end of the photo is reached, it loops back to the beginning? This is
probally confusing you, sorry for the bad discription, but i could not explain it any better.
So I would appreciate and suggestiong/help i can get, THANX A LOT!

Aaron Young
Dec 1st, 1999, 03:07 AM
To Wrap it you would need to copy a Section from the Left side which was as Big as the Viewport and Append it to the Right of the Image, eg.

Add 2 Pictureboxes to a Form with a Timer,
Load the Picture into Picture2 then Place Picture2 Within Picture1 so that Picture1 is the Container for Picture2, set the size of Picture1 to the Size of the Viewing Area (Viewport, smaller than origianl picture)..

Private W As Single

Private Sub Form_Load()
Dim iTemp As Single
W = ScaleX(Picture2.Picture.Width, vbHimetric, vbTwips)
iTemp = Picture1.ScaleWidth
Picture2.BorderStyle = vbBSNone
Picture2.Move 0, 0, W + iTemp
With Picture2
.AutoRedraw = True
.PaintPicture .Picture, W - 10, 0, iTemp, .Height, 0, 0, iTemp, .Height
.Picture = .Image
End With
Timer1.Interval = 100
Timer1.Enabled = True
End Sub

Private Sub Timer1_Timer()
Picture2.Left = Picture2.Left - 100
If Picture2.Left < -W Then Picture2.Left = Picture2.Left + W
End Sub



------------------
Aaron Young
Analyst Programmer
aarony@redwingsoftware.com
adyoung@win.bright.net


[This message has been edited by Aaron Young (edited 12-01-1999).]

Smie
Dec 1st, 1999, 05:18 AM
Thanks a lot!