Skip to content

Language Formation

nulli0n edited this page Feb 16, 2024 · 2 revisions

πŸ‘€ Overview

Each nightcore plugin has a /lang/ folder where configurations for different languages are stored. In this page you can learn some tips and features to customize your messages and redefine the plugin style.

πŸ–Š Creating Language

To create a new language config, use the following filename pattern: messages_ + your language code. For example, messages_ru.yml. Then, in plugin config.yml set Plugin.Language option to your language code, ru in this example.

βœ‚ Line Breaks

There are two ways to split message into multiple lines:

  1. Using the line break <br> tag:
Message: Text for Line 1<br>Text for Line 2
  1. Using the YAML list syntax:
Message:
- Text for Line 1
- Text for Line 2

Notes

  • When using YAML List syntax, all empty lines will be skipped and not displayed in game.
Message:
- '<noprefix>' # This will be empty line after tag(s) got parsed, skipped.
- '' # Also empty line, skipped
- ' ' # Not empty (whitespace), will be displayed.
- 'Some Text'
- 'Another Text'

πŸ”– Message Tags

Similar to regular Tags, language messages has a few it's own ones. They don't have to be closed and should be put before the actual language text.

πŸ“„ Tag List

  • <noprefix> - Removes plugin prefix from the message.
  • <papi> - Sets message to apply PlaceholderAPI placeholders before send to a player.
  • <output:"chat"> - Sets message to be printed in player's chat (set by default).
  • <output:"action_bar"> - Sets message to be printed in Action Bar (above player's hotbar).
  • <output:"titles:20:60:20"> - Sets message to be printed as Titles. Where numbers are fade in, stay, and fade out times in game ticks. 2 lines max.
  • <output:"none"> - Disables message from being sent at all.
  • <sound:"BLOCK_NOTE_BLOCK_BELL"> - Players specified Sound to a player when message is sent.

🧾 Examples

  • <noprefix><red>You don't have permissions to do that!</red>
  • <output:"titles:20:60:20"><red>Error<br>You don't have permissions to do that!</red>

🧭 Navigation Menu

🏠 General

🧩 Configuration

Clone this wiki locally