Skip to content

Tutorials · Worlds and Levels · Chapter 3

Painting faster

45 minutes Uses: TileMap

By the end

  • A terrain, stone, made from the blob set in one press, and the halls east of the first hall painted with it, every edge the tile its neighbours call for
  • Their plain stone varied from a seed: cracked, mossy and worn stone at their Weights, 0.15, 0.10 and 0.05
  • A pattern, pillar, lifted with Pick, saved, and stamped along the halls on a layer of its own, the last one flipped
  • The halls’ back wall turned to wet stone with Replace inside a lift, the first hall’s left as it was
On this page

Faster than by hand

Chapter 2 painted the first hall’s stone cell by cell, reading each edge off the picker. The halls east of it are 960 units of floor, ceiling and wall with a pool and a pit dug in them: by hand, an afternoon. This chapter paints them with the Tilemap tab’s faster tools. No grey stand-in goes here, since the crypt had none; everything is on the crypt’s map, art/crypt.tilemap, and nothing else changes.

Which of them to reach for: a terrain for a mass of stone whose edges and corners should follow its shape; the Variety band for a fill that should not be one tile repeated; and a pattern for a piece placed again and again, such as a pillar.

A terrain

A terrain is a named set of tiles, each filed with the neighbours its art joins onto. Painting with it, the editor lays in each cell the tile whose neighbours match the cell’s, and lays them again round a stroke as it changes them. crypt-stone.png was drawn as a blob set: the 47 tiles a square wall needs for every edge and corner, in the order the editor knows, so one press files them all.

  1. Open scenes/crypt.ron, select halls, and click the Tilemap tab.
  2. In the Terrains band, type stone in the box, and press Add.
  3. Click the stone row: it lights, armed, and the band reads Painting stone.
  4. Under the held tile’s rows, 47-tile blob from reads #1, the lone block. Press Add blob.
The Terrains band: Painting stone; the stone row lit, with its rename and delete buttons; the box New terrain and Add; Paint tiles, Re-solve and The whole layer; then Tile #1: In stone: none, Joins onto: none, three by three squares with the lone block in the middle and none of the eight lit, Update in stone and Remove from stone; and 47-tile blob from #1 with Add blob
The Terrains band, stone armed: tile #1, the lone block, joins onto nothing.
The same band with tile #32 held: In stone: E SE S SW W, Joins onto: E SE S SW W, and of the eight squares round the tile the bottom three and the two at its sides lit
Tile #32, the floor’s top: stone west, east and below it, and nothing above.

Each of the 47 is filed with the neighbours its place in the set means: #47 with all eight, stone all round. The fill’s variety, cracked, mossy and worn stone, #49, #50 and #51, is filed by hand as full stone.

  1. Click tile #49 in the picker. In the Tile band under it, set Weight to 0.15.
  2. Click the stone row again: clicking the picker let go of the terrain. Click all eight squares round the tile, and press Add to stone.
  3. Do the same for #50, Weight 0.10, and #51, Weight 0.05. #47 keeps the 1 every tile comes with.

They are full tiles of the terrain, so they count as stone round their neighbours; a stroke never lays them, since where two tiles fit, the heavier, #47, wins.

A terrain
A named set of tiles in the map’s .tilemap, each filed with the eight neighbours its art joins onto. Armed, it is the brush: each cell a stroke touches, and each of their neighbours, gets the tile that fits. Square grids only: on another Grid the band is greyed and says why.
Arming a terrain
A click on its row in the Terrains band: the band reads Painting stone, and every tool lays the terrain. Paint tiles, or a click in the picker, goes back to the picked tile.
Add blob
Files 47 tiles into the armed terrain at once, from the tile 47-tile blob from names, the lone block, each with the neighbours its place in the blob set means.
The held tile’s eight squares, and Add to stone
Round the held tile, its eight neighbours: click one to say the tile’s art joins onto it, and Add to stone files the tile so; Update in stone and Remove from stone once it is filed.
Re-solve
Gives walls painted by hand their edges and corners: every cell of the terrain on the lit layer is laid again with the tile its neighbours call for, over the whole layer, or over a block lifted with Pick, as the line beside it says. One step to undo.

