Honeypot Help

Language Files

Language files are a way to translate Honeypot's chat output to your native language. They also allow for custom formatting of messages, and even changing the prefix of Honeypot to remove its branding if you so chose!

Rather than list out every single individual translation, you can download a sample translation in the en_US language here

Translating Honeypot

If you're here to learn how to translate Honeypot, thank you! There are two ways you can do this, one is easier than the other but the other makes it easier on me lol

Contribute via Pull Request

The quickest way to provide translation is via a pull request.

  1. Create a fork of the repository.

  2. Locate the lang folder within src/main/resources/lang

  3. Create a new file with the language code. For example, if you were creating one for Chinese (PRC), it would be zh_CN.yml. For Chinese (Hong Kong) it would be zh_HK.yml. Microsoft keeps a list of these language codes as a good reference as part of their Open Specifications. Copy and paste one of the existing language files, then translate everything past the 2nd line (Don't touch the language-version line 😁).

  4. Commit your changes to your fork

  5. Create a pull request with the new language file. Once I review the changes, I will merge them into the project :)

Contribute via providing me a language file

This is easier, but definitely slower.

  1. Locate the lang folder within src/main/resources/lang

  2. Create a new file with the language code. For example, if you were creating one for Chinese (PRC), it would be zh_CN.yml. For Chinese (Hong Kong) it would be zh_HK.yml. Microsoft keeps a list of these language codes as a good reference as part of their Open Specifications. Copy and paste one of the existing language files, then translate everything past the 2nd line (Don't touch the language-version line 😁).

  3. Send the file to me my Discord in either a ticket or the #honeypot channel. Once received I will review the file, add it to the repo, and create a new commit.

Creating personal translations

If you'd like to create your own translations locally without waiting for my plugin to support them, you can do that too! (Please share them though 🥺)

  1. Load the plugin for the first time, just to generate the default en_US.yml language file. You can edit that file if you want, or you can create a new one. If you chose to just edit that file, edit it, restart the server, and enjoy your translations. If you want to create a new one, keep reading

  2. Copy the en_US.yml file and rename it whatever you want. The name doesn't matter, I just use the xx_YY format for consistency.

  3. Copy the en_US.yml file and rename it whatever you want. The name doesn't matter, I just use the xx_YY format for consistency.

  4. Translate everything past line 2 and save it.

  5. Open the Honeypot config.yml file in the Honeypot folder. You will see a section called CHAT SETTINGS. It looks like this:

    ###################################################################### # C H A T S E T T I N G S # ###################################################################### # Select your language. Current supported languages are: [en_US, es_MX, fr_FR, ja_JP, zh_CN] # Want to create your own translation? Visit here: https://github.com/TerrorByteTW/Honeypot/wiki/Translating-Honeypot language: en_US # If you're providing your own language file, set this to true. If you've incorrectly translated it, though, expect errors in console! # If you don't know what this is, leave it set to false bypass-language-check: false
  6. Change language to whatever you named your file (MINUS the .yml part) and change bypass-language-check to true. If you leave it false, the plugin will, by default, load en_US if your language isn't already supported by the plugin (Likely not)

  7. Voilà! You've successfully created your own language. Beware though, if you fail to translate it correctly or miss something (Or if the plugin updates later down the line and adds new translations) then expect errors in the console 😉

Last modified: 02 November 2024