Class RainbowBeansScroll

All Implemented Interfaces:
EquipListener, TurnListener, UseListener, Stackable<StackableItem>, Killer, Cloneable, Iterable<String>, Serializable

public class RainbowBeansScroll extends TimedTeleportScroll
Represents the rainbow beans that takes the player to the dream world zone, after which it will teleport player to a random location in 0_semos_plains_s.
  • Constructor Details

    • RainbowBeansScroll

      public RainbowBeansScroll(String name, String clazz, String subclass, Map<String,​String> attributes)
      Creates a new timed marked RainbowBeansScroll scroll.
      Parameters:
      name -
      clazz -
      subclass -
      attributes -
    • RainbowBeansScroll

      public RainbowBeansScroll(RainbowBeansScroll item)
      Copy constructor.
      Parameters:
      item - item to copy
  • Method Details

    • useTeleportScroll

      protected boolean useTeleportScroll(Player player)
      Description copied from class: TimedTeleportScroll
      Is invoked when a teleporting scroll is used. Tries to put the player on the scroll's destination, or near it.
      Overrides:
      useTeleportScroll in class TimedTeleportScroll
      Parameters:
      player - The player who used the scroll and who will be teleported
      Returns:
      true if teleport was successful
    • getBeforeReturnMessage

      protected String getBeforeReturnMessage()
      Description copied from class: TimedTeleportScroll
      override this to show a message before teleporting the player back.
      Overrides:
      getBeforeReturnMessage in class TimedTeleportScroll
      Returns:
      the message to shown or null for no message
    • getAfterReturnMessage

      protected String getAfterReturnMessage()
      Description copied from class: TimedTeleportScroll
      override this to show a message after teleporting the player back.
      Overrides:
      getAfterReturnMessage in class TimedTeleportScroll
      Returns:
      the message to shown or null for no message