# Grid Cell Indicator Visual Generator

The **Grid Cell Indicator Visual Generator** component is located in: <mark style="color:purple;">**SoulGames > Easy Grid Builder Pro 2 > Scripts > Grid Visuals Scripts**</mark> This component is very similar to the **Grid Area Visual Generator** component. However, it is only used in **Grid Cell Indicator Prefab** located in: <mark style="color:purple;">**SoulGames > Easy Grid Builder Pro 2 > Prefabs > Grid Cell Indicator.**</mark> This prefab is used in the **Buildable Object Selector** component's **Grid Cell Indicator** section. It displays a visual cell indicator that follows the mouse pointer and snaps to the nearest grid cell.

<figure><img src="/files/ZYjWzQuDZJuqtgABUYYy" alt=""><figcaption></figcaption></figure>

***

## <mark style="color:green;">General Settings</mark>

<table data-full-width="false"><thead><tr><th width="216">Property</th><th width="429.3333333333333">Function</th><th>Required</th></tr></thead><tbody><tr><td>Warp Around Surface Below</td><td>Enables warping of the generated visual indicator to align with underlying surfaces</td><td>No</td></tr><tr><td>Custom Warp Surface Layer Mask</td><td>Specifies which layers are eligible for surface warping</td><td>No</td></tr><tr><td>Raycast Above Offset</td><td>The height above the surface from which raycasting is performed to determine the Warp Surface</td><td>No</td></tr><tr><td>Space Between Visual and Surface</td><td>The distance between to offset the visual indicator from the detected surface (This is used for offsetting the visual slightly to prevent overlapping)</td><td>No</td></tr></tbody></table>

***

## <mark style="color:green;">Area Shape</mark>

<table data-full-width="false"><thead><tr><th width="216">Property</th><th width="429.3333333333333">Function</th><th>Required</th></tr></thead><tbody><tr><td>Shape</td><td>Defines the shape of the generated visual indicator area (Rectangle or Circle)</td><td><mark style="color:red;">Yes</mark></td></tr><tr><td>Cell Size</td><td>Specifies the size of each visual cell. (While this doesn’t have to match your Grid System’s cell size, it is recommended to keep them the same in most cases)</td><td><mark style="color:red;">Yes</mark></td></tr><tr><td>Width</td><td>Number of cells along the width of the visual shape</td><td><mark style="color:red;">Yes</mark></td></tr><tr><td>Length</td><td>Number of cells along the length of the visual shape</td><td><mark style="color:red;">Yes</mark></td></tr><tr><td>Radius</td><td>Radius for circular grid visuals (This is ignored for Rectangular shape)</td><td><mark style="color:red;">Yes</mark></td></tr></tbody></table>

***

## <mark style="color:green;">Gizmos</mark>

<table data-full-width="false"><thead><tr><th width="216">Property</th><th width="429.3333333333333">Function</th><th>Required</th></tr></thead><tbody><tr><td>Enable Gizmos</td><td>Toggles the display of debugging gizmos</td><td>No</td></tr><tr><td>Enable Simplified Gizmos</td><td>Displays a simplified gizmo representation (Better for editor performance)</td><td>No</td></tr><tr><td>Gizmo Color</td><td>Sets the color for the debug gizmos</td><td>No</td></tr></tbody></table>

{% hint style="info" %}
If the blue gizmos aren’t visible, ensure that **"Show Gizmos"** is enabled in your Scene view.
{% endhint %}

***

## <mark style="color:green;">Visual Settings</mark>

<table data-full-width="false"><thead><tr><th width="216">Property</th><th width="429.3333333333333">Function</th><th>Required</th></tr></thead><tbody><tr><td>Visual Material</td><td>Material applied to the visual indicator</td><td><mark style="color:red;">Yes</mark></td></tr><tr><td>Cell Image Texture</td><td>The texture used for each cell in the visual indicator</td><td><mark style="color:red;">Yes</mark></td></tr><tr><td>Cell Show Color</td><td>Color when the generated visual is visible</td><td><mark style="color:red;">Yes</mark></td></tr><tr><td>Cell Hide Color</td><td>Color when the generated visual is hidden</td><td><mark style="color:red;">Yes</mark></td></tr><tr><td>Cell Show Color HDR</td><td>Similar to the <strong>Cell Show Color</strong> property this one uses an emissive HDR color</td><td>No</td></tr><tr><td>Cell Hide Color HDR</td><td>Similar to the <strong>Cell Hide Color</strong> property this one uses an emissive HDR color</td><td>No</td></tr><tr><td>Color Transition Speed</td><td>Speed of color transitions between show and hide</td><td><mark style="color:red;">Yes</mark></td></tr></tbody></table>

