Interface SafeTTeleporter
-
- All Superinterfaces:
Teleporter
- All Known Implementing Classes:
SimpleSafeTTeleporter
public interface SafeTTeleporter extends Teleporter
Used to safely teleport people.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.bukkit.Location
findPortalBlockNextTo(org.bukkit.Location l)
Finds a portal-block next to the specifiedLocation
.org.bukkit.Location
getSafeLocation(org.bukkit.entity.Entity e, MVDestination d)
Returns a safe location for the entity to spawn at.org.bukkit.Location
getSafeLocation(org.bukkit.Location l)
Gets the next safe location around the given location.org.bukkit.Location
getSafeLocation(org.bukkit.Location l, int tolerance, int radius)
Gets the next safe location around the given location.TeleportResult
safelyTeleport(org.bukkit.command.CommandSender teleporter, org.bukkit.entity.Entity teleportee, MVDestination d)
Safely teleport the entity to the MVDestination.TeleportResult
safelyTeleport(org.bukkit.command.CommandSender teleporter, org.bukkit.entity.Entity teleportee, org.bukkit.Location location, boolean safely)
Safely teleport the entity to the Location.-
Methods inherited from interface com.onarandombox.MultiverseCore.api.Teleporter
teleport
-
-
-
-
Method Detail
-
getSafeLocation
org.bukkit.Location getSafeLocation(org.bukkit.Location l)
Gets the next safe location around the given location.- Parameters:
l
- ALocation
.- Returns:
- A safe
Location
.
-
getSafeLocation
org.bukkit.Location getSafeLocation(org.bukkit.Location l, int tolerance, int radius)
Gets the next safe location around the given location.- Parameters:
l
- ALocation
.tolerance
- The tolerance.radius
- The radius.- Returns:
- A safe
Location
.
-
safelyTeleport
TeleportResult safelyTeleport(org.bukkit.command.CommandSender teleporter, org.bukkit.entity.Entity teleportee, MVDestination d)
Safely teleport the entity to the MVDestination. This will perform checks to see if the place is safe, and if it's not, will adjust the final destination accordingly.- Parameters:
teleporter
- Person who performed the teleport command.teleportee
- Entity to teleportd
- Destination to teleport them to- Returns:
- true for success, false for failure
-
safelyTeleport
TeleportResult safelyTeleport(org.bukkit.command.CommandSender teleporter, org.bukkit.entity.Entity teleportee, org.bukkit.Location location, boolean safely)
Safely teleport the entity to the Location. This may perform checks to see if the place is safe, and if it's not, will adjust the final destination accordingly.- Parameters:
teleporter
- Person who issued the teleport command.teleportee
- Entity to teleport.location
- Location to teleport them to.safely
- Should the destination be checked for safety before teleport?- Returns:
- true for success, false for failure.
-
getSafeLocation
org.bukkit.Location getSafeLocation(org.bukkit.entity.Entity e, MVDestination d)
Returns a safe location for the entity to spawn at.- Parameters:
e
- The entity to spawnd
- The MVDestination to take the entity to.- Returns:
- A new location to spawn the entity at.
-
findPortalBlockNextTo
org.bukkit.Location findPortalBlockNextTo(org.bukkit.Location l)
Finds a portal-block next to the specifiedLocation
.- Parameters:
l
- TheLocation
- Returns:
- The next portal-block's
Location
.
-
-