# sm.noise.perlinNoise2d

A perlin noise 2d function.

**Kind:** Function

**Environments:** Game, Terrain

## Game

``` { .lua .api-signature }
sm.noise.perlinNoise2d( x, y, seed )
```

[Open the full Game reference](../Game-Script-Environment/Static-Functions/sm.noise.md#perlinnoise2d)

**Parameters:**

| Name | Type | Description |
| --- | --- | --- |
| `x` | number | The X value. |
| `y` | number | The Y value. |
| `seed` | integer | The seed. |

**Returns:**

| Type | Description |
| --- | --- |
| number | The noise value. |

## Terrain

``` { .lua .api-signature }
sm.noise.perlinNoise2d( x, y, seed )
```

[Open the full Terrain reference](../Terrain-Script-Environment/Static-Functions/sm.noise.md#perlinnoise2d)

**Parameters:**

| Name | Type | Description |
| --- | --- | --- |
| `x` | number | The X value. |
| `y` | number | The Y value. |
| `seed` | integer | The seed. |

**Returns:**

| Type | Description |
| --- | --- |
| number | The noise value. |
