Created
January 6, 2020 11:19
-
-
Save Cadiboo/7782819faf49c40d389dfb7b3cf35607 to your computer and use it in GitHub Desktop.
How to get to your Dimension in 1.14 (and probably in 1.13 and 1.15 too)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// By Commoble#9251 | |
// https://discordapp.com/channels/176780432371744769/179315645005955072/661244291833790494 on the MMD Discord (https://discord.mcmoddev.com/) | |
// How to get to your Dimension in 1.14 (and probably in 1.13 and 1.15 too) | |
public static void teleportPlayerToDimension(ServerPlayerEntity player, DimensionType destinationType, BlockPos destinationPos) { | |
ServerWorld nextWorld = player.getServer().getWorld(destinationType); | |
nextWorld.getChunk(destinationPos); // Make sure the chunk is loaded | |
player.teleport(nextWorld, destinationPos.getX(), destinationPos.getY(), destinationPos.getZ(), player.rotationYaw, player.rotationPitch); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment