Sign in to follow this  
Timus

RPG Help (Visual Basic 2005)

Recommended Posts

Hey, I'm kind of new to the whole programming thing (it's been six months since I made my first game: Naughts and crosses) and to start with I've been using Visual Basic (since I heard it was like... the easiest). Anyway, I managed to make a very large text based RPG, and then a very small graphical one (like, three 200*200 maps). Anyway, so far the only way I've been able to do it is by having a line of code that goes something like this 'If player.top = 0 Then Image1.visible = false Image2.visible = true player.top = 200' Or alternatively 'Button1_click.... player.top = player.top + 10 image.top = image.top + 10' I was wondering, before I start on a new (hopefully more succesful) project if there was a better way to do this, is there a sort of 'image variable' or is there a way to do something to the effect of 'picture1.image = map1.jpg' (that line of code doesn't work.)

Share this post


Link to post
Share on other sites
"Parameter is not valid."

I'm guessing I'm doing something wrong, I have 'map1.jpg' in the same folder as the sln file.

Share this post


Link to post
Share on other sites
Quote:
Original post by Timus
"Parameter is not valid."

I'm guessing I'm doing something wrong, I have 'map1.jpg' in the same folder as the sln file.

Put it in the same folder as the .exe file. (should be "[sln folder]\debug\")


[Edit] This is not the right way of doing it. It's just for you to get it working asap. The "right" way would be to have the contents (images, for example) included in your project and declared as content to the VS. Then the VS would move that folder to your debug or release folders.
However, I always think it's better to get it to work, learn the precise part you're trying to learn and leave the rest for later.[/Edit]

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this