Dueris / OriginsPaper

Custom Origins Plugin for PaperMC
https://modrinth.com/plugin/originspaper
Other
27 stars 4 forks source link

[BUG] - Lang files errors 1.20.1 #81

Closed Boddebon closed 4 months ago

Boddebon commented 5 months ago

Describe the bug I can't change the language at all - every time I change the value "lang" in origin-server.yml to something except "en_US", plugin uses English strings anyway but some of strings change to "There was a problem reading a lang file". And tell me, will this be fixed for version 1.20.1, if not, how can I fix it on my own?

Plugin Version 0.2.1

Minecraft version 1.20.1

Server software Paper

Steps to reproduce

Set "lang" value from "en_us" to another lang file name Start/reload the server Try to choose origin and get back in origins menu, "Return" button should be "There was a problem reading a lang file". image image image

Dueris commented 5 months ago

Lang has been an issue since it was implemented and has been removed in the beta versions of 1.0.0. I also dont recommend 0.2.1, there have been 7 updates since and Genesis has become a lot more stable

Dueris commented 5 months ago

However I am a little confused because your saying it's 0.2.1 in the report, but the logs say it's 1.0.0? If your running the latest beta builds on git then just update to the latest commit, that should fix it up

Boddebon commented 5 months ago

Sorry, I took the photo from a message from a previous user, I was not on a PC. The problem is that I cannot use the latest version 1.0.0, because my server is on 1.20.1 and I do not plan to migrate it yet. Is it possible to somehow make version 1.0.0 for server 1.20.1?

Boddebon commented 5 months ago

I tried to compile your code, but I got errors, so I didn't even try to compile it for the old version

Dueris commented 5 months ago

Idk why you would get errors, it compiles fine for me. It's a little hard to downgrade 1.0.0 or any version of genesis due to a lot of the code being highly version dependant. The last time a backport was made it ended horribly to the point of it would crash the server

Boddebon commented 5 months ago

Oh, this is very bad, I have been looking for a translation of this mod into a plugin for a long time and found you here, even my players really want to play with this plugin, unfortunately for some reason we cannot switch to a new version, this affects both the optimization of new versions and and the plugins that we use, quite a few of them do not work after version 1.20.2

Boddebon commented 5 months ago

Idk why you would get errors, it compiles fine for me. It's a little hard to downgrade 1.0.0 or any version of genesis due to a lot of the code being highly version dependant. The last time a backport was made it ended horribly to the point of it would crash the server

It turns out that it is not possible to change version 1.0.0 to 1.20.1?

If not, is it possible to fix the language error on the old version?

Dueris commented 5 months ago

Try looking at the language file itself and just copy the name to the value in origin-server.yml but without the ".yml" extension

Boddebon commented 5 months ago

Try looking at the language file itself and just copy the name to the value in origin-server.yml but without the ".yml" extension

I already tried it, it doesn’t help, even when the language is set to en_us, I get these errors image image

Dueris commented 5 months ago

The error has nothing todo with the lang file.

Boddebon commented 5 months ago

I started the server, immediately changed it to another language and went to the server and received this error and the language did not change. image

After which I decided to change to another language, turned off the server, changed the language and turned it on, after which I received the following errors image image

Dueris commented 5 months ago

I think you can see now why i don't recommend the early 0.2.# versions lol

Dueris commented 5 months ago

Honestly, idk what the issue is. It's been a long time since 0.2.1 and the codebase is entirely different from what it used to be

Boddebon commented 5 months ago

Honestly, idk what the issue is. It's been a long time since 0.2.1 and the codebase is entirely different from what it used to be

It turns out that the problem is not just in the kernel, but also in the fact that the code system itself has been changed due to which it cannot be run on the old version?

Dueris commented 5 months ago

There's lots of factors that go into updating and backporting. For example, biome conditions won't be possible in 1.20.1 since the class CraftBiome doesn't exist for converting bukkit and NMS biomes. By backporting even 1 version, I would expect there to be tons of issues and errors scattered throughout the plugin. And that's even if I can get it to compile. Genesis was never made to be backportable, and the current hope of having genesis run on multiple versions is some new changes coming to Paper to help with that. It's just way too much of a hassle and way too much time spent on 1 backport that won't be released or supported in the future.

Boddebon commented 5 months ago

There's lots of factors that go into updating and backporting. For example, biome conditions won't be possible in 1.20.1 since the class CraftBiome doesn't exist for converting bukkit and NMS biomes. By backporting even 1 version, I would expect there to be tons of issues and errors scattered throughout the plugin. And that's even if I can get it to compile. Genesis was never made to be backportable, and the current hope of having genesis run on multiple versions is some new changes coming to Paper to help with that. It's just way too much of a hassle and way too much time spent on 1 backport that won't be released or supported in the future.

Oh, this is very unpleasant to hear, it looks like mojang is not interested in developing the plugin component of their community. Okay, I realized that this is very difficult and not worth it, thank you for spending your time and telling me everything, in the future, when they release a more stable version for servers, I will be happy to create a server using your plugin, I hope by then there will be instructions on how to create your own races . Good luck in your work)

Dueris commented 5 months ago

In 1.0.0 you can create ur own origins the exact way you do with the normal mod. Mojang does care about the plugin component of their community, but I just use methods that aren't very... safe, one might say? I use lots of techniques and weird methods to make some of this happen, and 99% of that is weird stuff with internals, which change every update. Its more of how I made the plugin and not mojangs fault at all, however if I didn't use internals then a large portion of the plugin wouldn't be possible or would have to be accessed via reflection.

What is currently holding u back from updating?

Boddebon commented 5 months ago

Versions higher than 1.20.1 are quite unoptimized and many of my players complain about lags, literally alone. + We have quite a lot of plugins that are no longer updated and because of this they don’t work, and my experience in programming is not enough to import them to new versions

Dueris commented 5 months ago

Alright. Makes sense. If you want to do a backport you can, but I don't recommend it at all. The safest option is find replacements for the plugins and update to 1.20.4(if the server is the one that's lagging lmk, I develop a servertype that is extremely performant that should help with server-side lag. As for client lag, use sodium).

Boddebon commented 5 months ago

I don’t understand a little, how do you optimize the server?

Dueris commented 5 months ago

Modifying the source code. Like what paper does

Boddebon commented 5 months ago

Well, unfortunately, my main server is on version 1.20.1. I have plans to open a second server and would not mind creating it based on your plugin for version 1.204 - 1.21, although I need another plugin, which unfortunately is not on the Internet and I will probably have to write it myself (

Dueris commented 5 months ago

What plugin r u lookin for?

Boddebon commented 5 months ago

I need a plugin for one block, but where the leveling of breaking levels is not tied to the player, and so that blocks can be spawned by a command at any time, unfortunately, I haven’t found such plugins(

Dueris commented 4 months ago

Im closing this issue due to it being a very outdated version and new versions fixing this issue