Interface RealPortal
- All Superinterfaces:
- MetadataHolder,- Portal
- All Known Implementing Classes:
- StargatePortal
- 
Method SummaryModifier and TypeMethodDescriptionvoidactivate(org.bukkit.entity.Player player) Activates this portal for the given player during internally specified timevoidclose(long relatedOpenTime) Closes this portalvoidDeactivate this portalvoiddoTeleport(@NotNull org.bukkit.entity.Entity target) Teleports the given entity to stored destinationvoiddoTeleport(@NotNull org.bukkit.entity.Entity target, @Nullable Portal destination) Teleports the given entity to given destination@Nullable UUIDorg.bukkit.LocationgetExit()Gets the exit location of this portalorg.bukkit.block.BlockFaceGet the facing entities exit from this portal.getGate()Gets the gate belonging to this portalList<org.bukkit.Location> Gets the location of all positions of the specified portal position typebooleanisActive()voidOpen this portal without any checksvoidRedraw all signs in this portalvoidsetBehavior(PortalBehavior portalBehavior) Modify the behavior this portal usesvoidsetSignColor(org.bukkit.DyeColor color, PortalPosition portalPosition) Updates the color of this portal's signMethods inherited from interface org.sgrewritten.stargate.api.MetadataHoldergetMetadata, getMetadata, setMetadata, setMetadataMethods inherited from interface org.sgrewritten.stargate.api.network.portal.PortaladdFlag, close, destroy, getAllFlagsString, getGlobalId, getId, getName, getNetwork, getOwnerUUID, getStorageType, hasFlag, isDestroyed, isOpen, isOpenFor, open, overrideDestination, removeFlag, setName, setNetwork, setOwner, teleportHere, updateState
- 
Method Details- 
openvoid open(@Nullable @Nullable Portal destination, @Nullable @Nullable org.bukkit.entity.Player actor) Open this portal without any checks- Parameters:
- destination-- The destination to open to 
- actor-- The player which opened this portal 
 
- 
setSignColorUpdates the color of this portal's signReplacement function for Sign.setColor(org.bukkit.DyeColor), as the portal sign is an interface that is using a combination of various colors; more has to be processed- Parameters:
- color-- Color to change the sign text to. If null, then the default color will be used 
 
- 
getGateGateAPI getGate()Gets the gate belonging to this portal- Returns:
- The gate belonging to this portal 
 
- 
closevoid close(long relatedOpenTime) Closes this portalEverytime most of the portals opens, there is going to be a scheduled event to close it after a specific time. If a player enters the portal before this, then it is going to close, but the scheduled close event is still going to be there. And if the portal gets activated again, it is going to close prematurely, because of this already scheduled event. Solution to avoid this is to assign an open-time for each scheduled close event and only close if the related open time matches with the most recent time the portal was opened. - Parameters:
- relatedOpenTime-- The time this portal was opened 
 
- 
getExitorg.bukkit.Location getExit()Gets the exit location of this portal- Returns:
- The exit location of this portal 
 
- 
getPortalPositionGets the location of all positions of the specified portal position type- Parameters:
- type-- The type of portalPosition 
- Returns:
- The location of this portal's signs 
 
- 
getActivatorUUID- Returns:
- The uuid activator or null if portal is not active (or always on) 
 
- 
deactivatevoid deactivate()Deactivate this portal
- 
getExitFacingorg.bukkit.block.BlockFace getExitFacing()Get the facing entities exit from this portal.- Returns:
- The facing entities exit from this portal. 
 
- 
getBehaviorPortalBehavior getBehavior()- Returns:
- The behavior which defines this portal destination selection and sign text 
 
- 
setBehaviorModify the behavior this portal uses- Parameters:
- portalBehavior-- New behavior this portal should follow 
 
- 
redrawSignsvoid redrawSigns()Redraw all signs in this portal
- 
activatevoid activate(org.bukkit.entity.Player player) Activates this portal for the given player during internally specified time- Parameters:
- player-- The player to activate this portal for 
 
- 
isActiveboolean isActive()- Returns:
- True if this portal is active 
 
- 
doTeleportvoid doTeleport(@NotNull @NotNull org.bukkit.entity.Entity target, @Nullable @Nullable Portal destination) Teleports the given entity to given destination- Parameters:
- target-- The entity to teleport 
 
- 
doTeleportvoid doTeleport(@NotNull @NotNull org.bukkit.entity.Entity target) Teleports the given entity to stored destination- Parameters:
- target-- The entity to teleport 
 
 
-