Game Development Reference
In-Depth Information
Note that you could also use a sprite with a gradient image; however, if you don't need
any more details other than the gradient itself, the Gradient Node is likely faster and def-
initely consumes a lot less memory.
Adding the main Background Sprite
There's also a background sprite provided with the topic's downloadable archive, named
level1_background_Cerberus.png . It's depicted in Figure 3-7 . It will be drawn
over the gradient and is slightly larger than the gradient. The larger a background layer or
image is, the faster it will parallax as the player moves across the level. As before, if you
prefer you can provide an image of your own creation provided that the image size
matches.
Figure 3-7 . Cerberus background image
Speaking of image sizes. Since SpriteBuilder assumes all images to be designed for iPad
Retina resolution by default, the image has to be correspondingly huge: 2375x1625 pixels.
SpriteBuilder will automatically create downscaled versions of the image for non-Retina
iPads and Retina iPhones (1188x813 pixels) and non-Retina iPhones (594x406 pixels). As
you can see, when scaled down to non-Retina iPhone point dimensions, the image is just
barely larger than the 4-inch iPhone's dimensions of 568x320 points.
Search WWH ::




Custom Search