The halls

With stone armed, on ground, the tools of chapter 2 lay stone that joins itself. The halls run east of the first hall, x 640 to 1600, its floor down to the first hall’s depth and its ceiling 64 thick.

  1. Click ground’s row. In the Tools band, set Size to 2: a wide brush paints a square of cells, 2 by 2, at each step of the drag.
  2. With Erase, drag down the first hall’s east wall, columns 40 and 41, from the ceiling to the floor: it opens, and the floor and the ceiling it leaves are laid again with their edges.
  3. Paint the rest from the table, each with the tool it names, at the Size it names.
PieceCells (column; row)World (x; y)How
the first hall’s east wall, opened40 and 41; -12 to -1640 to 672; -192 to 0Erase, Size 2
the halls’ floor40 to 99; 0 to 6640 to 1600; 0 to 112Rect
the halls’ ceiling40 to 99; -16 to -13640 to 1600; -256 to -192Rect
the east wall100 and 101; -16 to 61600 to 1632; -256 to 112Rect
the pool, dug50 to 63; 0 to 2800 to 1024; 0 to 48Erase, Size 3
the pit, dug74 to 79; 0 and 11184 to 1280; 0 to 32Erase, Size 2

The pool is sunk 48, the floor under it, 64 deep, its bed; the pit is sunk 32, its bed 80 deep. Every stone cell is now the tile of the set its eight neighbours call for: a cell with a gap beside it is that edge’s tile, and one with stone all round is #47.

The crypt at 200%, the halls’ west end: the first hall’s dark back wall at the left, the halls’ blue-grey wall, the first pillar on the floor, and in the air over the pool a block of stone ten cells by four with a mossy top edge, its sides and its four corners each a different edge tile; the Tools band, Rect lit, and ground’s row lit
One Rect with stone armed, on a copy: the block’s top, its sides and its corners each the tile that fits.
The Tools band’s Size, a wide brush
The brush’s width in cells, 1 as it comes; [ and ] step it while painting. A wide brush paints a square of cells at each step, Size by Size, and so does the eraser.

A fill that varies

Plain stone, #47 in every cell, reads as wallpaper. The Variety band paints from a set of tiles instead, one per cell, chosen by weight. It comes after every terrain stroke on ground: a later stroke would lay a varied neighbour back to #47.

  1. Click #47 in the picker, and press Set in the Variety band.
  2. Click #49, press Set again, then Add #49. Picking a tile lets go of the set, so each Add comes after a Set: do the same for #50 and #51.
  3. Type 7 in Seed.
  4. With Fill, click the halls’ ceiling, then their floor.
The Tile band for tile #49, Cell 49 of 64: Tint, Art origin, Z offset, Y sort and Weight 0.15; Animation and Data empty; Scene none and Draws as #49; the Terrains band reading Painting tile #49; and the Variety band: Tile lit, Set and Scatter; Add #49 and its line, Pick tiles and add them, the brush draws one per cell; Every 3, Chance 0.50 and its line; Seed 7 and Reroll
Tile #49 held: its Weight, 0.15, in the Tile band, and the Variety band under it, Seed 7.

The floor runs on under the pool and the pit and west under the first hall’s floor, now as deep, so the Fill rolls that too, and the stone of the stair and the west wall it runs into: 572 cells rolled, 361 of the halls, 205 of the first hall’s floor and 6 on the stair and the west wall, of which 116 vary. #47 is the most of them, and #49, the heaviest of the three, comes up more often than #51.

A tile’s Weight
In the Tile band: how often the tile comes up in a set, against the others’ weights; 1 as a tile comes, 0 never. It is saved in the map, and it is the weight the tile joins a set with.
The Variety band’s Set
The brush paints one tile of the set per cell, by weight. Its rows list each tile, its weight, which can be changed there, and its share. Picking a tile in the picker goes back to Tile, the picked tile in every cell.
The Variety band’s Add
Add #49 puts the picked tile in the set, at its own weight. It shows while the picked tile is not in the set.
The Variety band’s Seed
Every random brush rolls from it and the cell, so the same seed and the same strokes make the same room, and a redo gives back the room that was undone.
The Variety band’s Reroll
A new seed: a different room from the same strokes.
The Variety band’s Scatter
The third brush: a block held from the picker or lifted with Pick, laid on a lattice Every so many cells, some of the time, Chance. Like a wide brush’s, its footprint is a square of cells. Hollowmere does not use it.

