# Sandbox.Gizmo.GizmoDraw.Grid

## Overload 1

```csharp
void Grid(GridAxis axis, float spacing = 32, float opacity = 1, float minorLineWidth = 0.01, float majorLineWidth = 0.02)
```

Draws a grid

### Parameters

- `axis` (`GridAxis`)
- `spacing` (`float`), default `32`
- `opacity` (`float`), default `1`
- `minorLineWidth` (`float`), default `0.01`
- `majorLineWidth` (`float`), default `0.02`

## Overload 2

```csharp
void Grid(GridAxis axis, Vector2 spacing = null, float opacity = 1, float minorLineWidth = 0.01, float majorLineWidth = 0.02)
```

Draws a grid

### Parameters

- `axis` (`GridAxis`)
- `spacing` (`Vector2`), default `null`
- `opacity` (`float`), default `1`
- `minorLineWidth` (`float`), default `0.01`
- `majorLineWidth` (`float`), default `0.02`

## Overload 3

```csharp
void Grid(Vector3 center, GridAxis axis, Vector2 spacing = null, float opacity = 1, float minorLineWidth = 0.01, float majorLineWidth = 0.02)
```

Draws a grid centered at a position

### Parameters

- `center` (`Vector3`)
- `axis` (`GridAxis`)
- `spacing` (`Vector2`), default `null`
- `opacity` (`float`), default `1`
- `minorLineWidth` (`float`), default `0.01`
- `majorLineWidth` (`float`), default `0.02`

Declared in [Sandbox.Gizmo.GizmoDraw](/api/Sandbox.Gizmo.GizmoDraw).
Assembly: `Sandbox.Engine`.