{% hint style="info" %}
In the **Visual Material** property, custom materials cannot be used. Instead, you must use the specific material called **Grid Quad Shader Graph Material**, located in:\ <mark style="color:purple;">**SoulGames > Easy Grid Builder Pro 2 > Misc Assets > Materials**</mark><mark style="color:purple;">.</mark>

This material uses the **Grid Quad Shader Graph** shader, which is specifically designed for these components. If you need multiple versions of this material, simply duplicate it and use the duplicates with the **Grid Area Visual Generator** component.
{% endhint %}

{% hint style="info" %}
For the **Cell Image Texture** property, you can use any of the provided cell textures located in:\ <mark style="color:purple;">**SoulGames > Easy Grid Builder Pro 2 > Misc Assets > Grid Textures > Cell Textures**</mark><mark style="color:purple;">,</mark>\
or you can use any custom cell texture you’ve designed.
{% endhint %}

***

## <mark style="color:green;">Scrolling Noise</mark>

You can apply a **Scrolling Noise** effect to the generated visual indicator, similar to the functionality available in the **Visual - Object Grid** section of your **Easy Grid Builder Pro XZ / XY** components.

<table data-full-width="false"><thead><tr><th width="216">Property</th><th width="429.3333333333333">Function</th><th>Required</th></tr></thead><tbody><tr><td>Use Scrolling Noise</td><td>Enables scrolling noise textures on the generated visuals</td><td>No</td></tr><tr><td>Noise Texture</td><td>The texture used for noise</td><td>No</td></tr><tr><td>Texture Tiling</td><td>Tiling factor for the noise texture</td><td>No</td></tr><tr><td>Texture Scrolling</td><td>Scrolling speed and direction for the noise texture</td><td>No</td></tr></tbody></table>

{% hint style="info" %}
For the **Noise Texture** property, you can use any of the provided noise textures located in: <mark style="color:purple;">**SoulGames > Easy Grid Builder Pro 2 > Misc Assets > Grid Textures > Scrolling Noise Textures,**</mark> or you can use any custom cell texture you’ve designed.
{% endhint %}

***

## <mark style="color:green;">Example Use case</mark>

As mentioned earlier, this component is exclusively used with the **Grid Cell Indicator Prefab** in the **Buildable Object Selector** component. When using it, it is recommended to create a **Prefab Variant** to customize its values for your grid.

To create a prefab variant:

1. Locate the **Grid Cell Indicator Prefab** in:\ <mark style="color:purple;">**SoulGames > Easy Grid Builder Pro 2 > Prefabs > Grid Cell Indicator**</mark><mark style="color:purple;">.</mark>
2. Right-click the prefab and select <mark style="color:purple;">**Create > Prefab Variant**</mark><mark style="color:purple;">.</mark> This will create a new version of the prefab that you can customize.
3. In the new prefab, modify the **Grid Cell Indicator Visual Generator** component to fit your requirements.

The most important value to adjust is usually the **Cell Size**. Set it to match your grid system's **Cell Size**, and make any other changes necessary to align with your scene setup.

<figure><img src="/files/7gPW1eiJLS1WalNrlsPj" alt=""><figcaption></figcaption></figure>

Next, select the **Buildable Object Selector** GameObject located within the **Grid Managers** GameObject in your scene.

In the **Buildable Object Selector** component attached to this GameObject, locate the section for enabling the **Grid Cell Indicator**.

To enable this feature:

1. Check the **Enable Grid Cell Indicator** property.
2. Assign the **new prefab variant** you created to the **Grid Cell Indicator Prefab** property.

This setup activates the grid cell indicator functionality with your customized prefab variant.

<figure><img src="/files/egyLQQLFLVLq6EXwZxlN" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://soulgamess-studio.gitbook.io/easy-grid-builder-pro-2-documentation/secondary-components/grid-cell-indicator-visual-generator.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
