Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add config support for other languages #1

Open
OoLunar opened this issue Dec 31, 2022 · 4 comments
Open

Add config support for other languages #1

OoLunar opened this issue Dec 31, 2022 · 4 comments
Assignees
Labels
enhancement New feature or request

Comments

@OoLunar
Copy link

OoLunar commented Dec 31, 2022

Summary

As seen in below, currently the text is hardcoded:

if (message.contains("The game starts in 2 seconds")) {

For those who use other languages, such as Russian or Chinese, this mod won't work as expected. If you PR support for loading the expected text from a config file, then I will manually go through each Hypixel language and PR full support for each language.

Notes

I just really want my pirate speak to work with this mod lmao

@dubfib dubfib self-assigned this Dec 31, 2022
@dubfib dubfib added the enhancement New feature or request label Dec 31, 2022
@dubfib
Copy link
Owner

dubfib commented Dec 31, 2022

Thinking of what your saying, I could add multiple checks for multiple phrases, thats my first solution I can think of right now but it's going to look like a monstrosity in the code. (never heard of someone who uses pirate speak)

translation for pirate speak:
Thinkin' o' what yer saying, I could add multiple checks fer multiple phrases, thats me first solution I can think o' as we speak but it be goin' to look like a monstrosity in the code.

@OoLunar
Copy link
Author

OoLunar commented Dec 31, 2022

I mean, ye could load to the sky all the config values into a 'ashset an' then check if the message be in the 'ashset.

Translation: I mean, you could load up all the config values into a hashset and then check if the message is in the hashset.

@dubfib
Copy link
Owner

dubfib commented Dec 31, 2022

An update on pirate speak translation, I made a hashmap and it works with both english and pirate speak and unicode font. You can see the development in the dev branch which is located here. I already made a alpha build download if you would like to use it. The alpha build is located here on modrinth. You can see the code for ChatEvent.java here.

Translation to Pirate Speak:
An update on Pirate Speak translation, I made a 'ashmap an' it works with both English an' Pirate Speak an' unicode font. Ye can see the development in the dev branch which be located here. I already made a alpha build download if ye would like to use it. The alpha build be located here on modrinth. Ye can see the code fer ChatEvent.java here.

@OoLunar
Copy link
Author

OoLunar commented Jan 1, 2023

The code been written an' tested. Now it be just fillin' up the json file with translations.

Translation: The code has been written and tested. Now it's just filling up the JSON file with translations.

OoLunar added a commit to OoLunar/autoutils that referenced this issue Jan 18, 2023
…ries; Added all of Hypixel's translations. Closes dubfib#1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants