# Installation

Add the resource, import the database table and start it in the right order.

## 1. Add the resource

Place the `wd_rememberme` folder in your server's `resources` directory, for example `resources/[wolfden]/wd_rememberme`. **Do not rename it**; exports use the folder name.

## 2. Create the database table

Wolfden Remember Me does not create or change tables by itself. Import the included [`sql/install.sql`](reference/wd_rememberme/sql/install.sql) once into the database used by oxmysql:

```sql sql/install.sql
-- Wolfden Remember Me by Wolfden Studio. Import once into the framework database.
CREATE TABLE IF NOT EXISTS `wolfden_rememberme` (
  `id` INT UNSIGNED NOT NULL AUTO_INCREMENT,
  `observer` VARCHAR(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL,
  `remembered` VARCHAR(191) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL,
  `alias` VARCHAR(64) NOT NULL,
  `note` VARCHAR(500) NOT NULL DEFAULT '',
  `created_at` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updated_at` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`),
  UNIQUE KEY `observer_remembered` (`observer`, `remembered`),
  KEY `remembered` (`remembered`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
```

Each row is one character's memory of another character. Aliases and notes support any language and emoji.

Updating an existing install? Run any database changes listed for your version in the [Changelog](#/docs/wd_rememberme/changelog?section=database) instead of importing the file again.

## 3. Add it to server.cfg

Turn on OneSync, and start Wolfden Remember Me **after** oxmysql, your framework, your appearance resource and, if you use them, ox_lib and your target resource:

```cfg server.cfg
set onesync on
ensure oxmysql
ensure ox_lib             # only if something you run needs it
ensure qbx_core           # or qb-core / es_extended
ensure illenium-appearance
ensure ox_target          # optional
ensure wd_rememberme
```

On ESX, start `skinchanger` and `esx_skin` (or your supported replacement) in place of illenium-appearance.

If the framework or database is not ready yet, the resource waits instead of failing: the server console shows `Startup waiting: …` and it retries every 5 seconds.

## 4. Choose your setup

Open `config.lua` and check these five settings:

```lua config.lua
Config.Framework = 'auto'     -- or 'qbox', 'qb', 'esx'
Config.Appearance = 'auto'    -- or your appearance resource's name
Config.Locale = 'en'          -- language file in locales/
Config.UI = 'builtin'         -- or 'ox_lib'
Config.Target = 'none'        -- or 'ox_target', 'qb-target'
```

- **Framework.** `auto` works when exactly one supported framework is running. Name it explicitly if you also run a compatibility or migration resource.
- **Locale.** Everything players see is in English by default. To use another language, add a file to `locales/` as described in [Translations](#/docs/wd_rememberme/configuration?section=translations).
- **UI.** `builtin` is the memory book shown to players, with no extra dependency. `ox_lib` uses ox_lib's dialogs and needs ox_lib started first.
- **Target.** `none` keeps it to commands. With `ox_target` or `qb-target`, players also get **Remember / rename person** when they target another player.

Every other setting is in [Configuration](#/docs/wd_rememberme/configuration).

## 5. Add your own clothing

Masks work out of the box on the freemode models. If your server has helmets, glasses, face-hiding tops, fake beards or wigs that should affect recognition, add them now. See [Masks & disguises](#/docs/wd_rememberme/clothing).

## 6. Restart and test

You need two players for this; a friend or a second account both work.

1. Restart your server.
2. Check the server console. You should see `Framework bridge: qbox` (or your framework) and no `Startup waiting` line.
3. Stand close to the other player, look at them and type `/remember`. Save them under any alias.
4. Hold **Left Alt**. Your alias appears over their head. Release the key and it disappears.
5. Ask them to put on a mask. Holding the key now shows **Face covered**.
6. Type `/memories` to see the person you saved.

If something does not appear, see [Troubleshooting](#/docs/wd_rememberme/troubleshooting).
