Table of Contents

Constructor TerrainGridCreationContext

Namespace
Pinwheel.Vista
Assembly
Pinwheel.Vista.Runtime.dll

TerrainGridCreationContext(Vector2Int, Vector3, Transform)

Creates a validated grid description. Throws when any value would produce a degenerate grid, so an instance that exists is always usable by a backend.

public TerrainGridCreationContext(Vector2Int tileCount, Vector3 tileSize, Transform parent = null)

Parameters

tileCount Vector2Int

Number of tiles, x for columns and y for rows. Both must be at least one.

tileSize Vector3

Tile size in meters, x for width, y for height, z for length. Every axis must be positive.

parent Transform

Optional transform the grid is created under and pivoted on.

Exceptions

ArgumentException

Thrown when a tile count is below one, a tile dimension is not positive, or the texture density is not positive.