Run the python interpreter, then directly
import roller, and run roller.main(). It will produce an initial
window like this:![]() |
After you click on the roll button, you'll see something like this:![]() |
Important Note: The first roll is done for you. In other words the dice come out with different, random values on them. This is a little different than the roller example where they all started at 1. You'll have to call the correct button method to do this, after you have created them of course, but before the while loop.
pt = win.getMouse() # get the next mouseclick # statements in here will process the results of the mouseclick while not (roll1 and roll2): # if both are True, condition is FalseThe program gets the next mouseclick, and processes it, as long as roll1 and roll2 are not both True. The body of the while loop is a big if-elif-else statement.
This homework is due by 11:59 pm Monday April 23.
After putting the documentation in (at the top and throughout), submit it by typingrsubmit homework9 hw9.py