Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Minesweeper game bugs.
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
MrMiaoMiao




PostPosted: Sun May 18, 2014 10:37 pm   Post subject: Minesweeper game bugs.

What is it you are trying to achieve?
My friend sent me his minesweeper program so that I can fix some errors. But there's a few parts that I can't get. He wants the user to enter the number of mines for every game and right now, I have a GUI text field for that but whenever it gets to the screen where it's supposed to show, it doesn't and the picture which he is using as the background doesn't show either. The other thing is a check for when the user wins. the one my friend had works on most possibilities except when there's only 1 that's not a mine, I'm not sure how to check for that one.
And if you know how to clear a text field, that'd be really helpful too. Right now, whenever the game restarts, whatever the user enters in the previous game stays there. So for example, if they entered 1 for the number of mines the first time, and enter 2 the second time, the second game will have 12 mines. Though, if I can fix the first error, this wouldn't be a problem


What is the problem you are having?
So basically, there's a loading screen and after that is supposed to be a screen where the user enters the number of mines they want for that game.
But after the loading bar, the next screen doesn't show up and it looks like the program froze. But, the program is still running so if you type the number of mines you want and press enter, it will work normally after that. This also happens when you finish the game and want to start a new one.


Describe what you have tried to solve this problem
I tried getting rid of the GUI and using a get instead, but it's still the same.
I also tried making the picture into a GUI but that failed too :/

Please specify what version of Turing you are using
4.1.1



Minesweeper.zip
 Description:
I put a box around where the main problem is

Download
 Filename:  Minesweeper.zip
 Filesize:  1.69 MB
 Downloaded:  102 Time(s)

Sponsor
Sponsor
Sponsor
sponsor
Zren




PostPosted: Mon May 19, 2014 12:39 am   Post subject: RE:Minesweeper game bugs.

View.Set

Quote:

"nooffscreenonly", "offscreenonly" Causes or (suppresses) output from being sent to the visible window. When the offscreenonly option is active, any text and graphics output is drawn to the offscreen buffer that is maintained for every Run window but not drawn to the screen. View.Update is then used to copy the entire contents of the offscreen buffer to the Run window. By allowing numerous drawing commands to be sent to the offscreen buffer and then updating the window at one time, it is possible to get smoother animation.
MrMiaoMiao




PostPosted: Mon May 19, 2014 10:32 am   Post subject: Re: RE:Minesweeper game bugs.

Zren @ Mon May 19, 2014 12:39 am wrote:
View.Set

Quote:

"nooffscreenonly", "offscreenonly" Causes or (suppresses) output from being sent to the visible window. When the offscreenonly option is active, any text and graphics output is drawn to the offscreen buffer that is maintained for every Run window but not drawn to the screen. View.Update is then used to copy the entire contents of the offscreen buffer to the Run window. By allowing numerous drawing commands to be sent to the offscreen buffer and then updating the window at one time, it is possible to get smoother animation.



Wow...I never thought of that, thank you so much ^___^ Very Happy Very Happy
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 3 Posts ]
Jump to:   


Style:  
Search: