Skip to content

Fill Rect Pattern

Fills a rectangular tilemap region with a procedural two-tile pattern (checker, stripes, rings, or noise).

This is useful for quickly generating floors, wall trims, hazard zones, and stylized map variation.

Parameters

Parameter Description
Tilemap Target tilemap to paint.
Rect Rectangular area to fill.
Pattern Pattern type: Checker, Stripe X, Stripe Y, Diagonal, Rings, Diamond Rings, Square Rings, or Noise.
Tile A Tile used for A cells (can be empty to clear cells).
Tile B Tile used for B cells (can be empty to clear cells).
Cell Size Pattern block size (for example 1 = 1x1, 2 = 2x2 blocks). Not used by Noise.
Origin Mode Pattern alignment mode: Global Alignment, Local Alignment, or Custom Origin.
Custom Origin Custom cell origin when Origin Mode is Custom Origin.
Phase Extra offset applied to the origin to shift the pattern phase.
Period Stripe/ring spacing in cells. Not used by Noise.
Noise Threshold Threshold from 0 to 1 for Noise pattern. Used only by Noise.

How It Works

  1. Builds a scan region from Rect.
  2. Computes pattern origin and center from Origin Mode.
  3. Evaluates pattern per cell and chooses Tile A or Tile B.
  4. Applies all tile changes in one batch.

Tips

  • Leave Tile A or Tile B empty to carve holes/void cells as part of the pattern.
  • Use Global Alignment when you want patterns to continue seamlessly across adjacent regions.
  • Use Local Alignment to center rings/stripes within each filled rect.
  • Use Custom Origin plus Phase when you need deterministic alignment between multiple tilemaps.