End Gateway (block)

The end gateway is a block that forms a part of end gateways, which teleport the player between the main island and the outer islands in the End.
== Obtaining ==
The end gateway block cannot be obtained as an item and can be placed only by using block placement commands such as or .
, it may be obtained as an item via inventory editing or add-ons. It cannot be placed by block placement commands in this edition, but it can be placed using structure blocks.
=== Post-generation ===
End gateway blocks form the functional part of end gateways. Each time the ender dragon is defeated, one end gateway spawns around the central island in the End, up to 20 times. Activating each of them spawns one additional gateway in the outer islands.
=== Natural generation ===
More naturally generated gateways that transport the player back to the obsidian platform can be found throughout the outer End islands.
== Usage ==
End gateway blocks in their original form can be used to teleport to the outer islands of the end. End gateway blocks can be used as a custom teleporter using NBT tags.
* ExitPortal tag holds a set of X/Y/Z coordinates to determine the general location the player can be "safely" teleported to when entering.
* Setting ExactTeleport to 1 teleports entities to the specified coordinates exactly instead of at a safer location around those coordinates.
* Age determines how long the gateway has existed. This is used to determine when the beam is rendered.
* Example: 
When created in a dimension other than the End without ExitPortal NBT data, it does not teleport entities but still activates its beam effect when an entity enters.
, when the gateway is placed and entered in the End, it teleports the user to coordinates 0, 0, 0, below the main island. In the Overworld or Nether, it acts as a solid block and cannot be entered.
Gateways have a small chance to teleport the player directly into the void at y=0.
=== Beam ===
When generated (either naturally as part of an end gateway, or through ), the block emits a beam of light vertically from its top and bottom, lasting for while fading in and out.
An end gateway block also emits a beam of light vertically from the top and bottom when an entity enters it. During the this beam is visible, no additional entities can be teleported.
It also emits the teleport beam every .
The creation beam extends from around Y=0 through the block up to Y=256; the teleport beam goes 50 blocks above and below the gateway block. The beam is visible from roughly the same distance as a single ordinary stack of blocks. If a render distance of 16 chunks is set, the beam of light is visible from up to 255 blocks away. Unlike the beam of a beacon, this beam does not change color if the player puts stained glass over it.
It is not possible to disable either of the beams entirely. However, it is possible to edit the age of the block to a negative value, effectively delaying beam-emitting properties of the end gateway. You can change the age of the block by entering the command (for example) as follows: /setblock ~ ~ ~ minecraft:end_gateway{Age:-9223372036854775808L}. This will last for 14,993,257,186 years, effectively disabling the beam.
=== Piston interactivity ===
End gateway blocks cannot be interacted with pistons or sticky pistons.
== Sounds ==
=== Generic ===
=== Unique ===
:
: None
== Data values ==
=== ID ===
:
:
=== Block data ===
An end gateway block has a block entity associated with it that holds additional data about the block.
:
:
: See Bedrock Edition level format/Block entity format.
== History ==
=== End gateway "item" ===
== Issues ==
== Gallery ==
File:GatewayBlockBeamMagenta.png|An End gateway block emitting a magenta beam after being created.
File:GatewayBlockBeamPurple.png|An End gateway block emitting a purple beam after teleporting an entity.
File:GatewayBlockBeamComparison.png|Comparison between the magenta (left) and purple (right) beams.
File:GatewayBlockBeamYellow.png|An End gateway block emitting a yellow beam after teleporting an entity (before Java Edition 1.11).
File:End gateway portal inside.png|An interior view of an End gateway block.
File:Double yellow beam.png|Comparison of the historically emitted yellow beam with a yellow-tinted beacon beam.
==Trivia==
* if one manages to place an end gateway at the center of the obsidian platform, it teleports the player before the platform regenerates. As a result, the platform appears in a different location than it should, like below the main island.
== References ==
Category:End blocks
Category:Block entities
Category:Generated structure blocks
Category:Non-solid blocks
Category:Utility blocks
Category:Light sources
fr:Bloc de passerelle de l'End
ja:エンドゲートウェイ (ブロック)
ko:엔드 관문 (블록)
pl:Blok portalu bramy Endu
pt:Passagem do End (bloco)
ru:Блок врат Края
zh:末地折跃门方块