Class PortalPlayerSession

java.lang.Object
org.mvplugins.multiverse.portals.PortalPlayerSession

public class PortalPlayerSession extends Object
  • Constructor Details

    • PortalPlayerSession

      public PortalPlayerSession(MultiversePortals plugin, org.bukkit.entity.Player p)
  • Method Details

    • selectPortal

      public boolean selectPortal(MVPortal portal)
    • getSelectedPortal

      public MVPortal getSelectedPortal()
    • setDebugMode

      public void setDebugMode(boolean debugMode)
    • isDebugModeOn

      public boolean isDebugModeOn()
    • setStaleLocation

      public void setStaleLocation(boolean active)
    • isStaleLocation

      public boolean isStaleLocation()
    • doTeleportPlayer

      public boolean doTeleportPlayer(MoveType eventType)
    • getLocation

      public org.bukkit.Location getLocation()
    • setStaleLocation

      public void setStaleLocation(org.bukkit.Location loc, MoveType moveType)
    • setLeftClickSelection

      public boolean setLeftClickSelection(org.bukkit.util.Vector v, org.mvplugins.multiverse.core.world.LoadedMultiverseWorld world)
    • setRightClickSelection

      public boolean setRightClickSelection(org.bukkit.util.Vector v, org.mvplugins.multiverse.core.world.LoadedMultiverseWorld world)
    • getSelectedRegion

      public MultiverseRegion getSelectedRegion()
    • getStandingInPortal

      public MVPortal getStandingInPortal()
      If a player teleports from A - B, this method will report A even if the player is in B. This is done for hysteresis. For the exact detection please use getUncachedStandingInPortal()
      Returns:
      The MVPortal the player is standing in.
    • getUncachedStandingInPortal

      public MVPortal getUncachedStandingInPortal()
      This will ALWAYS return the portal a player is actually in. For hysteresis see getStandingInPortal().
      Returns:
      The MVPortal the player is standing in.
    • playerDidTeleport

      public void playerDidTeleport(org.bukkit.Location location)
      This method should be called every time a player teleports to a portal.
      Parameters:
      location -
    • hasMovedOutOfPortal

      public boolean hasMovedOutOfPortal()
    • showDebugInfo

      public boolean showDebugInfo()
    • showDebugInfo

      public boolean showDebugInfo(MVPortal portal)
    • setTeleportTime

      public void setTeleportTime(Date date)
    • checkAndSendCooldownMessage

      public boolean checkAndSendCooldownMessage()
      Checks if the teleport cooldown is still in effect. If it is, a message is sent to the player informing them.
      Returns:
      True if the teleport cooldown is still in effect, false otherwise.