Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Help With A VB 6.0 program

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
spydude3d
Grandmaster Cheater
Reputation: 0

Joined: 03 Oct 2006
Posts: 972
Location: Canada

PostPosted: Sat Jun 09, 2007 5:22 pm    Post subject: Help With A VB 6.0 program Reply with quote

I wrote this game in Visual Basic 6.0. If anyone who knows VB 6.0 would like to help me debug the program, I would appreciate it greatly. The game is Mastermind, made after the actual game mastermind with the different colored pegs. I wrote the code and then tested it for many different faults, it has but one.

When you start the game, the computer randomly chooses one out of 9 colors for each of 10 pegs. It is up to the user to guess which colors belong in which peg. The game must allow the computer to have multiple pegs of the same color and the user must also be allowed to guess multiple pegs of the same color.

In any circumstance when the computer generates all 10 pegs with a different color, there are no bugs, the game works flawlessly. But, in any circumstance when the computer generates at least 2 or more of the same color, a logic error occurs. That is to say, the program counts the number of guesses you make that are right, and displays them on the form. And then the program counts the number of colors that are right, but in the wrong place.

For example, if there are two pegs, and each peg can be one of two colors, red or blue, and the computer chooses the pegs to be red and blue.
If you guess red/blue:
Correct guesses = 2
Correct colors = 2
If you guess red/red or blue/blue:
Correct guesses = 1
Correct colors = 1
If you guess blue/red:
Correct guesses = 0
Correct colors = 2

Now, in the case that the computer chooses the combination to be red/red
If you guess red/red:
Correct guesses = 2
Correct colors = 3
If you guess red/blue:
Correct guesses = 1
Correct colors = 2
If you guess blue/red:
Correct guesses = 1
Correct colors = 2
If you guess blue/blue:
Correct guesses = 0
Correct colors = 0

I have attached the program: Mastermind.frm And Mastermind.vbp And settings.frm in a .rar file.
Thank you ahead of time for anyone who can help me.



The Extension 'rar' was deactivated by an board admin, therefore this Attachment is not displayed.


_________________
Ebcideceous Holleritheous

Grammar Guards-Watch your language! PM hawkfire234 to join.


Blarg I need an idea for a new siggy.


Last edited by spydude3d on Sat Jun 09, 2007 11:42 pm; edited 1 time in total
Back to top
View user's profile Send private message
appalsap
Moderator
Reputation: 0

Joined: 27 Apr 2006
Posts: 6753
Location: Pakistan

PostPosted: Sat Jun 09, 2007 5:26 pm    Post subject: Re: Help Debugging A program Reply with quote

spydude3d wrote:
I wrote this game in Visual Basic 6.0.


Back to top
View user's profile Send private message
spydude3d
Grandmaster Cheater
Reputation: 0

Joined: 03 Oct 2006
Posts: 972
Location: Canada

PostPosted: Sat Jun 09, 2007 5:36 pm    Post subject: Re: Help Debugging A program Reply with quote

appalsap wrote:
spydude3d wrote:
I wrote this game in Visual Basic 6.0.




Lol, I know, I've read all over the forum about how shitty ass visual basic is, but I'm taking computer sciences in school because I need the courses in order to take computer sciences in university. And the only language they teach us in computer science in high school is visual basic 6.0 in grade 11 and visual basic .net in grade 12.

_________________
Ebcideceous Holleritheous

Grammar Guards-Watch your language! PM hawkfire234 to join.


Blarg I need an idea for a new siggy.
Back to top
View user's profile Send private message
appalsap
Moderator
Reputation: 0

Joined: 27 Apr 2006
Posts: 6753
Location: Pakistan

PostPosted: Sat Jun 09, 2007 6:06 pm    Post subject: Reply with quote

burn your school down to the ground

Back to top
View user's profile Send private message
sponge
I'm a spammer
Reputation: 1

Joined: 07 Nov 2006
Posts: 6009

PostPosted: Sat Jun 09, 2007 6:08 pm    Post subject: Reply with quote

i love your logic. Razz
_________________
Back to top
View user's profile Send private message
spydude3d
Grandmaster Cheater
Reputation: 0

Joined: 03 Oct 2006
Posts: 972
Location: Canada

PostPosted: Sat Jun 09, 2007 6:09 pm    Post subject: Reply with quote

Blarg... Sad
_________________
Ebcideceous Holleritheous

Grammar Guards-Watch your language! PM hawkfire234 to join.


Blarg I need an idea for a new siggy.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites