When zh info, the variant section does not apply locale.
mhtvsSFrpHdE opened this issue · 2 comments
Bug report
What are you trying to do ?
To display horse data use /zh info
What is the expected behavior ?
Show translated variant name in locale_EN.yml
.
What is the actual behavior ?
In game, ride a horse and type /zh info
still print Variant: Horse
instead of Variant: 马
How to reproduce the bug ?
1.Modify locale_EN.yml
, change variantHorse:
value from
variantHorse: "<yellow><<gold>H<yellow>>"
to
variantHorse: "<yellow><<gold>马<yellow>>"
2.In game, type /zh reload
or restart the server.
3.Ride a owned horse then type /zh info
4.Translated text not show.
Console output
No errors in console.
Environment specifications
- Operating system :
Windows
- Java version :
Java 8
- Server version :
[INFO]: This server is running CraftBukkit version git-Spigot-79a30d7-acbc348 (MC: 1.12.2) (Implementing API version 1.12.2-R0.1-SNAPSHOT)
[INFO]: This is a final build for 1.12.2. Please see https://www.spigotmc.org/ for details about upgrading.
- ZHorse version :
[INFO]: -+- ZHorse 1.6.9 (by Z3dd7) -+-
[INFO]: /zh help: Display the available commands.
- Database :
default
This is in fact not a bug, rather a bad choice of names for locale entries from me. Indeed, the locale entry variantHorse
is meant to be displayed with /zh list
.
What you're looking for is a locale entry to translate the variant displayed with /zh info
. Unfortunately, there exist no such entry, my bad.
On top of that, the locale entry variant
is used by /zh info
and not /zh list
which adds even more confusion.
I plan to fix that in 1.8.2 by making /zh info
use the locale entries variantXXXX
and adding new ones (like shortVariantXXXX
) to replace them for /zh list
.
The concerned locale entries should look like this:
shortVariantHorse: "<gold>Horse"
shortVariantDonkey: "<gold>Donkey"
shortVariantMule: "<gold>Mule"
shortVariantLlama: "<gold>Llama"
shortVariantSkeleton: "<gold>Skeleton"
shortVariantZombie: "<gold>Zombie"
variant: "<yellow>Variant: <<gold><value><yellow>>"
variantHorse: "H"
variantDonkey: "D"
variantMule: "M"
variantLlama: "L"
variantSkeleton: "S"
variantZombie: "Z"
PS: I think that you should rather use other locale files (such as locale_CN.yml
which is provided by default as of ZHorse 1.8.1) than modifying locale_EN.yml
. See How to create a custom localization file ? for more information.
@Zedd7 Well I just don't like what he translated
GouLiGuoJiaNaive
if that was him.
Then I doing the translate myself.
I then make a plan for move to next version!