Kitty & Katty Development ◾ 103
Let’s start by implementing the splash screen then. We are going to
keep things extremely simple here (but you can of course let your imagi-
nation and artistic creativity run wild), so all we will have is a big text with
the game title and, possibly Kitty and Katty sprites.
Once we set this up,
we need to implement the most crucial component of the framework: its
We already used buttons in Moon Wolf, and, indeed, using buttons to
navigate from layout to layout is clearly the easiest route. However, we
won’t do that here. e reason is that the Button object is specic to the
Web and might not work on other platforms if later we decide to port and
wrap our HTML5 game by using other tools. Even if we are planning this
game to be a PC/web title only, it is always a good practice to keep as many
opportunities open as possible.
For this reason, we are going to make our own buttons by using
sprites, but there is also another aspect we should consider before
choosing our approach: web games can also be played in countless
different resolutions, and sprites may not always scale that well. To
work around this problem, Construct 2 offers the 9-patch object. A
9-patch image is subdivided in nine different areas, eight small ones
encompassing the edges and one big central one (Figure8.5), so when
we need to stretch the image to fit a different resolution, we can have
much finer control on each area and decide whether to “stretch” or
“tile” them (“tile” means repeating the same section over and over)
I’ll be using free PD art from www.clker.com.
FIGURE 8.4 Deciding the rst layout to load in the project properties.