Messages & Language

Every message TradeSMP shows comes from a language file, so you can reword anything without touching code. It ships with English, French, and Spanish, and you can add any other language yourself.

Where the files live

plugins/TradeSMP/lang/
  en.yml   English
  fr.yml   French
  es.yml   Spanish

Pick which one to use with the language key in config.yml:

language: en

Change a value, save, and run /tradesmp reload.

Add your own language

You do not need an update from us to add a language.

Adding Hindi, for example

  1. In config.yml, set language: hindi.
  2. Run /tradesmp reload. TradeSMP sees there is no hindi.yml and creates one for you, a full copy of the English file.
  3. Open plugins/TradeSMP/lang/hindi.yml and translate the values.
  4. Run /tradesmp reload again to apply your text.

Nothing breaks while you translate

Until you fill it in, English text keeps showing. And any single line you leave untranslated falls back to English, so a half done file never shows blank or broken messages.

Colors and styles

Messages support more than plain & color codes:

StyleExample
Classic color codes&aGreen text
Hex colors&#34d399Custom green
Gradientssupported
Rainbowsupported

The main messages

Here are the keys you are most likely to reword. Placeholders like %level% get filled in by the plugin, keep them as they are.

KeyShown when
level-upA player’s level goes up.
level-downA player’s level goes down.
level-check-selfA player checks their own level.
level-check-otherA player checks someone else’s level.
locate-resultA village is found.
locate-cooldownThe locator is still on cooldown.
locate-requires-levelA non +3 player tries the locator.
ban-messageA player is banned at -3.
trade-set-successAn admin sets a level.
reload-successThe config and language files reload.

The file-version line

Each language file starts with a file-version number. Leave it alone. It works the same way as config-version, letting new message keys merge in on update. See Configuration.