MeteorDevelopment / meteor-client

Based Minecraft utility mod.
https://meteorclient.com
GNU General Public License v3.0
2.17k stars 802 forks source link

Change dimension detection #4448

Open W1tt opened 6 months ago

W1tt commented 6 months ago

Describe the feature

public static Dimension getDimension() {
        if (mc.world == null) return Dimension.Overworld;
        return switch (mc.world.getRegistryKey().getValue().getPath()) {
            case "the_nether" -> Dimension.Nether;
            case "the_end" -> Dimension.End;
            default -> Dimension.Overworld;
        };

The PlayerUtils.getDimension() method returns dimension based on the world name, which means that if nether world's name is different than "the_nether", then it would return overworld

Before submitting a suggestion

hexadecimal233 commented 6 months ago

implemented in #4011 wait for merge