1.

What events does the MoleMash app respond to?

The MoleMash app responds to 3 events in total. The first is a Canvas.Touched event which is triggered when the user touches the screen. The second is an ImageSprite.Touched event which is triggered if the user touches the sprite. Finally the third is a Clock.Timer event which is triggered by the clock.

Show Answer

2.

What properties of an ImageSprite (or Ball) are used to record its location? What does each represent?

The location of an image sprite or ball is recorded in it's X and Y properties. X determines the horizontal location of the sprite and Y determines the vertical location of the sprite.

Show Answer

3.

What is the purpose of the subtractions in the blocks below?

The subtractions in the MoveMole procedure are performed so that the image always stays completely on the Canvas. The X-Y location of an image sprite corresponds to its top-left corner, so if a large X or Y value is randomly selected, part of the image sprite might be to the right or below the canvas and thus not appear.

Show Answer

4.

Assume a Canvas has imageSprite1 on it. When the user touches imageSprite1, what events are triggered?

When ImageSprite1 (or any image sprite) is touched by the user, two events are triggered: ImageSprite1.Touched and Canvas.Touched.

Show Answer

5.

Sketch the blocks for a "countdown" app that:
a. Displays the number 10 (in label CountLabel) when the app begins.
b. Subtracts 1 from the number each second, so it shows 10, then 9, then 8, etc.
c. When the number reaches 0, the countdown stops.
d. When the user clicks the restartButton, 10 is redisplayed and the countdown restarts.


You may use the blocks below (you need not use all of them, and you can use some twice):