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

# npc.questeffectread\_1db

```lua
npc.questeffectread_1db(slot, file)
```

|                         |                                   |
| ----------------------- | --------------------------------- |
| id                      | `0x01DB`                          |
| arguments               | 2: Int, Int                       |
| in NPC Kit              | yes                               |
| measured from a kit NPC | returns                           |
| vanilla scripts         | 2389 calls in 141 of 1114 scripts |

## What it does

Loads a quest effect file into one of the 32 script effect slots, to play it later with [effectplay\_e2](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/effectplay_e2.md). The load runs in the background: wait for it with [effectreadsync\_e1](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/effectreadsync_e1.md).

## Arguments

### `slot` (Int)

The slot, 0 to 31 (others are clamped). The 32 slots are shared by every script running, the map's too: vanilla uses 0 to 15 and 31, so a kit NPC is safest on 16 to 30.

### `file` (Int)

The quest effect file. Vanilla: `47` and `48` (a thousand calls each), `43`, `30` to `41`, `73`, `116`. What each file shows has no bundled table.

## Timing

Returns at once; the file loads on its own.

## In NPC Kit

Not tested on a kit NPC. A slot still holding an effect (read, played, or cancelled and not yet cleared by the game) ignores the read: cancel it with [effectcancel\_e4](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/effectcancel_e4.md) and give it a moment, or use another slot.

## Used with

* [effectreadsync\_e1](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/effectreadsync_e1.md): wait for the load.
* [effectplay\_e2](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/effectplay_e2.md): play it.
* [effectcancel\_e4](https://fehdead.gitbook.io/npc-kit/vm-reference/calls/effectcancel_e4.md): stop it.

## Example

The vanilla shape: read, wait for it, play part 0 and part 1, stop it at the end.

```lua
flash = function()
    npc.questeffectread_1db(16, 116);
    npc.effectreadsync_e1(16);
    npc.effectplay_e2(16, 0);
    npc.effectplay_e2(16, 1);
    npc.wait(90);
    npc.effectcancel_e4(16);
end,
```

## Pitfalls

* A read into a busy slot does nothing, with no error.
* Slots 0 to 15 and 31 are the map's: a kit NPC reading there can cut a map effect short.
