Quick Start

beginner quick start

Terrain Grid System 2 · Quick Start

Quick Start (5 minutes)

Prerequisites: Unity 2022.3+ with any render pipeline. Import Terrain Grid System 2 from the Asset Store.

Step 1 — Import and Run Demo Scenes

  1. Import the asset into your project (or create a fresh project).
  2. Open the Demo folder and run the included scenes to explore common use cases.
  3. Examine the script attached to the Demo GameObject to understand how TGS properties and events work from code.
Tip: Demo scenes include a TerrainGridSystem instance (the prefab) and a Demo GameObject with a script that demonstrates key API usage.

Step 2 — Add a Grid to Your Scene

There are three ways to add the grid in the Editor:

MethodWhen to UseSteps
Menu 2D / non-terrain grids Go to GameObject > 3D Object > Terrain Grid System
Add Component Terrain or mesh-based terrain Select your terrain GameObject, click Add Component, search for Terrain Grid System
Prefab Manual setup Drag the TerrainGridSystem prefab from Resources/Prefabs into your scene, then assign the terrain reference

Step 3 — Add a Grid at Runtime

You can also instantiate the grid dynamically:

// Option A: Add component directly
TerrainGridSystem tgs = myTerrainGameObject.AddTerrainGridSystem();

// Option B: Instantiate the prefab and assign terrain
GameObject prefab = Resources.Load<GameObject>("Prefabs/TerrainGridSystem");
GameObject go = Instantiate(prefab);
go.GetComponent<TerrainGridSystem>().SetTerrain(myTerrainGameObject);

Step 4 — Basic Configuration

Once the grid is in the scene, configure these key properties in the Inspector:

  1. Topology — choose Hexagonal, Box, or Irregular
  2. Rows / Columns — set the grid dimensions
  3. Territories — optionally set the number of territories
  4. Highlight Mode — choose Cells or Territories for mouse interaction
URP Note: If the grid is not visible in URP, try disabling Depth Priming Mode in your Universal Renderer asset.

Next Steps

Was this page helpful?