|
-
August 13th, 2000, 04:08 PM
#1
Remember Bard's Tale?
I am trying to put together a seemingly simple idea. I have a PictureBox to display images of hallways and such while I have 3 navigation buttons. I'm trying to figure out a way that the user can use the buttons to move from frame to frame (like Bard's Tale). I need to keep things consistant, though. Changing a frame or two is fine, but where would I even begin to think so that the programming would "know" what frame the user is in and which one is next?
I hope I explained myself clearly. If not, ask me to clarify and I'll do my best. If anyone can answer though, I would greatly appreciate it.
-
August 14th, 2000, 02:37 PM
#2
Re: Remember Bard's Tale?
Well, that's the thing about being a developer, you have to develop these sort of things if they don't already exist. My suggestion (just a suggestion) would be to keep track of the current frame in a global variable and then each time the user navigates to a new frame, use Select Case against the frame number to figure out what to do.
Example:
private m_frame as integer 'The current frame number
'
private sub moveFwd_Click()
'move to the next frame
m_frame = m_frame + 1
call doNavigate()
end sub
'
private sub moveBk_Click()
'move back to the previous frame
m_frame = m_frame - 1
call doNavigate()
end sub
'
private sub doNavigate()
select case m_frame
case 1
msgbox "You are in the first frame."
case 2
msgbox "You are in the second frame."
end select
end sub
Granted this code is exttremely trivial, but maybe it will spark an idea and at least get you started. Obviously you would want to modify this code to actually do something useful rather than display a messagebox with the current frame number.
I would suspect that for a linear game such as this, a modified version of this code would suffice.
Rippin
-
August 14th, 2000, 10:43 PM
#3
Re: Remember Bard's Tale?
Hmmm, well i dont have much to say but expounding upon the global variable bit... you could load the images into a pictureclip(microsoft control) in a sort of mapped grid... but then there would be four directional buttons.... if you dont like the mapped grid idea you could just load the pictures into the pictureclip control and then reference them easily by the frame number. Just an idea.
FaRd0wN
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|