# Vec3.abs

Returns a vector of only positive values by taking the absolute value of each component in the input vector.

**Kind:** Function

**Environments:** Game, Terrain

## Game

``` { .lua .api-signature }
vec3:abs(  )
```

[Open the full Game reference](../Game-Script-Environment/Userdata/Vec3.md#abs)

**Parameters:**

| Name | Type | Description |
| --- | --- | --- |
| `v` | [Vec3](../Game-Script-Environment/Userdata/Vec3.md) | The vector. |

**Returns:**

| Type | Description |
| --- | --- |
| [Vec3](../Game-Script-Environment/Userdata/Vec3.md) | The absolute value vector. |

## Terrain

``` { .lua .api-signature }
vec3:abs(  )
```

[Open the full Terrain reference](../Terrain-Script-Environment/Userdata/Vec3.md#abs)

**Parameters:**

| Name | Type | Description |
| --- | --- | --- |
| `v` | [Vec3](../Terrain-Script-Environment/Userdata/Vec3.md) | The vector. |

**Returns:**

| Type | Description |
| --- | --- |
| [Vec3](../Terrain-Script-Environment/Userdata/Vec3.md) | The absolute value vector. |
