6: Teleporting a player to stored coordinates [Minecraft Map Making]

Subscribers:
4,230
Published on ● Video Link: https://www.youtube.com/watch?v=jAGSITu3ZP8



Minecraft
Game:
Minecraft (2011)
Duration: 15:10
303 views
11


Ep6: Teleporting a player to coordinates that are stored as scoreboard objectives.

Originally for Udemy, but uploaded here.
Commands, builds and ideas for people making their own Minecraft maps.

Check out my collabs on Coppit's channel: https://www.youtube.com/c/CoppitJ

Join the server I play on and the Discord where I hang out.
Server IP: 51.81.246.145:25588
Discord: https://discord.gg/KNSmPWdnfG

Udemy notes. YouTube formatting may make some of these wrong. :)

Commands used:
Create objective to hold the X coordinate:
scoreboard objectives add spawnX dummy
Create objective to hold the Y coordinate:
scoreboard objectives add spawnY dummy
Create objective to hold the Z coordinate:
scoreboard objectives add spawnZ dummy

Set the X coordinate:
scoreboard players set @p spawnX 19
Set the Y coordinate:
scoreboard players set @p spawnY 56
Set the Z coordinate:
scoreboard players set @p spawnZ -35

Store the players X coordinate:
execute store result score @p spawnX run data get entity @p Pos[0]
Store the players Y coordinate:
execute store result score @p spawnY run data get entity @p Pos[1]
Store the players Z coordinate:
execute store result score @p spawnZ run data get entity @p Pos[2]

Create the End Gateway:
setblock -14 55 -22 minecraft:end_gateway{ExactTeleport:1b}
Set the X destination of the End Gateway:
execute store result block -14 55 -22 ExitPortal.X double 1 run scoreboard players get @p spawnX
Set the Y destination of the End Gateway:
execute store result block -14 55 -22 ExitPortal.Y double 1 run scoreboard players get @p spawnY
Set the Z destination of the End Gateway:
execute store result block -14 55 -22 ExitPortal.Z double 1 run scoreboard players get @p spawnZ
Teleport the player into the End Gateway:
tp @p -14 55 -22
Replace the End Gateway with Red Wool:
setblock -14 55 -22 red_wool







Tags:
minecraft
adventure map
map making
commands
command blocks
1.16
1.17
1.18
custom commands
redstone
map ideas
map suggesstions
custom maps



Other Statistics

Minecraft Statistics For Infernal Device

At present, Infernal Device has 184,447 views spread across 877 videos for Minecraft, accounting for over 10 days of watchable video on his channel. This is 94.82% of the total watchable video for Minecraft on Infernal Device's YouTube channel.