Level designed using the tile sets layered in a variety of ways.

Pixel Art 3C: Tile Permutations In GraphicsGale

Grade 4 - Grade 6

Section Navigation
Ian MacLean

Ian MacLean

About the author

Ian MacLean is a professional pixel artist/animator and illustrator who has worked in the gaming industry for 16 years. He considers himself a super nerd and has the polyhedral dice, comic collection, and miniatures to prove it.

Art & Design, Computer Fundamentals
Lesson Plan

In the series: Pixel Art

Introduction

Tilesets used within video games seldom function as purely standalone objects. Variety within an environment requires variants and permutations of tiles where they interact with one another. Building an entire area using a basic tile, even a seamlessly tiling one, is a quick way to develop in-game environments, but it would yield a visually uninteresting result. Permutations allow varied shapes to be created in areas where one type of tile connects with another, often to make environments look more natural, or to establish clear boundaries between environment types.

Learning Goals

Students will learn about the function of tiles within a game and how to create their own. Building on techniques acquired in previous modules they will build important game framework tiles. Students will also learn how to work with layers and transparency within the image creation software GraphicsGale.

Vocabulary

Tile
A modular graphic used to construct scenic elements in a game.
Tileset
A full group of tiles containing all of the scenic elements for a game or a game section.
Seamless Tiles
A tile, or group of tiles, which are placed adjacently without any visual indication where one ends and the next begins.
Layer
A transparent “level” in a graphics editor file which allows separate images or elements to be created and manipulated in the same canvas space, without affecting the other elements.
Transitional Tiles
Tiles used in areas where two or more different environmental textures meet.
Permutations
A set of variant tiles within a tileset that allow for multiple arrangements.

Guiding Questions

  1. What is a transition?
  2. Where can you find transitioning textures in nature?
  3. How many combinations of lines can you form with two equal-sized, perpendicular lines?

Curriculum Links

This module aligns with Art, Computers, and Technology curriculums through the learning of new software and ways of creating graphical game elements.

Materials

Non-Computer Activity

Popsicle-Stick Permutations

Basic geometric permutations for top-down tilesets often use very standard shapes. By gluing popsicle sticks together you can create some permutation pieces to create a miniature map, which could become a template for level design. The basic shapes you’ll often use are as follows:

Permutation pieces (wall, hall, corner, end, and block) made out of popsicle sticks.

Computer Activity

Creating Tile Permutations and Transitions

Tiles will usually be used in conjunction with many other tiles and textures to create a varied environment. Transitional tiles are often used where two tile textures meet, where one type of tile either blends to another tile, or where a defined edge between the two is present. These transitional tiles require multiple permutations, to accommodate the different possible arrangements they may need to indicate.

As in previous modules where we made seamless tiles, we will use a 48×48 canvas, but will also use Layers to keep the tiles separate. Go to File>New (CTRL+N) to create a new canvas, set to 48×48 and 16bit colour (so the indexed palettes of both the grass and brick tiles aren’t lost). Import the grass tile PNG by going to Edit>Import, selecting the file, and dragging it to the centre square. Click the Add Layer button and import your brick tile in the same manner.

Newly created canvas with brick and grass layer imported.

Select the layer with the brick tile and use the Rectangular Selection tool to select it. Copy and Paste (CTRL+C/CTRL+V) your brick tile and drag them so that they surround the grass tile.

Canvas with grass title at the center surrounded by duplicated brick tiles.

With the bricks layer still selected, use the Pencil Tool to draw some edge trim around the grass tile, 5 pixels deep. Since the previously indexed palette choices aren’t shown in the palette, simply right-click to sample the colours directly from the canvas. Add shadows on the bottom and right sides of the brick trim to give the appearance of depth.

Canvas with centered grass tile surrounded by brick tiles and added trimmed edge around the grass.

We now have eight unique permutations of the original brick tiles. These will work as transition tiles for any other terrain type, not just grass. To save each of these permutations use the Rectangular Selection tool to select the top-left tile, go to All Frames>Crop, then File>Save As. Give the tile a name that references how it is used. This one is trim for a northwest corner, so something such as “brick_nw.png” is appropriate. After saving this tile, Undo (CTRL+Z) to return to the state prior to the Crop action. Select the next tile, crop, save it, undo the crop and repeat for all eight permutations of the brick tile.

Top left permutation of bricks.

After saving all eight of these new brick edge tiles, we need to make four more, to account for both inside and outside corners. Select the brick tiles in the centre on the top, bottom, left, and right, and delete them (press the Delete key or go to Edit>Delete). Select the grass tile layer by left-clicking it in the Layers panel, then copy and paste the grass tile into the empty spaces left by the deleted brick tiles. Re-select the brick tile layer by left-clicking it in the Layers panel, then draw the same 5 pixel deep trim along the edges where the brick tiles meets the grass tiles. Add shadows and highlights to give depth to the trim.

Four new permutations created to account for both inside and outside corners.

Now we have 12 permutations created which will allow two different tile types to interact in a variety of situations. To make the appearance of different tile materials existing in the same space more natural, we will create some permutations of the grass tile, by adding a shadow cast by the brick tiles. Starting with the current tile arrangement, select the grass tile layer and use the Pencil Tool to right-click the dark colour from the grass tiles. Draw over the medium green pixels in the two rows/columns beside the right and bottom edges of the brick tiles. Select the medium green colour from the grass tiles and colour the lighter green pieces in this shadow area.

All inside and outside permutations with added shadow cast from the bricks.

Select, crop, save, and undo for all five of these shadowed grass tiles. There’s one more shadowed tile to create for where grass meets brick on the top and left sides, simply add a shadow two pixels deep along the top edge of the top centre grass tile. Select, crop, and save this one and we’re done! Now you can use your tilesets to make a variety of level designs. Here’s just one example of what could be created:

Level designed using the tile sets layered in a variety of ways.

Conclusion

Tilesets don’t exist independently, they interact with a variety of other tile types. Combining those tile types without creating jarring artificial connections requires transitional tiles and a full set of permutations to accommodate a variety of possible arrangements. Understanding how tile permutations work helps to better plan required assets when developing a game or program that requires a tiled background.

Resources

Additional Resources

Social Media Resources

Previous In Series

Next In Series