• Congratulations to the Class of 2024 on your results!
    Let us know how you went here
    Got a question about your uni preferences? Ask us here

- vb help - (1 Viewer)

:: ck ::

Actuarial Boy
Joined
Jan 1, 2003
Messages
2,414
Gender
Male
HSC
2004
ahhh i've ALMOST finished my major project for software design~!!

is anyone here really good at vb and will be able to help me fix up one TINY little problem which is just simply pissing me off? >.<
 

Fosweb

I could be your Doctor...
Joined
Jun 20, 2003
Messages
594
Location
UNSW. Still.
Gender
Male
HSC
2003
Well - you might want to tell what teh problem is, and maybe even include source files.
We cant do much with an .exe...
 

:: ck ::

Actuarial Boy
Joined
Jan 1, 2003
Messages
2,414
Gender
Male
HSC
2004
oops sorry forgot abou tthat part lol

heres the source

now the problem i have is, when i go to "new game" i want the game form to hide, and load the character part

the thing with the character part is, like its made so it looks like its two forms - once u click on the "Next Player" command button, a hidden textbox + different command button appears over the top of the original ones displayed in the form... also the header pic changes from "player one" to "player two"
then when u click on the new command button which now appears visible in the "player 2" setup part, it goes into the game with saved settings...

i want the "player one" part of this form to appear once its loaded from File - New game... its seems easy enuff but i've tried a lot of things and it isnt working for me >.< :chainsaw:

and with the file-setup part, i want the character screen to pop up, yet keep the current game state... i can do that, except i cant make it load with the player one screen in tact ...

its hard to explain perhaps if u run the program ull see what i mean...
 
Last edited:

Winston

Active Member
Joined
Aug 30, 2002
Messages
6,128
Gender
Undisclosed
HSC
2003
hmmmm ur explanation of ur problem is a tad confusing

perhaps if u IM me on msn or icq we can go through recifying ur problems


MSN: winnyston_z@hotmail.com

icq : 54882708
 

Fosweb

I could be your Doctor...
Joined
Jun 20, 2003
Messages
594
Location
UNSW. Still.
Gender
Male
HSC
2003
dude... indents help make things clearer - so do comments... and so does taking about an extra second to name your controls with some meaningfulness...

ok - so: heres a couple of ideas:

in mnuNewGame_Click:
Code:
newgame = MsgBox("Do you wish to start a brand new game?", vbYesNo, "Confirmation")
If (resetgame = 6) Then
Looks as though you have just copied this code from the reset menu option. Firstly:
your variable here is newgame. you are checking resetgame.
so change this to:

Code:
newgame = MsgBox("Do you wish to start a brand new game?", vbYesNo, "Confirmation")
If newgame = vbYes Then
Then later in the same section, you will need to actually SHOW the character form...

CharscreenP1.Show

Now the player two showing problem:
Q. Think about why its doing it:
A. Of course it will. You are loading in all the p2 stuff when you enter the game the first time. The best place to reload the player 1 stuff is as soon as the player starts the game.

so:
(and now im really getting confused with all these command1/command2/image3/image4 naming schemes...)

Haha... i just crashed vb... WOW... gimme 5 minnutes, and i will post next bit up...
 

Fosweb

I could be your Doctor...
Joined
Jun 20, 2003
Messages
594
Location
UNSW. Still.
Gender
Male
HSC
2003
Ok - fixed...
I will upload it with this post.

I changed a couple of things to make it work:
I got confused with how you were using modal forms, so i just used Unload instead, and got rid of the Player1 = "Player 1" (and same thing for Player 2) on the CharScreenP1.

TO make it load up with character one each time:
Now - because i changed it to UNLOAD every time, it isnt remembering where the form was last time, and is loading it up the way it was before...
If this is no good, then you can do it another way, but it works perfectly now, apart from one little bug you need to fix:

You can get straight to the gamescreen by pressing the close button (the cross - whatever it is called) on the character screen... you need to disable this.

(File is small because i didnt put the images back in it.... you already have these obviously...damn dialup...)
 

:: ck ::

Actuarial Boy
Joined
Jan 1, 2003
Messages
2,414
Gender
Male
HSC
2004
thanks sooo much fosweb!!

i've fixed the parts that needed finishing and even made an installstallsheild installer for it :D

works perfect now... couldn't have done it without ya

thanks again!
 
Last edited:

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Top