Pillars from a pattern

Pillars stand along the halls, on a layer of their own behind the rest. One is painted with the terrain, then saved as a pattern and stamped.

  1. Click back’s row, and press + under the rows: an empty layer goes in over back, second in the file, and the painter moves onto it. Double-click its name, rename it pillars, and set its z to -1. It is not Solid, as a new layer comes.
  2. Click the stone row in the Terrains band to arm it again: the Variety steps’ clicks in the picker let it go.
  3. Set Size in the Tools band back to 1.
  4. With Rect, a pillar two cells by four at cells 40 and 41, rows -4 to -1: x 640 to 672, y -64 to 0, where the first hall’s east wall stood.
  5. With Pick, drag over the pillar: it is lifted. In the Tools band, press Save as pattern…, type pillar, and press Enter.
  6. Press Tile in the Variety band, which lets go of the terrain: an armed terrain would lay a stamp’s cells again, and set a flipped one upright.
  7. With Stamp and Merge, click with the pattern’s top-left on cell 70, -4, x 1120, then on 80, -4, x 1280, on the pit’s east lip.
  8. Press Flip X, and stamp it on 90, -4, x 1440.
The Tools band with pillar chosen: Stamp lit; Size 1; the F, Flip X, Flip Y, Rotate and upright; 2x4, 8 tiles, Merge lit and Overwrite; Patterns pillar with rename and delete buttons; Save as pattern…; Replace and Pick a painted cell first
The pattern pillar, chosen: two cells by four, eight tiles, Stamp and Merge.
The crypt at 200%: the first pillar on the floor at the halls’ west end, and a second beside it, its mirror; the Tools band, Stamp and Flip X lit, the F drawn mirrored, 2x4, 8 tiles, Merge lit; pillars’ row lit
A pillar stamped with Flip X on a copy, beside the first: its mirror. The page’s own flipped one is at x 1440.
PillarTop-left cellWorld (x; y)
painted40, -4640 to 672; -64 to 0
stamped70, -41120 to 1152; -64 to 0
stamped80, -41280 to 1312; -64 to 0, on the pit’s east lip
stamped, Flip X90, -41440 to 1472; -64 to 0

Every pillar stands on the floor, and none over the pool, where chapter 4’s ledges run. A block need not come off the map: drag across the picker, and the tiles you drag over are held as a block, as Pick holds a lifted one.

The Tools band with a block held from the sheet: Stamp lit, 4x1, 4 tiles, Merge lit and Overwrite, Patterns Choose…, Save as pattern…; the Layers band; the Tileset band folded; and the picker, the four water tiles in its seventh row outlined
A block from the picker: the four water tiles, held to stamp. The Tileset band is folded by a click on its head, which brings the picker up.
The Tools band with Rotate pressed once: Brush lit, Size 1, the F turned a quarter clockwise, Flip X, Flip Y, Rotate and the readout 90 cw; Replace and Pick a painted cell first
Rotate pressed once: the F turned a quarter clockwise, the readout 90 cw.

The readout beside the buttons counts Rotate’s presses alone: upright, 90 cw, 180, 270 cw. The F at the row’s start shows how the tile will land with the flips as well, and its hover says so in words. Press Flip Y alone and the readout still says upright, since Rotate was not pressed, while the F stands on its head, its bar to the right, and the hover says 180 mirrored: a flip top to bottom is a half turn and a mirror together.

