Name: __________________
Objective: Objectdraw input
You will add input processing to your Jack-o-Lantern
Instructions
-
Open your Jack project.
-
If you haven't already done so, add a sun and moon. The moon comes out when it’s night, the sun comes out when it’s day.
-
Add an onMouseClick() method that does the following:
-
If the user clicks on a facial feature, change the feature’s color to yellow.
-
If the user clicks on the pumpkin, change all facial features to black
-
If the user clicks on the background, move the sun or moon to the clicked location.
-
Add an onMouseEnter() method that turns the scene to night.
-
Add an onMouseExit() method that turns the scene to day.
-
Print your source code and hand in with your grading sheet.
Extra credit for
-
Additional points might be given for cool stuff.
Grading
|
|
Points
|
Extra
|
Correct
|
Incorrect
|
Notes |
|
Facial feature click
|
5
|
|
|
|
|
|
Pumpkin click
|
5
|
|
|
|
|
|
Enter and exit window
|
5
|
|
|
|
|
|
Other cool stuff
|
|
|
|
|
|
|
Total points
|
15
|
|
|
|
|
Notes
Comments (0)
You don't have permission to comment on this page.