# Configuration
Amplifier has two files in `plugins/Amplifier/`, and they do different jobs:
- **`config.yml`** is the one you'll actually use. Voice behaviour, storage, messages.
- **`loader.yml`** decides which build of the plugin gets downloaded. You'll rarely touch it.
Both are written for you on first start.
Changed `config.yml`? Run `/amplifier reload`. Changed `loader.yml`? You'll need a restart, because it's only read while the plugin is loading.
## Voice chat
```yaml
voice-chat:
max-distance: 48
enabled: true
debug: false
cross-dimension: true
```
| Setting | Default | What it does |
|---|---|---|
| `max-distance` | `48` | How far a voice carries, in blocks |
| `enabled` | `true` | Turn this off and only players with `lodestone.amplifier.bypass` can talk |
| `debug` | `false` | Extra logging, for when something isn't working |
| `cross-dimension` | `true` | Whether players in a group hear each other across different worlds |
## Remembering settings
```yaml
persistence:
enabled: true
```
With this on, someone's pitch and volume survive a restart. Turn it off and everyone starts fresh each boot.
## Where settings are saved
Set `storage.type` to `LOCAL`, `MYSQL` or `MONGODB`.
### Local files
The default. Nothing to set up.
```yaml
storage:
type: "LOCAL"
```
### MySQL
For when you already run MySQL, or you want several servers sharing the same settings.
```yaml
storage:
type: "MYSQL"
mysql:
url: "jdbc:mysql://localhost:3306/amplifier"
username: "root"
password: "password"
pool-size: 10
```
`pool-size` is how many connections Amplifier keeps open. 10 is plenty unless you're running something very large.
### MongoDB
Same idea, if Mongo is what you have.
```yaml
storage:
type: "MONGODB"
mongodb:
uri: "mongodb://localhost:27017"
database: "amplifier"
collection: "voice_players"
pool-size: 10
```
## Syncing across servers
If you run a network and want voice state to follow players between servers, point Amplifier at Redis:
```yaml
redis:
enabled: false
uri: "redis://localhost:6379"
password: ""
channel: "amplifier:voice"
server-id: null
```
| Setting | What it does |
|---|---|
| `enabled` | Turn cross-server syncing on |
| `uri` | Where your Redis is |
| `password` | Leave empty if there isn't one |
| `channel` | Which channel to talk on. The default is fine unless it clashes |
| `server-id` | A name for this server. Leave it `null` and Amplifier makes one up |
## Voice analysis with Cipher
If you use Cipher for speech-to-text or voice fingerprinting, this hands it the raw audio:
```yaml
cipher:
enabled: false
channel: "amplifier:cipher"
```
It needs `redis.enabled: true` as well, since it travels over the same Redis connection, just on its own channel. This is separate from cross-server syncing, so you can have one without the other.
## What players see
These are the messages Amplifier sends. MiniMessage formatting works, and `<target>` fills in the name of whoever was targeted.
```yaml
translations:
voicechat_disabled: "<red>Voice chat is globally muted!</red>"
broadcasting_voice: "<green>Your voice is currently being broadcasted!</green>"
voicechat_suppressed: "<red>Your voice is currently being suppressed!</red>"
muted_self: "<red>You have been muted.</red>"
unmuted_self: "<green>You have been unmuted.</green>"
muted_other: "<gray><target> is now muted.</gray>"
unmuted_other: "<gray><target> is now unmuted.</gray>"
```
| Message | When it shows |
|---|---|
| `voicechat_disabled` | Someone tries to talk while voice chat is off |
| `broadcasting_voice` | Shown to whoever is broadcasting |
| `voicechat_suppressed` | Their voice is being held back |
| `muted_self` / `unmuted_self` | Sent to the player it happened to |
| `muted_other` / `unmuted_other` | Sent to whoever did it |
## Choosing which build you get
`loader.yml` controls which version of Amplifier gets downloaded:
```yaml
loader_version: auto
loader_channels: release
```
| Setting | What it does |
|---|---|
| `loader_version` | `auto` keeps you on the newest release. Put a version like `1.0.64` here to stay on that one |
| `loader_channels` | Which kinds of build you'll accept. `release` is stable. Add `beta` or `alpha` to test early builds |
To help test a pre-release, use `loader_channels: release,alpha` and restart.
## A full example
```yaml
version: 5
voice-chat:
max-distance: 48
enabled: true
debug: false
cross-dimension: true
persistence:
enabled: true
storage:
type: "LOCAL"
mysql:
url: "jdbc:mysql://localhost:3306/amplifier"
username: "root"
password: "password"
pool-size: 10
mongodb:
uri: "mongodb://localhost:27017"
database: "amplifier"
collection: "voice_players"
pool-size: 10
redis:
enabled: false
uri: "redis://localhost:6379"
password: ""
channel: "amplifier:voice"
server-id: null
cipher:
enabled: false
channel: "amplifier:cipher"
translations:
voicechat_disabled: "<red>Voice chat is globally muted!</red>"
broadcasting_voice: "<green>Your voice is currently being broadcasted!</green>"
voicechat_suppressed: "<red>Your voice is currently being suppressed!</red>"
muted_self: "<red>You have been muted.</red>"
unmuted_self: "<green>You have been unmuted.</green>"
muted_other: "<gray><target> is now muted.</gray>"
unmuted_other: "<gray><target> is now unmuted.</gray>"
```
## Related Pages
- [[Amplifier/Server Owners/Overview]], what Amplifier does
- [[Amplifier/Server Owners/Commands]], every command with examples