Portals teleport a player that enters the specified region to an exact location, by a certain offset amount or to a random location inside a region.
The position and direction attributes of a portal are relative to the players location and where they are looking. Prefix these values with an at symbol @
to specify absolute values. Portals can be restricted to certain teams by defining their filter attribute.
Portals respond to any player move event, this allows almost instant teleportation as soon as the player matches the portals filter.
TIP:
Copy the yaw and pitch from the F3 screen in minecraft (the Facing: Direction (Axis) (Yaw/Pitch)
line).
Element | Description | |
---|---|---|
<portals> </portals>
|
Node containing the portals on this map. | |
Sub-elements | Value/Children | |
<portal>
|
An individual portal node. | Portal Sub-elements |
Attribute | Description | Value | Default |
---|---|---|---|
x
,
y
,
z
|
Offset the players X,Y,Z position by the amount specified. |
Number | |
region
|
Property
Required
Region where this portals entrance is located.
Cannot combine an entrance region with forward or transit properties.
|
Region | |
destination
|
Property
Destination of the portal, teleports players to a random point inside the region.
Cannot combine an exit region with reverse or transit properties.
|
Randomize-able Region | |
filter
|
Property Filter portal player access. | Filter |
<always/>
|
forward
|
Property Apply forward transform on rising edge | Dynamic Filter | |
reverse
|
Property Apply reverse transform on rising edge | Dynamic Filter | |
transit
|
Property
Apply forward transform on rising edge and reverse transform on falling edge
Cannot combine transit property with forward or reverse properties.
|
Dynamic Filter | |
observers
|
Property Filter portal observer access. | Filter |
<always/>
|
sound
|
Play the portal sound | true/false | true |
protect
|
Protect the portal entrance and exit regions. | true/false | false |
bidirectional
|
Creates a dual-linked portal that goes both ways. This can only be used when all coordinates and directions are relative. | true/false | false |
yaw
|
Specify the direction the player is looking horizontally from -180° to 180°.
South 0, East -90, North 180 and West 90. |
Number | |
smooth
|
Smoothly teleport players. | true/false | false |
pitch
|
Specify the direction the player is looking vertically from -90° to 90°.
-90 is straight up 90 is straight down. |
Number |
Element | Description | Value/Children | |
---|---|---|---|
<region>
|
Property Required Region where this portals entrance is located. | Regions | |
<destination>
|
Property
Destination of the portal, teleports players to a random point inside the region.
Region is automatically filtered against block place. |
Randomize-able Regions | |
<filter>
|
Property Filter portal player access. | Filters | |
<forward>
|
Property Apply forward transform on rising edge | Dynamic Filters | |
<reverse>
|
Property Apply reverse transform on rising edge | Dynamic Filters | |
<transit>
|
Property
Apply forward transform on rising edge and reverse transform on falling edge
Cannot combine transit property with forward or reverse properties.
|
Dynamic Filters | |
<observers>
|
Property Filter portal observer access. | Filters |
Examples
<!-- Portals from Harb -->
<portals>
<!-- Adds 110 to the players X position, Y, Z, pitch & yaw remain unchanged -->
<portal x="110">
<region><cuboid min="-56,33,-1" max="-55,35,2"/></region>
</portal>
<!-- Subtracts 110 from the players X position, Y, Z, pitch & yaw remain unchanged -->
<portal x="-110">
<region><cuboid min="56,33,-1" max="57,35,2"/></region>
</portal>
</portals>
<portal yaw="@0" sound="false">
<forward>
<all>
<filter id="portal-filter"/>
<region id="portal-region"/>
</all>
</forward >
<destination>
<region id="portal-destination"/>
</destination>
</portal>
<portals>
<!-- Moves the player to exactly X:10 Y:8 Z:45, pitch & yaw remain unchanged -->
<portal x="@10" y="@8" z="@45">
<region><cuboid min="-56,33,-1" max="-55,35,2"/></region>
</portal>
<!-- Adds 12 to the players Z position, turning them to face east and 10° up -->
<portal z="12" pitch="@10" yaw="@-90">
<region><cuboid min="-56,33,-1" max="-55,35,2"/></region>
</portal>
<!-- Teleport the player from portal-entrance to a random point inside portal-exit -->
<portal region="portal-entrance">
<destination><region id="portal-exit"/></destination>
</portal>
</portals>