Skip to content

TileMapLayers and TileSets

Manuel Quiñones edited this page Mar 2, 2026 · 4 revisions

The layout and landscapes of the levels in Threadbare are primarily built out of a stack of TileMapLayer nodes. Each layer contains a different type of terrain or decoration, rendered on top of the layers below. As well as determining the level's physical appearance, certain tiles contain physics and occlusion layers that affect where the player-character can walk, where projectiles can float without bouncing, and where guards' torchlights can shine and detect the player-character.

Available TileSets

We have different TileSet resources for different kinds of landscape features, all stored in the res://tiles/ folder:

Resource filename Purpose
bridges.tres Bridges, and shadows under bridges
decoration.tres Decorations to place on top of cliffs
elevation_2.tres Cliffs
elevation.tres An older cliff TileSet which is harder to use. This will be removed once all scenes are updated to use elevation_2.
exterior_floors.tres Grass, dirt, and sand
foam_2.tres Foam, for where land meets water
shadows.tres Shadows cast by cliffs
void_chromakey.tres The Void, a starry backdrop of nothingness. This TileSet must be used together with a shader; see below.
water.tres It's wet.

Tip

If you are making a StoryQuest, the Create StoryQuest from Template… tool makes copies of all the tilesets listed above into the tiles/ subfolder of your StoryQuest folder.

TileSet-specific notes

Water and Bridges

Visually, there is only one water tile: a solid blue square. This tile has a physics shape in the non_walkable_floor layer that blocks the player from walking across it, but allows projectiles to cross it. Together with cliffs, this is the main way that we block out levels in Threadbare.

There are two alternatives of this tile, which you can choose between when drawing water:

image

They differ in the shape of their Physics Layer 2 (non_walkable_floor). While the base tile is fully covered on this layer, the first alternative has no physics, and the second is only non-walkable on its bottom half. It is a little hard to see in the TileSet editor because Godot draws the collision shapes in blue, and water is also blue:

image

The purpose of these alternatives is to make bridges work. You can see all three tiles in Fray's End. In the screenshot below, the tiles marked with a yellow box use the first alternative (no collision shape), so that you can walk across the bridge; while the tile marked with a red box uses the second alternative (collision shape at the bottom), so that you can walk up to the end of the bridge but no further:

image

Making a bridge can involve 5 or more layers working together:

  1. Water: use the water.tres TileSet. Use the appropriate alternative tile for the water tiles under the bridge; and use the base water tile elsewhere so that the player cannot walk over the water.
  2. Shadows: for horizontal bridges, use the bridges.tres TileSet, and draw shadow tiles under the appropriate square.
  3. Stone: if the bridge is above sea level, use 1 or more layers with the elevation_2.tres TileSet to draw the raised stone. Like water, you must use the appropriate alternative tile where the bridge meets land, so that the player can walk across it.
  4. Grass / Paths: generally you will use one or more exterior_floors.tres layer to draw grass, dirt, and paths layered upon each other
  5. Bridges: use bridges.tres and draw the actual bridge.

Foam

Whenever water meets land (or stone) you should use a Foam TileMapLayer, with the foam_2.tres TileSet, to draw foam. Place one tile of foam underneath the land/stone.

When the land is raised, bear in mind that the fake perspective means that the (invisible) top cliff meets the water 1 tile further down than the edge of the visible land. Look carefully at the island in this screenshot for an example:

image

Cliff shadows

Consistently add shadows below cliffs. Add a Shadows TileMapLayer, with the shadows.tres TileSet. One per cliff elevation.

cliff-shadows

Void

The PNG asset for the void_chromakey.tres TileSet looks like this:

Void_Tiles_Chromakey

In-game, it looks very different: it's a starfield that does not move when the camera moves, implying the stars are a great distance away:

image

This effect is achieved by configuring void_chromakey_material.tres as the TileMapLayer's Material. This material uses a shader to replace the red area of the texture with the starfield.

image

Clone this wiki locally