The picker’s block
A drag across the picker holds the tiles it covers as a block, and arms Stamp, as Pick holds a block lifted off the map. A click on one tile holds that tile for the brush.
Save as pattern…, and a pattern
Files the held block on the sheet under a name, typed into the field that opens: a pattern, saved in the .tilemap. The Patterns list beside Stamp holds the sheet’s patterns; choosing one holds it, with Stamp armed. Its diamond button renames the chosen pattern, and its bin deletes it, which Ctrl+Z brings back.
Stamp: Merge and Overwrite
Puts the held block down, its top-left on the cell clicked. S. Merge leaves what is under the block’s empty cells, a shelf hung on a wall; Overwrite clears them too, for a piece whose own empty space is part of it.
Move
Slides a lifted block somewhere else: it leaves its cells and lands where the drag ends. M.
Flip X and Flip Y
Mirror the tile as it is laid, left to right or top to bottom, and the held block with it, which mirrors where its cells stand as well as their art.
Rotate
A quarter turn clockwise, the tile and the held block, at each press; R in Paint mode. Four presses come back upright.

The wet back wall

The halls’ back wall is wet stone, #58, where the first hall’s is dry, #48. It is laid as the first hall’s, then swapped inside a lift, so the first hall’s stays as it was.

  1. Click back’s row. With Pick, click the first hall’s back wall: the picker holds #48.
  2. With Rect, lay it behind the halls, columns 40 to 99, rows -12 to -1, and one Rect down into each hollow, the pool’s and the pit’s.
  3. With Pick, drag over the halls’ back wall, the hollows with it: it is lifted, and the Tools band names it under Replace.
  4. With Pick, click a cell of #48, which is what to swap from. Click #58 in the picker, the wet stone. Press Replace. Press Ctrl+S.
The Tools band: Pick lit and its line, click reads a cell into the brush, drag lifts a block out; Replace, with #48 -> #58 beside it, and under it Holding the 60x15 block lifted from back. Esc in Paint mode drops it; then the Layers band, back’s row lit
A lift from back, sixty cells by fifteen: Replace will swap #48 for #58 inside it.

The halls’ 774 cells become the wet stone, and the first hall’s back wall stays #48, every cell. The status line says which cells a Replace took: the lifted ones, or the whole layer.

A part of the game in the crypt: the first hall’s dark brown brick back wall at the left meeting the halls’ blue-grey wet stone at the right, the first pillar standing at the join, the pilgrim in front of it, and under them the floor, its mossy top and its stone
Where the first hall’s back wall meets the halls’: #48 and #58.
Replace
Swaps every cell of the tile Pick last read for the tile the picker holds, in one step: inside the block lifted from the lit layer, or over the whole layer when nothing was lifted from it. The line beside it reads #48 -> #58; before a Pick it reads Pick a painted cell first.
A lift, and Esc
A block lifted with a Pick drag stays held, and the Tools band names it under Replace, Holding the 60x15 block lifted from back. It narrows Replace and Re-solve on its own layer only: a block lifted from pillars leaves a Replace on back the whole layer. Esc, in Paint mode, lets go of it.

The halls, painted

The crypt’s halls selected and framed at 49.3%: the first hall at the left with its stair and dark back wall, the halls to the right with their blue-grey wet wall, four pillars on the floor, the pool and the pit dug in it, the ceiling thicker over the halls; the Inspector shows the map’s TileMap: Tilemap crypt.tilemap, Tile Size 16 and 16, Grid Rectangle, Sort Layer Ground, Collision ticked
The crypt, east to x 1632: the first hall and the halls, painted.

Every edge of the halls is the tile its neighbours call for, and every cell with stone all round is #47 or one of the three. He can walk them end to end: from where he comes in, D held and Space tapped each second take him through where the first hall’s east wall stood, down into the pool and out of it, over the pit, and past x 1560, by the halls’ east wall, within twelve seconds, never lower than the pool’s floor, y 48.

The crypt’s map

WhatWhereValue
terrain stoneTerrains bandthe blob set from #1, and #49, #50 and #51 with all eight neighbours
WeightTile band#49 0.15, #50 0.10, #51 0.05; #47 1
the fillVariety bandSet of #47, #49, #50, #51; Seed 7
pillarsLayers bandsecond in the file, z -1, not Solid
pattern pillarTools bandtwo cells by four, from the painted pillar
backthe halls#58, 774 cells; the first hall’s #48

Check it works