was using this code in 1.18 it has broke in 1.19 and can not find a fix.
this code breaks every time the version changes the mod talks to a 3rd party app to set the LED's colors on your keyboard
is there an easy way to do this so it does not break on version change
DimensionType dimension = world.dimensionType();
if (DimensionType.NETHER_LOCATION.location().equals(dimension.effectsLocation()))
dimensionID = 1;
else if (DimensionType.OVERWORLD_LOCATION.location().equals(dimension.effectsLocation()))
dimensionID = 2;
else if (DimensionType.END_LOCATION.location().equals(dimension.effectsLocation()))
dimensionID = -1;
else
dimensionID = 0;
} catch (Exception ignore) {
}