Package redempt.redlib.misc
Class Hologram
java.lang.Object
redempt.redlib.misc.Hologram
Represents a number of floating armor stands intended to display information
-
Method Summary
Modifier and TypeMethodDescriptionvoidAdds a line at the bottom of this Hologramvoidclear()Clears this Hologramstatic HologramCreates a HologramvoidRemoves and re-adds all armor stands in this Hologramstatic HologramgetAt(org.bukkit.Location loc) Attempts to get a Hologram at a specified locationgetLine(int line) getLines()doubleorg.bukkit.LocationList<org.bukkit.entity.ArmorStand>voidInserts a line in this Hologramvoidmove(org.bukkit.Location loc) Moves this HologramvoidAdds a line at the top of this Hologramvoidremove(int line) Removes a line from this HologramvoidSets the text for a line of this HologramvoidsetLineSpacing(double lineSpacing) Sets the vertical distance between each line in this Hologramintsize()
-
Method Details
-
create
Creates a Hologram- Parameters:
loc- The location to create the Hologram atlines- The lines of text for this Hologram- Returns:
- The Hologram that was created
-
getAt
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
- 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
- Returns:
- All the ArmorStands in this Hologram
-
setLine
Sets the text for a line of this Hologram- Parameters:
line- The index of the line to settext- 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
Adds a line at the bottom of this Hologram- Parameters:
text- The text to append
-
prepend
Adds a line at the top of this Hologram- Parameters:
text- The text to add
-
insert
Inserts a line in this Hologram- Parameters:
line- The position to insert attext- The text to insert
-
size
public int size()- Returns:
- The number of lines in this Hologram
-
getLines
-