mlmliner.blogg.se

Jumble words games
Jumble words games






We are setting the first parameter to True, so that will ensure that all the other windows created from this application has the same icon. root.iconphoto( ): We are using it to set the icon in the title bar for our application window.root.resizable( ): Here we are using it to prevent the users from resizing our main window.In our case the background color will be black. nfigure( ): We use this to specify the background color for our application.In our case, it will open at 100 points to the left and 0 points to the down from the top-left corner. root.geometry( ): We use this to specify at which location our application window will open.root.title( ): We use it to set the title for our application.

jumble words games

root = Tk( ): This is used to initialize our tkinter module.When the user presses the main close button in title bar, it will exit the loop. Our program will generate a new window when the variable is set to True. First we create a variable called running and set its value to True.Our program will also play different sound files on various events. If the user wants to terminate the game, they have to press the close button on the window. If the user wants to play the game again, they wait for 3 seconds, and the new window will open with new word.

jumble words games

Our program will not show the correct word or time taken if the user’s guess is wrong. If the user’s guess is wrong, then label will show a Lose image, and the entry widget will be cleared for to enter the word again. Our program will also show us the time taken by the user to guess the correct word. If the guessed word is correct, the label will transform its image to Win and the correct word will be shown to user. Now, to check if the guessed word was correct, the user has to press the check button. Now the user has to guess the actual word from the jumbled word provided and enter their guess in the entry widget. When the user runs the program, the user will see a jumbled word on the Tkinter window.








Jumble words games