6. Sensor Blocks
You may have noticed a couple of blocks at the bottom of Motion palette. The and
are called sensor blocks.
Sensor blocks tell you something about the state of your program or computer. Click on the gray boxes to the left of these sensor blocks, and then look over to the stage. You will see that the values of these sensor blocks are displayed in the upper left corner of the stage.
The and the
will tell you the position of your sprite on the screen. Move the sprite around and the values of these blocks change.
Besides looking to the stage for viewing the values of these sensor blocks, you always click on the sensor blocks in the palette, or drag them out to the scripting area and click on them there.
You will see more sensing blocks in the future. Sensing blocks fall under a category of blocks that we call "reporters" because these blocks have something to report to you. These blocks will always be rounded (not rectangular shaped).