Class Hologram

java.lang.Object
redempt.redlib.misc.Hologram

public class Hologram extends Object
Represents a number of floating armor stands intended to display information
  • Method Details

    • create

      public static Hologram create(org.bukkit.Location loc, String... lines)
      Creates a Hologram
      Parameters:
      loc - The location to create the Hologram at
      lines - The lines of text for this Hologram
      Returns:
      The Hologram that was created
    • getAt

      public static Hologram getAt(org.bukkit.Location loc)
      Attempts to get a Hologram at a specified location
      Parameters:
      loc - The location to check at
      Returns:
      The Hologram found at the location, or null if none was found
    • fixStands

      public void fixStands()
      Removes and re-adds all armor stands in this Hologram
    • getLine

      public String getLine(int line)
      Parameters:
      line - The index of the line
      Returns:
      The line of text at the given index
    • move

      public void move(org.bukkit.Location loc)
      Moves this Hologram
      Parameters:
      loc - The location to move this Hologram to
    • getLocation

      public org.bukkit.Location getLocation()
      Returns:
      The location of the top of this Hologram
    • getStands

      public List<org.bukkit.entity.ArmorStand> getStands()
      Returns:
      All the ArmorStands in this Hologram
    • setLine

      public void setLine(int line, String text)
      Sets the text for a line of this Hologram
      Parameters:
      line - The index of the line to set
      text - The text to set the line to
    • remove

      public void remove(int line)
      Removes a line from this Hologram
      Parameters:
      line - The line number to remove
    • clear

      public void clear()
      Clears this Hologram
    • getLineSpacing

      public double getLineSpacing()
      Returns:
      The vertical distance between each line in this Hologram
    • setLineSpacing

      public void setLineSpacing(double lineSpacing)
      Sets the vertical distance between each line in this Hologram
      Parameters:
      lineSpacing - The line spacing to set
    • append

      public void append(String text)
      Adds a line at the bottom of this Hologram
      Parameters:
      text - The text to append
    • prepend

      public void prepend(String text)
      Adds a line at the top of this Hologram
      Parameters:
      text - The text to add
    • insert

      public void insert(int line, String text)
      Inserts a line in this Hologram
      Parameters:
      line - The position to insert at
      text - The text to insert
    • size

      public int size()
      Returns:
      The number of lines in this Hologram
    • getLines

      public List<String> getLines()