Tweak
All checks were successful
EnergonRelics/pipeline/head This commit looks good

This commit is contained in:
TheBrokenRail 2020-08-02 10:40:08 -04:00
parent fdad30c27f
commit 9ec92ee4d9

View File

@ -53,7 +53,7 @@ class EnergyTeleporter {
} }
} }
private static int changeY(int y, int oldHeight, int newHeight) { private static int convertY(int y, int oldHeight, int newHeight) {
int bottomPadding = HardcodedConfig.ENERGY_PORTAL_Y_PADDING; int bottomPadding = HardcodedConfig.ENERGY_PORTAL_Y_PADDING;
int topPadding = bottomPadding + HardcodedConfig.ENERGY_PORTAL_Y_PADDING_EXTRA_TOP; int topPadding = bottomPadding + HardcodedConfig.ENERGY_PORTAL_Y_PADDING_EXTRA_TOP;
@ -84,8 +84,7 @@ class EnergyTeleporter {
ServerWorld to = world.getServer().getWorld(toKey); ServerWorld to = world.getServer().getWorld(toKey);
assert to != null; assert to != null;
int y = changeY(center.getY(), world.getDimensionHeight(), to.getDimensionHeight()); int y = convertY(center.getY(), world.getDimensionHeight(), to.getDimensionHeight());
int x = (int) (center.getX() * multiplier); int x = (int) (center.getX() * multiplier);
int z = (int) (center.getZ() * multiplier); int z = (int) (center.getZ() * multiplier);