> 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/mesopenspeed_1b.md).

# npc.mesopenspeed\_1b

```lua
npc.mesopenspeed_1b(slot, open, close)
```

|                         |                                  |
| ----------------------- | -------------------------------- |
| id                      | `0x001B`                         |
| arguments               | 3: Int, Int, Int                 |
| in NPC Kit              | yes                              |
| measured from a kit NPC | returns                          |
| vanilla scripts         | 1513 calls in 16 of 1114 scripts |

## What it does

Sets how long window `slot`'s next window takes to open and to close.

## Arguments

### `slot` (Int)

The window slot, 0 to 7.

### `open` (Int)

The opening time, in units of about 33 ms; `0` at once.

### `close` (Int)

The closing time, in the same units.

Vanilla: `(0, 6, 6)` 652 times, `(0, 0, 0)` 621, `(6, 15, 15)`.

## Timing

Returns at once.

## In NPC Kit

**Use the `openSpeed` and `closeSpeed` fields of `dialog.*`** (milliseconds) for the kit's windows.

## Used with

* [amese](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/amese.md), [aaske](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/aaske.md) in vanilla.

## Example

The kit form of vanilla's `mesopenspeed_1b(0, 0, 0)` before a line: a window that pops open and shut at once.

```lua
local boo = [[
Boo! Ha, you should have seen your face just now.
Don't worry, I only scare the ones I like best.
]]

npc.lua(function(handle)
    if not dialog.amese.open {
            speaker = "NPCKit 0020",
            body = boo,
            openSpeed = 0,
            closeSpeed = 0,
            queue = true,
            onClose = function() handle.finish() end,
            onError = function() handle.finish() end
        } then
        handle.finish()
    end
end);
```
