User Guide

102
If you prefer to draw your own background then you can do this
in Scratch’s Paint Editor instead of importing your graphics in the
next section. Try to make the overall shape and design similar to
the image above, as this will help in later sections of the tutorial.
Importing the Background Graphics
To import each background sprite:
1. In the Sprite List, click Paint new sprite, and then
click Import.
2. Browse to your background file, click it, and then
click OK.
3. Click OK.
4. In the Sprite List, click your new sprite and then in
the Scripts Area, rename the sprite. For example:
L1M1 for the first sprite, L1M2 for the second, and
so on.
Hiding the Background on the Title Screen
The furthest position that a sprite of this size can move to the left
is -462. This means that a 480px-wide background sprite cannot
move far enough to the left to hide the last 18 pixels. The
furthest position that a sprite of this size can be positioned to the
right is 462. This means that the first 18 pixels of the image are
always visible.
These two 18-pixel-wide areas at the edge of the Stage cause
visible errors in the appearance of the scrolling and are hidden
later.
When the game starts, the title screen broadcasts the message
“StartGame”. At this point, the background sprites should not
be visible on the screen. You need to add a script to each
background sprite so that it hides when that message is
received. Make sure that when the background sprites are made
visible, that they are on the lowest layer. Do this by bringing each
sprite to the front, and then sending it back six layers.