Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

package meteordevelopment.meteorclient.settings;

import meteordevelopment.meteorclient.utils.world.Dimension;
import net.minecraft.nbt.CompoundTag;

import java.util.ArrayList;
Expand Down Expand Up @@ -53,7 +54,17 @@ public CompoundTag save(CompoundTag tag) {

@Override
public T load(CompoundTag tag) {
parse(tag.getStringOr("value", ""));
String value = tag.getStringOr("value", "");

// Dimension#toString returned the namespaced id for a while, so older saves hold "minecraft:the_nether"
if (!parse(value) && get() instanceof Dimension) {
for (Dimension dimension : Dimension.values()) {
if (value.equals(dimension.toIdentifier())) {
parse(dimension.toString());
break;
}
}
}

return get();
}
Expand Down
Loading