08.11.2012 Views

Designing Games with Game Maker - YoYo Games

Designing Games with Game Maker - YoYo Games

Designing Games with Game Maker - YoYo Games

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

• Clear. Clear the image to the left color (which then automatically becomes the<br />

transparency color).<br />

• Gradient fill. With this command you can fill the image <strong>with</strong> a gradually changing<br />

color (not very useful for making sprites, but it looks nice, and can be used for<br />

backgrounds, which use the same paint program).<br />

Note that more fancy drawing routines are missing. For this you should use a more advanced<br />

drawing program (or simply the paint program that comes <strong>with</strong> Windows). The easiest way to<br />

do this is to use the copy button to put the image on the clipboard. Now in your painting<br />

program, use paste to get it. Change it and copy it to the clipboard. Now, in <strong>Game</strong> <strong>Maker</strong> you<br />

can paste the updated image back in.<br />

Advanced sprite settings<br />

In advanced mode, in the sprite properties form there are a number of advanced options that<br />

we will treat here.<br />

First of all there are options related to collision checking. Whenever two instances meet a<br />

collision event is generated. Collisions are checked in the following way. Each sprite has a<br />

bounding box. This box is such that it contains the non-transparent part of all the subimages.<br />

When the bounding boxes do overlap, it is checked whether two pixels in the current<br />

subimages of the two sprites overlap. This second operation is expensive and requires extra<br />

memory and preprocessing. So if you are not interested in precise collision checking for a<br />

certain sprite, you should uncheck the box labeled Precise collision checking. In this case<br />

only bounding box checking is performed. You can also change the bounding box. This is<br />

hardly ever required but sometimes you might want to make the bounding box smaller, so<br />

that collisions <strong>with</strong> some extending parts of the sprite are not taken into account.<br />

The edges of sprites can look a bit blocky. To avoid this you can check the box labelled<br />

Smooth edges. In this case pixel at the edges of the sprite (that is, pixels that are neighbors<br />

to transparent pixels) are drawn partially transparent. This can make them look a lot nicer.<br />

(Don't use this when the sprites need to match up to form larger shapes because in that case<br />

a partially transparent line will appear between the parts.) The effect of this setting is only<br />

visible in the game, not in the editor!<br />

During gameplay, sprites are turned into textures. Textures must be moved to video memory<br />

(on the graphics card) before they can be used. When the box Preload texture is checked

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!