EssentialsX

EssentialsX

2M Downloads

Wrong World Names in userdata files on EssentialsX 2.19.x

Chris6ix opened this issue ยท 17 comments

commented

Type of bug

Other unexpected behaviour

/ess version output

Server version: 1.17-R0.1-SNAPSHOT git-Paper-71 (MC: 1.17)
Brand version: Paper
EssentialsX version: 2.19.0-dev+191-555a62c
EssentialsXChat version: 2.19.0-dev+191-555a62c

Server startup log

https://paste.gg/p/anonymous/e1e5a3b01b94457bac3283730c5f2225

EssentialsX config files

https://paste.gg/p/anonymous/ab3606c8adba45a8a0e252ee6b2d6059

Error log (if applicable)

No response

Bug description

EssentialsX 2.19.x does not save the correct world names in the homes section and logoutlocation:world in the userdata/playerUUID.yml
EssentialsX 2.18.2 does not have this issue.

Better Explanation and Examples:

EssentialsX 2.18.2:
I do /sethome Test, and it says "1.17_Test" as the world name for homes:Test:world (Correct)
I leave the server and it says "1.17_Test" as the world name for lastlocation:world (Correct)

EssentialsX 2.19.x:
I do /sethome Test and leave the server and it says "347a5d2c-5cdb-4ce0-b67c-ac685cbc7f9b" as the world name for logoutlocation:world and for homes:Test:world (Wrong)

This was just tested several times on Paper 1.17 #71, and I can recreate it every time...

Steps to reproduce

1.Set a Home with Essx 2.18.2 or leave the server
2.See that is correcly saves the world names
3.Set a Home with Essx 2.19.x or leave the server
4.See that the saved world names are weird

Expected behaviour

Should save correct world names

Actual behaviour

Saves weird and wrong world names

commented

Ohhh..i didn't know that EssentialsX now uses the worlds UUID and not the name...
So this is meant to be and not a bug?

Correct, you can always use world names in userdata if you'd like as they are backwards compatible.

commented

And how?

commented

And how?

Essentials will continue to use world UUIDs but you could always type out the world name if you needed to (not recommended)

commented

Like manually changing them for every home of every player?

commented

What exactly do you mean by that?

commented

Like manually changing them for every home of every player?

Can I ask why you want world names?

commented

I want the world name 1.to generally know in which worlds the homes are and 2.they need to be shows by HomeGUI....
Because now HomeGUI just shows "World:347a5d2c-5cdb-4ce0-b67c-ac685cbc7f9b" which is nonsense...
Now with UUIDs you don't even know in what world your home is...

commented

Sounds like an issue for HomeGUI to fix. It would be a good idea to report this to them instead so they can update how their plugin displays the world.

commented

No this is not just a HomeGUI issue because it also shows this UUID in the userdata files...
If i now want to know where a players homes are, i just get a UUID that says absolutely nothing :/
I don't even understand why this change was even made...it's not like your going to change a world's name in-between times or something...and if you do than it's your own fault because this is not something that you do...

There should at least be a config option that lets you choose it Essx saves world names or world UUIDs...

commented

Looking at userdata files directly is not the intended way to view a player's homes. Use the /home <player>: command to list a player's homes and /home <player>:<homename> to teleport to one.

commented

I know that this command exists, but like this i have to enter and teleport to every single Home of a player...looking at a players file is just the WAY WAY quicker way...

Because players dont name their homes like "Survival-2-Home-3" for example...
With stuff like "Farm2","CoolHome","Home123" etc. you have no idea in what world they are...

But in a players file you could in the past see all the info about a players homes very quickly and well structured...

commented

Your argument still doesn't make sense since you're still not going to know what location the home is at just by prying into the userdata file. Unless you just happen to know that -4567, 68, 2258 (or insert random coordinates here) is some known location just by looking at it, you still have no clue what that home is unless the name makes sense, or you teleport there.

That aside, the only difference here is that the storage library used by Essentials is now storing the worlds by UUID. You should still be able to perfectly well identify a world by UUID rather than by name. The UUID will always be the same for a specific world. So pretend 63740d47-0b5b-4291-be4c-b076b118943e is the id for a world named world. Every place you see that UUID in any playerdata file will always be that same world.

This isn't likely to be changed anytime soon, so you should update your plugins, and learn the new format if you must work with the userdata files directly for whatever reasons you may have.

commented

My argument does make sense...
An example to clarify:

If we know that for example in world Survival-2 there is a lag machine at around -4567, 68, 2258, then we do know the exact location.
We could then for example unload this world or stop this server, so it stops the machine(and lag) and then quickly go through the player files to see for example that every player with a home at this location is involved in the problem without needing to teleport to every single home of every single player (which btw doesn't even work if that world is unloaded or that server is stopped...)

And reading stuff like "Survival-2" is easier than "63740d47-0b5b-4291-be4c-b076b118943e" even if we would remember every UUID for every world (Which btw gets very hard and confusing with a lot of worlds...)

commented

Again, using the userdata manually this way is in no way intended nor recommended. I fully and completely understand the reasoning for preferring the world name over the UUID for readability, but this is not what it is designed for.

For emphasis:

This isn't likely to be changed anytime soon, so you should update your plugins, and learn the new format if you must work with the userdata files directly for whatever reasons you may have.

commented

I get that its "in no way intended nor recommended" but It's just objectively the better way...
I opened #4311 in hopes that this will be changed, as i really don't like the current way...

Anyway, i thank you for your time and have a nice day!

commented

Essentials now uses the world UUID rather than name when storing worlds. Are you sure that the worlds are the wrong ones or did you just not understand what the UUID was?

commented

Ohhh..i didn't know that EssentialsX now uses the worlds UUID and not the name...
So this is meant to be and not a bug?