> For the complete documentation index, see [llms.txt](https://fehdead.gitbook.io/npc-kit/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/aturny.md).

# npc.aturny

```lua
npc.aturny(x, z)
```

|                         |                                                                         |
| ----------------------- | ----------------------------------------------------------------------- |
| id                      | `0x02D6`                                                                |
| arguments               | 2: Float, Float                                                         |
| in NPC Kit              | yes                                                                     |
| measured from a kit NPC | returns                                                                 |
| waits                   | it has a wait handler: it can hold the script, and in `talk` the player |
| vanilla scripts         | 143 calls in 23 of 1114 scripts                                         |

## What it does

Turns the NPC's body to face a ground point and points its head toward it, holding the script until the turn ends. [aturn](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/aturn.md) without the height: it takes only `x` and `z`.

## Arguments

### `x` (Float)

### `z` (Float)

The ground point, in map coordinates. The head look gets a height of `0.0`.

## Timing

Waits until the turn has ended.

## In NPC Kit

Vanilla's common use is a point at a fixed distance in a heading: `(math.sin(h) + x, math.cos(h) + z)` faces heading `h` from where the NPC stands.

## Used with

* [aturn](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/aturn.md): the same with a height for the head.
* [lookatoff](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/lookatoff.md): the head back to straight after.
* [turn](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/turn.md): the body turn only.

## Example

```lua
npc.aturny(21.9, 68.0);
```

## Pitfalls

* Two arguments, not three: a `y` in the middle shifts the point.
* The head stays on the point: [lookatoff](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/lookatoff.md) before a talk.
